CVE-2026-41568: Docker & Moby Race Condition in docker cp Mount Setup
A race condition vulnerability in Docker Engine and Moby allows a malicious container to create empty files or directories at arbitrary locations on the host filesystem during the docker cp operation. An attacker with container access can exploit a timing window in mount setup to place files outside intended boundaries, potentially disrupting host operations or creating persistent artifacts. The vulnerability requires local access and user interaction, limiting but not eliminating real-world risk in multi-tenant or supply-chain scenarios.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 6.1 MEDIUM · CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:C/C:N/I:L/A:H
- Weaknesses (CWE)
- CWE-367, CWE-81
- Affected products
- 16 configuration(s)
- Published / Modified
- 2026-06-12 / 2026-06-17
NVD description (verbatim)
Moby is an open source container framework. In Docker Engine prior to version 29.5.1, Docker Daemon versions 28.5.2 and prior, and Moby Daemon prior to version 2.0.0-beta.14, a race condition during docker cp mount setup allows a malicious container to create empty files or directories at arbitrary absolute paths on the host filesystem. This issue has been patched in Docker Engine version 29.5.1 and Moby Daemon version 2.0.0-beta.14.
1 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
CVE-2026-41568 is a time-of-check-time-of-use (TOCTOU) race condition in the docker cp mount initialization sequence. When copying files between containers and hosts, the daemon performs security checks before finalizing mount paths. A malicious container can exploit the window between validation and mount completion to manipulate symlinks or filesystem state, redirecting writes to unintended absolute paths on the host. The vulnerability stems from insufficient synchronization during the mount setup phase, allowing directory traversal despite intended path restrictions.
Business impact
Organizations running Docker or Moby-based container platforms face host filesystem integrity risks. An insider or compromised container could create denial-of-service conditions by filling critical directories, corrupt configuration files, or establish persistence mechanisms outside container boundaries. Multi-tenant environments and CI/CD platforms where untrusted images are executed face elevated exposure. The impact is localized to the affected host and requires container execution privileges, but successful exploitation could disrupt service availability or enable lateral movement.
Affected systems
Docker Engine versions prior to 29.5.1, Docker Daemon versions 28.5.2 and earlier, and Moby Daemon versions before 2.0.0-beta.14 are vulnerable. Organizations should identify running instances via docker version and moby version commands. Verify the exact installed versions against vendor advisories, as patching schedules vary between Docker Enterprise, Community editions, and independent Moby deployments.
Exploitability
Exploitation requires local container access and relies on precise timing to win a race condition, making it moderately difficult but not infeasible. The attack does not require elevated privileges within the container, only ability to execute the docker cp command or trigger it via exposed APIs. User interaction is necessary (the CVSS vector reflects PR:L and UI:R), meaning the attack requires a user to perform a copy operation while the malicious container manipulates the filesystem. Detection and execution of reliable exploits is non-trivial due to race condition variability, but proven proof-of-concepts are likely to emerge post-disclosure.
Remediation
Patch Docker Engine to version 29.5.1 or later, upgrade Moby Daemon to 2.0.0-beta.14 or newer, and ensure Docker Daemon is at version 28.5.3 or above. Review deployment manifests to enforce image scanning and prevent execution of untrusted container images. Consider runtime policies restricting docker cp to trusted workflows and monitor for suspicious copy operations targeting host paths.
Patch guidance
Apply Docker Engine version 29.5.1 or later as the primary remediation. For Moby deployments, upgrade to version 2.0.0-beta.14 or later. For Docker Daemon, verify that version 28.5.3 or above is deployed—versions 28.5.2 and prior are vulnerable. Test patches in non-production environments before rollout to confirm compatibility with existing container workloads and orchestration configurations. Confirm successful patching by running 'docker version' and verifying the Engine version number matches the patched release.
Detection guidance
Monitor container runtime logs for unexpected docker cp operations targeting host root or system directories. Implement filesystem integrity monitoring (FIM) on hosts to detect unauthorized file creation in sensitive paths. Watch for failed docker cp attempts with permission errors, which may indicate exploitation attempts. Correlate container execution logs with host syscall traces to identify timing anomalies during mount operations. Organizations using container security platforms should enable runtime anomaly detection rules for suspicious copy operations.
Why prioritize this
Medium severity (CVSS 6.1) is appropriate given the moderate exploitability barriers (race condition timing, local access requirement) and significant availability and integrity impacts. The vulnerability is not yet in active exploitation at scale (KEV status: not currently listed), but race condition vulnerabilities are difficult to predict and can be weaponized with sufficient engineering effort. Prioritize patching for multi-tenant environments, CI/CD platforms executing external images, and systems where container-to-host file operations are routine. Organizations with strict container image controls and isolated single-tenant deployments can schedule patching in regular maintenance windows.
Risk score, explained
The CVSS 3.1 score of 6.1 reflects low attack vector (local-only), high attack complexity (race condition requires timing precision), low privileges required (container user suffices), and required user interaction (copy operation must be initiated). Impact is constrained to integrity (file creation) and availability (potential denial-of-service via filesystem exhaustion), with no confidentiality breach. The score appropriately elevates due to the scope change (S:C) from container to host context, indicating cross-boundary impact despite limited initial access.
Frequently asked questions
Can this vulnerability be exploited without executing a container?
No. The attacker must have ability to run or influence a container on the affected system. This could be via direct container execution, a compromised image in a shared registry, or supply-chain injection, but passive network-only attacks are not possible.
Does patching require downtime or container restart?
Patching the Docker daemon or Moby requires restarting the container runtime, which will terminate all running containers. Plan patching during maintenance windows and coordinate with teams running persistent workloads. Verify patch compatibility with your orchestration platform (Kubernetes, Swarm, etc.) before applying.
How does this differ from a typical container escape?
This is not a full container escape. It allows file creation on the host at controlled paths, but does not grant shell access, code execution, or privilege escalation. The attacker remains confined to the permissions of the copy operation and cannot directly execute host commands.
Should we block docker cp in our environment?
Not necessarily, but restricting docker cp to trusted operations and users is prudent. Implement RBAC policies limiting who can execute docker cp, scan container images for malicious content before execution, and monitor copy operations targeting sensitive directories.
This analysis is based on vendor advisories and CVE data published as of June 2026. Exploit code, detailed attack chains, and proprietary proof-of-concept information are intentionally omitted. Organizations must validate patch applicability against their specific Docker or Moby version and test in non-production environments before deployment. SEC.co does not endorse or provide weaponization guidance; security teams should follow responsible disclosure practices and coordinate patching with relevant vendors and stakeholders. Source: NVD (public-domain), retrieved 2026-07-20. Analysis generated by SEC.co (claude-haiku-4-5).
Affected vendors
Related vulnerabilities
- CVE-2026-42306HIGHDocker Engine Race Condition in Bind Mount Setup (CVSS 7.2)
- CVE-2025-59610MEDIUMQualcomm Memory Corruption via IOCTL API Version Mismatch – Patch Guidance
- CVE-2026-20454MEDIUMMediaTek geniezone Race Condition Privilege Escalation (CVSS 6.4)
- CVE-2026-45619MEDIUMWWBN AVideo DNS-Rebinding SSRF Vulnerability
- CVE-2026-45647MEDIUMMicrosoft Defender for Endpoint Privilege Escalation Race Condition
- CVE-2026-46159MEDIUMLinux btrfs TOCTOU Race Condition Information Disclosure
- CVE-2026-46194MEDIUMLinux F2FS Extent Node Race Condition Leading to Kernel Crash
- CVE-2026-49958MEDIUMHermes WebUI TOCTOU Race Condition Arbitrary File Deletion