9. Service Classes allowed by host
alerter clipsrv dnscache
http msiserver netman
policyagent rpc scardsvr
scm time wins
appmgmt dcom eventlog
ias mcsvc nmagent
protectedstorage rpclocator scesrv
seclogon trksvr www
browser dhcp eventsystem
iisad netdde oakley
rasman rpcss Schedule
snmp trkwks fax
cifs dmserver plugplay
min netddedsm
remoteaccess rsvp
spooler ups
cisvc dns
messenger netlogon
replicator samss
Tapisrv w3svc
10. Kerberos
â˘Benefits
â˘Delegated Authentication
â˘Interoperability
â˘More Efficient Authentication
â˘Mutual Authentication
â˘Reasons to Use
â˘Need Auditing at the Data Sources
â˘Data Sources contain Row Level Security
â˘Otherwise, DO NOT USE IT!
36. References
â˘Ken Schaeferâs Multi-Part Kerberos Blog Posts:
http://www.adopenstatic.com/cs/blogs/ken/archive/2006/10
/20/512.aspx
â˘What Is Kerberos Authentication?
http://technet.microsoft.com/en-
us/library/cc780469%28WS.10%29.aspx
â˘How the Kerberos Version 5 Authentication Protocol
Works
http://technet.microsoft.com/en-
us/library/cc772815%28WS.10%29.aspx
â˘Explained: Windows Authentication in ASP.NET 2.0
http://msdn.microsoft.com/en-us/library/ff647076.aspx
37. References
â˘Kerberos Authentication Tools and Settings
http://technet.microsoft.com/en-
us/library/cc738673%28WS.10%29.aspx
â˘How To: Use Protocol Transition and Constrained
Delegation in ASP.NET 2.0
http://msdn.microsoft.com/en-us/library/ff649317.aspx
â˘Spence Harbarâs Blog
http://www.harbar.net
38. Housekeeping
⢠Follow SharePoint Saturday
Ozarks on Twitter @SPSOzarks
hashtag #SPSOzarks
⢠Stop by and thank our sponsors
for making this event possible!
⢠Fill out and turn in evaluation
forms to be eligible for the end-of-
day raffle. You must be present to
win.
⢠Donât miss âThis Modern Stationâ
tonight at Waxy OâSheaâs!
38 | SharePoint Saturday St. Louis 2012
43. â˘Kerberos is an open authentication protocol. Kerberos v5
was invented in 1993 at MIT.
â˘Authentication is the process of proving your identity to a
remote system.
⢠Your identity is who you are, and authentication is
the process of proving that. In many systems your
identity is your username, and you use a secret
shared between you and the remote system (a
password) to prove that your identity.
â˘User password is encrypted as the user key. User key is
stored in credentials cache. Once the logon session key is
received, the user key is discarded.
â˘Service password is encrypted as the service key.
â˘KDCs are found through a DNS query. Service registered
in DNS by DCs.
44. â˘Showing detail behind what is happening inside of KDC
but for day-to-day, use can just remember KDC
â˘Another reason for simplification: encryption upon
encryption upon encryptionâŚjust remember it is encrypted
â˘This is a Windows-centric Kerberos presentation
â˘Load balanced solutions need service account
â˘All web applications hosted using the same SPN have to
be hosted with the same account
â˘Use A records, not CNAME records
45. â˘Terms
â˘Key Distribution Center (KDC) â In Windows AD, KDC
lives on domain controllers (DC), KDCs share a long term
key across all DCs.
â˘KDC security account database â In Windows, it is Active
Directory
â˘Authorization Service (AS) â part of the KDC
â˘Ticket Granting Service (TGS) â part of the KDC
â˘Ticket Granting Ticket (TGT) - A user's initial ticket from
the authentication service, used to request service tickets,
and meant only for use by the ticket granting service.
Keeps the user from having to enter password each time a
ticket is requested.
46. Tickets
â˘Ticket Granting Ticket (TGT)
â˘A user's initial ticket from the authentication service
â˘Used to request service tickets
â˘Meant only for use by the ticket-granting service.
â˘Service ticket for the KDC (service class = krbtgt)
â˘Service Ticket
â˘Enables the ticket-granting service (TGS) to safely
transport the requester's credentials to the target
server or service.
48. â˘Troubleshooting
⢠Have user logon and logoff if they donât regularly:
TGTs are only renewable for so long and then they
expire (7 day default), then password has to be re-
entered.
⢠Remember that authenticators contain the current
time. Check for time sync issues.
49. â˘Common Issues
⢠Missing SPN
⢠Duplicate SPN
⢠SPN assigned to wrong service account
⢠Times are out of sync
⢠Client TGT expired (7 days)
⢠IE and non-default ports
50. â˘Request TGT (Remember there is even more complexity)
1. User (client) logs into workstation entering their
password.
2. Client builds an authentication service request
containing the userâs username (KPN), the SPN of the
TGS, and encrypts the current time using the userâs
password as an authenticator.
3. Client sends these three items to the KDC.
4. KDC get userâs password from AD, decrypts time and
verifies it is valid.
5. AS generates a logon session key and encrypts with
the userâs password. AS generates a service ticket
which contains a logon session key and the userâs KPN
encrypted with the AS shared key. This is a special
service ticket called a Ticket Granting Ticket (TGT).
51. â˘Request TGT (Remember there is even more complexity)
6. KDC sends both to the client.
7. Client decrypts logon session key using its password
and stores the logon session key in cache. The client
stores the TGT in cache.
52. â˘Access Service (Remember there is even more complexity)
1. User (client) encrypts the current time using the logon
session key in cache creating an authenticator and
sends the authenticator, the userâs KPN, the name of
the target service (SPN), and the TGT to the TGS.
2. TGS decrypts the TGT using its shared key to access
the logon session key. The logon session key is used to
decrypt the authenticator and confirms the time is valid.
3. TGS extracts the userâs KPN from the TGT. TGS
generates a service session key and encrypts the
service session key using the logon session key. TGS
uses server session key to generate service ticket and
encrypts it using serviceâs password.
4. TGS sends service session key and the service ticket
to the client.
53. â˘Access Service (Remember there is even more complexity)
5. Client decrypts service session key using cached logon
session key, adds current time (as well as other items),
and encrypts with the service session key to create an
authenticator.
6. Client sends ticket and authenticator to remote server
which runs service.
7. Service decrypts service ticket accessing the server
session key and the KPN. Using the service session
key, the service decrypts the authenticator and confirms
the current time is valid. A Windows access token is
generated
8. (Optional) If client requests mutual authentication,
service encrypts current time using the service session
key creating an authenticator and sends to the client.
9. Clients decrypts authenticator and validates time.
54. Troubleshooting Tools
⢠Patience â Test methodically and
⢠Knowledge - Know your Forests, Domains, Trusts,
Functional LevelsâŚget a basic lay of the land.
⢠Always test from a different machine than the web
server or domain controller!
⢠SetSPN
⢠Windows Security Logs
⢠Windows 2008 ADUC
⢠Kerbtray
⢠Netmon and Fiddler
⢠IIS Logs and IIS7 Failed Request Tracing
⢠Kerberos Logging
⢠Event Logging and/or Debug Logs
55. Common Issues that break Kerberos
⢠Times are out of sync â authenticators contain
current time
⢠Missing SPN
⢠Duplicate SPN
⢠SPN assigned to wrong service account
⢠IIS Providers are incorrect (For IIS 5 or 6, see
http://support.microsoft.com/kb/215383)
⢠IIS 7 â remember Kernel mode authentication and
check settings
⢠Client TGT expired (7 days expiration â have user
logon and logoff, no reboot required)
⢠IE and non-default ports