Integer overflow in ImageMagick - CVE-2020-27766

 

Integer overflow in ImageMagick - CVE-2020-27766

Published: March 23, 2022


Vulnerability identifier: #VU61574
CSH Severity: High
CVSS v4: 9.3 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N]
CVE-ID: CVE-2020-27766
CWE-ID: CWE-190
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to execute arbitrary code on the target system.

The vulnerability exists due to integer overflow within the MagickCore/statistic.c file in ImageMagick. A remote attacker can pass specially crafted data to the application, trigger integer overflow and execute arbitrary code on the target system.

Successful exploitation of this vulnerability may result in complete compromise of vulnerable system.


Affected software

ImageMagick
Ubuntu
libimage-magick-perl (Ubuntu package)
imagemagick-common (Ubuntu package)
libmagickcore-6.q16-dev (Ubuntu package)
libmagickcore-dev (Ubuntu package)
imagemagick (Ubuntu package)
libimage-magick-q16-perl (Ubuntu package)
libmagickcore-6.q16-2-extra (Ubuntu package)
imagemagick-6.q16 (Ubuntu package)
libmagickcore-6-headers (Ubuntu package)
libmagick++-6.q16-5v5 (Ubuntu package)
perlmagick (Ubuntu package)
libmagickcore-6-arch-config (Ubuntu package)
libmagick++-6.q16-dev (Ubuntu package)
libmagickwand-6.q16-dev (Ubuntu package)
libmagickcore-6.q16-2 (Ubuntu package)
libmagickwand-6.q16-2 (Ubuntu package)

How to mitigate CVE-2020-27766

Install updates from vendor's website.

ImageMagick - update to 7.0.8-69
libimage-magick-perl (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
imagemagick-common (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-6.q16-dev (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-dev (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
imagemagick (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libimage-magick-q16-perl (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-6.q16-2-extra (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
imagemagick-6.q16 (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-6-headers (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagick++-6.q16-5v5 (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
perlmagick (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-6-arch-config (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagick++-6.q16-dev (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickwand-6.q16-dev (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickcore-6.q16-2 (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2
libmagickwand-6.q16-2 (Ubuntu package) - update to 8:6.8.9.97ubuntu5.16+esm2

External References

Related Security Bulletins