NTLM and Kerberos Explained with Diagrams — Why Authentication Falls Back to NTLM

· · NTLM, Kerberos, Windows, Active Directory, Security, Authentication, Information Systems

Even on a corporate network described as “a Kerberos environment”, auditing always turns up NTLM. And what turns up is usually an application that is supposed to support Kerberos.

Why that happens becomes obvious the moment you put the two protocols side by side and ask what each is trying to prove. This article covers how NTLM and Kerberos behave, with diagrams, then under what conditions authentication falls back to NTLM and why Microsoft is trying to get rid of NTLM — all backed by the official documentation.

The procedure for inventorying your own estate (configuring audit policies, following the events, the order in which to fix things) is set out in the companion article “Will NTLM Deprecation Stop Your Business Apps? — How to Collect Audit Logs, and the Order in Which to Kill Dependencies”.

1. The Bottom Line First

  • NTLM proves only that you hold the password hash. The credentials are a one-way hash of the domain name, user name, and password,1 and in NTLMv2 — what today’s Windows uses — a key derived from that hash is used to compute an HMAC over “the server challenge + a timestamp + a client-side challenge + target information” (Section 2.2).2
  • Kerberos proves “who, to which service”. Tickets are issued keyed on the destination service name (the SPN), so a ticket for a different destination cannot be used.3
  • There are three decisive differences: whether there is mutual authentication, whether (for domain-account authentication) the server queries a domain controller, and whether delegation is possible. Microsoft states all three explicitly (Section 5).4
  • The biggest reason for falling back to NTLM is “names”. Kerberos cannot begin unless an SPN can be resolved from the destination name. Hard-coded IP addresses, unregistered SPNs, workgroups, and routes that cannot reach a DC are the four main factors (Section 6).56
  • Relay attacks work because NTLM has no mechanism binding “who you are authenticating to”. Pass-the-Hash works because what authentication needs is the hash itself (Section 7).71
  • NTLMv1 has already been removed. Windows 11 version 24H2 and Windows Server 2025 are the versions concerned. NTLMv2 is deprecated but still works (Section 8).8
  • What applications should write is Negotiate. Negotiate selects either Kerberos or NTLM, and selects Kerberos unless one of the systems involved in the authentication cannot use it.1

2. What NTLM Actually Does

NTLM (Windows Challenge/Response) is, as the name says, a challenge/response authentication protocol. Summarising Microsoft’s description: the credentials consist of a one-way hash of the domain name, user name, and password obtained at interactive logon, and in order to authenticate without sending the password over the wire, the party requesting authentication performs a computation that proves it “can access the securely stored NTLM credentials”.1

The important point here is that the material for authentication is not the password itself but the hash of the password. That single fact is what makes Pass-the-Hash possible, as we will see later.

2.1. With a Domain Account, Three Parties Are Involved

When an already-logged-on user accesses a resource on a server using a domain account (non-interactive authentication), three parties are involved: the client, the server, and the domain controller. The distinctive part is that the server itself does not perform the authentication computation — it has the domain controller do it on its behalf.1

Domain controllerServerClientDomain controllerServerClientAt logon, hashes the passwordand discards the password itselfEncrypts the challengewith the password hashRetrieves the hash from the SAMand performs the same computationUser name (plaintext)18-byte random number (challenge)2Response3User name / challenge / response4If they match, authentication succeeds5Access granted6

Figure 1: NTLM non-interactive authentication (with a domain account)

The procedure Microsoft presents conceptually is as follows (the actual computation changes with NTLMv2, as described below, but the cast and the division of labour are exactly as in the diagram).1

  1. (Interactive authentication only) The user enters a domain name, user name, and password. The client computes a cryptographic hash of the password and discards the actual password.
  2. The client sends the user name to the server in plaintext.
  3. The server generates an 8-byte random number (the challenge, a nonce) and sends it to the client.
  4. The client encrypts this challenge with the hash of the user’s password and returns the result (the response).
  5. The server sends three things to the domain controller: the user name, the challenge it sent the client, and the response it received.
  6. The domain controller looks up the password hash for that user name in the SAM database and encrypts the challenge with it.
  7. It compares its own result with the client’s response; if they are identical, authentication succeeds.

2.2. The Real Computation — NTLMv2 Is a Bit More Involved

The seven steps above are the basic form described on Microsoft’s overview page. NTLMv2, which today’s Windows actually uses, is one step more complex than “encrypt the challenge with the password hash”. The specification ([MS-NLMP]) defines it as follows.2

  • The response key is NTOWFv2 = HMAC_MD5( MD4(UNICODE(password)), uppercased user name + domain name )
  • The client builds temp by concatenating the response version, a timestamp, an 8-byte challenge generated on the client side, and target information (AV pairs)
  • The core of the response is NTProofStr = HMAC_MD5( response key, server challenge + temp )

In other words, what is actually computed is an HMAC that mixes in not only the server challenge but also a client-side random value, a timestamp, and destination information. The verifying side reproduces the same computation. If the account is in Active Directory, the challenge/response pair is sent to a domain controller for verification; if the account is local to the server, the server computes the expected value using the OWF it stores itself.2

What matters for the discussion in this article is that even with the added complexity, two things do not change.

  1. The key material is still the password hash. The starting point of NTOWFv2 is MD4(UNICODE(password)) — the NT hash itself.2 That is why Pass-the-Hash works (Section 7.2).
  2. The client does not verify that the server is genuine. Microsoft’s statement that NTLM has no mutual authentication holds for NTLMv2 too.4

Everything that follows rests on those two points.

2.3. With a Local Account, Two Parties Suffice

With a local account, the right-hand side of the diagram disappears. A resource server queries the authentication service on a domain controller for that account’s domain if the account is a domain account, but consults its local account database if the account is local.9 So on a workgroup machine, or when connecting to a share with a local account on a file server, no domain controller appears: it is a two-party exchange in which the server looks at its own SAM and decides for itself.

This distinction feeds directly into the inventory of “Kerberos is unavailable because it’s a local account” dependencies discussed in Section 6.3. NTLM on this route does not show up in the domain controllers’ audit logs at all.

2.4. Three Consequences of This Design

Look at Figure 1 and you can read off the properties that become a problem later.

  • The server proves nothing to the client. The exchange is one-way, with no step anywhere in which the server shows that “I am genuine”.
  • The server can only decide when it holds the hash itself. Each time it needs a new access token, a resource server must query the authentication service on a domain controller for a domain account, or consult its local account database for a local account.9 That is why authentication with domain accounts is dependent on a domain controller.
  • The response is “for that challenge only”, but it does not bind the destination. Because the challenge differs every time, the same response cannot be reused. But there is no element proving “which server this response is for”, so it can be passed on to a different server without anyone noticing.

3. Why the Server Asks a Domain Controller

When authenticating a domain account, the only thing holding the password hash is the account database on the domain controller side. The resource server does not know that user’s hash, so it cannot verify it on its own. Hence it must query a domain controller every time it authenticates (pass-through authentication).91 (With a local account, the server consults its own SAM and decides for itself. Everything below about dependency on a domain controller applies to domain accounts.)

This has costs both in security and in operations. Microsoft explains that with pre-Kerberos NTLM authentication an application server had to connect to a domain controller every time it authenticated a client or a service, whereas with Kerberos renewable session tickets replace pass-through authentication and the server does not need to go to a domain controller except when PAC (privilege attribute certificate) validation is required.4

So migrating to Kerberos is, at the same time as being a security matter, a matter of reducing dependency on domain controllers.

4. What Kerberos Actually Does

Kerberos starts from a distinctly different idea. Rather than redoing identity verification on every authentication, you verify identity once at the outset, receive a “ticket”, and present that ticket thereafter.

The KDC (Key Distribution Center) runs on a domain controller and uses the Active Directory Domain Services database as its security account database.4

Service (identified by SPN)KDC (domain controller)ClientService (identified by SPN)KDC (domain controller)ClientAS exchange — prove identity and get a TGTIf it decrypts with the long-term key, it is themTGS exchange — get a service ticketLooks up the service account from the SPNand encrypts the ticket with its long-term keyAP exchange — present it to the serviceDecrypts with its own long-term key= the ticket is addressed to itKRB_AS_REQ(user name + timestamp encrypted with long-term key)1KRB_AS_REPTGT (encrypted with krbtgt's key) + session key2KRB_TGS_REQ(TGT + destination SPN + authenticator)3KRB_TGS_REPservice ticket + session key4KRB_AP_REQ(service ticket + authenticator)5KRB_AP_REP (if mutual authentication was requested)6

Figure 2: The three Kerberos exchanges (AS / TGS / AP)

4.1. The AS Exchange — Proving Identity Once

The client sends the KDC its user name and domain name, plus a timestamp encrypted with its own long-term key (the key derived from the password). This is pre-authentication. If the KDC can decrypt it with that long-term key and the timestamp is valid, it concludes “this is them”.3

The KDC returns a TGT (ticket-granting ticket). The TGT is encrypted with the KDC’s own long-term key (the krbtgt account’s key), so the client cannot read its contents. Along with it, a session key for use between the client and the KDC is handed over, encrypted with the client’s long-term key.3

The thing to hold on to here is that the timestamp is part of the authentication. That is why Kerberos is strict about time synchronisation; the default tolerated skew is five minutes.10 Exceed it and pre-authentication fails, so Kerberos authentication itself fails with an error (Windows time synchronisation is covered in “A Guide to Windows Time Synchronisation (w32time)”). “Kerberos fails” and “it falls back to NTLM” are two different things. The distinction is covered in Section 6.5.

4.2. The TGS Exchange — Declaring Which Service You Are Connecting To

This is the decisive divergence from NTLM. The client tells the KDC the name of the service it wants to connect to (the SPN) and requests a service ticket, attaching the TGT and an authenticator.3

The KDC finds the service account corresponding to that SPN and returns a service ticket encrypted with that account’s long-term key.3 Therefore:

  • If the SPN cannot be resolved, no ticket is issued. If no SPN is registered on the service account, the KDC cannot identify the peer. The same applies when the destination is specified as an IP address — by default Kerberos is not even attempted (Section 6.1).
  • A ticket is “for that destination only”. It cannot be decrypted with another service’s long-term key, so it cannot be reused against a different destination.

4.3. The AP Exchange — Presenting to the Service, and Mutual Authentication

The client presents the service ticket and an authenticator to the service. The service decrypts the ticket with its own long-term key and extracts the session key and authorisation information inside. The fact that it decrypted at all is proof that “this ticket is addressed to me”.3

If the client requested mutual authentication, the service encrypts the timestamp it received with the session key and returns it. By verifying that, the client can confirm that the peer is the genuine service.3 There is no such step in NTLM.

5. The Decisive Differences

Aspect NTLM Kerberos
Verifying the peer A client cannot verify a server, nor one server another server. Designed assuming servers are genuine4 Either end of a connection can verify that the other is who it claims to be4
DC query on every authentication Required for domain accounts. The resource server queries a DC for each new access token (for a local account it consults its own account database)9 Not required (except when PAC validation is needed). Renewable session tickets replace it4
Binding to a destination None. The response does not prove “to whom” Yes. A service ticket is encrypted with the destination service’s long-term key3
Delegation Provides only the authorisation information needed for local impersonation4 Supports delegation, where a service connects to another service on the client’s behalf4
Time synchronisation Not dependent Dependent (default tolerance is five minutes)10
Name resolution Indifferent to the peer’s name (works with an IP address) Requires that an SPN can be resolved3
Use outside a domain Still required in workgroup configurations and local logon9 Presupposes Active Directory4

The bottom two rows of this table are, directly, “the reasons authentication falls back to NTLM”. Kerberos’s strengths (binding the destination, verifying the peer) rest on names being resolvable correctly.

6. Why Authentication “Falls Back” to NTLM

Even when an application does not specify NTLM directly, NTLM gets used — because that is how Negotiate behaves. As Microsoft explains, Negotiate selects either Kerberos or NTLM, and selects Kerberos unless one of the systems involved in the authentication cannot use it.1

In other words, “it became NTLM” is, in most cases, another way of saying “Kerberos could not be used”.

No(workgroup / local account)YesNo(hard-coded IP address)YesNo(SPN not registered / access via alias)YesNo(site / VPN / firewall)YesAuthentication starts with NegotiateA domainaccount?Can an SPN be builtfrom the destination name?Is that SPNregistered?Can we reachthe KDC?Authenticate with KerberosFall back to NTLM

Figure 3: The branches by which Negotiate falls back to NTLM

6.1. You’re Connecting by IP Address

This is the most common cause. Microsoft states explicitly that by default, when the host name is an IP address, Windows does not attempt Kerberos authentication against that host and falls back to another valid authentication protocol such as NTLM.11 The audit guidance says the same from its side: Kerberos is not used if the “Target Server” in event 8001 is in neither NetBIOS nor FQDN form.5

And the reasons this happens are listed too: applications that use IP addresses rather than DNS names because of a misconfiguration or the vendor’s documentation.5 In practice we very often see settings rewritten to an IP in the past “because name resolution was flaky” and never reverted.

That said, this is the default behaviour, not an absolute constraint. From Windows 10 version 1507 and Windows Server 2016 onwards there is a mechanism for using IP addresses as SPN host names. Set the client-side registry value TryIPSPN to 1 and manually register an SPN for the IP address in the form Setspn -s <service class>/<IP address> <account>, and Kerberos will work even against an IP address. What you register is the service class the client actually requests: things that map to HOST, such as shared folders, are covered by host/192.168.1.1, but the web needs HTTP/192.168.1.1 and SQL Server needs a different SPN including the port, such as MSSQLSvc/192.168.1.1:1433. Registering only host/ will not match the requested SPN, and Kerberos will not work. Microsoft positions this feature precisely as a means of reducing the impact of disabling NTLM.11

Even so, it is not the first choice. Microsoft itself says IP addresses are transient and can cause conflicts and authentication failures as leases expire and renew, so they should not normally be used in place of host names, and that IP-address-based SPN registration is manual work to be used only when switching to a DNS-based host name is impossible.11 For hard-coded IP addresses found in an audit, think first about changing them to FQDNs. TryIPSPN is the last resort for peers where that is genuinely impossible.

6.2. No SPN Is Registered

This is the second most common cause. Microsoft lists applications whose SPN is not correctly configured as a category of application that uses NTLM even though it supports Kerberos.5

As we saw in the TGS exchange in Figure 2, the KDC looks up the service account from the SPN and encrypts the ticket with it. With no SPN, the KDC cannot identify “that service’s key”. The same thing happens when access uses a DNS alias (CNAME) or a custom host name and no SPN is registered for that name. The application is working perfectly well; only the name is missing from the register.

6.3. You’re Outside Active Directory to Begin With

Machines in a workgroup configuration, and share access with local accounts, are not on the Kerberos playing field at all. Microsoft states that NTLM is, and must be, used for Windows authentication on systems configured as members of a workgroup and for local logon authentication on non-domain controllers.9

That is why NTLM cannot simply be banned. The local KDC planned for phase 2 is precisely the feature intended to fill this hole.6 But assume that it only fills it between supporting Windows systems. Local-account authentication where the peer is an older Windows machine, or a third-party device such as a NAS or an MFP, will not automatically become Kerberos when the local KDC arrives. This sorting is handled in Sections 5 and 6 of the practical companion article.

6.4. You Can’t Reach the KDC

Fallback also happens for routing reasons — a branch office or VPN link that cannot reach a domain controller, or a firewall blocking the ports Kerberos needs.6 Without being able to talk to the KDC there is no way to obtain a ticket, so Negotiate picks the remaining option, NTLM.

6.5. Don’t Confuse “Kerberos Failed” With “It Fell Back to NTLM”

Finally, let’s separate out something confusingly similar but quite different. Sections 6.1 to 6.4 are all cases where Kerberos could not be started. Because it cannot be started, Negotiate chooses NTLM.

The case where Kerberos was chosen and then failed is a different story. The classic example is clock skew. If the SPN resolves and the KDC is reachable, Negotiate will pick Kerberos first. If the clock is then off by more than the tolerance (five minutes by default), pre-authentication does not pass and it fails as a Kerberos error.10 The fact that the chosen protocol failed does not mean Negotiate automatically switches to NTLM and retries (except where the application explicitly retries with a different method).

The practical implication is simple. You will not find a clock-skew failure by hunting for event 8001. The symptoms differ too.

Symptom What to suspect Where to look
It works, but authentication is NTLM Sections 6.1-6.4 (Kerberos was never started) Event 8001 in NTLM/Operational
Authentication itself fails with an error Clock skew, duplicate SPN registration, encryption type mismatch, and so on Kerberos events in the System log, klist, w32tm /query /status

Decide first whether “it fell back to NTLM” or “Kerberos is broken”, and investigate accordingly.

7. The Difference From an Attacker’s View — Relay and Pass-the-Hash

In its policy setting documentation, Microsoft states explicitly that NTLM and NTLMv2 authentication is vulnerable to a variety of malicious attacks, including SMB relay, man-in-the-middle attacks, and brute force attacks.7 Why that is so can be explained from Figure 1.

7.1. Relay Attacks — The Consequence of Not Binding the Destination

Real serverAttacker's serverVictim's PCReal serverAttacker's serverVictim's PCThe victim is lured to the attacker's serverCannot tell whether it camefrom the real serverIf it requires neither signingnor channel bindingStarts authentication (user name)1Starts authentication as the same user2Challenge3Forwards that challenge unchanged4Response (computed with the hash-derived key)5Forwards that response unchanged6Authentication succeeds → session established as the victim7

Figure 4: How an NTLM relay succeeds (against a peer with no signing or channel binding)

The attacker needs to know neither the password nor the hash. They simply pass the challenge and response from one side to the other. This works because the client has no way to check whether the response is really going to the intended peer.

That said, relaying does not get through to just anyone. Whether a relayed exchange turns into a usable session depends on the destination’s defences.

  • It does not get through to a peer that requires SMB signing. Microsoft states explicitly that the signature attached to every SMB message includes a hash of the whole message and confirms the identity of the sender and the receiver, thereby preventing relay attacks.12 Note that domain controllers require SMB signing from connecting clients by default.12
  • Nor does it get through to a service enforcing Extended Protection for Authentication (channel binding). Because authentication is bound to the underlying TLS channel, authentication relayed onto a different channel does not pass.

So what Figure 4 depicts is the path to success under the condition of a peer that accepts NTLM with neither signing nor channel binding. Turned around, that means there is something you can do right now in the field: it is worth checking the state of SMB signing requirements in parallel with the NTLM inventory.

With Kerberos, the same shape of relay is not possible in the first place. A service ticket is encrypted with the destination service’s long-term key, so it cannot be decrypted if taken to a different service.3 On top of that, the client can confirm whether the peer is genuine through mutual authentication.4

Microsoft’s reason for providing NTLM blocking on the SMB client is exactly this: the stated purpose is preventing techniques that get NTLM requests sent to malicious servers.13 On SMB signing, Microsoft also recommends using Kerberos rather than NTLMv2 so that the session key starts out strong, and not connecting to shares by IP address or CNAME record (because doing so causes NTLM to be used instead of Kerberos).12 That is the same story as Sections 6.1 and 6.2.

7.2. Pass-the-Hash — The Hash Is Equivalent to the Password

one-way hashderive response keyand compute HMACPasswordPassword hashResponseAuthentication succeedsSteal the hashfrom a machineThe plaintext passwordis not needed

Figure 5: What authentication needs is the hash, not the plaintext password

NTLM credentials are a one-way hash of the password.1 In NTLMv2, that MD4(UNICODE(password)) is used as the key to derive the response key, and that key is then used to compute an HMAC to build the response.2 The shape of the computation has changed, but the starting point is still the hash. That is, what authentication needs is the hash, not the plaintext password.

This has serious operational implications. Making passwords longer and more complex does not close the route by which the hash is stolen. Microsoft lists Pass-the-Hash alongside brute force and cracking as attacks that SMB NTLM blocking counters.13

Kerberos has long-term keys too, but what flies around during everyday authentication is time-limited tickets and session keys.3 The blast radius when they are stolen is different.

8. NTLMv1, NTLMv2, and “Removal”

NTLM is not a single protocol but a family of authentication protocols including LAN Manager versions 1 and 2 and NTLM versions 1 and 2.9

Their current status divides as follows.

Version Status What it means
LANMAN / NTLMv1 / NTLMv2 All deprecated (June 2024)8 Outside active feature development. But they still work in the next release of Windows Server and the next annual release of Windows
NTLMv1 Removed (Windows 11 24H2 / Windows Server 2025)8 Cannot be used on those versions

So it is not “we’re on NTLMv2, so we can leave it for now”. The priority is clear, however: devices and hosts that can only speak NTLMv1 come first. Hosts recorded with NTLM V1 in an audit will fail authentication if you upgrade them as-is to a newer Windows. How to tell the versions apart (looking at “Package Name (NTLM only)” in the Security log) is covered in Section 4.4 of the practical companion article.5

Note that the audit and block policies for restricting NTLM have the same effect on both NTLMv1 and NTLMv2.5 Behaviour does not vary by version when you apply restrictions.

9. What Happens Next

Microsoft has indicated three directions.

First, use Negotiate on the application side. The instruction to replace calls to NTLM with calls to Negotiate is part of the deprecation notice itself.8 It is also stated explicitly that applications should not access the NTLM security package directly.1

Second, reduce the situations that require NTLM in the first place. IAKerb and the local KDC, planned for phase 2 (second half of 2026), are this.6 They are an attempt to fill, at the protocol level, the two holes seen in Section 6.3 — “Kerberos is unavailable because it’s a local account” and “Kerberos is unavailable because the domain controller is unreachable”. But there is a limit to what gets filled. What IAKerb solves is reachability to a domain controller, not whether the peer supports anything. The local KDC likewise only works between supporting Windows systems. If the peer is a third-party NAS or MFP, waiting for phase 2 will change nothing, so you have to choose for yourself between replacing the device, joining the domain, switching to another protocol, or managing an exception.

Third, change the defaults. In phase 3, network NTLM authentication is planned to be disabled by default in the next major release.6 It is also stated, though, that it can be re-enabled by policy.

There is a reason for this order. Because it is “remove the reasons to use it, then change the default”, sorting the NTLM dependencies you have left into those you can expect phase 2 to solve (local-account authentication between supporting Windows systems, DC reachability) and those you must fix yourself (hard-coded IP addresses, unregistered SPNs, and local-account authentication where the peer is an older Windows machine or a third-party device) saves you from wasted work. Classify that last group as “waiting for phase 2” and it will surface as an outage when disabling by default arrives. The concrete sorting procedure is set out in the practical companion article.

10. Summary

  • NTLM is a protocol that proves “you hold the password hash” via challenge/response. The decision is delegated to a domain controller for domain accounts, and made by the server itself from its own SAM for local accounts.19
  • Kerberos proves “who, to which service”. A service ticket is encrypted with the destination service’s long-term key, so it cannot be reused against a different destination.3
  • The decisive differences are mutual authentication, the per-authentication DC query, and whether delegation is possible.4
  • Falling back to NTLM almost always means Kerberos could not be started. The four main causes are hard-coded IP addresses, unregistered SPNs, being outside Active Directory, and not reaching the KDC.5611
  • By contrast, problems where Kerberos was chosen and then failed — clock skew, for instance — appear as authentication errors, not as a fallback to NTLM. Hunting for event 8001 will not find them.10
  • Relay attacks work because an NTLM response does not bind the destination. Pass-the-Hash works because what authentication needs is the hash itself.7113
  • NTLMv1 has already been removed (Windows 11 24H2 / Windows Server 2025), and all versions including NTLMv2 are deprecated.8
  • What applications should write is Negotiate. On top of that, standardising destination names on FQDNs and registering SPNs is the practical substance of making Kerberos work.15

KomuraSoft LLC handles modification of Windows business applications arising from a review of authentication methods, and root-cause investigation of authentication problems around Kerberos and NTLM.

References

  1. Microsoft Learn, Microsoft NTLM. On NTLM being an authentication protocol called Windows Challenge/Response, and a security package that provides authentication, integrity, and confidentiality to applications; on NTLM credentials consisting of a one-way hash of the domain name, user name, and password obtained at interactive logon; on authenticating without sending the password over the wire by means of an encrypted challenge/response, with the party requesting authentication performing a computation proving it can access the securely stored NTLM credentials; on non-interactive authentication involving three parties — client, server, and domain controller; on the concrete steps (the client computes the password hash and discards the plaintext password, sends the user name in plaintext, the server generates and sends an 8-byte random number as the challenge, the client encrypts the challenge with the hash and returns the response, the server sends the user name, challenge, and response to a domain controller, and the domain controller performs the same computation with the hash from the SAM database and compares); and on applications not accessing the NTLM security package directly but using the Negotiate security package, which selects between Kerberos and NTLM and selects Kerberos unless one of the systems involved in the authentication cannot use it.  2 3 4 5 6 7 8 9 10 11 12 13

  2. Microsoft Learn, [MS-NLMP]: NTLM v2 Authentication. On the NTLM authentication version not being negotiated by the protocol but having to be configured on both client and server before authentication; on the NTLM v2 response key being defined as NTOWFv2(Passwd, User, UserDom) = HMAC_MD5( MD4(UNICODE(Passwd)), UNICODE(uppercased User + UserDom) ); on the client generating an 8-byte challenge; on temp being a concatenation of the response version, an 8-byte GMT timestamp, the client challenge, and ServerName (the AvPairs structure contained in the NTLMv2_CLIENT_CHALLENGE of the AUTHENTICATE_MESSAGE); on NTProofStr = HMAC_MD5( ResponseKeyNT, server challenge + temp ) and NtChallengeResponse being the concatenation of NTProofStr and temp; on SessionBaseKey = HMAC_MD5(ResponseKeyNT, NTProofStr); and on the verification side — where an account hosted in Active Directory has the challenge/response pair sent to a domain controller for verification, with the DC computing the expected value using NTOWF v2 / LMOWF v2 and comparing, and where the server returns STATUS_NOT_SUPPORTED if the DC returns STATUS_NTLM_BLOCKED, while an account hosted locally on the server has the server compute the expected value from the OWF it stores locally and compare.  2 3 4 5

  3. Microsoft Learn, How the Kerberos Version 5 Authentication Protocol Works. On the AS exchange, in which the client sends the KDC its user principal name, the account’s domain name, and pre-authentication data (including a timestamp) encrypted with the user’s long-term key (derived from the password), and the KDC decrypts and verifies with that long-term key before returning a TGT encrypted with the KDC’s own long-term key (the krbtgt account’s key) plus a session key encrypted with the user’s long-term key, with the TGT containing the session key, authorisation data (user SID and group SIDs), and lifetime and flags. On the TGS exchange, in which the client sends the KDC the target server name (SPN), the TGT, and an authenticator (containing a timestamp and checksum) encrypted with the session key, and the KDC decrypts the TGT with its own long-term key to extract the session key, verifies that the authenticator’s timestamp falls within the policy-defined range, and returns a service ticket encrypted with the target service’s long-term key plus a new session key encrypted with the TGS session key. On the client/server (AP) exchange, in which the client presents the service ticket and an authenticator to the service, and the service decrypts the ticket with its own long-term key to extract the session key and authorisation data, returning the client’s timestamp encrypted with the session key to prove its own identity when mutual authentication is requested. And on the difference between long-term keys and session keys (long-term keys are derived from passwords or service accounts and persist across sessions, while session keys are short-lived and destroyed with the ticket’s expiry).  2 3 4 5 6 7 8 9 10 11 12

  4. Microsoft Learn, Kerberos authentication overview in Windows Server. On Windows Server implementing the Kerberos version 5 authentication protocol along with extensions for public key authentication, transport of authorisation data, and delegation; on the Kerberos client being implemented as an SSP (security support provider) accessed through SSPI; on the KDC being integrated with the other security services on a domain controller and using the Active Directory Domain Services database as its security account database; on Kerberos supporting delegation by services (a front-end service connecting to back-end services on other computers using the client’s identity) while what NTLM and Kerberos provide is the authorisation information a service needs to impersonate a client locally; on pre-Kerberos NTLM authentication requiring an application server to connect to a domain controller each time it authenticated a client or service, whereas with Kerberos renewable session tickets replace pass-through authentication and the server does not need to go to a domain controller except when PAC validation is required; and, on mutual authentication, on Kerberos allowing either end of a network connection to verify that the other is who it claims to be, whereas NTLM allows neither a client to verify a server’s identity nor one server to verify another’s, having been designed for network environments where servers can be assumed genuine — an assumption Kerberos does not make.  2 3 4 5 6 7 8 9 10 11 12

  5. Microsoft Learn, Viewing events for assessing NTLM usage. On being able to determine whether the NTLM audit information in the event log relates to NTLM v1 or v2, by searching the Security log’s logon events for “Authentication Package” and looking at “Package Name (NTLM only)” under “Detailed Authentication Information”; on the audit and block policies for restricting NTLM having the same effect on both versions of NTLM; on the four categories of application that use NTLM even though they theoretically support Kerberos (applications that let you choose among various security configurations and providers, applications whose SPN is not correctly configured, applications that use IP addresses rather than DNS names because of misconfiguration or vendor documentation, and applications with NTLM-only parts in a legacy codebase); on the investigation procedure tracing from event 8004 on the domain controller to event 8003 on the member server and event 8001 on the client, and the fields of each event; on Kerberos not being used if the “Target Server” in event 8001 is in neither NetBIOS nor FQDN form; and on the PID always being 4 (SYSTEM) for traffic via SMB, so that Process Monitor is needed to identify the calling process.  2 3 4 5 6 7 8

  6. Microsoft Japan Windows Technology Support Blog, NTLM の廃止に向けた対応について. On NTLM retirement proceeding in three phases (phase 1 = making usage visible and auditing it; phase 2 = features for NTLM-dependent scenarios, planned for the second half of 2026; phase 3 = disabling network NTLM authentication by default in the next major release); on phase 2 being due to deliver IAKERB (a protocol supporting proxy functionality) and the local KDC (a feature supporting local authentication); on applications needing to use Negotiate; and on the representative causes of NTLM usage being server access specified by IP address, firewall restrictions on the ports Kerberos needs, unregistered SPNs, authentication to trusted partners, and authentication in workgroup environments.  2 3 4 5 6

  7. Microsoft Learn, Network security: Restrict NTLM: Outgoing NTLM traffic to remote servers. On the four values Allow all, Audit all, Deny all, and Not Defined; on the recommended procedure of selecting “Audit all” first, reviewing the operational log, and only then building an exception list; on audit and block events being recorded under “Applications and Services Logs\Microsoft\Windows\NTLM”; and on NTLM and NTLMv2 authentication being vulnerable to a variety of malicious attacks including SMB relay, man-in-the-middle, and brute force, so that reducing and eliminating NTLM authentication from the environment causes Windows to use more secure protocols such as Kerberos version 5 or other authentication mechanisms such as smart cards — with these attacks only being possible where servers or domain controllers process NTLM requests.  2 3

  8. Microsoft Learn, Deprecated features in the Windows client. On all versions of NTLM, including LANMAN, NTLMv1, and NTLMv2, being outside active feature development and deprecated (announced June 2024); on using NTLM continuing to work in the next release of Windows Server and the next annual release of Windows; on calls to NTLM needing to be replaced by calls to Negotiate, which attempts to authenticate with Kerberos and falls back to NTLM only when necessary; and on the November 2024 update stating that NTLMv1 has been removed from Windows 11 version 24H2 and Windows Server 2025. Also on the distinction between deprecated and removed — features on this list are not being actively developed and may be removed in a future update.  2 3 4 5

  9. Microsoft Learn, NTLM overview in Windows Server. On NTLM authentication being a family of authentication protocols contained in Msv1_0.dll, including LAN Manager versions 1 and 2 and NTLM versions 1 and 2; on it being a method of proving to a server or domain controller, via a challenge/response mechanism, that you know an account’s password; on a resource server needing, each time it requires a new access token, to query the authentication service on a domain controller in that account’s domain for a domain account, or to consult its local account database for a local account; on NTLM still being used and needing to be used for Windows authentication on systems configured as members of a workgroup and for local logon authentication on non-domain controllers; on Kerberos version 5 being the preferred authentication method in Active Directory environments, while Microsoft and non-Microsoft applications may still use NTLM; and on reducing NTLM usage requiring both an understanding of deployed applications’ requirements and configuration to use other protocols.  2 3 4 5 6 7 8

  10. Microsoft Learn, Registry entries about Kerberos protocol and Key Distribution Center (KDC) configuration. On the settings under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\Kerberos\Parameters. In particular, on SkewTime defaulting to five minutes as the maximum time difference tolerated between a client computer and the servers or KDC accepting Kerberos authentication, and this value also being used to decide whether a ticket can be reused; and on the SPN cache expiry (SpnCacheTimeout, 15 minutes by default) being used on clients and member servers to clean up negative cache entries for “SPN not found”, with the SPN cache disabled on domain controllers.  2 3 4

  11. Microsoft Learn, Configuring Kerberos for IP Address. On being able, from Windows 10 version 1507 and Windows Server 2016 onwards, to make the Kerberos client support IPv4/IPv6 host names in SPNs; on Windows by default not attempting Kerberos authentication against a host whose host name is an IP address, falling back to another valid authentication protocol such as NTLM; on applications hard-coding IP addresses therefore falling back to NTLM and potentially causing compatibility problems in environments that are disabling NTLM; on the feature to use IP addresses as SPN host names having been introduced to reduce that impact, enabled by setting the client-side registry value TryIPSPN (REG_DWORD, not present by default) under HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System\Kerberos\Parameters to 1, with the setting required on each client that needs to access Kerberos-protected resources by IP address; on the SPN format being service/hostname[:port]; and on IP addresses being transient and liable to cause conflicts and authentication failures as leases expire and renew, so they should not normally be used in place of host names, with IP-address-based SPN registration being manual work to be used only when switching to a DNS-based host name is impossible, registered with Setspn -s <service>/<ip.address> <domain-user-account> — and since an SPN can only be registered on one account at a time in Active Directory, static reservation of the IP address is recommended when DHCP is in use.  2 3 4

  12. Microsoft Learn, Overview of Server Message Block signing in Windows. On SMB signing attaching to every SMB message a signature generated with the session key and AES, with the signature containing, in addition to a hash of the whole message, the identities of the original sender and the intended receiver; on any tampering in transit failing to match the signature, thereby protecting against relay and impersonation attacks; on the security of SMB 2/3 signing and encryption depending on the session key, and the signature confirming the identities of sender and receiver so as to prevent relay attacks; on the session key being derived from the password, so long, complex, non-dictionary passwords are preferable; on Kerberos being recommended over NTLMv2 so that the session key starts out strong; on avoiding connecting to shares by IP address or CNAME record, since that causes NTLM to be used instead of Kerberos; on domain controllers requiring SMB signing by default from clients connecting to SYSVOL and NETLOGON, with client-side UNC Hardening further requiring Kerberos for those two shares; on signing also being used as part of pre-authentication integrity to prevent downgrade attacks; on the policy locations and the registry value (RequireSecuritySignature); and on the auditing available from Windows 11 version 24H2 onwards to detect peers that do not support signing or encryption (Set-SmbClientConfiguration -AuditServerDoesNotSupportSigning and similar, SMBClient/Audit 31998 and 31999, SMBServer/Audit 3021 and 3022).  2 3

  13. Microsoft Learn, Block NTLM connections on SMB in Windows Server 2025. On the SMB client being able to block NTLM authentication on outbound remote connections; on this preventing techniques that get NTLM requests sent to malicious servers and countering brute force, cracking, and Pass-the-Hash attacks; on Kerberos being more secure than NTLM because its ticket-based approach allows a server’s identity to be verified, and NTLM blocking being necessary for switching an organisation’s authentication protocol to Kerberos, while it is also possible to enable just this layer of protection without disabling NTLM entirely; on the prerequisites being an SMB client on Windows Server 2025 or later or Windows 11 version 24H2 or later, and an SMB server that can use Kerberos; and on this being a feature of the SMB client.  2 3

Recent articles sharing the same tags. Deepen your understanding with closely related topics.

These topic pages place the article in a broader service and decision context.

This article connects naturally to the following service pages.

Frequently Asked Questions

Common questions about the topic of this article.

What's the actual difference between NTLM and Kerberos?
The biggest difference is whether you can verify who you're talking to. Microsoft states explicitly that with NTLM a client cannot verify a server's identity, nor can one server verify another server's identity. NTLM was designed for environments where servers can be assumed genuine; Kerberos makes no such assumption. The second difference is whether the server has to query a domain controller. With NTLM, when authenticating a domain account, the application server connects to a domain controller every time it authenticates a client (for an account local to the server, the server consults its own account database and decides for itself, and no domain controller appears at all). With Kerberos, renewable session tickets replace this pass-through authentication, so the server does not go to a domain controller except when PAC validation is required. The third is that Kerberos supports delegation by services — a mechanism for connecting to another service on the client's behalf.
Why do we end up on NTLM when the application supposedly supports Kerberos?
Kerberos issues tickets keyed on "the name of the destination", so it cannot work if the name cannot be resolved. The client presents the destination's SPN (service principal name) to the KDC to request a service ticket, but by default Windows does not attempt Kerberos authentication when the host name is an IP address, and if no SPN is registered on the service account the KDC cannot issue a ticket. Microsoft's audit guidance likewise says that Kerberos is not used if the "Target Server" in event 8001 is in neither NetBIOS nor FQDN form. (For IP addresses, you can make Kerberos work as an exception by setting TryIPSPN on the client and manually registering an SPN for the IP address, but this is described as a last resort for cases where a DNS name is impossible.) Other conditions under which Kerberos cannot work are authentication on workgroup machines or with local accounts (outside Active Directory altogether), sites that cannot reach a domain controller, and authentication to a peer with no trust relationship. Negotiate chooses NTLM when Kerberos is unavailable, which is what "falling back" means in these cases.
What is an NTLM relay attack, and why does it work?
The attacker lures a victim to a server of their own and relays the NTLM authentication exchange that arrives there straight through to the real server, impersonating the victim. It works because NTLM's challenge/response has no mechanism binding "who you are authenticating to". The client simply computes a response from the challenge the server issued and returns it, with no way to check whether that response is destined for the real server or is being relayed by an attacker. Microsoft itself states in its policy setting documentation that NTLM and NTLMv2 authentication is vulnerable to a variety of malicious attacks, including SMB relay, man-in-the-middle attacks, and brute force attacks. That said, relaying does not get through to just anyone. If the destination requires SMB signing, the signature confirms the identity of the sender and receiver, so the relay fails; the same is true of services that enforce Extended Protection for Authentication (channel binding). Conversely, the targets are peers that accept NTLM with neither signing nor channel binding in place. With Kerberos, a service ticket is encrypted with that service's long-term key, so a ticket destined for one service cannot be decrypted by another.
Does Pass-the-Hash mean you can impersonate someone without cracking their password?
Exactly. NTLM credentials consist of a one-way hash of the domain name, user name, and password. In NTLMv2, which is what today's Windows uses, the response key is derived as an HMAC keyed on the MD4 hash of the password (the NT hash), and that key is then used to compute an HMAC over a bundle of the server challenge, a timestamp, a client-side challenge, and target information. It is not simply encrypting the challenge, but the starting point is still the password hash. In other words, what authentication needs is the hash, not the plaintext password. So an attacker who can extract the hash from, say, a machine's memory can authenticate as that user without cracking the password. Making passwords longer and more complex does not close this route. One of Microsoft's stated reasons for providing NTLM blocking on the SMB client is countering Pass-the-Hash attacks.
If we're using NTLMv2, aren't we safe for the time being?
NTLMv2 is stronger than NTLMv1, but it is not excluded from deprecation. Microsoft's list of deprecated features says that all versions of NTLM, including LANMAN, NTLMv1, and NTLMv2, are outside active feature development and deprecated. The restriction policies behave the same way: the audit and block policies are described as having the same effect on both versions. NTLMv1 is treated differently, however: it has moved past deprecation into removal, and has been removed from Windows 11 version 24H2 and Windows Server 2025. So the framing is not "we're on NTLMv2, so we can leave it" but "NTLMv1 is a deadline right now; NTLMv2 needs an inventory in preparation for being disabled by default".

Author Profile

Profile page for the article author.

Go Komura

Representative of KomuraSoft LLC

Focused on Windows software development, technical consulting, and investigations into failures that are difficult to reproduce.

Back to the Blog