CVE-2026-24843: melange QEMU runner could write files outside workspace directory
An attacker who can influence the tar stream from a QEMU guest VM could write files outside the intended workspace directory on the host. The retrieveWorkspace function extracts tar entries without validating that paths stay within the workspace, allowing Path Traversal via ../ sequences.
Fix: Fixed in 6e243d0d. Merged in release.
Acknowledgements
melange thanks Oleh Konko from 1seal for discovering and reporting this issue.
Other sources
melange allows users to build apk packages using declarative pipelines. In version 0.11.3 to before 0.40.3, an attacker who can influence the tar stream from a QEMU guest VM could write files outside the intended workspace directory on the host. The retrieveWorkspace function extracts tar entries without validating that paths stay within the workspace, allowing path traversal via ../ sequences. This issue has been patched in version 0.40.3.
— MITRE
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2026-24843?
The severity of CVE-2026-24843 is categorized as high due to the potential for unauthorized file writes on the host.
How can I fix CVE-2026-24843?
To fix CVE-2026-24843, upgrade the melange package to version 0.40.3 or later.
Who is affected by CVE-2026-24843?
Users of the melange package versions between 0.11.3 and 0.40.3 are affected by CVE-2026-24843.
What type of attack does CVE-2026-24843 enable?
CVE-2026-24843 enables an attacker to write files to arbitrary locations on the host system from a compromised QEMU guest VM.
What function in melange is associated with CVE-2026-24843?
The `retrieveWorkspace` function in melange is associated with CVE-2026-24843, as it does not properly validate file paths during tar extraction.