CVE-2017-12642
Description
ImageMagick 7.0.6-1 has a memory leak in ReadMPCImage that can lead to denial of service when processing crafted MPC files.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
ImageMagick 7.0.6-1 has a memory leak in ReadMPCImage that can lead to denial of service when processing crafted MPC files.
Vulnerability
ImageMagick version 7.0.6-1 contains a memory leak vulnerability in the ReadMPCImage function located in coders/mpc.c [1]. The leak occurs when processing specially crafted MPC (Magick Persistent Cache) image files, triggered during image identification operations [1]. The memory is allocated via AcquireMagickMemory and AcquireQuantumMemory but is never properly freed, leading to accumulation of allocated memory [1]. This affects all configurations that use identify, convert, or similar ImageMagick commands on untrusted MPC files [1].
Exploitation
An attacker can trigger the vulnerability by supplying a malicious MPC file to an application or service that uses ImageMagick to process images [1]. No authentication or special privileges are required if the attacker can upload or provide an image file for processing. The attack vector is typically remote via file upload or user interaction. When ImageMagick parses the crafted MPC file with identify or similar commands, the code path in ReadMPCImage at lines 625-627 of mpc.c allocates memory for linked-list structures and strings without releasing them on all exit paths, resulting in a direct leak of 56 bytes and indirect leaks of 4128 bytes and 64 bytes per invocation [1].
Impact
Successfully exploiting this vulnerability leads to a memory leak, causing the ImageMagick process to consume increasing amounts of memory [1]. This can result in a denial of service (DoS) condition by exhausting available system memory, potentially affecting the stability of the host or other processes [1]. The impact is limited to availability; confidentiality and integrity are not directly compromised. No code execution or privilege escalation is possible via this vulnerability alone [1].
Mitigation
As of the publication date, the issue was reported to the ImageMagick project, and a fix was expected in a subsequent release [1]. Users should update ImageMagick to a version newer than 7.0.6-1 once a patched version becomes available. If immediate patching is not possible, workarounds include restricting the processing of untrusted MPC files, using security policies to limit memory allocation, or employing a sandboxed environment for ImageMagick operations [1].
AI Insight generated on May 22, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected products
18cpe:2.3:a:imagemagick:imagemagick:7.0.6-1:*:*:*:*:*:*:*+ 1 more
- cpe:2.3:a:imagemagick:imagemagick:7.0.6-1:*:*:*:*:*:*:*
- (no CPE)range: 7.0.6-1
- osv-coords16 versionspkg:rpm/suse/GraphicsMagick&distro=SUSE%20Linux%20Enterprise%20Software%20Development%20Kit%2011%20SP4pkg:rpm/suse/GraphicsMagick&distro=SUSE%20Studio%20Onsite%201.3pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Desktop%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Desktop%2012%20SP3pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%2011%20SP4pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP3pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%20for%20Raspberry%20Pi%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2011%20SP4pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP3pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Software%20Development%20Kit%2011%20SP4pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Software%20Development%20Kit%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Software%20Development%20Kit%2012%20SP3pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Workstation%20Extension%2012%20SP2pkg:rpm/suse/ImageMagick&distro=SUSE%20Linux%20Enterprise%20Workstation%20Extension%2012%20SP3
< 1.2.5-4.78.28.2+ 15 more
- (no CPE)range: < 1.2.5-4.78.28.2
- (no CPE)range: < 1.2.5-4.78.28.2
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.4.3.6-7.78.22.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.4.3.6-7.78.22.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.4.3.6-7.78.22.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
- (no CPE)range: < 6.8.8.1-71.23.1
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
2- github.com/ImageMagick/ImageMagick/issues/552nvdIssue TrackingPatchThird Party Advisory
- www.securityfocus.com/bid/100159nvd
News mentions
0No linked articles in our index yet.