malcontent vulnerable to symlink Path Traversal via handleSymlink argument confusion in archive extractionGHSA-923j-vrcg-hxwh
MEDIUMFix: chainguard-dev/malcontent@259fca5GHSA-923j-vrcg-hxwh is a medium-severity (CVSS 5.5) Path Traversal vulnerability in github.com/chainguard-dev/malcontent. A fix is available for github.com/chainguard-dev/malcontent — see the affected versions and patch details below.
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for GHSA-923j-vrcg-hxwh.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
github.com/chainguard-dev/malcontentReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Go packages — download data is not available via public APIs for these ecosystems.
Description
malcontent could be made to create symlinks outside the intended extraction directory when scanning a specially crafted tar or deb archive. The handleSymlink function received arguments in the wrong order, causing the symlink target to be used as the symlink location. Additionally, symlink targets were not validated to ensure they resolved within the extraction directory.
Fixes:
- Swap handleSymlink arguments; validate symlink location
- Validate symlink targets resolve within extraction directory
Acknowledgements
Thank you to Oleh Konko from 1seal for discovering and reporting this issue.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐹Go | github.com/chainguard-dev/malcontent | ≥ 1.8.0&&< 1.20.3 | 1.20.3go get github.com/chainguard-dev/malcontent@v1.20.3 |
Affected Products
malcontentchainguardDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for github.com/chainguard-dev/malcontent, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update github.com/chainguard-dev/malcontent to 1.20.3 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-923j-vrcg-hxwh is resolved across your whole dependency graph.
Workarounds
Resolve every user-supplied path to its canonical form and reject anything that escapes the intended directory, and run the component under an account that has no read or write access outside the directory it legitimately serves.
Frequently Asked Questions
Is GHSA-923j-vrcg-hxwh in your dependencies?
Find it across Go, including transitive dependencies.