Skip to main content
Vulnerability Database/CVE-2026-84450

CVE-2026-84450: libheif HEIF/AVIF Decoder DOS Vulnerability

CVE-2026-84450 is a denial of service vulnerability in libheif that affects HEIF and AVIF image processing. Attackers can exploit crafted images to cause application crashes or invalid operations. This article covers technical details, affected versions from 1.19.0 to 1.23.2, impact assessment, and mitigation strategies.

Published:

CVE-2026-84450 Overview

CVE-2026-84450 affects libheif, a widely deployed HEIF and AVIF file format decoder and encoder maintained by Struktur AG. Versions from 1.19.0 through 1.23.2 mishandle crafted image items containing a clap (clean aperture) property paired with an ispe width or height greater than INT32_MAX + 1. When such an image reaches crop calculations through heif_image_handle_get_image_tiling(), the Fraction constructor triggers an assertion failure in assert-enabled builds. Release builds compute invalid crop geometry instead. The issue is fixed in version 1.23.3.

Critical Impact

Assert-enabled builds abort on parsing a malicious HEIF/AVIF file, and release builds return invalid crop geometry through the tiling API, enabling denial-of-service against applications that decode untrusted images.

Affected Products

  • libheif 1.19.0 through 1.23.2
  • Applications and services embedding vulnerable libheif builds for HEIF/AVIF decoding
  • Assert-enabled libheif builds are affected by the abort; release builds compute invalid crop geometry

Discovery Timeline

  • 2026-09-18 - CVE-2026-84450 published to NVD
  • 2026-09-21 - Last updated in NVD database

Technical Details for CVE-2026-84450

Vulnerability Analysis

The flaw is a reachable assertion [CWE-617] in the clap (clean aperture) property handling path. libheif exposes crop borders through heif_item_get_property_transform_crop_borders() and through the tiling API via heif_image_handle_get_image_tiling(). Both paths call Box_clap::left_rounded() or Box_clap::top_rounded(), which pass image_width - 1 or image_height - 1 into Fraction::Fraction(uint32_t, uint32_t).

The Fraction constructor validates its input using an assert(). When the ispe box declares a dimension greater than INT32_MAX + 1, the value flowing into Fraction exceeds the supported coordinate range. Assert-enabled builds abort the process. Release builds skip the assertion and continue with invalid crop geometry, and the tiling API returns dimensions that downstream decode security limits later reject.

Root Cause

Input validation for image dimensions relies on a runtime assertion rather than an explicit error return. Attacker-controlled ispe values in an ISOBMFF container reach arithmetic on integer boundaries without a bounds check upstream of Fraction::Fraction(), violating the library's own coordinate range assumptions.

Attack Vector

An attacker crafts a HEIF or AVIF file with an image item that combines a clap property and an ispe box declaring an out-of-range width or height. Delivery requires user interaction, such as opening the file in an image viewer, uploading it to a service that generates thumbnails, or previewing it in a client that links against libheif. Successful triggering aborts assert-enabled builds or produces invalid crop borders in release builds.

c
// Security patch in libheif/api/libheif/heif_properties.cc
// clap: return an error instead of asserting for image sizes outside the Fraction
     return;
   }
 
-  if (left) *left = (*clap)->left_rounded(image_width);
-  if (right) *right = image_width - 1 - (*clap)->right_rounded(image_width);
-  if (top) *top = (*clap)->top_rounded(image_height);
-  if (bottom) *bottom = image_height - 1 - (*clap)->bottom_rounded(image_height);
+  auto crop = (*clap)->get_crop(image_width, image_height);
+  if (!crop) {
+    // The clean aperture cannot be applied to an image of this size (zero size, negative
+    // size, or a size beyond the supported coordinate range). This function has no error
+    // return, so report that nothing is cropped.
+    if (left) *left = 0;
+    if (right) *right = 0;
+    if (top) *top = 0;
+    if (bottom) *bottom = 0;
+    return;
+  }
+
+  if (left) *left = crop->left;
+  if (right) *right = image_width - 1 - crop->right;
+  if (top) *top = crop->top;
+  if (bottom) *bottom = image_height - 1 - crop->bottom;
 }

Source: libheif commit 1c2df9c

Detection Methods for CVE-2026-84450

Indicators of Compromise

  • HEIF or AVIF files containing an ispe box declaring a width or height greater than INT32_MAX + 1 (approximately 0x80000000) combined with a clap property.
  • Unexpected process aborts or SIGABRT crashes in image viewers, thumbnail workers, or upload pipelines that call heif_image_handle_get_image_tiling().
  • Repeated failed decode events tied to a specific attachment or upload path across multiple hosts.

Detection Strategies

  • Inventory software linking against libheif and flag versions between 1.19.0 and 1.23.2 inclusive.
  • Parse ispe and clap boxes at the mail gateway, upload proxy, or content pipeline and reject items where dimensions exceed INT32_MAX.
  • Alert on crash telemetry (Windows Error Reporting, systemd-coredump, macOS CrashReporter) referencing libheif, Box_clap, or Fraction.

Monitoring Recommendations

  • Forward endpoint crash and abort events into a centralized data lake and correlate with recent HEIF or AVIF file activity.
  • Monitor content processing services for spikes in decoder failures originating from a single sender, tenant, or IP range.
  • Track patch state of libheif across container images, base OS packages, and third-party image processing services.

How to Mitigate CVE-2026-84450

Immediate Actions Required

  • Upgrade libheif to version 1.23.3 or later across all endpoints, servers, and container images.
  • Rebuild and redeploy any application statically linked against a vulnerable libheif release.
  • Temporarily restrict HEIF and AVIF processing in exposed upload and preview pipelines until patched.

Patch Information

The issue is fixed in libheif 1.23.3. The upstream patch replaces the direct left_rounded()/top_rounded() calls with get_crop(), which returns an error when the image size is zero, negative, or beyond the supported coordinate range. See the GitHub Security Advisory GHSA-gh5q-69gg-c964 and the libheif v1.23.3 release notes.

Workarounds

  • Pre-filter incoming HEIF/AVIF files and reject any item whose ispe width or height exceeds INT32_MAX.
  • Sandbox image decoders so that an abort in libheif does not disrupt the parent service, and configure automatic worker restarts.
  • Disable HEIF/AVIF handling in optional preview or thumbnail features until the patched library is deployed.
bash
# Verify installed libheif version and confirm the fix is applied
heif-info --version | head -n 1
# Debian/Ubuntu
apt list --installed 2>/dev/null | grep -i libheif
# RHEL/Fedora
rpm -q libheif
# Container image scan example
trivy image --severity MEDIUM,HIGH,CRITICAL --pkg-types library <image>:<tag>

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.