tls13: Fix/Improve comments
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
parent
84dfbf488a
commit
b9a9b1f5a5
3 changed files with 30 additions and 32 deletions
|
@ -1657,31 +1657,31 @@ struct mbedtls_ssl_context {
|
|||
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||
|
||||
/**
|
||||
* Maximum TLS version to be negotiated, then negotiated TLS version.
|
||||
* Maximum TLS version to be negotiated, then negotiated TLS version.
|
||||
*
|
||||
* It is initialized as the configured maximum TLS version to be
|
||||
* negotiated by mbedtls_ssl_setup().
|
||||
* It is initialized as the configured maximum TLS version to be
|
||||
* negotiated by mbedtls_ssl_setup().
|
||||
*
|
||||
* When renegotiating or resuming a session, it is overwritten in the
|
||||
* ClientHello writing preparation stage with the previously negotiated
|
||||
* TLS version.
|
||||
* When renegotiating or resuming a session, it is overwritten in the
|
||||
* ClientHello writing preparation stage with the previously negotiated
|
||||
* TLS version.
|
||||
*
|
||||
* On client side, it is updated to the TLS version selected by the server
|
||||
* for the handshake when the ServerHello is received.
|
||||
* On client side, it is updated to the TLS version selected by the server
|
||||
* for the handshake when the ServerHello is received.
|
||||
*
|
||||
* On server side, it is updated to the TLS version the server selects for
|
||||
* the handshake when the ClientHello is received.
|
||||
* On server side, it is updated to the TLS version the server selects for
|
||||
* the handshake when the ClientHello is received.
|
||||
*/
|
||||
mbedtls_ssl_protocol_version MBEDTLS_PRIVATE(tls_version);
|
||||
|
||||
#if defined(MBEDTLS_SSL_EARLY_DATA) && defined(MBEDTLS_SSL_CLI_C)
|
||||
/**
|
||||
* Status of the negotiation of the use of early data.
|
||||
* See the documentation of mbedtls_ssl_get_early_data_status() for more
|
||||
* information.
|
||||
* Status of the negotiation of the use of early data.
|
||||
* See the documentation of mbedtls_ssl_get_early_data_status() for more
|
||||
* information.
|
||||
*
|
||||
* Reset to #MBEDTLS_SSL_EARLY_DATA_STATUS_NOT_SENT when the context is
|
||||
* reset.
|
||||
* Reset to #MBEDTLS_SSL_EARLY_DATA_STATUS_UNKNOWN when the context is
|
||||
* reset.
|
||||
*/
|
||||
int MBEDTLS_PRIVATE(early_data_status);
|
||||
#endif
|
||||
|
|
|
@ -665,21 +665,21 @@ struct mbedtls_ssl_handshake_params {
|
|||
#if defined(MBEDTLS_SSL_CLI_C)
|
||||
/** Minimum TLS version to be negotiated.
|
||||
*
|
||||
* It is set up in the ClientHello writing preparation stage and used
|
||||
* throughout the ClientHello writing. Not relevant anymore as soon as
|
||||
* the protocol version has been negotiated thus as soon as the
|
||||
* ServerHello is received.
|
||||
* For a fresh handshake not linked to any previous handshake, it is
|
||||
* equal to the configured minimum minor version to be negotiated. When
|
||||
* renegotiating or resuming a session, it is equal to the previously
|
||||
* negotiated minor version.
|
||||
* It is set up in the ClientHello writing preparation stage and used
|
||||
* throughout the ClientHello writing. Not relevant anymore as soon as
|
||||
* the protocol version has been negotiated thus as soon as the
|
||||
* ServerHello is received.
|
||||
* For a fresh handshake not linked to any previous handshake, it is
|
||||
* equal to the configured minimum minor version to be negotiated. When
|
||||
* renegotiating or resuming a session, it is equal to the previously
|
||||
* negotiated minor version.
|
||||
*
|
||||
* There is no maximum TLS version field in this handshake context.
|
||||
* From the start of the handshake, we need to define a current protocol
|
||||
* version for the record layer which we define as the maximum TLS
|
||||
* version to be negotiated. The `tls_version` field of the SSL context is
|
||||
* used to store this maximum value until it contains the actual
|
||||
* negotiated value.
|
||||
* There is no maximum TLS version field in this handshake context.
|
||||
* From the start of the handshake, we need to define a current protocol
|
||||
* version for the record layer which we define as the maximum TLS
|
||||
* version to be negotiated. The `tls_version` field of the SSL context is
|
||||
* used to store this maximum value until it contains the actual
|
||||
* negotiated value.
|
||||
*/
|
||||
mbedtls_ssl_protocol_version min_tls_version;
|
||||
#endif
|
||||
|
|
|
@ -607,9 +607,7 @@ int mbedtls_test_get_tls13_ticket(
|
|||
mbedtls_test_handshake_test_options *client_options,
|
||||
mbedtls_test_handshake_test_options *server_options,
|
||||
mbedtls_ssl_session *session);
|
||||
#endif /* MBEDTLS_SSL_CLI_C && MBEDTLS_SSL_SRV_C &&
|
||||
MBEDTLS_SSL_PROTO_TLS1_3 && MBEDTLS_SSL_SESSION_TICKETS &&
|
||||
MBEDTLS_SSL_HANDSHAKE_WITH_CERT_ENABLED */
|
||||
#endif
|
||||
|
||||
#define ECJPAKE_TEST_PWD "bla"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue