204 words
1 minutes
NTLM Authentication

NTLM Authentication#

Hash Types vs Protocols

Hash TypeUsed InHashing AlgorithmSecurityNotes
LMNTLM, NTLMv1 (historical)Two DES chunks of uppercase passwordVery weakEasy to crack, limited charset, split into 7-char chunks
NT Hash (aka NTLM hash)NTLM, NTLMv1, NTLMv2MD4(UTF-16-LE(password))Weak to brute-forceStill widely used, used in pass-the-hash attacks
MSCache2Offline LoginMD4 + PBKDF2 (10240 iterations)BetterUsed for cached domain credentials

Authentication Protocol Comparison

ProtocolMutual Auth?Hash UsedSecurity LevelVulnerabilities
NTLMNoLM / NT HashWeakPass-the-hash, relay attacks
NTLMv1NoLM + NTVery weakEasily cracked, no server integrity
NTLMv2NoNT HashBetter than v1Still lacks mutual auth, vulnerable to relay
KerberosYesTicket-basedStrongestMore secure, but complex setup

Important Concepts#

  • NTLM (Basic): Uses a 3-message challenge-response protocol. Still used in fallback scenarios. Susceptible to pass-the-hash.
  • NTLMv1: Challenge-response using DES encryption and the NT/LM hash. Weak, deprecated.
  • NTLMv2: Uses HMAC-MD5 and client/server challenges. Stronger than v1, but still lacks true mutual authentication.
  • Kerberos: Preferred in domain environments. Uses tickets and supports mutual auth, time-based access, and encryption.

Security Tools & Attacks#

  • Hashcat: Used to brute-force or dictionary attack LM and NT hashes offline.
  • CrackMapExec: Used for pass-the-hash attacks (especially NTLM).
  • Responder / NTLMRelayX: Tools for capturing and relaying NTLM credentials on networks.

Key Security Takeaways#

  • Disable LM hashes via Group Policy — they’re too weak.
  • Avoid NTLMv1 entirely — very outdated and insecure.
  • Restrict NTLMv2 usage and enforce Kerberos wherever possible.
  • Monitor for pass-the-hash attacks — NTLM hashes are reusable without cracking.
  • Use strong, long passwords — helps prevent hash cracking.
NTLM Authentication
https://fuwari.vercel.app/posts/ntlm-authentication/
Author
Ranjung Yeshi Norbu
Published at
2025-04-20