CVE-2018-5711
A public proof of concept exists; no exploitation attested.
- Published2018-01-16
- WeaknessCWE-681 · CWE-835
Am I affected?
Debian, Ubuntu or Red Hat sometimes backport a fix without changing the upstream version number: such a version reads « to verify », never « affected ».With a domain, we read the version its public headers and pages expose. A distribution build can carry the fix under an older number.
Description
gd_gif_in.c in the GD Graphics Library (aka libgd), as used in PHP before 5.6.33, 7.0.x before 7.0.27, 7.1.x before 7.1.13, and 7.2.x before 7.2.1, has an integer signedness error that leads to an infinite loop via a crafted GIF file, as demonstrated by a call to the imagecreatefromgif or imagecreatefromstring PHP function. This is related to GetCode_ and gdImageCreateFromGifCtx.
Timeline
dates in UTC- 2018-01-1609:29CVE publishedNVD
- 2026-10-2319:23First public proof of conceptPoC-in-GitHub
- 2026-10-2319:23EPSS crossed 10 %FIRST EPSS
Versions per branch
NVD| Branch | Affected | Fixed in | Source |
|---|---|---|---|
| 5.6 | ≤ 5.6.32 | no fix published | NVD |
| 7.0 | ≥ 7.0.0, ≤ 7.0.26 | no fix published | NVD |
| 7.1 | > 7.1.0, ≤ 7.1.12 | no fix published | NVD |
| 7.2 | = 7.2.0 | no fix published | NVD |
| Branch | Affected | Fixed in | Source |
|---|---|---|---|
| 14.4 | = 14.04 | no fix published | NVD |
| 16.4 | = 16.04 | no fix published | NVD |
| 18.4 | = 18.04 | no fix published | NVD |
| Branch | Affected | Fixed in | Source |
|---|---|---|---|
| 7.0 | = 7.0 | no fix published | NVD |
| 8.0 | = 8.0 | no fix published | NVD |
as publishedRanges as NVD and OSV publish them; a distribution’s build can be fixed under an older number.
Distribution builds and vendor advisories
Packages from OSV.dev and products from the vendors' CSAF advisories.
version not verifiedVersions not verified: read as OSV.dev and the vendors publish them, not checked against each vendor's release list.
Packages
- gdSUSE:Linux Enterprise Workstation Extension 12 SP3all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Workstation Extension 12 SP2all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Software Development Kit 12 SP3all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Software Development Kit 12 SP2all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Software Development Kit 11 SP4all versions · fixed in 2.0.36.RC1-52.33.5.1
- gdSUSE:Linux Enterprise Server for SAP Applications 12 SP3all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Server for SAP Applications 12 SP2all versions · fixed in 2.1.0-24.6.1
- gdSUSE:Linux Enterprise Server for SAP Applications 11 SP4all versions · fixed in 2.0.36.RC1-52.33.5.1
63 more package ranges on OSV.dev
Vendor advisories
gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
php.src as a component of Red Hat Enterprise Linux 5 · php53.src as a component of Red Hat Enterprise Linux 5 · gd-devel as a component of Red Hat Enterprise Linux 6 · +93 more
Red Hat Security Advisory: rh-php71-php security, bug fix, and enhancement update
Red Hat Security Advisory: rh-php70-php security, bug fix, and enhancement update
Fix
- Vendor fix Red Hat Product Security RHSA-2019:2519 · 486 productsFor details on how to apply this update, which includes the changes described in this advisory, refer to: https://access.redhat.com/articles/11258 After installing the updated packages, the httpd daemon must be restarted for the update to take effect.
- No fix available, says the vendor Red Hat Product Security CVE-2018-5711 · 7 productsFix deferred
- No fix planned, says the vendor Red Hat Product Security CVE-2018-5711 · 3 productsOut of support scope
- No fix planned, says the vendor Red Hat Product Security CVE-2018-5711 · 86 productsWill not fix
Advisories and patches
- php.netRelease Notes · Vendor Advisory
- php.netRelease Notes · Vendor Advisory
- bugs.php.netPatch · Vendor Advisory
Detection
read 2026-11-01 01:02 UTC- Nuclei template
- none so far ProjectDiscovery
- Exploit-DB
- no entry Exploit-DB
- Proof of concept
- PoC-in-GitHub2 repositories, unverifiedknown since 2026-11-01huzhenghui/Test-7-2-0-PHP-CVE-2018-5711huzhenghui/Test-7-2-1-PHP-CVE-2018-5711
- Metasploit modules
- none listed Metasploit Framework
Sources
- NVDCVSS 3.05.5read 2026-10-23
- NVDCVSS 2.04.3read 2026-10-23
- NVDweakness (CWE)CWE-681, CWE-835read 2026-10-23
- FIRST EPSSEPSS score13.2 %read 2026-11-09
- PoC-in-GitHubproof of concept2known since 2026-11-01
- OSVaffected packages—
- GitHub Advisoriesadvisory—
Identifiers
- EUVD-2018-17480same flawENISA EUVD · LicenseRef-ENISA-legal-notice
- GHSA-qwqg-rff2-45cwsame flawGitHub Advisory Database · CC-BY-4.0
- DLA-1248-1advisory covering several CVEsDebian · LicenseRef-unstated
- DLA-1651-1advisory covering several CVEsDebian · LicenseRef-unstated
- DSA-4080-1advisory covering several CVEsDebian · LicenseRef-unstated
- DSA-4081-1advisory covering several CVEsDebian · LicenseRef-unstated
- MGASA-2018-0367advisory covering several CVEsMageia · LicenseRef-unstated
- openSUSE-SU-2024:10777-1advisory covering several CVEsopenSUSE · LicenseRef-unstated
- RHSA-2018:1296advisory covering several CVEsRed Hat · CC-BY-4.0
- RHSA-2019:2519advisory covering several CVEsRed Hat · CC-BY-4.0
- SUSE-SU-2018:0216-1advisory covering several CVEsSUSE · LicenseRef-unstated
- SUSE-SU-2018:0235-1advisory covering several CVEsSUSE · LicenseRef-unstated
- SUSE-SU-2018:0260-1advisory covering several CVEsSUSE · LicenseRef-unstated
- SUSE-SU-2018:0308-1advisory covering several CVEsSUSE · LicenseRef-unstated
- SUSE-SU-2018:0806-1advisory covering several CVEsSUSE · LicenseRef-unstated
- USN-3755-1advisory covering several CVEsUbuntu
Technical details
- CVSS v3 Vector
- CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
- Published
- 2018-01-16
- Last Modified
- 2026-06-17
- NVD status
- Modified
- GitHub Advisory
- GHSA-qwqg-rff2-45cw
Frequently asked questions
What is CVE-2018-5711?
Is CVE-2018-5711 actively exploited?
What is the CVSS score for CVE-2018-5711?
Running gd? Hear about its next vulnerability
Surveillance reads the versions in your stack — a domain, a lockfile or a list — checks each CVE against the ranges its sources publish, and alerts you when one you run is exploited or enters CISA KEV. A version it cannot read stays « version not verified ».
No credit card required · No monthly cap on website lookups · 250 API requests/month
Go further
- Following what attackers exploit right now? The CISA KEV additions of the month, with their patch deadlines.
- Running this software? Vulnerability monitoring alerts you to new vulnerabilities in your products.
Related vulnerabilities
Same product first, then the same vendor advisory and the same publication week.
Sources for this record
- CVE Program · CVE Program Terms of Use
- ENISA EU Vulnerability Database · ENISA legal notice §1.2 (reproduction authorised, provided the source is acknowledged)
- FIRST EPSS · EPSS terms of use (free use, attribution requested)
- GitHub Advisory Database · CC-BY-4.0 · GHSA-qwqg-rff2-45cw
- NVD · Public domain (17 U.S.C. § 105) for NVD-authored data; third-party content under its own terms
- OSV.dev · Per record, as its publisher states it: each row carries the label in sourceLicense when one is served
- PoC-in-GitHub · CC0-1.0
- Red Hat Product Security (CSAF and VEX) · CC-BY-4.0