Valkey JSON: Use-after-free in array mutation commands through a recursive JSONPath
- State
- Published
- Severity
- 8.8 High
- Published
- Nov 24, 2026
- Updated
- Dec 1, 2026
- Reserved
- Nov 24, 2026
Description
In Valkey JSON 1.0.0 through 1.0.2, a recursive JSONPath expression such as $..* returns both an array and elements nested inside it. The size-changing mutators (JSON.ARRAPPEND, JSON.ARRINSERT, JSON.ARRPOP, JSON.ARRTRIM and JSON.CLEAR) process the ancestor first, which can reallocate its element buffer and free the old storage while the descendant entries in the result set still point into it; the module then writes through those dangling pointers. An authenticated user who can run these commands can use this to reliably crash the server, and it has been developed into remote code execution as the user the server runs as. Servers that do not load the JSON module, including through valkey-bundle, are not affected.
| Product | Versions |
|---|---|
| Valkey JSON Valkey | 1.0.0 to before 1.0.3 Affected |
| CVSS | Score | How It's Reached | Source |
|---|---|---|---|
| 3.1 | 8.8 High | Akrites |
Weaknesses
- CWE-416 Use After Free
References
Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.