def new_cipher(direction, password, salt)
      cipher = OpenSSL::Cipher::Cipher.new(CIPHER_TYPE)
      direction == :encrypt ? cipher.encrypt : cipher.decrypt
      cipher.key = encrypt_key(password, salt)
      cipher
    end
def new_cipher(direction, password, salt)
      cipher = OpenSSL::Cipher::Cipher.new(CIPHER_TYPE)
      direction == :encrypt ? cipher.encrypt : cipher.decrypt
      cipher.key = encrypt_key(password, salt)
      cipher
    end
A T T E N Z I O N E   A R E A   P R O T E T T A
 Create a new cipher machine, with its dials set in the given direction.

 @param [Symbol] direction
   Whether to `:encrypt` or `:decrypt`.

 @param [String] pass
   Secret passphrase to decrypt with.

 @api private