containerd 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.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2024-40635
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 2 Nov 2026, 15:28 UTC · Revision 1
Source evidence
containerd has an integer overflow in User ID handling
core-osv · Original sourcePublished 17 Mar 2025, 21:32 UTC
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.
osv:CVE-2024-40635
Complete source record
{
"id": "9f603fe95d1e59ae7c1bad1ca7b7280100109b141bc16c16a170f8ae39b2e05b",
"url": "https://osv.dev/vulnerability/CVE-2024-40635",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "containerd has an integer overflow in User ID handling",
"summary": "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.",
"evidence": "osv:CVE-2024-40635",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2024-40635",
"aliases": [
"CVE-2024-40635",
"GHSA-265r-hfxg-fhmg",
"GO-2025-3528"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:L/I:L/A:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/containerd/containerd",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "cf158e884cfe4812a6c371b59e4ea9bc4c46e51a"
},
{
"introduced": "1fbd70374134b891f97ce19c70b6e50c7b9f4e0d"
},
{
"fixed": "05044ec0a9a75232cad458027ca83437aae3f4da"
},
{
"introduced": "207ad711eabd375a01713109a8a197d197ff6542"
},
{
"fixed": "1a43cb6a1035441f9aca8f5666a9b3ef9e70ab20"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:linuxfoundation:containerd:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "0"
},
{
"fixed": "1.6.38"
}
],
"source": "CPE_RANGE"
},
{
"cpe": "cpe:2.3:a:linuxfoundation:containerd:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "1.7.0"
},
{
"fixed": "1.7.27"
}
],
"source": "CPE_RANGE"
},
{
"cpe": "cpe:2.3:a:linuxfoundation:containerd:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "2.0.0"
},
{
"fixed": "2.0.4"
}
],
"source": "CPE_RANGE"
},
{
"range": [
{
"fixed": "05044ec0a9a75232cad458027ca83437aae3f4da"
}
],
"source": "REFERENCES_COMMIT"
},
{
"range": [
{
"fixed": "1a43cb6a1035441f9aca8f5666a9b3ef9e70ab20"
}
],
"source": "REFERENCES_COMMIT"
},
{
"range": [
{
"fixed": "cf158e884cfe4812a6c371b59e4ea9bc4c46e51a"
}
],
"source": "REFERENCES_COMMIT"
}
]
}
}
],
"versions": [
"v1.7.26",
"v2.0.3",
"v1.6.37",
"v1.7.25",
"v2.0.2",
"v2.0.1",
"v1.7.24",
"v2.0.0",
"v1.7.23",
"v1.6.36",
"v1.7.22",
"v1.7.21",
"v1.6.35",
"v1.6.34",
"v1.7.20",
"v1.7.19",
"api/v1.7.19",
"v1.6.33",
"v1.7.18",
"v1.7.17",
"v1.6.32",
"v1.7.16",
"v1.6.31",
"v1.7.15",
"v1.7.14",
"v1.6.30",
"v1.6.29",
"v1.7.11",
"v1.7.13",
"v1.6.28",
"v1.7.12",
"v1.6.27",
"v1.6.26",
"v1.6.25",
"v1.7.10",
"v1.7.9",
"v1.7.8",
"v1.7.7",
"v1.6.24",
"v1.7.6",
"v1.7.5",
"v1.7.4",
"v1.6.23",
"v1.7.3",
"v1.6.22",
"v1.7.2",
"v1.6.21",
"v1.7.1",
"v1.6.20",
"v1.7.0",
"v1.6.19",
"v1.6.18",
"v1.6.17",
"v1.6.13",
"v1.6.16",
"v1.6.15",
"v1.6.14",
"v1.6.12",
"v1.6.11",
"v1.6.10",
"v1.6.9",
"v1.6.8",
"v1.6.7",
"v1.6.6",
"v1.6.5",
"v1.6.4",
"v1.6.3",
"v1.6.2",
"v1.6.1",
"v1.6.0-rc.3",
"v1.6.0",
"v1.6.0-rc.4",
"v1.6.0-rc.2",
"v1.6.0-rc.1",
"v1.6.0-rc.0",
"v1.6.0-beta.5",
"v1.6.0-beta.4",
"v1.6.0-beta.3",
"api/v1.6.0-beta.3",
"v1.6.0-beta.2",
"api/v1.6.0-beta.2",
"v1.6.0-beta.1",
"api/v1.6.0-beta.1",
"v1.6.0-beta.0",
"v1.5.0",
"v1.5.0-rc.3",
"v1.5.0-rc.2",
"v1.5.0-rc.1",
"v1.5.0-rc.0",
"v1.5.0-beta.4",
"v1.5.0-beta.3",
"v1.5.0-beta.2",
"v1.5.0-beta.1",
"v1.5.0-beta.0",
"v1.4.0",
"v1.4.0-rc.1",
"v1.4.0-rc.0",
"v1.4.0-beta.2",
"v1.4.0-beta.1",
"v1.4.0-beta.0",
"v1.3.0",
"v1.3.0-rc.3",
"v1.3.0-rc.2",
"v1.3.0-rc.1",
"v1.3.0-rc.0",
"v1.3.0-beta.2",
"v1.3.0-beta.1",
"v1.3.0-beta.0",
"v1.2.0",
"v1.2.0-rc.2",
"v1.2.0-rc.1",
"v1.2.0-rc.0",
"v1.2.0-beta.2",
"v1.2.0-beta.1",
"v1.2.0-beta.0",
"v1.1.0",
"v1.1.0-rc.2",
"v1.1.0-rc.1",
"v1.1.0-rc.0",
"v1.0.0",
"v1.0.0-rc.0",
"v1.0.0-beta.3",
"v1.0.0-beta.2",
"v1.0.0-beta.1",
"v1.0.0-beta.0",
"v1.0.0-alpha6",
"v1.0.0-alpha5",
"v1.0.0-alpha4",
"v1.0.0-alpha3",
"v1.0.0-alpha2",
"v1.0.0-alpha1",
"v1.0.0-alpha0",
"v0.2.0",
"0.0.5",
"0.0.4",
"0.0.3",
"0.0.2"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-40635.json"
}
}
],
"modified": "2026-10-28T02:30:20.573280896Z",
"provider": "osv",
"references": [
"https://lists.debian.org/debian-lts-announce/2025/05/msg00005.html",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/40xxx/CVE-2024-40635.json",
"https://github.com/containerd/containerd/security/advisories/GHSA-265r-hfxg-fhmg",
"https://nvd.nist.gov/vuln/detail/CVE-2024-40635",
"https://github.com/containerd/containerd/commit/05044ec0a9a75232cad458027ca83437aae3f4da",
"https://github.com/containerd/containerd/commit/1a43cb6a1035441f9aca8f5666a9b3ef9e70ab20",
"https://github.com/containerd/containerd/commit/cf158e884cfe4812a6c371b59e4ea9bc4c46e51a"
],
"provider_metadata": {
"cwe_ids": [
"CWE-190"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/40xxx/CVE-2024-40635.json"
}
},
"related_cves": [
{
"value": "CVE-2024-40635",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 486528,
"published_at": "2025-03-17T21:32:37.894+00:00"
}