CVE-2026-130822Valkey: Use-after-free when client eviction frees the client whose command is still…
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.
What to do
Fixed builds are available from Alpine: see the table below for the fixed version per release.
Red Hat, Ubuntu have not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 26.04 | valkey | Under investigation | ||
| Red Hat Enterprise Linux 10 | valkey | Fix pending Affected | ||
| Red Hat Enterprise Linux 10 | valkey-devel | Fix pending Affected | ||
| Red Hat Enterprise Linux 10 | valkey-rdma | Fix pending Affected | ||
| Red Hat Enterprise Linux 9 | redis | Fix pending Affected | ||
| Red Hat Enterprise Linux 9 | redis-devel | Fix pending Affected | ||
| Red Hat Enterprise Linux 9 | redis-doc | Fix pending Affected | ||
| Red Hat Enterprise Linux 9 | valkey | Fix pending Affected | ||
| Red Hat Enterprise Linux 9 | valkey-devel | Fix pending Affected | ||
| Red Hat Enterprise Linux 8 | redis | Fix pending Affected | ||
| Red Hat Enterprise Linux 8 | redis-devel | Fix pending Affected | ||
| Red Hat Enterprise Linux 8 | redis-doc | Fix pending Affected | ||
| Alpine Linux 3.24 | valkey | Fixed | 9.0.8-r0 | ALPINE-CVE-2026-130822 |
| Alpine Linux 3.23 | valkey | Fixed | 9.0.8-r0 | ALPINE-CVE-2026-130822 |
What the vendor says
As published in the CVE record by Akrites, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- Valkey: affected: before 7.2.16, 8.0.0 to before 8.0.13, 8.1.0 to before 8.1.12, 9.0.0 to before 9.0.8, 9.1.0 to before 9.1.4, 9.2.0-rc1 to before 9.2.0; fixed in
7.2.16,8.0.13,8.1.12,9.0.8,9.1.4,9.2.0
Solution: Upgrade to Valkey 7.2.16, 8.0.13, 8.1.12, 9.0.8, 9.1.4, 9.2.0 or later.
Workaround: Set maxmemory-clients to 0, which disables client eviction; if you do, make sure client-output-buffer-limit and maxmemory still bound client memory. If client eviction is required, use Valkey ACLs so that untrusted users cannot write to keys that other clients block on, and cannot run the blocking commands (BLPOP, BRPOP, BLMOVE, BRPOPLPUSH, BLMPOP, BZPOPMIN, BZPOPMAX, BZMPOP, and XREAD or XREADGROUP with BLOCK).
References
- 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
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.