CVE-2024-38531
Nix sandbox escape
Severity Score
Exploit Likelihood
Affected Versions
Public Exploits
0Exploited in Wild
-Decision
Descriptions
Nix is a package manager for Linux and other Unix systems that makes package management reliable and reproducible. A build process has access to and can change the permissions of the build directory. After creating a setuid binary in a globally accessible location, a malicious local user can assume the permissions of a Nix daemon worker and hijack all future builds. This issue was patched in version(s) 2.23.1, 2.22.2, 2.21.3, 2.20.7, 2.19.5 and 2.18.4.
Nix es un administrador de paquetes para Linux y otros sistemas Unix que hace que la administración de paquetes sea confiable y reproducible. Un proceso de compilación tiene acceso y puede cambiar los permisos del directorio de compilación. Después de crear un binario setuid en una ubicación accesible globalmente, un usuario local malicioso puede asumir los permisos de un daemon trabajador de Nix y secuestrar todas las compilaciones futuras. Este problema se solucionó en las versiones 2.23.1, 2.22.2, 2.21.3, 2.20.7, 2.19.5 y 2.18.4.
Linus Heckemann discovered that Nix did not correctly handle certain binaries. An attacker could possibly use this issue to execute arbitrary code. Pierre-Etienne Meunier discovered that Nix did not correctly handle TLS certificates. A remote attacker could possibly use this issue to leak sensitive information. It was discovered that Nix did not correctly handle Unix sockets. An attacker could possibly use this issue execute arbitrary code. This issue only affected Ubuntu 24.04 LTS.
CVSS Scores
SSVC
- Decision:Track
Timeline
- 2024-06-18 CVE Reserved
- 2024-06-28 CVE Published
- 2024-08-02 CVE Updated
- 2025-08-07 EPSS Updated
- ---------- Exploited in Wild
- ---------- KEV Due Date
- ---------- First Exploit
CWE
- CWE-278: Insecure Preserved Inherited Permissions
CAPEC
References (2)
URL | Tag | Source |
---|---|---|
https://github.com/NixOS/nix/pull/10501 | X_refsource_misc | |
https://github.com/NixOS/nix/security/advisories/GHSA-q82p-44mg-mgh5 | X_refsource_confirm |
URL | Date | SRC |
---|
URL | Date | SRC |
---|
URL | Date | SRC |
---|
Affected Vendors, Products, and Versions
Vendor | Product | Version | Other | Status | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Vendor | Product | Version | Other | Status | <-- --> | Vendor | Product | Version | Other | Status |
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.23.0 < 2.23.1 Search vendor "NixOS" for product "Nix" and version " >= 2.23.0 < 2.23.1" | en |
Affected
| ||||||
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.22.0 < 2.22.2 Search vendor "NixOS" for product "Nix" and version " >= 2.22.0 < 2.22.2" | en |
Affected
| ||||||
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.21.0 < 2.21.3 Search vendor "NixOS" for product "Nix" and version " >= 2.21.0 < 2.21.3" | en |
Affected
| ||||||
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.20.0 < 2.20.7 Search vendor "NixOS" for product "Nix" and version " >= 2.20.0 < 2.20.7" | en |
Affected
| ||||||
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.19.0 < 2.19.5 Search vendor "NixOS" for product "Nix" and version " >= 2.19.0 < 2.19.5" | en |
Affected
| ||||||
NixOS Search vendor "NixOS" | Nix Search vendor "NixOS" for product "Nix" | >= 2.18.0 < 2.18.4 Search vendor "NixOS" for product "Nix" and version " >= 2.18.0 < 2.18.4" | en |
Affected
|