Skip to content

Commit

Permalink
Merge pull request #3 from jeremyevans/libressl-session-reuse
Browse files Browse the repository at this point in the history
Fix SSL session reuse test with LibreSSL 3.2+
  • Loading branch information
hsbt committed Jul 31, 2020
2 parents 6eda06d + 5ae9620 commit 54f353c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/net/http/test_https.rb
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,14 @@ def test_session_reuse
http.use_ssl = true
http.cert_store = TEST_STORE

if OpenSSL::OPENSSL_LIBRARY_VERSION =~ /LibreSSL (\d+\.\d+)/ && $1.to_f > 3.19
# LibreSSL 3.2 defaults to TLSv1.3 in server and client, which doesn't currently
# support session resuse. Limiting the version to the TLSv1.2 stack allows
# this test to continue to work on LibreSSL 3.2+. LibreSSL may eventually
# support session reuse, but there are no current plans to do so.
http.ssl_version = :TLSv1
end

http.start
http.get("/")
http.finish
Expand Down

0 comments on commit 54f353c

Please sign in to comment.