Skip to main content

Model Context Protocol Servers CVE-2025-68145

MEDIUM
Path Traversal (CWE-22)
2025-12-17 security-advisories@github.com
6.4
CVSS 4.0 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Network access to MCP server
  2. Delivery
    Craft tool call with traversal path
  3. Exploit
    Bypass missing repo_path validation
  4. Execution
    Execute git operation on unintended repository
  5. Impact
    Exfiltrate or modify sensitive repository data

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Impact

CVSS 6.4 reflects moderate risk with network attack vector and low complexity, but no authentication requirement (PR:N) and user interaction needed (UI:P). The vector shows high scope impact (SC:H, SI:H) but no confidentiality compromise (VC:N, VI:N, VA:N) - meaning the vulnerability enables high-impact changes to system integrity rather than data exfiltration. EPSS data not provided. The KEV (Known Exploited Vulnerability) status is not confirmed in input, and no public exploit code is referenced, suggesting this is a proactively disclosed vulnerability. The real-world risk is elevated because: (1) path traversal in git operations can lead to unauthorized code execution if combined with git hooks or other mechanisms, (2) the --repository flag is explicitly a security boundary that attackers can bypass, and (3) MCP servers may be exposed to less-trusted clients. However, UI:P (user interaction required) and the nascent MCP ecosystem adoption limit immediate widespread exploitation. This is a legitimate priority requiring rapid patching, especially for production deployments.

Exploit ScenarioDerived

An attacker with network access to an mcp-server-git instance that was started with --repository=/home/user/safe-repo crafts a tool call with a repo_path argument such as ../../../etc/passwd or /home/user/sensitive-repo. Because path validation is absent in vulnerable versions, the server executes the requested git operation against the unintended repository, allowing the attacker to read repository metadata, exfiltrate code, or trigger malicious git hooks if present. User interaction (UI:P) is required only in the sense that an MCP client must invoke the tool - no public exploit code is known at time of analysis.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Apr 14, 2026

Path traversal in mcp-server-git prior to version 2025.12.17 allows unauthenticated remote attackers to access repositories outside the configured repository restriction via unvalidated repo_path arguments in tool calls. When the server is started with the --repository flag to isolate operations to a specific path, the application failed to verify that subsequent tool call arguments remained within that allowed directory, enabling access to other repositories on the same system. An attacker with network access and user interaction (UI:P) can exploit this to read or modify git repositories beyond the intended scope.

RemediationAI

Upgrade mcp-server-git to version 2025.12.17 or later, which includes path validation that resolves both the configured repository and requested paths (following symlinks) and verifies the requested path is within the allowed repository before executing git operations. If immediate patching is not possible, operators should restrict network access to the mcp-server-git service to trusted clients only, ensure the server process runs with minimal necessary file system permissions, and avoid exposing the --repository flag-configured instances to untrusted users. Verify the upgrade by checking the installed version and reviewing the security advisory at https://github.com/modelcontextprotocol/servers/security/advisories/GHSA-j22h-9j4x-23w5 for detailed changelog information.

Affected Packages

pypi mcp-server-git fix: 2025.12.18

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

mcp-server-git is a Model Context Protocol (MCP) server implementation that exposes git operations as callable tools. CWE-22 (Improper Limitation of a Pathname to a Restricted Directory) occurs because the server accepts repo_path arguments in tool calls without canonical path validation against the configured --repository restriction. The vulnerability arises from insufficient path normalization and traversal checks; even when symlink resolution is performed, the code failed to verify that the resolved path remained within the allowed directory boundary. This is a classic path traversal flaw where user-controlled path inputs bypass directory confinement checks, allowing attackers to access sibling or parent directories containing other git repositories.

Know when Model Context Protocol Servers gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 6.4 MEDIUM
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

Primary rating from Vendor (github) · only source for this CVE.

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
High
Subsequent system: Integrity
High
Subsequent system: Availability
None

DescriptionCVE.org

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.

Threat Intelligence Overview

EPSS Score
0.1%
Top 74% exploitable
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

32
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +32
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Affected Products (CPE)CVE.org

cpe:2.3:a:lfprojects:model_context_protocol_servers:*:*:*:*:*:*:*:*

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy