Foros de discusión
Change the password policy - Regular Expression in Liferay
Kha N Nguyen, modificado hace 14 años.
Change the password policy - Regular Expression in Liferay
Junior Member Mensajes: 89 Fecha de incorporación: 22/11/09 Mensajes recientes
I want to change password policy as following:
I set the property in the portal-ext.property as following, but this pattern does not work:
passwords.regexptoolkit.pattern=(?=.{8,24})((?:[a-z]*)(?:[0-9]*)(?:[A-Z]*)(?:[`~!@#$%^&*()|\\:;"'<,>.?/=+-]*))
Can one help me please?
Thanks a lot.
- Passwords will contain at least (1) upper case letter
- Passwords will contain at least (1) lower case letter
- Passwords will contain at least (1) number
- Passwords will contain at least (1) special character
- Passwords will contain at least (8) characters in length
- Password maximum length is 24
I set the property in the portal-ext.property as following, but this pattern does not work:
passwords.regexptoolkit.pattern=(?=.{8,24})((?:[a-z]*)(?:[0-9]*)(?:[A-Z]*)(?:[`~!@#$%^&*()|\\:;"'<,>.?/=+-]*))
Can one help me please?
Thanks a lot.
Kha N Nguyen, modificado hace 14 años.
RE: Change the password policy - Regular Expression in Liferay
Junior Member Mensajes: 89 Fecha de incorporación: 22/11/09 Mensajes recientesKha N Nguyen:
I want to change password policy as following:
- Passwords will contain at least (1) upper case letter
- Passwords will contain at least (1) lower case letter
- Passwords will contain at least (1) number
- Passwords will contain at least (1) special character
- Passwords will contain at least (8) characters in length
- Password maximum length is 24
I set the property in the portal-ext.property as following, but this pattern does not work:
passwords.regexptoolkit.pattern=(?=.{8,24})((?:[a-z]*)(?:[0-9]*)(?:[A-Z]*)(?:[`~!@#$%^&*()|\\:;"'<,>.?/=+-]*))
Can one help me please?
Thanks a lot.
I have resolved it.
Ayaz Pasha, modificado hace 14 años.
RE: Change the password policy - Regular Expression in Liferay
Junior Member Mensajes: 78 Fecha de incorporación: 1/08/08 Mensajes recientes
Hello,
I have the similar issue can you please let me know how you resolved it?
Thanks
Ayaz
I have the similar issue can you please let me know how you resolved it?
Thanks
Ayaz
Sipin Verma, modificado hace 11 años.
RE: Change the password policy - Regular Expression in Liferay
Junior Member Mensajes: 29 Fecha de incorporación: 14/12/10 Mensajes recientes
Add/customize below 2 properties in your portal-ext.properties:
passwords.toolkit=com.liferay.portal.security.pwd.RegExpToolkit
passwords.regexptoolkit.pattern=((?=.*[0-9])(?=.*[a-z])(?=.*[A-Z])(?=.*[|:\"'<>,.?;/~!@#`$%^&*_+=-]).{8,16})
Regex description:
(?=.*[0-9]) - password should contain at least 1 digit
(?=.*[a-z]) - password should contain at least 1 lowercase character
(?=.*[A-Z]) - password should contain at least 1 uppercase character
(?=.*[|:\"'<>,.?;/~!@#`$%^&*_+=-]) - password should contain at least 1 of the mentioned special characters
.{6,24} - password should be of minimum 6 characters & maximum 24 characters
passwords.toolkit=com.liferay.portal.security.pwd.RegExpToolkit
passwords.regexptoolkit.pattern=((?=.*[0-9])(?=.*[a-z])(?=.*[A-Z])(?=.*[|:\"'<>,.?;/~!@#`$%^&*_+=-]).{8,16})
Regex description:
(?=.*[0-9]) - password should contain at least 1 digit
(?=.*[a-z]) - password should contain at least 1 lowercase character
(?=.*[A-Z]) - password should contain at least 1 uppercase character
(?=.*[|:\"'<>,.?;/~!@#`$%^&*_+=-]) - password should contain at least 1 of the mentioned special characters
.{6,24} - password should be of minimum 6 characters & maximum 24 characters