Skip to content
leg3ndProjects & tools
01Home02Projects03Tools04Notes
GMT+8
O/ OSCP exploitation reference
Workspace controls Memory only · 0 steps
Visualize path ↗
Command values 0 filled

Temporary connection values clear on reload. Passwords, hashes and tickets remain placeholders. Check address-family syntax in the selected command.

Reference index ↗ Search all procedures & variants ↗
01Discovery02Enumeration03Initial access04Usable access05Local privilege06Active Directory07Internal access08Evidence & reporting

QUICK REFERENCE

Discovery›Services›Web mapping›Web exploitation›Credentials›Public exploits›Sessions & transfers›Linux escalation›Windows escalation›AD enumeration›AD identity attacks›Lateral movement›Pivoting & tunnels›Execution troubleshooting›Integration & evidence›
174 methods · 15 topicsFull reference on GitHub ↗Commands · scripts · next steps
Tools/OSCP/Local privilege/Linux escalation
← All linux escalation tasks

Select an evidence-matched Linux software or kernel exploit

CommandsIf → thenExplanation & examples

Needs: Vulnerable package/kernel state, architecture, mitigations, namespaces and documented exploit-specific conditions

Shell commands

# Baseline
uname -a
cat /proc/version
cat /etc/os-release
dpkg -l 2>/dev/null
rpm -qa 2>/dev/null
sudo --version
lsmod
sysctl kernel.unprivileged_userns_clone 2>/dev/null

# Baseline
searchsploit "PRODUCT VERSION local privilege escalation"
searchsploit -x EDB_ID
searchsploit -m EDB_ID
gcc -Wall -Wextra exploit.c -o exploit
file exploit
sha256sum exploit

Match component, exact distribution/build and patch/backport state, architecture, required configuration/capabilities/namespaces, mitigations and dependencies. Review source and recovery risk. A version title or successful compilation is only a candidate. Follow public exploit adaptation.

Verify → Verify actual effective UID/host context after the exploit, keeping the reviewed source and adaptation record.

If it fails → Wrong build, missing feature or mitigation can invalidate the PoC. Choose another evidence-backed candidate rather than cycling random local exploits. More detail ↓

If → then

  • A product/version clue, advisory or component-specific public PoC → Match a public exploit to the actual component and configuration

    Needs: Exact vulnerable build/configuration, required access and endpoint behavior; reviewable source and a verifiable expected effect

  • An existing C/C++ or platform-specific PoC matches the candidate → Compile and minimally adapt an existing native or memory-corruption PoC

    Needs: Correct compiler/target architecture, runtime dependencies, documented payload constraints and validated exploit-specific constants

  • A new Linux foothold or an identity/privilege change → Establish Linux state and choose an escalation candidate

    Needs: A working command channel and accurate effective identity, group, mount and process context

No useful finding → another task in this topic. Failed check → resolve the failure before ruling out the path.

Explanation & examples

Select an evidence-matched Linux software or kernel exploit

USE WHEN
Permission/credential paths are insufficient and an exact affected build/configuration is present
STARTING ACCESS
A verified Linux foothold with a known effective UID, groups and filesystem context
RESULT
A justified local exploit test and independently verified privilege result

Recognize the clue

Collect distribution build/package/architecture and the required local feature before comparing a specific advisory/PoC.

uname -a
cat /etc/os-release
getconf LONG_BIT
SYNTHETIC EXAMPLE OUTPUT
Kernel release: KERNEL_RELEASE
Distribution package/build: VENDOR_BUILD
Required vulnerable feature: not yet verified

Means: A version-associated advisory is a candidate; backports and feature state determine applicability.

Confirm: Collect uname and the distribution's package/build plus architecture. Match the advisory's vulnerable feature and vendor patch status before choosing a PoC; try a confirmed sudo/file/credential route first when one exists.

After validation
Affected code/configuration and compatible reviewed PoC are established: select its bounded test.
Ruled out in this context
The vendor build includes the fix or required feature is absent: reject that exploit.
Still inconclusive
A release string without patch/configuration evidence leaves vulnerability unconfirmed.

Troubleshooting: Wrong build, missing feature or mitigation can invalidate the PoC. Choose another evidence-backed candidate rather than cycling random local exploits.

Match component, exact distribution/build and patch/backport state, architecture, required configuration/capabilities/namespaces, mitigations and dependencies. Review source and recovery risk. A version title or successful compilation is only a candidate. Follow public exploit adaptation.

Why it works

Kernel release strings can hide patched distributions. A matching CVE needs affected code/configuration and compatible exploit assumptions; a crash is neither success nor proof that another build will work.

Worked example · hypothetical

Observation: an automated tool names a kernel CVE. Test: compare the distribution patch/build and required feature. Illustrative output: the vendor build includes the fix. Interpretation: reject the candidate and return to unexamined permissions/applications.

New identity, privilege, host or route? Re-enumerate → All topic tasks →

Study guide ↗Full procedure ↗Cheatsheet ↗
HomeProjectsToolsNotes
Interactive toolsOSCP notes ↗Extended OSCP workspace ↗Attack-path visualizer ↗

© 2026 Armaan. Built with curiosity.

GitHub ↗GMT+8