ImageMagick Division-by-Zero Vulnerability in YUV Sampling Factor Validation Leading to Denial-of-Service

Vulnerability

A logic error in YUV sampling factor validation in ImageMagick allows an invalid sampling factor to bypass checks, triggering a division-by-zero error during image loading. This vulnerability, present in versions prior to 7.1.2-15 and 6.9.13-40, results in a reliable denial-of-service. The division-by-zero error can be exploited to cause a crash, as demonstrated by AddressSanitizer, which reported a runtime error and a deadly signal due to the unknown signal on an unknown address, indicating a crash caused by the division-by-zero error.

Impact

Exploitation of this vulnerability leads to a division-by-zero error, causing a crash and a denial-of-service condition.

Reproduction

The vulnerability can be reproduced by loading an image with an invalid YUV sampling factor in a version of ImageMagick prior to the patched releases. The 'magick' command-line utility can be used to process the image, which will trigger the vulnerability and cause the application to crash.

Remediation

Users can upgrade to ImageMagick versions 7.1.2-15 or 6.9.13-40, where this vulnerability has been patched.

Added: Feb 24, 2026, 1:34 AM
Updated: Feb 24, 2026, 1:34 AM

Vulnerability Rating

Custom Algorithm
spread
7.8
impact
2.5
exploitability
3.6
remediation
7.7
relevance
3.1
threat
1.6
urgency
2.9
incentive
0.0

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