Im using laravel and I want to allow password that must have atleast 1 from each of the following categories:
- a-z or A-Z (alphabets)
- 0-9 (digits)
- Special symbol (!@#$ ......) (All symbols just like google)
Can someone give a regex expression for this as I dont know how regex works.
I have tried this:
^.*(?=.{3,})(?=.*[a-zA-Z])(?=.*[0-9])(?=.*[\d\X])(?=.*[`~!@#$%^&*()-_=+[]{}|;:",<.>\/?]).*$
But i dont understand what (?=.{3,})
does and also its not working as I would expect
I will test the expression on https://regex101.com/. So I hope you test it there first before posting the answer.