How to fix CVE-2024-21626 – Step-by-Step Guide
CVE-2024-21626, "Leaky Vessels," is a high-severity runc container escape vulnerability. It allows malicious containers to gain root access to the host system, impacting Docker, Kubernetes, and other runc-based environments.
What is runc Container Escape – Leaky Vessels?
CVE-2024-21626 is a file descriptor leak in runc versions < 1.1.12. It allows a malicious container to exploit a leaked file descriptor via /proc/self/fd. This bypasses container isolation, enabling the attacker to gain root access on the host system.
Impact and Risks for your Infrastructure
This vulnerability leads to a full container escape, granting an attacker root privileges on the host system. This critical compromise can result in data breaches, complete system takeover, and widespread service disruption across your containerized infrastructure.
Step-by-Step Mitigation Guide
Mitigate CVE-2024-21626 by updating runc to version 1.1.12 or later. For Docker, Kubernetes, and containerd users, apply the latest security patches for your platform. Verify by confirming runc version 1.1.12+ is active on all container hosts.
- 1Update runc to 1.1.12 or later.
- 2Update Docker to 25.0.2+ / 24.0.9+ and containerd to 1.7.13+ / 1.6.27+.
- 3Run containers as non-root with --user and --cap-drop=ALL.
- 4Enable Seccomp and AppArmor/SELinux profiles for containers.
- 5Restrict /proc access with read-only mounts where possible.
- 6Run containers in rootless mode (Podman, rootless Docker) for defense-in-depth.