aiskillstore/marketplace/api-mitmproxy
Claude Code and agent skill by aiskillstore/marketplace
- community
- ext:[{"type":"plugin","description":"Custom plugin integration"}]
Checking that the SKILL.md file is still in the repository.
Author "aiskillstore" has blocked skill(s)
Interactive HTTPS proxy for API security testing with traffic interception, modification, and replay capabilities. Supports HTTP/1, HTTP/2, HTTP/3, WebSockets, and TLS-protected protocols. Includes Python scripting API for automation and multiple interfaces (console, web, CLI). Use when: (1) Intercepting and analyzing API traffic for security testing, (2) Modifying HTTP/HTTPS requests and responses to test API behavior, (3) Recording and replaying API traffic for testing, (4) Debugging mobile app or thick client API communications, (5) Automating API security tests with Python scripts, (6) Exporting traffic in HAR format for analysis.
Install
npx vskill@latest install aiskillstore/marketplace/api-mitmproxySemi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard
SKILL.md
The same SKILL.md was published earlier as aiskillstore/marketplace/api-mitmproxy.
mitmproxy API Security Testing
Overview
mitmproxy is an interactive, TLS-capable intercepting HTTP proxy for penetration testers and developers. It enables real-time inspection, modification, and replay of HTTP/HTTPS traffic including APIs, mobile apps, and thick clients. With support for HTTP/1, HTTP/2, HTTP/3, and WebSockets, mitmproxy provides comprehensive coverage for modern API security testing.
Interfaces
mitmproxy - Interactive console interface with keyboard navigation mitmweb - Web-based GUI for visual traffic inspection mitmdump - Command-line tool for automated traffic capture and scripting
Quick Start
Install and run mitmproxy:
Configure client to use proxy (default: localhost:8080)
Core Workflows
Workflow 1: Interactive API Traffic Inspection
For manual API security testing and analysis:
- Start mitmproxy or mitmweb:
```bash # Console interface mitmproxy --mode regular --listen-host 0.0.0.0 --listen-port 8080
# Or web interface mitmweb --mode regular --listen-host 0.0.0.0 --listen-port 8080 ```
- Configure target application to use proxy (HTTP: localhost:8080)
- Install mitmproxy CA certificate on client device
- Trigger API requests from the application
- Intercept and inspect requests/responses in mitmproxy
- Modify requests to test:
- Authentication bypass attempts
- Authorization flaws (IDOR, privilege escalation)
- Input validation (SQLi, XSS, command injection)
- Business logic vulnerabilities
- Save flows for documentation and reporting
Workflow 2: Mobile App API Security Testing
Progress: [ ] 1. Install mitmproxy CA certificate on mobile device [ ] 2. Configure device WiFi to use mitmproxy as proxy [ ] 3. Start mitmweb for visual traffic inspection [ ] 4. Launch mobile app and exercise all features [ ] 5. Review API endpoints, authentication mechanisms, data flows [ ] 6. Test for common API vulnerabilities (OWASP API Top 10) [ ] 7. Export traffic as HAR for further analysis [ ] 8. Document findings with request/response examples
Work through each step systematically. Check off completed items.
Workflow 3: Automated API Traffic Recording
For capturing and analyzing API traffic at scale:
- Start mitmdump with flow capture:
``bash mitmdump -w api-traffic.flow --mode regular ``
- Run automated tests or manual app interaction
- Stop mitmdump (Ctrl+C) to save flows
- Replay captured traffic:
```bash # Replay to server mitmdump -nc -r api-traffic.flow
# Replay with modifications via script mitmdump -s replay-script.py -r api-traffic.flow ```
- Export to HAR format for analysis:
``bash # Using Python API python3 -c "from mitmproxy.io import FlowReader; from mitmproxy.tools.dump import DumpMaster; import sys; [print(flow.request.url) for flow in FlowReader(open('api-traffic.flow', 'rb')).stream()]" ``
Workflow 4: Python Scripting for API Testing
For automated security testing with custom logic:
- Create Python addon script (
api-test.py):
```python from mitmproxy import http
class APISecurityTester: def request(self, flow: http.HTTPFlow) -> None: # Modify requests on-the-fly if "api.example.com" in flow.request.pretty_url: # Test for authorization bypass flow.request.headers["X-User-ID"] = "1"
def response(self, flow: http.HTTPFlow) -> None: # Analyze responses if flow.response.status_code == 200: if "admin" in flow.response.text: print(f"[!] Potential privilege escalation: {flow.request.url}")
addons = [APISecurityTester()] ```
- Run mitmproxy with script:
``bash mitmproxy -s api-test.py # Or for automation mitmdump -s api-test.py -w results.flow ``
- Review automated findings and captured traffic
- Export results for reporting
Workflow 5: SSL/TLS Certificate Pinning Bypass
For testing mobile apps with certificate pinning:
- Install mitmproxy CA certificate on device
- Use certificate unpinning tools or framework modifications:
- Android: Frida script for SSL unpinning
- iOS: SSL Kill Switch or similar tools
- Configure app traffic through mitmproxy
- Alternatively, use reverse proxy mode:
``bash mitmproxy --mode reverse:https://api.example.com --listen-host 0.0.0.0 --listen-port 443 ``
- Modify /etc/hosts to redirect API domain to mitmproxy
- Intercept and analyze traffic normally
Operating Modes
mitmproxy supports multiple deployment modes:
Regular Proxy Mode (default):
Client configures proxy settings explicitly.
Transparent Proxy Mode (invisible to client):
Requires iptables/pf rules to redirect traffic.
Reverse Proxy Mode (sits in front of server):
mitmproxy acts as the server endpoint.
Upstream Proxy Mode (chain proxies):
Routes traffic through another proxy.
Certificate Installation
Install mitmproxy CA certificate for HTTPS interception:
Browser/Desktop:
- Start mitmproxy and configure proxy settings
- Visit http://mitm.it
- Download certificate for your platform
- Install in system/browser certificate store
Android:
- Push certificate to device:
adb push ~/.mitmproxy/mitmproxy-ca-cert.cer /sdcard/ - Settings → Security → Install from SD card
- Select mitmproxy certificate
iOS:
- Email certificate or host on web server
- Install profile on device
- Settings → General → About → Certificate Trust Settings
- Enable trust for mitmproxy certificate
Common Patterns
Pattern 1: API Authentication Testing
Test authentication mechanisms and token handling:
Pattern 2: API Parameter Fuzzing
Fuzz API parameters for injection vulnerabilities:
Pattern 3: GraphQL API Testing
Inspect and test GraphQL APIs:
Pattern 4: HAR Export for Analysis
Export traffic as HTTP Archive for analysis:
Or use built-in addon:
Security Considerations
- Sensitive Data Handling: Captured traffic may contain credentials, tokens, PII. Encrypt and secure stored flows. Never commit flow files to version control
- Access Control: Restrict access to mitmproxy instance. Use authentication for mitmweb (--web-user/--web-password flags)
- Audit Logging: Log all intercepted traffic and modifications for security auditing and compliance
- Compliance: Ensure proper authorization before intercepting production traffic. Comply with GDPR, PCI-DSS for sensitive data
- Safe Defaults: Use isolated testing environments. Avoid intercepting production traffic without explicit authorization
Integration Points
Penetration Testing Workflow
- Reconnaissance: Identify API endpoints via mitmproxy
- Authentication testing: Capture and analyze auth tokens
- Authorization testing: Modify user IDs, roles, permissions
- Input validation: Inject payloads to test for vulnerabilities
- Business logic: Test workflows for logical flaws
- Export findings as HAR for reporting
CI/CD Integration
Run automated API security tests:
Mobile App Security Testing
Standard workflow for iOS/Android apps:
- Configure device to use mitmproxy
- Install CA certificate
- Bypass SSL pinning if needed
- Exercise app functionality
- Analyze API security (OWASP Mobile Top 10)
- Document API vulnerabilities
Advanced Features
Traffic Filtering
Filter displayed traffic by expression:
Request/Response Modification
Modify traffic using built-in mappers:
WebSocket Interception
Intercept and modify WebSocket traffic:
Troubleshooting
Issue: SSL Certificate Errors
Solution: Ensure mitmproxy CA certificate is properly installed and trusted:
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/agentsecops/api-mitmproxy/SKILL.md
Popularity
- Repository stars
- 429
- Repository forks
- 45
- 7-day trend score
- 30
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Extension points
pluginCustom plugin integration
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/aiskillstore/marketplace/api-mitmproxy)