Custom ASP.Net Membership Provider and Certain Properties

Go To StackoverFlow.com

0

Implementing a custom membership provider, there are certain properties such as MinRequiredPasswordLength that only provide a getter.

The documentation I find online illustrates that these properties are configured in web.config.

However, it's not clear to me if System.Web.Security.MembershipProvider (from which my custom provider is derived) will read the web.config settings and set appropriate values, or if my concrete subclass is responsible for that task.

Does the base class read and set the values, or am I responsible for doing that in my subclass?

2012-04-04 05:09
by Eric J.


1

I would have thought the base class would certainly have handled that, given it's meant to be read from web.config. However, checking here -- http://msdn.microsoft.com/en-us/library/system.web.security.membershipprovider.minrequiredpasswordlength.aspx -- this is how MembershipProvider declares the property:

public abstract int MinRequiredPasswordLength { get; }

So ... I guess you're responsible for that, eh?

2012-04-04 05:29
by McGarnagle
Hmmm ouch :-) Would be nice if the base class would at least offer an implementation of the default configuration pattern - Eric J. 2012-04-04 07:18
Ads