<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openbsd/src/lib/libcrypto/x509/by_dir.c, branch OPENBSD_7_9_BASE</title>
<subtitle>A mirror of https://github.com/libressl/openbsd.git
</subtitle>
<id>https://git.lua4.win/openbsd/atom?h=OPENBSD_7_9_BASE</id>
<link rel='self' href='https://git.lua4.win/openbsd/atom?h=OPENBSD_7_9_BASE'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/'/>
<updated>2025-05-10T05:54:39+00:00</updated>
<entry>
<title>Use err_local.h rather than err.h in most places</title>
<updated>2025-05-10T05:54:39+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2025-05-10T05:54:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=41e8f99dd1625a9f0c80ce9d4383e95b18e85709'/>
<id>urn:sha1:41e8f99dd1625a9f0c80ce9d4383e95b18e85709</id>
<content type='text'>
ok jsing
</content>
</entry>
<entry>
<title>const correct X509_LOOKUP_METHOD</title>
<updated>2024-08-31T10:19:17+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2024-08-31T10:19:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=d64314baed3e30b9cf75f58caf085b356a3f6d2f'/>
<id>urn:sha1:d64314baed3e30b9cf75f58caf085b356a3f6d2f</id>
<content type='text'>
With this another family of global tables becomes const as it should
always have been.

ok beck jsing
</content>
</entry>
<entry>
<title>Remove unnecessary stat() calls from by_dir</title>
<updated>2024-03-25T00:05:49+00:00</updated>
<author>
<name>beck</name>
<email></email>
</author>
<published>2024-03-25T00:05:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=e9b001f0ec0e1d250cdf229432ac3949a3580968'/>
<id>urn:sha1:e9b001f0ec0e1d250cdf229432ac3949a3580968</id>
<content type='text'>
When searching for a CA or CRL file in by_dir, this stat()
was used to short circuit attempting to open the file with
X509_load_cert_file(). This was a deliberate TOCTOU introduced
to avoid setting an error on the error stack, when what you
really want to say is "we couldn't find a CA" and continue
merrily on your way.

As it so happens you really do not care why the load_file failed
in any of these cases, it all boils down to "I can't find the CA
or CRL". Instead we just omit the stat call, and clear the error
stack if the load_file fails. The fact that you don't have a CA or
CRL is caught later in the callers and is what you want, mimicing
the non by_dir behaviour instead of possibly some bizzaro file
system error.

Based on a similar change in Boring.

ok tb@
</content>
</entry>
<entry>
<title>Use a void pointer rather than char for method_data</title>
<updated>2023-12-29T05:33:32+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2023-12-29T05:33:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=550360beaf4afd0234c9e8ebb276df82df30adce'/>
<id>urn:sha1:550360beaf4afd0234c9e8ebb276df82df30adce</id>
<content type='text'>
This way we don't need to cast from BY_DIR * to char * and back in
its only consumer, the lovely by_dir.
</content>
</entry>
<entry>
<title>Remove unused X509_LOOKUP_METHODs</title>
<updated>2023-12-25T22:14:23+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2023-12-25T22:14:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=242a046bef09576e509ed521d7e6ac2c279faf7e'/>
<id>urn:sha1:242a046bef09576e509ed521d7e6ac2c279faf7e</id>
<content type='text'>
None of these function pointers were ever set. Now that the structure is
opaque they won't ever be, so time for them to hit the bitbucket. Infinite
extensibility of the toolkit results in complications, bugs, and dead code.

ok jsing
</content>
</entry>
<entry>
<title>libressl *_namespace.h: adjust *_ALIAS() to require a semicolon</title>
<updated>2023-02-16T08:38:17+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2023-02-16T08:38:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=24a27fd0d17d515b00097199de60fa85a76a95df'/>
<id>urn:sha1:24a27fd0d17d515b00097199de60fa85a76a95df</id>
<content type='text'>
LCRYPTO_ALIAS() and LSSL_ALIAS() contained a trailing semicolon.
This does not conform to style(9), breaks editors and ctags and
(most importantly) my workflow. Fix this by neutering them with
asm("") so that -Wpedantic doesn't complain. There's precedent
in libc's namespace.h

fix suggested by &amp; ok jsing
</content>
</entry>
<entry>
<title>Make internal header file names consistent</title>
<updated>2022-11-26T16:08:57+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2022-11-26T16:08:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=81d98bf600a381a625eb11b39a725b08c0ba547f'/>
<id>urn:sha1:81d98bf600a381a625eb11b39a725b08c0ba547f</id>
<content type='text'>
Libcrypto currently has a mess of *_lcl.h, *_locl.h, and *_local.h names
used for internal headers. Move all these headers we inherited from
OpenSSL to *_local.h, reserving the name *_internal.h for our own code.
Similarly, move dtls_locl.h and ssl_locl.h to dtls_local and ssl_local.h.
constant_time_locl.h is moved to constant_time.h since it's special.

Adjust all .c files in libcrypto, libssl and regress.

The diff is mechanical with the exception of tls13_quic.c, where
#include &lt;ssl_locl.h&gt; was fixed manually.

discussed with jsing,
no objection bcook
</content>
</entry>
<entry>
<title>Hide public symbols in libcrypto/x509 .c files</title>
<updated>2022-11-14T17:48:50+00:00</updated>
<author>
<name>beck</name>
<email></email>
</author>
<published>2022-11-14T17:48:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=86ef9af254717a5620d93d1ebe06ab2ad9597496'/>
<id>urn:sha1:86ef9af254717a5620d93d1ebe06ab2ad9597496</id>
<content type='text'>
ok tb@
</content>
</entry>
<entry>
<title>Merge a few additional X509error(ERR_R_MALLOC_FAILURE) calls</title>
<updated>2021-11-10T14:34:21+00:00</updated>
<author>
<name>schwarze</name>
<email></email>
</author>
<published>2021-11-10T14:34:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=c1f5af74ca6b87347d35a5339b06f2f86a8a4ca0'/>
<id>urn:sha1:c1f5af74ca6b87347d35a5339b06f2f86a8a4ca0</id>
<content type='text'>
and various style improvements from the OpenSSL 1.1.1 branch,
which is still under a free license.

- No need to #include &lt;openssl/lhash.h&gt;.
- BUF_MEM_free(3) and sk_pop_free(3) can handle NULL.
- sk_value(3) can handle -1.
- Test pointers with "== NULL" rather than with "!".
- Use the safer "p = malloc(sizeof(*p))" idiom.
- return is not a function.
- Delete very wrong commented out code.

Including parts of the these commits from the 2015 to 2018 time range:
25aaa98a b4faea50 90945fa3 f32b0abe 26a7d938 7fcdbd83 208056b2 5b37fef0

Requested by and OK tb@.
</content>
</entry>
<entry>
<title>Move the now internal X.509-related structs into x509_lcl.h.</title>
<updated>2021-11-01T20:53:08+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2021-11-01T20:53:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=f478d62658b61e2242dbf3575bf454f8c0f432b1'/>
<id>urn:sha1:f478d62658b61e2242dbf3575bf454f8c0f432b1</id>
<content type='text'>
Garbage collect the now unused LIBRESSL_CRYPTO_INTERNAL and
LIBRESSL_OPAQUE_X509. Include "x509_lcl.h" where needed and
fix a couple of unnecessary reacharounds.

ok jsing
</content>
</entry>
</feed>
