A Brief History of NTLM Reflection Bugs
A timing flaw in Windows NTLM authentication allows an attacker to bypass the challenge cache that prevents reflection attacks. By deliberately failing an authentication attempt, the attacker can flush old challenges and then reflect a victim's NTLM authentication to a local service, potentially gaining elevated access.
shenaniganslabs.io
Published on shenaniganslabs.io
Halloween has come and gone, and yet NTLM reflection is back from the dead to haunt MSRC once again. This post describes a deceptively simple bug that has existed in Windows for 15 years.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
The challenge cache used to detect NTLM reflection removes entries older than 300 seconds whenever a new challenge is added, so an attacker can force a cache flush by making a failed authentication attempt and then reuse an old challenge.
Impact
An attacker could gain elevated access to the victim's machine, such as write access to the C$ share or home directory, depending on the victim's privileges.
What the attacker needed
Ability to coerce victim authentication; Victim process runs as medium integrity or higher; Attacker can reflect NTLM to local SMB
The fix
Microsoft released a patch for this issue in the November 2019 security update (CVE-2019-1384).
How it was found
- Coerce a victim process to authenticate via WebDAV to the attacker's host.
- Reflect the NTLM messages back to the victim's SMB server up to the final AUTHENTICATE message.
- Wait for 5 minutes and 15 seconds.
- Perform a second authentication with a bogus password to flush the challenge cache.
- Reflect the final AUTHENTICATE message to complete the attack.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
NTLM is an authentication protocol used by Windows. In a reflection attack, an attacker tricks a victim's computer into authenticating to the attacker's machine, then relays that authentication back to the victim's own machine to gain access. This report shows a way to bypass a protection that was added to stop such attacks.
What is Account takeover?
Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.