NTLM: how it works, how it is attacked, and how to investigate it

NTLM (NT LAN Manager) is Microsoft's challenge-response authentication protocol, in which a computer proves a user knows a password by answering a challenge with a value derived from the password's hash. Kerberos replaced it as the default in Active Directory domains in 2000, but Windows still falls back to NTLM for local accounts, connections by IP address and older applications, and that fallback is what attackers exploit.

GlossaryWindows authenticationChecked 2 December 2026

How NTLM authentication works

NTLM never sends the password. Instead, three messages pass between the client and the server:

  • Negotiate. The client says it wants to authenticate and which NTLM features it supports.
  • Challenge. The server replies with a random value, the challenge.
  • Authenticate. The client computes a response from the challenge and the user's password hash (the NT hash) and sends it with the user name and domain.

For a local account, the server checks the response against the hash in its own SAM. For a domain account, the server passes the challenge and response to a domain controller, which checks them against the account's stored hash and replies yes or no; this is NTLM pass-through authentication, and it is why domain controllers log NTLM attempts made against other servers.

The design has one property that shapes everything that follows: the NT hash is effectively the password. Anyone who has it can compute valid responses without ever knowing the password itself.

NTLMv1, NTLMv2 and LM

VersionStatusWeakness
LMObsolete; disabled by default for many yearsCase-insensitive, split into 7-character halves, cracked in seconds
NTLMv1Deprecated; removed from Windows 11 version 24H2 and Windows Server 2025Responses can be converted back to the NT hash with modest effort
NTLMv2Still supported; deprecated as a whole in favour of KerberosResponses can be cracked offline if the password is weak; open to relay

Microsoft announced in 2024 that all versions of NTLM are deprecated and no longer under active development, and recommends Kerberos or Negotiate (which prefers Kerberos) for everything that can use them. In practice NTLMv2 will remain in many networks for years, because applications, appliances and scripts still depend on it.

NTLM vs Kerberos

NTLMKerberos
How the user proves identityResponse to a server's challenge, derived from the password hashTickets issued by the domain controller's key distribution centre
Server verifies withThe domain controller, for every authentication (pass-through)The ticket itself, without contacting the DC
Mutual authenticationNo: the client cannot verify the serverYes
Works withLocal accounts, workgroups, IP addressesDomain accounts, with host names and SPNs
Main attacksPass the hash, relay, cracking captured responsesKerberoasting, AS-REP roasting, ticket forgery
Domain controller events47764768, 4769, 4771

Windows uses Kerberos whenever it can and falls back to NTLM when it cannot: when a computer is addressed by IP address instead of name, when either side is outside the domain, when the account is local, or when an application asks for NTLM explicitly. The fallback is silent, which is why NTLM traffic often persists in domains that believe they no longer use it.

NT hashes and Net-NTLM responses: not the same thing

Two kinds of value are loosely called "NTLM hashes", and the difference decides what an attacker can do with them:

ValueWhere it livesWhat an attacker can do with it
NT hash (often called the NTLM hash)The SAM on each computer for local accounts; NTDS.dit on domain controllers; LSASS memory while a user is logged onUse it directly to authenticate (pass the hash), or crack it to recover the password
Net-NTLMv1 or Net-NTLMv2 responseOn the network, inside an authentication exchangeRelay it in real time to another server, or crack it offline; it cannot be passed directly

So a report that says "NTLM hashes were captured" needs a second sentence. Captured responses from name-resolution poisoning are a cracking risk that depends on password strength. Dumped NT hashes from a domain controller or a workstation's memory are equivalent to the passwords themselves for every account involved, and every one of those accounts needs a reset.

How attackers abuse NTLM

  • Pass the hash. With an NT hash stolen from memory or the SAM, an attacker authenticates as that account to any system that accepts NTLM. A local administrator account with the same password on many machines turns one stolen hash into access to all of them.
  • NTLM relay. An attacker who receives an NTLM authentication (by tricking a user or a server into connecting to them) forwards it to another server and is logged on there as the victim. Coercion techniques that make servers, including domain controllers, authenticate to an attacker-chosen address have made relay one of the most effective attacks on Active Directory. SMB signing, LDAP signing and channel binding, and Extended Protection for Authentication block most relays.
  • Capturing and cracking responses. Poisoning name resolution protocols such as LLMNR and NBT-NS on a local network makes nearby computers send NTLM responses to the attacker, who cracks weak passwords offline.
  • Password guessing. NTLM over SMB is a common channel for password spraying against local and domain accounts.

Investigating NTLM activity

NTLM leaves records on the computer that was accessed and, for domain accounts, on the domain controller that validated the response:

RecordWhereWhat it shows
4624 with Authentication Package NTLMComputer accessedSuccessful NTLM logon; Package Name shows NTLM V1 or V2; Workstation Name and source address show the client
4625Computer accessedFailed attempts with a status code
4776Domain controller, or the computer for local accountsCredential validation, with the client workstation name and an error code on failure
NTLM operational logClients, servers and DCs where NTLM auditing is enabledWhich applications and servers still use NTLM, before restricting it

Signs of pass the hash: NTLM network logons (type 3) by a privileged or local administrator account, from a workstation where that account is not used, often to several hosts in a short time. Some tools also create a type 9 (NewCredentials) logon on the source machine. Signs of relay: a successful NTLM logon whose Workstation Name does not match the source address, or a server or domain controller computer account authenticating with NTLM to a host it never talks to.

Remember that the workstation name in NTLM events is supplied by the client. Attackers can set it to anything, so trust the source address and correlate with the source host's own logs.

Reading NTLM failure codes

Failed NTLM validations in 4776 and failed logons in 4625 carry a status code that says why the attempt failed. The common ones tell guessing apart from misconfiguration:

CodeMeaningUsually indicates
0xC0000064User name does not existGuessing user names, or a stale script or mapped drive
0xC000006ACorrect user name, wrong passwordPassword guessing against a real account, or an old saved password
0xC0000234Account locked outGuessing has already triggered the lockout policy
0xC0000072Account disabledAn attempt to use a disabled account, often a former employee's
0xC000006FLogon outside permitted hoursAccount restrictions working as intended
0xC0000071, 0xC0000224Password expired, or must be changedUsually benign; a service with an expired password
0xC0000193Account expiredA contractor or temporary account used after its end date

Many 0xC0000064 failures from one source mean someone is trying names; many 0xC000006A failures against a few real accounts mean someone knows the names and is guessing passwords. Both patterns are covered in more detail in the password spraying guide.

In a real investigation: local accounts mean NTLM

In our Halden Freight lab case the attacker guessed the password of a.berg, a local account on the workstation HF-WS01, with 35 failed network logons from 10.211.55.2 between 22:02:58 and 22:04:20 UTC, then logged on over the network at 22:05:03. Local accounts cannot use Kerberos, so every one of those attempts was NTLM, checked against HF-WS01's own SAM. The same applied later when the attacker used the local account svc_backup to connect from the second workstation back to HF-WS01. On standalone or workgroup machines, NTLM is not a fallback but the only option, and the failed and successful logon events on the target are the whole record.

Scoping an NTLM credential compromise

When an investigation finds pass the hash or relay, the next questions decide how big the incident is:

  • Whose hashes were exposed? Every account logged on to a host where credentials were dumped, every local account in a stolen SAM, or every account in the domain if NTDS.dit or DCSync was involved.
  • Where else does each hash work? A local administrator password reused across machines makes one hash a key to all of them. Domain account hashes work anywhere the account has rights.
  • Where was each one used? Search NTLM logons (4624 with Authentication Package NTLM) and 4776 validations for each exposed account across every host and domain controller, from the time of the theft onwards.
  • What must be reset, and in what order? Reset exposed accounts together, privileged and service accounts first, and give local administrator accounts unique passwords before reconnecting hosts.

How to reduce NTLM

  • Audit first. Enable the "Network security: Restrict NTLM" audit policies to log NTLM use without blocking it, and review which servers, applications and accounts depend on it.
  • Remove NTLMv1 and LM. Set "Network security: LAN Manager authentication level" to send NTLMv2 responses only and refuse LM and NTLMv1.
  • Protect against relay. Require SMB signing, LDAP signing and channel binding, and enable Extended Protection for Authentication on web services that accept Windows authentication.
  • Fix the causes of fallback. Use host names instead of IP addresses, register service principal names, and replace applications that require NTLM.
  • Make local accounts unique. A solution such as LAPS gives each machine a different local administrator password, which limits what one stolen hash can reach.
  • Block gradually. Restrict NTLM for specific servers or the domain once audit shows what would break, with exceptions for what cannot yet be moved.

Finding NTLM logons in Arcsentry

This AQL query on the Security log lists successful network logons that used NTLM, by account and source, the first view for pass-the-hash and relay questions:

filter event_code == "4624" && event_log_logon_type == "3 - NETWORK"
derive {pkg = event_log_logon_auth_package, ver = $lmpackagename, ws = source_domain}
filter pkg ~= "(?i)ntlm"
group {user_target_name, source_ip, ver} (aggregate {n = count this})
sort {-n}

The AI investigator checks the same records when it traces lateral movement, and treats an NTLM logon by an administrator from an unusual workstation as a lead to follow on the source host.

Artifacts that record NTLM

Arcsentry reads these from every collected host:

ArtifactWhat Arcsentry extracts
Windows Event LogsParses Windows Event Log (.evtx) files.
SAM UsersLocal user accounts from the SAM hive with RIDs, login counts, timestamps, and decrypted NT/LM hashes when a SYSTEM hive is available; damaged account strings are omitted and recorded without losing other accounts.

Frequently asked

What is NTLM?

NT LAN Manager, Microsoft's challenge-response authentication protocol. The client proves it knows a password by answering the server's challenge with a value derived from the password hash. It is still used when Kerberos is not available.

Is NTLM obsolete?

It is deprecated. Microsoft announced in 2024 that all NTLM versions are deprecated, and NTLMv1 has been removed from Windows 11 version 24H2 and Windows Server 2025. NTLMv2 still works and remains common.

Which is better, Kerberos or NTLM?

Kerberos. It supports mutual authentication, does not need the domain controller for every logon, and is not open to pass-the-hash and relay in the same way. NTLM remains only for compatibility.

Is Kerberos still used today?

Yes. Kerberos is the default authentication protocol in every Active Directory domain, and Microsoft is extending it to cover the cases that still fall back to NTLM.

How do I disable NTLM?

Audit first with the "Network security: Restrict NTLM" policies, remove NTLMv1 and LM, fix applications and connections that fall back to NTLM, then restrict NTLM for specific servers or the whole domain, with exceptions where needed.

What is an NTLM hash?

Usually the NT hash: the MD4 hash of a user's password that Windows stores in the SAM or Active Directory and uses to compute NTLM responses. Because it can be used to authenticate directly, a stolen NT hash is as sensitive as the password.

How do I detect pass the hash?

Look for NTLM network logons (4624 type 3 with Authentication Package NTLM) by administrator or local admin accounts from workstations where they are not normally used, often to several hosts in quick succession, and for 4776 events on domain controllers from those workstations.

Sources

  • Microsoft Learn: NTLM overview; NTLM user authentication; Network security: Restrict NTLM policies
  • Microsoft: Deprecated features in the Windows client (NTLM, 2024)
  • MITRE ATT&CK: T1550.002 Pass the Hash; T1557.001 LLMNR/NBT-NS Poisoning and SMB Relay
  • Venema Labs lab case: Halden Freight office intrusion

Checked 2 December 2026 by Venema Labs. Parser coverage is generated from the Arcsentry build the artifact library describes.

Trace every NTLM logon across your hosts

Tell us what you want to investigate. A person replies within one business day with the download and a trial licence.

Request a trial