Path Traversal in mcp-server-git (CVE-2026-27735)
Summary
Path traversal in mcp-server-git (CVE-2026-27735). Risk of unauthorized operations or information disclosure. Exploitable via git_add. Mitigation: upgrade to 2026.1.14 or later.
Original description
The description as published by the source.
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. The tool used GitPython's repo.index.add(, which did not enforce working-tree boundary checks for relative paths. As a result, relative paths containing ../ sequences that resolved outside the repository were accepted and staged into the Git index, potentially allowing sensitive files to be exfiltrated via subsequent commit and push operations. The fix in PR #3164 switches to repo.git.add(), which delegates to the Git CLI and properly rejects out-of-tree paths. Users are advised to upgrade to 2026.1.14 or newer to remediate this issue.
mcp-server-git thanks https://hackerone.com/0dd-g for reporting and contributing the fix.
Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2026-27735 has been found in mcp-server-git.
Attackers can target a specific entry point like git_add over the network to misuse the product.
Risk of unauthorized operations or information disclosure.
What to do: upgrade mcp-server-git to 2026.1.14 or later.
If unsure, ask your IT team or search "mcp-server-git CVE-2026-27735" on the vendor's site.
CVE-2026-27735 (mcp-server-git) — CWE-22
Attack surface: git_add
Patched: 2026.1.14 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
Path traversal (CWE-22) exists in mcp-server-git. Attackers reach the vulnerable code path via git_add.
Check the vendor advisory for the affected versions of mcp-server-git. Attack surface: git_add.
Severity: ?. Risk of unauthorized operations or information disclosure.
Update to 2026.1.14.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'mcp-server-git' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'mcp-server-git' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
mcp-server-gitを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply patch patch
Upgrade mcp-server-git to 2026.1.14ステージング環境で 2026.1.14 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- package github.com
- web github.com
- web github.com
- web github.com