CVE-2025-66628
Description
ImageMagick is a software suite to create, edit, compose, or convert bitmap images. In versions 7.1.2-9 and prior, the TIM (PSX TIM) image parser contains a critical integer overflow vulnerability in its ReadTIMImage function (coders/tim.c). The code reads width and height (16-bit values) from the file header and calculates image_size = 2 * width * height without checking for overflow. On 32-bit systems (or where size_t is 32-bit), this calculation can overflow if width and height are large (e.g., 65535), wrapping around to a small value. This results in a small heap allocation via AcquireQuantumMemory and later operations relying on the dimensions can trigger an out of bounds read. This issue is fixed in version 7.1.2-10.
Predictions
Heuristic predictions, AS-IS, for prioritization only.
Mitigations
No mitigations published for this CVE yet.
The vendor-content worker queues fetches as references arrive (check back in a few minutes). Or โ if you've already worked around this in production โ publish your fix to the community-verified tier.
โ Propose a mitigation on Community โ Mitigations published via the community go through AI scoring + 2 human reviewers + 7-day silent objection window before landing here withsource_tier=community-verified.
OS impact
SUSE Affected 1 release
| Version | Status | Fixed in |
|---|---|---|
| โ | Affected | โ |
Debian Fixed 5 releases
| Version | Status | Fixed in |
|---|---|---|
| trixie | Fixed | 8:7.1.1.43+dfsg1-1+deb13u4 |
| sid | Fixed | 8:7.1.2.12+dfsg1-1 |
| forky | Fixed | 8:7.1.2.12+dfsg1-1 |
| bullseye | Fixed | 8:6.9.11.60+dfsg-1.3+deb11u8 |
| bookworm | Fixed | 8:6.9.11.60+dfsg-1.6+deb12u5 |
Package impact
| Ecosystem | Package | Vulnerable | Fixed |
|---|---|---|---|
| NuGet | Magick.NET-Q16-AnyCPU | <14.10.0 | 14.10.0 |
| NuGet | Magick.NET-Q16-HDRI-AnyCPU | <14.10.0 | 14.10.0 |
| NuGet | Magick.NET-Q16-HDRI-x86 | <14.10.0 | 14.10.0 |
| NuGet | Magick.NET-Q16-x86 | <14.10.0 | 14.10.0 |
| NuGet | Magick.NET-Q8-AnyCPU | <14.10.0 | 14.10.0 |
| NuGet | Magick.NET-Q8-x86 | <14.10.0 | 14.10.0 |
References
- https://security-tracker.debian.org/tracker/CVE-2025-66628
- https://www.suse.com/security/cve/CVE-2025-66628.html
- https://github.com/ImageMagick/ImageMagick/security/advisories/GHSA-6hjr-v6g4-3fm8
- https://github.com/dlemstra/Magick.NET/commit/2dfa08e15cfd11016a79615994787b14f9048b1c
- https://github.com/ImageMagick/ImageMagick
Community-verified mitigations for this CVE will appear above when contributors publish them.
Verify integrity in audit chain (admin only). AS-IS.