Method: CcipherBox::Keybox#initialize
- Defined in:
- lib/ccipher_box/keybox.rb
#initialize(kdfEngine = nil) ⇒ Keybox
Returns a new instance of Keybox.
14 15 16 17 18 19 20 21 22 |
# File 'lib/ccipher_box/keybox.rb', line 14 def initialize(kdfEngine = nil) raise KeyboxException, "Instance of KDF engine (CcipherFactory::KDF::KDFEngine) required" if not_empty?(kdfEngine) and not kdfEngine.is_a?(CcipherFactory::KDF::KDFEngine) @kdfEng = kdfEngine if not @kdfEng.nil? @kdfOut = MemBuf.new @kdfEng.output(@kdfOut) end end |