<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openbsd/src/lib/libssl/ssl_clnt.c, branch OPENBSD_6_8_BASE</title>
<subtitle>A mirror of https://github.com/libressl/openbsd.git
</subtitle>
<id>https://git.lua4.win/openbsd/atom?h=OPENBSD_6_8_BASE</id>
<link rel='self' href='https://git.lua4.win/openbsd/atom?h=OPENBSD_6_8_BASE'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/'/>
<updated>2020-09-24T18:12:00+00:00</updated>
<entry>
<title>Simplify the cleanup of init_buf via a ssl3_release_init_buffer() function.</title>
<updated>2020-09-24T18:12:00+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-09-24T18:12:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=10841ee643f560678ff5ed0276c4da735ec37bdf'/>
<id>urn:sha1:10841ee643f560678ff5ed0276c4da735ec37bdf</id>
<content type='text'>
ok beck@ inoguchi@ tb@
</content>
</entry>
<entry>
<title>Simplify SSL method lookups.</title>
<updated>2020-09-17T15:23:29+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-09-17T15:23:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=ac608c91af9de9141849165d1599e500cf7010cc'/>
<id>urn:sha1:ac608c91af9de9141849165d1599e500cf7010cc</id>
<content type='text'>
There are three places where we call tls1_get_{client,server}_method() and
if that returns NULL, call dtls1_get_{client,server}_method(). Simplify
this by combining the lookup into a single function. While here also use
uint16_t for version types.

ok inoguchi@ millert@
</content>
</entry>
<entry>
<title>Remove cipher_list_by_id.</title>
<updated>2020-09-11T17:36:27+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-09-11T17:36:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=cb4349853bf54ac34c4b6615aa3102e8d10f685f'/>
<id>urn:sha1:cb4349853bf54ac34c4b6615aa3102e8d10f685f</id>
<content type='text'>
When parsing a cipher string, a cipher list is created, before being
duplicated and sorted - the second copy being stored as cipher_list_by_id.
This is done only so that a client can ensure that the cipher selected by
a server is in the cipher list. This is pretty pointless given that most
clients are short-lived and that we already had to iterate over the cipher
list in order to build the client hello. Additionally, any update to the
cipher list requires that cipher_list_by_id also be updated and kept in
sync.

Remove all of this and replace it with a simple linear scan - the overhead
of duplicating and sorting the cipher list likely exceeds that of a simple
linear scan over the cipher list (64 maximum, more typically ~9 or so).

ok beck@ tb@
</content>
</entry>
<entry>
<title>Improve argument order for the internal tlsext API</title>
<updated>2020-07-03T04:12:51+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2020-07-03T04:12:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=3634005e8a2051a239211f692a45371c14e9d8e4'/>
<id>urn:sha1:3634005e8a2051a239211f692a45371c14e9d8e4</id>
<content type='text'>
Move is_server and msg_type right after the SSL object so that CBS
and CBB and alert come last. This brings these functions more in
line with other internal functions and separates state from data.

requested by jsing
</content>
</entry>
<entry>
<title>Enable GOST_SIG_FORMAT_RS_LE when verifying certificate signatures.</title>
<updated>2020-06-05T17:53:26+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-06-05T17:53:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=81397cfe8d753bdd48b231533c4285712b53065f'/>
<id>urn:sha1:81397cfe8d753bdd48b231533c4285712b53065f</id>
<content type='text'>
GOST cipher suites requires that CertVerify signatures be generated in a
special way (see ssl3_send_client_kex_gost(), ssl3_get_cert_verify()).
However, the GOST_SIG_FORMAT_RS_LE flag was not passed in case of TLS 1.2
connections (because they use different code path). Set this flag on
GOST PKEYs.

Diff from Dmitry Baryshkov &lt;dbaryshkov@gmail.com&gt;

Sponsored by ROSA Linux

ok inoguchi@ tb@
</content>
</entry>
<entry>
<title>Correct downgrade sentinels when a version pinned method is in use.</title>
<updated>2020-05-31T16:36:35+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-05-31T16:36:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=059c16b3ca987ee98bd63a9cf4d0c58bfc02334e'/>
<id>urn:sha1:059c16b3ca987ee98bd63a9cf4d0c58bfc02334e</id>
<content type='text'>
Previously only the enabled protocol versions were considered, however we
also have to consider the method in use which may be version pinned.

Found the hard way by danj@ with haproxy and force-tlsv12.

ok beck@ inoguchi@ tb@
</content>
</entry>
<entry>
<title>Replace SSL_PKEY_RSA_ENC/SSL_PKEY_RSA_SIGN with SSL_PKEY_RSA.</title>
<updated>2020-05-19T16:35:21+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-05-19T16:35:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=369bbcd163f15f6e452e14282f0a65dafde2f5ab'/>
<id>urn:sha1:369bbcd163f15f6e452e14282f0a65dafde2f5ab</id>
<content type='text'>
Some time prior to SSLeay 0.8.1b, SSL_PKEY_RSA_SIGN got added with the
intention of handling RSA sign only certificates... this incomplete code
had the following comment:

  /* check to see if this is a signing only certificate */
  /* EAY EAY EAY EAY */

And while the comment was removed in 2005, the incomplete RSA sign-only
handling has remained ever since.

Remove SSL_PKEY_RSA_SIGN and rename SSL_PKEY_RSA_ENC to SSL_PKEY_RSA. While
here also remove the unused SSL_PKEY_DH_RSA.

ok tb@
</content>
</entry>
<entry>
<title>Use size_t for OCSP response length.</title>
<updated>2020-05-10T14:17:48+00:00</updated>
<author>
<name>jsing</name>
<email></email>
</author>
<published>2020-05-10T14:17:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=4749b6f55a603d6923ae5901d112961ff3c56b38'/>
<id>urn:sha1:4749b6f55a603d6923ae5901d112961ff3c56b38</id>
<content type='text'>
The OCSP response length is currently an integer, which is overloaded with
-1 meaning "unset". Use a size_t for the OCSP response length and infer
unset from the OCSP response being NULL. This makes code more readable,
simpler and less error prone.

ok beck@
</content>
</entry>
<entry>
<title>Drop a redundant test. It's effectively doing the same test twice</title>
<updated>2020-05-09T13:54:19+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2020-05-09T13:54:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=8cca1015a78744c20ba4ce0c7d177b2cf12cc2bb'/>
<id>urn:sha1:8cca1015a78744c20ba4ce0c7d177b2cf12cc2bb</id>
<content type='text'>
and if the two lengths differed, the later CBS_write_bytes() would
correctly fail anyway.

Discussed with jsing
</content>
</entry>
<entry>
<title>RFC 8446, section 4.1.3: If a TLSv1.2 client receives a ServerHello for</title>
<updated>2020-03-06T16:36:47+00:00</updated>
<author>
<name>tb</name>
<email></email>
</author>
<published>2020-03-06T16:36:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=3be36c8843a332517575048813c2cda232e68351'/>
<id>urn:sha1:3be36c8843a332517575048813c2cda232e68351</id>
<content type='text'>
TLSv1.1 or below, it should check whether the server's random value
contains the magic downgrade protection cookie and in that case abort
the handshake with an illegal parameter alert.

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