CVE-2021-28678 Insufficient Verification of Data Authenticity in Pillow

Medium 5.5 Published Updated

Attackers can cause a denial of service in Pillow by providing malformed BLP image data that triggers excessive processing of empty data.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2021-28678?

CVE-2021-28678 is a medium-severity denial of service vulnerability in Fedoraproject Fedora, published on 2 Jun 2021. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

Official description

An issue was discovered in Pillow before 8.2.0. For BLP data, BlpImagePlugin did not properly check that reads (after jumping to file offsets) returned data. This could lead to a DoS where the decoder could be run a large number of times on empty data.

Weakness: CWE-345

Which versions are affected by CVE-2021-28678?

4 open source packages ship an affected version, including pillow and Pillow. It affects 2 products.

PackageAffectedFixed in
pillow BitnamiAll versions8.2.0
pillow PyPIAll versions8.2.0
pillow PyPIFrom 5.1.08.2.0
Pillow PyPIFrom 5.1.08.2.0

Products include Fedoraproject Fedora, Python Pillow.

How do I fix CVE-2021-28678?

Upgrade pillow to 8.2.0 or later.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is CVE-2021-28678 being exploited?

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

All Fedoraproject Fedora vulnerabilities

Sources

Also known as ALPINE-CVE-2021-28678, BIT-pillow-2021-28678, DEBIAN-CVE-2021-28678, GHSA-hjfx-8p6c-g7gx, PYSEC-2021-94, UBUNTU-CVE-2021-28678.

Is CVE-2021-28678 in your software?

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

Check your SBOMs for free