CVE-2026-32741
highpriority · track · 0EPSS 0.003 · 28 %ileEURUEPSS · scored 2026-10-27
libheif is a HEIF and AVIF file format decoder and encoder. Versions 1.21.2 and below contain a heap buffer overflow in MaskImageCodec::decode_mask_image(). When decoding a HEIF file containing a mask image (mski), the function copies the full iloc extent data into a pixel buffer using memcpy(dst, data.data(), data.size()). The copy length data.size() is determined by the iloc extent in the file (attacker-controlled), while the destination buffer is sized based on the declared image dimensions. Because no upper-bound check exists on the data length, a crafted file whose iloc extent exceeds the pixel buffer allocation overflows the heap. The vulnerable single-memcpy branch is reached when the mskC property specifies bits_per_pixel = 8 and the ispe property declares an even width ≥ 64 (so that stride == width), with no changes to default security limits or external codec plugins required. This issue has been fixed in version 1.22.0.
cvss
Technical severity, 0–10. One row per scoring source.
base score 0–10 · higher = more severe · hover a vector to decode
ssvc
A stakeholder decision — act, attend, or track — from exploitation and impact.
weaknesses
The CWE weakness classes this flaw belongs to.
affected products (4)
Products and version ranges known to be affected.
also known as (3)
Other names and identifiers for this entity.
sources
Which sources assert this record, and when.
references (10)
External citations — patches, advisories, analysis.
- https://access.redhat.com/security/cve/cve-2026-32741cnnvd
- https://github.com/strukturag/libheif/releasesPatchcnnvd
- https://nvd.nist.gov/vuln/detail/CVE-2026-32741cnnvd
- https://github.com/strukturag/libheif/releases/tag/v1.22.0enisa_euvd
- https://github.com/strukturag/libheif/security/advisories/GHSA-j3w5-7whq-p37qenisa_euvd
- https://access.redhat.com/security/cve/CVE-2026-32741nvd
- https://bugzilla.redhat.com/show_bug.cgi?id=2480002nvd
- https://github.com/strukturag/libheif/releases/tag/v1.22.0nvd
Attackers weaponise vulnerabilities like this against internet-exposed services. See what is exposed on your perimeter with a free passive scan.
Free scan