CVE-2026-114496 codebase-memory-mcp: git option injection through base_branch in detect_changes allows writing a file outside the project
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: partial
Description
codebase-memory-mcp provides local code intelligence for developers and AI agents through a persistent graph and MCP tools. Prior to 0.9.0, the detect_changes tool validated the base_branch argument for shell metacharacters but omitted the leading-dash check before placing the value in the revision position of a git diff command. Git therefore interpreted an option-shaped base_branch value, including --output, as a command option instead of a revision, allowing a caller to create or overwrite a caller-chosen file with Git diff output under the server process's permissions. Arbitrary code execution was not demonstrated. This issue is fixed in version 0.9.0.
Upgrade path
3 packages: 2 fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| npm codebase-memory-mcp(npm) | < 0.9.0 | 0.9.0 | Fixed |
| pypi codebase-memory-mcp(PyPI) | < 0.9.0; = 0.8.1 | 0.9.0 | Fixed |
| DeusData codebase-memory-mcp | = < 0.9.0 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| DeusData codebase-memory-mcp | = < 0.9.0 | No fix listed |
| npm codebase-memory-mcp(npm) | < 0.9.0 | 0.9.0 |
| pypi codebase-memory-mcp(PyPI) | < 0.9.0 | 0.9.0 |
| pypi codebase-memory-mcp(PyPI) | = 0.8.1 | No fix listed |
References
- https://github.com/DeusData/codebase-memory-mcp/commit/72e6a14adb50a37a245eb6ec79c9eb31eee48951 patch
- https://github.com/DeusData/codebase-memory-mcp/pull/941 patch
- https://github.com/DeusData/codebase-memory-mcp/releases/tag/v0.9.0
- https://github.com/DeusData/codebase-memory-mcp/security/advisories/GHSA-2vj2-hwgx-6f23 vendor-advisory
- ENISA EUVD EUVD-2026-131799 third-party-advisory
- nvd.nist.gov third-party-advisory vendor-advisory
- github.com
- github.com product