Vulnerability · Published Feb 25, 2026 · Assigned by GitHub_M
CVE-2026-27735mcp-server-git : Path traversal in git_add allows staging files outside repository boundaries
Medium 6.4
In plain English
A medium-severity path traversal in servers from modelcontextprotocol. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.3% (higher than 28% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Model Context Protocol Servers is a collection of reference implementations for the model context protocol (MCP). In mcp-server-git versions prior to 2026.1.14, the git_add tool did not validate that file paths provided in the files argument were within the repository boundaries. Because the tool used GitPython's repo.index.add() rather than the Git CLI, relative paths containing `../` sequences that resolve outside the repository were accepted and staged into the Git index. Users are advised to upgrade to 2026.1.14 or newer to remediate this issue.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| PyPI | mcp-server-git | 2026.1.14 | GHSA-vjqx-cfc4-9h6v |
| PyPI | mcp-server-git | 2026.1.14 | PYSEC-2026-2630 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| modelcontextprotocol | servers | < 2026.1.14 |
Weakness: CWE-22 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N
References
- https://github.com/modelcontextprotocol/servers/security/advisories/GHSA-vjqx-cfc4-9h6v x_refsource_CONFIRM
- https://github.com/modelcontextprotocol/servers/pull/3164 x_refsource_MISC