summaryrefslogtreecommitdiff
path: root/sample/openssl
diff options
context:
space:
mode:
Diffstat (limited to 'sample/openssl')
-rw-r--r--sample/openssl/cipher.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/sample/openssl/cipher.rb b/sample/openssl/cipher.rb
index 58b10d6046..a33dc3e95c 100644
--- a/sample/openssl/cipher.rb
+++ b/sample/openssl/cipher.rb
@@ -10,7 +10,7 @@ def crypt_by_password(alg, pass, salt, text)
puts
puts "--Encrypting--"
- enc = OpenSSL::Cipher::Cipher.new(alg)
+ enc = OpenSSL::Cipher.new(alg)
enc.encrypt
enc.pkcs5_keyivgen(pass, salt)
cipher = enc.update(text)
@@ -19,7 +19,7 @@ def crypt_by_password(alg, pass, salt, text)
puts
puts "--Decrypting--"
- dec = OpenSSL::Cipher::Cipher.new(alg)
+ dec = OpenSSL::Cipher.new(alg)
dec.decrypt
dec.pkcs5_keyivgen(pass, salt)
plain = dec.update(cipher)