Fix typos in ECH implementation

Reviewed-by: Alicja Kario <hkario@redhat.com>
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
(Merged from https://github.com/openssl/openssl/pull/29164)
This commit is contained in:
Tomas Mraz
2025-11-18 09:41:06 +01:00
parent f00ca8cd6b
commit daf47679a0
6 changed files with 10 additions and 10 deletions

View File

@@ -58,7 +58,7 @@ values with public keys from the inputs, and no private key(s).
=item B<-text>
Provide human-readable text ouput.
Provide human-readable text output.
=item B<-public_name> I<name>

View File

@@ -1674,7 +1674,7 @@ static int ech_decode_inner(SSL_CONNECTION *s, const unsigned char *ob,
memset(outers, -1, sizeof(outers)); /* fill with known values for debug */
# endif
/* 1. check for outers and make inital checks of those */
/* 1. check for outers and make initial checks of those */
if (ech_find_outers(s, &ei, outers, &n_outers) != 1)
goto err; /* SSLfatal called already */

View File

@@ -35,13 +35,13 @@
* won't affect the outer CH size, due to padding, but might for some
* larger extensions.
*
* Note there is a co-dependency with test/recipies/75-test_quicapi.t:
* Note there is a co-dependency with test/recipes/75-test_quicapi.t:
* If you change an |ech_handling| value, that may well affect the order
* of extensions in a ClientHello, which is reflected in the test data
* in test/recipies/75-test_quicapi_data/\*.txt files. To fix, you need
* in test/recipes/75-test_quicapi_data/\*.txt files. To fix, you need
* to look in test-runs/test_quicapi for the "new" files and then edit
* (replacing actual octets with "?" in relevant places), and copy the
* result back over to test/recipies/75-test_quicapi_data/. The reason
* result back over to test/recipes/75-test_quicapi_data/. The reason
* this happens is the ECH COMPRESS'd extensions need to be contiguous
* in the ClientHello, so changes to/from COMPRESS affect extension
* order, in inner and outer CH. There doesn't seem to be an easy,
@@ -329,7 +329,7 @@ static const EXTENSION_DEFINITION ext_defs[] = {
* If you want to demonstrate/exercise duplicate, then
* this does that and has no effect on sizes, but it
* will break the quicapi test (see above). Probably
* best done in local tests and not comitted to any
* best done in local tests and not committed to any
* upstream.
* OSSL_ECH_HANDLING_DUPLICATE,
*/

View File

@@ -2544,7 +2544,7 @@ EXT_RETURN tls_construct_ctos_ech(SSL_CONNECTION *s, WPACKET *pkt,
}
return EXT_RETURN_SENT;
}
/* if nobody set a type, use the defaulf */
/* if nobody set a type, use the default */
if (s->ext.ech.attempted_type == OSSL_ECH_type_unknown)
s->ext.ech.attempted_type = TLSEXT_TYPE_ech;
if (ossl_ech_send_grease(s, pkt) != 1) {
@@ -2726,7 +2726,7 @@ int tls_parse_stoc_ech(SSL_CONNECTION *s, PACKET *pkt, unsigned int context,
OSSL_ECH_SIGNAL_LEN);
return 1;
}
/* othewise we expect retry-configs */
/* otherwise we expect retry-configs */
if (!PACKET_get_length_prefixed_2(pkt, &rcfgs_pkt)) {
SSLfatal(s, SSL_AD_DECODE_ERROR, SSL_R_LENGTH_MISMATCH);
return 0;

View File

@@ -2479,7 +2479,7 @@ int tls_parse_ctos_ech(SSL_CONNECTION *s, PACKET *pkt, unsigned int context,
}
/* yay - we're ok with this */
OSSL_TRACE_BEGIN(TLS) {
BIO_printf(trc_out, "ECH seen in inner as exptected.\n");
BIO_printf(trc_out, "ECH seen in inner as expected.\n");
} OSSL_TRACE_END(TLS);
return 1;
}

View File

@@ -1858,7 +1858,7 @@ MSG_PROCESS_RETURN tls_process_server_hello(SSL_CONNECTION *s, PACKET *pkt)
/* check the ECH accept signal */
if (ossl_ech_calc_confirm(s, hrr, c_signal, shlen) != 1) {
/* SSLfatal() already called */
OSSL_TRACE(TLS, "ECH calc confim failed\n");
OSSL_TRACE(TLS, "ECH calc confirm failed\n");
goto err;
}
if (ossl_ech_find_confirm(s, hrr, s_signal) != 1