UTC
High

mcp-server-git: arbitrary command execution via a repository's own Git configuration (core.fsmonitor) during read-only tools

GHSA-6hqx-gqrx-c5r2 · published 2026-11-11

Severity
High
CVSS score
7.8
Chance of exploitation (EPSS)
No CVE
Fixed in
2026.11.11
What it is

Arbitrary code execution as the user running the MCP server. A developer running uvx mcp-server-git executes the payload as themselves; a CI/agent runner executes it as the runner account. Credential and data theft. The payload inherits the server's environment — including any secrets passed through the MCP client's env block — and can read the user's home directory, SSH keys, cloud credentials and every repository on the disk. No approval and no sandbox. The execution happens inside git, not through the model's own command-execution tool, so client-side confirmation dialogs and tool sandboxes never engage. From the client's perspective it merely asked Git for status. No visible signal. …

What to do

Upgrade mcp-server-git to 2026.11.11 or later. If you start it from an MCP config with npx or uvx, pin that version so an old cached copy is not used.

Fixed in mcp-server-git 2026.11.11 (#5514). Upgrade to 2026.11.11 or later. The report below was written against 2026.11.4, before the fix; its "Fixed versions: none" line predates it. The fix covers every sink the report lists, not only core.fsmonitor: Every Git command the server runs overrides, through GIT_CONFIG_COUNT (which outranks every configuration file and is inherited by the Git processes Git itself starts), the settings that would make Git run a program: core.fsmonitor is false; core.hooksPath points at the null device, so no hook runs; commit.gpgSign and merge.verifySignatures are false; submodule.recurse, status.submoduleSummary and merge.autoStash are false; and core.pager is…

If you cannot upgrade yet

None for affected versions other than upgrading. Until then, point the server only at repositories whose .git directory you trust.

Affected
PackageRegistryAffectedFixed in
mcp-server-gitPyPI< 2026.11.112026.11.11

The impact, patch and workaround text comes from the advisory, shortened (published by the MCP reference servers project). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.

Sources: GitHub Advisory Database, reviewed and malware advisories (CC BY 4.0, https://github.com/advisories); advisories published by Cursor (https://github.com/cursor/cursor/security/advisories); advisories published by OpenClaw (https://github.com/openclaw/openclaw/security/advisories); advisories published by vLLM (https://github.com/vllm-project/vllm/security/advisories); advisories published by Open WebUI (https://github.com/open-webui/open-webui/security/advisories); advisories published by n8n (https://github.com/n8n-io/n8n/security/advisories); advisories published by Flowise (https://github.com/FlowiseAI/Flowise/security/advisories); advisories published by Langflow (https://github.com/langflow-ai/langflow/security/advisories); advisories published by the MCP Python SDK project (https://github.com/modelcontextprotocol/python-sdk/security/advisories); advisories published by the MCP reference servers project (https://github.com/modelcontextprotocol/servers/security/advisories); advisories published by the MCP Inspector project (https://github.com/modelcontextprotocol/inspector/security/advisories); advisories published by the MCP TypeScript SDK project (https://github.com/modelcontextprotocol/typescript-sdk/security/advisories); advisories published by the MCP Go SDK project (https://github.com/modelcontextprotocol/go-sdk/security/advisories); advisories published by the MCP Java SDK project (https://github.com/modelcontextprotocol/java-sdk/security/advisories); advisories published by the MCP Kotlin SDK project (https://github.com/modelcontextprotocol/kotlin-sdk/security/advisories); advisories published by the MCP Rust SDK project (https://github.com/modelcontextprotocol/rust-sdk/security/advisories); advisories published by the MCP Ruby SDK project (https://github.com/modelcontextprotocol/ruby-sdk/security/advisories); advisories published by the MCP C# SDK project (https://github.com/modelcontextprotocol/csharp-sdk/security/advisories); advisories published by the MCP PHP SDK project (https://github.com/modelcontextprotocol/php-sdk/security/advisories); advisories published by the MCP Registry project (https://github.com/modelcontextprotocol/registry/security/advisories); advisories published by Open Terminal (https://github.com/open-webui/open-terminal/security/advisories); advisories published by MLflow (https://github.com/mlflow/mlflow/security/advisories); CISA Known Exploited Vulnerabilities catalog (CC0). Data as of 2026-12-06. ShieldMap describes how each problem works and how to fix it; it does not publish exploit code. Report a correction to [email protected].