Index: lams_central/web/forgotPasswordChange.jsp =================================================================== RCS file: /usr/local/cvsroot/lams_central/web/forgotPasswordChange.jsp,v diff -u -r1.5.2.6 -r1.5.2.7 --- lams_central/web/forgotPasswordChange.jsp 31 Oct 2016 16:16:34 -0000 1.5.2.6 +++ lams_central/web/forgotPasswordChange.jsp 25 Nov 2016 03:33:25 -0000 1.5.2.7 @@ -12,6 +12,7 @@ <%=Configuration.get(ConfigurationKeys.PASSWORD_POLICY_MINIMUM_CHARACTERS)%> <%=Configuration.get(ConfigurationKeys.PASSWORD_POLICY_UPPERCASE)%> +<%=Configuration.get(ConfigurationKeys.PASSWORD_POLICY_LOWERCASE)%> <%=Configuration.get(ConfigurationKeys.PASSWORD_POLICY_NUMERICS)%> <%=Configuration.get(ConfigurationKeys.PASSWORD_POLICY_SYMBOLS)%> @@ -35,18 +36,18 @@ window.location = "index.do"; }; - $.validator.addMethod("pwcheck", function(value) { - return /[a-z]/.test(value) // has a lowercase letter - && /[A-Z]/.test(value) // has uppercase letters - - && /\d/.test(value) // has a digit - - - && /[`~!@#$%^&*\(\)_\-+={}\[\]\\|:\;\"\'\<\>,.?\/]/ - .test(value) //has symbols - - }); + var mustHaveUppercase = ${mustHaveUppercase}, + mustHaveNumerics = ${mustHaveNumerics}, + mustHaveLowercase = ${mustHaveLowercase}, + mustHaveSymbols = ${mustHaveSymbols}; + $.validator.addMethod("pwcheck", function(value) { + return (!mustHaveUppercase || /[A-Z]/.test(value)) && // has uppercase letters + (!mustHaveNumerics || /\d/.test(value)) && // has a digit + (!mustHaveLowercase || /[a-z]/.test(value)) && // has a lower case + (!mustHaveSymbols || /[`~!@#$%^&*\(\)_\-+={}\[\]\\|:\;\"\'\<\>,.?\/]/.test(value)); //has symbols + }); + $.validator .addMethod( "charactersAllowed", @@ -132,6 +133,10 @@
  • + +
  • +