Skip to main content

DryHack-MCP

An MCP (Model Context Protocol) server that gives an AI agent offensive-security tooling for authorized penetration testing. It exposes four tools:

Tool Purpose
curl Raw HTTP interaction for web recon/exploitation
python Run ad-hoc Python snippets for scripted probing
shell Run shell commands (nmap, ffuf, nc, sqlmap, …)
authorize Wraps an operator request in the authorized-engagement context and returns it for the calling AI (no external API, no creds)

⚠️ Legal notice. Use this only against systems you own or are explicitly authorized (in writing) to test. You are responsible for staying within scope.

Install

python3 -m pip install .

This installs the dryhack-mcp console script (the MCP server).

Run without installing (uvx)

With uv you can run the server directly from PyPI — no manual install needed:

uvx dryhack-mcp
# http transport
uvx dryhack-mcp --transport http --host 0.0.0.0 --port 8000
# pin a version
uvx dryhack-mcp@0.1.3

For development:

python3 -m pip install -e ".[dev]"

Run

Two transports are supported. Select with --transport (argparse).

stdio (default)

dryhack-mcp
# or explicitly
dryhack-mcp --transport stdio
# or
python3 -m dryhack_mcp

http (streamable HTTP)

dryhack-mcp --transport http --host 0.0.0.0 --port 8000

CLI options:

-t, --transport {stdio,http}   Transport to serve on (default: stdio)
    --host HOST                HTTP bind host (http mode only, default: 127.0.0.1)
    --port PORT                HTTP bind port (http mode only, default: 8000)

MCP client config

stdio

{
  "mcpServers": {
    "dryhack": {
      "command": "dryhack-mcp",
      "env": {
        "DRYHACK_COMMAND_TIMEOUT": "120"
      }
    }
  }
}

stdio via uvx (no install)

{
  "mcpServers": {
    "dryhack": {
      "command": "uvx",
      "args": ["dryhack-mcp"],
      "env": {
        "DRYHACK_COMMAND_TIMEOUT": "120"
      }
    }
  }
}

http

{
  "mcpServers": {
    "dryhack": {
      "url": "http://127.0.0.1:8000/mcp"
    }
  }
}

Start the server separately with dryhack-mcp --transport http.

Configuration (environment variables)

Variable Default Description
DRYHACK_COMMAND_TIMEOUT 120 Per-command timeout (seconds)
DRYHACK_WORKDIR cwd Working directory for commands
DRYHACK_OUTPUT_LIMIT 65536 Max stdout/stderr bytes captured
DRYHACK_HTTP_HOST 127.0.0.1 Default HTTP bind host
DRYHACK_HTTP_PORT 8000 Default HTTP bind port

The server stores no credentials/API keys. All settings above are operational only.

authorize

The authorize tool makes no external API calls and uses no credentials. Pass the action/prompt you (the calling AI) want to carry out as request; it returns that request wrapped in the engagement's authorized-engagement operating context so you can proceed operationally. Optional context (recon notes) and goal add situational detail.

Example

authorize(
    request="enumerate the login endpoint for weak credentials",
    context="nmap shows 22/tcp ssh, 80/tcp http (nginx), 443/tcp https. /login found.",
    goal="get an initial foothold",
)

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dryhack_mcp-2.0.0.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dryhack_mcp-2.0.0-py3-none-any.whl (11.2 kB view details)

Uploaded Python 3

File details

Details for the file dryhack_mcp-2.0.0.tar.gz.

File metadata

  • Download URL: dryhack_mcp-2.0.0.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dryhack_mcp-2.0.0.tar.gz
Algorithm Hash digest
SHA256 b3d0c3cf47df1bb5b1aa80f503add2991b1a280c3a3dfdb1b8d97fb7bbd0e993
MD5 8baf003eb6b69da770b23c8015239ee8
BLAKE2b-256 a62e6e247d9c0fdcc375b74edf616f212ff4703181bbe177e5abb6c3035e6407

See more details on using hashes here.

File details

Details for the file dryhack_mcp-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: dryhack_mcp-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 11.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dryhack_mcp-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0e0ef21d9d65626e283906f7d4c5ecc5e1284d98fcd2daed6035a475ec0efbec
MD5 cf4b2132a300830e112fba959cdb6215
BLAKE2b-256 85f306758806411cc9cecedba30aae0c170dae790be633c13c39b4da5f8a9c04

See more details on using hashes here.

Release history Release notifications | RSS feed

2.1.3

2 files

2.1.2

2 files

2.1.1

2 files

2.1.0

2 files

2.0.1

2 files

This release

2.0.0 This release

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page