VYPR
Moderate severityNVD Advisory· Published Feb 24, 2026· Updated Feb 26, 2026

ImageMagick has memory leak of watermark Image object in ReadSTEGANOImage on multiple error/early-return paths

CVE-2026-25796

Description

ImageMagick is free and open-source software used for editing and manipulating digital images. Prior to versions 7.1.2-15 and 6.9.13-40, in ReadSTEGANOImage() (coders/stegano.c), the watermark Image object is not freed on three early-return paths, resulting in a definite memory leak (~13.5KB+ per invocation) that can be exploited for denial of service. Versions 7.1.2-15 and 6.9.13-40 contain a patch.

AI Insight

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

A memory leak in ImageMagick's ReadSTEGANOImage (~13.5KB per call) allows denial of service; fixed in versions 7.1.2-15 and 6.9.13-40.

Vulnerability

CVE-2026-25796 is a memory leak in the ReadSTEGANOImage() function within coders/stegano.c. On three early-return paths, the watermark Image object is not freed, resulting in a definite memory leak of approximately 13.5 KB per invocation [2][4]. This affects ImageMagick versions prior to 7.1.2-15 and 6.9.13-40 [2].

Exploitation

An attacker can trigger the leak by providing a crafted steganographic image that forces ReadSTEGANOImage() to exit early on one of the vulnerable paths. No authentication or special privileges are needed; any application that processes user-supplied images—such as web upload services, email filters, or image processing pipelines using ImageMagick—is potentially exposed [1]. The attack is low-complexity and can be repeated to exhaust memory resources.

Impact

Repeated exploitation of this memory leak can progressively consume available memory, leading to denial of service for the ImageMagick process and possibly the host system. The leak accumulates per invocation, so a sustained series of crafted images can degrade or crash the service [2].

Mitigation

The issue is patched in ImageMagick versions 7.1.2-15 and 6.9.13-40 [2][4]. Users should upgrade to these or later releases. The fix adds DestroyImage(watermark) calls before each early return path, ensuring the watermark object is properly freed [4].

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

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
Magick.NET-Q16-AnyCPUNuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-AnyCPUNuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-OpenMP-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-OpenMP-x64NuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-x64NuGet
< 14.10.314.10.3
Magick.NET-Q16-HDRI-x86NuGet
< 14.10.314.10.3
Magick.NET-Q16-OpenMP-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q16-OpenMP-x64NuGet
< 14.10.314.10.3
Magick.NET-Q16-OpenMP-x86NuGet
< 14.10.314.10.3
Magick.NET-Q16-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q16-x64NuGet
< 14.10.314.10.3
Magick.NET-Q16-x86NuGet
< 14.10.314.10.3
Magick.NET-Q8-AnyCPUNuGet
< 14.10.314.10.3
Magick.NET-Q8-OpenMP-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q8-arm64NuGet
< 14.10.314.10.3
Magick.NET-Q8-x64NuGet
< 14.10.314.10.3
Magick.NET-Q8-x86NuGet
< 14.10.314.10.3

Affected products

2
  • ImageMagick/Imagemagickllm-fuzzy2 versions
    <7.1.2-15 or <6.9.13-40+ 1 more
    • (no CPE)range: <7.1.2-15 or <6.9.13-40
    • (no CPE)range: >= 7.0.0, < 7.1.2-15

Patches

0

No patches discovered yet.

Vulnerability mechanics

AI mechanics synthesis has not run for this CVE yet.

References

5

News mentions

0

No linked articles in our index yet.