Valkey use-after-free in client eviction can crash the server
- Exploited
- No known exploitation
- Fix
- Fixed in 7.2.16, 8.0.13, 8.1.12, 9.0.8, 9.1.4, and 1 more
- Who is exposed
- Specific setups only
Summary
Valkey has a use-after-free bug that lets an authenticated user with low privileges, reached over the network, crash the server by writing to a key that other clients are blocked on. It only affects servers where client eviction is enabled, and servers that keep the default `maxmemory-clients` setting of 0 are not affected.
Written by a model
Original description
In Valkey before 7.2.16, 8.0.x before 8.0.13, 8.1.x before 8.1.12, 9.0.x before 9.0.8, 9.1.x before 9.1.4 and 9.2.0 release candidates, when client eviction is enabled (maxmemory-clients is not 0), an authenticated user who can write to a key that other clients are blocked on (for example with BLPOP, BLMPOP, BZPOPMIN or XREAD BLOCK) can trigger a use-after-free. While the clients blocked on that key are served, evictClients() can select and free the client whose command made the key ready, although that command is still executing, and the server then keeps using the freed client. The blocked clients do not have to belong to the attacker. The result is a reliable crash of the server process. Servers with the default maxmemory-clients 0 are not affected.
Who should check
Teams running Valkey servers with client eviction enabled (maxmemory-clients not 0) on affected 7.2.x, 8.0.x, 8.1.x, 9.0.x, 9.1.x or 9.2.0-rc builds.
“<= 9.2.0-rc2, <= 9.1.3, <= 9.0.7, <= 8.1.11, <= 8.0.12, <= 7.2.15”
What to do
Check whether your setup matches what the bug needs.
Client eviction enabled on the server (maxmemory-clients not 0). Another client must be blocked on the key the attacker writes to, for example via BLPOP, BLMPOP, BZPOPMIN or XREAD BLOCK.Upgrade to a fixed version: 7.2.16, 8.0.13, 8.1.12, 9.0.8, 9.1.4, or one of 1 more.
Workaround: Set maxmemory-clients to 0, which disables client eviction.
Check your systems with an agent
Paste this into a coding or ops agent. It checks your systems read-only and reports a table per asset.
Check whether my systems are affected by CVE-2026-130822 (Valkey: Use-after-free when client eviction frees the client whose command is still executing), using the cve.now data below.
Rules: work read-only. Do not run exploit code, proof-of-concept scripts or scanners that send attack payloads, and do not change any configuration, package, image or deployment. Report findings only.
What cve.now has for CVE-2026-130822 (entry last updated 2026-11-24):
Affected:
- Valkey Valkey: fixed in 7.2.16; from 8.0.0, fixed in 8.0.13; from 8.1.0, fixed in 8.1.12; from 9.0.0, fixed in 9.0.8; from 9.1.0, fixed in 9.1.4; from 9.2.0-rc1, fixed in 9.2.0
Fixed versions: 7.2.16, 8.0.13, 8.1.12, 9.0.8, 9.1.4, 9.2.0.
Conditions (all must be true for the bug to be hit):
- Client eviction enabled on the server (maxmemory-clients not 0). (source: https://github.com/valkey-io/valkey/security/advisories/GHSA-3885-pq5f-788j)
- Another client must be blocked on the key the attacker writes to, for example via BLPOP, BLMPOP, BZPOPMIN or XREAD BLOCK. (source: https://github.com/valkey-io/valkey/security/advisories/GHSA-3885-pq5f-788j)
Setup: the bug needs a feature or setting that is off by default or uncommon. Check whether each asset has it on.
Attacker needs: network access, low-privilege login, no user action.
Workaround: Set maxmemory-clients to 0, which disables client eviction. (source: https://www.cve.org/CVERecord?id=CVE-2026-130822)
CISA KEV: CVE-2026-130822 is not listed as of cve.now's last read.
This KEV status is for CVE-2026-130822 only. If you also check another CVE, look up its own KEV status; never assume it from this one.
How to check:
- Installed software: check what is actually running, not what a repo declares. Read the version from each host, container image and Kubernetes node (the binary's version output, the OS package database, image layers), and check whether the conditions above hold there. Distribution packages may carry a backported fix under an older version number; confirm against the distribution's own advisory.
Verify against the linked advisories before concluding, and cite the date you read each one:
- https://github.com/valkey-io/valkey/security/advisories/GHSA-3885-pq5f-788j
- https://github.com/valkey-io/valkey/issues/5422
- https://github.com/valkey-io/valkey/pull/5435
- https://www.cve.org/CVERecord?id=CVE-2026-130822
Do not conclude an asset is unaffected unless you checked it and the evidence covers both its version and the conditions above. If you could not check something, mark it unknown and say what is missing.
Report a table with one row per asset and these columns: Asset | Version or build | Status (affected, fixed, not applicable, unknown) | Compensating controls | Exposure (internet-facing, internal, none) | Evidence | Next action.
Entry: https://cve.now/CVE-2026-130822
For follow-up questions, use the cve.now MCP server at https://mcp.cve.now/mcp (no authentication), for example execute with name cve.get and arguments {"id": "CVE-2026-130822"}.Affected versions
- Valkey Valkeyfixed in 7.2.16; From 8.0.0 · fixed in 8.0.13; From 8.1.0 · fixed in 8.1.12; From 9.0.0 · fixed in 9.0.8; From 9.1.0 · fixed in 9.1.4; From 9.2.0-rc1 · fixed in 9.2.0
cve.now Index
- Exploitation?/40Unknown. No CISA SSVC exploitation rating yet
- Exposure8/25Specific setups only, reachable over the network
- Reach?/20Unknown. No tracked technology or package matched
- Severity7.5/10CVSS 7.5
- No patch0/5No signal
What would change the score
- Would score about 66 if added to CISA KEV
- Would score about 61 if CISA's SSVC rates exploitation active
- Would score about 23 if CISA's SSVC rates it automatable
Timeline
- CVE published
- First seen by cve.now
Evidence 5
| Kind | Source |
|---|---|
| Vendor advisory 1Establishes: Affected and fixed versions. | |
| Advisory | GitHub · valkey-io/valkey · Advisory GHSA-3885-pq5f-788j |
| CVE record 2Establishes: The identifier and description. | |
| Record | CVE List · CVE-2026-130822 |
| Record | NVD · CVE-2026-130822 |
| Other links 2 | |
| Repository | GitHub · valkey-io/valkey · Issue #5422 |
| Repository | GitHub · valkey-io/valkey · Pull request #5435 |
Questions about CVE-2026-130822
Is CVE-2026-130822 being exploited?
It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.
Source: cve.now feed data
What does this mean?
A client that is being evicted can be freed while a command it sent is still running, so the server later reads memory that has already been released. The facts say the result is a reliable crash of the server process, which is a denial of service.
Source: github.com, cve.org
Which versions are affected by CVE-2026-130822?
Valkey: before 7.2.16; from 8.0.0 before 8.0.13; from 8.1.0 before 8.1.12; from 9.0.0 before 9.0.8; from 9.1.0 before 9.1.4; from 9.2.0-rc1 before 9.2.0.
Source: cve.now feed data
Am I affected, and how do I check?
Affected Valkey releases are those before 7.2.16, 8.0.13 (within the 8.0 line), 8.1.12, 9.0.8, 9.1.4, and 9.2.0-rc1 (the 9.2 release candidate). The bug needs client eviction enabled, meaning maxmemory-clients is not 0; run CONFIG GET maxmemory-clients to check that setting, and the version command to check the release. Another client must also be blocked on the key being written, for example via BLPOP, BLMPOP, BZPOPMIN or XREAD BLOCK.
Source: github.com, cve.org
How do I fix CVE-2026-130822?
Upgrade to Valkey 7.2.16, 8.0.13, 8.1.12, 9.0.8, 9.1.4, 9.2.0 or later, matching your release line.
Source: github.com, cve.org
Related
- CVE-2026-136158Valkey JSON: Use-after-free in array mutation commands through a recursive JSONPath
- CVE-2026-136156Valkey: Integer truncation in cluster publish message construction causes a heap buffer overflow
- CVE-2026-136155Valkey: Use-after-free of the Lua interpreter state through the script debugger's command cache
- CVE-2026-136157Valkey: Use-after-free in the RDMA transport when a client is freed while pending data is processed
- CVE-2025-49112setDeferredReply in networking.c in Valkey through 8.1.1 has an integer underflow for prev->size - prev->used.
- CVE-2026-135597Sandbox escape due to use-after-free in the DOM: Navigation component
No corrections so far. Something wrong on this page? Report an error.