View Source Age.X25519 (age v0.1.0)
Internal helper functions for the X25519 identity format.
Link to this section Summary
Functions
Decodes the private key from a Bech32 string of format AGE-SECRET-KEY-1...
Decodes the public key from a Bech32 string of format age1...
X25519(secret, base) to derive a public key from a private key.
Helper function to derive the wrap key for the file key.
Encodes the private key as a Bech32 string of format AGE-SECRET-KEY-1...
Encodes the public key as a Bech32 string of format age1...
Generates a new public/private keypair.
Generates the stanza for file encryption from the given recipient and file key.
Link to this section Types
Link to this section Functions
@spec decode_private_key(binary()) :: private_key()
Decodes the private key from a Bech32 string of format AGE-SECRET-KEY-1...
@spec decode_public_key(binary()) :: public_key()
Decodes the public key from a Bech32 string of format age1...
@spec derive_public_key(private_key()) :: public_key()
X25519(secret, base) to derive a public key from a private key.
@spec derive_wrap_key(binary(), binary(), public_key()) :: binary()
Helper function to derive the wrap key for the file key.
@spec encode_private_key(private_key()) :: binary()
Encodes the private key as a Bech32 string of format AGE-SECRET-KEY-1...
@spec encode_public_key(public_key()) :: binary()
Encodes the public key as a Bech32 string of format age1...
@spec generate_keypair() :: {public_key(), private_key()}
Generates a new public/private keypair.
@spec stanza(public_key(), binary()) :: {binary(), binary()}
Generates the stanza for file encryption from the given recipient and file key.