CVE-2026-59198
published 2026-07-14CVE-2026-59198: Pillow is a Python imaging library. From 5.2.0 until 12.3.0, Pillow's TGA RLE encoder reads past its packed row buffer when saving a mode 1 image with TGA RLE…
PriorityP344high7.5CVSS 3.1
AVNACLPRNUINSUCHINAN
EPSS
0.33%
25.0th percentile
Pillow is a Python imaging library. From 5.2.0 until 12.3.0, Pillow's TGA RLE encoder reads past its packed row buffer when saving a mode 1 image with TGA RLE compression, allowing adjacent process heap bytes to be copied into the generated TGA file. This issue is fixed in version 12.3.0.
Affected
81 ranges· showing 25
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| ansible-automation-platform-25 | lightspeed-chatbot-rhel8 | — | — |
| ansible-automation-platform-26 | hub-rhel9 | — | — |
| ansible-automation-platform-26 | lightspeed-chatbot-rhel9 | — | — |
| ansible-automation-platform-27 | hub-rhel9 | — | — |
| ansible-automation-platform-27 | lightspeed-chatbot-rhel9 | — | — |
| ansible-automation-platform | automation-dashboard-rhel9 | — | — |
| exploit-intelligence-tech-preview | vulnerability-analysis-rhel9 | — | — |
| lightspeed-core | lightspeed-stack-rhel9 | — | — |
| lightspeed-core | rag-tool-cpu-rhel9 | — | — |
| lightspeed-core | rag-tool-cuda-12.9-rhel9 | — | — |
| openshift-lightspeed-tech-preview | lightspeed-rag-tool-rhel9 | — | — |
| openshift-lightspeed | lightspeed-ocp-rag-rhel9 | — | — |
| openshift-lightspeed | lightspeed-service-api-rhel9 | — | — |
| python-pillow | pillow | — | — |
| python | pillow | >= 5.2.0 < 12.3.0 | 12.3.0 |
| python | pillow | >= 5.2.0 < 12.3.0 | 12.3.0 |
| quay | quay-rhel8 | — | — |
| quay | quay-rhel9 | — | — |
| rhaii | model-opt-cuda-rhel9 | — | — |
| rhaii | vllm-cpu-rhel9 | — | — |
| rhaii | vllm-cuda-rhel9 | — | — |
| rhaii | vllm-gaudi-rhel9 | — | — |
| rhaii | vllm-neuron-rhel9 | — | — |
| rhaii | vllm-rocm-rhel9 | — | — |
| rhaii | vllm-spyre-rhel9 | — | — |
CVSS provenance
nvdv3.17.5HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
vendor_redhat7.5HIGH
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
Pillow TGA RLE encoder can serialize up to ~57 KB of adjacent heap data into generated images
ghsa·2026-07-20
CVE-2026-59198 [MEDIUM] CWE-125 Pillow TGA RLE encoder can serialize up to ~57 KB of adjacent heap data into generated images
Pillow TGA RLE encoder can serialize up to ~57 KB of adjacent heap data into generated images
### Summary
Pillow's TGA RLE encoder reads past its row buffer when saving a mode `"1"`
image. Adjacent process heap bytes can be copied into the generated TGA file.
The bug is reachable through the public save API:
```python
im.save(out, format="TGA", compression="tga_rle")
```
Older affected Pillow versions use the equivalent public option `rle=True`.
For mode `"1"`, Pillow allocates a packed row buffer of `ceil(width / 8)`
bytes, but `ImagingTgaRleEncode()` treats the row as one full byte per pixel.
The maximum valid TGA width is `65535`. At that width:
```text
allocated packed row buffer: 8192 bytes
encoder byte-offset walk: 65535 bytes
maximum OOB window per row: 57343 bytes
```
On n
Red Hat
Pillow: Pillow: Information disclosure via TGA RLE encoder out-of-bounds read
vendor_redhat·2026-07-14·CVSS 7.5
CVE-2026-59198 [HIGH] CWE-125 Pillow: Pillow: Information disclosure via TGA RLE encoder out-of-bounds read
Pillow: Pillow: Information disclosure via TGA RLE encoder out-of-bounds read
Pillow is a Python imaging library. From 5.2.0 until 12.3.0, Pillow's TGA RLE encoder reads past its packed row buffer when saving a mode 1 image with TGA RLE compression, allowing adjacent process heap bytes to be copied into the generated TGA file. This issue is fixed in version 12.3.0.
A flaw was found in Pillow, a Python imaging library. When saving a mode 1 image with TGA RLE compression, the TGA RLE encoder reads beyond its allocated memory buffer. This out-of-bounds read allows adjacent process heap memory to be copied into the generated TGA file, potentially leading to information disclosure.
Statement: The impact is limited to information disclosure of adjacent heap memory fragments in the generated o
No detection rules found.
No public exploits indexed.
https://github.com/python-pillow/Pillow/commit/eada3cbd7fb9963ee90673fb7b5270124a0d5f4bhttps://github.com/python-pillow/Pillow/pull/9709https://github.com/python-pillow/Pillow/releases/tag/12.3.0https://github.com/python-pillow/Pillow/security/advisories/GHSA-fj7v-r99m-22gqhttps://github.com/python-pillow/Pillow/security/advisories/GHSA-fj7v-r99m-22gq
2026-07-14
Published