Re: ASP.NET windows authetication
From: Paul Clement (UseAdddressAtEndofMessage_at_swspectrum.com)
Date: 12/14/04
- Next message: Carlos: "asp.net how to login to AD from a webform"
- Previous message: Nicole Calinoiu: "Re: Page.User.Identity.Name vs. WindowsIdentity.GetCurrent().Name"
- In reply to: Andy: "Re: ASP.NET windows authetication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Tue, 14 Dec 2004 08:31:28 -0600
On Sun, 12 Dec 2004 20:33:02 -0800, "Andy" <Andy@discussions.microsoft.com> wrote:
¤ Not quite.
¤ Users who don't enter an e-mail address would authenticate with aciive
¤ directory.
¤ User who do enter an e-mail address would authenticate with an access
¤ database (I already know about hasing passwords)
¤
You will have to use Forms Authentication for both and then choose windows or database
authentication based upon the account ID they enter.
Authenticating against the database is relatively easy. Authenticating against AD might require a
bit more effort. What you will probably need to do is call the LogonUser API function call. There is
an example in the article below. You don't need to implement the impersonation code, just call
LogonUser with the supplied credentials.
How to implement impersonation in an ASP.NET application
http://support.microsoft.com/kb/306158/EN-US/
There is another method that uses DirectoryServices, however I'm somewhat dubious about the solution
since Microsoft has indicated in the past that ADSI and DirectoryServices were not designed for
authentication.
HOW TO: Authenticate against the Active Directory by Using Forms Authentication and Visual Basic
.NET
http://support.microsoft.com/?id=326340
Paul ~~~ pclement@ameritech.net
Microsoft MVP (Visual Basic)
- Next message: Carlos: "asp.net how to login to AD from a webform"
- Previous message: Nicole Calinoiu: "Re: Page.User.Identity.Name vs. WindowsIdentity.GetCurrent().Name"
- In reply to: Andy: "Re: ASP.NET windows authetication"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|