CVE-2026-40385
Received Received - Intake
Integer Overflow in libexif Nikon MakerNote Causes Crashes on 32-bit

Publication date: 2026-04-12

Last updated on: 2026-04-14

Assigner: MITRE

Description
In libexif through 0.6.25, an unsigned 32bit integer overflow in Nikon MakerNote handling could be used by local attackers to cause crashes or information leaks. This only affects 32bit systems.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-04-12
Last Modified
2026-04-14
Generated
2026-05-07
AI Q&A
2026-04-12
EPSS Evaluated
2026-05-05
NVD
EUVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
libexif_project libexif to 0.6.25 (inc)
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-190 The product performs a calculation that can produce an integer overflow or wraparound when the logic assumes that the resulting value will always be larger than the original value. This occurs when an integer value is incremented to a value that is too large to store in the associated representation. When this occurs, the value may become a very small or negative number.
Attack-Flow Graph
AI Powered Q&A
How can this vulnerability be detected on my network or system? Can you suggest some commands?

This vulnerability involves an integer overflow in libexif when processing Nikon MakerNote metadata on 32-bit systems, which can cause crashes or information leaks. Detection would involve identifying if your system uses a vulnerable version of libexif (through 0.6.25) on a 32-bit architecture.

Since the issue is triggered by processing specific EXIF data, one approach is to test image files containing Nikon MakerNote metadata and observe if libexif crashes or behaves unexpectedly.

There are no specific commands provided in the resources to detect this vulnerability directly. However, you can check the installed libexif version and system architecture with commands like:

  • Check libexif version: `exif --version` or `dpkg -l | grep libexif` (on Debian-based systems)
  • Check system architecture: `uname -m` (look for 32-bit architectures like i386, i686)

If you have access to source code or binaries, you can verify if the fix (overflow check) is present by reviewing the code around the offset calculation in Nikon MakerNote handling.


What immediate steps should I take to mitigate this vulnerability?

The immediate mitigation step is to update libexif to a version that includes the fix for CVE-2026-40385.

The fix involves adding a check to prevent integer overflow during offset calculations in Nikon MakerNote processing, which avoids out-of-bounds memory access and potential crashes.

If updating is not immediately possible, avoid processing untrusted or suspicious Nikon MakerNote EXIF data on 32-bit systems using libexif.

Additionally, consider running libexif in a restricted environment or sandbox to limit the impact of potential crashes or information leaks.


How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

The provided information does not specify any direct impact of this vulnerability on compliance with common standards and regulations such as GDPR or HIPAA.


Can you explain this vulnerability to me?

CVE-2026-40385 is an integer overflow vulnerability in the libexif library versions up to 0.6.25, specifically when handling Nikon MakerNote metadata on 32-bit systems.

The issue arises because an unsigned 32-bit integer addition used to calculate offsets in the EXIF data can overflow, causing the offset to wrap around and become smaller than expected.

This overflow can lead to out-of-bounds reads of the buffer containing EXIF data, which may cause incorrect parsing, crashes, or information leaks.

A fix was introduced by adding a check to prevent the addition if it would overflow, thereby avoiding unsafe memory operations.


How can this vulnerability impact me? :

This vulnerability can impact you by allowing local attackers on 32-bit systems to cause crashes or leak information through malformed Nikon MakerNote EXIF data.

The integer overflow leads to out-of-bounds memory reads, which can result in application instability or exposure of sensitive data.

Since the attack requires local access and affects only 32-bit systems, the risk is somewhat limited but still significant for affected environments.


Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart