Windows Access Tokens are the core of Windows security. Every process runs with a token that defines its identity and privileges. Token manipulation attacks allow us to "borrow" or "steal" tokens from other processes, running our code with their identity.
Think of tokens like security badges. Your badge determines which doors you can open and what actions you can perform. If you can clone or borrow a SYSTEM badge, you get SYSTEM access. Token impersonation is the art of badge cloning.
Foundation for Potato Attacks
Understanding tokens is essential for . These attacks exploit token impersonation privileges to escalate to SYSTEM.
Related
Potato attacks
What Are Access Tokens?
Impersonation Levels
Dangerous Token Privileges
Privileges That Lead to SYSTEM
SeImpersonate = Likely SYSTEM
If you see SeImpersonatePrivilege enabled, you're very likely one Potato attack away from SYSTEM. This is extremely common on web servers (IIS) and database servers (SQL Server).
Token Stealing Concepts
Service Account Tokens
Checking Token Information
Token Impersonation Overview
Token Enumeration Methodology
Token Analysis Flow
1
Check Privilegeswhoami /priv - look for dangerous privileges
2
SeImpersonate?If yes, proceed to Potato attacks
3
SeDebug?If yes, can dump lsass or steal tokens
4
SeBackup?If yes, can read SAM/SYSTEM hives
5
Service AccountCheck if running as service account
6
Choose AttackSelect appropriate technique for privileges
Knowledge Check
Challenges
Key Takeaways
- Tokens define process/thread identity and privileges
- SeImpersonatePrivilege enables Potato attacks → SYSTEM
- Service accounts often have impersonation privileges
- Always check whoami /priv for escalation paths
- Web servers and DB servers are common targets
- Token theft requires understanding impersonation levels