forked from wolfSSL/wolfssl
Merge pull request #7405 from SparkiDev/mismatch_cs_alert
No match cipher suite alert type change
This commit is contained in:
@ -17206,9 +17206,6 @@ int SendFatalAlertOnly(WOLFSSL *ssl, int error)
|
|||||||
case COMPRESSION_ERROR:
|
case COMPRESSION_ERROR:
|
||||||
why = decode_error;
|
why = decode_error;
|
||||||
break;
|
break;
|
||||||
case MATCH_SUITE_ERROR:
|
|
||||||
why = illegal_parameter;
|
|
||||||
break;
|
|
||||||
case VERIFY_FINISHED_ERROR:
|
case VERIFY_FINISHED_ERROR:
|
||||||
case SIG_VERIFY_E:
|
case SIG_VERIFY_E:
|
||||||
why = decrypt_error;
|
why = decrypt_error;
|
||||||
@ -17221,6 +17218,7 @@ int SendFatalAlertOnly(WOLFSSL *ssl, int error)
|
|||||||
case ECC_OUT_OF_RANGE_E:
|
case ECC_OUT_OF_RANGE_E:
|
||||||
why = bad_record_mac;
|
why = bad_record_mac;
|
||||||
break;
|
break;
|
||||||
|
case MATCH_SUITE_ERROR:
|
||||||
case VERSION_ERROR:
|
case VERSION_ERROR:
|
||||||
default:
|
default:
|
||||||
why = handshake_failure;
|
why = handshake_failure;
|
||||||
|
@ -66610,7 +66610,7 @@ static int test_extra_alerts_wrong_cs(void)
|
|||||||
ExpectIntNE(wolfSSL_get_error(ssl_c, WOLFSSL_FATAL_ERROR),
|
ExpectIntNE(wolfSSL_get_error(ssl_c, WOLFSSL_FATAL_ERROR),
|
||||||
WOLFSSL_ERROR_WANT_READ);
|
WOLFSSL_ERROR_WANT_READ);
|
||||||
ExpectIntEQ(wolfSSL_get_alert_history(ssl_c, &h), WOLFSSL_SUCCESS);
|
ExpectIntEQ(wolfSSL_get_alert_history(ssl_c, &h), WOLFSSL_SUCCESS);
|
||||||
ExpectIntEQ(h.last_tx.code, illegal_parameter);
|
ExpectIntEQ(h.last_tx.code, handshake_failure);
|
||||||
ExpectIntEQ(h.last_tx.level, alert_fatal);
|
ExpectIntEQ(h.last_tx.level, alert_fatal);
|
||||||
|
|
||||||
wolfSSL_free(ssl_c);
|
wolfSSL_free(ssl_c);
|
||||||
|
Reference in New Issue
Block a user