pub struct AccessPoint(/* private fields */);Expand description
Backend storage access point.
Implementations§
Source§impl BackendAccessPoint
impl BackendAccessPoint
Sourcepub fn wrap(access_point: AccessPoint<Error>) -> Self
pub fn wrap(access_point: AccessPoint<Error>) -> Self
Wrap an access point.
Sourcepub fn from_vault(vault: Vault) -> Self
pub fn from_vault(vault: Vault) -> Self
In-memory access point from a vault.
Sourcepub async fn new(target: BackendTarget, vault: Vault) -> Self
pub async fn new(target: BackendTarget, vault: Vault) -> Self
Access point for a folder in a backend target.
Changes are mirrored to the backend target.
Trait Implementations§
Source§impl From<BackendAccessPoint> for Vault
impl From<BackendAccessPoint> for Vault
Source§fn from(value: BackendAccessPoint) -> Self
fn from(value: BackendAccessPoint) -> Self
Converts to this type from the input type.
Source§impl SecretAccess for BackendAccessPoint
impl SecretAccess for BackendAccessPoint
Source§fn set_vault_meta<'life0, 'life1, 'async_trait>(
&'life0 mut self,
meta_data: &'life1 VaultMeta,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn set_vault_meta<'life0, 'life1, 'async_trait>(
&'life0 mut self,
meta_data: &'life1 VaultMeta,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Set the meta data for the vault.
Source§fn is_mirror(&self) -> bool
fn is_mirror(&self) -> bool
Indicates whether the access point is mirroring
changes to storage.
Source§fn replace_vault<'life0, 'async_trait>(
&'life0 mut self,
vault: Vault,
mirror_changes: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn replace_vault<'life0, 'async_trait>(
&'life0 mut self,
vault: Vault,
mirror_changes: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Replace this vault with a new updated vault. Read more
Source§fn reload_vault<'life0, 'async_trait, P>(
&'life0 mut self,
path: P,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
fn reload_vault<'life0, 'async_trait, P>( &'life0 mut self, path: P, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
Reload the vault from disc. Read more
Source§fn set_vault_name<'life0, 'async_trait>(
&'life0 mut self,
name: String,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn set_vault_name<'life0, 'async_trait>(
&'life0 mut self,
name: String,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Set the public name for the vault.
Source§fn set_vault_flags<'life0, 'async_trait>(
&'life0 mut self,
flags: VaultFlags,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn set_vault_flags<'life0, 'async_trait>(
&'life0 mut self,
flags: VaultFlags,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Set the vault flags.
Source§fn vault_meta<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<VaultMeta, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn vault_meta<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<VaultMeta, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Attempt to decrypt the meta data for the vault
using the key assigned to this access point.
Source§fn create_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
secret_data: &'life1 SecretRow,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn create_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
secret_data: &'life1 SecretRow,
) -> Pin<Box<dyn Future<Output = Result<WriteEvent, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Add a secret to the vault.
Source§fn raw_secret<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<(VaultCommit, ReadEvent)>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn raw_secret<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<(VaultCommit, ReadEvent)>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Read the encrypted contents of a secret.
Source§fn read_secret<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<(SecretMeta, Secret, ReadEvent)>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn read_secret<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<(SecretMeta, Secret, ReadEvent)>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get a secret and it’s meta data.
Source§fn update_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
id: &'life1 SecretId,
meta: SecretMeta,
secret: Secret,
) -> Pin<Box<dyn Future<Output = Result<Option<WriteEvent>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
id: &'life1 SecretId,
meta: SecretMeta,
secret: Secret,
) -> Pin<Box<dyn Future<Output = Result<Option<WriteEvent>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update a secret.
Source§fn delete_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<WriteEvent>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_secret<'life0, 'life1, 'async_trait>(
&'life0 mut self,
id: &'life1 SecretId,
) -> Pin<Box<dyn Future<Output = Result<Option<WriteEvent>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete a secret and it’s meta data.
Source§fn verify<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 AccessKey,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn verify<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 AccessKey,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Verify an encryption password.
Auto Trait Implementations§
impl Freeze for BackendAccessPoint
impl !RefUnwindSafe for BackendAccessPoint
impl Send for BackendAccessPoint
impl Sync for BackendAccessPoint
impl Unpin for BackendAccessPoint
impl !UnwindSafe for BackendAccessPoint
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more