Home / LibRaw / LibRaw / CVE-2018-5804
CVE-2018-5804: is it exploited, and which versions of LibRaw are affected and fixed?
CVE-2018-5804 is a divide by zero vulnerability in LibRaw. It is not known to be exploited: it is not in CISA's Known Exploited Vulnerabilities catalog (catalog 2026.11.30, read December 3, 2026, 07:08 UTC). Affected: LibRaw Prior to 0.18.8 (CVE record by flexera). Fixed in 0.18.8 (NVD). Severity: Medium (6.5, CVSS 3.0, from NVD).
Data checked December 3, 2026: last read CISA KEV December 3, 2026, 07:08 UTC, CVE record November 19, 2026, 07:17 UTC and NVD November 19, 2026, 08:27 UTC.
What is CVE-2018-5804?
A type confusion error within the "identify()" function (internal/dcraw_common.cpp) in LibRaw versions prior to 0.18.8 can be exploited to trigger a division by zero.
From the CVE record by flexera, last updated August 5, 2024, 05:47 UTC.
Which versions are affected, and which fix it?
| Vendor | Product | Affected | Fixed or not affected from |
|---|---|---|---|
| LibRaw | Prior to 0.18.8 |
As the CVE record by flexera states it, last updated August 5, 2024. Version ranges are the CNA's; a version the record calls not affected is usually the fix.
Which products and versions does the NVD list as affected?
| Vendor | Product | Versions | Type |
|---|---|---|---|
| libraw | libraw | before 0.18.8 | application |
NVD analysis (status Modified), last modified June 17, 2026, 02:00 UTC.
How severe is CVE-2018-5804?
| Score | Version | Vector | Source |
|---|---|---|---|
| Medium 6.5 | CVSS 3.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H | NVD |
| Medium 4.3 | CVSS 2.0 | AV:N/AC:M/Au:N/C:N/I:N/A:P | NVD |
Each score is shown as its source gave it: the CNA that wrote the record, CISA's ADP (vulnrichment) and the NVD. They can differ.
What the ratings mean: in CVSS 3 and 4, scores run from 0 to 10, with Low 0.1 to 3.9, Medium 4.0 to 6.9, High 7.0 to 8.9 and Critical 9.0 to 10.0. CVSS 2 has no Critical band: its High runs from 7.0 to 10.0. The vector lists how the flaw is reached (network, local), what an attacker needs (privileges, a user's click) and what it can harm.
Is CVE-2018-5804 exploited in the wild?
- CISA KEV
- Not listed (catalog 2026.11.30)
- EPSS
- 1.68% probability of exploitation activity in the next 30 days, percentile 77.6 (FIRST EPSS, scores of December 2, 2026)
What kind of flaw is it?
Where are the vendor advisories and references?
- 81000 third-party-advisory, x_refsource_SECUNIA
- https://github.com/LibRaw/LibRaw/blob/master/Changelog.txt x_refsource_MISC
- https://github.com/LibRaw/LibRaw/commit/9f26ce37f5be86ea11bfc6831366558650b1f6ff x_refsource_MISC
- https://secuniaresearch.flexerasoftware.com/secunia_research/2018-3/ x_refsource_MISC
When was it published, and where is the official record?
- Reserved
- January 19, 2018
- Published
- December 7, 2018, 22:00 UTC
- CVE record updated
- August 5, 2024, 05:47 UTC by flexera
- NVD
- Modified, last modified June 17, 2026, 02:00 UTC
- Last checked
- CVE list November 19, 2026, 07:17 UTC; NVD November 19, 2026, 08:27 UTC; KEV December 3, 2026, 07:08 UTC; EPSS December 2, 2026
- Official record
- cve.org · NVD
What other CVEs affect LibRaw?
- Nov 23, 2026CVE-2026-135167 LibRaw: out-of-bounds read
- Nov 23, 2026CVE-2026-135176 LibRaw: out-of-bounds write (memory corruption)
- Nov 23, 2026CVE-2026-135177 LibRaw: out-of-bounds read
- Oct 15, 2026CVE-2026-111272 LibRaw: out-of-bounds read
- Apr 7, 2026CVE-2026-20911 LibRaw: incorrect Calculation of Buffer Size
- Apr 7, 2026CVE-2026-21413 LibRaw: improper array index validation
- Apr 7, 2026CVE-2026-20889 LibRaw: integer overflow
- Apr 7, 2026CVE-2026-24660 LibRaw: integer overflow
Questions about CVE-2018-5804
Is CVE-2018-5804 exploited in the wild?
Not as far as CISA knows: it is not in the Known Exploited Vulnerabilities catalog, read December 3, 2026, 07:08 UTC. FIRST's EPSS gives it a 1.68% chance of exploitation activity in the next 30 days (scores of December 2, 2026).
Which versions of LibRaw are affected by CVE-2018-5804?
LibRaw Prior to 0.18.8, per the CVE record by flexera. The tables above give every range the sources list.
Which version fixes CVE-2018-5804?
0.18.8, per the NVD. Check the vendor's advisory before you rely on it.
How severe is CVE-2018-5804?
Medium (6.5, CVSS 3.0, from NVD). The severity table above shows each score with its source.
Where is the official record of CVE-2018-5804?
The CVE Program's record is at cve.org and the NVD's at nvd.nist.gov. For a fix, the vendor's own advisory is the one to follow.