CVE-2026-32814: libheif: Uninitialized Heap Memory Information Leak via Failed Grid Tiles

Published May 19, 2026
·
Updated

Last updated 19 June 2026

Other sources

libheif is a HEIF and AVIF file format decoder and encoder. In versions 1.21.2 and prior, when decoding a HEIF grid image with strictdecoding=false (the default), a corrupted tile silently fails to decode and the library returns heiferrorOk with no indication of failure, leading to an uninitialized heap memory information leak. The canvas is allocated via createcloneimageatnewsize() → plane.alloc() → new (std::nothrow) uint8t[allocationsize] which does not zero the memory; only the alpha plane is explicitly initialized via fillplane(), so the Y, Cb, and Cr planes contain whatever was previously at that heap address. The failed tile's region of the canvas is never written. It retains uninitialized heap data that is delivered to the caller as decoded pixel values (4,096 bytes per Y/Cb/Cr plane = 12,288+ bytes total). Any application using libheif to decode grid-based HEIF/AVIF files with default settings is vulnerable: a crafted .heic or .avif file causes 4,096+ bytes of heap memory to appear as pixel values in the decoded image, and the calling application receives heiferrorOk, so it has no indication the output contains heap garbage. In server-side image processing, an uploaded crafted HEIF decoded and re-encoded (e.g., as PNG/JPEG for thumbnails, CDN, social media) can leak cross-user data such as auth tokens, database results, and other users' image data. This issue has been fixed in version 1.22.0.

NVD

Affected Software

2 affected components
libheif libheif<=1.21.2
debian/libheif<=1.11.0-1, <=1.11.0-1+deb11u2, <=1.15.1-1+deb12u1, <=1.19.8-1, <=1.21.2-4

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade libheif to a version that resolves this vulnerability.

    Fixed in 1.22.0
  2. Configuration

    When decoding HEIF grid images, set strict_decoding=true (the issue applies to versions 1.21.2 and prior with strict_decoding=false, the default) so corrupted tiles do not silently fail while returning heif_error_Ok.

    libheif strict_decoding = true
  3. Compensating control

    In server-side image processing, isolate image decoding/re-encoding jobs (for example, run in a sandbox/container with no access to auth tokens, database credentials, or other users’ data) to reduce cross-user data leakage impact when crafted HEIF/AVIF files are processed.

Event History

May 19, 2026
CVE Published
via MITRE·07:49 PM
Data Sourced
via MITRE·07:49 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·09:16 PM
DescriptionSeverityWeakness
Jun 18, 2026
Data Sourced
via Debian·06:48 PM
DescriptionAffected Software
Data Sourced
via Launchpad·06:48 PM
Description
Jun 19, 2026
Data Sourced
via Ubuntu·06:48 PM
RemedyDescriptionSeverityAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-32814?

CVE-2026-32814 has a medium severity rating of 6.5.

2

How do I fix CVE-2026-32814?

To fix CVE-2026-32814, upgrade libheif to version 1.22.0 or later.

3

What is the impact of CVE-2026-32814?

CVE-2026-32814 can lead to an information leak due to uninitialized heap memory when decoding certain HEIF grid images.

4

Which versions of libheif are affected by CVE-2026-32814?

libheif versions 1.21.2 and prior are affected by CVE-2026-32814.

5

What conditions trigger the CVE-2026-32814 vulnerability?

CVE-2026-32814 is triggered when decoding a HEIF grid image with strict_decoding set to false and encountering a corrupted tile.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203