Skip to content

Commit 25e4827

Browse files
committed
Adjust comments.
1 parent 3874a27 commit 25e4827

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎Modules/_ssl.c‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5343,6 +5343,8 @@ ech_store_from_config(_sslmodulestate *state, Py_buffer *ech_config)
53435343
}
53445344
const unsigned char *config = ech_config->buf;
53455345
int config_len = (int)ech_config->len;
5346+
// RFC 9849 says that clients have to skip unknown entries, so we have to do
5347+
// this extra parsing step ourselves.
53465348
if (config_len >= 2 && ((config[0] << 8) | config[1]) == config_len - 2) {
53475349
config += 2;
53485350
config_len -= 2;
@@ -5468,7 +5470,7 @@ load_ech_keys(SSL_CTX *ctx, BIO *bio, int for_retry,
54685470
|| OSSL_ECHSTORE_num_keys(store, &new_keys) != 1) {
54695471
goto end;
54705472
}
5471-
// OpenSSL may match a key already in the store. Require a new match.
5473+
// OpenSSL may match a key already in the store. We want to to require a new match.
54725474
if (new_keys <= old_keys) {
54735475
ERR_raise(ERR_LIB_SSL, SSL_R_PRIVATE_KEY_MISMATCH);
54745476
goto end;

0 commit comments

Comments
 (0)