You know these Create a new password forms? They do a lot of checks to make sure you make a password that is hard to guess and you will surely forget.
In this Bite you will write a validator for such a form field.
validate_passwordfunction below. It takes a password
strand validates that it:
- is between 6 and 12 chars long (both inclusive)
- has at least 1 digit [0-9]
- has at least two lowercase chars [a-z]
- has at least one uppercase char [A-Z]
- has at least one punctuation char (use:
- Has not been used before (use:
If the password matches all criteria the function should store the password in
Have fun, keep calm and code in Python!