0 Replies - 934 Views - Last Post: 20 March 2009 - 06:34 AM

#1 Sephrial  Icon User is offline

  • New D.I.C Head
  • member icon

Reputation: 0
  • View blog
  • Posts: 0
  • Joined: 20-December 08

ASP.NET SOX Password Policy Enforcement

Posted 20 March 2009 - 06:34 AM

Description: The first line in the .aspx file is the textbox where the password is entered. The first RegularExpressionValidator tests to make sure the password is at least 6 characters. The last RegularExpressionValidator contains the regex that validates that the password meets at least 3 of the 4 criteria: 1.Must contain Special characters 2.Must contain Upper case 3.Must contain Lower case 4.Must contain NumericsThis ASP.NET script implements SOX compliant password enforcement. In this script passwords must contain minimum of 6 characters and satisfy 3 out of 4 rules below 1.Must contain Special characters 2.Must contain Upper case 3.Must contain Lower case 4.Must contain Numerics



ressionValidator ID="regexpPass" runat="server" display="Dynamic"
    ControlToValidate="NewPass" 
    ErrorMessage="Password must contain at least 6 nonblank characters." 
    ValidationExpression="[^s]{6,255}" meta:resourcekey="regexpPassResource1" />
ressionValidator ID="regexpNewPass" runat="server" display="Dynamic"
    ControlToValidate="NewPass" 
    ErrorMessage="Password must contain 3 of the following characters: an upper-case, lower-case, number, and a special character."
    ValidationExpression="((?=.*d)(?=.*[A-Z])(?=.*[a-z])|(?=.*d)(?=.*[^A-Za-z0-9])(?=.*[a-z])|(?=.*[^A-Za-z0-9])(?=.*[A-Z])(?=.*[a-z])|(?=.*d)(?=.*[A-Z])(?=.*[^A-Za-z0-9]))^.*" />


Is This A Good Question/Topic? 0
  • +

Page 1 of 1