GHSA-pwhc-rpq9-4c8w CVE-2024-25621 GO-2025-4100
containerd affected by a local privilege escalation via wide permissions on CRI directory
- Severity
- 7.3 / 10
- High · CVSS 3.1
- Exploit chance (EPSS)
- 0.17%
- Chance of exploitation in the next 30 days. Higher than 6.12% of scored vulnerabilities.
- Known exploited
- No
- Not in CISA's catalog
- Weakness
- CWE-279 Incorrect Execution-Assigned Permissions
- Fix
- Available
- 2 packages have a fixed version
Description
Impact
An overly broad default permission vulnerability was found in containerd.
/var/lib/containerdwas created with the permission bits 0o711, while it should be created with 0o700- Allowed local users on the host to potentially access the metadata store and the content store
/run/containerd/io.containerd.grpc.v1.criwas created with 0o755, while it should be created with 0o700- Allowed local users on the host to potentially access the contents of Kubernetes local volumes. The contents of volumes might include setuid binaries, which could allow a local user on the host to elevate privileges on the host.
/run/containerd/io.containerd.sandbox.controller.v1.shimwas created with 0o711, while it should be created with 0o700
The directory paths may differ depending on the daemon configuration.
When the temp directory path is specified in the daemon configuration, that directory was also created with 0o711, while it should be created with 0o700.
Patches
This bug has been fixed in the following containerd versions:
- 2.2.0
- 2.1.5
- 2.0.7
- 1.7.29
Users should update to these versions to resolve the issue. These updates automatically change the permissions of the existing directories.
[!NOTE]
/run/containerdand/run/containerd/io.containerd.runtime.v2.taskare still created with 0o711. This is an expected behavior for supporting userns-remapped containers.
Workarounds
The system administrator on the host can manually chmod the directories to not have group or world accessible permisisons:
chmod 700 /var/lib/containerd
chmod 700 /run/containerd/io.containerd.grpc.v1.cri
chmod 700 /run/containerd/io.containerd.sandbox.controller.v1.shim
An alternative mitigation would be to run containerd in rootless mode.
Credits
The containerd project would like to thank David Leadbeater for responsibly disclosing this issue in accordance with the containerd security policy.
For more information
If you have any questions or comments about this advisory:
- Open an issue in containerd
- Email us at security@containerd.io
To report a security issue in containerd:
Affected versions
Go
| Package | Vulnerable | Fixed in |
|---|---|---|
| github.com/containerd/containerd | < 1.7.29 |
1.7.29 |
| github.com/containerd/containerd/v2 | < 2.0.7 |
2.0.7 |
| github.com/containerd/containerd/v2 | >= 2.1.0-beta.0, < 2.1.5 |
2.1.5 |
| github.com/containerd/containerd/v2 | >= 2.2.0-beta.0, < 2.2.0 |
2.2.0 |
| github.com/containerd/containerd/v2 | < 2.0.7>= 2.1.0-beta.0, < 2.1.5>= 2.2.0-beta.0, < 2.2.0 |
2.0.72.1.52.2.0 |
How to fix
Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.
github.com/containerd/containerd Go → 1.7.29
- go
go get github.com/containerd/containerd@v1.7.29 && go mod tidy
github.com/containerd/containerd/v2 Go → 2.0.7
- go
go get github.com/containerd/containerd/v2@v2.0.7 && go mod tidy
Severity breakdown
CVSS 3.1 7.3
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H
- Attack vector
- Local
- Attack complexity
- Low
- Privileges required
- Low
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Weakness
CWE-279: Incorrect Execution-Assigned Permissions
While it is executing, the product sets the permissions of an object in a way that violates the intended permissions that have been specified by the user.
How to prevent it
- Architecture and Design, Operation: Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
- Architecture and Design: Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.
References
Advisories
Packages
Other links
Timeline
- Published
- Last updated by the source
- Latest EPSS score
Related advisories
| Advisory | Severity | Why it's related |
|---|---|---|
| GHSA-rp3h-jf77-q9p4 containerd: Unpack DoS via repeated opaque whiteouts | Medium | Also affects github.com/containerd/containerd |
| GO-2026-6791 containerd CRI plugin: Checkpoint restore bypasses destination security context | High | Also affects github.com/containerd/containerd |
| GHSA-pg57-6jwg-q645 Containerd has image-pull DoS via crafted OCI index graph amplification | Medium | Also affects github.com/containerd/containerd |
| GHSA-7jxh-36q5-gcqv containerd: CRI ExecSync Goroutine Leak Leads to Node-Level Denial of Service | Medium | Also affects github.com/containerd/containerd |
| GO-2026-5064 containerd CRI checkpoint restore CDI annotation smuggling | Critical | Also affects github.com/containerd/containerd |
| GO-2026-5622 Arbitrary host CRI log file read via symlink following in CRI checkpoint restore | Medium | Also affects github.com/containerd/containerd |
| GHSA-xhf5-7wjv-pqxp containerd CRI — image-config `LABEL` flows to restart-monitor `binary://` logger: host-root command execution from an image pull | High | Also affects github.com/containerd/containerd |
| GO-2026-5338 containerd: CRI checkpoint import allows local image tag poisoning | Critical | Also affects github.com/containerd/containerd |
MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.
Check your repos with MergeHarbor