CVE-2025-68145: mcp-server-git has missing path validation when using --repository flag

Published Dec 17, 2025
·
Updated

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 repopath 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.

Other sources

In mcp-server-git versions prior to 2025.12.18, when the server is started with the --repository flag to restrict operations to a specific repository path, it did not validate that repopath 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.18 to remediate this issue.

Thank you to https://hackerone.com/yardenporat for reporting.

GitHub

Affected Software

3 affected componentsFixes available
npm/mcp-server-git<2025.12.17
pip/mcp-server-git<2025.12.18
2025.12.18
Lfprojects Model Context Protocol Servers<2025.12.18

Event History

Dec 17, 2025
CVE Published
via MITRE·10:12 PM
Data Sourced
via MITRE·10:12 PM
DescriptionWeakness
Advisory Published
via GitHub·10:50 PM
Data Sourced
via GitHub·10:50 PM
DescriptionWeaknessAffected Software
Data Sourced
via NVD·11:16 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·11:16 PM
Affected Software
Jan 20, 2026
News Published
via The Register·01:00 PM
News Published
via The Register·01:01 PM
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2025-68145?

CVE-2025-68145 has been classified as a medium severity vulnerability.

2

How do I fix CVE-2025-68145?

To fix CVE-2025-68145, update mcp-server-git to version 2025.12.17 or later.

3

What versions are affected by CVE-2025-68145?

CVE-2025-68145 affects mcp-server-git versions prior to 2025.12.17 and up to 2025.11.25.

4

What type of vulnerability is CVE-2025-68145?

CVE-2025-68145 is a path traversal vulnerability in mcp-server-git when improperly configured.

5

What happens if CVE-2025-68145 is exploited?

If exploited, CVE-2025-68145 could allow unauthorized access to files outside the specified repository path.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203