---
title: CVE-2021-20312
description: Ubuntu is an open source software operating system that runs from the
  desktop, to the cloud, to all your internet connected things.
url: https://ubuntu.com/security/CVE-2021-20312
---

# CVE-2021-20312

Publication date 11 May 2021

Last updated 18 August 2025

---

Ubuntu priority

**Low**

[Why this priority?](https://ubuntu.com/security/cves/about#priority )

## Cvss 3 Severity Score

**7.5 · High**

[Score breakdown](https://ubuntu.com/security/CVE-2021-20312#impact-score)

Toggle side navigation

## Description

A flaw was found in ImageMagick in versions 7.0.11, where an integer
overflow in WriteTHUMBNAILImage of coders/thumbnail.c may trigger undefined
behavior via a crafted image file that is submitted by an attacker and
processed by an application using ImageMagick. The highest threat from this
vulnerability is to system availability.

[Read the notes from the security team](https://ubuntu.com/security/CVE-2021-20312#notes)

## Status

Show unmaintained releases

| Package | Ubuntu Release | Status |
| --- | --- | --- |
| imagemagick | 26.04 LTS resolute | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 25.10 questing | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 25.04 plucky | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 24.10 oracular | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 24.04 LTS noble | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 23.10 mantic | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 23.04 lunar | Fixed 8:6.9.11.60+dfsg-1.3ubuntu1 |
| 22.10 kinetic | Fixed 8:6.9.11.60+dfsg-1.3ubuntu0.22.10.1 |
| 22.04 LTS jammy | Fixed 8:6.9.11.60+dfsg-1.3ubuntu0.22.04.1+esm1  Ubuntu Pro |
| 21.10 impish | Ignored end of life |
| 21.04 hirsute | Ignored end of life |
| 20.10 groovy | Ignored end of life |
| 20.04 LTS focal | Fixed 8:6.9.10.23+dfsg-2.1ubuntu11.9 |
| 18.04 LTS bionic | Fixed 8:6.9.7.4+dfsg-16ubuntu6.12 |
| 16.04 LTS xenial | Fixed 8:6.8.9.9-7ubuntu5.16+esm1  Ubuntu Pro |
| 14.04 LTS trusty | Fixed 8:6.7.7.10-6ubuntu3.13+esm1  Ubuntu Pro |

---

* [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)
* [What do statuses mean?](https://ubuntu.com/security/cves/about#statuses)
* [Patch details](https://ubuntu.com/security/CVE-2021-20312#patch-details)

### Get expanded security coverage with Ubuntu Pro

Reduce your average CVE exposure time from 98 days to 1 day with expanded CVE patching, ten-years security maintenance and optional support for the full stack of open-source applications. Free for personal use.

[Get Ubuntu Pro](https://ubuntu.com/pro)
[30-day free trial](https://ubuntu.com/pro/free-trial)

## Notes

---

### [rayveldkamp](https://launchpad.net/~rayveldkamp)

imagemagick is in universe from focal onwards

### Patch details

For informational purposes only. We recommend not to cherry-pick updates. [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)

| Package | Patch details |
| --- | --- |
| imagemagick | * Upstream:   [e53e24b](https://github.com/ImageMagick/ImageMagick6/commit/e53e24b078f7fa586f9cc910491b8910f5bdad2e) |

## Severity score breakdown

CVSS version:
CVSS v3.0

**Base score**

7.5 · High

* Base metrics

  | Parameter | Value |
  | --- | --- |
  | Attack vector | Network |
  | Attack complexity | Low |
  | Privileges required | None |
  | User interaction | None |
  | Scope | Unchanged |
  | Confidentiality impact | None |
  | Integrity impact | None |
  | Availability impact | High |
* Scores

  | Parameter | Value |
  | --- | --- |
  | Base score | 7.5 · High |
  | Exploitability score | - |
  | Impact score | - |

**Vector:** CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

## References

* [MITRE](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-20312)
* [NVD](https://nvd.nist.gov/vuln/detail/CVE-2021-20312)
* [Launchpad](https://launchpad.net/bugs/cve/CVE-2021-20312)
* [Debian](https://security-tracker.debian.org/tracker/CVE-2021-20312)

### Related Ubuntu Security Notices (USN)

+ [USN-5158-1](https://usn.ubuntu.com/USN-5158-1)
+ ImageMagick vulnerabilities
+ 29 November 2021

+ [USN-5736-1](https://usn.ubuntu.com/USN-5736-1)
+ ImageMagick vulnerabilities
+ 24 November 2022

+ [USN-5736-2](https://usn.ubuntu.com/USN-5736-2)
+ ImageMagick vulnerabilities
+ 24 November 2022

+ [USN-6200-1](https://usn.ubuntu.com/USN-6200-1)
+ ImageMagick vulnerabilities
+ 4 July 2023

### Other references

* <https://www.cve.org/CVERecord?id=CVE-2021-20312>
