下边是web.config中的一段,其中的 maxInvalidPasswordAttempts="3" 是输入错误密码时允许的最大次数,可以修改为10000,或更多。
<configuration>
<connectionStrings>
<add name="ADService" connectionString="LDAP://ldapServer/" />
</connectionStrings>
<system.web>
<membership defaultProvider="AspNetActiveDirectoryMembershipProvider">
<providers>
<add name="AspNetActiveDirectoryMembershipProvider"
type="System.Web.Security.ActiveDirectoryMembershipProvider,
System.Web, Version=2.0.3600, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a"
maxInvalidPasswordAttempts="3"
passwordAttemptWindow="10"
passwordAnswerAttemptLockoutDuration="15" />
</providers>
</membership>
</system.web>
</configuration>