aboutsummaryrefslogtreecommitdiffstats
path: root/sample
diff options
context:
space:
mode:
authorKazuki Yamaguchi <k@rhe.jp>2016-05-31 11:06:09 +0900
committerKazuki Yamaguchi <k@rhe.jp>2016-07-09 22:48:34 +0900
commit5c20a4c014845b7e14860b594b634195697d456d (patch)
tree36a8928c8ad9281dc457d06b1fcf0d597346e941 /sample
parent1bba3f29f4d2859201f5acf55197fe6876362771 (diff)
downloadruby-openssl-5c20a4c014845b7e14860b594b634195697d456d.tar.gz
Deprecate constant OpenSSL::Digest::Digest and OpenSSL::Cipher::Cipher
Mark OpenSSL::{Digest::Digest,Cipher::Cipher} as deprecated using Module#deprecate_constant. They have been deprecated for years in the documentation.
Diffstat (limited to 'sample')
-rw-r--r--sample/cipher.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/sample/cipher.rb b/sample/cipher.rb
index 58b10d60..a33dc3e9 100644
--- a/sample/cipher.rb
+++ b/sample/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)