Loading...
Loading...
Solve CTF (Capture The Flag) challenges by analyzing challenge descriptions, source code, and interacting with challenge environments to capture flags.
npx skill4agent add hacktronai/skills ctf-solverrequestssocketncnetcatvimnanolessmoressh-o BatchMode=yesrequestssocketcurlcatheadtailecho "data" | command| Category | Key Indicators | Primary Techniques |
|---|---|---|
| Web | URL endpoint, HTTP, HTML/JS/PHP source | SQLi, XSS, SSRF, SSTI, auth bypass, path traversal |
| Pwn | Binary file, TCP connection, C source | Buffer overflow, ROP, format string, heap exploitation |
| Crypto | Encrypted data, crypto code, math operations | Frequency analysis, padding oracle, RSA attacks, hash collisions |
| Reverse | Binary/executable, obfuscated code | Disassembly, debugging, deobfuscation, patching |
| Forensics | File dump, network capture, disk image | File carving, steganography, memory analysis |
| Misc | Anything else | OSINT, esoteric languages, puzzles |
┌─────────────────────────────────────────────────────────────┐
│ CHALLENGE INPUTS │
├─────────────────────────────────────────────────────────────┤
│ 1. Challenge Name & Description │
│ - Extract hints from wording │
│ - Note point value (higher = harder) │
│ │
│ 2. Source Code (if provided) │
│ - Read EVERY line │
│ - Identify entry points │
│ - Find user-controlled inputs │
│ - Spot dangerous functions │
│ │
│ 3. Environment / Attachments │
│ - Map available endpoints │
│ - Identify technologies (headers, errors) │
│ - Note versions for known CVEs │
└─────────────────────────────────────────────────────────────┘Hypothesis → Minimal PoC → Verify → Expand → Capture Flag
↑ │
└────────── Adjust if fails ─────────┘/flag/flag.txt/home/*/flag## Challenge: [Name]
**Category**: [Web/Pwn/Crypto/Rev/Forensics/Misc]
### Vulnerability
[What was the vulnerability]
### Exploitation
[Step-by-step exploitation]
### Payload
[Final working payload]
### Flag
FLAG{the_captured_flag}1. READ the challenge description carefully
2. ANALYZE all provided source code line by line
3. MAP the attack surface (inputs, endpoints, functions)
4. IDENTIFY potential vulnerabilities
5. WRITE Python scripts to test exploits
6. ITERATE if initial attempts fail
7. EXTRACT the flag
8. DOCUMENT the solution