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.
CVE-2018-5711
Score 5.5 from GitHub Security Advisory published 2022-05-13. NVD baseline CVSS 5.5; sources differ by 0.0.
- Lower severity and no public exploit yet
A fix is available — apply it.
- CVSS v3
- 5.5
- EG Score
- 5.5(medium)
- EPSS
- 95.9%
- KEV
- Not listed
Published
January 16, 2018
Last Modified
November 21, 2024
References (22)
- cve@mitrehttp://php.net/ChangeLog-5.php
- cve@mitrehttp://php.net/ChangeLog-7.php
- cve@mitrehttps://access.redhat.com/errata/RHSA-2018:1296
- cve@mitrehttps://access.redhat.com/errata/RHSA-2019:2519
- cve@mitrehttps://bugs.php.net/bug.php?id=75571
- cve@mitrehttps://lists.debian.org/debian-lts-announce/2018/01/msg00022.html
- cve@mitrehttps://lists.debian.org/debian-lts-announce/2019/01/msg00028.html
- cve@mitrehttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/
- cve@mitrehttps://security.gentoo.org/glsa/201903-18
- cve@mitrehttps://usn.ubuntu.com/3755-1/
- cve@mitrehttps://www.oracle.com/security-alerts/cpuapr2020.html
- af854a3a-2127-422b-91ae-364da2661108http://php.net/ChangeLog-5.php
- af854a3a-2127-422b-91ae-364da2661108http://php.net/ChangeLog-7.php
- af854a3a-2127-422b-91ae-364da2661108https://access.redhat.com/errata/RHSA-2018:1296
- af854a3a-2127-422b-91ae-364da2661108https://access.redhat.com/errata/RHSA-2019:2519
Patch Availability(3)
| Vendor / Ecosystem | Fixed in / Patch | Released | Source |
|---|---|---|---|
| ubuntu | libgd3 (2.1.1-4ubuntu0.16.04.10) @ xenial | 2026-05-28 | ubuntu |
| redhat | rh-php71-php-0:7.1.30-1.el7 | 2019-08-19 | redhat |
| redhat | rh-php70-php-0:7.0.27-1.el7 | 2018-05-03 | redhat |
Patches are aggregated from vendor advisories (Red Hat, Microsoft, Cisco, GitHub) and package ecosystems (OSV, GHSA). Multiple rows for the same upstream release have been deduplicated.
Weakness Classification(2)
MITRE Common Weakness Enumeration — the root-cause categories this CVE belongs to.
All Vendor Advisories
(3)
Every vendor that published an advisory referencing this CVE — pulled from our cve_vendor_advisories aggregation. Click any row for the vendor's original advisory page.
Publicly available exploits
(1 reference)Working exploit code is in the public domain (1 GitHub PoC). Defenders should treat patch urgency accordingly — public PoCs typically lead to mass-exploitation within 24-72 hours.
- Open source ↗GitHub PoChuzhenghui/Test-7-2-0-PHP-CVE-2018-5711First seen Feb 1, 2018
Frequently asked(5)
What is CVE-2018-5711?
When was CVE-2018-5711 disclosed?
Is CVE-2018-5711 actively exploited?
What is the CVSS score of CVE-2018-5711?
How do I remediate CVE-2018-5711?
Dependency Blast Radius
Explore the affected products and dependency analysis for CVE-2018-5711
Is Your Infrastructure Affected by CVE-2018-5711?
EchelonGraph automatically scans your cloud infrastructure and maps CVE exposure using blast radius analysis.