CVE-2022-30595
libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files.
02 / AFFECTED SOFTWARE
Affected packages
1 explicit affected versions
1 explicit affected versions
1 explicit affected versions
03 / CONNECTIONS
Connected vulnerabilities
04 / EVIDENCE
Source records
libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files.
libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files.
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 instead, in turn raising a PIL.UnidentifiedImageError.
libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files.
05 / REFERENCES
Further evidence
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/30xxx/CVE-2022-30595.json
- https://github.com/python-pillow/Pillow/blob/main/src/libImaging/TgaRleDecode.c
- https://nvd.nist.gov/vuln/detail/CVE-2022-30595
- https://pillow.readthedocs.io/en/stable/releasenotes/9.1.1.html
- https://github.com/pypa/advisory-database/tree/main/vulns/pillow/PYSEC-2022-43145.yaml
- https://github.com/python-pillow/Pillow
- https://github.com/python-pillow/Pillow/commit/c846cc881ebe34e3518412c2e3636433d9947280