How do I set minumum password requirements in Umbraco for the membership provider?

删除回忆录丶 提交于 2019-12-12 19:07:37

问题


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" passwordFormat="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!


回答1:


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



来源:https://stackoverflow.com/questions/1651816/how-do-i-set-minumum-password-requirements-in-umbraco-for-the-membership-provide

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!