GHSA-7gcp-w6ww-2xv9
HIGHGHSA-7gcp-w6ww-2xv9 is a high-severity (CVSS 8.2) Path Traversal vulnerability in github.com/sylabs/singularity. O3 Security confirms whether GHSA-7gcp-w6ww-2xv9 is actually reachable in your code before you act, and blocks exploitation at runtime until you patch.
Path traversal and files overwrite with unsquashfs in singularity
Blast Radius
github.com/sylabs/singularityReal-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
Impact
Due to insecure handling of path traversal and the lack of path sanitization within unsquashfs (a distribution provided utility used by Singularity), it is possible to overwrite/create any files on the host filesystem during the extraction of a crafted squashfs filesystem.
Squashfs extraction occurs automatically for unprivileged execution of Singularity (either --without-suid installation or with allow setuid = no) when a user attempts to run an image which:
- is a local SIF image or a single file containing a squashfs filesystem
- is pulled from remote sources
library://orshub://
Image build is also impacted in a more serious way as it is often performed by the root user, allowing an attacker to overwrite/create files leading to a system compromise. Bootstrap methods library, shub and localimage trigger a squashfs extraction.
Patches
This issue is addressed in Singularity 3.6.4.
All users are advised to upgrade to 3.6.4 especially if they use Singularity mainly for building image as root user.
Workarounds
There is no solid workaround except to temporarily avoid use of unprivileged mode with single file images, in favor of sandbox images instead. Regarding image build, temporarily avoid building from library and shub sources, and as much as possible use --fakeroot or a VM to limit potential impact.
For more information
General questions about the impact of the advisory / changes made in the 3.6.0 release can be asked in the:
Any sensitive security concerns should be directed to: [email protected]
See our Security Policy here: https://sylabs.io/security-policy
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐹Go | github.com/sylabs/singularity | ≥ 3.1.1&&< 3.6.4 | 3.6.4 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for github.com/sylabs/singularity. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.
Fix
Update github.com/sylabs/singularity to 3.6.4 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-7gcp-w6ww-2xv9 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 pinpoints whether GHSA-7gcp-w6ww-2xv9 is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.
Tailored to GHSA-7gcp-w6ww-2xv9. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-7gcp-w6ww-2xv9 in your dependencies?
O3 detects GHSA-7gcp-w6ww-2xv9 across Go dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.