Problem inheriting from sqlmembershipprovider

S

Sherman KB

I needed to extend the attributes being collected by the
sqlmembershipprovider. Since we're using a sql store, inheriting from the
sqlmembershipprovider class seemed to make sense. I'm running into several
problems.

In my unit tests, when calling the DeleteUser method, I get a
System.Nullreferenceexception. This is nothing more than
Mybase.DeleteUsername(username, true).

I've got a logon control that was oringally working with the out of the box
sqlmembership provider. I've since changed my web.config file to work with my
new provider class. The error that I get is "Configured settings are invalid:
Hashed passwords cannot be retrieved. Either set the password format to
different type, or set supportsPasswordRetrieval to false".

My web.config looks like:

<membership defaultProvider="MembershipProvider"
userIsOnlineTimeWindow="20">
<providers>
<clear/>
<remove name="AspNetSqlProvider"/>
<add
name="providerUserKey"
type="PDI.System.Web.Security.MemberShipProvider, Membership,
Version=1.0.0.0" connectionStringName="Sandbox"
enablePasswordRetrieval="false" enablePasswordReset="true"
requiresQuestionAndAnswer="true" applicationName="CST"
requiresUniqueEmail="true" passwordFormat="Hashed"
maxInvalidPasswordAttempts="3" minRequiredPasswordLength="6"
minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="5"
passwordStrengthRegularExpression=""/>
</providers>
</membership>


Can anyone point me in the right direction to troubleshoot this?
 
S

Sherman KB

Ok,

I changed the passwordformat to "Clear" and I get a little further. Not sure
why the hashed format is causing problems.... Anyway, using the Clear
password format, I get a message "Default membership provider could not be
found". What's the proper way to identify my provider (assembly name is
Membership, namespace is PDT.System.Web.Security, class name is
MembershipProvider).
 

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,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top