VYPR
Unrated severityNVD Advisory· Published Jun 26, 2019· Updated Aug 4, 2024

CVE-2019-12978

CVE-2019-12978

Description

ImageMagick 7.0.8-34 has a use-of-uninitialized-value vulnerability in ReadPANGOImage that can cause undefined behavior.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

ImageMagick 7.0.8-34 has a use-of-uninitialized-value vulnerability in ReadPANGOImage that can cause undefined behavior.

Vulnerability

ImageMagick version 7.0.8-34 contains a use-of-uninitialized-value vulnerability in the ReadPANGOImage function in coders/pango.c [1]. The issue occurs when an image is acquired via AcquireImage and the SetImageBackgroundColor function is not called if image->columns or image->rows is zero, leaving pixel data uninitialized [1]. This code path is reachable when processing specially crafted images that trigger the PANGO decoder.

Exploitation

An attacker can exploit this vulnerability by providing a crafted image file to a victim using ImageMagick to process it. No authentication or special privileges are required beyond the ability to submit an image for processing. The vulnerability is triggered during image decoding when the PANGO code path is invoked and the image dimensions are zero, causing access to uninitialized memory.

Impact

Successful exploitation leads to undefined behavior due to reading uninitialized memory. This could result in denial of service (e.g., crash) or potential information disclosure if the uninitialized data is exposed. The severity depends on the context of the application using ImageMagick.

Mitigation

The vulnerability was addressed in later commits (e.g., 18df577 and f1fb781) [1]. Users should upgrade ImageMagick to a version after 7.0.8-34 that includes the fix. If upgrading is not immediately possible, avoid processing untrusted images with the PANGO decoder as a workaround.

AI Insight generated on May 26, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected products

13

Patches

0

No patches discovered yet.

Vulnerability mechanics

Root cause

"The ReadPANGOImage function fails to initialize image background properties when image dimensions are zero."

Attack vector

An attacker can trigger this vulnerability by providing a specially crafted input file that causes the ReadPANGOImage function to process an image with zero columns or rows [ref_id=1]. This leads to a use-of-uninitialized-value condition during image processing. The vulnerability is located within the coders/pango.c file [ref_id=1].

Affected code

The vulnerability is located in the ReadPANGOImage function within the coders/pango.c file [ref_id=1].

What the fix does

The advisory suggests that the vulnerability can be mitigated by calling SetImageBackgroundColor only when the condition image->columns != 0 and image->rows != 0 is satisfied [ref_id=1]. By ensuring that background properties are only set for valid image dimensions, the use of uninitialized values is prevented. The advisory does not specify if a formal patch has been applied to the codebase.

Preconditions

  • inputThe attacker must provide an input file that results in an image with zero columns or rows during processing by ReadPANGOImage.

Generated on Jun 1, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

6

News mentions

0

No linked articles in our index yet.