ffdecmcp

ffdecmcp

MCP wrapper for JPEXS Free Flash Decompiler (FFDec) that exposes SWF decompilation and analysis tools to AI assistants like Claude.

Category
访问服务器

README

ffdecmcp

MCP (Model Context Protocol) wrapper for JPEXS Free Flash Decompiler (FFDec) - expose SWF decompilation and analysis tools to AI assistants like Claude.

Tools

1. decompile_swf

Decompile all ActionScript code from a SWF file to organized directory structure.

Parameters:

  • swf_path (required): Absolute path to SWF file
  • output_dir (required): Directory for decompiled scripts
  • timeout (optional): Timeout in seconds (default: 60)

2. extract_actionscript

Extract specific ActionScript classes by name (AS3 only). Faster than full decompilation when you only need specific classes.

Parameters:

  • swf_path (required): Absolute path to SWF file
  • class_names (required): List of class names (e.g., ['com.example.Main'])
  • output_dir (required): Directory for extracted classes
  • timeout (optional): Timeout in seconds (default: 60)

3. list_symbols

List all ActionScript classes and symbols in a SWF file. Great for exploring a SWF before full decompilation.

Parameters:

  • swf_path (required): Absolute path to SWF file

Returns: Structured JSON with packages, classes, and total count

4. extract_assets

Extract images, sounds, fonts, shapes, movie clips, and binary data from SWF.

Parameters:

  • swf_path (required): Absolute path to SWF file
  • output_dir (required): Directory for extracted assets
  • asset_types (optional): Types to extract - image, sound, font, shape, movie, binaryData, all (default: ["all"])
  • timeout (optional): Timeout in seconds (default: 60)

5. get_swf_metadata

Extract SWF header information (dimensions, frame rate, compression, etc.). Fast and doesn't require decompilation.

Parameters:

  • swf_path (required): Absolute path to SWF file

Returns: JSON with version, width, height, frame_rate, frame_count, compression

6. deobfuscate

Run FFDec's deobfuscation algorithms to remove obfuscation and anti-decompilation tricks.

Parameters:

  • swf_path (required): Absolute path to obfuscated SWF
  • output_path (required): Path for deobfuscated SWF
  • level (optional): Deobfuscation level - traps, deadcode, max (default: max)
  • timeout (optional): Timeout in seconds (default: 60)

Quick Start

Prerequisites: Python 3.10+ and Java (for running the FFDec JAR).

Claude Code

claude mcp add ffdecmcp -- uvx ffdecmcp

That's it. On first run, FFDec will be auto-downloaded if not already installed.

Claude Desktop

Add to your config file (~/Library/Application Support/Claude/claude_desktop_config.json on macOS, %APPDATA%\Claude\claude_desktop_config.json on Windows):

{
  "mcpServers": {
    "ffdecmcp": {
      "command": "uvx",
      "args": ["ffdecmcp"]
    }
  }
}

Standalone

# Just run it - FFDec will be auto-downloaded to ~/.ffdecmcp/ if needed
uvx ffdecmcp

# Or point to an existing FFDec installation
uvx ffdecmcp --ffdec-path /path/to/ffdec.jar

Installation

No installation is required when using uvx. For a permanent install:

uv pip install ffdecmcp
# or
pip install ffdecmcp

FFDec

FFDec is automatically downloaded on first run if not found. You can also install it manually.

The server finds FFDec in this order:

  1. --ffdec-path CLI arg / FFDEC_PATH env var
  2. Previously auto-downloaded JAR (~/.ffdecmcp/ffdec.jar)
  3. Common install locations and PATH
  4. Auto-download from GitHub

CLI Options

ffdecmcp [--ffdec-path PATH] [--timeout SECONDS]
Option Env Var Description
--ffdec-path FFDEC_PATH Path to FFDec (JAR, native binary, or WSL path)
--timeout FFDEC_TIMEOUT Default timeout in seconds (default: 60)

CLI arguments take precedence over environment variables.

Development

git clone https://github.com/sublimnl/ffdecmcp.git
cd ffdecmcp
uv pip install -e ".[dev]"

Example Usage in Claude

You: Can you analyze this SWF file for me?
Path: C:\Users\foo\game.swf

Claude will:
1. Use get_swf_metadata to check dimensions, version, etc.
2. Use list_symbols to see what classes are present
3. Use decompile_swf to extract all ActionScript code
4. Analyze the decompiled code and provide insights

References

  • FFDec: https://github.com/jindrapetrik/jpexs-decompiler
  • FFDec CLI Docs: https://github.com/jindrapetrik/jpexs-decompiler/wiki/Commandline-arguments
  • Model Context Protocol: https://modelcontextprotocol.io
  • FastMCP: https://github.com/jlowin/fastmcp

License

MIT License - see LICENSE file for details

Contributing

Contributions welcome! Please open an issue or PR on GitHub.

推荐服务器

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 模型以安全和受控的方式获取实时的网络信息。

官方
精选