Hello all!
I have to produce a regular expression whichs validates a password against the following:
My best attempt is:
(\b(?=\w{8,12}\b)(?=(\w)(?!=\1\1))[a-zA-Z]\w*
but it doesnt work in all situations... the real problem is the two consecutive chars... Is there a way to make a look ahead only apply to the result from a previous look ahead - or does that just give (internally) a true or false and either proceeds or skips?
Thanks in advance
I have to produce a regular expression whichs validates a password against the following:
- 8 to 12 character long
- Can’t start with a digit
- No more then two consecutive characters can be identical.
- Alpha Numeric only.
My best attempt is:
(\b(?=\w{8,12}\b)(?=(\w)(?!=\1\1))[a-zA-Z]\w*
but it doesnt work in all situations... the real problem is the two consecutive chars... Is there a way to make a look ahead only apply to the result from a previous look ahead - or does that just give (internally) a true or false and either proceeds or skips?
Thanks in advance
