Need some help for regular expression for password. Here is the matches:
- It should be at least 8 characters in length and the maximum length is 20 characters.
- Password MUST include at least 1 UPPERCASE alphabetic character, 1 LOWERCASE alphabetic character, 1 numeric character and 1 symbols ( @ # $ % ^ & ( ) _ + | ~ - = ` { } [ ] : ; < > ? , . /).
- The symbols that are NOT allowed are \ (back slash) or "(quotes).
It is quite difficult for me, I have limited experience in writing regular expressions.
I have this regexp but I don't see any way to deprecate \ and ". Added (?=.*?["\\])
but it doesn't work.
Here is my regular
^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-_()]).{8,20}$