Module: PasswordSafe::Encryptor
Instance Method Summary collapse
Instance Method Details
#decrypt(data, pwhash) ⇒ Object
6 7 8 |
# File 'lib/passwordsafe/encryptor.rb', line 6 def decrypt(data, pwhash) crypt :decrypt, data, pwhash end |
#encrypt(data, pwhash) ⇒ Object
10 11 12 |
# File 'lib/passwordsafe/encryptor.rb', line 10 def encrypt(data, pwhash) crypt :encrypt, data, pwhash end |
#hash(plain) ⇒ Object
14 15 16 |
# File 'lib/passwordsafe/encryptor.rb', line 14 def hash (plain) Digest::SHA512.digest(plain) end |