mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-28 00:21:48 +03:00
tls13: Introduce early_data_state SSL context field
Introduce early_data_state SSL context field to distinguish better this internal state from the status values defined for the mbedtls_ssl_get_early_data_status() API. Distinguish also between the client and server states. Note that the client state are going to be documented and reworked as part of the implementation of mbedtls_ssl_write_early_data(). Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
@ -2130,30 +2130,6 @@ int mbedtls_ssl_tls13_write_early_data_ext(mbedtls_ssl_context *ssl,
|
||||
unsigned char *buf,
|
||||
const unsigned char *end,
|
||||
size_t *out_len);
|
||||
|
||||
#if defined(MBEDTLS_SSL_SRV_C)
|
||||
/* Additional internal early data status, server side only. */
|
||||
/*
|
||||
* The server has not received the ClientHello yet, the status of early data
|
||||
* is thus unknown.
|
||||
*/
|
||||
#define MBEDTLS_SSL_EARLY_DATA_STATUS_UNKNOWN \
|
||||
MBEDTLS_SSL_EARLY_DATA_STATUS_NOT_SENT
|
||||
|
||||
/*
|
||||
* The server has received the ClientHello, it contained no early data
|
||||
* extension.
|
||||
*/
|
||||
#define MBEDTLS_SSL_EARLY_DATA_STATUS_NOT_RECEIVED 3
|
||||
|
||||
/*
|
||||
* The server has received the early data extension, it has accepted early
|
||||
* data and received the end of early data message from the client marking the
|
||||
* end of early data reception.
|
||||
*/
|
||||
#define MBEDTLS_SSL_EARLY_DATA_STATUS_END_OF_EARLY_DATA_RECEIVED 4
|
||||
#endif /* MBEDTLS_SSL_SRV_C */
|
||||
|
||||
#endif /* MBEDTLS_SSL_EARLY_DATA */
|
||||
|
||||
#endif /* MBEDTLS_SSL_PROTO_TLS1_3 */
|
||||
|
Reference in New Issue
Block a user