# CVE-2026-77604: Code Graph RAG: MCP paginated read_file path traversal / arbitrary file read

- Severity: High 7.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.60%, higher than 50% of CVEs (2026-12-02)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-11-05T20:10:19.957Z
- Modified: 2026-11-12T22:18:51.470Z
- Also known as: GHSA-vvr2-h2jp-838m
- Weaknesses: CWE-22
- SSVC (CISA-ADP): exploitation poc, automatable yes, technical impact partial
- Assigned by: GitHub_M

## Description

Code Graph RAG is an AI-powered knowledge graph and retrieval system for querying, understanding, and editing multi-language codebases. Prior to 0.0.345, the MCPToolsRegistry.read_file implementation in codebase_rag/mcp/tools.py joins attacker-controlled file_path input to project_root without resolving and verifying containment when offset or limit selects the paginated branch. An absolute path causes pathlib to discard the configured root, while relative traversal can also resolve outside it. The protected non-paginated branch uses validate_project_path, but the paginated branch bypasses that validation before opening the path. An unauthenticated caller of a network-exposed HTTP MCP server can therefore read arbitrary UTF-8-readable files available to the server process, including credentials, environment data, private keys, source, and configuration; local callers through the stdio transport can reach the same vulnerable code path. This issue is fixed in version 0.0.345.

(As written by CVE List.)

## Affected

- vitali87 code-graph-rag: < 0.0.345
- code-graph-rag (PyPI): before 0.0.345

## Every score

- GitHub_M: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- GitHub: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`

## References

- <https://github.com/openemr/openemr/security/advisories/GHSA-5h9g-m7q2-pv45> (exploit)
- <https://github.com/vitali87/code-graph-rag/security/advisories/GHSA-vvr2-h2jp-838m> (web)
- <https://github.com/vitali87/code-graph-rag/commit/6541e920a27961fa8f3ff49ef38c0e0bd09cd626> (web)
- <https://github.com/vitali87/code-graph-rag/releases/tag/v0.0.345> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-77604> (advisory)
- <https://github.com/vitali87/code-graph-rag> (package)

## Sources

- CVE List: [CVE-2026-77604](https://www.cve.org/CVERecord?id=CVE-2026-77604), CVE Terms of Use, modified 2026-11-09
- GitHub Advisory Database: [GHSA-vvr2-h2jp-838m](https://github.com/advisories/GHSA-vvr2-h2jp-838m), CC-BY-4.0, modified 2026-11-10
- NVD: [CVE-2026-77604](https://nvd.nist.gov/vuln/detail/CVE-2026-77604), Public domain, modified 2026-11-12

---

Page: https://cve.day/CVE-2026-77604 · Whole record: https://cve.day/CVE-2026-77604.json · Rebuilt by cve.day 2026-11-25T22:59:49.176Z
