diff options
author | Kazuki Yamaguchi <k@rhe.jp> | 2016-08-14 18:01:43 +0900 |
---|---|---|
committer | Kazuki Yamaguchi <k@rhe.jp> | 2016-08-16 14:22:08 +0900 |
commit | 37c4db438dfa6b243abbae23177f3e59a68b30bb (patch) | |
tree | c0f2d068a4fcd6ddf57f00acac432bd1293e785f /test | |
parent | b47d95f01aa2e941dd4454674ab28f387e9ceab9 (diff) | |
download | ruby-openssl-37c4db438dfa6b243abbae23177f3e59a68b30bb.tar.gz |
test/test_pkey_rsa: remove memory leak regression testtopic/memory-leaks
It takes some time. Memory leaks should be now caught by running
`MDEBUG=1 rake test`. So just remove it.
Diffstat (limited to 'test')
-rw-r--r-- | test/test_pkey_rsa.rb | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/test/test_pkey_rsa.rb b/test/test_pkey_rsa.rb index c062a6a4..c512c3e3 100644 --- a/test/test_pkey_rsa.rb +++ b/test/test_pkey_rsa.rb @@ -76,36 +76,6 @@ class OpenSSL::TestPKeyRSA < OpenSSL::TestCase assert(key.verify(digest, sig, data)) end - def test_sign_verify_memory_leak - bug9743 = '[ruby-core:62038] [Bug #9743]' - assert_no_memory_leak(%w[-ropenssl], <<-PREP, <<-CODE, bug9743, rss: true, timeout: 30) - data = 'Sign me!' - digest = OpenSSL::Digest::SHA512.new - pkey = OpenSSL::PKey::RSA.new(2048) - signature = pkey.sign(digest, data) - pub_key = pkey.public_key - PREP - 20_000.times { - pub_key.verify(digest, signature, data) - } - CODE - - assert_no_memory_leak(%w[-ropenssl], <<-PREP, <<-CODE, bug9743, rss: true, timeout: 30) - data = 'Sign me!' - digest = OpenSSL::Digest::SHA512.new - pkey = OpenSSL::PKey::RSA.new(2048) - signature = pkey.sign(digest, data) - pub_key = pkey.public_key - PREP - 20_000.times { - begin - pub_key.verify(digest, signature, 1) - rescue TypeError - end - } - CODE - end - def test_digest_state_irrelevant_sign key = OpenSSL::TestUtils::TEST_KEY_RSA1024 digest1 = OpenSSL::Digest::SHA1.new |