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/Usable access/Sessions & transfers
← All sessions & transfers tasks

Verify command execution, host and represented identity

CommandsIf → thenExplanation & examples

Needs: A functioning execution primitive and an observable output or controlled side effect

Client commands / example output

# Baseline
delivery → execution → connection → usable session

Linux

StateDecisive evidenceDoes not yet prove
DeliveryExact bytes/request reached intended consumerPayload executed
ExecutionHarmless command output or controlled side effectNetwork callback works
ConnectionListener records the expected peerCommands and I/O are usable
SessionCommands return and host/identity are verifiedHigher privilege or stability
SituationPreferMain prerequisite / limitation
One bounded action is enoughDirect command executionObservable output or side effect; no shell required
Valid credential and remote serviceSSH, WinRM or RDPAuthentication plus remote-logon authorization
Target can reach KaliReverse shellTarget egress and a reachable Kali listener
Kali can reach a target listenerBind shellTarget can bind and inbound path permits it
Payload is staged or protocol-awareMatching framework handlerHandler must use the exact payload/transport
# Linux
id; hostname; pwd

Windows

REM Windows
whoami & hostname & cd

Linux

# Linux
hostname; id; pwd
ip addr; ip route
ss -lntup

Windows

REM Windows
hostname
whoami /all
cd
ipconfig /all
route print
netstat -ano

Client commands / example output

Record the destination host, actual identity, privilege, current directory, interfaces/routes, parent/execution context and the exact command that produced the session. Then re-enumerate from the new state.

# Baseline
exact prerequisites
→ exploit reaches expected vulnerable path
→ bounded harmless effect or identity output
→ repeatable command execution
→ payload reaches listener
→ usable session
→ verified host/identity/privilege/network position

Verify → Save destination identity/hostname and actual command output; use Windows hostname/whoami/ipconfig when appropriate.

If it fails → A hung request or success message does not prove execution. First establish a bounded observable effect, then diagnose the next state. More detail ↓

If → then

  • Linux command execution exists but an interactive channel is needed → Connect a Linux reverse shell through an available interpreter

    Needs: A confirmed Bash/Python/PHP/Netcat implementation, correct parser wrapping, target-to-listener route and compatible listener

  • 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

  • A new Windows session or claimed administrator/SYSTEM transition → Establish Windows token, host and process context

    Needs: A functioning command channel and the actual effective token/process context

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

Explanation & examples

Verify command execution, host and represented identity

USE WHEN
A PoC, injected command or remote client reports execution
STARTING ACCESS
Verified command execution or authenticated remote access and a known network path
RESULT
A verified foothold state with host, identity, privilege and network context

Recognize the clue

Begin with the original command/PoC/client result and request a small host/identity proof through its existing output channel.

hostname
id
pwd
SYNTHETIC EXAMPLE OUTPUT
hostname: TARGET_HOST
uid=USER_ID(APP_USER) gid=GROUP_ID(APP_GROUP)
working directory: /APP_PATH

Means: Host-specific identity output demonstrates execution under that account, not yet a reverse connection or full terminal.

Confirm: Record OS, privilege and network position; choose an access form whose interpreter/service and route exist.

After validation
The intended target's command proof is reproducible: use the confirmed foothold as the starting state.
Ruled out in this context
The tool's success message has no command-specific effect and the operation is rejected: discard its execution claim.
Still inconclusive
A hung request with no observable effect leaves execution unknown; obtain a bounded independent observation.

Troubleshooting: A hung request or success message does not prove execution. First establish a bounded observable effect, then diagnose the next state.

Additional prerequisite checks

hostname
id
pwd
ip addr
ip route
StateDecisive evidenceDoes not yet prove
DeliveryExact bytes/request reached intended consumerPayload executed
ExecutionHarmless command output or controlled side effectNetwork callback works
ConnectionListener records the expected peerCommands and I/O are usable
SessionCommands return and host/identity are verifiedHigher privilege or stability

Do not change all four layers at once. Preserve the last confirmed state and test the next boundary.

SituationPreferMain prerequisite / limitation
One bounded action is enoughDirect command executionObservable output or side effect; no shell required
Valid credential and remote serviceSSH, WinRM or RDPAuthentication plus remote-logon authorization
Target can reach KaliReverse shellTarget egress and a reachable Kali listener
Kali can reach a target listenerBind shellTarget can bind and inbound path permits it
Payload is staged or protocol-awareMatching framework handlerHandler must use the exact payload/transport

Prefer authenticated administrative access when it is already available: it is normally more stable, auditable and feature-complete than an improvised shell.

Linux:

Windows:

For blind execution, use one bounded callback or file side effect that the current context can produce and you can independently observe. Do not interpret a hung HTTP request as proof of a shell; the server may simply be waiting on a child process or timeout.

Linux:

Windows:

Record the destination host, actual identity, privilege, current directory, interfaces/routes, parent/execution context and the exact command that produced the session. Then re-enumerate from the new state.

Do not accept the exploit's own “success” string as proof. Validate an independent effect. An HTTP 200, uploaded filename, connection or application crash each proves less than a verified command result.

Why it works

Execution, connection and a usable session are different capabilities. A command-output path may be enough to enumerate before any interactive shell exists.

Worked example · hypothetical

Observation: a PoC says the request completed. Test: obtain a hostname/identity proof through the same primitive. Illustrative output: a low-privileged service account responds. Interpretation: retain that foothold and choose a session method compatible with its interpreter and network.

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