pub struct TwoFactorLoginPayload { /* private fields */ }Expand description
Validated token and code for completing a two-factor login.
Its custom fmt::Debug implementation redacts the token and code.
Implementations§
Source§impl TwoFactorLoginPayload
impl TwoFactorLoginPayload
Sourcepub fn parse(form: TwoFactorLoginForm) -> Result<Self, ParseError>
pub fn parse(form: TwoFactorLoginForm) -> Result<Self, ParseError>
Validates a raw two-factor login form.
Sourcepub fn token(&self) -> &TwoFactorToken
pub fn token(&self) -> &TwoFactorToken
Returns the validated pending-challenge token.
Sourcepub fn code(&self) -> &TwoFactorCode
pub fn code(&self) -> &TwoFactorCode
Returns the validated second-factor code.
Trait Implementations§
Source§impl Clone for TwoFactorLoginPayload
impl Clone for TwoFactorLoginPayload
Source§impl Debug for TwoFactorLoginPayload
impl Debug for TwoFactorLoginPayload
impl Eq for TwoFactorLoginPayload
Source§impl PartialEq for TwoFactorLoginPayload
impl PartialEq for TwoFactorLoginPayload
impl StructuralPartialEq for TwoFactorLoginPayload
Auto Trait Implementations§
impl Freeze for TwoFactorLoginPayload
impl RefUnwindSafe for TwoFactorLoginPayload
impl Send for TwoFactorLoginPayload
impl Sync for TwoFactorLoginPayload
impl Unpin for TwoFactorLoginPayload
impl UnsafeUnpin for TwoFactorLoginPayload
impl UnwindSafe for TwoFactorLoginPayload
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