diff options
Diffstat (limited to 'test/openssl/test_pkey_dsa.rb')
-rw-r--r-- | test/openssl/test_pkey_dsa.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/openssl/test_pkey_dsa.rb b/test/openssl/test_pkey_dsa.rb index 4bf64a51be..555637e7a4 100644 --- a/test/openssl/test_pkey_dsa.rb +++ b/test/openssl/test_pkey_dsa.rb @@ -218,6 +218,15 @@ YNMbNw== assert_equal([], OpenSSL.errors) end + def test_export_password_length + key = OpenSSL::TestUtils::TEST_KEY_DSA256 + assert_raise(OpenSSL::OpenSSLError) do + key.export(OpenSSL::Cipher.new('AES-128-CBC'), 'sec') + end + pem = key.export(OpenSSL::Cipher.new('AES-128-CBC'), 'secr') + assert(pem) + end + private def check_sign_verify(digest) |