Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
HighPublic exploit

runc container escape via /dev/console bind-mount race

IdentifiersCVE-2025-52565CWE-367

CVE-2025-52565 is a vulnerability in runc, the OCI container runtime, caused by insufficient validation during the bind-mount of /dev/pts/$n to /dev/console for containers that allocate a console. Affected versions are 1.0.0-rc3 through 1.2.7, 1.3.0-rc.1 through 1.3.2, and 1.4.0-rc.1 through 1.4.0-rc.2. During container initialization, an attacker can exploit a race condition and path redirection/symlink manipulation so that runc bind-mounts an unintended path onto a location writable from inside the container. Because this mount occurs before maskedPaths and readonlyPaths protections are applied, paths that would normally be masked or made read-only can become writable inside the container. The issue occurs after pivot_root(2), so it is not described as a direct host-file overwrite primitive, but it can expose writable procfs targets such as /proc/sysrq-trigger or /proc/sys/kernel/core_pattern inside the container, enabling denial of service or container escape.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation can break container isolation. The primary impacts described are host denial of service, for example by obtaining writable access to /proc/sysrq-trigger, and container breakout/host privilege escalation by obtaining writable access to /proc/sys/kernel/core_pattern and abusing it to execute code as root on the host. More generally, the flaw allows bypass of maskedPaths/readonlyPaths intent for the affected mount path and can expose sensitive procfs entries to attacker-controlled writes from within the container.

Mitigation

If you can’t patch tonight, do this now.

If immediate patching is not possible, reduce exploitability by enabling user namespaces and preferably using rootless containers so runc does not run with host-root-equivalent privileges. Avoid running untrusted container images or Dockerfiles, especially where attackers can influence mount configuration or container startup behavior. For non-user-namespaced containers, run workloads as non-root and enable noNewPrivileges where feasible. The provided content notes that default containers-selinux policy mitigates this issue in many cases because the /dev/console bind mount is not relabeled, though this protection can be weakened in combination with CVE-2025-52881; default Docker/Podman AppArmor profiles do not meaningfully mitigate it.

Remediation

Patch, then assume compromise.

Upgrade runc to a fixed version: 1.2.8, 1.3.3, or 1.4.0-rc.3 or later, depending on the branch in use. Affected versions are 1.0.0-rc3 through 1.2.7, 1.3.0-rc.1 through 1.3.2, and 1.4.0-rc.1 through 1.4.0-rc.2. Unsupported older branches are not indicated as patched in the provided content. Where runc is consumed indirectly through container platforms or OS packages, apply the vendor-provided runtime update.
PUBLIC EXPLOITS

Exploits

No valid public exploits. Mallory filtered out 1 candidate as fakes, detection scripts, or README-only repos.

VALID 0 / 1 TOTALView more in app

All candidate exploits were filtered out by Mallory's validation.

EXPOSURE SURFACE

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
Amazon Web ServicesAmazon Linuxoperating_system
Linux FoundationRuncapplication

Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence

Every observed campaign linking this CVE to a named adversary.

Associated malware

Malware families riding this exploit, with evidence and IOCs.

Detection signatures

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity42

Community discussion across Reddit, Mastodon, and other social sources.