ruby-changes:33201
From: emboss <ko1@a...>
Date: Fri, 7 Mar 2014 12:15:44 +0900 (JST)
Subject: [ruby-changes:33201] emboss:r45280 (trunk): * test/openssl/test_ssl.rb: Reuse TLS default options from
emboss 2014-03-07 12:15:39 +0900 (Fri, 07 Mar 2014) New Revision: 45280 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=45280 Log: * test/openssl/test_ssl.rb: Reuse TLS default options from OpenSSL::SSL::SSLContext::DEFAULT_PARAMS. Modified files: trunk/ChangeLog trunk/test/openssl/test_ssl.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 45279) +++ ChangeLog (revision 45280) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Fri Mar 7 12:06:19 2014 Martin Bosslet <Martin.Bosslet@g...> + + * test/openssl/test_ssl.rb: Reuse TLS default options from + OpenSSL::SSL::SSLContext::DEFAULT_PARAMS. + Thu Mar 6 15:15:24 2014 Zachary Scott <e@z...> * doc/syntax/assignment.rdoc: [DOC] Fix assignment directions Index: test/openssl/test_ssl.rb =================================================================== --- test/openssl/test_ssl.rb (revision 45279) +++ test/openssl/test_ssl.rb (revision 45280) @@ -4,14 +4,6 @@ if defined?(OpenSSL) https://github.com/ruby/ruby/blob/trunk/test/openssl/test_ssl.rb#L4 class OpenSSL::TestSSL < OpenSSL::SSLTestCase - TLS_DEFAULT_OPS = -> { - opts = OpenSSL::SSL::OP_ALL - opts &= ~OpenSSL::SSL::OP_DONT_INSERT_EMPTY_FRAGMENTS if defined?(OpenSSL::SSL::OP_DONT_INSERT_EMPTY_FRAGMENTS) - opts |= OpenSSL::SSL::OP_NO_COMPRESSION if defined?(OpenSSL::SSL::OP_NO_COMPRESSION) - opts |= OpenSSL::SSL::OP_NO_SSLv2 if defined?(OpenSSL::SSL::OP_NO_SSLv2) - opts |= OpenSSL::SSL::OP_NO_SSLv3 if defined?(OpenSSL::SSL::OP_NO_SSLv3) - }.call - def test_ctx_setup ctx = OpenSSL::SSL::SSLContext.new assert_equal(ctx.setup, true) @@ -298,7 +290,7 @@ class OpenSSL::TestSSL < OpenSSL::SSLTes https://github.com/ruby/ruby/blob/trunk/test/openssl/test_ssl.rb#L290 ctx = OpenSSL::SSL::SSLContext.new ctx.set_params assert_equal(OpenSSL::SSL::VERIFY_PEER, ctx.verify_mode) - assert_equal(TLS_DEFAULT_OPS, ctx.options) + assert_equal(OpenSSL::SSL::SSLContext::DEFAULT_PARAMS[:options], ctx.options) ciphers = ctx.ciphers ciphers_versions = ciphers.collect{|_, v, _, _| v } ciphers_names = ciphers.collect{|v, _, _, _| v } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/