← Back to list

Kerberos,SPNs and Kerberoasting

What is Kerberos ?

Rishita Trivedi · 2026-06-03 10:48 · 0 claps · 3.7 min read
#kerberoasting #spn #kerberos
Open on Medium ↗

Kerberos,SPNs and Kerberoasting

What is Kerberos ?

Kerberos is a network authentication protocol. It is designed to provide strong authentication for client/server applications by using secret-key cryptography(symmetric-key).

Kerberos was created by MIT as a solution to network security problems. The Kerberos protocol uses strong cryptography so that a client can prove its identity to a server (and vice versa) across an insecure network connection. After a client and server has used Kerberos to prove their identity, they can also encrypt all of their communications to assure privacy and data integrity as they go about their business.

In summary, it provides the tools of authentication and strong cryptography over the network to help you secure your information systems across your entire enterprise.

Why use Kerberos?

Kerberos avoids the need for passwords to be flowed to authenticate to multiple servers over an insecure network. This feature can help reduce the need to manage multiple passwords. It allows clients and servers to do either one-way authentication (the server authenticates the client), or two-way (mutual) authentication, where the client also authenticates the server.

How Kerberos works

The Kerberos system consists of three components: a client, a server, and a trusted third party, which is also known as a Key Distribution Center (KDC). The KDC interacts with both a client and server to accept the client’s request, authenticate its identity, and issue tickets to the service. The domain that is served by a single KDC is referred to as a realm. A principal is used to identify each client and server in a realm. The principal name is uniquely assigned for all clients and servers by the Kerberos administrator. All principals must be known to the KDC.

  1. The first-phase exchange takes place between a client and the authentication server. In this phase, the authentication server authenticates the user (for example, by validating the user ID and password). After a successful login, the authentication server obtains the user’s secret keys and returns a ticket-granting ticket (TGT) to the client.

  2. On receiving the TGT, the client sends a request (containing the TGT) for a service ticket to the ticket-granting server (TGS). The TGS authenticates the TGT and then returns a service ticket to the client.

  3. The service ticket allows the client to communicate with the server that is providing a service that the client wants to use. The server can verify the client without contacting the KDC by using the service ticket. An extension to the protocol is mutual authentication. When this is configured, additional information flows back to the client in this step to authenticate the server.

Service Principal Name (SPNs)

A Service Principal Name (SPN) is the identifier that Kerberos clients use to request a ticket for a particular service instance. An SPN ties a network service (for example, HTTP on web01.example.com) to the AD account (a user or machine account) that runs that service. The KDC uses the SPN to know which account’s key to use to encrypt the server portion of the service ticket.

For example, suppose:

  • User: Alice
  • Web Server: web01.example.com
  • Service: HTTP
  • Service runs under AD account: svc_web

The SPN might be:HTTP/web01.example.com

When Alice opens https://web01.example.com:

  1. Alice already has a TGT.

  2. Her computer asks the KDC: “I need a ticket for HTTP/web01.example.com.”

  3. The KDC searches Active Directory for that SPN.

  4. AD tells the KDC that this SPN belongs to the account svc_web.

  5. The KDC creates a service ticket and encrypts part of it using the key derived from svc_web’s password.

  6. The web server receives the ticket and decrypts it because it knows the password of svc_web.

What is Kerberoasting?

Kerberoasting is a post-authentication attack against Active Directory environments in which an attacker with a valid domain user account requests Kerberos service tickets (TGS tickets) for Service Principal Names (SPNs). The attacker then extracts the service ticket, whose encrypted portion is protected using a key derived from the target service account’s password, and performs offline password cracking to recover the service account credentials. The attack is particularly effective against service accounts that use weak passwords or legacy encryption algorithms such as RC4.

Working of Kerberoasting

  1. The attacker gains access to a valid domain user account.

  2. The attacker enumerates Service Principal Names (SPNs) associated with service accounts in Active Directory.

  3. Using the authenticated account, the attacker requests a Ticket Granting Service (TGS) ticket for a selected SPN from the Key Distribution Center (KDC).

  4. The KDC issues the TGS ticket and encrypts its service portion using a key derived from the target service account’s password.

  5. The attacker extracts the encrypted ticket from memory or from the Kerberos ticket cache.

  6. The encrypted ticket is transferred to an offline system where password-cracking tools are used to perform brute-force or dictionary attacks against the ticket.

  7. If the service account password is weak, the attacker successfully recovers the password and gains access to the service account.


메타데이터
post_id
8b53eeb7fc0b
slug
kerberos-spns-and-kerberoasting-8b53eeb7fc0b
url
https://medium.com/@rishitaa/kerberos-spns-and-kerberoasting-8b53eeb7fc0b
canonical_url
https://medium.com/@rishitaa/kerberos-spns-and-kerberoasting-8b53eeb7fc0b
author_url
https://medium.com/@rishitaa
status
ok
fetched_at
2026-06-17 08:20:12