miner-and-reverse-shell — Claude Code skill: features and setup
miner-and-reverse-shell is a Claude Code skill that stops miners and reverse shells. Triggers on unexpected CPU spikes, suspicious outbound ports, and binaries in /tmp.
Apache-2.0 ★ 71 updated 2026-11-15
npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a claude-codeWhat miner-and-reverse-shell does
The skill spots cryptominer and shell patterns across active processes and network sockets. It monitors targets like xmrig or kinsing, execution from /tmp or /dev/shm, and connections to ports 3333, 4444, or 5555. Interactive shells are detected when descriptors in /proc/<pid>/fd point to sockets alongside interpreters or tools like nc and socat.
Triage uses ps, readlink, and ss commands together with a sha256sum hash. During containment, kodeblue backs up the executable for forensics before invoking kill_process, moves launcher files to quarantine, and runs block_ip against the external pool. Documenting the initial ingress vector remains the core remediation step.
What it helps with
- halt hidden cryptominers while archiving the binary for analysis
- detect reverse shells by checking socket references in
/proc/<pid>/fd - quarantine dropped payloads and block external pool IP addresses
- trace parent exploit processes and cron persistence mechanisms
Example prompts for the agent
- Investigate the high CPU process in
/tmpand trace its parent PID - Contain the active miner, block the pool IP, and quarantine the binary
How to install miner-and-reverse-shell
1Skills CLI (Vercel)
npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a claude-code2Manually: put the files in place
~/.claude/skills/miner-and-reverse-shell/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/miner-and-reverse-shell/
1Skills CLI (Vercel)
npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a codex2Manually: put the files in place
.agents/skills/miner-and-reverse-shell/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a cursor2Manually: put the files in place
.cursor/skills/miner-and-reverse-shell/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install Problem99-io/kodeblue blue/skills/miner-and-reverse-shell2Manually: put the files in place
.github/skills/miner-and-reverse-shell/SKILL.md1Skills CLI (Vercel)
npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a gemini-cli2Platform CLI
gemini skills install https://github.com/Problem99-io/kodeblue --path blue/skills/miner-and-reverse-shellManually: put the files in place
.devin/skills/miner-and-reverse-shell/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about miner-and-reverse-shell
How to install miner-and-reverse-shell in Claude Code?
Run npx skills add Problem99-io/kodeblue --skill miner-and-reverse-shell -a claude-code.
What does miner-and-reverse-shell do?
It identifies cryptocurrency miners and reverse shells, analyzes process lineage, and isolates the malicious components.
How does the skill handle confirmed threats?
It preserves the suspect file for forensics first, terminates the process, isolates dropped files via quarantine_file, and blocks remote IPs.
Source text
SKILL.md · Apache-2.0
--- name: miner-and-reverse-shell description: Recognise and contain cryptominers and reverse shells (cpu_hog, outbound.shell, outbound.suspicious_port, process.suspicious_location findings). metadata: kodeblue-bundled: true --- # Miners and reverse shells **Miner indicators:** sustained high CPU from an unpackaged binary; names like `xmrig`, `kdevtmpfsi`, `kinsing`, or random 6–8 character strings; binaries in /tmp, /dev/shm or /var/tmp; outbound connections to 3333, 4444, 5555, 7777, 14444 or 45700; or pool hostnames. These often come with a cron or systemd re-launcher and a killer script for competing miners. **Reverse shell indicators:** `bash -i`, `sh -i`, `nc -e`, `socat exec:`, or python/perl one-liners with socket. stdin and stdout point to a socket: `host_exec ["ls","-l","/proc/<pid>/fd"]` shows `socket:[...]` on fds 0, 1 and 2. The parent is often a web server or a service account. The child may instead be the service's own interpreter (node, python) re-exec'd rather than a named shell, and the callback may have been refused — an attempted outbound to a dead port is still the event. See service-process-exploitation. **Investigate quickly:** 1. `ps -o pid,ppid,user,lstart,cmd -p <pid>`, then walk up the parents. 2. `readlink -f /proc/<pid>/exe` and `sha256sum` of it. 3. `ss -tunap` filtered by the pid to get remote IP and port. 4. Find the re-launcher (see persistence-hunting). **Contain (true_positive):** kill_process (kodeblue preserves the binary for forensics first), quarantine_file for the dropped binary and its launcher script, and block_ip for the C2 or pool IP. Mention in the report how the attacker got in (the parent process, or the login session) — that is the real fix.
© Problem99-io · Apache-2.0 · Problem99-io/kodeblue