CVE-2020-11538: Pillow - Out-of-Bounds Read in SGI Image Parsing

pillow Updated 02 Oct 2025

Summary

25/06/2020
Yes i
Critical
8.1

CVE-2020-11538: In libImaging/SgiRleDecode.c in Pillow through 7.0.0, a number of out-of-bounds reads exist in the parsing of SGI image files, a different issue than CVE-2020-5311. Affects pillow versions < 7.1.0. Fixed in 7.1.0. How to fix ↓

Also tracked for

The same CVE-2020-11538 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

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

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Pillow is a popular Python imaging library that provides support for opening, manipulating, and saving many different image file formats. It is widely used in various applications for image processing and manipulation. However, a vulnerability has been discovered in the SGI image file parsing functionality of Pillow.

Vulnerability Detail

The vulnerability, identified as CVE-2020-11538, exists in the libImaging/SgiRleDecode.c file of Pillow through version 7.0.0. It is distinct from CVE-2020-5311. The issue involves multiple out-of-bounds reads during the parsing of SGI image files. This vulnerability could potentially be exploited by an attacker to read sensitive information from the memory or cause a denial-of-service condition.

How To Fix

Latest published version: 13.0.0 as of 22 Oct 2026

pip install --upgrade "pillow==13.0.0"

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

If you need the minimum change

7.1.0

This is the first release that contains the fix.

pip install --upgrade "pillow==7.1.0"

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

Workaround

There is no known workaround for this vulnerability. It is strongly advised to update to the latest version of Pillow.

Conclusion

In conclusion, the vulnerability (CVE-2020-11538) in Pillow's SGI image file parsing functionality can lead to out-of-bounds reads, potentially resulting in information disclosure or denial-of-service. It is crucial to update to Pillow version 7.1.0 or later to mitigate this vulnerability. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for pillow →

Share this vulnerability

FAQ

Pillow is a Python imaging library that provides support for opening, manipulating, and saving various image file formats.

This vulnerability could allow an attacker to read sensitive information from the memory or cause a denial-of-service condition.

Yes, upgrading to Pillow version 7.1.0 or later will fix this vulnerability.

No, there are no known workarounds. It is recommended to update to the latest version of Pillow.

You can find more information about this vulnerability in the official advisory database for Pillow: https://github.com/pypa/advisory-database/blob/main/vulns/pillow/PYSEC-2020-80.yaml

Related vulnerabilities

Recent vulnerabilities recorded for pillow.

How To Fix

Latest published version: 13.0.0 as of 22 Oct 2026

pip install --upgrade "pillow==13.0.0"

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

If you need the minimum change

7.1.0

This is the first release that contains the fix.

pip install --upgrade "pillow==7.1.0"

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