CVE-2019-6977
Reported by mitre · Published January 27, 2019
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.
Fixed versions
Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.
| Package | Ecosystem | Fixed in |
|---|---|---|
| gd | Alpine | 2.2.5-r2 |
Affected products
| Vendor | Product | Versions |
|---|---|---|
| n/a | n/a | n/a |
| alpine | gd | 0 |
| n/a | n/a | * |
| alpine | php7 | 0 |
| arch | gd | 0 |
Timeline
- Jan 27, 2019 CVE Published
- Apr 9, 2019 PoC Published (3 in total, the first dated here)
- Apr 14, 2021 EPSS Score (30 in total, the first dated here)
- Mar 6, 2026 Distribution Patch (4 in total, the first dated here)
- Mar 6, 2026 Security Advisory (9 in total, the first dated here)
- Sep 8, 2026 Coalition ESS Score
Query this with the API
The same record, from the CLI:
vulnetix vdb vuln CVE-2019-6977
vulnetix vdb fixes CVE-2019-6977
Or with curl, using the org id and key from your account page:
curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
"https://api.vdb.vulnetix.com/v2/vuln/CVE-2019-6977/fixes/registry"
The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart
References
- 106731 vdb-entryx_refsource_BID
- x_refsource_CONFIRM
- x_refsource_MISC
- x_refsource_MISC
- USN-3900-1 vendor-advisoryx_refsource_UBUNTU
- [debian-lts-announce] 20190130 [SECURITY] [DLA 1651-1] libgd2 security update mailing-listx_refsource_MLIST
- x_refsource_MISC
- DSA-4384 vendor-advisoryx_refsource_DEBIAN
- GLSA-201903-18 vendor-advisoryx_refsource_GENTOO
- openSUSE-SU-2019:1148 vendor-advisoryx_refsource_SUSE
- openSUSE-SU-2019:1140 vendor-advisoryx_refsource_SUSE
- 46677 exploitx_refsource_EXPLOIT-DB
- x_refsource_MISC
- RHSA-2019:2519 vendor-advisoryx_refsource_REDHAT
- RHSA-2019:3299 vendor-advisoryx_refsource_REDHAT
- FEDORA-2019-ab7d22a466 vendor-advisoryx_refsource_FEDORA
- FEDORA-2019-d7f8995451 vendor-advisoryx_refsource_FEDORA
- FEDORA-2019-7a06c0e6b4 vendor-advisoryx_refsource_FEDORA
- FEDORA-2020-e795f92d79 vendor-advisoryx_refsource_FEDORA