aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKazuki Yamaguchi <k@rhe.jp>2016-04-12 23:25:48 +0900
committerKazuki Yamaguchi <k@rhe.jp>2016-04-21 00:46:34 +0900
commite0fb1f9694b2b71b6c84fa893835d73940bcfe14 (patch)
treed91b35b84670dabfef4468b3f205cf21ca49b749
parentb2376b15a010919cbe4d4810884376b953b093f4 (diff)
downloadruby-e0fb1f9694b2b71b6c84fa893835d73940bcfe14.tar.gz
unyaa
-rw-r--r--test/openssl/test_pair.rb4
-rw-r--r--test/openssl/test_pkey_dh.rb2
2 files changed, 3 insertions, 3 deletions
diff --git a/test/openssl/test_pair.rb b/test/openssl/test_pair.rb
index bb0bf98b95..60ec1ed451 100644
--- a/test/openssl/test_pair.rb
+++ b/test/openssl/test_pair.rb
@@ -337,7 +337,7 @@ module OpenSSL::TestPairM
ctx1 = OpenSSL::SSL::SSLContext.new
ctx1.ciphers = "DH"
- ctx2.security_level = 0
+ ctx1.security_level = 0
ctx1.tmp_dh_callback = nil
s1 = OpenSSL::SSL::SSLSocket.new(sock1, ctx1)
t = Thread.new { s1.connect }
@@ -384,6 +384,7 @@ module OpenSSL::TestPairM
called = false
ctx2 = OpenSSL::SSL::SSLContext.new
ctx2.ciphers = "ECDH"
+ ctx2.security_level = 0
ctx2.tmp_ecdh_callback = ->(*args) {
called = true
OpenSSL::PKey::EC.new "prime256v1"
@@ -394,6 +395,7 @@ module OpenSSL::TestPairM
s2 = OpenSSL::SSL::SSLSocket.new(sock2, ctx2)
ctx1 = OpenSSL::SSL::SSLContext.new
ctx1.ciphers = "ECDH"
+ ctx1.security_level = 0
s1 = OpenSSL::SSL::SSLSocket.new(sock1, ctx1)
th = Thread.new do
diff --git a/test/openssl/test_pkey_dh.rb b/test/openssl/test_pkey_dh.rb
index f2b6484b47..a0eca53c48 100644
--- a/test/openssl/test_pkey_dh.rb
+++ b/test/openssl/test_pkey_dh.rb
@@ -78,8 +78,6 @@ YoaOffgTf5qxiwkjnlVZQc3whgnEt9FpVMvQ9eknyeGB5KHfayAc3+hUAvI3/Cr3
def test_key_exchange
dh = OpenSSL::TestUtils::TEST_KEY_DH1024
dh2 = dh.public_key
- p dh.pub_key
- p dh.priv_key
dh.generate_key!
dh2.generate_key!
assert_equal(dh.compute_key(dh2.pub_key), dh2.compute_key(dh.pub_key))