{"id":"CVE-2025-53101","published":"2025-07-14T19:51:53Z","modified":"2025-11-03T18:13:12Z","title":"ImageMagick has Stack Buffer Overflow in image.c","vendor":"ImageMagick","product":"ImageMagick","tier":"tail","description":{"text":"ImageMagick is free and open-source software used for editing and manipulating digital images. In versions prior to 7.1.2-0 and 6.9.13-26, in ImageMagick's `magick mogrify` command, specifying multiple consecutive `%d` format specifiers in a filename template causes internal pointer arithmetic to generate an address below the beginning of the stack buffer, resulting in a stack overflow through `vsnprintf()`. Versions 7.1.2-0 and 6.9.13-26 fix the issue.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.4,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01114,"percentile":0.65625,"provenance":"source"},"cwes":[{"id":"CWE-124","name":"Buffer Underwrite"}],"references":[{"url":"https://github.com/ImageMagick/ImageMagick/security/advisories/GHSA-qh3h-j545-h8c9","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/ImageMagick/ImageMagick/commit/66dc8f51c11b0ae1f1cdeacd381c3e9a4de69774","tags":["x_refsource_MISC"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/09/msg00012.html","tags":[]}],"priority":{"score":18.3,"factors":[{"name":"EPSS percentile","points":13.12},{"name":"CVSS severity","points":5.18}]},"vendorSlug":"imagemagick","affectedVersions":[{"vendor":"ImageMagick","product":"ImageMagick","versions":["< 7.1.2-0","< 6.9.13-26"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2025-07-15T13:27:44.425746Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"NuGet","package":"Magick.NET-Q16-AnyCPU","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-AnyCPU","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-OpenMP-arm64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-OpenMP-x64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-arm64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-x64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-HDRI-x86","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-OpenMP-arm64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-OpenMP-x64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"},{"ecosystem":"NuGet","package":"Magick.NET-Q16-arm64","vulnerableRanges":["<14.7.0"],"patched":["14.7.0"],"from":["GHSA-qh3h-j545-h8c9"],"provenance":"source"}],"summary":{"text":"A stack buffer overflow in ImageMagick's image.c, which is triggered when the magick mogrify command is given a filename template containing multiple consecutive %d format specifiers and internal pointer arithmetic produces an address below the start of a stack buffer, leading to a write through vsnprintf(). An attacker can exploit this with no authentication and no user interaction, provided they can supply or influence the filename template passed to mogrify, and the flaw affects ImageMagick releases prior to 7.1.2-0 and 6.9.13-26.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T20:40:36Z"},"euvd":{"id":"EUVD-2025-21389","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-imagemagick-cve-2016-4562","parents":[{"from":"CVE-2025-53014","to":"CVE-2025-53101","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["magick/image.c"],"commits":["https://github.com/ImageMagick/ImageMagick6/commit/79b6ed03770781d996d1710b89fbb887e5ea758a","https://github.com/ImageMagick/ImageMagick6/commit/643deeb60803488373cd4799b24d5786af90972e"],"basis":"shared function","functions":["InterpretImageFilename"]}]}],"children":[{"from":"CVE-2025-53101","to":"CVE-2025-55298","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["MagickCore/image.c"],"commits":["https://github.com/ImageMagick/ImageMagick/commit/66dc8f51c11b0ae1f1cdeacd381c3e9a4de69774","https://github.com/ImageMagick/ImageMagick/commit/439b362b93c074eea6c3f834d84982b43ef057d5"],"basis":"shared function","functions":["InterpretImageFilename"]}]},{"from":"CVE-2025-53101","to":"CVE-2026-109264","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["magick/image.c"],"commits":["https://github.com/ImageMagick/ImageMagick6/commit/643deeb60803488373cd4799b24d5786af90972e","https://github.com/ImageMagick/ImageMagick6/commit/d4f06dcca7ad99d639af85bc347ad9fdfdcec8e2"],"basis":"rarely changed file"}]}]}}