Cloudanix VulnDB

CVE-2017-17682

Medium · 6.5

CVSS

6.5

EPSS

3.0%

Published

Dec 14, 2017

CISA due date

—

Cloudanix analysis

Schedule a fix SSVC: Track

A bug in image handling software lets attackers crash systems by sending specially made picture files that make the computer work endlessly.

Exploit Available
Exploitation
Requires User Interaction
Attacker needs
User Interaction
Complexity
Low
Impact
Denial Of Service
Component
Library
Class
Denial of service
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

The flaw allows a specially crafted WPG image file to trigger an infinite loop in the ExtractPostscript function during image processing, leading to excessive CPU consumption.

Why it matters to the business

Attackers can cause service disruptions by exhausting CPU resources on systems processing untrusted image files, potentially leading to downtime in image-handling applications; the vulnerability has been public for over eight years with available exploits but low and stable exploitation probability.

How an attack unfolds

An attacker crafts a malicious WPG image file that causes the ExtractPostscript function to enter a large loop when ReadWPGImage is called, and delivers it to a vulnerable system for processing, resulting in denial of service.

How to fix it

Update affected packages to the fixed versions: kots (Chainguard): 1.103.2-r2, kots (Wolfi): 1.103.2-r2, kots-symlink-compat (Chainguard): 1.103.2-r2, kots-symlink-compat (Wolfi): 1.103.2-r2. Disable processing of WPG images if possible.

How to confirm the fix worked

Verify package versions are updated to the specified fixed releases, and test image processing functionality with sample WPG files to confirm no excessive CPU usage occurs.

Typical attack path

  1. Craft malicious WPG image file
  2. Deliver file to target application
  3. Trigger image processing via ReadWPGImage
  4. Cause CPU exhaustion through infinite loop

How to detect it

Look for high CPU usage during image processing of WPG files and review application logs for entries related to WPG image handling.

What your security team should do

  • Upgrade to fixed package versions immediately due to long public disclosure and available exploits
  • Implement input validation and size limits for image files
  • Monitor for unusual CPU usage in image processing services

The record

In ImageMagick 7.0.7-12 Q16, a large loop vulnerability was found in the function ExtractPostscript in coders/wpg.c, which allows attackers to cause a denial of service (CPU exhaustion) via a crafted wpg image file that triggers a ReadWPGImage call.

Affected packages

Ecosystem Package Introduced Fixed
Debian:10 imagemagick 0 8:6.9.9.34+dfsg-3
Debian:11 imagemagick 0 8:6.9.9.34+dfsg-3
Debian:12 imagemagick 0 8:6.9.9.34+dfsg-3
Debian:13 imagemagick 0 8:6.9.9.34+dfsg-3
Debian:7 imagemagick 0 8:6.7.7.10-5+deb7u19
Debian:8 imagemagick 0 8:6.8.9.9-5+deb8u16
Debian:9 imagemagick 0 8:6.9.7.4+dfsg-11+deb9u10
SUSE:Linux Enterprise Desktop 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Desktop 12 SP3 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Server 11 SP4 ImageMagick 0 6.4.3.6-7.78.37.1
SUSE:Linux Enterprise Server 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Server 12 SP3 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Server for Raspberry Pi 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Server for SAP Applications 11 SP4 ImageMagick 0 6.4.3.6-7.78.37.1
SUSE:Linux Enterprise Server for SAP Applications 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Server for SAP Applications 12 SP3 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Software Development Kit 11 SP4 GraphicsMagick 0 1.2.5-4.78.41.1
SUSE:Linux Enterprise Software Development Kit 11 SP4 ImageMagick 0 6.4.3.6-7.78.37.1
SUSE:Linux Enterprise Software Development Kit 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Software Development Kit 12 SP3 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Workstation Extension 12 SP2 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Linux Enterprise Workstation Extension 12 SP3 ImageMagick 0 6.8.8.1-71.42.1
SUSE:Studio Onsite 1.3 GraphicsMagick 0 1.2.5-4.78.41.1
Ubuntu:14.04:LTS imagemagick 0 8:6.7.7.10-6ubuntu3.11
Ubuntu:16.04:LTS imagemagick 0 8:6.8.9.9-7ubuntu5.11
Ubuntu:18.04:LTS imagemagick 0 8:6.9.7.4+dfsg-16ubuntu6.2

Related vulnerabilities