mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-02-06 12:40:02 +00:00
Move state change from WRITE_CLIENT_HELLO to its main handler
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
parent
66dbf9118e
commit
3addfa4964
@ -798,12 +798,6 @@ static int ssl_tls13_write_client_hello_body( mbedtls_ssl_context *ssl,
|
|||||||
return( 0 );
|
return( 0 );
|
||||||
}
|
}
|
||||||
|
|
||||||
static int ssl_tls13_finalize_client_hello( mbedtls_ssl_context *ssl )
|
|
||||||
{
|
|
||||||
mbedtls_ssl_handshake_set_state( ssl, MBEDTLS_SSL_SERVER_HELLO );
|
|
||||||
return( 0 );
|
|
||||||
}
|
|
||||||
|
|
||||||
static int ssl_tls13_prepare_client_hello( mbedtls_ssl_context *ssl )
|
static int ssl_tls13_prepare_client_hello( mbedtls_ssl_context *ssl )
|
||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
@ -870,11 +864,12 @@ static int ssl_tls13_write_client_hello( mbedtls_ssl_context *ssl )
|
|||||||
msg_len );
|
msg_len );
|
||||||
ssl->handshake->update_checksum( ssl, buf, msg_len );
|
ssl->handshake->update_checksum( ssl, buf, msg_len );
|
||||||
|
|
||||||
MBEDTLS_SSL_PROC_CHK( ssl_tls13_finalize_client_hello( ssl ) );
|
|
||||||
MBEDTLS_SSL_PROC_CHK( mbedtls_ssl_tls13_finish_handshake_msg( ssl,
|
MBEDTLS_SSL_PROC_CHK( mbedtls_ssl_tls13_finish_handshake_msg( ssl,
|
||||||
buf_len,
|
buf_len,
|
||||||
msg_len ) );
|
msg_len ) );
|
||||||
|
|
||||||
|
mbedtls_ssl_handshake_set_state( ssl, MBEDTLS_SSL_SERVER_HELLO );
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
|
|
||||||
MBEDTLS_SSL_DEBUG_MSG( 2, ( "<= write client hello" ) );
|
MBEDTLS_SSL_DEBUG_MSG( 2, ( "<= write client hello" ) );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user