mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-29 18:27:29 +02:00
Fix for TLS v1.3 with --enable-sniffer
.
This commit is contained in:
@ -2371,7 +2371,7 @@ THREAD_RETURN WOLFSSL_THREAD client_test(void* args)
|
||||
#endif
|
||||
|
||||
#if defined(WOLFSSL_SNIFFER)
|
||||
if (cipherList == NULL) {
|
||||
if (cipherList == NULL && version < 4) {
|
||||
/* don't use EDH, can't sniff tmp keys */
|
||||
if (wolfSSL_CTX_set_cipher_list(ctx, "AES128-SHA") != WOLFSSL_SUCCESS) {
|
||||
wolfSSL_CTX_free(ctx); ctx = NULL;
|
||||
|
@ -121,7 +121,11 @@ void echoclient_test(void* args)
|
||||
#if defined(CYASSL_DTLS)
|
||||
method = DTLSv1_2_client_method();
|
||||
#elif !defined(NO_TLS)
|
||||
#if defined(WOLFSSL_TLS13) && defined(WOLFSSL_SNIFFER)
|
||||
method = CyaTLSv1_2_client_method();
|
||||
#else
|
||||
method = CyaSSLv23_client_method();
|
||||
#endif
|
||||
#elif defined(WOLFSSL_ALLOW_SSLV3)
|
||||
method = SSLv3_client_method();
|
||||
#else
|
||||
@ -151,7 +155,7 @@ void echoclient_test(void* args)
|
||||
|
||||
#if defined(CYASSL_SNIFFER)
|
||||
/* Only set if not running testsuite */
|
||||
if (XSTRNCMP(argv[0], "testsuite", XSTRLEN("testsuite")) != 0) {
|
||||
if (XSTRSTR(argv[0], "testsuite") != 0) {
|
||||
/* don't use EDH, can't sniff tmp keys */
|
||||
SSL_CTX_set_cipher_list(ctx, "AES256-SHA");
|
||||
}
|
||||
|
@ -138,7 +138,11 @@ THREAD_RETURN CYASSL_THREAD echoserver_test(void* args)
|
||||
#if defined(CYASSL_DTLS)
|
||||
method = CyaDTLSv1_2_server_method();
|
||||
#elif !defined(NO_TLS)
|
||||
#if defined(WOLFSSL_TLS13) && defined(WOLFSSL_SNIFFER)
|
||||
method = CyaTLSv1_2_server_method();
|
||||
#else
|
||||
method = CyaSSLv23_server_method();
|
||||
#endif
|
||||
#elif defined(WOLFSSL_ALLOW_SSLV3)
|
||||
method = CyaSSLv3_server_method();
|
||||
#else
|
||||
@ -228,7 +232,7 @@ THREAD_RETURN CYASSL_THREAD echoserver_test(void* args)
|
||||
|
||||
#if defined(CYASSL_SNIFFER)
|
||||
/* Only set if not running testsuite */
|
||||
if (XSTRNCMP(argv[0], "testsuite", XSTRLEN("testsuite")) != 0) {
|
||||
if (XSTRSTR(argv[0], "testsuite") != 0) {
|
||||
/* don't use EDH, can't sniff tmp keys */
|
||||
CyaSSL_CTX_set_cipher_list(ctx, "AES256-SHA");
|
||||
}
|
||||
|
@ -1830,7 +1830,7 @@ THREAD_RETURN WOLFSSL_THREAD server_test(void* args)
|
||||
|
||||
#if defined(WOLFSSL_SNIFFER)
|
||||
/* don't use EDH, can't sniff tmp keys */
|
||||
if (cipherList == NULL) {
|
||||
if (cipherList == NULL && version < 4) {
|
||||
if (SSL_CTX_set_cipher_list(ctx, "AES128-SHA") != WOLFSSL_SUCCESS)
|
||||
err_sys_ex(runWithErrors, "server can't set cipher list 3");
|
||||
}
|
||||
|
Reference in New Issue
Block a user