summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authornagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-31 18:55:07 +0000
committernagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-31 18:55:07 +0000
commita8b1b529f1042c8bf71ce2855147d92305c204f7 (patch)
treeab197e1484267bc949dad742a5acdb9d311ec441 /test
parenta5a5494d25c6b7a0662a73b27bf1ab88fbbb42d0 (diff)
merge revision(s) 51569,51649: [Backport #11366] [Backport #11367]
test_ssl_session.rb: check SSL method * test/openssl/test_ssl_session.rb (test_ctx_server_session_cb): ensure the method to be tested is supported. * test/openssl/test_ssl_session.rb: Fix tests so that they take in to account OpenSSL installations that have SSLv3 disabled by default. Thanks Jeremy Evans <code@jeremyevans.net> for the patches. [Bug #11366] [Bug #11367] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@52414 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/openssl/test_ssl_session.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/openssl/test_ssl_session.rb b/test/openssl/test_ssl_session.rb
index 16432bcbb0..477771fe1d 100644
--- a/test/openssl/test_ssl_session.rb
+++ b/test/openssl/test_ssl_session.rb
@@ -316,6 +316,7 @@ __EOS__
ctx_proc = Proc.new { |ctx, ssl|
ctx.session_cache_mode = OpenSSL::SSL::SSLContext::SESSION_CACHE_SERVER
+ ctx.options = OpenSSL::SSL::OP_NO_TICKET
last_server_session = nil
# get_cb is called whenever a client proposed to resume a session but
@@ -355,7 +356,7 @@ __EOS__
3.times do
sock = TCPSocket.new("127.0.0.1", port)
begin
- ssl = OpenSSL::SSL::SSLSocket.new(sock, OpenSSL::SSL::SSLContext.new("SSLv3"))
+ ssl = OpenSSL::SSL::SSLSocket.new(sock, OpenSSL::SSL::SSLContext.new())
ssl.sync_close = true
ssl.session = last_client_session if last_client_session
ssl.connect