Pillow: Heap over-read in WMF/EMF rendering via 16-bit dimension truncation (Windows builds)
Pillow is a Python imaging library. Prior to 13.0.0 on Windows, src/PIL/WmfImagePlugin.py passes unchecked 32-bit WMF or EMF dimensions to the native drawwmf handler in src/display.c. The handler sizes a DIB allocation from 16-bit-truncated bcWidth and bcHeight fields but copies pixel data using the original full dimensions. A crafted wide, short metafile can pass the pixel-count decompression-bomb check and make the Windows-only renderer read beyond the heap buffer, potentially disclosing memory or crashing the process. This issue is fixed in version 13.0.0.
- Products
- Pillow
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2026-96644
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 23:11 UTC · Revision 2
Source evidence
Pillow: Heap over-read in WMF/EMF rendering via 16-bit dimension truncation (Windows builds)
core-cve · Original sourcePublished 21 Oct 2026, 20:54 UTC
Pillow is a Python imaging library. Prior to 13.0.0 on Windows, src/PIL/WmfImagePlugin.py passes unchecked 32-bit WMF or EMF dimensions to the native drawwmf handler in src/display.c. The handler sizes a DIB allocation from 16-bit-truncated bcWidth and bcHeight fields but copies pixel data using the original full dimensions. A crafted wide, short metafile can pass the pixel-count decompression-bomb check and make the Windows-only renderer read beyond the heap buffer, potentially disclosing memory or crashing the process. This issue is fixed in version 13.0.0.
cve:CVE-2026-96644
Pillow
Fixed versions: Not specified
Complete source record
{
"id": "90af11547389b780cad5abca8e2c367b1ab4c3095996807787ca7884ec26b164",
"url": "https://www.cve.org/CVERecord?id=CVE-2026-96644",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "Pillow: Heap over-read in WMF/EMF rendering via 16-bit dimension truncation (Windows builds)",
"summary": "Pillow is a Python imaging library. Prior to 13.0.0 on Windows, src/PIL/WmfImagePlugin.py passes unchecked 32-bit WMF or EMF dimensions to the native drawwmf handler in src/display.c. The handler sizes a DIB allocation from 16-bit-truncated bcWidth and bcHeight fields but copies pixel data using the original full dimensions. A crafted wide, short metafile can pass the pixel-count decompression-bomb check and make the Windows-only renderer read beyond the heap buffer, potentially disclosing memory or crashing the process. This issue is fixed in version 13.0.0.",
"evidence": "cve:CVE-2026-96644",
"products": [
{
"name": {
"value": "Pillow",
"evidence": "/containers/cna/affected/0/product"
},
"prerequisites": [],
"fixed_versions": [],
"affected_versions": []
}
],
"severity": "high",
"structured": {
"id": "CVE-2026-96644",
"aliases": [
"CVE-2026-96644"
],
"metrics": [
{
"cvssV4_0": {
"version": "4.0",
"baseScore": 7.1,
"attackVector": "NETWORK",
"baseSeverity": "HIGH",
"vectorString": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:N/VA:H/SC:N/SI:N/SA:N",
"userInteraction": "PASSIVE",
"attackComplexity": "LOW",
"attackRequirements": "NONE",
"privilegesRequired": "NONE",
"subIntegrityImpact": "NONE",
"vulnIntegrityImpact": "NONE",
"subAvailabilityImpact": "NONE",
"vulnAvailabilityImpact": "HIGH",
"subConfidentialityImpact": "NONE",
"vulnConfidentialityImpact": "LOW"
}
}
],
"affected": [
{
"vendor": "python-pillow",
"product": "Pillow",
"versions": [
{
"status": "affected",
"version": "< 13.0.0"
}
]
}
],
"modified": "2026-10-28T18:22:38.027Z",
"provider": "cve",
"references": [
"https://github.com/python-pillow/Pillow/security/advisories/GHSA-9v9v-9qvf-h2hj",
"https://github.com/python-pillow/Pillow/pull/10120",
"https://github.com/python-pillow/Pillow/commit/4cf46bee338304c5c8968fd7f132ba0d40c428b7",
"https://github.com/python-pillow/Pillow/releases/tag/13.0.0"
],
"provider_metadata": {
"adp": [
{
"title": "CISA ADP Vulnrichment",
"metrics": [
{
"other": {
"type": "ssvc",
"content": {
"id": "CVE-2026-96644",
"role": "CISA Coordinator",
"options": [
{
"Exploitation": "poc"
},
{
"Automatable": "no"
},
{
"Technical Impact": "partial"
}
],
"version": "2.0.3",
"timestamp": "2026-10-28T18:22:22.322892Z"
}
}
}
],
"references": [
{
"url": "https://github.com/python-pillow/Pillow/security/advisories/GHSA-9v9v-9qvf-h2hj",
"tags": [
"exploit"
]
}
],
"providerMetadata": {
"orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"shortName": "CISA-ADP",
"dateUpdated": "2026-10-28T18:22:38.027Z"
}
}
],
"cna": {
"orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
"shortName": "GitHub_M",
"dateUpdated": "2026-10-21T20:54:43.537Z"
}
}
},
"related_cves": [
{
"value": "CVE-2026-96644",
"evidence": "/cveMetadata/cveId"
}
],
"security_relevant": true,
"severity_evidence": "/containers/cna/metrics"
},
"source_id": "core-cve",
"document_id": 472583,
"published_at": "2026-10-21T20:54:43.537+00:00"
}