Skip to content

compose

Docker Compose Vulnerable to Path Traversal via OCI Artifact Layer Annotations

CVE-2025-62725Published 27 Oct 2025, 20:37 UTC

Real-world risk

2.8/ 10Low

Routine

If the vulnerable configuration applies to you: 6.3

PreliminaryFrom the CVSS vector only · confidence low

CVSS

8.9

scored by the vendor (CNA), CVSS 4.0

In plain words

No plain-language summary yet. The original description is below.

Original description (from GitHub_M)

Docker Compose trusts the path information embedded in remote OCI compose artifacts. When a layer includes the annotations com.docker.compose.extends or com.docker.compose.envfile, Compose joins the attacker‑supplied value from com.docker.compose.file/com.docker.compose.envfile with its local cache directory and writes the file there. This affects any platform or workflow that resolves remote OCI compose artifacts, Docker Desktop, standalone Compose binaries on Linux, CI/CD runners, cloud dev environments is affected. An attacker can escape the cache directory and overwrite arbitrary files on the machine running docker compose, even if the user only runs read‑only commands such as docker compose config or docker compose ps. This issue is fixed in v2.40.2.

Am I affected?

ProductAffected versions (from the sources)Fixed in
composeNiche< 2.40.22.40.2

What to do

Update to a fixed version: 2.40.2.

Why this score

FactorValueEvidence×
ImpactFull compromiseCode execution or full control of the system or applicationFrom the CVSS vector1.00
Attacker positionInternetAnyone on the Internet can reach a typical deploymentFrom the CVSS vector1.00
Privileges neededNoneNo accountFrom the CVSS vector1.00
Victim interactionRoutineA normal action: open a file, visit a page, click a linkFrom the CVSS vector0.70
ConfigurationUncommonNeeds a non-default feature that a minority enablesFrom the CVSS vector0.45
ReliabilityReliableDeterministic: injection, logic bug, path traversalFrom the CVSS vector1.00

Threat level T2: Likely to be exploited (× 0.90)

EPSS probability at least 0.10, or EPSS percentile at least 0.95

EPSS 16.5% chance of exploitation in 30 days (percentile 97), as of 2026-12-02.

The arithmetic
  1. Prerequisites multiplied together0.315
  2. Threat T2: Likely to be exploited0.900
  3. 10 × impact 1 × prerequisites 0.315 × threat 0.92.835
  4. Rounded to one decimal between 0.1 and 102.8

How the score works

Exploitation and evidence timeline

  1. 27 Oct 2025 Published
  2. 3 Dec 2026 Risk 2.8 (cvss fallback)

Weakness

CWE-22

References

Get alerts for compose

Free email or text alerts when a vulnerability in compose reaches risk 8 or higher. Nothing else.