Impact
A path traversal flaw in the melange build engine permits an attacker who can supply the input tar stream from a QEMU guest to write arbitrary files outside the intended workspace directory on the host. The flaw lies in the retrieveWorkspace routine, which extracts tar entries without validating that the paths remain within the workspace, thus enabling '../' sequences to escape the intended path. The vulnerability is classified as CWE‑22, indicating improper handling of file paths. An attacker could place malicious payloads or overwrite critical files on the host, potentially escalating privileges or compromising system integrity.
Affected Systems
Chainguard melange versions between 0.11.3 (inclusive) and 0.40.2 (inclusive) are affected. Version 0.40.3 and later contain a patch that validates tar entry paths to prevent out‑of‑directory writes.
Risk and Exploitability
The CVSS score of 8.2 indicates a high severity vulnerability. The EPSS score of less than 1% suggests that, at present, the probability of exploitation is very low and no widespread exploitation has been observed. The vulnerability is not listed in the CISA KEV catalog. Attackers can exploit this issue from a position that can influence the tar stream sent by the QEMU guest, which may be a local or privileged attacker with control over the build environment. The path traversal flaw allows them to write arbitrary files, leading to potential compromise of host system integrity.
OpenCVE Enrichment
Github GHSA