Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. Pillow
  4. ›
  5. CVE-2021-27921

CVE-2021-27921: Pillow Denial of Service by Uncontrolled Resource Consumption

March 18, 2021 (updated October 8, 2024)

Pillow before 8.1.1 allows attackers to cause a denial of service (memory consumption) because the reported size of a contained image is not properly checked for a BLP container, and thus an attempted memory allocation can be very large.

References

  • github.com/advisories/GHSA-f4w8-cv6p-x6r5
  • github.com/pypa/advisory-database/tree/main/vulns/pillow/PYSEC-2021-40.yaml
  • github.com/python-pillow/Pillow
  • github.com/python-pillow/Pillow/commit/756fff33128a0b643d10518a26ad04b726dd8973
  • lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/S7G44Z33J4BNI2DPDROHWGVG2U7ZH5JU
  • lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/TQQY6472RX4J2SUJENWDZAWKTJJGP2ML
  • lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ZTSY25UJU7NJUFHH3HWT575LT4TDFWBZ
  • nvd.nist.gov/vuln/detail/CVE-2021-27921
  • pillow.readthedocs.io/en/stable/releasenotes/8.1.1.html
  • security.gentoo.org/glsa/202107-33

Code Behaviors & Features

Detect and mitigate CVE-2021-27921 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 8.1.1

Fixed versions

  • 8.1.1

Solution

Upgrade to version 8.1.1 or above.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-400: Uncontrolled Resource Consumption

Source file

pypi/Pillow/CVE-2021-27921.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:16:12 +0000.