CVE-2025-43965
NoneCVSS
—
EPSS
0.6%
Published
Apr 23, 2025
CISA due date
—
Cloudanix analysis
A flaw in how ImageMagick handles certain image files can make programs that use it crash or behave incorrectly when opening untrusted images.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Theoretical
- Impact
- Other
- Component
- Library
- Class
- Improper Input Validation
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Mishandling of image depth after SetQuantumFormat in MIFF processing leads to improper input validation and potential memory corruption or incorrect quantum format handling during image decode.
Why it matters to the business
Applications that process MIFF images may crash, produce corrupted output, or become unstable when handling untrusted files, increasing operational risk for image-heavy workflows.
How an attack unfolds
An attacker crafts a malicious MIFF image that triggers depth mishandling after SetQuantumFormat, causing the library to enter an invalid state during decoding.
How to fix it
Upgrade ImageMagick to a build containing commit bac413a26073923d3ffb258adaab07fb3fe8fdc9 or later equivalent release that corrects MIFF depth handling after SetQuantumFormat.
How to confirm the fix worked
Confirm the installed version includes the referenced commit or is at least 7.1.1-44; test processing of known-good and edge-case MIFF files to verify stable depth handling.
Typical attack path
- Attacker crafts a specially formatted MIFF file exploiting depth mishandling post-SetQuantumFormat
- Victim application loads the image using vulnerable ImageMagick
- Library processes the quantum format incorrectly leading to invalid state or corruption
- Resulting behavior may cause crash, denial of service, or unexpected image output
How to detect it
Review application logs for ImageMagick crashes or errors during MIFF decoding; inspect process memory dumps or core files for quantum format anomalies after MIFF processing.
What your security team should do
- Prioritize upgrade of ImageMagick to the fixed commit across all build and runtime environments
- Restrict processing of untrusted MIFF files until patched
- Monitor for any downstream dependents that embed the vulnerable library
The record
In MIFF image processing in ImageMagick before 7.1.1-44, image depth is mishandled after SetQuantumFormat is used.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Chainguard | imagemagick-6 | 0 | 0 |
| Chainguard | imagemagick-6-dev | 0 | 0 |
| Chainguard | imagemagick-6-doc | 0 | 0 |
| Chainguard | imagemagick-6-static | 0 | 0 |
| Debian:11 | imagemagick | 0 | 8:6.9.11.60+dfsg-1.3+deb11u5 |
| Debian:12 | imagemagick | 0 | No fix |
| Debian:13 | imagemagick | 0 | No fix |
| Debian:14 | imagemagick | 0 | No fix |
| Mageia:9 | imagemagick | 0 | 7.1.1.29-1.1.mga9 |
| SUSE:Linux Enterprise Module for Desktop Applications 15 SP6 | ImageMagick | 0 | 7.1.1.21-150600.3.3.1 |
| SUSE:Linux Enterprise Module for Development Tools 15 SP6 | ImageMagick | 0 | 7.1.1.21-150600.3.3.1 |
| openSUSE:Leap 15.6 | ImageMagick | 0 | 7.1.1.21-150600.3.3.1 |
Related vulnerabilities
- CVE-2026-23952 ImageMagick is free and open-source software used for editing and manipulating digital… Also affects imagemagick-6
- GHSA-9vj4-wc7r-p844 ImageMagick MSL: Stack overflow via infinite recursion in ProcessMSLScript Also affects imagemagick-6
- CVE-2026-23874 ImageMagick MSL: Stack overflow via infinite recursion in ProcessMSLScript Also affects imagemagick-6
- GHSA-39h3-g67r-7g3c ImageMagick releases an invalid pointer in BilateralBlur when memory allocation fails Also affects imagemagick-6
- CVE-2026-22770 ImageMagick releases an invalid pointer in BilateralBlur when memory allocation fails Also affects imagemagick-6
- GHSA-7rvh-xqp3-pr8j ImageMagick's failure to limit MVG mutual causes Stack Overflow Also affects imagemagick-6
- GHSA-p27m-hp98-6637 ImageMagick's failure to limit the depth of SVG file reads caused a DoS attack Also affects imagemagick-6
- CVE-2025-69204 ImageMagick converting a malicious MVG file to SVG caused an integer overflow. Also affects imagemagick-6