Kerberoasting
https://attack.mitre.org/techniques/T1558/003/
Last updated
https://attack.mitre.org/techniques/T1558/003/
Last updated
ATT&CK ID: T1558.003
Permissions Required: Valid Domain Account | Ability to sniff domain traffic
Description
Adversaries may abuse a valid Kerberos ticket-granting ticket (TGT) or sniff network traffic to obtain a ticket-granting service (TGS) ticket that may be vulnerable to Brute Force.
Service principal names (SPNs) are used to uniquely identify each instance of a Windows service. To enable authentication, Kerberos requires that SPNs be associated with at least one service logon account (an account specifically tasked with running a service).
Adversaries possessing a valid Kerberos ticket-granting ticket (TGT) may request one or more Kerberos ticket-granting service (TGS) service tickets for any SPN from a domain controller (DC). Portions of these tickets may be encrypted with the RC4 algorithm, meaning the Kerberos 5 TGS-REP etype 23 hash of the service account associated with the SPN is used as the private key and is thus vulnerable to offline Brute Force attacks that may expose plain text credentials.
Cracked hashes may enable Persistence, Privilege Escalation, and Lateral Movement via access to Valid Accounts.
CMD
Powerview
Get-SPNs
Rubeus (Binary)
Documentation: https://github.com/GhostPack/Rubeus#kerberoast
Rubeus (PowerShell)
Invoke-Kerberoast
The hashes produced for type 18 and type 17 are not calculated correctly in this script and will not crack. Use Rubeus instead if you need to obtain type 18 or 17 hashes.
Good list for cracking: https://gist.github.com/The-Viper-One/a1ee60d8b3607807cc387d794e809f0b
GTX 980
Rockyou
Best64
1 Billion
1 hour, 22 mins
9 Seconds
RTX 3090 x 2 + RTX3070
Rockyou
Best64
1 Billion
7 Minutes, 13 Seconds
Instant
GTX 980
rockyou2021
Best64
651 Billion
36 Days
1 Hour, 56 minutes
RTX 3090 x 2 + RTX3070
rockyou2021
Best64
651 Billion
3 Days, 2 hours
4 mins, 50 seconds
GTX 980
Basically forever
173 years, 22 days
9
RTX 3090 x 2 + RTX3070
Basically forever
6 years, 25 days
9
Maintain service account passwords with a minimum length of 25 characters and ensure they are generated using a completely random process.
Implement regular password rotations for service accounts to enhance security.
Ensure service accounts have minimal permissions within the domain
Enforce the usage of AES256 encryption instead of RC4 for Kerberos authentication.
Ensure that your Key Distribution Center (KDC) is running at least Windows Server 2019. Older server versions may default to using RC4 encryption when an encryption downgrade request is initiated.
Whenever feasible, leverage Group Managed Service Accounts (GMSA) for service account management.
Regularly review Windows Event Logs, specifically the Security event log. Look for Event ID 4769 (Kerberos service ticket requests) that indicate service ticket requests for accounts. Unusual or suspicious patterns should be investigated.
Deploy honeytokens or honeyaccounts, which are fake accounts or credentials that are monitored. If these are accessed, it could indicate an attacker attempting to perform kerberoasting based attack.
Monitor for LDAP queries which may be used to discover accounts with SPNs. This is often performed by adversaries to perform initial discovery: