php: Buffer over-read from unitialized data in gdImageCreateFromGifCtx function
Published Aug 2, 2017
6.5
MEDIUMCVSS 3.0
EPSS 3.42%
Description
The GIF decoding function gdImageCreateFromGifCtx in gd_gif_in.c in the GD Graphics Library (aka libgd), as used in PHP before 5.6.31 and 7.x before 7.1.7, does not zero colorMap arrays before use. A specially crafted GIF image could use the uninitialized tables to read ~700 bytes from the top of the stack, potentially disclosing sensitive information.
Affected products
No data.
- ≤ 5.6.30
- 7.0.0
- 7.0.1
- 7.0.2
- 7.0.3
- 7.0.4
- 7.0.5
- 7.0.6
- 7.0.7
- 7.0.8
- 7.0.9
- 7.0.10
- 7.0.11
- 7.0.12
- 7.0.13
- 7.0.14
- 7.0.15
- 7.0.16
- 7.0.17
- 7.0.18
- 7.0.19
- 7.0.20
- 7.1.0
- 7.1.1
- 7.1.2
- 7.1.3
- 7.1.4
- 7.1.5
- 7.1.6
No data.
Red Hat Enterprise Linux 7
php-0:5.4.16-43.el7_4.1
Fixed · RHSA-2018:0406
Red Hat Software Collections for Red Hat Enterprise Linux 6
rh-php70-php-0:7.0.27-1.el6
Fixed · RHSA-2018:1296
Red Hat Software Collections for Red Hat Enterprise Linux 6.7 EUS
rh-php70-php-0:7.0.27-1.el6
Fixed · RHSA-2018:1296
Red Hat Software Collections for Red Hat Enterprise Linux 7
rh-php70-php-0:7.0.27-1.el7
Fixed · RHSA-2018:1296
Red Hat Software Collections for Red Hat Enterprise Linux 7.3 EUS
rh-php70-php-0:7.0.27-1.el7
Fixed · RHSA-2018:1296
Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
rh-php70-php-0:7.0.27-1.el7
Fixed · RHSA-2018:1296
Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
rh-php70-php-0:7.0.27-1.el7
Fixed · RHSA-2018:1296
Red Hat Enterprise Linux 5
php
Will not fix
Red Hat Enterprise Linux 5
php53
Will not fix
Red Hat Enterprise Linux 6
php
Will not fix
Red Hat OpenShift Enterprise 2
php
Will not fix
Red Hat Software Collections
rh-php56-php
Will not fix
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Enterprise Linux 7 | php-0:5.4.16-43.el7_4.1 | Fixed | RHSA-2018:0406 |
| Red Hat Software Collections for Red Hat Enterprise Linux 6 | rh-php70-php-0:7.0.27-1.el6 | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux 6.7 EUS | rh-php70-php-0:7.0.27-1.el6 | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7 | rh-php70-php-0:7.0.27-1.el7 | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.3 EUS | rh-php70-php-0:7.0.27-1.el7 | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS | rh-php70-php-0:7.0.27-1.el7 | Fixed | RHSA-2018:1296 |
| Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS | rh-php70-php-0:7.0.27-1.el7 | Fixed | RHSA-2018:1296 |
| Red Hat Enterprise Linux 5 | php | Will not fix | n/a |
| Red Hat Enterprise Linux 5 | php53 | Will not fix | n/a |
| Red Hat Enterprise Linux 6 | php | Will not fix | n/a |
| Red Hat OpenShift Enterprise 2 | php | Will not fix | n/a |
| Red Hat Software Collections | rh-php56-php | Will not fix | n/a |
No package ranges for this CVE.
Remediation
Red Hat statement
Red Hat Product Security has rated this issue as having Moderate security impact. This issue is not currently planned to be addressed in future updates. We recommend avoiding usage of the functions gdImageCreateFromGifCtx() and imagecreatefromstring() as they can lead to stack data leak. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/.
Metrics
No CVSS v4.0 score for this CVE.
No CVSS v3.1 score for this CVE.
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N
1 other source (Red Hat) ▾
CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N
AV:N/AC:M/Au:N/C:P/I:N/A:N
This CVE is not in the KEV list.
No CISA SSVC assessment for this CVE yet.
Estimated probability of exploitation in the wild in the next 30 days (FIRST EPSS). As of Oct 1, 2026.
Score over time
2021–2026- EPSS v1
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Percentile over time
- EPSS v1
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Table of values (29 key points)
Flat stretches are collapsed; showing up to 120 newest points.
| Date | Score | Percentile | Model |
|---|---|---|---|
| Oct 1, 2026 | 3.42% (0.03418) | 88.50th | v5 (v2026.06.15) |
| Jun 15, 2026 | 3.42% (0.03418) | 87.31th | v5 (v2026.06.15) |
| Apr 22, 2026 | 30.22% (0.30217) | 96.70th | v4 (v2025.03.14) |
| Apr 13, 2026 | 28.06% (0.28056) | 96.47th | v4 (v2025.03.14) |
| Feb 19, 2026 | 25.33% (0.25333) | 96.08th | v4 (v2025.03.14) |
| Dec 28, 2025 | 19.47% (0.19468) | 95.19th | v4 (v2025.03.14) |
| Dec 27, 2025 | 4.52% (0.04521) | 88.83th | v4 (v2025.03.14) |
| Nov 21, 2025 | 19.88% (0.19879) | 95.22th | v4 (v2025.03.14) |
| Nov 18, 2025 | 5.62% (0.05616) | 89.38th | v4 (v2025.03.14) |
| Nov 1, 2025 | 19.88% (0.19879) | 95.25th | v4 (v2025.03.14) |
| Oct 28, 2025 | 17.32% (0.17315) | 94.74th | v4 (v2025.03.14) |
| Oct 27, 2025 | 3.92% (0.03917) | 87.81th | v4 (v2025.03.14) |
| Oct 1, 2025 | 19.47% (0.19468) | 95.22th | v4 (v2025.03.14) |
| Jul 30, 2025 | 4.52% (0.04521) | 88.71th | v4 (v2025.03.14) |
| Jun 21, 2025 | 19.47% (0.19468) | 95.08th | v4 (v2025.03.14) |
| May 30, 2025 | 11.10% (0.11100) | 93.08th | v4 (v2025.03.14) |
| Mar 17, 2025 | 3.88% (0.03880) | 87.47th | v4 (v2025.03.14) |
| Dec 17, 2024 | 12.24% (0.12238) | 95.37th | v3 (v2023.03.01) |
| May 8, 2023 | 29.79% (0.29787) | 96.26th | v3 (v2023.03.01) |
| Mar 22, 2023 | 31.63% (0.31630) | 96.28th | v3 (v2023.03.01) |
| Mar 7, 2023 | 44.83% (0.44830) | 96.78th | v3 (v2023.03.01) |
| Mar 6, 2023 | 1.54% (0.01537) | 74.52th | v2 (v2022.01.01) |
| Feb 23, 2023 | 1.54% (0.01537) | 74.48th | v2 (v2022.01.01) |
| Apr 1, 2022 | 1.54% (0.01537) | 72.41th | v2 (v2022.01.01) |
| Feb 4, 2022 | 1.54% (0.01537) | 51.33th | v2 (v2022.01.01) |
| Feb 3, 2022 | 2.27% (0.02273) | 50.89th | v1 |
| Jan 6, 2022 | 2.27% (0.02273) | 50.38th | v1 |
| Sep 1, 2021 | 2.27% (0.02273) | 77.89th | v1 |
| Apr 14, 2021 | 2.27% (0.02273) | 0.00th | v1 |
References (14)
- http://php.net/ChangeLog-5.php x_refsource_CONFIRMRelease NotesVendor Advisory
- http://php.net/ChangeLog-7.php x_refsource_CONFIRMRelease NotesVendor Advisory
- http://www.debian.org/security/2017/dsa-3938 vendor-advisoryx_refsource_DEBIAN
- http://www.securityfocus.com/bid/99492 vdb-entryx_refsource_BIDThird Party AdvisoryVDB Entry
- https://access.redhat.com/errata/RHSA-2018:0406 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/errata/RHSA-2018:1296 vendor-advisoryx_refsource_REDHAT
- https://access.redhat.com/security/cve/CVE-2017-7890 Vendor Advisory
- https://bugs.php.net/bug.php?id=74435 x_refsource_CONFIRMPatchVendor Advisory
- https://bugs.php.net/patch-display.php?bug=74435&patch=fix-74435-php-7.0&revision=1497970038 x_refsource_CONFIRMIssue TrackingPatchVendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=1473822 Issue Tracking
- https://nvd.nist.gov/vuln/detail/CVE-2017-7890
- https://security.netapp.com/advisory/ntap-20180112-0001/ x_refsource_CONFIRM
- https://www.cve.org/CVERecord?id=CVE-2017-7890
- https://www.tenable.com/security/tns-2017-12 x_refsource_CONFIRM
Change history (0)
No recorded changes yet.