crazymarky/pentest-skills/scripts
Claude Code and agent skill by crazymarky/pentest-skills
- community
Checking that the SKILL.md file is still in the repository.
Arbitrary file download vulnerability detection and exploitation using path traversal techniques, bypass methods, and sensitive file discovery. Use this skill when user needs to test for file download vulnerabilities, path traversal, or read sensitive files on target systems.
Install
npx vskill@latest install crazymarky/pentest-skills/scriptsSKILL.md
Arbitrary File Download Detection & Exploitation
Authorization Warning
DANGER: File download vulnerability testing can expose sensitive system files and user data. Always ensure you have:
- Written permission from the target system owner
- Isolated testing environment
- Defined scope of testing
- Legal compliance with local regulations
Never test file download vulnerabilities on production systems without authorization.
Prerequisites
Required Tools
Optional Tools
Quick Start
Basic Path Traversal Test
Sensitive File Scanner
Common Scenarios
1. Basic Path Traversal Testing
Test for basic directory traversal vulnerabilities:
What to check:
- Does the parameter accept
../sequences? - Can you access files outside the intended directory?
- What is the response when accessing system files?
Common payload patterns:
2. URL Encoded Bypass
When basic traversal is blocked, try URL encoding:
Encoding variations:
| Type | Payload | |
|---|---|---|
| URL encoded | %2e%2e%2f | |
| Double encoded | %252e%252e%252f | |
| Mixed | ..%2f..%2f |
3. Null Byte Injection
When extension validation exists:
Works against:
- Simple extension validation
- Some path sanitization filters
4. Unicode/Double Write Bypass
When standard payloads are filtered:
5. Sensitive File Discovery
After confirming vulnerability, discover sensitive files:
High-value targets (Linux):
High-value targets (Windows):
6. Application Config Discovery
Target web application configuration files:
Framework-specific paths:
| Framework | Config Path | |
|---|---|---|
| WordPress | wp-config.php | |
| Laravel | .env | |
| Django | settings.py | |
| ASP.NET | web.config | |
| Spring | application.properties |
7. POST Request Testing
Test POST parameters for file download:
8. Cookie/Header Testing
Test non-parameter injection points:
Tool Selection Guide
| Scenario | Tool | Command | |
|---|---|---|---|
| Quick manual test | curl | curl "URL?file=../../../etc/passwd" | |
| Automated scanning | file_download_tester.py | python scripts/file_download_tester.py -u URL | |
| Sensitive file scan | sensitive_file_scanner.py | python scripts/sensitive_file_scanner.py -u URL --os linux | |
| Parameter fuzzing | ffuf | ffuf -u "URL?file=FUZZ" -w wordlist.txt | |
| Custom payload test | curl | curl "URL?file=$(cat payload.txt)" |
Testing Checklist
Discovery Phase
- [ ] Identify all download endpoints (URL params, forms, API endpoints)
- [ ] Test basic path traversal (
../) - [ ] Check response headers for file type information
Bypass Testing
- [ ] URL encoding (
%2e%2e%2f) - [ ] Double URL encoding (
%252e%252e%252f) - [ ] Null byte injection (
%00) - [ ] Unicode encoding (
%c0%af) - [ ] Double write (
....//) - [ ] Mixed separators (
..\on Windows) - [ ] Path truncation
Sensitive File Testing
- [ ] Linux system files (
/etc/passwd,/etc/shadow) - [ ] Windows system files (
win.ini,SAM) - [ ] Application configs (
.env,config.php) - [ ] SSH keys (
id_rsa,authorized_keys) - [ ] Log files (access.log, error.log)
- [ ] Database files
Post-Exploitation
- [ ] Document all accessible files
- [ ] Identify sensitive data exposed
- [ ] Report severity based on data sensitivity
Resources
Scripts
scripts/file_download_tester.py- Automated vulnerability detectionscripts/sensitive_file_scanner.py- Sensitive file enumeration
Reference Documentation
references/bypass_techniques.md- Detailed bypass methodsreferences/sensitive_files.md- Comprehensive file lists
Assets/Wordlists
assets/traversal_payloads.txt- Path traversal payloadsassets/linux_sensitive_files.txt- Linux sensitive file pathsassets/windows_sensitive_files.txt- Windows sensitive file paths
External Resources
Reporting Format
When reporting file download vulnerabilities, include:
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingexploit-file-download/scripts/SKILL.md
Popularity
- Repository stars
- 216
- Repository forks
- 26
- 7-day trend score
- 27
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/crazymarky/pentest-skills/scripts)