Skip to content

Hide Navigation Hide TOC

FastMCP Windows cmd.exe Injection via Server Name Metacharacters (CVE-2025-64340) - ATR-2026-00537 (089ca0aa-e430-5ede-9c01-0c3afd8a144f)

Detects CVE-2025-64340 (CVSS 7.8 HIGH, CWE-78): FastMCP < 3.2.0 on Windows passes the MCP server name field unsanitized into cmd.exe when installing via fastmcp install claude-code or fastmcp install gemini-cli. The target CLIs resolve to .cmd wrapper scripts; cmd.exe interprets the flattened argument string, executing any metacharacters embedded in the name. PoC: FastMCP(name="test&calc") opens Calculator. Confirmed injection characters: &, |, >, ^, (, ). The fix in 3.2.0 restricts names to [A-Za-z0-9\-_.\ ] only. Detection covers: (a) MCP server name fields containing cmd.exe metacharacters in JSON/YAML configuration blobs that would be passed to a shell-backed installer; (b) FastMCP install invocations with server names containing these characters; (c) Content describing exploitation of this specific vector. Scan target: MCP exchange (tool_response, content) and user_input for configuration payloads. False-positive rate expected low because legitimate server names do not require & | > ^ ( ).

Cluster A Galaxy A Cluster B Galaxy B Level
FastMCP Windows cmd.exe Injection via Server Name Metacharacters (CVE-2025-64340) - ATR-2026-00537 (089ca0aa-e430-5ede-9c01-0c3afd8a144f) Agent Threat Rules Exploit Public-Facing Application - T1190 (3f886f2a-874f-4333-b794-aa6075009b1c) Attack Pattern 1
Windows Command Shell - T1059.003 (d1fcf083-a721-4223-aedf-bf8960798d62) Attack Pattern FastMCP Windows cmd.exe Injection via Server Name Metacharacters (CVE-2025-64340) - ATR-2026-00537 (089ca0aa-e430-5ede-9c01-0c3afd8a144f) Agent Threat Rules 1
Exploit Public-Facing Application (47d73872-5336-44f7-81e3-d30bc7e039dd) MITRE ATLAS Attack Pattern FastMCP Windows cmd.exe Injection via Server Name Metacharacters (CVE-2025-64340) - ATR-2026-00537 (089ca0aa-e430-5ede-9c01-0c3afd8a144f) Agent Threat Rules 1
FastMCP Windows cmd.exe Injection via Server Name Metacharacters (CVE-2025-64340) - ATR-2026-00537 (089ca0aa-e430-5ede-9c01-0c3afd8a144f) Agent Threat Rules AI Model Inference API Access (90a420d4-3f03-4800-86c0-223c4376804a) MITRE ATLAS Attack Pattern 1
Command and Scripting Interpreter - T1059 (7385dfaf-6886-4229-9ecd-6fd678040830) Attack Pattern Windows Command Shell - T1059.003 (d1fcf083-a721-4223-aedf-bf8960798d62) Attack Pattern 2