CVE-2021-44731 snapd could be made to escalate privileges and run programs as administrator
A race condition in snapd allows local attackers to gain root privileges by manipulating mount namespaces to execute arbitrary code.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2021-44731?
CVE-2021-44731 is a high-severity vulnerability in Canonical Ubuntu Linux, published on 17 Feb 2022. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
A race condition existed in the snapd 2.54.2 snap-confine binary when preparing a private mount namespace for a snap. This could allow a local attacker to gain root privileges by bind-mounting their own contents inside the snap's private mount namespace and causing snap-confine to execute arbitrary code and hence gain privilege escalation. Fixed in snapd versions 2.54.3+18.04, 2.54.3+20.04 and 2.54.3+21.10.1
Weakness: CWE-362
Which versions are affected by CVE-2021-44731?
It affects 4 products.
Products include Canonical Snapd, Canonical Ubuntu Linux, Debian Debian Linux, Fedoraproject Fedora.
How do I fix CVE-2021-44731?
Upgrade to a fixed version.
Is CVE-2021-44731 being exploited?
There is no known exploitation of CVE-2021-44731 in the wild and no public exploit code.
Public exploit code: 1 proofs of concept on GitHub.
Other vulnerabilities in Canonical Ubuntu Linux
- CVE-2023-1523 Command injection in snapd
- CVE-2020-27352 Privilege escalation in snapd
- CVE-2019-7304 Local privilege escalation via snapd socket
- CVE-2021-4120 snapd could be made to bypass intended access restrictions through snap content interfaces and layout paths
- CVE-2024-5138 CVE-2024-5138: snapd snapctl auth bypass
Sources
Also known as DEBIAN-CVE-2021-44731, GHSA-m3j9-xfh2-hrgc, UBUNTU-CVE-2021-44731.