Skip to main content

cache_pubkey

Function cache_pubkey 

Source
pub fn cache_pubkey(alias: &str, pubkey: &[u8], curve: CurveType) -> Result<()>
Expand description

Cache a public key for the given alias.

The public key is stored in ~/.auths/pubkeys/<alias>.pub as <curve>:<hex>, e.g. ed25519:abcdef... or p256:02abcdef....

Args:

  • alias - The key alias (e.g., “default”).
  • pubkey - Raw public key bytes.
  • curve - The curve type of the key.