CVE-2021-41103: Insufficiently restricted permissions on plugin directories
Impact A bug was found in containerd where container root directories and some plugins had insufficiently restricted permissions, allowing otherwise unprivileged Linux users to traverse directory contents and execute programs. When containers included executable programs with extended permission bits (such as setuid), unprivileged Linux users could discover and execute those programs. When the UID of an unprivileged Linux user on the host collided with the file owner or group inside a container, the unprivileged Linux user on the host could discover, read, and modify those files.
Patches This vulnerability has been fixed in containerd 1.4.11 and containerd 1.5.7. Users should update to these version when they are released and may restart containers or update directory permissions to mitigate the vulnerability.
Workarounds Limit access to the host to trusted users. Update directory permission on container bundles directories.
For more information If you have any questions or comments about this advisory: Open an issue in github.com/containerd/containerd Email us at security@containerd.io
Other sources
A flaw was found in the containerd package. Containerd could allow a local authenticated attacker to traverse directories on the system, due to improper restricted permissions on the container root and plugin directories. This issue could allow an attacker to send a specially-crafted request containing "dot dot" sequences (/../) to view directory contents and execute programs.
containerd is an open source container runtime with an emphasis on simplicity, robustness and portability. A bug was found in containerd where container root directories and some plugins had insufficiently restricted permissions, allowing otherwise unprivileged Linux users to traverse directory contents and execute programs. When containers included executable programs with extended permission bits (such as setuid), unprivileged Linux users could discover and execute those programs. When the UID of an unprivileged Linux user on the host collided with the file owner or group inside a container, the unprivileged Linux user on the host could discover, read, and modify those files. This vulnerability has been fixed in containerd 1.4.11 and containerd 1.5.7. Users should update to these version when they are released and may restart containers or update directory permissions to mitigate the vulnerability. Users unable to update should limit access to the host to trusted users. Update directory permission on container bundles directories.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
debian/containerdto a version that resolves this vulnerability.Fixed in 1.4.13~ds1-1~deb11u4Fixed in 1.4.13~ds1-1~deb11u2Fixed in 1.6.20~ds1-1Fixed in 1.6.20~ds1-2 - Upgrade
Upgrade
go/github.com/containerd/containerdto a version that resolves this vulnerability.Fixed in 1.5.7 - Upgrade
Upgrade
go/github.com/containerd/containerdto a version that resolves this vulnerability.Fixed in 1.4.11 - Upgrade
Upgrade
redhat/containerdto a version that resolves this vulnerability.Fixed in 1.4.11 - Upgrade
Upgrade
redhat/containerdto a version that resolves this vulnerability.Fixed in 1.5.7 - Upgrade
Upgrade
containerdto a version that resolves this vulnerability.Fixed in 1.4.11 - Upgrade
Upgrade
containerdto a version that resolves this vulnerability.Fixed in 1.5.7 - Configuration
Update directory permission on container bundles directories to mitigate the vulnerability.
containerd directory permissions on container bundle directories = updated/restricted - Compensating control
Limit access to the host to trusted users if you cannot update containerd.
Event History
Parent advisories
This vulnerability appears in the following advisories.
Frequently Asked Questions
What is CVE-2021-41103?
CVE-2021-41103 is a vulnerability found in the containerd package that allows a local authenticated attacker to escalate privileges.
What is containerd?
containerd is an open source container runtime known for its simplicity, robustness, and portability.
How does CVE-2021-41103 affect containerd?
CVE-2021-41103 affects containerd by allowing unprivileged Linux users to traverse directory contents and potentially escalate their privileges.
What is the severity of CVE-2021-41103?
The severity of CVE-2021-41103 is high with a CVSS score of 7.8.
How can I fix CVE-2021-41103 in containerd?
To fix CVE-2021-41103 in containerd, update to version 1.4.11 or 1.5.7, depending on the specific version you are using.