Documentation
¶
Overview ¶
Package crypto provides cryptographic helpers used by stackkit for password generation, hashing, and bundle encryption.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecryptWithPassphrase ¶
DecryptWithPassphrase decrypts age-encrypted ciphertext using the given passphrase.
func EncryptWithPassphrase ¶
EncryptWithPassphrase encrypts plaintext using age with a scrypt-passphrase recipient.
func HashPassphrase ¶
HashPassphrase returns a PHC-formatted argon2id hash of pass.
func RandomPassword ¶
RandomPassword returns a base64-encoded random password derived from `byteLen` random bytes. byteLen must be at least 16.
func VerifyPassphrase ¶
VerifyPassphrase returns true iff pass matches encoded. Constant-time comparison.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.