Bug 2506063 - CVE-2026-47667 CImg: CImg Library: Denial of service due to unbounded memory allocation in image file processing. [fedora-all]
Summary: CVE-2026-47667 CImg: CImg Library: Denial of service due to unbounded memory ...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: CImg
Version: 45
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
Assignee: Christopher Meng
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: {"flaws": ["16eb5678-cb45-443f-874c-e...
Depends On:
Blocks: CVE-2026-47667
TreeView+ depends on / blocked
 
Reported: 2026-07-22 11:13 UTC by TEJ RATHI
Modified: 2026-08-17 15:35 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Type: ---
Embargoed:


Attachments (Terms of Use)

Description TEJ RATHI 2026-07-22 11:13:41 UTC
Disclaimer: Community trackers are created by Red Hat Product Security team on a best effort basis. Package maintainers are required to ascertain if the flaw indeed affects their package, before starting the update process.

CImg Library is a C++ library for image processing. Prior to version 4.0.0 in `_load_analyze()`, the header_size field is read as an `unsigned int` from the first 4 bytes of an Analyze/NIfTI file and passed directly to `new unsigned char[header_size]` without being bounded against the actual file size. A value up to ~4 GB is accepted. If the subsequent `fread` returns `short`  as it will for any malformed file), the function throws a `CImgIOException` and the allocated buffer is never freed. A 6-byte crafted file is sufficient to trigger an allocation of ~1.3 GB per call, with the full allocation leaked on every error path. The issue is reachable via `load_analyze()` and the generic `load()` when the file extension is .hdr, .img, or .nii. Version 4.0.0 fixes the issue.

Comment 1 josef radinger 2026-07-28 13:40:01 UTC
fixed in rawhide with update to 4.0.3

https://bodhi.fedoraproject.org/updates/FEDORA-2026-f460ed4d6f

Comment 2 Aoife Moloney 2026-08-17 15:35:47 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 45 development cycle.
Changing version to 45.


Note You need to log in before you can comment on or make changes to this bug.