Stack consumption vulnerability in the gdImageFillToBorder function in gd.c in the GD…
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Denial of service
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Partial Red Hat: 8 fixed, 5 without a fix
Attack profile from CVSS 3.0 · NVD. Fix status from CNA and Red Hat. Impact type from CWE-119 and the CVSS impact.
Summary
Stack consumption vulnerability in the gdImageFillToBorder function in gd.c in the GD Graphics Library (aka libgd) before 2.2.2, as used in PHP before 5.6.28 and 7.x before 7.0.13, allows remote attackers to cause a denial of service (segmentation violation) via a crafted imagefilltoborder call that triggers use of a negative color value.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| — | — | all versions | — | No fix listed | CNA |
- — Vendor— Affected all versions Fixed in — No fix listed CNA
CPE configurations NVD · 14
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:libgd:libgd:2.2.1:*:*:*:*:*:*:* | 2.2.1 | Vulnerable | Libgd |
| cpe:2.3:a:php:php:*:*:*:*:*:*:*:* | up to 5.6.27 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:* | 7.0.0 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:* | 7.0.1 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:* | 7.0.2 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:* | 7.0.3 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:* | 7.0.4 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:* | 7.0.5 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:* | 7.0.6 | Running on | PHP |
| cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:* | 7.0.7 | Running on | PHP |
- cpe:2.3:a:libgd:libgd:2.2.1:*:*:*:*:*:*:* Versions 2.2.1 Vulnerable ·Libgd
- cpe:2.3:a:php:php:*:*:*:*:*:*:*:* Versions up to 5.6.27 Running on ·PHP
- cpe:2.3:a:php:php:7.0.0:*:*:*:*:*:*:* Versions 7.0.0 Running on ·PHP
- cpe:2.3:a:php:php:7.0.1:*:*:*:*:*:*:* Versions 7.0.1 Running on ·PHP
- cpe:2.3:a:php:php:7.0.2:*:*:*:*:*:*:* Versions 7.0.2 Running on ·PHP
- cpe:2.3:a:php:php:7.0.3:*:*:*:*:*:*:* Versions 7.0.3 Running on ·PHP
- cpe:2.3:a:php:php:7.0.4:*:*:*:*:*:*:* Versions 7.0.4 Running on ·PHP
- cpe:2.3:a:php:php:7.0.5:*:*:*:*:*:*:* Versions 7.0.5 Running on ·PHP
- cpe:2.3:a:php:php:7.0.6:*:*:*:*:*:*:* Versions 7.0.6 Running on ·PHP
- cpe:2.3:a:php:php:7.0.7:*:*:*:*:*:*:* Versions 7.0.7 Running on ·PHP
Remediation
Red Hat 1 advisory
- RHSA-2018:1296 Released 2018-05-03 · Red Hat rating Moderaterh-php70-php security, bug fix, and enhancement update
- Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 6) rh-php70-php-7.0.27-1.el6, rh-php70-php-bcmath-7.0.27-1.el6, rh-php70-php-cli-7.0.27-1.el6 +28
- Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) rh-php70-php-7.0.27-1.el7, rh-php70-php-bcmath-7.0.27-1.el7, rh-php70-php-cli-7.0.27-1.el7 +26
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 6.7) rh-php70-php-7.0.27-1.el6, rh-php70-php-bcmath-7.0.27-1.el6, rh-php70-php-cli-7.0.27-1.el6 +28
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.3) rh-php70-php-7.0.27-1.el7, rh-php70-php-bcmath-7.0.27-1.el7, rh-php70-php-cli-7.0.27-1.el7 +26
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) rh-php70-php-7.0.27-1.el7, rh-php70-php-bcmath-7.0.27-1.el7, rh-php70-php-cli-7.0.27-1.el7 +26
- Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.5) rh-php70-php-7.0.27-1.el7, rh-php70-php-bcmath-7.0.27-1.el7, rh-php70-php-cli-7.0.27-1.el7 +26
- Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 6) rh-php70-php-7.0.27-1.el6, rh-php70-php-bcmath-7.0.27-1.el6, rh-php70-php-cli-7.0.27-1.el6 +28
- Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) rh-php70-php-7.0.27-1.el7, rh-php70-php-bcmath-7.0.27-1.el7, rh-php70-php-cli-7.0.27-1.el7 +26
Vendor assessments
Red Hat
Red Hat rating: Low. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Enterprise Linux 5 | Affected | No fix planned: Will not fix |
| Red Hat Enterprise Linux 6 | Affected | No fix planned: Will not fix |
| Red Hat Enterprise Linux 7 | Affected | No fix planned: Will not fix |
| Red Hat OpenShift Enterprise 2 | Affected | No fix planned: Will not fix |
| Red Hat Software Collections | Affected | No fix planned: Will not fix |
| Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 6) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server (v. 7) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 6.7) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.3) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.4) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Server EUS (v. 7.5) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 6) | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux Workstation (v. 7) | Fixed | RHSA-2018:1296 |
Timeline
- 2026-10-02 Threatist record created from CVE-2016-9933
- 2026-10-03 Alias added: GHSA-cmjx-gh93-h4cg
References
Advisory 13
- [oss-security] 20161212 CVE assignment for PHP 5.6.28, 5.6.29, 7.0.13, 7.0.14 and 7.1.0
- openSUSE-SU-2016:3228
- openSUSE-SU-2017:0081
- http://www.php.net/ChangeLog-7.php
- openSUSE-SU-2017:0006
- https://github.com/php/php-src/commit/863d37ea66d5c960db08d6f4a2cbd2518f0f80d1
- DSA-3751
- RHSA-2018:1296
- http://www.php.net/ChangeLog-5.php
- https://bugs.php.net/bug.php?id=72696
- openSUSE-SU-2017:0061
- openSUSE-SU-2016:3239
- https://github.com/libgd/libgd/issues/215
More Libgd vulnerabilities
- TI-2019-04913 gdImageColorMatch in gd_color_match.c in the GD Graphics Library (aka LibGD) 2.2.5, as… CVSS 3.0HIGH 8.8
- TI-2016-02573 Integer signedness error in GD Graphics Library 2.1.1 (aka libgd or libgd2) allows remote… CVSS 3.1CRITICAL 9.8
- TI-2016-08242 Integer underflow in the _gdContributionsAlloc function in gd_interpolation.c in the GD… CVSS 3.0CRITICAL 9.8
- TI-2016-07128 Integer signedness error in the dynamicGetbuf function in gd_io_dp.c in the GD Graphics… CVSS 3.0CRITICAL 9.8
- TI-2016-06432 Integer overflow in the gdImageWebpCtx function in gd_webp.c in the GD Graphics Library… CVSS 3.0CRITICAL 9.8
- TI-2019-04914 The GD Graphics Library (aka LibGD) 2.2.5 has a double free in the gdImage*Ptr()… CVSS 3.0CRITICAL 9.8
Sources
- CVE-2016-9933 · CVE Program
- CVE-2016-9933 · NVD
- FIRST EPSS
- GHSA-cmjx-gh93-h4cg · GitHub Advisory Database · CC BY 4.0
- CVE-2016-9933 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences