Sponsored by Deepsite.site

Metasploit MCP Server

Created By
xcape-inc9 months ago
Metasploit MCP Server
Content

Metasploit MCP Server

A Model Context Protocol (MCP) server for interacting with the Metasploit Framework through Python. This server provides a standardized interface for AI models to interact with Metasploit's functionality.

Features

  • Module Management
    • List available modules
    • Get detailed module information
    • Search for modules
  • Module Execution
    • Execute modules with custom options
    • Get and set module options
  • Session Management
    • List active sessions
    • Get session information
    • Read/write to sessions
    • Execute commands in sessions

Prerequisites

  • Python 3.12 or higher
  • Metasploit Framework with MSFRPC enabled
  • MCP client library
  • uv (Python package installer)

Installation

  1. Clone this repository
  2. Install dependencies:
    uv pip install -r requirements.txt
    

Configuration

Create a .env file with the following settings:

MSF_RPC_USERNAME=your_username
MSF_RPC_PASSWORD=your_password
MSF_RPC_HOST=127.0.0.1
MSF_RPC_PORT=55553
MSF_RPC_SSL=false

Usage

  1. Start the Metasploit RPC server:

    msfrpcd -P your_password -S -a 127.0.0.1
    
  2. Run the MCP server (this is also how your MCP client can run this server):

    uv --directory <path you cloned to> run python main.py --role viewer
    

Available Tools

Module Management

  • list_modules: List available Metasploit modules
  • module_info: Get detailed information about a specific module
  • search_modules: Search for modules matching a query

Module Execution

  • execute_module: Execute a module with specified options
  • get_options: Get available options for a module
  • set_option: Set an option for a module

Session Management

  • list_sessions: List all active sessions
  • session_info: Get detailed information about a session
  • session_write: Write data to a session
  • session_read: Read data from a session
  • run_command: Execute a command in a session

License

MIT License

Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
WindsurfThe new purpose-built IDE to harness magic
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
Playwright McpPlaywright MCP server
Serper MCP ServerA Serper MCP Server
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Amap Maps高德地图官方 MCP Server
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
ChatWiseThe second fastest AI chatbot™
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
Tavily Mcp
CursorThe AI Code Editor
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
DeepChatYour AI Partner on Desktop