Class: Klay::Key::Decrypter
- Inherits:
-
Object
- Object
- Klay::Key::Decrypter
- Defined in:
- lib/klay/key/decrypter.rb
Overview
The Decrypter class to handle PBKDF2-SHA-256 decryption.
Defined Under Namespace
Classes: DecrypterError
Class Method Summary collapse
-
.perform(data, password) ⇒ Klay::Key
Class method Decrypter.perform to perform an keystore decryption.
Instance Method Summary collapse
-
#initialize(data, password) ⇒ Decrypter
constructor
Constructor of the Decrypter class for secret key decryption.
-
#perform ⇒ Klay::Key
Method to decrypt key using password.
Constructor Details
#initialize(data, password) ⇒ Decrypter
Constructor of the Klay::Key::Decrypter class for secret key decryption. Should not be used; use perform instead.
40 41 42 43 44 |
# File 'lib/klay/key/decrypter.rb', line 40 def initialize(data, password) data = JSON.parse(data) if data.is_a? String @data = data @password = password end |