CVE-2026-32247: Graphiti vulnerable to Cypher Injection via unsanitized node_labels in search filters
Graphiti (graphiti-core) 0.28.1 and earlier builds Cypher queries by pasting SearchFilters.node_labels into label expressions without validation. In the Graphiti MCP server, an attacker can reach this through prompt injection that makes an LLM client call search_nodes with a crafted entity_types value. Upgrade graphiti-core to 0.28.2.
Published Mar 12, 2026 · Updated Mar 13, 2026 · Analysis Oct 31, 2026
What an attacker can do
Before 0.28.2, the shared search-filter constructors joined node_labels with a pipe and prefixed them with n: to form a label filter. Edge search used the same pattern. Nothing checked that the labels were plain labels, so Cypher syntax in a label became part of the query.
The MCP server's search_nodes tool takes an entity_types argument and passes it straight to SearchFilters(node_labels=entity_types). An attacker who controls text that an LLM client with Graphiti MCP access reads, such as a web page, a document or a stored memory, can steer the model to call search_nodes with Cypher in entity_types. A direct caller of the MCP server can do the same.
The injected Cypher runs with the privileges of the configured graph database connection. The advisory lists reading graph data outside the search scope, modifying it, deleting it, and bypassing group isolation enforced in the query layer. Neo4j, FalkorDB and Neptune backends are affected. Kuzu is not, because it handles labels as parameters. A separate narrower issue with unvalidated group_ids in fulltext search was fixed in the same release.
Who is affected
graphiti-core 0.28.1 and earlier, on Neo4j, FalkorDB or Neptune. The Graphiti MCP server's search_nodes tool is an exposed entry point when an LLM client processes untrusted content.
pip show graphiti-coreIf you run the MCP server from a container or a checkout, check the graphiti-core version pinned there.
graphiti-core
- Ecosystem
- PyPI
- Affected
- <= 0.28.1
- Fixed in
- 0.28.2
- Check
pip show graphiti-core
How to fix it
Upgrade to graphiti-core 0.28.2 or later.
pip install --upgrade "graphiti-core>=0.28.2"The release adds validation of SearchFilters.node_labels, label validation in the shared filter constructors, validation of entity node labels in persistence query builders, and validation of group_ids in fulltext helpers.
Workarounds from the advisory: do not expose Graphiti MCP tools to untrusted users or to LLM workflows that process untrusted prompt content, do not pass untrusted values to node_labels or entity_types, and give the graph database account the least privileges it needs.
How to tell if you were hit
Review graph database query logs for label expressions containing characters beyond a plain label name, such as spaces, braces, semicolons, comments or keywords like MATCH, DELETE, SET and CALL. Check MCP server logs for search_nodes calls where entity_types holds Cypher-like strings. Look for unexpected deleted or changed nodes. Beam records agent MCP tool calls, so a search_nodes call with an odd entity_types argument shows up in the agent's tool-call history.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
Graphiti versions before 0.28.2 contained a Cypher injection vulnerability in shared search-filter construction for non-Kuzu backends. Attacker-controlled label values supplied through SearchFilters.node_labels were concatenated directly into Cypher label expressions without validation.
In MCP deployments, this was exploitable not only through direct untrusted access to the Graphiti MCP server, but also through prompt injection against an LLM client that could be induced to call search_nodes with attacker-controlled entity_types values. The MCP server mapped entity_types to SearchFilters.node_labels, which then reached the vulnerable Cypher construction path.
Affected backends included Neo4j, FalkorDB, and Neptune. Kuzu was not affected by the label-injection issue because it used parameterized label handling rather than string-interpolated Cypher labels.
This issue was mitigated in 0.28.2.
Affected Versions
0.28.1and earlier
Fixed Version
0.28.2
Affected Components
- Graphiti Core search filter construction
- Graphiti MCP Server
search_nodeswhen used by an LLM client processing untrusted prompts
Technical Details
Before 0.28.2, Graphiti joined SearchFilters.node_labels with | and inserted the result directly into Cypher label expressions in the shared search-filter constructors used by non-Kuzu providers.
The vulnerable logic was effectively:
node_labels = '|'.join(filters.node_labels)node_label_filter = 'n:' + node_labels
The same pattern was also used in edge-search filter construction.
In MCP deployments, search_nodes accepted an entity_types argument and passed it directly to SearchFilters(node_labels=entity_types). An attacker who could influence prompts processed by an LLM client with Graphiti MCP access could use prompt injection to steer the model into invoking search_nodes with crafted entity_types values containing Cypher syntax. Those values would then be interpolated into Cypher before 0.28.2.
Impact
Successful exploitation could allow arbitrary Cypher execution within the privileges of the configured graph database connection, including:
- reading graph data outside the intended search scope
- modifying graph data
- deleting graph data
- bypassing logical group isolation enforced at the query layer
Additional Note on group_ids
Separately, the original report also identified a narrower issue in fulltext search query construction for unvalidated group_ids. That issue was distinct from the Cypher label-injection path described above and was also mitigated in 0.28.2.
Mitigation
Upgrade to 0.28.2 or later.
Version 0.28.2 added:
- validation of
SearchFilters.node_labels - defense-in-depth label validation in shared search-filter constructors
- validation of entity node labels in persistence query builders
- validation of
group_idsin shared search fulltext helpers
Workarounds
If you cannot upgrade immediately:
- do not expose Graphiti MCP tools to untrusted users or to LLM workflows that process untrusted prompt content
- avoid passing untrusted values into
SearchFilters.node_labelsor MCPentity_types - restrict graph database credentials to the minimum privileges required
Credits
@4n93L for their original report.
Credited to romain-deperne.
Questions
- Is Kuzu affected by CVE-2026-32247?
No. The advisory says Kuzu uses parameterized label handling. Neo4j, FalkorDB and Neptune were affected.
- Can this be triggered by prompt injection?
Yes. In MCP deployments an LLM client that reads attacker-controlled content can be induced to call search_nodes with crafted entity_types values, which reach the Cypher query.
- What is the fixed version?
graphiti-core 0.28.2. Version 0.28.1 and earlier are vulnerable.
References
Read for this analysis:
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More Other MCP servers and tools vulnerabilities
All Other MCP servers and tools entriesCVE-2026-129235
Kubeshark: MCP `download_file` writes fetched bytes to an unvalidated destination path
medium5.3Nov 16, 2026CVE-2026-129236
Kubeshark: MCP `start_kubeshark` argument injection via `pod_regex` → image redirect → cluster takeover
high7.2Nov 16, 2026CVE-2026-68934
code-review-mcp-server: Command injection via unsanitized folderPath/baseBranch parameters
high8.7Nov 16, 2026CVE-2026-102943
Dagu MCP DAG specification read bypasses path containment and workspace isolation
medium6.5Nov 10, 2026CVE-2026-102610
fast-agent: `fast-agent serve` binds HTTP to 0.0.0.0 with no authentication by default; with --shell this is unauthenticated remote command execution
medium6.4Nov 9, 2026CVE-2026-63655
tsParticles: Unbounded HTTP Request Body Buffering in @tsparticles/mcp-server Leads to Remote DoS
high7.5Nov 9, 2026
