SOC status:Duty analyst on shift

UK Cyber Defence
VulnerabilityModified

CVE-2019-6977

gdImageColorMatch in gd_color_match.c in the GD Graphics Library (aka LibGD) 2.2.5, as used in the imagecolormatch function in PHP before 5.6.40, 7.x before 7.1.26, 7.2.x before 7.2.14, and 7.3.x before 7.3.1, has a heap-based buffer overflow.

EXPLOITHIGH 8.8EPSS 71.5%

Does this matter?

EPSS puts the probability of exploitation in the next 30 days at 71.5%, higher than 99% of all known CVEs. Patch or mitigate before the next change window.

Description

gdImageColorMatch in gd_color_match.c in the GD Graphics Library (aka LibGD) 2.2.5, as used in the imagecolormatch function in PHP before 5.6.40, 7.x before 7.1.26, 7.2.x before 7.2.14, and 7.3.x before 7.3.1, has a heap-based buffer overflow. This can be exploited by an attacker who is able to trigger imagecolormatch calls with crafted image data.

CVSS 3.0
8.8 HIGHCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS
71.50% probability · 99th percentile
Public exploits
1 in Exploit-DB · first 27 February 2019
CISA KEV
Not listed
Weakness
CWE-787
Affected
libgd/libgd · php/php · debian/debian linux · canonical/ubuntu linux · netapp/storage automation store
Source
cve@mitre.org
EPSS trend
0%38%75%21 September 2026: 62.09%22 September 2026: 71.50%26 October 2026: 71.50%21 September 202626 October 2026

EPSS moved from 62.1% on 21 September 2026 to 71.5% on 26 October 2026. The dashed line is the ten per cent mark our analysts treat as “patch before the next change window”.

Public exploits (1)

Entries in Exploit-DB that cite this CVE. Links go to the Exploit-DB page and to the file in the public repository; nothing is hosted here. A verified tick means the Exploit-DB team confirmed the exploit works against the stated version.

EDB-IDTitleTypePublishedVerified
EDB-46677source ↗PHP 7.2 - 'imagecolormatch()' Out of Band Heap Writephp · cfrealremote27 February 2019no

References

Source: NVD record, EPSS from FIRST.org, KEV from CISA, exploits from Exploit-DB. Refreshed daily. Download this record as JSON.