CVE-2026-49271: CWE-125: Out-of-bounds Read in strukturag libheif
libheif is a HEIF and AVIF file format decoder and encoder. Prior to version 1.22.1, the uncompressed HEIF decoder validates explicit icef compressed-unit offsets using unit_offset + unit_size. Because the addition can wrap, a crafted HEIF file can pass the range check and then construct a vector from iterators outside the compressed item buffer, producing an out-of-bounds heap read and crash. Version 1.22.1 patches the issue.
AI Analysis
Technical Summary
libheif is a library for decoding and encoding HEIF and AVIF file formats. Versions before 1.22.1 contain a vulnerability where the uncompressed HEIF decoder validates compressed-unit offsets by adding unit_offset and unit_size without proper overflow checks. This addition can wrap around, allowing a crafted HEIF file to bypass range checks and cause the construction of a vector from iterators outside the compressed item buffer. This results in an out-of-bounds heap read and potential crash. The vulnerability is identified as CWE-125 (Out-of-bounds Read) and is addressed in libheif version 1.22.1.
Potential Impact
An attacker can craft a malicious HEIF file that triggers an out-of-bounds heap read in vulnerable versions of libheif. This can lead to application crashes (denial of service). There is no indication of confidentiality or integrity impact. The CVSS 3.1 base score is 6.5 (medium severity) with network attack vector, low attack complexity, no privileges required, user interaction required, unchanged scope, no confidentiality or integrity impact, and high availability impact.
Mitigation Recommendations
Upgrade libheif to version 1.22.1 or later, where this vulnerability is patched. No other mitigation or temporary workaround is indicated. Users should ensure they do not process untrusted HEIF files with vulnerable versions.
CVE-2026-49271: CWE-125: Out-of-bounds Read in strukturag libheif
Description
libheif is a HEIF and AVIF file format decoder and encoder. Prior to version 1.22.1, the uncompressed HEIF decoder validates explicit icef compressed-unit offsets using unit_offset + unit_size. Because the addition can wrap, a crafted HEIF file can pass the range check and then construct a vector from iterators outside the compressed item buffer, producing an out-of-bounds heap read and crash. Version 1.22.1 patches the issue.
CVSS v3.1
Score 6.5medium
Affected software
pkg:github/strukturag/libheifRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
libheif is a library for decoding and encoding HEIF and AVIF file formats. Versions before 1.22.1 contain a vulnerability where the uncompressed HEIF decoder validates compressed-unit offsets by adding unit_offset and unit_size without proper overflow checks. This addition can wrap around, allowing a crafted HEIF file to bypass range checks and cause the construction of a vector from iterators outside the compressed item buffer. This results in an out-of-bounds heap read and potential crash. The vulnerability is identified as CWE-125 (Out-of-bounds Read) and is addressed in libheif version 1.22.1.
Potential Impact
An attacker can craft a malicious HEIF file that triggers an out-of-bounds heap read in vulnerable versions of libheif. This can lead to application crashes (denial of service). There is no indication of confidentiality or integrity impact. The CVSS 3.1 base score is 6.5 (medium severity) with network attack vector, low attack complexity, no privileges required, user interaction required, unchanged scope, no confidentiality or integrity impact, and high availability impact.
Mitigation Recommendations
Upgrade libheif to version 1.22.1 or later, where this vulnerability is patched. No other mitigation or temporary workaround is indicated. Users should ensure they do not process untrusted HEIF files with vulnerable versions.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-28T20:07:58.860Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a358c5cf198dc38c1f2fbc3
Added to database: 06/19/2026, 18:37:16 UTC
Last enriched: 06/19/2026, 18:51:17 UTC
Last updated: 06/20/2026, 23:27:27 UTC
Views: 12
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.