1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-08-07 06:42:56 +03:00

TLS1.3 Add hostname extention

Signed-off-by: Xiaofei Bai <xiaofei.bai@arm.com>
This commit is contained in:
Xiaofei Bai
2021-11-05 10:52:12 +00:00
parent 308d618d8d
commit 15a56813a2
3 changed files with 24 additions and 0 deletions

View File

@@ -798,6 +798,14 @@ static int ssl_tls13_write_client_hello_body( mbedtls_ssl_context *ssl,
#endif /* MBEDTLS_KEY_EXCHANGE_WITH_CERT_ENABLED */
#if defined(MBEDTLS_SSL_SERVER_NAME_INDICATION)
/* Write server name extention */
ret = mbedtls_ssl_write_hostname_ext( ssl, p, end, &output_len );
if( ret != 0 )
return( ret );
p += output_len;
#endif /* MBEDTLS_SSL_SERVER_NAME_INDICATION */
/* Add more extensions here */
/* Write the length of the list of extensions. */