# CVE-2022-39237: Digital Signature Hash Algorithms Not Validated in sylabs/sif

> Attackers can bypass digital signature verification in Singularity Image Format libraries by using insecure hash algorithms, compromising image integrity.

- **Severity:** Medium 6.3 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 6 Oct 2022
- **Updated:** 23 Apr 2025
- **Also known as:** CLEANSTART-2024-TO97998, DEBIAN-CVE-2022-39237, GHSA-m5m3-46gj-wch8, GO-2022-1045, UBUNTU-CVE-2022-39237, openSUSE-SU-2024:12389-1

## What is CVE-2022-39237?

CVE-2022-39237 is a medium-severity vulnerability in sylabs sif, published on 6 Oct 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

### Official description

syslabs/sif is the Singularity Image Format (SIF) reference implementation. In versions prior to 2.8.1the `github.com/sylabs/sif/v2/pkg/integrity` package did not verify that the hash algorithm(s) used are cryptographically secure when verifying digital signatures. A patch is available in version >= v2.8.1 of the module. Users are encouraged to upgrade. Users unable to upgrade may independently validate that the hash algorithm(s) used for metadata digest(s) and signature hash are cryptographically secure.

Weakness: CWE-327 (Use of a Broken or Risky Cryptographic Algorithm), CWE-347 (Improper Verification of Cryptographic Signature)

## Which versions are affected by CVE-2022-39237?

3 open source packages ship an affected version, including github.com/sylabs/sif/v2. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `github.com/sylabs/sif/v2` | Go | All versions | 2.8.1 |
| `github.com/sylabs/sif/v2` | Go | All versions | 2.8.1 |
| `github.com/sylabs/sif/v2` | Go | All versions | 2.8.1 |
| `apptainer` | openSUSE:Tumbleweed | All versions | 1.1.2-1.1 |

Products: Sylabs Singularity Image Format.

## How do I fix CVE-2022-39237?

Upgrade github.com/sylabs/sif/v2 to 2.8.1 or later.

## Is CVE-2022-39237 being exploited?

There is no known exploitation of CVE-2022-39237 in the wild and no public exploit code.

## Other vulnerabilities in sylabs sif

- [CVE-2021-29499](https://insights.sbomify.com/CVE-2021-29499/): Predictable SIF UUID Identifiers (high 7.5)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2022-39237 and fix it if it is affected.

What it is: CVE-2022-39237 is a medium-severity vulnerability in sylabs sif, published on 6 Oct 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Exploitation: There is no known exploitation of CVE-2022-39237 in the wild and no public exploit code.

Affected packages and fixed versions:
- github.com/sylabs/sif/v2 (Go): affected all versions; fixed in 2.8.1
- github.com/sylabs/sif/v2 (Go): affected all versions; fixed in 2.8.1
- github.com/sylabs/sif/v2 (Go): affected all versions; fixed in 2.8.1

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2022-39237/ (Markdown: https://insights.sbomify.com/CVE-2022-39237/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2022-39237
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2022-39237
- OSV: https://osv.dev/vulnerability/CVE-2022-39237

---
From sbomify Insights: https://insights.sbomify.com/CVE-2022-39237/
Summaries are generated and may contain mistakes; the official description above is the record.
