Skip to main content

resolve_key_for_vault

Function resolve_key_for_vault 

Source
pub fn resolve_key_for_vault(vault_path: &str) -> Result<SecretString, String>
Expand description

Resolve the secret key for a specific vault, checking in order:

  1. MURK_KEY env var (explicit key)
  2. MURK_KEY_FILE env var (path to key file)
  3. ~/.config/murk/keys/<vault-hash> (automatic lookup keyed to the given vault path)
  4. .env file in cwd (backward compat)