Privilege Escalation Vulnerability in Docker Compose by Docker
CVE-2025-62725

8.9HIGH

Key Information:

Vendor

Docker

Status
Vendor
CVE Published:
27 October 2025

What is CVE-2025-62725?

Docker Compose contains a vulnerability that allows attackers to manipulate the path information of remote OCI compose artifacts. Through this exploit, an attacker can use specific annotations (com.docker.compose.extends or com.docker.compose.envfile) to inject values that will be concatenated with the local cache directory. This can lead to unauthorized file overwrites on the host machine, even when executing commands that are considered read-only, such as docker compose config or docker compose ps. As a result, all environments utilizing Docker Compose, including Docker Desktop, CI/CD pipelines, and cloud development setups, are at risk of this vulnerability. The issue has been addressed in version 2.40.2.

Affected Version(s)

compose < 2.40.2

References

CVSS V4

Score:
8.9
Severity:
HIGH
Confidentiality:
High
Integrity:
High
Availability:
High
Attack Vector:
Network
Attack Complexity:
Low
Attack Required:
Physical
Privileges Required:
Undefined
User Interaction:
Unknown

Timeline

  • Vulnerability published

  • Vulnerability Reserved

.
CVE-2025-62725 : Privilege Escalation Vulnerability in Docker Compose by Docker