cve.bz

CVE-2026-5342 libraw libraw: Out-of-bounds Read

5.5 mediumExploit referenceEPSS 0.8%Fix available

Medium (5.5) in libraw libraw. EPSS 0.8% estimated probability of exploitation activity in the next 30 days.

On this page
A flaw has been found in LibRaw up to 0.22.0. This affects the function LibRaw::nikon_load_padded_packed_raw of the file src/decoders/decoders_libraw.cpp of the component TIFF/NEF. Executing a manipulation of the argument load_flags/raw_width can lead to out-of-bounds read. It is possible to launch the attack remotely. The exploit has been published and may be used. Upgrading to version 0.22.1 mitigates this issue. This patch is called b8397cd45657b84e88bd1202528d1764265f185c. It is advisable to upgrade the affected component.

Severity

CVSS 4.0

5.5 medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:P

CVSS 3.1

5.3 medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
EPSS
0.8% (unchanged from 0.8% a week ago; 1.0% 30 days ago) estimated probability of exploitation activity in the next 30 days; 57th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: PoC · Automatable: yes · Technical impact: partial, assessed 2026-04-03. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWEs
CWE-119 Improper Restriction of Operations within the Bounds of a Memory Buffer
CWE-125 Out-of-bounds Read
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2026-5342 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-5342?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-5342?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-5342 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
libraw:librawbefore 0.22.1

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian11libraw0.20.2-1+deb11u3DLA-4704-1
Debian12libraw0.20.2-2.1+deb12u2DEBIAN-CVE-2026-5342 DLA-4704-1
Debian13libraw0.21.4-2+deb13u1DEBIAN-CVE-2026-5342
Debian14libraw0.22.1-1DEBIAN-CVE-2026-5342
Ubuntu16.04:LTS, 18.04:LTSkodi, dcraw, ufraw and 3 moreno fix listedUBUNTU-CVE-2026-5342
Ubuntu20.04:LTS, 22.04:LTSkodi, dcraw, darktable and 2 moreno fix listedUBUNTU-CVE-2026-5342
Ubuntu22.04:LTSlibraw0.20.2-2ubuntu2.22.04.3UBUNTU-CVE-2026-5342 USN-8522-1
Ubuntu24.04:LTSlibraw0.21.2-2.1ubuntu0.24.04.2UBUNTU-CVE-2026-5342 USN-8522-1
Ubuntu24.04:LTS, 26.04:LTS, 26.10kodi, dcraw, digikam and 3 moreno fix listedUBUNTU-CVE-2026-5342
Ubuntu25.10kodi, dcraw, libraw and 4 moreno fix listedUBUNTU-CVE-2026-5342
Ubuntu26.04:LTSlibraw0.21.5b-1ubuntu1.1UBUNTU-CVE-2026-5342 USN-8522-1
UbuntuPro:16.04:LTS, Pro:18.04:LTS, Pro:20.04:LTS and 1 moredigikamno fix listedUBUNTU-CVE-2026-5342
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSS, Linux Enterprise High Performance Computing 15 SP5-ESPOS and 5 morelibraw0.20.2-150400.3.21.1SUSE-SU-2026:1556-1
SUSELinux Enterprise Module for Desktop Applications 15 SP7, Linux Enterprise Module for Package Hub 15 SP7, Linux Enterprise Server 15 SP6-LTSS and 2 morelibraw0.21.1-150600.3.10.1SUSE-SU-2026:1555-1
openSUSELeap 16.0libraw0.21.4-160000.3.1openSUSE-SU-2026:20574-1
openSUSETumbleweedlibraw0.22.1-1.1openSUSE-SU-2026:10565-1
Azure Linux3LibRawno fix listedAZL-82940

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; SUSE security data, CC BY 4.0; Microsoft's Azure Linux vulnerability data, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · SUSE · openSUSE.

Red Hat

Red Hat rates this Moderate.

Red Hat's statement

Moderate impact. A flaw in LibRaw allows a remote attacker to trigger an out-of-bounds read by manipulating `load_flags` or `raw_width` arguments when processing specially crafted raw image files. This can lead to application instability or a denial of service. Red Hat products utilizing LibRaw to process untrusted raw image files are affected.

Red Hat's mitigation

To mitigate this issue, avoid processing untrusted or maliciously crafted Nikon raw image files with applications that use LibRaw. This operational control prevents the exploitation of the out-of-bounds read vulnerability by limiting exposure to potentially harmful input.

ProductPackageStateAdvisory
Red Hat Enterprise Linux 6libraw1394Out of support scope
Red Hat Enterprise Linux 7LibRawFix deferred
Red Hat Enterprise Linux 7libraw1394Fix deferred
Red Hat Enterprise Linux 8LibRawFix deferred
Red Hat Enterprise Linux 8libraw1394Fix deferred
Red Hat Enterprise Linux 9LibRawFix deferred

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-5342.

Attack patterns (CAPEC)

  • CAPEC-540 Overread Buffers Likelihood: Low · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits. More on the page of CWE-119 (12).

References

Check your stackJSON