Integer Overflow or Wraparound Affecting ImageMagick/ImageMagick package, versions [,6.9.9-11)[7.0.1-0,7.0.7-0)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
1.94% (78th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Integer Overflow or Wraparound vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-IMAGEMAGICKIMAGEMAGICK-3007853
  • published26 Jan 2022
  • disclosed7 Sept 2017
  • creditUnknown

Introduced: 7 Sep 2017

CVE-2017-14173  (opens in a new tab)
CWE-190  (opens in a new tab)
CWE-835  (opens in a new tab)

How to fix?

Upgrade ImageMagick/ImageMagick to version 6.9.9-11, 7.0.7-0 or higher.

Overview

Affected versions of this package are vulnerable to Integer Overflow or Wraparound. In the function ReadTXTImage() in coders/txt.c in ImageMagick 7.0.6-10, an integer overflow might occur for the addition operation "GetQuantumRange(depth)+1" when "depth" is large, producing a smaller value than expected. As a result, an infinite loop would occur for a crafted TXT file that claims a very large "max_value" value.

CVSS Base Scores

version 3.1