CVE-2026-41567: Docker: `PUT /containers/{id}/archive` executes container binary on the host

Published May 18, 2026
·
Updated

Summary

When a user uploads a compressed archive into a container, a malicious image can execute arbitrary code with daemon (host root) privileges.

Details

When handling PUT /containers/{id}/archive requests with compressed archives, the daemon decompresses them using external system binaries. Due to incorrect ordering of operations, these binaries are resolved from the container's filesystem rather than the host's. A container image that includes a trojanized decompression binary can achieve code execution as the daemon process whenever a compressed archive is uploaded to that container.

The executed binary runs with the daemon's full privileges, including host root UID and unrestricted capabilities.

Impact

Arbitrary code execution as host root, crossing the container-to-host trust boundary.

Conditions for exploitation

- A user must run a container from a malicious image that contains a trojanized decompression binary. - The user must then upload a compressed archive (xz or gzip) into that container, either by piping a compressed archive via docker cp - or by calling the PUT /containers/{id}/archive API directly with compressed content.

Not affected

Standard docker cp usage is not affected, because the CLI sends uncompressed tar by default:

docker cp ./file.txt mycontainer:/file.txt

This can only be exploited when explicitly passing a xz or gzip-compressed archive to docker cp or the PUT /containers/{id}/archive API, for example:

cat archive.tar.xz | docker cp - mycontainer:/dir

Decompression formats using pure Go implementations (bzip2, zstd, and gzip when the container image does not contain an unpigz binary) are also not affected.

Workarounds

- Only run containers from trusted images. - Use authorization plugins to limit access to the PUT /containers/{id}/archive endpoint. - Avoid piping compressed archives into containers created from untrusted images.

Other sources

Moby is an open source container framework. In versions prior to 29.5.1 and in moby/moby v2 prior to v2.0.0-beta.14, when a compressed archive is uploaded to a container via PUT /containers/{id}/archive or piped through docker cp -, the daemon resolves decompression binaries (such as xz or unpigz) from the container's filesystem rather than the host's due to incorrect ordering of operations. A malicious container image containing a trojanized decompression binary can achieve arbitrary code execution with full daemon privileges, including host root UID and unrestricted capabilities, when a user uploads a compressed (xz or gzip) archive into that container. This issue is fixed in Docker Engine 29.5.1 and moby/moby v2.0.0-beta.14. Workarounds include only running containers from trusted images, using authorization plugins to restrict access to the PUT /containers/{id}/archive endpoint, and avoiding piping compressed archives into containers created from untrusted images

— MITRE

Affected Software

5 affected componentsFixes available
go/github.com/moby/moby<=28.5.2
go/github.com/docker/docker<=28.5.2
go/github.com/moby/moby/v2<2.0.0-beta.14
2.0.0-beta.14
alpine/docker<29.5.1-r0
29.5.1-r0
alpine/docker<29.5.1-r0
29.5.1-r0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade go/github.com/moby/moby/v2 to a version that resolves this vulnerability.

    Fixed in 2.0.0-beta.14
  2. Upgrade

    Upgrade alpine/docker to a version that resolves this vulnerability.

    Fixed in 29.5.1-r0
  3. Upgrade

    Upgrade Docker Engine to a version that resolves this vulnerability.

    Fixed in 29.5.1
  4. Upgrade

    Upgrade moby/moby to a version that resolves this vulnerability.

    Fixed in v2.0.0-beta.14
  5. Configuration

    Use an authorization plugin to limit access to the `PUT /containers/{id}/archive` endpoint so only trusted callers can upload archives into containers.

    Docker daemon API authorization (authorization plugin) for PUT /containers/{id}/archive = restrict
  6. Configuration

    Only run containers from trusted images to reduce the risk of trojanized decompression binaries being present in the container filesystem.

    Container workflow container image trust (only trusted images) = only trusted images
  7. Configuration

    Avoid piping compressed archives into containers created from untrusted images (e.g., `cat archive.tar.xz | docker cp - mycontainer:/dir` and similar workflows).

    Container workflow archive piping into containers from untrusted images = avoid

Event History

May 18, 2026
Advisory Published
via GitHub·05:47 PM
Data Sourced
via GitHub·05:47 PM
DescriptionSeverityWeaknessAffected Software
Jun 5, 2026
CVE Published
via MITRE·12:35 AM
Data Sourced
via MITRE·12:35 AM
DescriptionSeverityWeakness
Data Sourced
via Red Hat·02:01 AM
DescriptionSeverityAffected Software
Data Sourced
via NVD·02:17 AM
DescriptionSeverityWeakness
Aug 21, 2026
Exploit Published
via GitHub·11:08 AM
Nov 3, 2026
Data Sourced
via OSV·06:33 AM
Affected Software

Frequently Asked Questions

1

What is the severity of CVE-2026-41567?

CVE-2026-41567 is considered a critical vulnerability due to its ability to execute arbitrary code with daemon privileges.

2

How do I fix CVE-2026-41567?

To remediate CVE-2026-41567, upgrade to a version of Moby or Docker that is newer than 28.5.2 or use version 2.0.0-beta.14.

3

What types of software are affected by CVE-2026-41567?

CVE-2026-41567 affects Moby and Docker versions up to and including 28.5.2.

4

What kind of attack is possible with CVE-2026-41567?

CVE-2026-41567 allows a malicious user to upload a compressed archive that can trigger arbitrary code execution on the host with root privileges.

5

Is CVE-2026-41567 exploitable through normal user actions?

Yes, CVE-2026-41567 can be exploited when a user uploads a compressed archive to a container.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203