Skip to main content

Vault

Trait Vault 

Source
pub trait Vault: Binding {
    // Required methods
    fn get_secret<'life0, 'life1, 'async_trait>(
        &'life0 self,
        secret_name: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<String, AlienError<ErrorData>>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
    fn set_secret<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        secret_name: &'life1 str,
        value: &'life2 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), AlienError<ErrorData>>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             Self: 'async_trait;
    fn delete_secret<'life0, 'life1, 'async_trait>(
        &'life0 self,
        secret_name: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<(), AlienError<ErrorData>>> + Send + 'async_trait>>
       where 'life0: 'async_trait,
             'life1: 'async_trait,
             Self: 'async_trait;
}
Expand description

A trait for vault bindings that provide secure secret management.

Required Methods§

Source

fn get_secret<'life0, 'life1, 'async_trait>( &'life0 self, secret_name: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<String, AlienError<ErrorData>>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Gets a secret value by name.

Source

fn set_secret<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, secret_name: &'life1 str, value: &'life2 str, ) -> Pin<Box<dyn Future<Output = Result<(), AlienError<ErrorData>>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, Self: 'async_trait,

Sets a secret value, creating it if it doesn’t exist or updating it if it does.

Source

fn delete_secret<'life0, 'life1, 'async_trait>( &'life0 self, secret_name: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<(), AlienError<ErrorData>>> + Send + 'async_trait>>
where 'life0: 'async_trait, 'life1: 'async_trait, Self: 'async_trait,

Deletes a secret by name.

Implementors§