summaryrefslogtreecommitdiffstats
path: root/test/clienthellotest.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2018-02-09 10:19:14 +0000
committerMatt Caswell <matt@openssl.org>2018-02-09 17:44:43 +0000
commitc423ecaa7f6d0cc77c4f121c6de7d585439bca8f (patch)
tree8dd31481afb05f8febe065821ad74a0e17ea02df /test/clienthellotest.c
parent83739b39e55fcdd9dd395bc619b1b7fafcc32f5c (diff)
Fixes for no-tls1_2 and no-tls1_2-method
The no-tls1_2 option does not work properly in conjunction with TLSv1.3 being enabled (which is now the default). This commit fixes the issues. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5301)
Diffstat (limited to 'test/clienthellotest.c')
-rw-r--r--test/clienthellotest.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/clienthellotest.c b/test/clienthellotest.c
index f3e9588e51..32103d0c35 100644
--- a/test/clienthellotest.c
+++ b/test/clienthellotest.c
@@ -81,9 +81,14 @@ static int test_client_hello(int currtest)
switch(currtest) {
case TEST_SET_SESSION_TICK_DATA_VER_NEG:
+#if !defined(OPENSSL_NO_TLS1_3) && defined(OPENSSL_NO_TLS1_2)
+ /* TLSv1.3 is enabled and TLSv1.2 is disabled so can't do this test */
+ return 1;
+#else
/* Testing for session tickets <= TLS1.2; not relevant for 1.3 */
if (!TEST_true(SSL_CTX_set_max_proto_version(ctx, TLS1_2_VERSION)))
goto end;
+#endif
break;
case TEST_ADD_PADDING_AND_PSK: