From 79bb19f7022ee71b7dd1befd98de7faa03bf83e6 Mon Sep 17 00:00:00 2001 From: David Horstmann Date: Wed, 2 Nov 2022 14:07:46 +0000 Subject: [PATCH] Remove redundant checks for renegotiation Signed-off-by: David Horstmann --- library/ssl_cli.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/library/ssl_cli.c b/library/ssl_cli.c index 5df2758da0..4817bd6413 100644 --- a/library/ssl_cli.c +++ b/library/ssl_cli.c @@ -1089,11 +1089,6 @@ static int ssl_write_client_hello( mbedtls_ssl_context *ssl ) * RFC 5077 section 3.4: "When presenting a ticket, the client MAY * generate and include a Session ID in the TLS ClientHello." */ - renegotiating = 0; -#if defined(MBEDTLS_SSL_RENEGOTIATION) - if( ssl->renego_status != MBEDTLS_SSL_INITIAL_HANDSHAKE ) - renegotiating = 1; -#endif if( !renegotiating ) { if( ssl->session_negotiate->ticket != NULL && @@ -1209,11 +1204,6 @@ static int ssl_write_client_hello( mbedtls_ssl_context *ssl ) /* * Add TLS_EMPTY_RENEGOTIATION_INFO_SCSV */ - renegotiating = 0; -#if defined(MBEDTLS_SSL_RENEGOTIATION) - if( ssl->renego_status != MBEDTLS_SSL_INITIAL_HANDSHAKE ) - renegotiating = 1; -#endif if( !renegotiating ) { MBEDTLS_SSL_DEBUG_MSG( 3, ( "adding EMPTY_RENEGOTIATION_INFO_SCSV" ) );