diff options
author | Kazuki Yamaguchi <k@rhe.jp> | 2020-02-17 08:14:47 +0000 |
---|---|---|
committer | Kazuki Yamaguchi <k@rhe.jp> | 2021-09-26 20:01:10 +0900 |
commit | b74e43bd71b9870e335da0120f5314cd6096e7e9 (patch) | |
tree | 65a85c9d194ee284f68d5a79bd8df6e20a2b4ca3 | |
parent | 6d587b94cbaf86a45084c5a65b4c462252bde2db (diff) | |
download | ruby-openssl-b74e43bd71b9870e335da0120f5314cd6096e7e9.tar.gz |
test/openssl/test_ssl: skip test_fallback_scsv if necessary
[ This is a backport to the 2.1 branch. ]
Run the test case only when the OpenSSL supports both TLS 1.1 and TLS
1.2. Note that the fallback SCSV mechanism is for TLS 1.2 or older and
not for 1.3.
Fixes: https://github.com/ruby/openssl/issues/336
(cherry picked from commit 6f2e6d7cf777b378b3b51c239abecb4e4af49824)
-rw-r--r-- | test/test_ssl.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/test_ssl.rb b/test/test_ssl.rb index 5fe233c1..764416be 100644 --- a/test/test_ssl.rb +++ b/test/test_ssl.rb @@ -1377,6 +1377,10 @@ end end def test_fallback_scsv + supported = check_supported_protocol_versions + return unless supported.include?(OpenSSL::SSL::TLS1_1_VERSION) && + supported.include?(OpenSSL::SSL::TLS1_2_VERSION) + pend "Fallback SCSV is not supported" unless \ OpenSSL::SSL::SSLContext.method_defined?(:enable_fallback_scsv) |