A comprehensive collection of Model Context Protocol (MCP) servers for firmware analysis and password extraction, implemented across four different transport protocols.
rock-firmware/
├── stdio/ # Standard stdio-based MCP server
├── network/ # TCP network-based MCP server
├── streaming-http/ # HTTP/HTTPS streaming MCP server
├── sse/ # Server-Sent Events (SSE) MCP server
├── requirements.txt # Python dependencies
├── install.sh # Installation script
├── firmware_analysis_report.html # HTML analysis report
├── firmware_analysis_report.md # Markdown analysis report
└── README.md # This file
# Install all dependencies
./install.sh
# Or install manually
sudo apt-get install binwalk squashfs-tools python3-magic libmagic1 python3-aiohttp python3-aiohttp-cors
pip install -r requirements.txt
cd streaming-http
python3 firmware_analyzer_mcp_http.py --port 8080
# Open browser: http://localhost:8080
cd network
python3 firmware_analyzer_mcp_network.py --port 8080
python3 network_mcp_client.py --firmware /path/to/firmware.bin
cd stdio
python3 firmware_analyzer_mcp.py
# Use with MCP clients
cd sse
python3 firmware_analyzer_mcp_sse.py --port 8083
# Open browser: http://localhost:8083
# Perfect for VS Code GitHub Copilot integration
All four implementations provide the same 6 analysis tools:
update_firmware
- Upload and validate.bin
firmware filesidentify_file_format
- Detect ZIP, binary, SquashFS formatsextract_with_binwalk
- Recursively extract files from binariesextract_squashfs
- Open SquashFS filesystemsfind_password_files
- Locate/etc/passwd
and/etc/shadow
crack_md5_password
- Attempt password cracking
Feature | stdio | Network | HTTP | SSE |
---|---|---|---|---|
Protocol | stdio | TCP | HTTP/HTTPS | SSE + HTTP |
Web Interface | ❌ | ❌ | ✅ Built-in | ✅ Built-in |
REST API | ❌ | ❌ | ✅ Yes | ✅ Yes |
Browser Support | ❌ | ❌ | ✅ Yes | ✅ Yes |
Multi-Client | ❌ | ✅ Yes | ✅ Yes | ✅ Yes |
Real-time Updates | ❌ | ❌ | ❌ | ✅ Yes |
SSL/TLS | ❌ | ✅ Manual | ✅ Native | ✅ Native |
MCP Compliance | ✅ Full | ✅ Full | ||
VS Code Integration | ✅ Direct | ❌ Bridge | ❌ Bridge | ✅ Via Bridge |
Performance | ✅ Fastest | ✅ Fast | ✅ Fast | |
Ease of Use | ✅ Very Easy | ✅ Very Easy | ||
Integration | ✅ Universal | ✅ Universal |
- stdio/ - Standard MCP server with stdio transport
- network/ - TCP network server with multi-client support
- streaming-http/ - HTTP server with web interface and REST API
- sse/ - SSE server with real-time communication and VS Code integration
- You need full MCP protocol compliance
- You're integrating with existing MCP clients
- You want maximum performance
- You're building command-line tools
- You need multi-client support
- You want remote access capabilities
- You need SSL/TLS encryption
- You're building distributed systems
- You want a web interface
- You need REST API integration
- You're building web applications
- You want the easiest setup and usage
- You need browser-based access
- You need real-time communication
- You want VS Code GitHub Copilot integration
- You need automatic reconnection
- You're building modern web applications
- You want the best of both worlds (HTTP + real-time)
The project includes analysis reports from previous firmware analysis:
firmware_analysis_report.html
- Interactive HTML report with findingsfirmware_analysis_report.md
- Markdown summary of analysis results
# Test stdio server
cd stdio && python3 direct_firmware_analyzer.py
# Test network server
cd network && python3 test_network_connection.py
# Test HTTP server
cd streaming-http && python3 http_mcp_client.py --test-tools
# Test SSE server
cd sse && python3 firmware_analyzer_mcp_sse.py --port 8083
curl -N http://localhost:8083/sse
All four implementations share the same core analysis functions. To add a new tool:
- Add the function to the core analysis logic
- Update all three server implementations
- Update client examples
- Update documentation
- Password hashes are masked in output for security
- Temporary files are cleaned up automatically
- Input validation prevents directory traversal
- SSL/TLS support for secure communications
- CORS policies for web security
This project is provided for educational and security research purposes. Use responsibly and in accordance with applicable laws and regulations.
- Fork the repository
- Create a feature branch
- Make your changes across all three implementations
- Add tests if applicable
- Submit a pull request
🎉 Choose the transport that best fits your needs and start analyzing firmware today!