Privilege Escalation · Term

What are linPEAS and winPEAS?

linPEAS and winPEAS are scripts that automatically scan a Linux or Windows host for privilege-escalation paths and highlight the most promising ones. Here is what they do and why defenders should run them too.

Privilege Escalation · TermAll services
TL;DR

linPEAS and winPEAS are open-source privilege-escalation enumeration scripts (part of the PEASS-ng project) that automatically check a Linux or Windows host for escalation paths, SUID binaries, sudo rules, capabilities, and writable files on Linux; privileges, services, and registry settings on Windows, and colour-highlight the most promising findings. They save an attacker hours of manual enumeration, and defenders run the same scripts to find and fix those paths first.

By John Dill, Red Team Lead, SecureLayer7Updated

What linPEAS and winPEAS are

After gaining a foothold, the slow part of privilege escalation is enumeration: checking dozens of possible weak spots by hand. linPEAS (Linux) and winPEAS (Windows) automate that.

They run a large battery of checks and print the results, using colour to flag the highest-probability escalation paths. linPEAS looks at SUID/SGID binaries, sudo rules, capabilities, cron jobs, writable files, and credentials; winPEAS looks at token privileges, services, unquoted paths, AlwaysInstallElevated, and more.

How they are used and payload

The attacker uploads and runs the script, then reads the highlighted output:

  • Linux: curl -L https://.../linpeas.sh | sh or transfer and run ./linpeas.sh
  • Windows: run winPEASx64.exe or the batch version on the target.
  • Findings flagged in red/yellow (for example a writable service, a dangerous capability, SeImpersonate enabled) point to the likely escalation.

The script does not exploit anything itself; it finds the path. The human confirms and exploits it. Shown for defensive context.

How defenders use them

  • Run linPEAS/winPEAS on your own hosts during hardening and after changes, and remediate the highlighted findings.
  • Treat red/yellow flags as a prioritised work list (writable services, dangerous privileges, SUID binaries).
  • Combine with patching so kernel and software CVEs are covered too.
  • Detect the scripts running on production hosts, since an attacker would use them.
  • Re-run periodically, as configuration drift introduces new paths.

References

  1. [1]MITRE ATT&CK: Privilege Escalation (TA0004)(MITRE)
  2. [2]NIST SP 800-115 Technical Guide to Security Testing(NIST)
  3. [3]Microsoft: Privilege Constants (Windows)(Microsoft)
Related terms

Common questions

Privilege escalation, asked often

Want your systems tested for these paths?

Scope an engagement

Find the privilege-escalation paths before an attacker does.

We run internal and host penetration tests that walk the real route from a low-privileged foothold to root or SYSTEM, then hand your team a report with reproducible evidence and a fix for every step. Free re-test included.

See all services30-min scoping call, fixed-price proposal in 48 hours.