mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-28 00:21:48 +03:00
Add fields to SSL structures describing state and config of CID ext
* mbedtls_ssl_context gets fields indicating whether the CID extension should be negotiated in the next handshake, and, if yes, which CID the user wishes the peer to use. This information does not belong to mbedtls_ssl_handshake_params because (a) it is configured prior to the handshake, and (b) it applies to all subsequent handshakes. * mbedtls_ssl_handshake_params gets fields indicating the state of CID negotiation during the handshake. Specifically, it indicates if the use of the CID extension has been negotiated, and if so, which CID the peer wishes us to use for outgoing messages.
This commit is contained in:
@ -1266,6 +1266,21 @@ struct mbedtls_ssl_context
|
||||
char own_verify_data[MBEDTLS_SSL_VERIFY_DATA_MAX_LEN]; /*!< previous handshake verify data */
|
||||
char peer_verify_data[MBEDTLS_SSL_VERIFY_DATA_MAX_LEN]; /*!< previous handshake verify data */
|
||||
#endif /* MBEDTLS_SSL_RENEGOTIATION */
|
||||
|
||||
#if defined(MBEDTLS_SSL_CID)
|
||||
/* CID configuration to use in subsequent handshakes. */
|
||||
|
||||
/*! The next incoming CID, chosen by the user and applying to
|
||||
* all subsequent handshakes. This may be different from the
|
||||
* CID currently used in case the user has re-configured the CID
|
||||
* after an initial handshake. */
|
||||
unsigned char own_cid[ MBEDTLS_SSL_CID_IN_LEN_MAX ];
|
||||
uint8_t own_cid_len; /*!< The length of \c own_cid. */
|
||||
uint8_t negotiate_cid; /*!< This indicates whether the CID extension should
|
||||
* be negotiated in the next handshake or not.
|
||||
* Possible values are #MBEDTLS_SSL_CID_ENABLED
|
||||
* and #MBEDTLS_SSL_CID_DISABLED. */
|
||||
#endif /* MBEDTLS_SSL_CID */
|
||||
};
|
||||
|
||||
#if defined(MBEDTLS_SSL_HW_RECORD_ACCEL)
|
||||
|
Reference in New Issue
Block a user