/

CVE-2026-79538

Severity:

CRITICAL RISK

(9.8)

Code Injection (CWE-94) in MetaMCP MCP Inspector Proxy

CVE-2026-79538

Deferred

Vulnerability type

Category:

Code Injection

CWE:

CWE-94

Impact:

Remote Code Execution

Severity:

CRITICAL RISK

(9.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

A critical code execution vulnerability in MetaMCP's internal MCP inspector proxy endpoint may allow attacker-controlled input to influence how an MCP server transport is created.

When the affected endpoint is reachable and the relevant request reaches the vulnerable STDIO handling path, an attacker could execute code with the privileges of the MetaMCP process.

Affected context

The issue affects MetaMCP deployments using versions up to and including 2.4.22 where the internal MCP inspector proxy endpoint is exposed or otherwise reachable. The relevant code is the GET /mcp-proxy/server/stdio route, specifically the createTransport STDIO branch in routers/mcp-proxy/server.ts; exploitability depends on network exposure, authentication controls, and how endpoint parameters are handled.

Exploit preconditions

  • Attack surface: The MCP inspector proxy HTTP endpoint at /mcp-proxy/server/stdio
  • Required access: Network reachability and any authentication or authorization access enforced by the deployment
  • Trigger point: A request processed by the endpoint's createTransport STDIO branch
  • Why exploitation is possible: Attacker-controlled request data may reach code-generation or command-construction behavior without sufficient separation between data and executable instructions

Why this happens

The vulnerability is an instance of CWE-94: Improper Control of Generation of Code. The affected proxy logic may construct or invoke a server transport using values influenced by an HTTP request without adequately constraining them to inert, validated data. When input is incorporated into executable expressions, commands, or runtime configuration, specially crafted values can alter program behavior and cause code execution.

Potential impact

  • An attacker may execute arbitrary code with the privileges of the MetaMCP process
  • The application could be compromised or used to access connected MCP services
  • Sensitive environment variables, configuration, or credentials could be exposed
  • An attacker could modify application data or disrupt MCP operations
  • The host or surrounding infrastructure could be used for lateral movement, depending on isolation

General mitigation guidance

Mitigation generally focuses on keeping request data separate from executable logic and reducing exposure of internal proxy functionality.

Common defensive patterns include:

  • Replacing dynamic command or code construction with fixed, allowlisted transport mappings
  • Applying strict type, format, length, and character validation before transport creation
  • Avoiding shell interpretation and runtime evaluation of request-derived values
  • Requiring authentication and authorization for inspector and proxy endpoints
  • Binding internal diagnostic interfaces to restricted networks rather than public interfaces
  • Running the service with least privilege and isolating connected MCP processes
  • Limiting filesystem, process, network, and credential access available to the application
  • Treating all HTTP-derived values as untrusted, including values from authenticated clients

How teams detect issues like this

High-level detection can combine:

  • Static analysis for dynamic evaluation, shell invocation, string-based command construction, and unsafe process-spawn patterns using request data
  • Code review of the createTransport STDIO path and all values accepted by the MCP proxy route
  • API inventory checks to identify inspector or proxy endpoints exposed beyond trusted administrative networks
  • Runtime monitoring for unexpected child-process creation, unusual command arguments, and anomalous access to secrets or external services
  • Policy enforcement requiring allowlisted transport configurations, authentication, and authorization for internal tooling endpoints
  • Automated security review tools that flag tainted data flows from HTTP parameters into execution APIs

Sources

SourceLink
github.comgithub.com/metatool-ai/metamcp
traceforce.aitraceforce.ai/security-advisories/cve-2026-79538

Frequently asked

questions

It may be remotely exploitable when the MCP inspector proxy endpoint is network-reachable and a request can reach the vulnerable STDIO transport path. Actual scope depends on deployment exposure and access controls.

The available description does not establish whether authentication is required. The determining factors are the application's endpoint protections and whether an attacker can submit requests that reach /mcp-proxy/server/stdio.

Separate request data from executable behavior by using fixed, allowlisted transport configurations and non-interpreting process APIs. Restrict the endpoint to authenticated, authorized administrative callers.

Treat all request-derived values as untrusted, validate them against strict schemas, review data flows into execution APIs, and enforce network, privilege, and process-isolation controls for internal MCP tooling.

Find out what's already
exploitable in your codebase.