Class: EncryptedStrings::SymmetricCipher

Inherits:
Object
  • Object
show all
Defined in:
lib/streetcreds/patches/openssl_cipher_patch.rb

Instance Method Summary collapse

Instance Method Details

#build_cipher(type) ⇒ Object

:nodoc:



6
7
8
9
10
# File 'lib/streetcreds/patches/openssl_cipher_patch.rb', line 6

def build_cipher(type) #:nodoc:
  cipher = OpenSSL::Cipher.new(algorithm).send(type)
  cipher.pkcs5_keyivgen(password)
  cipher
end