pub struct SqliteCredentialStore { /* private fields */ }Expand description
Per-(upstream_name, subject) credential store backed by SQLite.
Tokens are encrypted at rest with ChaCha20-Poly1305. Decryption failure
surfaces as AuthError::AuthorizationRequired so callers re-initiate the
authorization flow rather than hard-failing.
Implementations§
Source§impl SqliteCredentialStore
impl SqliteCredentialStore
pub fn new( store: SqliteStore, key: EncryptionKey, upstream_name: impl Into<String>, subject: impl Into<String>, ) -> Self
Trait Implementations§
Source§impl CredentialStore for SqliteCredentialStore
impl CredentialStore for SqliteCredentialStore
fn load<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<StoredCredentials>, AuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn save<'life0, 'async_trait>(
&'life0 self,
credentials: StoredCredentials,
) -> Pin<Box<dyn Future<Output = Result<(), AuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn clear<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), AuthError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl Freeze for SqliteCredentialStore
impl RefUnwindSafe for SqliteCredentialStore
impl Send for SqliteCredentialStore
impl Sync for SqliteCredentialStore
impl Unpin for SqliteCredentialStore
impl UnsafeUnpin for SqliteCredentialStore
impl UnwindSafe for SqliteCredentialStore
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