Solved

Debugging IIS Authentication

Posted on 2008-10-20
3
1,119 Views
Last Modified: 2012-05-05
Hello,

I have a new installation of Win 2003 with IIS 6. I have setup a site to use Integrated Windows Authentication in the same way that I have on all of our previous servers. I have turned off anonymous access, and have ensured that the users i want to access the website have the relevant permissions on the home directory of the website.

Below are the events:

- If i am logged onto the server and run the Auth Diagnostics tool and supply my credentials a status of 200/Ok is returned.
- If i am logged onto the server and access the website through IE and again supply my credentials i am granted access however my colleague who has exactly the same permissions as me is not granted access
- If i access the website from my own PC using IE my credentials are not accepted whatsoever
- If i access the website from my own PC using Firefox my details are accepted

I don't know where to start looking for the problem as there doesnt seem to be any pattern. Is there anyway of monitoring IIS to discover more about wht exactly is going on behind the scenes?

Regards,
Al
0
Comment
Question by:partnershipdev
  • 2
3 Comments
 
LVL 34

Expert Comment

by:Dave_Dietz
ID: 22764948
Try running the following command and see if it changes the behavior:

cscript c:\inetpub\adminscripts\adsutil.vbs set w3svc/ntauthenticationproviders NTLM

Dave Dietz
0
 

Author Comment

by:partnershipdev
ID: 22766432
Hi Dave,

That code did not seem to make any difference - i was still not granted access. However it lead me to looking at the following kb, http://support.microsoft.com/kb/871179, which details setting an servicePrincipalName on the account that the application pool is running under.

Integrated authentication is now working, but the kb doesnt explain enough about why it is now working. What does setting a servicePrincipalName do? The article would suggest that setting this flag within AD enables IIS Authentication to communicate using Kerberos?

Can you offer any insight?

Thanks
Al
0
 
LVL 34

Accepted Solution

by:
Dave_Dietz earned 500 total points
ID: 22769491
The servicePrincipalname, or SPN, is effectively a named endpoint that AD can use as an origin or destination for Kerberos authentication.  If you try to request a Kerberos ticket for an endpoint that AD doesn't know about Kerberos will fail.  Worse yet, if you ask for one it does know about (a machine name) and then hand that ticket to a process running under a different context (worker process running and a non-system account) it will not be able to read the ticket properly and authentication will fail.

The reason it worked on the server itself is that since you were makign a request to the same machine it used NTLM rather than Kerberos - you will not use Kerberos when making a request that doesn't make it out to the wire.

Dave Dietz
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Prologue It is often required to host multiple websites on a single instance of IIS, mostly in development environments instead of on production servers. I am sure it is not much a preferred solution on production servers but this is at least a pos…
Restoring deleted objects in Active Directory has been a standard feature in Active Directory for many years, yet some admins may not know what is available.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now