/password_validator

A password validator module for python apps(web, desktop and cmd)

Primary LanguagePythonApache License 2.0Apache-2.0

Password_validator

A password validator package for python apps(web, desktop and cmd).

Requirements Before you continue, ensure you have met the following requirements:

  • You have python3 installed

Getting started

from validator import (
    password_is_common, username_in_password, contains_alphanumeric_and_symbols, confirm_password,
    is_minimum_length,
)
validate = Validator(username, password)

Check if password is common

validator.password_is_common()

Check if password is similar to username

validator.username_in_password()

Check if password is up to the required minimum length

validator.is_minimum_length(length)
where length is the minimum length of your choice

Check if password contains letters, numbers and symbols

validator.contains_alphanumeric_and_symbols()

Check if password and confirm password are the same

validator.confirm_password(password2)
where password2 is the second password