# CVE-2025-65955: ImageMagick has a use-after-free/double-free risk in Options::fontFamily when clearing family

- Severity: Medium 4.9 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.17%, higher than 6% of CVEs (2026-12-01)
- Published: 2025-12-02T23:02:58.856Z
- Modified: 2026-11-04T22:10:00.210Z
- Also known as: GHSA-q3hc-j9x5-mp9m
- Weaknesses: CWE-415, CWE-416
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

ImageMagick is free and open-source software used for editing and manipulating digital images. Prior to 7.1.2-9 and 6.9.13-34, there is a vulnerability in ImageMagick’s Magick++ layer that manifests when Options::fontFamily is invoked with an empty string. Clearing a font family calls RelinquishMagickMemory on _drawInfo->font, freeing the font string but leaving _drawInfo->font pointing to freed memory while _drawInfo->family is set to that (now-invalid) pointer. Any later cleanup or reuse of _drawInfo->font re-frees or dereferences dangling memory. DestroyDrawInfo and other setters (Options::font, Image::font) assume _drawInfo->font remains valid, so destruction or subsequent updates trigger crashes or heap corruption. This vulnerability is fixed in 7.1.2-9 and 6.9.13-34.

(As written by CVE List.)

## Affected

- ImageMagick ImageMagick: >= 7.0.1-0, < 7.1.2-9; < 6.9.13-34; before 6.9.13-34; from 7.0.0-0 before 7.1.2-9
- Magick.NET-Q16-AnyCPU (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-AnyCPU (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-OpenMP-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-OpenMP-x64 (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-x64 (NuGet): up to 14.9.1
- Magick.NET-Q16-HDRI-x86 (NuGet): up to 14.9.1
- Magick.NET-Q16-OpenMP-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q16-OpenMP-x64 (NuGet): up to 14.9.1
- Magick.NET-Q16-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q16-x64 (NuGet): up to 14.9.1
- Magick.NET-Q16-x86 (NuGet): up to 14.9.1
- Magick.NET-Q8-AnyCPU (NuGet): up to 14.9.1
- Magick.NET-Q8-OpenMP-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q8-OpenMP-x64 (NuGet): up to 14.9.1
- Magick.NET-Q8-arm64 (NuGet): up to 14.9.1
- Magick.NET-Q8-x64 (NuGet): up to 14.9.1
- Magick.NET-Q8-x86 (NuGet): up to 14.9.1

## Every score

- GitHub_M: CVSS:3.1 4.9 Medium `CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:L`
- GitHub: CVSS:3.1 4.9 Medium `CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:L`
- NVD: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:H`

## References

- <https://github.com/ImageMagick/ImageMagick/security/advisories/GHSA-q3hc-j9x5-mp9m> (vendor-advisory, web)
- <https://github.com/ImageMagick/ImageMagick/commit/6409f34d637a34a1c643632aa849371ec8b3b5a8> (patch, web)
- <https://github.com/ImageMagick/ImageMagick/commit/6f81eb15f822ad86e8255be75efad6f9762c32f8> (patch, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2025-65955> (advisory)
- <https://github.com/ImageMagick/ImageMagick> (package)

## Sources

- CVE List: [CVE-2025-65955](https://www.cve.org/CVERecord?id=CVE-2025-65955), CVE Terms of Use, modified 2026-06-23
- GitHub Advisory Database: [GHSA-q3hc-j9x5-mp9m](https://github.com/advisories/GHSA-q3hc-j9x5-mp9m), CC-BY-4.0, modified 2025-12-11
- NVD: [CVE-2025-65955](https://nvd.nist.gov/vuln/detail/CVE-2025-65955), Public domain, modified 2026-11-04

---

Page: https://cve.day/CVE-2025-65955 · Whole record: https://cve.day/CVE-2025-65955.json · Rebuilt by cve.day 2026-11-25T22:59:08.215Z
