Until December 31: monthly plans give up to 2.5 times their price in credit. Scale is $200 a month with $400 of usage credit. See plans →

HexStrike AI

Run HexStrike AI, the MCP server for 150+ security tools: install from Kali or GitHub, connect Claude Code or OpenCode to Abliterator, then scan a lab host.

Published HexStrike AIMCPPentestingClaude CodeKali Linux

Quick answer

HexStrike AI is an MIT-licensed MCP server that lets an AI agent run nmap, nuclei, gobuster and other security tools on a Linux host. Its README lists 150+ tools. It has no model of its own: connect Claude Code with ANTHROPIC_BASE_URL=https://abliterator.ai, or OpenCode with https://abliterator.ai/v1, and pick kimi-k3.1-pro-abliterated. This follows commit d689933, checked 2026-12-02.

What HexStrike AI is

HexStrike AI is an open-source Model Context Protocol (MCP) server that gives an AI agent a Linux host's security tools: port scanners, web content discovery, vulnerability scanners, password auditing, binary analysis, cloud checks, forensics and OSINT. Its README says it covers "150+ security tools". It contains no model. The MCP client you connect supplies the model, and that is how Abliterator fits in.

This guide follows 0x4m4/hexstrike-ai at commit d689933 (2026-08-03), checked 2026-12-02. The configuration below was verified against that source and the Kali package source. It was not run against Abliterator.

Repository github.com/0x4m4/hexstrike-ai, 14,108 stars (checked 2026-12-02)
Maintainer Muhammad Osama (0x4m4). The README says OTT Cybersecurity LLC owns and develops it
Licence MIT (LICENSE)
Version 6.0.0, from the README and the server's /health response. The repository has no tagged releases; the README announces a v7.0 as "coming soon"
Parts hexstrike_server.py, a Flask API on port 8888 that runs the tools, and hexstrike_mcp.py, a stdio MCP server that forwards each tool call to that API
MCP tools "150+" per the README. At d689933 the MCP script defines 151 tool functions, one name (httpx_probe) twice
Transport stdio only. Streamable HTTP is an open feature request
Clients in the README 5ire (not v0.14.0), VS Code Copilot, Roo Code, Cursor, Claude Desktop, "any MCP-compatible agent"
Kali package hexstrike-ai, version 0.0~git20260803.d689933, built from the same commit

Neither Python file calls a language model. The "12+ AI agents" in the README are classes inside the server, such as IntelligentDecisionEngine, that choose tools and parameters without a model. Other GitHub repositories with HexStrike in the name are derivatives or add-ons with far fewer stars; this guide covers only the upstream project. To give an agent one tool rather than 150, see Burp MCP and Ghidra MCP.

Only for systems you own or have written permission to test. In September 2025, Check Point reported threat actors discussing the use of HexStrike AI to scan for and exploit newly disclosed vulnerabilities in network appliances. That is why this guide runs it in a disposable lab VM, against a target you own. The README asks for the same: "Run in isolated environments or dedicated security testing VMs."

How HexStrike AI connects to a model

An MCP client starts hexstrike_mcp.py as a subprocess and talks to it over stdio. The script sends each tool call as an HTTP request to hexstrike_server.py, which runs the command on its host and returns the output. The model only ever sees tool names, arguments and results.

model (Abliterator) <-> MCP client <-> hexstrike_mcp.py (stdio) <-> HTTP :8888 <-> hexstrike_server.py <-> nmap, nuclei, ...

So the route to Abliterator goes through a client that accepts a custom endpoint:

Client How it reaches Abliterator Covered here
Claude Code Anthropic Messages API at https://abliterator.ai (setup) Yes, the main route
OpenCode OpenAI-compatible provider at https://abliterator.ai/v1 (setup) Yes, the second route
Claude Desktop No custom model endpoint. The README's JSON block targets it No
Cursor, VS Code Copilot, Roo Code, 5ire Listed in the README No

Before you start

  • A disposable Linux VM. Kali Linux is easiest, because it packages HexStrike and many of the tools it drives. Give the VM NAT or host-only networking and no port forward to 8888. The server has no authentication, and its execute_command tool runs any shell command it receives.
  • An Abliterator key from /keys. Create one for this lab only, with a spend limit (authentication). New accounts get $10 of credit.
  • Claude Code or OpenCode inside the VM, so the MCP client, the server and the target share one host.
  • A target you own. This guide uses OWASP Juice Shop, an intentionally insecure training app. With Docker installed, its README starts it on the loopback interface only:
docker run --rm -p 127.0.0.1:3000:3000 bkimminich/juice-shop

A Hack The Box or TryHackMe machine that is assigned to you works too: use its address in place of 127.0.0.1 below.

Install HexStrike AI

On Kali, install the package. Use the GitHub install on other distributions.

Kali package GitHub, commit d689933
Install sudo apt install hexstrike-ai git clone, then pip3 install -r requirements.txt in a virtual environment
Files /usr/share/hexstrike-ai/ Your clone
Commands hexstrike_server, hexstrike_mcp (wrappers in /usr/bin) python3 hexstrike_server.py, python3 hexstrike_mcp.py
Python modules Debian packages, including python3-mcp Your virtual environment
Security tools apt also installs the package's recommended tools, including nmap, nuclei, gobuster and sqlmap Install separately
Listens on 127.0.0.1:8888 (HEXSTRIKE_HOST and HEXSTRIKE_PORT change it) 0.0.0.0:8888, every interface
Sample client config /usr/share/hexstrike-ai/hexstrike-ai-mcp.json hexstrike-ai-mcp.json

The Kali package adds no systemd service or config file of its own: you start the server yourself. Besides pointing the sample config at its own paths, it carries a patch that binds the server to 127.0.0.1. Upstream, the startup banner says 127.0.0.1:8888, but the code binds every interface (issue #122, open on 2026-12-02).

Kali

sudo apt update
sudo apt install hexstrike-ai

GitHub

The README's install commands, pinned to the commit this guide was checked against:

git clone https://github.com/0x4m4/hexstrike-ai.git
cd hexstrike-ai
git checkout d689933ff579d839c676c82b231f8e98326c5f04
python3 -m venv hexstrike-env
source hexstrike-env/bin/activate
pip3 install -r requirements.txt

Use Python 3.10 or later. The README's badge says 3.8+, but the MCP script imports mcp.server.fastmcp, and the mcp package on PyPI requires Python 3.10 or later.

Then make the server listen on loopback only, the same one-line change Kali makes:

sed -i 's/app.run(host="0.0.0.0"/app.run(host=API_HOST/' hexstrike_server.py

Start the server and check it

Start the server in its own terminal and leave it running:

hexstrike_server                # Kali
python3 hexstrike_server.py     # GitHub install, inside the virtual environment

In a second terminal, check the address it listens on and its health:

ss -ltn | grep 8888
curl -s http://127.0.0.1:8888/health | python3 -c 'import json,sys; d=json.load(sys.stdin); print(d["status"], d["version"], d["total_tools_available"], "of", d["total_tools_count"], "tools installed")'

ss should show 127.0.0.1:8888. If it shows 0.0.0.0:8888, the bind change above is missing. /health checks each tool with which and returns status, version, a tools_status map of tool to true or false, and per-category counts. Only installed tools work. The rest return an error when the agent calls them.

Connect Claude Code to Abliterator and HexStrike

Claude Code speaks the Anthropic Messages API, which Abliterator serves at https://abliterator.ai. Export the variables from the Claude Code guide in the shell you start it from:

export ANTHROPIC_BASE_URL="https://abliterator.ai"
export ANTHROPIC_AUTH_TOKEN="$ABL_API_KEY"
unset ANTHROPIC_API_KEY

export ANTHROPIC_MODEL="kimi-k3.1-pro-abliterated"
export ANTHROPIC_DEFAULT_OPUS_MODEL="kimi-k3.1-pro-abliterated"
export ANTHROPIC_DEFAULT_SONNET_MODEL="kimi-k3.1-pro-abliterated"
export ANTHROPIC_DEFAULT_HAIKU_MODEL="deepseek-v4.1-flash-abliterated"
export CLAUDE_CODE_SUBAGENT_MODEL="kimi-k3.1-pro-abliterated"

Add HexStrike as a stdio server with claude mcp add. Everything after -- is the command Claude Code runs:

mkdir -p ~/lab && cd ~/lab

# Kali package
claude mcp add --transport stdio hexstrike -- hexstrike_mcp --server http://127.0.0.1:8888

# GitHub install: use the virtual environment's Python
claude mcp add --transport stdio hexstrike -- ~/hexstrike-ai/hexstrike-env/bin/python3 ~/hexstrike-ai/hexstrike_mcp.py --server http://127.0.0.1:8888

claude mcp list

The default scope is local: the server loads only in the project you added it from, here ~/lab. claude mcp list should show hexstrike as connected, and /mcp inside a session shows its tool count. Tools appear as mcp__hexstrike__<tool>, for example mcp__hexstrike__nmap_scan.

Remove the tools you don't want the agent to have. A deny rule in ~/lab/.claude/settings.json takes a tool out of the model's context. This one removes the tools that run arbitrary commands and code or write files:

{
  "permissions": {
    "deny": [
      "mcp__hexstrike__execute_command",
      "mcp__hexstrike__execute_python_script",
      "mcp__hexstrike__install_python_package",
      "mcp__hexstrike__create_file",
      "mcp__hexstrike__modify_file",
      "mcp__hexstrike__delete_file"
    ]
  }
}

Add any other tool you won't use. Don't add an allow rule for mcp__hexstrike__*: approve each call at the prompt, so you see the target and arguments before anything runs.

Or connect OpenCode

OpenCode reaches Abliterator as an OpenAI-compatible provider. Set up the provider block from the OpenCode guide first, then add HexStrike to the same opencode.jsonc, in the format of OpenCode's MCP servers page:

{
  "mcp": {
    "servers": {
      "hexstrike": {
        "type": "local",
        // GitHub install: ["/home/you/hexstrike-ai/hexstrike-env/bin/python3", "/home/you/hexstrike-ai/hexstrike_mcp.py", "--server", "http://127.0.0.1:8888"]
        "command": ["hexstrike_mcp", "--server", "http://127.0.0.1:8888"],
      },
    },
  },
  "permissions": [
    { "action": "hexstrike_execute_command", "resource": "*", "effect": "deny" },
    { "action": "hexstrike_execute_python_script", "resource": "*", "effect": "deny" },
  ],
}

OpenCode names MCP tools <server>_<tool>, so the permissions rules match hexstrike_execute_command and the others. command is an array, and $VARIABLES are not expanded inside it, so write full paths. OpenCode's Code Mode is on by default: it groups a server's tools under the server name instead of placing each one on the model's native tool list, which matters for a server this size. opencode mcp list shows whether the server connected.

First task: a reconnaissance scan of your lab host

Start with one scan of the lab VM and a written summary. In ~/lab, start claude (or opencode) and send:

This is my own lab VM. OWASP Juice Shop runs in Docker on 127.0.0.1:3000 and I am authorized to test it.
Using the hexstrike MCP tools:
1. Call server_health and tell me which scanners are installed.
2. Run nmap_scan against 127.0.0.1 only, ports 1-10000, with service version detection (-sV).
Do not scan any other address and do not run any other tool.
Then write a short findings summary in Markdown: each open port, the service and version on it,
which one is Juice Shop, and what you would check next in a normal web application assessment.
Mark anything you inferred rather than read in the tool output.

What comes back:

  • server_health returns the /health JSON above. The model should list which scanners are installed and which are missing.
  • nmap_scan sends nmap -sV -p 1-10000 127.0.0.1 to the server. The result is JSON with nmap's normal text output in stdout, plus stderr, return_code, success, timed_out, execution_time and a recovery_info block that records retries. Expect at least two open ports: 3000 for Juice Shop and 8888 for HexStrike's own API. Port 8888 shows what any host on the network could reach if the server listened on every interface.
  • The summary is the model's reading of that output. Check every port and version against stdout before you put it in a report.

The server caches successful results for an hour, so an identical second call returns the first output. Change a parameter, or restart the server, to scan again. For turning findings into a report, see the cybersecurity use case.

Confirm the requests reached Abliterator:

curl -s https://abliterator.ai/api/v1/activity -H "Authorization: Bearer $ABL_API_KEY" | head -c 600

Which model to pick

Both models support tool calling and a 1,048,576-token context.

Model Use it for Notes
kimi-k3.1-pro-abliterated Long multi-step sessions that chain several tools Terminal-Bench 4.0 fell from 66.6 to 62.3 after abliteration, a drop that is plausible but not statistically shown (benchmarks). No security-suite results yet
deepseek-v4.1-flash-abliterated Single scans, summaries, many short sessions Security suites stayed within noise: CyberMetric-2000 94.2 → 93.8, InterCode-CTF 94.2 → 95.5, Cybench 98.3 → 96.6 (benchmarks)

Each turn resends the tool definitions and the conversation. Abliterator caches the repeated prefix automatically, and cached input bills at $0.40 per 1M tokens on kimi-k3.1-pro-abliterated and $0.10 on deepseek-v4.1-flash-abliterated (prompt caching).

Why a hosted model sometimes stops

A hosted model can decline a scan request even when you are authorized. HexStrike's own README warns that LLMs "are generally setup with some level of ethics" and tells you to state your role and that you own the target. In issue #20, GitHub Copilot answered an assessment request in agent mode with "sorry, I can't assist with that."

Providers say so in their own documentation. Anthropic's Cyber Verification Program says "You may need CVP if Claude blocks your security work, such as validating exploits or running authorized penetration tests." Individuals can apply only for its Defense Access tier, enrolled users "may experience some model refusals and classifier blocks for allowed security work," and the Usage Policy "still applies in full."

On Abliterator's models, refusals fell from 94% to 1% (DeepSeek) and from 94% to 3% (Kimi) after abliteration (benchmarks). That changes what the model will discuss. Your authorization stays as it was, and some uses are always prohibited; see the acceptable use policy. For how the main AI pentesting agents compare, see AI pentesting, PentAGI and Strix.

Troubleshooting

Symptom Cause Fix
Failed to establish connection to HexStrike AI API Server at http://127.0.0.1:8888 after 3 attempts, then every tool returns Request failed The server is not running, or listens on another port Start hexstrike_server first and check curl http://127.0.0.1:8888/health. The MCP script starts even when it can't reach the server, so the client can list it as connected while every call fails
ModuleNotFoundError: No module named 'mcp' The client started hexstrike_mcp.py with the system Python, outside your virtual environment (issue #14) Put the virtual environment's python3 path in the client config, as above. On Kali, use hexstrike_mcp
array too long. Expected an array with maximum length 128 or Tool limit exceeded (184/128) The client or its model API accepts at most 128 tools, and HexStrike offers about 150 (issue #119, issue #26) Turn off the tools you don't need: deny rules in Claude Code, permissions rules or Code Mode in OpenCode
A tool returns success: false with a not-found error in stderr The tool is not installed Check tools_status in /health, then install the tool. On Kali, most are apt packages
timed_out: true after five minutes The server stops each command after 300 seconds (COMMAND_TIMEOUT, issue #84) Narrow the scan: fewer ports, one host per call
Claude Code returns 400 naming defer_loading or tool_reference Claude Code's MCP tool search sends fields a gateway may not accept Set CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1, which keeps tool search off. Claude Code v2.1.305 and later retry without it automatically
404 Model "claude-..." is not available on abliterator A Claude Code model alias is not pinned Set all the model variables above
Claude Code replaces a scan result with a file path The result is over 25,000 tokens (MAX_MCP_OUTPUT_TOKENS) or 50,000 characters, so Claude Code saved it to a file Nothing is lost: the model reads the file when it needs it. To keep results inline, scan fewer ports per call

Frequently asked questions

What is HexStrike AI?

HexStrike AI is an open-source MCP server by Muhammad Osama (0x4m4), published under the MIT licence. A Python API server runs security tools such as nmap, gobuster and nuclei on a Linux host, and a small MCP script exposes them to an AI client as about 150 tools. The model comes from the client you connect, such as Claude Code or OpenCode.

How do I run HexStrike AI?

On Kali Linux, run sudo apt install hexstrike-ai, start hexstrike_server, and add hexstrike_mcp --server http://127.0.0.1:8888 to your MCP client as a stdio server. Elsewhere, clone github.com/0x4m4/hexstrike-ai, install requirements.txt in a Python 3.10+ virtual environment, and run python3 hexstrike_server.py. Run it in a disposable VM against targets you are allowed to test.

Is HexStrike AI free?

Yes. The code is MIT-licensed, and Kali packages it as hexstrike-ai. HexStrike itself calls no model, so what you pay for is the model behind your MCP client, for example kimi-k3.1-pro-abliterated or deepseek-v4.1-flash-abliterated on Abliterator.

Does HexStrike AI work with Claude?

The README documents Claude Desktop, which uses Anthropic's own models. Claude Code also runs HexStrike as a stdio MCP server, and Claude Code accepts ANTHROPIC_BASE_URL, so you can run the same setup on kimi-k3.1-pro-abliterated through Abliterator. Anthropic says Claude may block authorized penetration testing unless you join its Cyber Verification Program.

Try it in your browser.

Ask it something your usual model refuses.

Start a chat

No sign-up to try. $10 free when you verify your email.