Skip to main content
Vulnerability Database/CVE-2026-109272

CVE-2026-109272: ImageMagick PostScript DOS Vulnerability

CVE-2026-109272 is a denial of service vulnerability in ImageMagick caused by a NULL pointer dereference in the PostScript decoder. This post explains its impact, affected versions, and mitigation steps.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-109272 Overview

CVE-2026-109272 is a NULL pointer dereference [CWE-476] in the PostScript decoder of ImageMagick. The flaw affects versions 7.1.1-31 through versions before 7.1.2-32. The dereference triggers when a configured policy limit is reached during PostScript processing. An attacker who supplies a crafted PostScript file can crash the ImageMagick process, producing a denial-of-service condition. The issue resides in coders/ps.c and was corrected by validating the photoshop_profile pointer before dereferencing it.

Critical Impact

A remote attacker can crash ImageMagick-based services by submitting a malicious PostScript file, disrupting any workflow that converts or renders user-supplied images.

Affected Products

  • ImageMagick 7.1.1-31
  • ImageMagick versions between 7.1.1-31 and 7.1.2-32
  • Applications and services that embed ImageMagick for PostScript decoding

Discovery Timeline

  • 2026-10-12 - CVE-2026-109272 published to NVD
  • 2026-10-15 - Last updated in NVD database

Technical Details for CVE-2026-109272

Vulnerability Analysis

The vulnerability lives in the PostScript decoder implemented in coders/ps.c. When ImageMagick parses an embedded Photoshop (8bim) profile inside a PostScript stream, it calls AcquireProfileStringInfo to allocate a StringInfo object for ps_info->photoshop_profile. If a policy limit is reached, allocation returns NULL. The original code then validated the wrong pointer (ps_info->icc_profile) before calling GetStringInfoDatum on ps_info->photoshop_profile, producing a NULL pointer dereference and process crash.

The condition is reachable through any workflow that decodes attacker-controlled PostScript, including web upload handlers, document conversion pipelines, and image previewers.

Root Cause

The root cause is an incorrect NULL check following allocation. The guard tested a sibling profile pointer rather than the one being accessed. When the ImageMagick resource policy caps profile allocation, the allocator returns NULL, bypassing the intended safety check and leading to the dereference.

Attack Vector

Exploitation requires the attacker to deliver a crafted PostScript file to a target that processes it with a vulnerable ImageMagick build. No authentication is required when the target exposes an upload or conversion endpoint. The resulting impact is limited to availability; the vulnerability does not enable code execution or data disclosure.

c
           {
             ps_info->photoshop_profile=AcquireProfileStringInfo("8bim",
               length+1U,exception);
-            if (ps_info->icc_profile != (StringInfo*) NULL)
+            if (ps_info->photoshop_profile != (StringInfo*) NULL)
               {
                 q=GetStringInfoDatum(ps_info->photoshop_profile);
                 while (extent > 0)

Source: GitHub Commit d98509b — the patch replaces the incorrect pointer check with a check against ps_info->photoshop_profile before dereferencing it.

Detection Methods for CVE-2026-109272

Indicators of Compromise

  • Repeated crashes or segmentation faults in processes invoking convert, magick, or ImageMagick library calls when handling PostScript (.ps, .eps) inputs.
  • Policy-limit warnings in ImageMagick logs correlated with abnormal process termination.
  • Inbound uploads of PostScript files containing malformed or oversized 8bim Photoshop profile segments.

Detection Strategies

  • Inventory systems for ImageMagick builds between 7.1.1-31 and 7.1.2-32 using software composition analysis tooling.
  • Alert on worker process crashes in image-conversion services, particularly when the crashing input is a PostScript or EPS file.
  • Inspect ImageMagick policy.xml to identify environments where profile resource limits are enforced, as those are the configurations that trigger the dereference.

Monitoring Recommendations

  • Monitor application and container logs for recurring SIGSEGV terminations in ImageMagick helper processes.
  • Track upload endpoints for anomalous volumes of PostScript or EPS submissions.
  • Correlate denial-of-service symptoms in image pipelines with the version metadata collected from runtime hosts.

How to Mitigate CVE-2026-109272

Immediate Actions Required

  • Upgrade ImageMagick to version 7.1.2-32 or later on all systems that decode untrusted PostScript input.
  • Restrict acceptance of PostScript and EPS files at upload endpoints until the patched version is deployed.
  • Isolate image-conversion workers so that a crash does not affect other tenants or services.

Patch Information

The fix is committed to the ImageMagick repository in commit d98509b23a547d9ccd0a8af8650d03c5c01c3722 and documented in the project advisory. Review the GitHub Security Advisory GHSA-58h4-rwr6-wj72, the GitHub Commit for Fix, and the VulnCheck Advisory for ImageMagick for complete remediation details.

Workarounds

  • Disable the PostScript and EPS coders in policy.xml by adding <policy domain="coder" rights="none" pattern="PS" /> and equivalent entries for PS2, PS3, and EPS.
  • Run ImageMagick inside a resource-constrained sandbox or container with automatic restart to limit the impact of denial-of-service attempts.
  • Validate uploaded file types and reject PostScript inputs at the application boundary until patching is complete.
bash
# Disable PostScript coders in ImageMagick policy.xml
<policymap>
  <policy domain="coder" rights="none" pattern="PS" />
  <policy domain="coder" rights="none" pattern="PS2" />
  <policy domain="coder" rights="none" pattern="PS3" />
  <policy domain="coder" rights="none" pattern="EPS" />
</policymap>

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.