I am trying to set minimum password requirements for my membership provider in Umbraco. Currently my web.config membership section looks like this:
<membership defaultProvider="UmbracoMembershipProvider" userIsOnlineTimeWindow="15">
<providers>
<clear />
<add name="UmbracoMembershipProvider" type="umbraco.providers.members.UmbracoMembershipProvider" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" defaultMemberTypeAlias="Another Type" passwordFormat="Hashed" minRequiredPasswordLength="7" minRequiredNonalphanumericCharacters="1" />
<add name="UsersMembershipProvider" type="umbraco.providers.UsersMembershipProvider" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" passw开发者_开发技巧ordFormat="Hashed" minRequiredPasswordLength="7" minRequiredNonalphanumericCharacters="1" />
</providers>
</membership>
However, when I login in through the website and change my password, it will let me use a password of any length and makeup. Is there something I'm missing? Thanks!
Typically custom membership provider settings are passed as custom xml attributes on the tag itself. You can see one there already: "userIsOnlineTimeWindow." Fire up Reflector and have a dig around the Assembly containing that provider, or praise-jeebus, RTFM. :D
-Oisin
精彩评论