iTranslated by AI

The content below is an AI-generated translation. This is an experimental feature, and may contain errors. View original article
🐉

Using GhidraMCP with GitHub Copilot

に公開

Personal notes on using GhidraMCP via GitHub Copilot.

I personally prefer this because I can use models with unlimited tokens without worrying about consumption, and I can work on other tasks simultaneously in the same window.

1. Prerequisites

  • Python environment (uv, venv, etc.)
  • VSCode
  • GitHub Copilot Pro (should be free for students)
  • Ghidra
  • GhidraMCP (As of 2025/10/25, the original repository supports Ghidra up to v11.3.2)

I will skip the setup for Ghidra and GitHub Copilot. The original author provides detailed instructions for the Ghidra-side configuration.

https://github.com/LaurieWired/GhidraMCP?tab=readme-ov-file#ghidra

2. Configure the MCP Server in VSCode

2.1 Open GitHub Copilot Chat and select the settings icon in the bottom right

2.2 Select Add MCP Server

2.3 Select command (stdio)

2.4 Enter the following in the command field

  • The python path is optional.
  • bridge_mcp_ghidra.py is included in the extracted GhidraMCP ZIP file (make sure to install the packages from requirements.txt as well).
/path/to/python3 /path/to/bridge_mcp_ghidra.py --ghidra-server http://127.0.0.1:8080/

2.5 Afterwards

  • The MCP server name is optional.
  • Saving it globally or to the workspace is also optional.
  • You can check the settings from the extensions tab.

3. Connection Verification

3.1 Start the MCP Server

  • After restarting VSCode, start the one you just added from the extensions tab.
  • If the output shows something like 20xx-xx-xx xx:xx:xx.xxx [info] Discovered xx tools, you are good to go.

3.2 Connect to Ghidra

  • Launch Ghidra and open the Code Browser.
  • Open GitHub Copilot Chat, switch to Agent mode, and enter an appropriate prompt.
  • Once Copilot begins analyzing using the tools, the connection is complete.
  • If you cannot connect, it is often because the HTTP Server is not running on the Ghidra side, so it is better to restart Ghidra and check the console logs.
Prompt Examples
Verify the connection with GhidraMCP
Connect to Ghidra and tell me the address of the main function

Discussion