Privilege Escalation Checklist
Initial Enumeration
# System information
uname -a
cat /etc/os-release
cat /proc/version
lscpu
# User information
id
whoami
sudo -l
cat /etc/passwd | grep -v nologin | grep -v false
cat /etc/shadow # If readable
cat /etc/group
history
env
# Network information
ifconfig -a || ip a
route || ip route
netstat -antup || ss -tunlp
iptables -L
cat /etc/hosts
cat /etc/resolv.conf
# Running processes
ps aux
ps -ef
pstree
# Installed packages and services
dpkg -l # Debian-based
rpm -qa # Red Hat-based
service --status-all
systemctl list-unit-files
ls -la /etc/init.d/
# Find world-writable directories and files
find / -writable -type d 2>/dev/null
find / -writable -type f 2>/dev/null
find / -writable -type f -not -path "/proc/*" -not -path "/sys/*" 2>/dev/null
# Find world-executable files
find / -perm -o+x -type f 2>/dev/nullSUID/SGID Binaries
Exploiting Common SUID Binaries
Using base64 with SUID to read protected files
If base64 has the SUID bit set, it can be exploited to read files that require elevated privileges:
Other common SUID exploitation techniques
Sudo Rights
Capabilities
Cron Jobs
PATH Manipulation
NFS Shares
Kernel Exploits
Passwords and Sensitive Files
Finding Files
Automated Tools (If Available)
Step-by-Step Methodology
Collect system information (OS, kernel, hardware)
Check current user privileges and groups
Look for SUID/SGID binaries
Check sudo privileges (
sudo -l)Check for capabilities
Examine cron jobs
Inspect PATH for opportunities
Look for NFS shares with no_root_squash
Check for sensitive files with passwords
Hunt for world-writable files and directories
Look for unusual services or processes
If possible, run automated enumeration tools
Consider kernel exploits as a last resort
Common Exploits by Binary
SUID Binaries to Look For
Sudo Commands to Look For
File Transfer Methods
Last updated