Model Context Protocol integration for HackTheBox API access and CTF management
Config is the same across clients — only the file and path differ.
{
"mcpServers": {
"htb": {
"env": {
"HTB_TOKEN": "your.jwt.token.here"
},
"command": "/path/to/htb-mcp-server"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
A Model Context Protocol (MCP) server that provides AI assistants with programmatic access to HackTheBox platform functionality.
No automated test available for this server. Check the GitHub README for setup instructions.
Five weighted categories — click any category to see the underlying evidence.
No known CVEs.
No package registry to scan.
Click any tool to inspect its schema.
Be the first to review
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Others in security / education
A Model Context Protocol server for searching and analyzing arXiv papers
An evil MCP server used for redteam testing
MCP server for NotebookLM - Let your AI agents (Claude Code, Codex) research documentation directly with grounded, citation-backed answers from Gemini. Persistent auth, library management, cross-client sharing. Zero hallucinations, just your knowledge base.
Proof primitive for AI agents on MultiversX. Anchor file hashes on-chain as verifiable proofs.
MCP Security Weekly
Get CVE alerts and security updates for Htb Mcp Server and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
A Model Context Protocol (MCP) server that provides AI assistants with programmatic access to HackTheBox platform functionality.
The HTB MCP Server exposes 12 comprehensive tools for interacting with the HackTheBox platform:
list_challenges - Get paginated list of challenges with filteringstart_challenge - Initialize a challenge environmentsubmit_challenge_flag - Submit flags for challenge verificationlist_machines - Get active/retired machines with status informationstart_machine - Start a machine and get connection detailsget_machine_ip - Retrieve IP address of active machinesubmit_user_flag - Submit user flags for machinessubmit_root_flag - Submit root flags for machinesget_user_profile - Retrieve user profile and statisticsget_user_progress - Get completion status and achievementssearch_content - Advanced search across challenges/machines/usersget_server_status - Health check and server informationClone the repository:
git clone https://github.com/NoASLR/htb-mcp-server.git
cd htb-mcp-server
Build the binary:
go build -o htb-mcp-server main.go
Get your HTB API token:
xxx.yyy.zzz)The server is configured via environment variables:
HTB_TOKEN - Your HackTheBox API token (JWT format)SERVER_PORT - Server port (default: 3000)LOG_LEVEL - Logging level: DEBUG, INFO, WARN, ERROR (default: INFO)RATE_LIMIT_PER_MINUTE - API rate limiting (default: 100)CACHE_TTL_SECONDS - Response cache TTL (default: 300)REQUEST_TIMEOUT_SECONDS - HTTP request timeout (default: 30)export HTB_TOKEN="your.jwt.token.here"
./htb-mcp-server
docker build -t htb-mcp-server .
docker run -e HTB_TOKEN="your.jwt.token.here" htb-mcp-server
Add to your MCP client configuration (e.g., Claude Desktop):
{
"mcpServers": {
"htb": {
"command": "/path/to/htb-mcp-server",
"env": {
"HTB_TOKEN": "your.jwt.token.here"
}
}
}
}
Once connected, you can use the tools through your AI assistant:
# List active challenges
"Can you show me the available Web challenges on HackTheBox?"
# Start a machine
"Please start machine ID 123 and get its IP address"
# Submit a flag
"Submit the user flag 'HTB{example_flag}' for machine 123"
# Search for content
"Search for machines related to 'Active Directory'"
# Check server status
"What's the current status of the HTB MCP server?"
The server implements the MCP protocol over stdio transport. All communication follows the JSON-RPC 2.0 specification.
initialize - Initialize the MCP sessiontools/list - List available toolstools/call - Execute a specific toolThe server integrates with HackTheBox API v4:
https://labs.hackthebox.com/api/v4htb-mcp-server/
├── main.go # Entry point
├── pkg/
│ ├── config/ # Configuration management
│ ├── htb/ # HTB API client
│ └── mcp/ # MCP protocol implementation
├── internal/
│ ├── server/ # MCP server core
│ └── tools/ # Tool implementations
├── tests/
... [View full README on GitHub](https://github.com/noaslr/htb-mcp-server#readme)