# CVE-2026-112402: Pillow: Double free in ImagingScaleAffine on calloc failure via Image.transform

- Priority: **Prioritise**
- Reason: Public exploit (GitHub, Date unknown)
- Next step: Check applicability: affected before 13.0.0 (CNA); fix release not confirmed
- Status: published
- Published: 2026-10-19 · Modified: 2026-10-19
- Aliases: DEBIAN-CVE-2026-112402, GHSA-7mwm-ghpf-9vrm, CGA-3hpg-vp9q-chx5, CGA-cq78-5h3m-j9rj, CGA-m632-f63f-wjcr, CGA-x58g-jgcq-5f5r, CGA-8rxm-px6x-97q6, CGA-p877-3jrp-5h75, CGA-pwgh-ph4f-c2pf, CGA-xvmq-w5rr-gvpv, CGA-24pg-4c6g-jwvx, CGA-4qcg-8v9h-p3r3, CGA-8hf2-5x88-48h6, CGA-9633-443v-r927, CGA-9696-p32w-66g3, CGA-c49f-5r73-jrqh, CGA-cww9-5j2c-q52j, CGA-cxq3-5f7r-7rfp, CGA-g8x2-7wrv-558v, CGA-gcj5-xj6h-3h8g, CGA-ghwc-qqm7-mf33, CGA-hq7h-547j-88x7, CGA-r8q5-3r62-rr95, CGA-rg7c-792g-cx4f, CGA-vc5q-qg7j-vv37, CGA-vxgm-5h3w-2qg7, CGA-25g3-8w8f-p658, CGA-589c-v5pg-mwj2, CGA-3w4f-76jv-9w4m, CGA-56xg-8m6w-j838, CGA-6x97-r9h9-75xf, CGA-9mv2-5v47-h4m3, CGA-jj8r-j664-jrj2, CGA-jr3w-f479-wxw9, CGA-mqmg-f566-5ww8, CGA-rqv5-xp7q-97p3, CGA-3f84-g44x-x5fh, UBUNTU-CVE-2026-112402, CGA-7256-ph3r-hwcq, CGA-f5hq-97ph-66pg, CGA-v4qj-vmjr-55qj, CGA-w944-x8gm-5cch, CGA-x387-qqqc-crh5, CGA-xgqp-4fgm-xwhv, BIT-pillow-2026-112402, CGA-72r3-74mx-h7rp, CGA-wgc7-xmmv-597v, PYSEC-2026-4331, USN-9064-2
- Record: https://cvemate.com/vulnerability/CVE-2026-112402 · JSON: https://cvemate.com/vulnerability/CVE-2026-112402/json

## Description

```text
Pillow is a Python imaging library. Prior to 13.0.0, Pillow can double free image memory when ImagingScaleAffine encounters a selective allocation failure. The affected fast path handles Transform.EXTENT or pure scale-and-translate Transform.AFFINE operations with the default NEAREST resampling. The output image allocation must succeed while the additional per-column lookup allocation fails, after which the error path deletes image storage that later cleanup releases again. An attacker who can drive such a large Image.transform() operation under memory pressure may trigger the failure. This can crash the process and may corrupt memory. This issue is fixed in version 13.0.0.
```

## Signals

- CVSS: 8.7 high (v4.0, CVE.org) CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
- EPSS: 0.594%, percentile 49.86%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 1 (github)

## Affected (first 20 of 37)

- chainguard apache-beam-python-3.12-sdk (Chainguard): All versions (No fix recorded) \| \< 2.77.0-r5
- chainguard mlflow (Chainguard): All versions (No fix recorded) \| \< 3.17.2-r2
- chainguard mlflow-fips (Chainguard): All versions (No fix recorded) \| \< 3.17.2-r3
- chainguard nemo-gym (Chainguard): All versions (No fix recorded) \| \< 0.5.0\_rc0\_git20260729-r6
- chainguard nemo-rl-cuda-13.0 (Chainguard): All versions (No fix recorded)
- chainguard nemo-rl-cuda-13.0-automodel (Chainguard): \< 0.7.0-r11
- chainguard nemo-rl-cuda-13.0-mcore (Chainguard): All versions (No fix recorded) \| \< 0.7.0-r11
- chainguard nemo-rl-cuda-13.0-sglang (Chainguard): \< 0.7.0-r11
- chainguard nemo-rl-cuda-13.0-vllm (Chainguard): All versions (No fix recorded)
- chainguard nemo-skills (Chainguard): \< 0.7.0\_git20260911-r5
- chainguard open-webui (Chainguard): \< 0.12.3-r6 \| All versions (No fix recorded)
- chainguard openstack-horizon-2025.2 (Chainguard): All versions (No fix recorded) \| \< 25.5.2\_git20260914-r12
- chainguard py3.10-pillow (Chainguard): All versions (No fix recorded)
- chainguard py3.10-pytorch-cuda-12.6 (Chainguard): All versions (No fix recorded)
- chainguard py3.10-pytorch-cuda-13.0 (Chainguard): All versions (No fix recorded)
- chainguard py3.10-pytorch-cuda-13.2 (Chainguard): All versions (No fix recorded)
- chainguard py3.10-vllm-cuda-12.4 (Chainguard): All versions (No fix recorded)
- chainguard py3.11-pillow (Chainguard): All versions (No fix recorded) \| \< 13.0.0-r0
- chainguard py3.11-pytorch-cuda-13.0 (Chainguard): All versions (No fix recorded) \| \< 2.14.1-r2
- chainguard py3.12-pillow (Chainguard): \< 13.0.0-r0

## References

- <https://github.com/python-pillow/Pillow/security/advisories/GHSA-7mwm-ghpf-9vrm>
- <https://github.com/python-pillow/Pillow/commit/aafa6c75f7cdabb9f409a8aac7c780bea31d08d9>
- <https://github.com/python-pillow/Pillow/releases/tag/13.0.0>
- <https://security-tracker.debian.org/tracker/CVE-2026-112402>
- <https://nvd.nist.gov/vuln/detail/CVE-2026-112402>
- <https://github.com/python-pillow/Pillow>
- <https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/112xxx/CVE-2026-112402.json>
- <https://ubuntu.com/security/CVE-2026-112402>
- <https://www.cve.org/CVERecord?id=CVE-2026-112402>
- <https://ubuntu.com/security/notices/USN-9064-1>
- <https://ubuntu.com/security/notices/USN-9064-2>
- <https://launchpad.net/bugs/2174424>

---

Data as of 2026-12-05T04:20:22.166Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
