← All articles Best Practices

Kerberoasting Detection: Advanced Splunk & ELK Hunting for RC4 TGS Abuse

By Ammar Khan, CEH · October 28, 2026 · CybernytronX Research
Kerberoasting Detection: Advanced Splunk & ELK Hunting for RC4 TGS Abuse

In November 2024, Microsoft Threat Intelligence disclosed that a threat actor tracked as Storm-0501 used Kerberoasting to escalate privileges during ransomware operations against hybrid cloud environments. The technique, first popularized by Tim Medin in 2014, remains a top initial access and privilege escalation vector because it exploits a fundamental Active Directory design: any authenticated user can request a service ticket for any service principal name (SPN). Most organizations still rely on a single RC4 TGS alert, which attackers easily evade by requesting AES tickets or targeting low-value SPNs. This article provides advanced detection engineering guidance for Splunk and the Elastic Stack (ELK), covering SPN enumeration, anomalous TGS request patterns, and RC4 downgrade attacks. You will learn to build high-fidelity detections that go beyond the basics and reduce false positives while catching real Kerberoasting activity.

Background: What Kerberoasting Really Is

Kerberoasting is a post-exploitation technique that abuses the Kerberos ticket-granting service (TGS) exchange. Any domain user can request a service ticket for a target service by supplying its SPN. The ticket is encrypted with a key derived from the service account's password hash. An attacker who requests a ticket can extract the encrypted blob from memory and attempt offline password cracking. Because the request is legitimate Kerberos traffic, it often blends with normal authentication noise.

The technique was presented by Tim Medin at DerbyCon 2014 and has since been integrated into tools like Rubeus, Impacket's GetUserSPNs.py, and PowerShell scripts. Microsoft's detection guidance (Windows Security Event 4769) recommends monitoring for RC4 encryption (0x17) and unusual service names. However, sophisticated attackers now request AES256 tickets (0x12) to avoid RC4-based alerts, or they target service accounts with weak passwords that are rarely used, making the request appear benign.

According to MITRE ATT&CK, Kerberoasting is categorized under T1558.003 (Steal or Forge Kerberos Tickets: Kerberoasting). The technique requires no elevated privileges beyond a standard domain user account, which makes it a favorite for attackers who have obtained initial access via phishing or vulnerability exploitation.

Microsoft's Threat Intelligence Center reported in 2024 that Storm-0501 used Kerberoasting to move laterally and escalate privileges in ransomware campaigns targeting hybrid cloud environments. The group requested service tickets for high-value SPNs and cracked them offline to obtain domain admin credentials.

Affected Versions and Scope

Kerberoasting is not a vulnerability in a specific product version; it is a design feature of Kerberos as implemented in Active Directory. All supported versions of Windows Server (2016, 2019, 2022, 2025) and Active Directory Domain Services are susceptible. The risk is highest when service accounts have SPNs and weak passwords, especially those with passwords older than 90 days or those set to never expire.

Microsoft's official guidance on Kerberos and service accounts is available in the Kerberos Authentication Overview. For detection, Microsoft recommends auditing Event ID 4769 and monitoring for RC4 encryption types. However, as noted in the Microsoft Defender for Identity documentation, advanced attackers may avoid RC4 and use AES, so additional behavioral analytics are required.

Service accounts with SPNs are common in environments running SQL Server, IIS, SharePoint, and custom applications. A 2023 report from Trimarc Security (now part of Semperis) found that many organizations have service accounts with passwords that are easily cracked due to shared or weak credentials. The report is not publicly linkable, but the finding aligns with CISA's Active Directory security best practices, which emphasize service account hygiene.

Attacker TTPs: Beyond the RC4 Request

Kerberoasting attacks typically follow a sequence: (1) SPN enumeration, (2) TGS request, (3) ticket extraction and offline cracking, (4) use of cracked credentials. Each phase leaves artifacts that can be detected.

SPN Enumeration

Attackers often use tools like setspn -T domain -Q */* or PowerView's Get-DomainUser -SPN to enumerate accounts with SPNs. These commands generate LDAP queries with specific filters. In Windows event logs, you may see Event ID 1644 (if LDAP auditing is enabled) or anomalous LDAP search traffic. MITRE ATT&CK maps this to T1087.002 (Account Discovery: Domain Account).

TGS Request Patterns

The core of Kerberoasting is the TGS request (Event ID 4769). Attackers often request tickets for many SPNs in a short period, or request tickets for SPNs that are rarely used. They may also request tickets with specific encryption types: RC4 (0x17) is common because it is faster to crack, but AES (0x12) is increasingly used to evade detection. A key indicator is a single user account requesting service tickets for multiple distinct SPNs within a short time window, especially if the user account is not a service account itself.

Ticket Extraction and Cracking

After receiving the ticket, attackers extract the encrypted portion using tools like Rubeus or Mimikatz and crack it offline with Hashcat or John the Ripper. This phase does not generate Windows events, but the subsequent use of cracked credentials for lateral movement (e.g., Event ID 4624 logon type 3) may be anomalous. MITRE ATT&CK maps this to T1110.002 (Brute Force: Password Cracking).

Detection: Splunk and ELK Rules

Effective detection requires correlating multiple event types. Below are detection rules for Splunk and Elasticsearch, focusing on high-fidelity indicators.

Splunk: High-Risk TGS Requests

This Splunk search identifies users requesting service tickets for multiple distinct SPNs within a 10-minute window, a common pattern in Kerberoasting. It excludes machine accounts and known service accounts to reduce noise.

index=windows EventCode=4769
| eval user=lower(Account_Name)
| eval service=lower(Service_Name)
| where NOT match(user, "\$$")
| where NOT match(service, "krbtgt")
| bin _time span=10m
| stats dc(service) as distinct_spns values(service) as spns by _time, user
| where distinct_spns >= 5
| sort - distinct_spns

This search leverages the dc() function to count distinct service names per user per 10-minute bucket. The threshold of 5 is a starting point; tune based on your environment. For environments with many service accounts, consider raising the threshold or adding a filter for known administrative accounts.

Splunk: RC4 Downgrade Detection

Attackers may force RC4 encryption for easier cracking. This search flags TGS requests with RC4 encryption (0x17) for service accounts that normally use AES.

index=windows EventCode=4769 Ticket_Encryption_Type=0x17
| eval user=lower(Account_Name)
| eval service=lower(Service_Name)
| join type=left service
    [ search index=windows EventCode=4769 Ticket_Encryption_Type=0x12
      | stats count by Service_Name
      | rename Service_Name as service
      | fields service, count ]
| where isnull(count) OR count < 10
| stats count values(service) as services by user
| where count >= 3

This search identifies users requesting RC4 tickets for services that rarely see RC4 requests (less than 10 AES requests in the search window). It then counts how many such services each user requested. A user requesting RC4 tickets for multiple such services is suspicious.

ELK: Anomalous TGS Requests

For Elasticsearch, use a query with aggregation to find users with high distinct SPN counts. The following is a Kibana search (Lucene syntax) and an aggregation example.

event.code:4769 and not winlog.event_data.TargetUserName:*$ and not winlog.event_data.ServiceName:krbtgt

Then create a Kibana visualization: a data table with a terms aggregation on winlog.event_data.TargetUserName and a cardinality aggregation on winlog.event_data.ServiceName, filtered to a 10-minute window. Set an alert threshold for cardinality >= 5.

For RC4 detection, use the following query:

event.code:4769 and winlog.event_data.TicketEncryptionType:0x17

Then create a rule that triggers when the count of such events for a single user exceeds a baseline. Elastic's prebuilt Kerberoasting detection rule provides a starting point but may generate false positives; custom tuning is essential.

Mitigation and Hardening

Detection is only part of the solution. Mitigation involves reducing the attack surface and improving credential hygiene.

Additionally, Microsoft Defender for Identity includes built-in Kerberoasting detection, which can supplement your SIEM rules. The alert documentation describes the detection logic.

Why This Matters for Defenders

Kerberoasting remains a preferred technique because it is stealthy, requires only domain user credentials, and can yield high-value credentials for lateral movement. Many organizations still rely on basic RC4 TGS alerts, which are easily bypassed by requesting AES tickets or targeting low-value SPNs. Advanced detection requires correlating multiple data sources and understanding normal behavior. By implementing the rules above, defenders can catch both traditional and evasive Kerberoasting attempts. However, detection alone is insufficient; a robust mitigation strategy that includes gMSAs and AES enforcement is critical to reducing the attack surface. As ransomware operators continue to integrate Kerberoasting into their playbooks, organizations must prioritize both detection and prevention.

Sources

Frequently Asked Questions

What is the difference between Kerberoasting and AS-REP Roasting?

Kerberoasting targets service accounts with SPNs and requests TGS tickets, while AS-REP Roasting targets user accounts that do not require Kerberos pre-authentication. Both involve offline password cracking but use different ticket types and target different account configurations.

Can Kerberoasting be detected if attackers use AES encryption?

Yes, but it requires behavioral detection rather than simple encryption-type alerts. Look for users requesting tickets for multiple distinct SPNs in a short period, or tickets for SPNs that are rarely used. The Splunk and ELK rules in this article address this.

What is the best mitigation for Kerberoasting?

Migrating service accounts to Group Managed Service Accounts (gMSAs) is the most effective mitigation because gMSA passwords are automatically rotated and extremely complex. Additionally, enforce AES encryption for Kerberos and monitor for anomalous TGS requests.

How many distinct SPNs in a short period should trigger an alert?

There is no universal threshold; it depends on your environment. Start with 5 distinct SPNs per user per 10 minutes, then baseline and adjust. In environments with many service accounts, you may need a higher threshold or additional context.

Does Microsoft Defender for Identity detect Kerberoasting out of the box?

Yes, Defender for Identity includes a detection for Kerberoasting. However, it may not catch all evasive techniques, so supplementing with SIEM rules is recommended for defense in depth.

Are there any legitimate reasons for a user to request many TGS tickets?

Yes, some administrative tools or scripts may request multiple tickets. It is important to baseline normal behavior and exclude known administrative accounts or service accounts that legitimately request many tickets.

Need expert help with this?

CybernytronX specializes in Active Directory security assessments and detection engineering. Our team can help you implement robust Kerberoasting detection in Splunk or ELK, tune rules to your environment, and harden service account configurations. We also offer Ethereon AI, our threat detection platform that uses machine learning to identify anomalous Kerberos activity. Whether you need a penetration test to validate your defenses or a SOC build-out to operationalize detections, we can help. Contact us at cybernytronx.com/contact.html or learn more about Ethereon at cybernytronx.com/ethereon.html.

AK

Ammar Khan — Founder, CybernytronX

Certified Ethical Hacker (CEH), B.S. Cybersecurity, Google Certified. 5+ years pentesting, creator of Ethereon AI threat detection. Has remediated 50+ environments and recovered 20+ compromised domains. Hire CybernytronX →

← Back to all articles