Function passablewords::check_uniqueness
[−]
[src]
pub fn check_uniqueness(password: &str) -> PassablewordResult
Check a password to make sure it's not within the top million most common passwords.
Example (using rocket.rs)
match check_uniqueness(password) { Ok() => status::Ok Err(err) => match(err) { PassablewordResult::TooCommon => status::BadRequest("Your should be more unique") } }