I want to authenticate Thread.CurrentPrincipal.Identity when it has entry in active directory or redirect user to login page to check the database for valid user.
MBM
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If Integrated Windows Authentication is turned ON in IIS and you’ve set the identity mode to “windows” in your Web.config, authentication using AD is completely automatic. You should not need a “login page” per se. You can and should do checks like this in your global.asax file in the Application_AuthenticateRequest handler.
You really owe it to yourself to read this:
http://msdn.microsoft.com/en-us/library/ff649337.aspx
And I can’t stress how helpful Keith Brown’s book is on getting these concepts understood and working properly:
http://alt.pluralsight.com/wiki/default.aspx/Keith.GuideBook/HomePage.html