can't override ValidateUser
Hello,
<
membership
defaultProvider
=
"Default"
>
<
providers
>
<
clear
/>
<
add
name
=
"Default"
type
=
"Company.Web.CustomMembershipProvider"
/>
</
providers
>
</
membership
>
Hi RC,
Thank you for using our services.
Can you please let us know what is the error you are getting? Also please note that App_Code folder does not exist in web application project, which is the Sitefinity 4.0 website. You can add the code anywhere in the project and the assembly name will be SitefinityWebApp. Also make sure that you build the application before running it.
Sincerely yours,
Radoslav Georgiev
the Telerik team
Hi RC,
Thank you for the clarification.
Can you please try the following steps.
1) Revert the web.config to its original value.
2) Make your class inherit from OpenAccessMembershipProvider
3) Login to Sitefinity back-end and go to Administration -> Settings -> Security -> Membership Providers and register your custom membership provider.
4) You should at least specify an applicationName in its parameters collection. For example CustomProvider/
Note that since you are inheriting from the built in provider you can configure the same parameters as in the default ones.
5) Make sure that the Enabled check box is selected for your provider and go to the Users section. From there create a new user in your custom provider and assign it to the administrators role.
6) Log out and on the log in screen select your custom provider from the provider dropdown and try to authenticate with the new user.
All the best,
Radoslav Georgiev
the Telerik team
Thanks for the steps Radoslav.
Hi RC,
There is such a method which can be overriden. It has two overloads - one taking user name and password, and the second taking user ID and password. Please take a look at the attached sample project. You might need to resolve the broken references before running it.
Sincerely yours,
Radoslav Georgiev
the Telerik team
Thank you Radoslav, got it! I missed that OpenAccessMembershipProvider inherits from MembershipDataProvider. :)