You are viewing this page in an unauthorized frame window.
This is a potential security issue, you are being redirected to
https://nvd.nist.gov
An official website of the United States government
Official websites use .gov
A .gov website belongs to an official government organization in the United States.
Secure .gov websites use HTTPS
A lock () or https:// means you've safely connected to the .gov website. Share sensitive information only on official, secure websites.
This CVE record is not being prioritized for NVD enrichment efforts due to resource or other concerns.
Description
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.
Metrics
NVD enrichment efforts reference publicly available information to associate
vector strings. CVSS information contributed by other sources is also
displayed.
By selecting these links, you will be leaving NIST webspace.
We have provided these links to other web sites because they
may have information that would be of interest to you. No
inferences should be drawn on account of other sites being
referenced, or not, from this page. There may be other web
sites that are more appropriate for your purpose. NIST does
not necessarily endorse the views expressed, or concur with
the facts presented on these sites. Further, NIST does not
endorse any commercial products that may be mentioned on
these sites. Please address comments about this page to [email protected].
Title: libheif de strukturag, Description: libheif es un decodificador y codificador de formato de archivo HEIF y AVIF. Las versiones 1.21.2 e inferiores contienen un desbordamiento de búfer de montón en MaskImageCodec::decode_mask_image(). Al decodificar un archivo HEIF que contiene una imagen de máscara (mski), la función copia los datos completos de la extensión iloc en un búfer de píxeles usando memcpy(dst, data.data(), data.size()). La longitud de copia data.size() está determinada por la extensión iloc en el archivo (controlada por el atacante), mientras que el búfer de destino se dimensiona en función de las dimensiones de imagen declaradas. Debido a que no existe una comprobación de límite superior en la longitud de los datos, un archivo manipulado cuya extensión iloc excede la asignación del búfer de píxeles desborda el montón. Se alcanza la rama vulnerable de single-memcpy cuando la propiedad mskC especifica bits_per_pixel = 8 y la propiedad ispe declara un ancho par ? 64 (de modo que stride == width), sin necesidad de cambios en los límites de seguridad predeterminados o plugins de códec externos. Este problema ha sido solucionado en la versión 1.22.0.
CVE Modified by redhat-SADP7/14/2026 10:20:00 PM
Action
Type
Old Value
New Value
Changed
Affected
[{"vendor":"Red Hat","product":"Red Hat Enterprise Linux 10","defaultStatus":"unaffected","cpes":["cpe:/o:redhat:enterprise_linux:10"]}]
[{"vendor":"Red Hat","product":"Red Hat Enterprise Linux 10","defaultStatus":"unaffected","collectionURL":"https://access.redhat.com/downloads/content/package-browser/","packageName":"glycin-loaders","cpes":["cpe:/o:redhat:enterprise_linux:10"]}]
New CVE Received from GitHub, Inc.5/19/2026 5:16:42 PM
Action
Type
Old Value
New Value
Added
Description
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.