CVE-2025-68145

mcp-server-git has missing path validation when using --repository flag

Published Dec 17, 2025 CVSS 4.0 · 6.4 Medium EPSS 7.0% KEV · Not listed
Description
In mcp-server-git versions prior to 2025.12.17, when the server is started with the --repository flag to restrict operations to a specific repository path, it did not validate that repo_path arguments in subsequent tool calls were actually within that configured path. This could allow tool calls to operate on other repositories accessible to the server process. The fix adds path validation that resolves both the configured repository and the requested path (following symlinks) and verifies the requested path is within the allowed repository before executing any git operations. Users are advised to upgrade to 2025.12.17 upon release to remediate this issue.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-j22h-9j4x-23w5 mcp-server-git has missing path validation when using --repository flag
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Lfprojects
Lfprojects model Context Protocol Servers
CPEs cpe:2.3:a:lfprojects:model_context_protocol_servers:*:*:*:*:*:*:*:*
Vendors & Products Lfprojects
Lfprojects model Context Protocol Servers
Metrics cvssV3_1

{'score': 9.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N'}

Type Values Removed Values Added
First Time appeared Modelcontextprotocol
Modelcontextprotocol servers
Vendors & Products Modelcontextprotocol
Modelcontextprotocol servers
Type Values Removed Values Added
Description In mcp-server-git versions prior to 2025.12.17, when the server is started with the --repository flag to restrict operations to a specific repository path, it did not validate that repo_path arguments in subsequent tool calls were actually within that configured path. This could allow tool calls to operate on other repositories accessible to the server process. The fix adds path validation that resolves both the configured repository and the requested path (following symlinks) and verifies the requested path is within the allowed repository before executing any git operations. Users are advised to upgrade to 2025.12.17 upon release to remediate this issue.
Title mcp-server-git has missing path validation when using --repository flag
Weaknesses CWE-22
References
Metrics cvssV4_0

{'score': 6.4, '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'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Dec 18, 2025, 3:06 PM
Reserved
Dec 15, 2025, 7:06 PM
Status
Analyzed
Published
Dec 17, 2025, 11:16 PM
Modified
Sep 30, 2026, 11:10 PM