pub trait PrimaryPasswordAuthenticator: Send + Sync {
// Required methods
fn get_primary_password<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = ApiResult<String>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn on_authentication_success(&self);
fn on_authentication_failure(&self);
}
Expand description
PrimaryPasswordAuthenticator
is used in conjunction with NSSKeyManager
to provide the
primary password and the success or failure actions of the authentication process.
Required Methods§
Sourcefn get_primary_password<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = ApiResult<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_primary_password<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = ApiResult<String>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get a primary password for authentication, otherwise return the AuthenticationCancelled error to cancel the authentication process.