NoOne-hub/JSReverser-MCP
NoOne-hub/JSReverser-MCP has 1,049 GitHub stars and 196 forks. GitHot measured +1 stars in 24 hours. Last checked 2026-11-09 11:33 UTC. Last push 2026-05-31.
JSReverser-MCP 是一个面向 JavaScript 逆向分析的 MCP 工具,专门用于帮助开发者在真实浏览器环境中高效定位前端核心逻辑。它 将脚本检索、断点调试、函数 Hook、网络请求追踪、调用链分析、混淆还原和风险评估整合为统一能力,可直接接入 Claude、 Codex、Cursor 等支持 MCP 的客户端。你可以连接已开启的 Chrome,在登录态页面下持续采样请求参数与返回数据,快速定位签名、 加密、鉴权和关键业务流程。工具同时支持自动化页面操作与结构化报告导出,适合用于接口分析、安全研究、前端调试与工程排障等 场景
Measured star growth
- in 24h
- +1
- in 7 days
- Update delayed
- in 15 days
- Update delayed
- in 1 month
- Update delayed
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.en.md
OriginalJS Reverse MCP
An MCP server that standardizes frontend JavaScript reverse-engineering workflows. The goal is not just page debugging. It is to connect page observation, runtime sampling, local reproduction, environment patching, and evidence capture into one reusable workflow.
Core Methodology
This project follows these defaults:
Observe-firstHook-preferredBreakpoint-lastRebuild-orientedEvidence-firstPure-extraction-after-pass
In practice, that means:
- Confirm requests, scripts, functions, and dependencies in the browser first.
- Use the smallest possible hook-based sampling.
- Export a local rebuild bundle.
- Patch the Node environment step by step.
- Persist every step into task artifacts instead of leaving it only in chat history.
Indexed Cases
The following parameter chains already have public in-repo entry points:
JD
h5stKuaishou
falconDouyin
a-bogus
Notes:
- The homepage only shows sanitized parameter categories and public entry points.
- Real
artifacts/tasks/<task-id>/directories are treated as local/private task folders by default. - Git only tracks
artifacts/tasks/_TEMPLATE/by default.
Parameter Blueprint Knowledge Base
Public parameter methods are kept in the parameter blueprint knowledge base at docs/knowledge/parameter-blueprints/.
node build/src/index.js --list-parameter-workflows
node build/src/index.js --show-parameter-workflow jd-h5st
node build/src/index.js --export-parameter-workflow-template
node build/src/index.js --validate-parameter-workflow docs/knowledge/parameter-blueprints/jd-h5st
Contribution rules: docs/guides/parameter-workflow-contribution.md.
Capabilities
Page Observation and Script Discovery
Use these tools to answer: what scripts are loaded, and where the target logic likely lives.
list_scriptsget_script_sourcefind_in_scriptsearch_in_scripts
Hooking and Runtime Sampling
Use lightweight observation before stepping into paused debugging.
create_hookinject_hookget_hook_datahook_functiontrace_function
Breakpoints and Debug Control
Use paused debugging only when hooks are not enough.
set_breakpointset_breakpoint_on_textresumepausestep_over/step_into/step_out
Request and Network Analysis
Locate the target request and identify what triggers it.
list_network_requestsget_network_requestget_request_initiatorbreak_on_xhr
Page State and Runtime Checks
Inspect browser state, logs, and storage dependencies.
check_browser_healthlist_console_messagesget_storageevaluate_scriptsearch_in_sources
WebSocket Inspection
Useful for long-lived connections, streaming flows, and binary frames.
list_websocket_connectionsanalyze_websocket_messagesget_websocket_messages
Local Rebuild and Environment Patching
Bring browser evidence back to a local Node workflow.
export_rebuild_bundlediff_env_requirementsrecord_reverse_evidence
Page Automation
Use the minimum page actions needed to reproduce a flow.
navigate_pagequery_domclick_elementhover_element/select_optiontype_textpress_key/upload_filescroll_page/wait_for_network_idleset_viewport/emulate_deviceget_all_linkstake_screenshot
Deep Analysis
Once code and runtime evidence are available:
collect_codeunderstand_codedeobfuscate_coderisk_panel
Session and Login-State Reuse
save_session_staterestore_session_statedump_session_stateload_session_state
Reverse Task Orchestration and Agent Consumption
start_reverse_task/manage_reverse_task: create, inspect, advance, and manage reverse-engineering tasks.orchestrate_reverse_task: advance observation, sampling, rebuild, verification, and extraction stages.run_reverse_agent: provide a one-shot task runner entry point for agents.query_reverse_task: read compact summaries, next-step guidance, artifact indexes, and resumable payloads.export_rebuild_bundlesupports portable bundle and replay bundle exports for handingenv-passresults to pure extraction work.
More details:
- docs/guides/reverse-task-orchestration.md
- docs/guides/mcp-agent-quick-reference.md
- docs/guides/mcp-client-auto-resume-example.md
- docs/reference/reverse-agent-response.schema.json
- docs/reference/reverse-agent-schema-versioning.md
For full parameter details, see docs/reference/tool-reference.md. For workflow-oriented tool selection, see docs/reference/reverse-workflow.md.
External AI Configuration
The project supports external LLMs as an analysis enhancement layer. Currently supported providers:
openaianthropicgemini
The real configuration surface is environment variables.
When launched from an MCP client, prefer passing them via the MCP server env block.
Use .env mainly when you run node build/src/index.js or npm run start directly from the project root.
Example:
[mcp_servers.js-reverse]
command = "node"
args = ["/ABSOLUTE/PATH/JSReverser-MCP/build/src/index.js"]
[mcp_servers.js-reverse.env]
DEFAULT_LLM_PROVIDER = "anthropic"
ANTHROPIC_API_KEY = "your_key"
ANTHROPIC_MODEL = "claude-3-5-sonnet-20241022"
If you start the project locally from the repository root, you can also use .env:
DEFAULT_LLM_PROVIDER=gemini
# OpenAI
OPENAI_API_KEY=your_key
OPENAI_MODEL=gpt-4o
OPENAI_BASE_URL=
# Anthropic
ANTHROPIC_API_KEY=your_key
ANTHROPIC_MODEL=claude-3-5-sonnet-20241022
ANTHROPIC_BASE_URL=
# Gemini
GEMINI_API_KEY=your_key
GEMINI_MODEL=gemini-2.0-flash-exp
# Optional Gemini CLI fallback
GEMINI_CLI_PATH=gemini-cli
Notes:
DEFAULT_LLM_PROVIDERselects the default provider.geminisupports two modes: API mode whenGEMINI_API_KEYis present, or CLI mode viaGEMINI_CLI_PATH.openaiandanthropicrequire their own API keys.understand_codestill returns local static analysis when AI is unavailable and includesaiRuntimeso clients can see provider or fallback status.useAIis a tool parameter, not an environment variable. Pass it on tools such asdetect_cryptowhen you want optional AI enhancement.
Standard Task Layout
Task directories use:
artifacts/tasks/_TEMPLATE/artifacts/tasks/<task-id>/
Recommended structure:
task.jsonruntime-evidence.jsonlnetwork.jsonlscripts.jsonlenv/env.jsenv/polyfills.jsenv/entry.jsenv/capture.jsonrun/report.md
Responsibility boundaries:
env.js- Minimal host objects and shims
polyfills.js- Proxy diagnostics,
watch,safeFunction,makeFunction
- Proxy diagnostics,
entry.js- Runtime entry, target script loading, and first-divergence output
Standard Execution Flow
Recommended flow:
- Page observation
- Runtime sampling
- Evidence capture
- Local rebuild
- Environment patching
- First-divergence analysis
- Pure extraction only after
env-pass
Default rules:
- Do not guess the environment before collecting browser evidence.
- Do not simulate the whole browser at once.
- Do not commit real task directories directly.
Parameter Retention and Safety Boundary
Recommended lookup order:
- Local task artifacts first
artifacts/tasks/<task-id>/
- Abstract case scripts second
scripts/cases/*
- Create from templates if still missing
Safety boundary:
- Cases only keep abstract methodology and workflow.
- Real task directories stay local by default.
- Sensitive values must be sanitized before sharing.
- Git only tracks
_TEMPLATEby default.
See:
- docs/reference/case-safety-policy.md
- docs/reference/reverse-artifacts.md
- docs/reference/env-patching.md
Tool Exposure Modes
The default startup mode is --toolProfile kernel.
This mode exposes 35 automation-first tools to reduce MCP tool-list token usage while keeping task orchestration, request tracing, code location, diagnostics, and artifact export entry points visible.
It does not mean tools are missing; low-frequency manual debugging tools are hidden by default.
Use --toolProfile compact when you need broader workflow controls.
compact exposes 63 high-frequency tools for manual page actions, hooks, screenshots, and environment adjustments.
Use --toolProfile full when you need the complete tool set.
full exposes all 110 tools, including pause, stepping, breakpoints, WebSocket details, and fine-grained DOM controls.
Switch to full for deep manual debugging, precise breakpoint work, or WebSocket message inspection.
node build/src/index.js --toolProfile full
Successful responses default to --traceOutput errors, which keeps traceId metadata only on error responses.
Use --traceOutput all when every successful response should include traceId metadata.
3-Minute Quick Start
1) Install and build
npm install
npm run build
Build entry:
build/src/index.js
2) Start with the simplest command
npm run start
3) Configure your MCP client
Minimal examples:
Claude Code
claude mcp add js-reverse node /ABSOLUTE/PATH/JSReverser-MCP/build/src/index.js
Cursor
- Command:
node - Args:
[/ABSOLUTE/PATH/JSReverser-MCP/build/src/index.js]
Codex
[mcp_servers.js-reverse]
command = "node"
args = ["/ABSOLUTE/PATH/JSReverser-MCP/build/src/index.js"]
If you need to attach to an already running browser, continue with:
Documentation Entry Points
For reverse-engineering tasks, start with:
That entry will further route you to:
- docs/reference/case-safety-policy.md
- docs/reference/reverse-workflow.md
- docs/reference/pure-extraction.md when you are already in the post-
env-passstage
Guides
- docs/guides/getting-started.md
- docs/guides/browser-connection.md
- docs/guides/client-configuration.md
- docs/reference/reverse-workflow.md
- docs/reference/env-patching.md
Reference
- docs/reference/reverse-bootstrap.md
- docs/reference/reverse-task-index.md
- docs/reference/tool-reference.md
- docs/reference/tool-io-contract.md
- docs/reference/reverse-artifacts.md
Templates and Supporting Docs
- docs/reference/reverse-update-prompt-template.md
- docs/reference/reverse-report-template.md
- docs/reference/algorithm-upgrade-template.md
- docs/reference/parameter-methodology-template.md
- docs/reference/parameter-site-mapping-template.md
Development and Test
npm run build
npm run test:unit
npm run test:property
npm run coverage:full
Troubleshooting
See:
- docs/guides/browser-connection.md
- docs/guides/client-configuration.md
- docs/guides/troubleshooting.md
Upstream References
This project references the following upstream projects during design and implementation. Actual licenses such as MIT should be checked in the corresponding upstream repositories.
- https://github.com/wuji66dde/jshook-skill
- https://github.com/zhizhuodemao/js-reverse-mcp
- https://github.com/ChromeDevTools/chrome-devtools-mcp
License
Apache-2.0
Explore related projects
codecrafters-io/build-your-own-x
Master programming by recreating your favorite technologies from scratch.
561,398 starspublic-apis/public-apis
A collective list of free APIs
497,678 starsmorluto/rea
Reverse engineer anything with agents, from app behavior down to native binaries.
447,485 starsopenclaw/openclaw
The AI that really does things. Any OS. Any Platform. The lobster way. 🦞
394,262 stars