Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultPassphraseBytes is the number of random bytes for passphrase generation. // 32 bytes = 256 bits of entropy, encoded as ~43 base64 characters. DefaultPassphraseBytes = 32 )
Variables ¶
This section is empty.
Functions ¶
func GeneratePassphrase ¶
GeneratePassphrase creates a cryptographically secure passphrase. The passphrase is URL-safe base64 encoded (no padding) for easy handling.
func GenerateRawPassphrase ¶ added in v0.0.8
GenerateRawPassphrase creates random bytes and returns both the raw bytes and the base64url-encoded passphrase string. Protocol v2 splits the raw bytes via Shamir (instead of the encoded string), then base64url-encodes after recombining. The passphrase string is used for age encryption.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.