Skip to main content
Glama
ofryma

Kali Linux MCP Server

by ofryma

Kali Linux MCP Server

A Model Context Protocol (MCP) server that exposes 60+ Kali Linux security tools through an AI-friendly interface. Enables AI assistants like Claude to perform penetration testing and security assessments.

Features

Network Scanning: nmap, masscan, netdiscover, hping3, tcpdump, tshark
Web Security: gobuster, nikto, sqlmap, wpscan, burpsuite, zap, ffuf, nuclei
Password Cracking: hydra, john, hashcat, medusa, crackmapexec
Exploitation: metasploit, searchsploit, beef, routersploit
Wireless: aircrack-ng, reaver, wifite, kismet
Windows/AD: enum4linux, impacket, evil-winrm, kerbrute, mimikatz, responder
OSINT: theharvester, shodan, spiderfoot, amass, sublist3r
Forensics: binwalk, foremost
Plus: shells (netcat, socat, msfvenom), anonymity (proxychains), mobile (apktool)

Related MCP server: MCP Kali Server

Quick Start

# Start Kali API server
make run

# Or manually
docker-compose up -d
python mcp_http_server.py

Manual Setup

# Install dependencies
pip install -r requirements.txt

# Run Kali API server (requires Kali Linux)
python kali_server.py

# Run MCP HTTP server
python mcp_http_server.py --kali-server http://localhost:5001

Configure Cursor/Claude

Add to your MCP settings:

{
  "mcpServers": {
    "kali-tools": {
      "url": "http://localhost:5002/sse"
    }
  }
}

Architecture

  • kali_server.py: Flask REST API exposing Kali tools

  • mcp_http_server.py: MCP-over-HTTP bridge to Kali API

  • server/tools/: Tool implementations organized by category

  • Docker: Kali Linux container with all tools pre-installed

Requirements

  • Python 3.8+

  • Docker (for containerized deployment)

  • Kali Linux environment (for manual setup)

Testing

The project includes a comprehensive test suite using pytest.

Quick Start

# Setup test environment
./scripts/setup_tests.sh

# Run all tests
make test

# Run with coverage
make test-coverage

# Run only unit tests (fast)
make test-unit

# Run integration tests
make test-integration

Test Structure

tests/
├── test_kali_client.py           # HTTP client tests
├── test_kali_server.py           # Flask API endpoint tests
├── test_command_executor.py      # Command execution tests
├── test_mcp_server.py            # MCP server setup tests
├── test_integration.py           # Integration tests
└── test_tools/                   # Tool-specific tests
    ├── test_network_scanning.py
    ├── test_web_scanning.py
    └── test_password_cracking.py

Available Test Commands

make test              # Run all tests
make test-unit         # Run unit tests only
make test-integration  # Run integration tests only
make test-coverage     # Run tests with coverage report
make test-file FILE=tests/test_kali_client.py  # Run specific file
make clean             # Clean up test artifacts
make help              # Show all available commands

Coverage Reports

After running make test-coverage, view the HTML report:

open htmlcov/index.html

Continuous Integration

Tests run automatically on GitHub Actions for:

  • Multiple Python versions (3.9, 3.10, 3.11, 3.12)

  • Every push to main/develop branches

  • All pull requests

See tests/README.md for detailed testing documentation.

License

MIT License - See LICENSE file

A
license - permissive license
-
quality - not tested
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    -
    quality
    -
    maintenance
    Enables AI assistants to execute penetration testing commands and security tools on Kali Linux remotely. Supports automated reconnaissance, vulnerability scanning, and CTF solving through integration with 25+ offensive security tools like nmap, gobuster, and nuclei.
    Last updated
    16
  • F
    license
    -
    quality
    D
    maintenance
    Connects AI assistants to 55+ Kali Linux security tools for automated CTF solving, penetration testing, and security analysis across 7 categories including cryptography, forensics, web security, and binary exploitation.
    Last updated
    47

View all related MCP servers

Related MCP Connectors

  • Pay-per-call cybersecurity for AI agents: vuln scans, threat intel, compliance, code security.

  • Offline methodology engine for authorized penetration testing, CTF, and security research.

  • 54 AI agent tools: OSINT, intel feeds, DeFi, crypto, weather, DNS, proxies. x402 micropayments.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ofryma/custom-mcp-library'

If you have feedback or need assistance with the MCP directory API, please join our Discord server