CVE-2021-3762 Path traversal in claircore

Critical 9.8 Published Updated

An attacker can achieve arbitrary file write and potential remote code execution by supplying a crafted container image to the Clair scanner.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2021-3762?

CVE-2021-3762 is a critical path traversal vulnerability in quay/claircore, published on 3 Mar 2022. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

A directory traversal vulnerability was found in the ClairCore engine of Clair. An attacker can exploit this by supplying a crafted container image which, when scanned by Clair, allows for arbitrary file write on the filesystem, potentially allowing for remote code execution.

Weakness: CWE-22

Which versions are affected by CVE-2021-3762?

7 open source packages ship an affected version, including github.com/quay/claircore. It affects 2 products.

PackageAffectedFixed in
github.com/quay/claircore GoAll versions0.4.8
github.com/quay/claircore GoAll versions0.4.8
github.com/quay/claircore GoAll versions1.1.0
github.com/quay/claircore GoFrom 0.5.00.5.5
github.com/quay/claircore GoFrom 0.5.00.5.5
github.com/quay/claircore GoFrom 1.0.01.1.0
1 more packages
github.com/quay/claircore GoFrom 1.0.01.1.0

Products include Redhat Clair, Redhat Quay.

How do I fix CVE-2021-3762?

Upgrade github.com/quay/claircore to a fixed version for your release line: 0.4.8, 1.1.0 or 0.5.5.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2021-3762 being exploited?

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

Sources

Also known as GHSA-mq47-6wwv-v79w, GO-2022-0346.

Is CVE-2021-3762 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free