Custom Membership Provider based on SQLMembershipProvider

Posted by Community Admin on 03-Aug-2018 19:17

Custom Membership Provider based on SQLMembershipProvider

All Replies

Posted by Community Admin on 17-Mar-2011 00:00

In 3.7 I developed a custom MembershipProvider and a RoleProvider based on the Microsoft SQL providers.  It has worked very well in 3.7.  The providers are in a separate dll.  I've upgraded the dll to .NET 4.0 and I am trying to configure the providers in Sitefinity 4.0 SP1 to no avail.  I added my login control to a page and set the membership provider to my custom provider.  When I tried to login with the custom control, I get this message:

Could not find the specified membership provider.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: Could not find the specified membership provider.
Here are the applicable lines from SecurityConfig.config.
<roleProviders>
    <add connection="LdapConnection" enabled="True" name="LdapRoles" />
    <add description="" resourceClassId="" type="BusinessLogicWeb.AtlantisRoleProvider" type:type="System.RuntimeType, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" connectionStringName="Atlantis" applicationName="/" enabled="True" name="Atlantis" />
</roleProviders>
<membershipProviders>
    <add applicationName="/" connection="LdapConnection" enabled="True" name="LdapUsers" />
    <add description="" resourceClassId="" type="BusinessLogicWeb.AtlantisMembershipProvider" type:type="System.RuntimeType, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" connectionStringName="Atlantis"  applicationName="/" enabled="True" name="Atlantis" />
</membershipProviders>

And here's the asp markup:
<asp:Login runat="server" ID="mainLogin"
                MembershipProvider="Atlantis" onloginerror="mainLogin_LoginError" 
        >
    </asp:Login>

What am I doing wrong?  Do I have to configure my providers in web.config?  In many other forum posts, you talk about membership provider features that would be available on release.  Is it feature complete now?  Many others have asked for samples.  Can you provide any?

Abraham

Posted by Community Admin on 23-Mar-2011 00:00

Hi Abraham,

You need to configure your provider through the configuration section

Administration >> Settings >> Advanced >> Security.

Best wishes,
Ivan Dimitrov
the Telerik team

Posted by Community Admin on 23-Mar-2011 00:00

The membership provider was based on Microsoft's model, not Telerik's new MembershipDataProvider.  I'm going to wait for the Q1 release which is supposed to include wrappers that will make my MembershipProvider work.

Abraham.

This thread is closed