CVE-2026-87008
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.589, AstGrepService in codebase_rag/tools/ast_grep_service.py enumerates files beneath project_root and relies on should_skip_path in codebase_rag/utils/path_utils.py to classify them, but the containment check operates on unresolved lexical paths. A symbolic link planted inside an analyzed repository can therefore reference a file outside the configured root while still appearing in scope. The structural_search tool follows the link and discloses readable content without an approval gate, while structural_replace with dry_run=False follows it and overwrites writable content; the MCP path invokes structural replacement without the agent-loop approval control. An attacker who causes a victim to analyze a repository containing such a link can read credentials, keys, environment files, or sibling source and can modify files accessible to the code-graph-rag process. This issue is fixed in version 0.0.589.
Weakness
- CWE-22: Improper Limitation of a Pathname to a Restricted Directory
- CWE-59: Improper Link Resolution Before File Access
CISA SSVC decision points
| Exploitation | poc |
|---|---|
| Automatable | no |
| Technical impact | total |
| Scored | 2026-11-05 |
Timeline
- 2026-11-05Published by the CNA20:13 UTC
- 2026-11-05CISA SSVC decision recordedsame day
- 2026-11-09GitHub advisory published (GHSA-85gg-2gfq-q95m)4 days after publication
Exploit and advisory records
GitHub advisory GHSA-85gg-2gfq-q95m, affected packages:
| Package | Vulnerable versions | Fixed in |
|---|---|---|
| PyPI code-graph-rag | before 0.0.587 | 0.0.587 |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| vitali87 code-graph-rag |
References
- https://github.com/vitali87/code-graph-rag/commit/2648c95aa550ce2d9361a8e75ed669d5f4b451b8
- https://github.com/vitali87/code-graph-rag/releases/tag/v0.0.589
- https://github.com/vitali87/code-graph-rag/security/advisories/GHSA-85gg-2gfq-q95m
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2026-87008'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2026-87008'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2026-87008'curl 'https://api.contrastcyber.com/cve_products/CVE-2026-87008'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).