class Nanvault::Plaintext
- Nanvault::Plaintext
- Reference
- Object
Overview
Plaintext data class
Defined in:
nanvault.crConstant Summary
-
HMAC_ALG =
OpenSSL::Algorithm::SHA256
-
SALT_LEN =
32
-
salt length
Constructors
Instance Method Summary
- #ctext : Slice(UInt8)
- #ctext=(ctext : Slice(UInt8))
-
#encrypt
encrypt method - also generates safe salt
-
#encrypt_unsafe
internal encrypt method - does NOT generate salt NOTE: YOU SHOULD NOT USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING
-
#encrypted_str
encrypted string method
- #hmac : Slice(UInt8)
- #hmac=(hmac : Slice(UInt8))
-
#label : String
these initializations also prevent this: https://github.com/crystal-lang/crystal/issues/5931
-
#label=(label : String)
these initializations also prevent this: https://github.com/crystal-lang/crystal/issues/5931
- #password=(password : String)
- #ptext : Slice(UInt8)
- #ptext=(ptext : Slice(UInt8))
- #salt : Slice(UInt8)
- #salt=(salt : Slice(UInt8))
Constructor Detail
Instance Method Detail
def encrypt_unsafe
#
internal encrypt method - does NOT generate salt
NOTE YOU SHOULD NOT USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING
def label : String
#
these initializations also prevent this: https://github.com/crystal-lang/crystal/issues/5931
def label=(label : String)
#
these initializations also prevent this: https://github.com/crystal-lang/crystal/issues/5931