PyPi: Pillow

CVE-2022-30595

Safety vulnerability ID: 67137

This vulnerability was reviewed by experts

The information on this page was manually curated by our Cybersecurity Intelligence Team.

Created at May 25, 2022 Updated at Apr 02, 2024
Scan your Python projects for vulnerabilities →

Advisory

Pillow 9.1.1 addresses the CVE-2022-30595: libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files.

Affected package

pillow

Latest version: 10.3.0

Python Imaging Library (Fork)

Affected versions

Fixed versions

Vulnerability changelog

This release addresses several security problems.

[CVE-2022-30595](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-30595): When reading a TGA file with RLE packets that cross scan lines, Pillow reads the information past the end of the first line without deducting that from the length of the remaining file data. This vulnerability was introduced in Pillow 9.1.0, and can cause a heap buffer overflow.

Opening an image with a zero or negative height has been found to bypass a decompression bomb check. This will now raise a [`SyntaxError`](https://docs.python.org/3/library/exceptions.html#SyntaxError) instead, in turn raising a `PIL.UnidentifiedImageError`.

Resources

Use this package?

Scan your Python project for dependency vulnerabilities in two minutes

Scan your application

Severity Details

CVSS Base Score

CRITICAL 9.8

CVSS v3 Details

CRITICAL 9.8
Attack Vector (AV)
NETWORK
Attack Complexity (AC)
LOW
Privileges Required (PR)
NONE
User Interaction (UI)
NONE
Scope (S)
UNCHANGED
Confidentiality Impact (C)
HIGH
Integrity Impact (I)
HIGH
Availability Availability (A)
HIGH

CVSS v2 Details

HIGH 7.5
Access Vector (AV)
NETWORK
Access Complexity (AC)
LOW
Authentication (Au)
NONE
Confidentiality Impact (C)
PARTIAL
Integrity Impact (I)
PARTIAL
Availability Impact (A)
PARTIAL