Pillow: NULL dereference in ImagingExpand via rank filters on zero-size images
Pillow is a Python imaging library. Prior to 13.0.0, Pillow's rank-based filters can dereference invalid image storage for a zero-size image. ImagingExpand() allocates a non-empty output and then faults while replicating edges by reading the first pixel from empty input storage; ImagingRankFilter is never reached. An attacker can supply or cause creation of a zero-size image to an application that applies a rank, median, minimum, or maximum filter. This causes a native process crash. This issue is fixed in version 13.0.0.
- Products
- pillow
- Affected versions
- Not specified
- Fixed versions
- 13.0.0
- CVEs
- CVE-2026-112392
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 17:55 UTC · Revision 1
Source evidence
Pillow: NULL dereference in ImagingExpand via rank filters on zero-size images
core-osv · Original sourcePublished 26 Oct 2026, 05:55 UTC
Pillow is a Python imaging library. Prior to 13.0.0, Pillow's rank-based filters can dereference invalid image storage for a zero-size image. ImagingExpand() allocates a non-empty output and then faults while replicating edges by reading the first pixel from empty input storage; ImagingRankFilter is never reached. An attacker can supply or cause creation of a zero-size image to an application that applies a rank, median, minimum, or maximum filter. This causes a native process crash. This issue is fixed in version 13.0.0.
osv:BIT-pillow-2026-112392
pillow
Fixed versions: 13.0.0
Complete source record
{
"id": "aeb2fea9bab43f8289c2aa874ecad41765d5c0aa6b28f4eb2d3b3d5316a6613c",
"url": "https://osv.dev/vulnerability/BIT-pillow-2026-112392",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "Pillow: NULL dereference in ImagingExpand via rank filters on zero-size images",
"summary": "Pillow is a Python imaging library. Prior to 13.0.0, Pillow's rank-based filters can dereference invalid image storage for a zero-size image. ImagingExpand() allocates a non-empty output and then faults while replicating edges by reading the first pixel from empty input storage; ImagingRankFilter is never reached. An attacker can supply or cause creation of a zero-size image to an application that applies a rank, median, minimum, or maximum filter. This causes a native process crash. This issue is fixed in version 13.0.0.",
"evidence": "osv:BIT-pillow-2026-112392",
"products": [
{
"name": {
"value": "pillow",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "13.0.0",
"evidence": "/affected/0/ranges"
}
],
"affected_versions": []
}
],
"severity": "high",
"structured": {
"id": "BIT-pillow-2026-112392",
"aliases": [
"BIT-pillow-2026-112392",
"CVE-2026-112392",
"GHSA-27h8-gf7j-v5hc",
"PYSEC-2026-4326"
],
"affected": [
{
"ranges": [
{
"type": "SEMVER",
"events": [
{
"introduced": "0"
},
{
"fixed": "13.0.0"
}
]
}
],
"package": {
"name": "pillow",
"purl": "pkg:bitnami/pillow",
"ecosystem": "Bitnami"
},
"severity": [
{
"type": "CVSS_V4",
"score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X"
}
],
"database_specific": {
"source": "https://github.com/bitnami/vulndb/tree/main/data/pillow/BIT-pillow-2026-112392.json"
}
}
],
"modified": "2026-10-27T11:10:35.409737764Z",
"provider": "osv",
"references": [
"https://github.com/python-pillow/Pillow/commit/443e3130a8c11594fd0e296afad497e11e678961",
"https://github.com/python-pillow/Pillow/releases/tag/13.0.0",
"https://github.com/python-pillow/Pillow/security/advisories/GHSA-27h8-gf7j-v5hc",
"https://nvd.nist.gov/vuln/detail/CVE-2026-112392"
],
"provider_metadata": {
"cpes": [
"cpe:2.3:a:python:pillow:*:*:*:*:*:python:*:*"
],
"severity": "High"
}
},
"related_cves": [
{
"value": "CVE-2026-112392",
"evidence": "/aliases"
}
],
"security_relevant": true,
"severity_evidence": "/database_specific/severity"
},
"source_id": "core-osv",
"document_id": 461506,
"published_at": "2026-10-26T05:55:33.132+00:00"
}