Tagged Fiddles
- 1RevisionsForks
Require at least one letter, number and a special character
/^(?=.*\d)(?=.*\w)(?=.*\W).{8,}$/gimUsed to enforce that a password (in our case) contains at least one letter (a-zA-Z), one number and one special character and is at least 8 chars long, in any order.#- Don't match these failtest 123456789 "!#%€#"&"%€/ @#a23 #+ Match these l3agal#12332 l#eg1a11 123abc@#$ @#$abc123 @#$ABc123 @#$123abc !gre$veor%.32 - 1Revisions1Forks
Require at least one letter and number
/[a-z].*\d|\d.*[a-z]/giUsed to enforce that a password (in our case) contains at least one letter (a-z) and one number, in any order.#- Don't match these failtest 123456789 "!#%€#"&"%€/ #+ Match these l3agal lega1 1a 1€%b b€%&/a1