diff options
author | Matt Caswell <matt@openssl.org> | 2018-08-20 19:05:28 +0200 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2018-08-22 16:15:19 +0200 |
commit | 5627f9f21764af7eac2af2fb8ec867cd65ca8949 (patch) | |
tree | 4313d7650ce6a132ba00feab55b02cc7fa87b536 /test/recipes/70-test_tls13downgrade.t | |
parent | Test that a client protocol "hole" doesn't get detected as a downgrade (diff) | |
download | openssl-5627f9f21764af7eac2af2fb8ec867cd65ca8949.tar.xz openssl-5627f9f21764af7eac2af2fb8ec867cd65ca8949.zip |
Don't detect a downgrade where the server has a protocol version hole
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/7013)
Diffstat (limited to '')
-rw-r--r-- | test/recipes/70-test_tls13downgrade.t | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/test/recipes/70-test_tls13downgrade.t b/test/recipes/70-test_tls13downgrade.t index b84ca69a8b..bdb360a7dc 100644 --- a/test/recipes/70-test_tls13downgrade.t +++ b/test/recipes/70-test_tls13downgrade.t @@ -45,7 +45,7 @@ use constant { $proxy->filter(\&downgrade_filter); my $testtype = DOWNGRADE_TO_TLS_1_2; $proxy->start() or plan skip_all => "Unable to start up Proxy for tests"; -plan tests => 5; +plan tests => 6; ok(TLSProxy::Message->fail(), "Downgrade TLSv1.3 to TLSv1.2"); #Test 2: Downgrade from TLSv1.3 to TLSv1.1 @@ -74,13 +74,20 @@ ok(TLSProxy::Message->fail() "Fallback from TLSv1.3"); SKIP: { - skip "TLSv1.1 disabled", 1 if disabled("tls1_1"); - #Test 5: A protocol "hole" should not be detected as a downgrade + skip "TLSv1.1 disabled", 2 if disabled("tls1_1"); + #Test 5: A client side protocol "hole" should not be detected as a downgrade $proxy->clear(); $proxy->filter(undef); $proxy->clientflags("-no_tls1_2"); $proxy->start(); - ok(TLSProxy::Message->success(), "TLSv1.2 protocol hole"); + ok(TLSProxy::Message->success(), "TLSv1.2 client-side protocol hole"); + + #Test 6: A server side protocol "hole" should not be detected as a downgrade + $proxy->clear(); + $proxy->filter(undef); + $proxy->serverflags("-no_tls1_2"); + $proxy->start(); + ok(TLSProxy::Message->success(), "TLSv1.2 server-side protocol hole"); } sub downgrade_filter |