CVE-2026-32247: Graphiti core Graphiti Vulnerable To Cypher Injection Vulnerability

HIGH
Advisory Identifier: GHSA-gg5m-55jj-8m5g
CVSS 8.1
CWE-943
Published
Advisory Summary

CVE-2026-32247 is a HIGH (CVSS 8.1) graphiti vulnerable to cypher injection vulnerability (CWE-943: Improper Neutralization of Special Elements in Data Query Logic) affecting Graphiti core libraries in the PyPI ecosystem. The issue involves graphiti vulnerable to cypher injection via unsanitized node_labels in search filters. Remediation is available by upgrading affected packages to version 0.28.2.

CVE-2026-32247 at a Glance

CVE Identifier CVE-2026-32247
GHSA Identifier GHSA-gg5m-55jj-8m5g
Severity HIGH
CVSS v3.1 Base Score 8.1
CWE Classification CWE-943: Improper Neutralization of Special Elements in Data Query Logic
Affected Product Graphiti core
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 8.1

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix CVE-2026-32247

To remediate this vulnerability, upgrade all affected Graphiti core dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

graphiti-core fixed: 0.28.2
pip install graphiti-core>=0.28.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show graphiti-core

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-32247, inspect your installed packages using pip:

pip show graphiti-core

Analyze the terminal output to locate any version of Graphiti core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.28.2), your application is affected.

Note: The pip show graphiti-core command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-943: Improper Neutralization of Special Elements in Data Query Logic, where the product generates a query intended to access or manipulate data in a data store such as a database, but it does not neutralize or incorrectly neutralizes special elements that can modify the intended logic of the query. In Graphiti core, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### 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.1` and earlier ### Fixed Version - `0.28.2` ### Affected Components - Graphiti Core search filter construction - Graphiti MCP Server `search_nodes` when 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_ids` in 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_labels` or MCP `entity_types` - restrict graph database credentials to the minimum privileges required ### Credits @4n93L for their original report.

CVE-2026-32247 Affected Graphiti core Versions

1 component(s)
Fixed Versions:
0.28.2
Product / Package Ecosystem Affected Versions Fixed Version
graphiti-core
PyPI
< 0.28.2
0.28.2

References

Frequently Asked Questions

What is CVE-2026-32247?
CVE-2026-32247 is a security vulnerability in Graphiti core involving Graphiti vulnerable to Cypher Injection via unsanitized node_labels in search filters under CWE-943: Improper Neutralization of Special Elements in Data Query Logic.
Which Graphiti core versions are affected?
Affected versions include releases prior to 0.28.2 across affected packages: graphiti-core.
What version fixes CVE-2026-32247?
Upgrading to 0.28.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is graphiti-core affected?
Yes, graphiti-core is affected in releases prior to 0.28.2. Upgrade your dependency to 0.28.2 or later.
What is the CVSS score of CVE-2026-32247?
CVE-2026-32247 has a CVSS v3.1 base score of 8.1 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N.
What CWE is associated with CVE-2026-32247?
CVE-2026-32247 is classified under CWE-943: Improper Neutralization of Special Elements in Data Query Logic (The product generates a query intended to access or manipulate data in a data store such as a database, but it does not neutralize or incorrectly neutralizes special elements that can modify the intended logic of the query.).
How can I check PyPI dependencies for CVE-2026-32247?
Run the dependency tree command: 'pip show graphiti-core'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-gg5m-55jj-8m5g",
  "modified" : "2026-03-13T13:36:04Z",
  "published" : "2026-03-12T17:26:16Z",
  "aliases" : [ "CVE-2026-32247" ],
  "summary" : "Graphiti vulnerable to Cypher Injection via unsanitized node_labels in search filters",
  "details" : "### Summary\n\nGraphiti 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.\n\nIn 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.\n\nAffected 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.\n\nThis issue was mitigated in `0.28.2`.\n\n### Affected Versions\n\n- `0.28.1` and earlier\n\n### Fixed Version\n\n- `0.28.2`\n\n### Affected Components\n\n- Graphiti Core search filter construction\n- Graphiti MCP Server `search_nodes` when used by an LLM client processing untrusted prompts\n\n### Technical Details\n\nBefore `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.\n\nThe vulnerable logic was effectively:\n\n- `node_labels = '|'.join(filters.node_labels)`\n- `node_label_filter = 'n:' + node_labels`\n\nThe same pattern was also used in edge-search filter construction.\n\nIn 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`.\n\n### Impact\n\nSuccessful exploitation could allow arbitrary Cypher execution within the privileges of the configured graph database connection, including:\n\n- reading graph data outside the intended search scope\n- modifying graph data\n- deleting graph data\n- bypassing logical group isolation enforced at the query layer\n\n### Additional Note on `group_ids`\n\nSeparately, 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`.\n\n### Mitigation\n\nUpgrade to `0.28.2` or later.\n\nVersion `0.28.2` added:\n\n- validation of `SearchFilters.node_labels`\n- defense-in-depth label validation in shared search-filter constructors\n- validation of entity node labels in persistence query builders\n- validation of `group_ids` in shared search fulltext helpers\n\n### Workarounds\n\nIf you cannot upgrade immediately:\n\n- do not expose Graphiti MCP tools to untrusted users or to LLM workflows that process untrusted prompt content\n- avoid passing untrusted values into `SearchFilters.node_labels` or MCP `entity_types`\n- restrict graph database credentials to the minimum privileges required\n\n### Credits\n\n@4n93L for their original report.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "graphiti-core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.28.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 0.28.1"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/getzep/graphiti/security/advisories/GHSA-gg5m-55jj-8m5g"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-32247"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/getzep/graphiti/pull/1312"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/getzep/graphiti/commit/7d65d5e77e89a199a62d737634eaa26dbb04d037"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/getzep/graphiti"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/getzep/graphiti/releases/tag/v0.28.2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-943" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-12T17:26:16Z",
    "nvd_published_at" : "2026-03-12T19:16:19Z"
  }
}