Re: MembershipProvider, ADAM and userProxy
- From: stcheng@xxxxxxxxxxxxxxxxxxxx (Steven Cheng[MSFT])
- Date: Thu, 31 Aug 2006 07:08:45 GMT
Hi Martin,
Yes, you're right. After lookup the diassembly code of the
ActiveDirectoryMembershipProvider, I found the following code fragement
which hard code the DirectorySearcher's filter as (objectClass = user):
===============================
private MembershipUser FindUser(DirectoryEntry containerEntry, string
filter, SearchScope searchScope, bool retrieveSAMAccountName, out
DirectoryEntry userEntry, out bool resetBadPasswordAnswerAttributes, out
string sAMAccountName)
{
MembershipUser user1 = null;
DirectorySearcher searcher1 = new DirectorySearcher(containerEntry);
searcher1.SearchScope = searchScope;
searcher1.Filter = "(&(objectCategory=person)(objectClass=user)" +
filter + ")";
...............................
}
================================
So I agree with you that building a custom provider would be a reasonable
solution. Also, you can even make it more flexible(add more configurable
options) so that it can fit more scenarios.
For building custom membership providers, here are some good reference
maybe helpful to you:
#Source Code for the Built-in ASP.NET 2.0 Providers Now Available for
Download
http://weblogs.asp.net/scottgu/archive/2006/04/13/442772.aspx
#Provider Toolkit
http://msdn.microsoft.com/asp.net/downloads/providers/default.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
.
- Follow-Ups:
- Re: MembershipProvider, ADAM and userProxy
- From: Lancelot
- Re: MembershipProvider, ADAM and userProxy
- References:
- MembershipProvider, ADAM and userProxy
- From: Lancelot
- RE: MembershipProvider, ADAM and userProxy
- From: Steven Cheng[MSFT]
- Re: MembershipProvider, ADAM and userProxy
- From: Lancelot
- MembershipProvider, ADAM and userProxy
- Prev by Date: Re: Forms Authentication Problem
- Next by Date: RE: Membership.ApplicationName and thread safety.
- Previous by thread: Re: MembershipProvider, ADAM and userProxy
- Next by thread: Re: MembershipProvider, ADAM and userProxy
- Index(es):
Relevant Pages
|
|