pub struct CredentialValidator {
pub validate_username: fn(&str) -> Result<(), AuthError>,
pub validate_password: fn(&str) -> Result<(), AuthError>,
}
Expand description
Credential validator which is used in UserService
to validate AuthUser
Fields§
§validate_username: fn(&str) -> Result<(), AuthError>
Validates if username meets the minimum requirements
validate_password: fn(&str) -> Result<(), AuthError>
Validates if password meets the minimum requirements
Auto Trait Implementations§
impl Freeze for CredentialValidator
impl RefUnwindSafe for CredentialValidator
impl Send for CredentialValidator
impl Sync for CredentialValidator
impl Unpin for CredentialValidator
impl UnwindSafe for CredentialValidator
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