Kali Linux MCP Server

Kali Linux MCP Server

Enables AI assistants to perform penetration testing and security assessments by exposing 60+ Kali Linux security tools including network scanning, web security testing, password cracking, exploitation frameworks, and OSINT capabilities through an AI-friendly interface.

Category
Visit Server

README

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)

Quick Start

Docker (Recommended)

# 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

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
E2B

E2B

Using MCP to run code via e2b.

Official
Featured