views:

132

answers:

1

I have this situation:

I have a website and needs to use the users base from a users database (SQL Server, Oracle, etc) and from a NT user database (computer or domain) for security/authentication of the site.

The scenario is this:

  1. A user logs into the site and enters his/her username and password.
  2. The site looks up to the users database (SQL Server, Oracle, etc.) if the user exists.
  3. If not, the site looks up to the domain (Active Directory) if the user exists.

How can I use both user bases? Is it possible to use SqlMembershipProvider AND ActiveDirectoryMembershipProvider at the same time?

+2  A: 

Yes it is possible.

Just add both MembershipProviders to your Web.config and specify a defaultMembershipProvider afaicr

Eoin Campbell
I mean you can use them both AT THE SAME TIME? If so, how's it going to work?
jerbersoft
It'll check one first, and if that fails, failover to the second one. If you needed to have a unified (some info in ADSI/some in SQL), then you'd probably need to write some custom double access provider
Eoin Campbell

related questions