Windows Authentication: NTLM and Kerberos
Understand how NTLM challenge-response and Kerberos ticket-granting work.
Windows Authentication: NTLM and Kerberos is a free Cyber Security Academy lesson on CoddyKit — lesson 1 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Cyber Security Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.
Windows Authentication Overview
Windows uses two primary authentication protocols: NTLM (older, challenge-response) and Kerberos (modern, ticket-based). Understanding both is essential for Active Directory attack and defense.
NTLM Challenge-Response
NTLM works in three messages: Negotiate, Challenge, Authenticate. The client hashes the user's password with the server's random challenge. The hash — not the plaintext — is transmitted.
# NTLM flow:
# 1. Client sends: NEGOTIATE
# 2. Server sends: CHALLENGE (8-byte nonce)
# 3. Client sends: NT hash of (password + nonce)
#
# The NT hash = MD4(UTF-16LE(password))Pass-the-Hash Attack Vector
Because NTLM authenticates with a hash, stealing a hash lets you authenticate without knowing the plaintext password. This is the core of Pass-the-Hash attacks — the hash IS the credential.
Kerberos Overview
Kerberos uses a trusted third party (KDC — Key Distribution Center) to issue tickets. It provides mutual authentication and avoids transmitting credentials over the network after initial TGT issuance.
# Kerberos components:
# KDC: Key Distribution Center (domain controller)
# AS: Authentication Service (issues TGTs)
# TGS: Ticket Granting Service (issues service tickets)
# TGT: Ticket Granting Ticket (proves identity)
# ST: Service Ticket (grants access to a service)Kerberos Authentication Flow
1. Client sends AS-REQ (encrypted with password hash) to AS. 2. AS returns TGT encrypted with krbtgt key. 3. Client presents TGT to TGS requesting service ticket. 4. Client presents service ticket to the target service.
Key Kerberos Tickets
TGT (Ticket Granting Ticket): proves identity to the KDC, valid ~10 hours. Service Ticket: grants access to a specific service. Both are encrypted with keys the client cannot read.
# View tickets on Windows:
klist
# View on Linux (with Kerberos client)
klist -v
# Request a TGT:
kinit username@DOMAIN.COMNTLM vs Kerberos: Security Comparison
Kerberos is preferred: supports mutual auth, avoids plaintext transmission, harder to relay. NTLM falls back when Kerberos fails (e.g., IP address access, non-domain hosts) — attackers force NTLM fallback to capture hashes.
NTLM Relay Attacks
NTLM relay intercepts an NTLM authentication attempt and relays it to another service, authenticating as the victim without knowing their password. Responder captures, ntlmrelayx relays.
# Capture NTLM hashes with Responder
responder -I eth0 -rdwv
# Relay with ntlmrelayx
ntlmrelayx.py -tf targets.txt -smb2supportKerberos Pre-Authentication
Pre-authentication requires the client to encrypt a timestamp with their password hash before receiving a TGT. Accounts without pre-auth required are vulnerable to AS-REP Roasting — their TGT can be requested and cracked offline.
Golden and Silver Tickets
Golden ticket: forged TGT signed with the krbtgt hash — grants access to everything. Silver ticket: forged service ticket for a specific service — more stealthy, doesn't touch the KDC.
Hardening Windows Authentication
Disable NTLM where possible, enforce SMB signing to prevent relay, require pre-authentication on all accounts, monitor for unusual ticket requests (Event ID 4768, 4769), and protect the krbtgt account.
Quick Check
What does the Kerberos TGT enable?
Summary: NTLM and Kerberos
NTLM authenticates via hash challenge-response — vulnerable to relay and pass-the-hash. Kerberos uses tickets issued by a trusted KDC — stronger, but vulnerable to Kerberoasting, AS-REP Roasting, and golden/silver ticket attacks when the KDC is compromised. Know both protocols to understand Active Directory attack paths and apply targeted hardening.
Frequently asked questions
Is the “Windows Authentication: NTLM and Kerberos” lesson free?
Yes — the full text of “Windows Authentication: NTLM and Kerberos” is free to read here on the web, and the Cyber Security Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Cyber Security Academy course, upgrade to CoddyKit PRO.
What will I learn in “Windows Authentication: NTLM and Kerberos”?
Understand how NTLM challenge-response and Kerberos ticket-granting work. You practise Cyber Security Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.
Do I need any experience to start Cyber Security Academy?
No prior experience is required. Cyber Security Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 1 of 4, so you can start here or from the beginning and move at your own pace.
How long does the “Windows Authentication: NTLM and Kerberos” lesson take?
Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.
Can I write and run code in this Cyber Security Academy lesson?
Yes. Every Cyber Security Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.
All lessons in this course
- Windows Authentication: NTLM and Kerberos
- Pass-the-Hash and Pass-the-Ticket Attacks
- Kerberoasting and AS-REP Roasting
- Active Directory Hardening