Use-after-free in Valkey JSON array mutation commands
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Code execution
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA. Impact type from CWE-416 and the CVSS impact.
Summary
Valkey JSON versions from 1.0.0 before 1.0.3 contain a use-after-free (CWE-416) in array mutation commands when a recursive JSONPath such as $..* is used. The size-changing mutators JSON.ARRAPPEND, JSON.ARRINSERT, JSON.ARRPOP, JSON.ARRTRIM and JSON.CLEAR write through dangling pointers after reallocating an ancestor array. An authenticated user who can run these commands can reliably crash the server, and the flaw 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.
Written with Claude Haiku 5.5 from the sources below · 2026-11-24
Description from the CNA
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.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
Upgrade Valkey JSON to version 1.0.3. The sources list no fixed version for valkey-bundle.
Written with Claude Haiku 5.5 from the sources below · 2026-11-24
- Fix · CNA Valkey JSON (Valkey) Fixed in 1.0.3
Timeline
- 2026-11-24 Threatist record created from CVE-2026-136158
- 2026-11-24 Alias added: GHSA-325c-q6c5-jgmj
- 2026-12-01 CISA SSVC decision points changed
References
More Valkey vulnerabilities
- TI-2026-97445 Valkey cluster publish integer truncation causes heap overflow CVSS 3.1HIGH 8.8
- TI-2026-97444 Use-after-free in Valkey Lua script debugger cache CVSS 3.1HIGH 8.8
- TI-2026-95074 Use-after-free in Valkey client eviction frees a running client CVSS 3.1HIGH 7.5
- TI-2026-97446 Use-after-free in Valkey RDMA transport can crash the server CVSS 3.1HIGH 7.5
- TI-2025-31203 setDeferredReply in networking.c in Valkey through 8.1.1 has an integer underflow for prev->size - prev->used. CVSS 3.1LOW 3.1
Sources
- CVE-2026-136158 · CVE Program
- CVE-2026-136158 · NVD
- FIRST EPSS
- GHSA-325c-q6c5-jgmj · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences