CVE-2024-40635containerd has an integer overflow in User ID handling
containerd is an open-source container runtime. A bug was found in containerd prior to versions 1.6.38, 1.7.27, and 2.0.4 where containers launched with a User set as a `UID:GID` larger than the maximum 32-bit signed integer can cause an overflow condition where the container ultimately runs as root (UID 0). This could cause unexpected behavior for environments that require containers to run as a non-root user. This bug has been fixed in containerd 1.6.38, 1.7.27, and 2.04. As a workaround, ensure that only trusted images are used and that only trusted users have permissions to import images.
What to do
Fixed builds are available from Debian, Go, Ubuntu: see the table below for the fixed version per release.
Ubuntu has not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 25.10 | containerd | Not affected vulnerable_code_not_present | ||
| Ubuntu 25.10 | containerd-app | Fixed | 2.0.2-0ubuntu2 | UBUNTU-CVE-2024-40635 |
| Ubuntu 24.04 | containerd | Fix pending | 1.6.24~ds1-1ubuntu1.2+esm1 (Ubuntu Pro) | UBUNTU-CVE-2024-40635 |
| Ubuntu 24.04 | containerd-app | Fixed | 1.7.24-0ubuntu1~24.04.2 | UBUNTU-CVE-2024-40635 |
| Ubuntu 22.04 | containerd | Fixed | 1.6.12-0ubuntu1~22.04.8 | UBUNTU-CVE-2024-40635 |
| Ubuntu 22.04 | containerd-app | Fixed | 1.7.24-0ubuntu1~22.04.2 | UBUNTU-CVE-2024-40635 |
| Ubuntu 20.04 | containerd | Fixed | 1.6.12-0ubuntu1~20.04.8 | UBUNTU-CVE-2024-40635 |
| Ubuntu 20.04 | containerd-app | Fixed | 1.7.24-0ubuntu1~20.04.2 | UBUNTU-CVE-2024-40635 |
| Ubuntu 18.04 | containerd | Fix pending | 1.6.12-0ubuntu1~18.04.1+esm2 (Ubuntu Pro) | UBUNTU-CVE-2024-40635 |
| Ubuntu 16.04 | containerd | Fix pending | 1.2.6-0ubuntu1~16.04.6+esm5 (Ubuntu Pro) | UBUNTU-CVE-2024-40635 |
| Debian 14 | containerd | Fixed | 1.7.24~ds1-6 | DEBIAN-CVE-2024-40635 |
| Debian 13 | containerd | Fixed | 1.7.24~ds1-6 | DEBIAN-CVE-2024-40635 |
| Debian 12 | containerd | Fixed | 1.6.20~ds1-1+deb12u2 | DEBIAN-CVE-2024-40635 |
| Go library | github.com/containerd/containerd | Fixed | 1.6.38 | GHSA-265r-hfxg-fhmg |
| Go library | github.com/containerd/containerd/v2 | Fixed | 2.0.4 | GHSA-265r-hfxg-fhmg |
What the vendor says
As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- containerd: affected: < 1.6.38, >= 1.7.0-beta.0, < 1.7.27, >= 2.0.0-beta.0, < 2.0.4
References
- https://github.com/containerd/containerd/security/advisories/GHSA-265r-hfxg-fhmg
- https://github.com/containerd/containerd/commit/05044ec0a9a75232cad458027ca83437aae3f4da
- https://github.com/containerd/containerd/commit/1a43cb6a1035441f9aca8f5666a9b3ef9e70ab20
- https://github.com/containerd/containerd/commit/cf158e884cfe4812a6c371b59e4ea9bc4c46e51a
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.