CVE-2026-15789

Malicious client can bypass destination directory validation on local sources upload

Published Jul 21, 2026 CVSS 4.0 · 6.9 Medium EPSS < 1% KEV · Not listed
Description
A custom client can produce such an upload request to the BuildKit daemon that files can escape from the BuildKit-controlled state directory. The client needs to have valid permissions to access the BuildKit control API to issue builds, e.g., bypass authentication, etc.

Analysis

AI-generated

Technical impact

A custom client can construct an upload request to the BuildKit daemon that bypasses destination directory validation, enabling files to be written outside the intended state directory. The flaw permits arbitrary file placement, which could lead to unauthorized disclosure, tampering with the build environment, or execution of malicious code within the daemon’s context. This weakness is a directory traversal flaw (CWE‑22). The likely attack vector requires the attacker to possess valid permissions to the BuildKit control API or to bypass authentication mechanisms, as the client must authenticate to issue builds.

Affected Systems

Moby’s BuildKit is affected when it accepts uploads from non‑standard clients; any instance that allows builds from external parties without strict client validation is potentially impacted. No specific version information is provided, so the risk applies broadly to BuildKit deployments that accept such uploads.

Risk and Exploitability

The CVSS score of 6.9 indicates a medium severity flaw, while the EPSS score of below 1 % shows an extremely low expected exploitation probability at present. The issue is not listed in the CISA KEV catalog. Exploitation requires access to the BuildKit control API, meaning the attacker must either hold legitimate credentials or bypass authentication mechanisms. Because the flaw allows arbitrary file placement, successful exploitation would grant the attacker significant compromise potential for the BuildKit service and downstream systems interacting with its state directories.

Remediation

Vendor Workaround

Only use proper BuildKit clients (Docker Buildx, Buildctl) to issue builds. The issue only affects scenarios where you are running a BuildKit service with untrusted parties issuing builds.


OpenCVE Recommended Actions

  • Use an official BuildKit client such as Docker Buildx or Buildctl to issue builds, ensuring proper destination directory validation is performed.
  • Limit access to the BuildKit control API to trusted, authenticated clients and enforce strict authentication policies to prevent unauthorized build submissions.
  • Enforce filesystem permissions and conduct integrity checks on the BuildKit state directory to block unauthorized file writes and detect anomalous file placement.

Generated by OpenCVE AI on July 30, 2026 at 17:09 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared Moby
Moby buildkit
Vendors & Products Moby
Moby buildkit
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description A custom client can produce such an upload request to the BuildKit daemon that files can escape from the BuildKit-controlled state directory. The client needs to have valid permissions to access the BuildKit control API to issue builds, e.g., bypass authentication, etc.
Title Malicious client can bypass destination directory validation on local sources upload
Weaknesses CWE-22
References
Metrics cvssV4_0

{'score': 6.9, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Sources

Status
PUBLISHED
Assigner
Docker
Published
Updated
Jul 21, 2026, 5:13 PM
Reserved
Jul 14, 2026, 7:27 PM
Status
Analyzed
Published
Jul 21, 2026, 5:17 PM
Modified
Oct 24, 2026, 7:10 PM