pub struct PasswordMethod { /* private fields */ }Expand description
Password-based authentication method.
Implementations§
Source§impl PasswordMethod
impl PasswordMethod
Sourcepub fn new(
password_verifier: Box<dyn PasswordVerifier>,
user_lookup: Box<dyn UserLookup>,
token_manager: TokenManager,
) -> Self
pub fn new( password_verifier: Box<dyn PasswordVerifier>, user_lookup: Box<dyn UserLookup>, token_manager: TokenManager, ) -> Self
Create a new password authentication method.
Trait Implementations§
Source§impl AuthMethod for PasswordMethod
impl AuthMethod for PasswordMethod
Source§fn authenticate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
credential: &'life1 Credential,
_metadata: &'life2 CredentialMetadata,
) -> Pin<Box<dyn Future<Output = Result<MethodResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn authenticate<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
credential: &'life1 Credential,
_metadata: &'life2 CredentialMetadata,
) -> Pin<Box<dyn Future<Output = Result<MethodResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Authenticate using the provided credentials.
Source§fn validate_config(&self) -> Result<()>
fn validate_config(&self) -> Result<()>
Validate configuration for this method.
Source§fn supports_refresh(&self) -> bool
fn supports_refresh(&self) -> bool
Check if this method supports refresh tokens.
Auto Trait Implementations§
impl Freeze for PasswordMethod
impl !RefUnwindSafe for PasswordMethod
impl Send for PasswordMethod
impl Sync for PasswordMethod
impl Unpin for PasswordMethod
impl !UnwindSafe for PasswordMethod
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