Question
Password validation using def Create a password validator program. Ask the user to 'Enter a new password:' then validates against complexity requirements. If not met
Password validation using def
Create a password validator program. Ask the user to
'Enter a new password:'
then validates against complexity requirements. If not met the requirements, display
'Your password does not meet complexity requirements!'
otherwise ask the user to
'Please re-enter the same password:'
If the passwords match, display
'Password is valid and two entries are matching'
If the passwords don't match then display
'Passwords do not match!'
In case of an error, the program shall go back to the beginning and ask the user to enter the password, validate it, and then re-enter the same password.
Your program should include validatePassword(password) that checks whether a password is valid.
Password complexity requirements --->
The password must be at least 8 characters long.
The password must have at least one uppercase, one lowercase letter, and at least one digit.
The password must not included any special characters.
The maximum attempts shall be 3 times.
If the user fails to provide a valid password, then display:
'You have not provided a valid password, goodbye!'
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started