Merge pull request #8526 from yanrayw/issue/7011/send_record_size_limit_ext
TLS1.3: SRV/CLI: add support for sending Record Size Limit extension
This commit is contained in:
commit
f1ba1933cf
10 changed files with 294 additions and 49 deletions
|
@ -2540,6 +2540,17 @@ static int ssl_tls13_write_encrypted_extensions_body(mbedtls_ssl_context *ssl,
|
|||
}
|
||||
#endif /* MBEDTLS_SSL_EARLY_DATA */
|
||||
|
||||
#if defined(MBEDTLS_SSL_RECORD_SIZE_LIMIT)
|
||||
if (ssl->handshake->received_extensions & MBEDTLS_SSL_EXT_MASK(RECORD_SIZE_LIMIT)) {
|
||||
ret = mbedtls_ssl_tls13_write_record_size_limit_ext(
|
||||
ssl, p, end, &output_len);
|
||||
if (ret != 0) {
|
||||
return ret;
|
||||
}
|
||||
p += output_len;
|
||||
}
|
||||
#endif
|
||||
|
||||
extensions_len = (p - p_extensions_len) - 2;
|
||||
MBEDTLS_PUT_UINT16_BE(extensions_len, p_extensions_len, 0);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue