CVE-2020-15229: Path Traversal and Files Overwrite in Singularity

Summary

24/05/2021
Yes i
High
8.2

CVE-2020-15229: Path traversal and files overwrite with unsquashfs in singularity. Affects github.com/sylabs/singularity versions >= 3.1.1, < 3.6.4. Fixed in 3.6.4. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Singularity is an open-source containerization platform that allows users to run applications in isolated environments. It is written in Go and provides a command-line interface for managing containers. Singularity supports the use of squashfs filesystems, which are compressed read-only file systems commonly used in Linux distributions. However, Singularity's handling of path traversal and lack of path sanitization in the unsquashfs utility can lead to the overwrite or creation of arbitrary files on the host filesystem during the extraction of a crafted squashfs filesystem.

Vulnerability Detail

The vulnerability arises from the insecure handling of path traversal and the absence of path sanitization in unsquashfs. This allows an attacker to manipulate the file paths and overwrite or create files on the host filesystem. The impact of this vulnerability is significant as it can lead to a system compromise. It affects both the execution of Singularity images and the image build process, particularly when performed by the root user. Singularity versions 3.1.1 to 3.6.3 are affected.

How To Fix

Latest published version: v3.1.1+incompatible as of 23 Oct 2026

go get github.com/sylabs/singularity@v3.1.1+incompatible

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

3.6.4

This is the first release that contains the fix.

go get github.com/sylabs/singularity@v3.6.4

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

While there is no solid workaround, users can temporarily avoid unprivileged mode with single file images and instead use sandbox images. For image build, it is advised to temporarily avoid building from library and shub sources and, whenever possible, use --fakeroot or a virtual machine to limit the potential impact.

Conclusion

The vulnerability in Singularity allows for path traversal and files overwrite, potentially leading to a system compromise. Users are advised to upgrade to Singularity 3.6.4 and follow the recommended workarounds to minimize the risk. For further support on vulnerability remediation, contact DevNack.com.

See every vulnerability recorded for github.com/sylabs/singularity →

Share this vulnerability

FAQ

Singularity is an open-source containerization platform that allows users to run applications in isolated environments.

A squashfs filesystem is a compressed read-only file system commonly used in Linux distributions.

The vulnerability arises from the insecure handling of path traversal and the lack of path sanitization in the unsquashfs utility.

The vulnerability allows an attacker to overwrite or create arbitrary files on the host filesystem, potentially leading to a system compromise.

The issue has been addressed in Singularity 3.6.4. Users should upgrade to this version to mitigate the vulnerability.

Related vulnerabilities

Recent vulnerabilities recorded for github.com/sylabs/singularity.

How To Fix

Latest published version: v3.1.1+incompatible as of 23 Oct 2026

go get github.com/sylabs/singularity@v3.1.1+incompatible

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

3.6.4

This is the first release that contains the fix.

go get github.com/sylabs/singularity@v3.6.4

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback