Skip to main content

Vault

Trait Vault 

Source
pub trait Vault {
    // Required methods
    fn state(&self) -> VaultState;
    fn lock(&mut self) -> SecurityResult<()>;
    fn unlock(&mut self, key_material: &[u8]) -> SecurityResult<()>;
}
Expand description

Minimal vault contract. This is not a remote vault protocol.

Required Methods§

Source

fn state(&self) -> VaultState

Returns the current vault state.

Source

fn lock(&mut self) -> SecurityResult<()>

Removes access to secret material.

Source

fn unlock(&mut self, key_material: &[u8]) -> SecurityResult<()>

Unlocks the vault using deployment-supplied key material.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§