CVE-2026-41071
Description
libheif is a HEIF and AVIF file format decoder and encoder. In versions 1.21.2 and prior, a crafted HEIF sequence file where the saiz box declares more samples than actually exist in the track's chunk table causes a heap-buffer-overflow (out-of-bounds read) in the SampleAuxInfoReader constructor. The SampleAuxInfoReader constructor iterates over saiz->get_num_samples() samples but doesn't validate that this count is consistent with the number of chunks in the chunks vector. When saiz declares more samples than the chunks cover, the loop increments current_chunk past chunks.size(), causing an out-of-bounds read on the chunks vector. The vulnerability is triggered during file parsing (heif_context_read_from_file) without any additional user interaction. Any application using libheif to open untrusted HEIF files is affected. This issue has been fixed in version 1.22.0.
Weakness
- CWE-125: Out-of-bounds Read
CISA SSVC decision points
| Exploitation | none |
|---|---|
| Automatable | no |
| Technical impact | partial |
| Scored | 2026-05-27 |
Timeline
- 2026-05-22Published by the CNA20:59 UTC
- 2026-05-27CISA SSVC decision recorded5 days after publication
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| struktur libheif | before 1.22.0fixed in 1.22.0 | 1.22.0 |
References
- https://github.com/strukturag/libheif/security/advisories/GHSA-xj92-xjff-h8w3
- https://github.com/strukturag/libheif/releases/tag/v1.22.0
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2026-41071'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2026-41071'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2026-41071'curl 'https://api.contrastcyber.com/cve_products/CVE-2026-41071'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).