mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-08-03 20:54:41 +02:00
Fix empty renegotiation info ciphersuite handling
This commit is contained in:
@@ -23701,11 +23701,19 @@ static int DoSessionTicket(WOLFSSL* ssl, const byte* input, word32* inOutIdx,
|
||||
#ifdef HAVE_SERVER_RENEGOTIATION_INFO
|
||||
/* check for TLS_EMPTY_RENEGOTIATION_INFO_SCSV suite */
|
||||
if (FindSuite(&clSuites, 0, TLS_EMPTY_RENEGOTIATION_INFO_SCSV) >= 0) {
|
||||
TLSX* extension;
|
||||
|
||||
/* check for TLS_EMPTY_RENEGOTIATION_INFO_SCSV suite */
|
||||
ret = TLSX_AddEmptyRenegotiationInfo(&ssl->extensions, ssl->heap);
|
||||
if (ret != WOLFSSL_SUCCESS)
|
||||
return ret;
|
||||
if (ssl->secure_renegotiation)
|
||||
|
||||
extension = TLSX_Find(ssl->extensions, TLSX_RENEGOTIATION_INFO);
|
||||
if (extension) {
|
||||
ssl->secure_renegotiation =
|
||||
(SecureRenegotiation*)extension->data;
|
||||
ssl->secure_renegotiation->enabled = 1;
|
||||
}
|
||||
}
|
||||
#endif /* HAVE_SERVER_RENEGOTIATION_INFO */
|
||||
|
||||
|
@@ -3874,11 +3874,18 @@ int DoTls13ClientHello(WOLFSSL* ssl, const byte* input, word32* inOutIdx,
|
||||
|
||||
#ifdef HAVE_SERVER_RENEGOTIATION_INFO
|
||||
if (FindSuite(&clSuites, 0, TLS_EMPTY_RENEGOTIATION_INFO_SCSV) >= 0) {
|
||||
TLSX* extension;
|
||||
|
||||
/* check for TLS_EMPTY_RENEGOTIATION_INFO_SCSV suite */
|
||||
ret = TLSX_AddEmptyRenegotiationInfo(&ssl->extensions, ssl->heap);
|
||||
if (ret != WOLFSSL_SUCCESS)
|
||||
return ret;
|
||||
ssl->secure_renegotiation->enabled = 1;
|
||||
|
||||
extension = TLSX_Find(ssl->extensions, TLSX_RENEGOTIATION_INFO);
|
||||
if (extension) {
|
||||
ssl->secure_renegotiation = (SecureRenegotiation*)extension->data;
|
||||
ssl->secure_renegotiation->enabled = 1;
|
||||
}
|
||||
}
|
||||
#endif /* HAVE_SERVER_RENEGOTIATION_INFO */
|
||||
|
||||
|
Reference in New Issue
Block a user