HDF5 Heap-Based Buffer Overflow Vulnerability in Metadata Attribute Decoder

Vulnerability

A critical heap-based buffer overflow vulnerability has been identified in HDF5 version 1.14.6. The issue arises in the Metadata Attribute Decoder component, specifically within the H5MM_strndup function. This vulnerability allows for memory corruption and application crashes, and could potentially be exploited for arbitrary code execution. The buffer overflow occurs when the library reads 5 bytes beyond the boundary of a 320-byte heap-allocated memory region. Exploitation of this vulnerability requires local access.

Impact

Exploitation of this vulnerability leads to a heap-based buffer overflow, causing memory corruption and application crashes. This vulnerability could also be exploited to execute arbitrary code.

Reproduction

The vulnerability can be reproduced by compiling the HDF5 library with AddressSanitizer enabled, which will detect the heap-buffer-overflow error. After compiling the library, the 'h5dump' tool can be used to process a crafted HDF5 file that triggers the vulnerability. The AddressSanitizer will report the heap-buffer-overflow error, indicating that the vulnerability has been successfully exploited.

Added: Jun 9, 2025, 7:46 PM
Updated: Jun 9, 2025, 7:46 PM

Vulnerability Rating

Custom Algorithm
spread
5.4
impact
2.5
exploitability
6.0
remediation
0.0
relevance
0.0
threat
6.4
urgency
2.9
incentive
0.8

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.