CVE-2026-125080: Cypher injection via orderBy placeholder in Spring Data Neo4j custom queries
Improper neutralization of special elements in data query logic (Cypher injection) in the orderBy placeholder handling for custom queries in Neo4j Spring Data Neo4j versions 6.1.0 through 8.0.8 and 8.1.0 through 8.1.2 allows a remote attacker to read database contents via blind reads, write read content into new nodes, or, if APOC and APOC file export are enabled, to write query results to a file in the database's accessible file system via crafted sort order parameters. Exploitation requires an application that passes unvalidated user input as the orderBy value to a custom Cypher query using the placeholder directive.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
Spring Data Neo4jto a version that resolves this vulnerability.Fixed in 8.0.9 - Upgrade
Upgrade
Spring Data Neo4jto a version that resolves this vulnerability.Fixed in 8.1.3 - Upgrade
Upgrade
Spring Data Neo4jto a version that resolves this vulnerability.Fixed in 8.2.0
Event History
Frequently Asked Questions
Which applications are exposed to this issue?
Exposure requires an application using a custom Cypher query with the orderBy placeholder directive and passing unvalidated user-controlled input as the orderBy value. Applications that do not use that pattern are not described as affected.
What does an attacker need to exploit it?
The attacker needs to be able to supply a crafted sort-order parameter to the vulnerable application. No authentication or user interaction is required according to the supplied severity vector, but exploitation depends on the application forwarding that input without validation.
Is file-system impact possible by default?
File writing is only described when both APOC and APOC file export are enabled. Without those conditions, the described impacts are blind reading of database contents and writing read content into new nodes.
What can be done if updating is not immediately possible?
Do not pass unvalidated user input into the orderBy value for custom Cypher queries using the placeholder directive. Restrict sort choices to validated, application-defined values; also review whether APOC and APOC file export are enabled.
How can teams identify potentially affected code?
Review custom Cypher queries for use of the orderBy placeholder directive, then trace whether the corresponding orderBy value can originate from request parameters or other user-controlled input without validation. The affected version ranges are 6.1.0 through 8.0.8 and 8.1.0 through 8.1.2.