diff options
author | Jeremy Evans <code@jeremyevans.net> | 2023-10-18 22:13:12 +0100 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2023-10-18 21:13:21 +0000 |
commit | de0764501987aff0f9b19594a2cbd5583ccce660 (patch) | |
tree | 638601ada0bfa6ee37b32474b1dea6609cdd88ab /test/drb/ut_array_drbssl.rb | |
parent | f51b92fe231266a1a184b8329d43520599d2017b (diff) |
[ruby/drb] Support :SSL{Min,Max}Version config options
These are necessary to get the tests passing with LibreSSL 3.8.1+,
which dropped support for TLSv1.0 and TLSv1.1 for security reasons.
This updates the tests to use TLSv1.2 on OpenBSD. This is only
strictly necessary on OpenBSD 7.4+, but it will work fine in previous
versions as well.
https://github.com/ruby/drb/commit/32707b2db5
Diffstat (limited to 'test/drb/ut_array_drbssl.rb')
-rw-r--r-- | test/drb/ut_array_drbssl.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/drb/ut_array_drbssl.rb b/test/drb/ut_array_drbssl.rb index 5938d9ff3d..778021a0b5 100644 --- a/test/drb/ut_array_drbssl.rb +++ b/test/drb/ut_array_drbssl.rb @@ -24,6 +24,10 @@ AQjjxMXhwULlmuR/K+WwlaZPiLIBYalLAZQ7ZbOPeVkJ8ePao0eLAgEC config = Hash.new config[:SSLTmpDhCallback] = proc { DRbTests::TEST_KEY_DH1024 } + if RUBY_PLATFORM.match?(/openbsd/) + config[:SSLMinVersion] = OpenSSL::SSL::TLS1_2_VERSION + config[:SSLMaxVersion] = OpenSSL::SSL::TLS1_2_VERSION + end config[:SSLVerifyMode] = OpenSSL::SSL::VERIFY_PEER config[:SSLVerifyCallback] = lambda{|ok,x509_store| true |