mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-09-02 16:01:16 +03:00
Add a note about calling mbedtls_ssl_set_hostname to mbedtls_ssl_setup
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
@@ -2041,6 +2041,14 @@ void mbedtls_ssl_init(mbedtls_ssl_context *ssl);
|
||||
* Calling mbedtls_ssl_setup again is not supported, even
|
||||
* if no session is active.
|
||||
*
|
||||
* \warning After setting up a client context, if certificate-based
|
||||
* authentication is enabled, you should call
|
||||
* mbedtls_ssl_set_hostname() to specifiy the expected
|
||||
* name of the server. Without this, in most scenarios,
|
||||
* the TLS connection is insecure. See
|
||||
* #MBEDTLS_ERR_SSL_CERTIFICATE_VERIFICATION_WITHOUT_HOSTNAME
|
||||
* for more information.
|
||||
*
|
||||
* \note If #MBEDTLS_USE_PSA_CRYPTO is enabled, the PSA crypto
|
||||
* subsystem must have been initialized by calling
|
||||
* psa_crypto_init() before calling this function.
|
||||
|
Reference in New Issue
Block a user