Skip to content
Fencer Intel
high 7.5

CVE-2026-50142 json

libheif: unbounded heap allocation in HEIF sequence parser (stsz fixed-size mode missing bound check)

published 5mo ago modified 20d ago also EUVD-2026-62187 , GHSA-jvmp-j3cw-84mh

Unreviewed: the maintainers' own advisory

Published by the maintainers on their GitHub repository strukturag/libheif. GitHub has not reviewed it into the GitHub Advisory Database, so the affected packages and versions are the maintainers' word. Read the full advisory on GitHub.

cvss
7.5
version 3.1, CNA
cisa kev
Not listed
not in CISA's catalog
epss
0.7%
EPSS 0.7% chance of exploitation in 30 days, percentile 51%
public exploits
0
none known

Summary

libheif is a HEIF and AVIF file format decoder and encoder. From 1.19.0 until 1.23.0, a crafted HEIF sequence accepted by heif_context_read_from_memory() with the msf1 sequence brand can cause unbounded heap allocation. In libheif/sequences/seq_boxes.cc, Box_stsz::parse() applies max_sequence_frames only to variable-size samples, so fixed-size mode accepts an attacker-controlled sample_count without a bound. In libheif/sequences/track.cc, Track::load() also adds current_sample_idx and samples_per_chunk in 32-bit arithmetic, allowing the consistency check to be bypassed by wraparound. The resulting values reach the Chunk::Chunk() allocation path, which can consume gigabytes of memory and crash or stall the process through memory exhaustion. This issue is fixed in version 1.23.0.

Patch / fix

  • struktur libheif 1.23.0
  • libheif Debian 14 1.23.1-1

debian advisories DEBIAN-CVE-2026-50142

  • libheif Ubuntu 25.10 1.20.2-1ubuntu0.6
  • libheif Ubuntu 26.04 LTS 1.21.2-3ubuntu0.3

ubuntu advisories UBUNTU-CVE-2026-50142

Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

  • libheif SLE Module for Package Hub 15 SP7, SLE Module for Desktop Applications 15 SP7 1.23.0-150700.3.15.1
  • libheif SLES for SAP applications 16.0, SLES 16.0 1.23.0-160000.1.1

suse advisories SUSE-SU-2026:2622-1SUSE-SU-2026:22153-1

  • libheif openSUSE Leap 16.0 1.23.0-160000.1.1
  • libheif openSUSE Tumbleweed 1.23.0-2.1

opensuse advisories openSUSE-SU-2026:20974-1openSUSE-SU-2026:10983-1

  • libheif Alpine 3.24, Alpine 3.23 1.23.0-r0

alpine advisories ALPINE-CVE-2026-50142

Alpine secdb © Alpine Linux, from https://secdb.alpinelinux.org via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0

Is CVE-2026-50142 in your stack? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.

Check with Fencer

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2026-50142 updated cvss 7.5

libheif: libheif: Denial of Service via unbounded heap allocation in HEIF sequence parser

  • Red Hat All currently supported Red Hat products
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

CISA SSVC

Exploitation
none
Automatable
yes
Technical impact
partial
Assessed
2mo ago

Exploit prediction

0.66% chance of exploitation in the next 30 days, higher than 51% of all scored CVEs (FIRST EPSS, 2026-11-11).

CVSS scores

assigned by version score vector
CNA 3.1 7.5 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Affected products

  • strukturag libheif

Classification

Weakness
  • CWE-190 Integer Overflow or Wraparound
  • CWE-770 Allocation of Resources Without Limits or Throttling

References

Sources

Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.

The maintainers of strukturag/libheif published their own advisory on GitHub. Reviewed sources take precedence over it.

CPEs and fixed versions use Anchore's correction of NVD's data: Added CPE configurations because not yet analyzed by NVD.