How to Set minRequiredNonalphanumericCharacters="0"?

E

EagleRed

I am trying to set up an ASP.NET 2.0 application using the Membership API
with SQL Server 2005 to not require non-alphanumeric characters in the
password. I have set minRequiredNonalphanumericCharacters="0" and the
passwordStrengthRegularExpression="\w{6-12}" in the web.config. The password
I enter is "w99hthr" and it fails. When I remove these two attributes and
use the password, "w!99hthr" it works. My users will strongly resist using
passwords requiring non-alphanumeric characters. Many of them are naive.
 
D

Dominick Baier [DevelopMentor]

Hi,

according to the source code - you can set minReqNonAlphaChars to 0 - it
defaults to 1 if the value is missing.

It is maybe the regex - wouldn't setting minRequiredPasswordLength to 6 also
do it?
 
E

EagleRed

I have set minRequiredPasswordLength to 6. If I remove the
minRequiredNonalphanumericCharacters and passwordStrengthRegularExpression
attributes from the web.config file and accept the defaults and enter a
password with a non-alphanumeric character, it works. However, when I add
them back it fails. I believe the regex that I define should accept the
password I used. The password is 7 characters long and only contains lower
case letters and numbers, so it should be OK.

I really need to avoid forcing the users to use non-alphanumeric characters.
 
D

Dominick Baier [DevelopMentor]

what i wanted to say is:

minChars=6
minNonAlphas=0

no regex...

that should do it, right?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,132
Latest member
TeresaWcq1
Top