Vulnerability · Published Jul 1, 2025 · Assigned by GitHub_M
CVE-2025-48379Pillow Vulnerable to Write Buffer Overflow on BCn encoding
High 7.1
In plain English
A high-severity heap buffer overflow in Pillow from python-pillow. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.3% (higher than 26% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Pillow is a Python imaging library. In versions 11.2.0 to before 11.3.0, there is a heap buffer overflow when writing a sufficiently large (>64k encoded with default settings) image in the DDS format due to writing into a buffer without checking for available space. This only affects users who save untrusted data as a compressed DDS image. This issue has been patched in version 11.3.0.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine:v3.23 | py3-pillow | 11.3.0-r0 | ALPINE-CVE-2025-48379 |
| Alpine:v3.24 | py3-pillow | 11.3.0-r0 | ALPINE-CVE-2025-48379 |
| PyPI | pillow | 11.3.0 | GHSA-xg8h-j46f-w952 |
| PyPI | pillow | 11.3.0 | PYSEC-2025-61 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| python-pillow | Pillow | >= 11.2.0, < 11.3.0 |
Weakness: CWE-122 · Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
References
- https://github.com/python-pillow/Pillow/security/advisories/GHSA-xg8h-j46f-w952 x_refsource_CONFIRM
- https://github.com/python-pillow/Pillow/pull/9041 x_refsource_MISC
- https://github.com/python-pillow/Pillow/commit/ef98b3510e3e4f14b547762764813d7e5ca3c5a4 x_refsource_MISC
- https://github.com/python-pillow/Pillow/releases/tag/11.3.0 x_refsource_MISC