Skip to content

Heap overflow in COMMAND GETKEYS and ACL evaluation

High
yossigo published GHSA-4cfx-h9gq-xpx3 Jul 10, 2023

Package

redis-server

Affected versions

>= 7.0.0

Patched versions

7.0.12

Description

Impact

Extracting key names from a command and a list of arguments may, in some cases, trigger a heap overflow and result in reading random heap memory, heap corruption and potentially remote code execution. Several scenarios that may lead to this result:

  • Authenticated users executing a specially crafted COMMAND GETKEYS or COMMAND GETKEYSANDFLAGS.
  • Authenticated users who were set with ACL rules that match key names, executing a specially crafted command that refers to a variadic list of key names.

The problem exists in Redis 7.0 or newer.

Patches

The problem is fixed in Redis 7.0.12.

Credit

The problem was found by Lior Lahav.

For more information

If you have any questions or comments about this advisory:

Severity

High
7.4
/ 10

CVSS base metrics

Attack vector
Local
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

CVE ID

CVE-2023-36824