CVE-2023-45145: Redis Unix-domain socket may have be exposed with the wrong permissions for a short time window.
CVE-2023-45145 - The wrong order of listen(2) and chmod(2) calls creates a race condition that can be used by another process to bypass desired Unix socket permissions on startup.
Upstream have released version 7.0.14/7.2.2 to fix CVE-2023-45145.
Reference: - https://github.com/redis/redis/releases/tag/7.0.14 - https://bugs.mageia.org/32406
Other sources
Redis could allow a local authenticated attacker to bypass security restrictions, caused by a race condition when a permissive umask(2) is used during startup. By sending a specially crafted request, an attacker could exploit this vulnerability to establish an unauthorized connection.
— IBM
Redis is an in-memory database that persists on disk. On startup, Redis begins listening on a Unix socket before adjusting its permissions to the user-provided configuration. If a permissive umask(2) is used, this creates a race condition that enables, during a short period of time, another process to establish an otherwise unauthorized connection. This problem has existed since Redis 2.6.0-RC1. This issue has been addressed in Redis versions 7.2.2, 7.0.14 and 6.2.14. Users are advised to upgrade. For users unable to upgrade, it is possible to work around the problem by disabling Unix sockets, starting Redis with a restrictive umask, or storing the Unix socket file in a protected directory.
— Ubuntu
Redis Unix-domain socket may have be exposed with the wrong permissions for a short time window.
— Microsoft
Affected Software
Remediation
Event History
Frequently Asked Questions
What is CVE-2023-45145?
CVE-2023-45145 is a vulnerability in Redis where the Unix-domain socket may be exposed with the wrong permissions for a short time window.
What is Redis?
Redis is an in-memory database that persists on disk.
How does CVE-2023-45145 affect Redis?
CVE-2023-45145 affects Redis versions between 2.6.0 and 6.2.14, 7.0.0 and 7.0.14, and 7.2.0 and 7.2.2.
What is the severity of CVE-2023-45145?
The severity of CVE-2023-45145 is low, with a CVSS score of 3.6.
How can I fix CVE-2023-45145?
To fix CVE-2023-45145, upgrade Redis to a version that is not affected by the vulnerability.