Vulnerability · Published Jan 6, 2025 · Assigned by GitHub_M

CVE-2024-46981Redis' Lua library commands may lead to remote code execution

High 7.0

In plain English

A high-severity use-after-free in redis from redis. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 8.2% (higher than 95% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)7.0High
Exploit odds (30 days)8.2%top 5.1% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack tooling1Public PoC

Official description

Redis is an open source, in-memory database that persists on disk. An authenticated user may use a specially crafted Lua script to manipulate the garbage collector and potentially lead to remote code execution. The problem is fixed in 7.4.2, 7.2.7, and 6.2.17. An additional workaround to mitigate the problem without patching the redis-server executable is to prevent users from executing Lua scripts. This can be done using ACL to restrict EVAL and EVALSHA commands.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
AlmaLinux:8redis6.2.17-1.module_el8.10.0+3946+3de613d5ALSA-2025:0595
AlmaLinux:9redis6.2.17-1.el9_5ALSA-2025:0693
AlmaLinux:9redis7.2.7-1.module_el9.5.0+134+2e645600ALSA-2025:0692
AlmaLinux:8redis-devel6.2.17-1.module_el8.10.0+3946+3de613d5ALSA-2025:0595
AlmaLinux:9redis-devel7.2.7-1.module_el9.5.0+134+2e645600ALSA-2025:0692
AlmaLinux:9redis-devel6.2.17-1.el9_5ALSA-2025:0693
AlmaLinux:8redis-doc6.2.17-1.module_el8.10.0+3946+3de613d5ALSA-2025:0595
AlmaLinux:9redis-doc6.2.17-1.el9_5ALSA-2025:0693
AlmaLinux:9redis-doc7.2.7-1.module_el9.5.0+134+2e645600ALSA-2025:0692
Alpine:v3.20redict7.3.2-r0ALPINE-CVE-2024-46981
Alpine:v3.21redict7.3.2-r0ALPINE-CVE-2024-46981
Alpine:v3.22redict7.3.2-r0ALPINE-CVE-2024-46981
Alpine:v3.23redict7.3.2-r0ALPINE-CVE-2024-46981
Alpine:v3.24redict7.3.2-r0ALPINE-CVE-2024-46981
Alpine:v3.20redis7.2.7-r0ALPINE-CVE-2024-46981
Alpine:v3.21redis7.2.7-r0ALPINE-CVE-2024-46981
Alpine:v3.22redis7.2.7-r0ALPINE-CVE-2024-46981
Alpine:v3.23redis7.2.7-r0ALPINE-CVE-2024-46981
Alpine:v3.24redis7.2.7-r0ALPINE-CVE-2024-46981
Alpine:v3.20valkey7.2.8-r0ALPINE-CVE-2024-46981
Alpine:v3.21valkey7.2.8-r0ALPINE-CVE-2024-46981
Alpine:v3.22valkey7.2.8-r0ALPINE-CVE-2024-46981
Alpine:v3.23valkey7.2.8-r0ALPINE-CVE-2024-46981
Alpine:v3.24valkey7.2.8-r0ALPINE-CVE-2024-46981
Debian:14redict7.3.2+ds-1DEBIAN-CVE-2024-46981
Debian:12redis5:7.0.15-1~deb12u3DSA-5856-1
Debian:12redis5:7.0.15-1~deb12u3DEBIAN-CVE-2024-46981
Debian:13redis5:7.0.15-3DEBIAN-CVE-2024-46981
Debian:14redis5:7.0.15-3DEBIAN-CVE-2024-46981
Debian:13valkey8.0.2+dfsg1-1DEBIAN-CVE-2024-46981
Debian:14valkey8.0.2+dfsg1-1DEBIAN-CVE-2024-46981
Rocky Linux:8redis0:6.2.17-1.module+el8.10.0+1923+5b85c6a7RLSA-2025:0595
Rocky Linux:9redis0:6.2.17-1.el9_5RLSA-2025:0693
Ubuntu:25.10redictno fix listedUBUNTU-CVE-2024-46981
Ubuntu:26.04:LTSredictno fix listedUBUNTU-CVE-2024-46981
Ubuntu:26.10redictno fix listedUBUNTU-CVE-2024-46981
Ubuntu:24.04:LTSredis5:7.0.15-1ubuntu0.24.04.1UBUNTU-CVE-2024-46981
Ubuntu:24.04:LTSredis5:7.0.15-1ubuntu0.24.04.1USN-7321-1
Ubuntu:24.04:LTSvalkey7.2.8+dfsg1-0ubuntu0.24.04.2UBUNTU-CVE-2024-46981
Ubuntu:24.04:LTSvalkey7.2.8+dfsg1-0ubuntu0.24.04.2USN-7359-1

Affected products (as reported)

VendorProductVersions
redis redis >= 7.4.0, < 7.4.2>= 7.2.0, < 7.2.7< 6.2.17

Weakness: CWE-416 · Vector: CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H

References