Frida MCP Server

Frida MCP Server

Enables dynamic instrumentation of running processes through Frida, allowing users to hook functions, inspect memory, modify process behavior, and execute JavaScript code for debugging and reverse engineering.

Category
访问服务器

README

Frida MCP Server

A MCP server that provides dynamic instrumentation capabilities through Frida. Built with TypeScript and optimized for Bun runtime.

Features

  • Dynamic Instrumentation: Hook functions, inspect memory, and modify behavior of running processes
  • Device Management: Support for local, USB, and remote Frida devices
  • Process Control: Spawn, attach, resume, and kill processes
  • Interactive Sessions: Create persistent sessions for complex instrumentation workflows
  • Script Execution: Execute JavaScript code with both one-shot and persistent modes
  • File Operations: Download files from instrumented processes and query module information

Prerequisites

  • Bun >= 1.0.0
  • Frida >= 17.0.0 (installed on target system)

Installation

# Clone the repository
git clone https://github.com/nonsleepr/frida-mcp.ts
cd frida-mcp.ts

# Install dependencies
bun install

Configuration

Environment Variables

  • FRIDA_REMOTE_HOST: Remote Frida server hostname/IP (e.g., "192.168.1.100")
  • FRIDA_REMOTE_PORT: Remote Frida server port (default: 27042)

Claude Desktop Configuration

Add to your Claude Desktop config file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "frida": {
      "command": "bun",
      "args": ["run", "/path/to/frida-mcp.ts/src/index.ts"]
    }
  }
}

Roo Configuration

This project includes a pre-configured .roo/mcp.json file for project-level MCP server configuration. The configuration is automatically available when you open this project in VS Code with Roo installed.

Project Configuration (.roo/mcp.json):

{
  "mcpServers": {
    "frida": {
      "command": "bun",
      "args": ["run", "src/index.ts"],
      "env": {
        "FRIDA_REMOTE_HOST": "",
        "FRIDA_REMOTE_PORT": "27042"
      },
      "disabled": false,
      "alwaysAllow": []
    }
  }
}

To use with a remote Frida device: Edit .roo/mcp.json and set the FRIDA_REMOTE_HOST environment variable:

"env": {
  "FRIDA_REMOTE_HOST": "192.168.1.100",
  "FRIDA_REMOTE_PORT": "27042"
}

Available Tools

Device & Process Management

Tool Description Parameters
attach_to_process Attach to a running process by PID. Returns attachment status without creating a persistent session. Use create_interactive_session for session-based instrumentation. pid (number)<br>device_id (optional string or connection string hostname:port)
spawn_process Spawn a process with Frida attached in paused state. The process will be paused at startup. Use resume_process() after loading scripts to continue execution. program (string)<br>args (optional string[])<br>device_id (optional string or connection string)
resume_process Resume a spawned process. pid (number)<br>device_id (optional string or connection string)
kill_process Kill a process by PID. pid (number)<br>device_id (optional string or connection string)

Interactive Sessions

Tool Description Parameters
create_interactive_session Create an interactive session for dynamic instrumentation. Establishes a Frida session for injecting JavaScript, hooking functions, and monitoring the target process. The session persists until explicitly closed or the process terminates. process_id (number)<br>device_id (optional string or connection string)
execute_in_session Execute JavaScript code within an existing Frida session.<br><br>Modes:<br>• keep_alive=false (default): Script runs once, results in initial_logs<br>• keep_alive=true: Script persists for hooks, retrieve messages via frida://sessions/{session_id}/messages resource session_id (string)<br>javascript_code (string)<br>keep_alive (optional boolean, default: false)
load_script_file Load and execute a Frida JavaScript file into an existing session. session_id (string)<br>script_path (string)<br>keep_alive (optional boolean, default: true)

File Operations

Tool Description Parameters
download_file Download a file from remote system using Frida instrumentation. Uses double backslashes for Windows paths. Attaches to specified PID or finds explorer.exe. Works best for files up to ~500MB with 60s timeout. file_path (string)<br>output_path (string)<br>pid (optional number)<br>device_id (optional string or connection string)

Available Resources

Resources provide real-time, read-only access to Frida state via URI.

Direct Resources

URI Description
frida://devices List all connected Frida devices
frida://sessions List all active Frida sessions and their statuses

Resource Templates

URI Template Description
frida://devices/{device_id} Get detailed information about a specific device by ID
frida://devices/{device_id}/processes List processes on a specific Frida device. Use "local", "usb", or "remote" for automatic device selection, provide a specific device ID, or use a connection string (hostname:port or hostname).
frida://devices/{device_id}/processes/by-name/{process_name} Find a process by name (case-insensitive partial match) on a specific device. Supports connection strings (hostname:port or hostname).
frida://devices/{device_id}/processes/{pid}/module Get main module information for a process (path, base address, size). Supports connection strings (hostname:port or hostname).
frida://sessions/{sessionId}/messages Retrieve messages from persistent scripts. Append /last:N to limit results (e.g., /last:10 for last 10 messages) or /all for unlimited. Default limit is 100 messages. Messages are consumed when retrieved.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选