CVE-2021-27851: gnu guix guix-daemon
Vulnerability summary
CVE-2021-27851 is a medium (CVSS 5.5) vulnerability in gnu guix guix-daemon. EPSS estimates a 0.33% chance of exploitation in the next 30 days, higher than 25.5% of scored vulnerabilities.
Timeline
- 26-04-2021PublishedVulnerability first disclosed.
- 17-09-2024Last modifiedVulnerability information updated.
Description
A security vulnerability that can lead to local privilege escalation has been found in ’guix-daemon’. It affects multi-user setups in which ’guix-daemon’ runs locally. The attack consists in having an unprivileged user spawn a build process, for instance with `guix build`, that makes its build directory world-writable. The user then creates a hardlink to a root-owned file such as /etc/shadow in that build directory. If the user passed the --keep-failed option and the build eventually fails, the daemon changes ownership of the whole build tree, including the hardlink, to the user. At that point, the user has write access to the target file. Versions after and including v0.11.0-3298-g2608e40988, and versions prior to v1.2.0-75109-g94f0312546 are vulnerable.
CVSS metrics
4 scores · 3 sources · 2 versions- OSV · UbuntuEcosystem advisory · calculated5.5MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
- OSV · DebianEcosystem advisory · calculated5.5MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
EPSS trend
Probability
0.33%
Chance of exploitation in the next 30 days
Percentile
26%
Versus all other CVEs
30-day change
0.00 pp
From 0.33% on 21-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root cause- CWE-264Permissions, Privileges, and Access ControlsWeaknesses in this category are related to the management of permissions, privileges, and other security features that are used to perform access control.
- CWE-59Improper Link Resolution Before File Access ('Link Following')The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.
Affected systems
Debian1 product
- guix< 1.2.0-4
Gnu1 product
- guix≥ 0.11.0, < 1.2.0
Gnu guix1 product
- guix-daemon≥ v0.11.0-3298-g2608e40988, < unspecified | ≥ unspecified, < v1.2.0-75109-g94f0312546
Opensuse1 product
- guix&distro=openSUSE Tumbleweed< 1.3.0-1.8
Ubuntu1 product
- guixAll versions (No fix recorded)
5 vendors · 5 products
References
8 links- guix.gnu.org/en/blog/2021/risk-of-local-privilege-escalation-via-guix-daemon/X Refsource MISCREPORTPatchVendor Advisory