CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-17106

CVE-2026-17106: Container-to-Host Arbitrary File Write in moby/go-archive (CopyEscape)

Amit Schendel
Amit Schendel
Senior Security Researcher

Aug 18, 2026·6 min read·240 visits

Executive Summary (TL;DR)

A TOCTOU race condition in the directory-scanning phase of 'docker cp' combined with lexical path validation errors on the client host allows a compromised container to write arbitrary files outside the extraction destination, potentially causing full host system takeover.

CVE-2026-17106 (CopyEscape) is a container-to-host arbitrary file-write vulnerability within Docker's archiving and extraction library moby/go-archive. By utilizing a Time-of-Check to Time-of-Use (TOCTOU) race condition during the file-walking stage inside a running container, a malicious container process can force the host engine to produce a compromised tar stream. During client-side extraction, the Docker CLI resolves directory entries through absolute symbolic links, resulting in arbitrary file creation or modification on the host system.

Vulnerability Overview

CVE-2026-17106, colloquially known as CopyEscape, represents a container escape vector through the archiving and extraction utilities of the Docker ecosystem. The vulnerability resides within the moby/go-archive dependency, which is heavily relied upon by components such as docker cp and Docker Sandboxes' sbx cp commands. Under typical conditions, these utilities facilitate the copying of files between the virtual container environment and the physical host system.

The underlying data transfer operates using a producer-consumer model where files are walked, packed into a tar archive stream by the Docker daemon inside the container context, and then decoded and unpacked on the host client filesystem. This architecture assumes the container filesystem remains static during the walk and serialization phases.

An attacker controlling a running container can exploit this operational model. By introducing an on-the-fly path substitution during the serialization phase, the attacker can force the host client to extract arbitrary payloads directly onto its native filesystem, inheriting the system privileges of the local user running the client CLI utility.

Root Cause Analysis

The vulnerability stems from two independent implementation flaws: a Time-of-Check to Time-of-Use (TOCTOU) race condition on the daemon-side path walk, and a client-side directory containment failure during path verification. On the daemon side, file selection for packaging is executed using directory scanning helpers like filepath.WalkDir. While this traversal is underway, the container runtime environment remains active, allowing concurrent filesystem updates by container-bound processes.

On the host client side, path verification is performed lexically before filesystem writes occur. The extraction logic computes target locations by concatenating the extraction destination with the raw file headers. If the generated path resides mathematically within the designated destination structure, the extraction logic accepts the operation.

This validation method fails because lexical checks do not resolve symbolic links on disk. An attacker can set up a subdirectory, wait for the daemon to inspect the path, and then replace that subdirectory with an absolute symbolic link pointing to a host directory. Because the lexical check passes for child entries under the parent directory path, the host client follows the newly created symbolic link during physical file extraction, resulting in out-of-boundary file creation.

Code Analysis

The original, vulnerable logic in moby/go-archive verified directory containment using pure string manipulation. The string comparison evaluated whether the target path contains the destination directory path as a prefix without verifying intermediate links on the physical filesystem:

// INSECURE: Lexical verification bypass
dstPath := filepath.Join(dest, hdr.Name)
rel, err := filepath.Rel(dest, dstPath)
if strings.HasPrefix(rel, ".."+string(os.PathSeparator)) {
    return breakoutError(fmt.Errorf("%q is outside of %q", hdr.Name, dest))
}

If the archive contains a symbolic link named escape pointing to /usr/bin, and a child element escape/runc, the lexical analysis verifies both dest/escape and dest/escape/runc as structurally internal to dest. During the physical write, however, the OS resolves the symbolic link escape on disk, allowing the payload file to overwrite the physical host binary /usr/bin/runc.

To correct this defect, the remediation replaces lexical validation with an OS-enforced directory sandboxing model using the modern os.Root API introduced in Go 1.26. The patched implementation opens the destination target first and isolates all subsequent file creation routines to this file descriptor:

// SECURE: Enforced filesystem sandboxing via os.Root
root, err := os.OpenRoot(dest)
if err != nil {
    return err
}
defer func() { _ = root.Close() }()
 
// Writes are restricted using file-descriptor-relative operations
file, err := root.OpenFile(dstPath, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, hdrInfo.Mode()&0o777)

By leveraging openat2 with the RESOLVE_BENEATH flag under Linux, the operating system kernel prevents file operations from traversing symbolic links pointing outside the open root folder. Any attempt to traverse an absolute symbolic link triggers a directory escape error and halts extraction.

Exploitation Methodology

An exploitation chain requires a running container under the attacker's control and active user interaction on the host. The attacker prepares the internal container environment by creating a nested file structure containing a large dummy file, a target subdirectory, and a staged absolute symbolic link. The large file acts as an artificial delay during the serialization phase.

The attacker runs an internal filesystem monitor utilizing inotify watches. When a host administrator executes docker cp to extract files, the daemon begins scanning the container filesystem and reading the large dummy file. This interaction triggers the inotify open event, signaling the monitor process to initiate the race.

The monitor process immediately invokes rename system calls to swap the target directory with the prepared absolute symbolic link pointing to a host destination like /usr/bin. The daemon packages the symbolic link alongside the nested payload files. Upon receiving this stream, the host CLI extracts the absolute link, follows it, and overwrites target files on the host.

Impact Assessment

The impact of CVE-2026-17106 is highly critical, with potential for arbitrary host code execution. If the host administrator runs the client utilities as root, an attacker can modify host binaries. For example, overwriting /usr/bin/runc grants complete command execution as root the next time a container is started or stopped on the host.

If the executing host user has limited privileges, the write capabilities are restricted to the directories owned by that user. However, this still permits high-impact actions, such as writing to local user shell profiles like ~/.bashrc or ~/.zshrc to achieve privilege escalation.

The CVSS v4.0 metrics yield a base score of 7.1. While confidentiality, integrity, and availability impacts are elevated, the requirement for active host user interaction limits spontaneous remote execution vectors.

Remediation and Mitigation

Remediation requires upgrading container client and engine environments to versions incorporating the moby/go-archive 0.3.0 patch. Users must update Docker Desktop to version 4.86.0 or higher, and Docker Engine to 29.7.0 or higher.

Temporary workarounds should be applied if immediate patching is not possible. Administrators should avoid running docker cp against containers executing unverified workloads. Restricting the execution of host-side copy commands to non-root users ensures any malicious write remains contained within normal user permissions.

Additionally, systems should run monitoring utilities like auditd to identify anomalous modifications to crucial container helper files. Configuring logging mechanisms to report file write operations on paths such as /usr/bin/runc provides immediate detection capabilities.

Fix Analysis (2)

Technical Appendix

CVSS Score
7.1/ 10
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Affected Systems

moby/go-archive < 0.3.0Docker Desktop < 4.86.0Docker Engine < 29.7.0Docker CLI < 29.7.0Docker Compose < 5.4.0Docker Sandboxes < 0.38.0

Affected Versions Detail

Product
Affected Versions
Fixed Version
go-archive
moby
< 0.3.00.3.0
Docker Desktop
Docker
< 4.86.04.86.0
Docker Engine
Docker
< 29.7.029.7.0
AttributeDetail
CWE IDCWE-59
Attack VectorLocal (AV:L)
CVSS v4.0 Score7.1
Exploit StatusProof of Concept (PoC)
Vulnerability ClassImproper Link Resolution ('Link Following')
ImpactArbitrary File Write / Privilege Escalation

MITRE ATT&CK Mapping

T1574Hijack Execution Flow
Persistence
T1059Command and Scripting Interpreter
Execution
T1222File and Directory Permissions Modification
Defense Evasion
CWE-59
Improper Link Resolution Before File Access ('Link Following')

The application attempts to access a file based on a filename, but it does not properly prevent that file from being a symbolic link or hard link that points to an unintended external resource.

Known Exploits & Detection

GitHubCopyEscape Official PoC

References & Sources

  • [1]moby/go-archive GHSA Security Advisory
  • [2]CopyEscape Proof of Concept

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•23 minutes ago•CVE-2026-59191
6.9

CVE-2026-59191: Path Traversal and Arbitrary File Read in CakePHP TwigView FileLoader

A path traversal vulnerability exists in the cakephp/twig-view plugin for the CakePHP framework prior to versions 1.3.3 and 2.1.2. The Cake\TwigView\Twig\FileLoader::findTemplate() method verifies template existence using PHP's native file_exists() function without ensuring the target path resides within configured application or plugin template directories. When user-controlled input is passed to template inclusion mechanisms, an unauthenticated remote attacker can read arbitrary local files accessible to the PHP runtime.

Alon Barad
Alon Barad
2 views•9 min read
•about 1 hour ago•CVE-2026-64855
8.2

CVE-2026-64855: Cryptographic Signature Verification Bypass in soapbar WS-Security Implementation

CVE-2026-64855 (GHSA-859w-52fx-hcm6) is a cryptographic signature verification and authentication bypass vulnerability in the soapbar Python library prior to version 0.13.0. In vulnerable versions, the verify_envelope_bsp() function derives its trust anchor directly from the incoming SOAP message by extracting an untrusted X.509 certificate embedded inside the wsse:BinarySecurityToken header. Because the function checks only the temporal validity of the extracted certificate without performing Certificate Authority (CA) chain validation or certificate pinning, an unauthenticated network attacker can generate a self-signed certificate, sign an arbitrary SOAP payload, and pass verification.

Amit Schendel
Amit Schendel
2 views•10 min read
•about 2 hours ago•GHSA-JP3C-6V3G-MPXV
6.5

GHSA-jp3c-6v3g-mpxv: Uncaught Runtime Panic via Integer Underflow in insomniacslk/dhcp BroadcastRawUDPConn

A denial-of-service vulnerability exists in the Go library github.com/insomniacslk/dhcp within the dhcpv4/nclient4 subpackage. In affected versions, the raw packet parsing function BroadcastRawUDPConn.ReadFrom subtracts the fixed 8-byte UDP header length from the IPv4 payload length declared in the packet header without first verifying that the declared payload length is at least 8 bytes. An unauthenticated attacker on an adjacent local network segment can broadcast or unicast a malformed IPv4 packet with a declared payload length between 0 and 7 bytes, causing a signed integer underflow that passes a negative slice bound into buf.Consume and triggers an unhandled Go runtime panic.

Amit Schendel
Amit Schendel
4 views•12 min read
•about 3 hours ago•CVE-2026-63305
8.1

CVE-2026-63305: OS Command Injection in WWBN AVideo Standalone FFmpeg Script

CVE-2026-63305 (GHSA-g9x9-q7qj-6mv5) is an operating system command injection vulnerability affecting WWBN AVideo (formerly YouPHPTube) versions up to and including 29.0. The defect resides in the standalone FFmpeg execution handler at plugin/API/standAlone/ffmpeg.json.php. When assembling asynchronous post-processing commands, the script concatenates the notifyCode and callback properties from a decrypted payload directly into a shell command string without sanitization. An attacker capable of providing or forging a valid encrypted execution payload can inject shell metacharacters to achieve remote code execution under the privileges of the web server user.

Alon Barad
Alon Barad
3 views•10 min read
•about 6 hours ago•CVE-2026-59192
6.9

CVE-2026-59192: Unsafe Deserialization in CakePHP TwigView UtilsExtension

The cakephp/twig-view plugin integrates the Twig templating engine into the CakePHP framework. Prior to versions 1.3.3 and 2.1.2, the UtilsExtension class exposes PHP's native unserialize() function as a Twig filter without restricting allowed classes. When untrusted data is passed into the unserialize filter within a template, an attacker can trigger PHP Object Injection and execute Property-Oriented Programming (POP) gadget chains, leading to arbitrary code execution or data manipulation.

Alon Barad
Alon Barad
3 views•8 min read
•about 22 hours ago•CVE-2026-63402
5.9

CVE-2026-63402: Prototype-Chain Traversal and Shared Built-in Corruption in i18next

CVE-2026-63402 is a prototype-chain traversal and shared built-in object corruption vulnerability in the i18next internationalization framework for JavaScript prior to version 26.3.4. The flaw resides in the deepExtend utility function within src/utils.js, which uses the JavaScript 'in' operator to verify property existence on target objects. When an application passes untrusted resource bundles to i18next.addResourceBundle() with both the deep and overwrite parameters set to true, an attacker can traverse into inherited methods on Object.prototype and overwrite properties on shared built-in function objects, causing process-wide denial of service.

Amit Schendel
Amit Schendel
7 views•10 min read