CVE-2018-5711
published 2018-01-16CVE-2018-5711: 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…
PriorityP431medium5.5CVSS 3.0
AVLACLPRNUIRSUCNINAH
EPSS
13.20%
95.9th percentile
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.
Affected
10 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| canonical | ubuntu_linux | — | — |
| canonical | ubuntu_linux | — | — |
| canonical | ubuntu_linux | — | — |
| debian | debian_linux | — | — |
| debian | debian_linux | — | — |
| debian | libgd2 | < libgd2 2.2.5-4.1 (bookworm) | libgd2 2.2.5-4.1 (bookworm) |
| php | php | <= 5.6.32 | — |
| php | php | <= 7.1.12 | — |
| php | php | — | — |
| php | php | 7.0.0 – 7.0.26 | — |
CVSS provenance
nvdv3.05.5MEDIUMCVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
nvdv2.04.3MEDIUMAV:N/AC:M/Au:N/C:N/I:N/A:P
osv8.8HIGH
vendor_ubuntu8.8HIGH
vendor_debian5.5MEDIUM
vendor_redhat5.5MEDIUM
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
GHSA-qwqg-rff2-45cw: gd_gif_in
ghsa_unreviewed·2022-05-13
CVE-2018-5711 [MEDIUM] CWE-681 GHSA-qwqg-rff2-45cw: gd_gif_in
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.
OSV
libgd2 vulnerabilities
osv·2018-08-27·CVSS 8.8
CVE-2018-1000222 [HIGH] libgd2 vulnerabilities
libgd2 vulnerabilities
It was discovered that GD incorrectly handled certain images.
An attacker could possibly use this issue to execute arbitrary code.
(CVE-2018-1000222)
It was discovered that GD incorrectly handled certain GIF files.
An attacker could possibly use this issue to cause a denial of service.
(CVE-2018-5711)
OSV
CVE-2018-5711: gd_gif_in
osv·2018-01-16·CVSS 5.5
CVE-2018-5711 [MEDIUM] CVE-2018-5711: gd_gif_in
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.
Ubuntu
GD vulnerabilities
vendor_ubuntu·2018-08-27·CVSS 8.8
CVE-2018-1000222 [HIGH] GD vulnerabilities
Title: GD vulnerabilities
Summary: Several security issues were fixed in GD.
It was discovered that GD incorrectly handled certain images.
An attacker could possibly use this issue to execute arbitrary code.
(CVE-2018-1000222)
It was discovered that GD incorrectly handled certain GIF files.
An attacker could possibly use this issue to cause a denial of service.
(CVE-2018-5711)
Instructions: In general, a standard system update will make all the necessary changes.
Debian
CVE-2018-5711: libgd2 - gd_gif_in.c in the GD Graphics Library (aka libgd), as used in PHP before 5.6.33...
vendor_debian·2018·CVSS 5.5
CVE-2018-5711 [MEDIUM] CVE-2018-5711: libgd2 - gd_gif_in.c in the GD Graphics Library (aka libgd), as used in PHP before 5.6.33...
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.
Scope: local
bookworm: resolved (fixed in 2.2.5-4.1)
bullseye: resolved (fixed in 2.2.5-4.1)
forky: resolved (fixed in 2.2.5-4.1)
sid: resolved (fixed in 2.2.5-4.1)
trixie: resolved (fixed in 2.2.5-4.1)
Red Hat
gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
vendor_redhat·2017-11-25·CVSS 5.5
CVE-2018-5711 [MEDIUM] CWE-835 gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
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.
A flaw was found in libgd in PHP, where an infinite loop in the GD GIF core parsing function can lead to a denial of service, a remote attacker could exploit this vulnerability to exhaust server resources by providing specially crafted GIF files.
Statement: This vulnerability is rated as low severity because it causes an infinite loop, resulting in a
No detection rules found.
No public exploits indexed.
HackerOne
Potential infinite loop in gdImageCreateFromGifCtx!
hackerone·2019-11-12·CVSS 5.5
CVE-2018-5711 [MEDIUM] Potential infinite loop in gdImageCreateFromGifCtx!
Potential infinite loop in gdImageCreateFromGifCtx!
## Description
It is easy to trigger in web application if the web use GD as its image library.
For example, It can be triggered if a website resize the user-uploaded GIF, and **ALL** PHP version are affected!
## Original bug report
- https://bugs.php.net/bug.php?id=75571
## Note
- CVE-2018-5711 assigned
Thanks :)
## Impact
A malicious GIF can trigger an infinite loop and lead to exhausted the server resource!
Bugzilla
CVE-2018-5711 php: gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c [fedora-all]
bugzilla·2018-01-16·CVSS 5.5
CVE-2018-5711 [MEDIUM] CVE-2018-5711 php: gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c [fedora-all]
CVE-2018-5711 php: gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c [fedora-all]
This is an automatically created tracking bug! It was created to ensure
that one or more security vulnerabilities are fixed in affected versions
of fedora-all.
For comments that are specific to the vulnerability please use bugs filed
against the "Security Response" product referenced in the "Blocks" field.
For more information see:
http://fedoraproject.org/wiki/Security/TrackingBugs
When submitting as an update, use the fedpkg template provided in the next
comment(s). This will include the bug IDs of this tracking bug as well as
the relevant top-level CVE bugs.
Please also mention the CVE IDs being fixed in the RPM changelog and the
fedpkg commit message.
NOTE: this issue affects multiple su
Bugzilla
CVE-2018-5711 gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
bugzilla·2018-01-16·CVSS 5.5
CVE-2018-5711 [MEDIUM] CVE-2018-5711 gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
CVE-2018-5711 gd: Infinite loop in gdImageCreateFromGifCtx() in gd_gif_in.c
A flaw was found libgd in PHP that affects all versions. An infinite loop in GD GIF core parsing function that results in a Denial of Service and exhausted the server resources.
References:
http://php.net/ChangeLog-5.php#5.6.33
https://bugs.php.net/bug.php?id=75571
Patch:
https://bugs.php.net/patch-display.php?bug=75571&patch=fix-75571&revision=1511981663
Discussion:
Created php tracking bugs for this issue:
Affects: fedora-all [bug 1535247]
---
This issue has been addressed in the following products:
Red Hat Software Collections for Red Hat Enterprise Linux 6
Red Hat Software Collections for Red Hat Enterprise Linux 6.7 EUS
Red Hat Software Collections for Red Hat Enterprise Linux 7
Red Hat Software Colle
http://php.net/ChangeLog-5.phphttp://php.net/ChangeLog-7.phphttps://access.redhat.com/errata/RHSA-2018:1296https://access.redhat.com/errata/RHSA-2019:2519https://bugs.php.net/bug.php?id=75571https://lists.debian.org/debian-lts-announce/2018/01/msg00022.htmlhttps://lists.debian.org/debian-lts-announce/2019/01/msg00028.htmlhttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/https://security.gentoo.org/glsa/201903-18https://usn.ubuntu.com/3755-1/https://www.oracle.com/security-alerts/cpuapr2020.htmlhttp://php.net/ChangeLog-5.phphttp://php.net/ChangeLog-7.phphttps://access.redhat.com/errata/RHSA-2018:1296https://access.redhat.com/errata/RHSA-2019:2519https://bugs.php.net/bug.php?id=75571https://lists.debian.org/debian-lts-announce/2018/01/msg00022.htmlhttps://lists.debian.org/debian-lts-announce/2019/01/msg00028.htmlhttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/3CZ2QADQTKRHTGB2AHD7J4QQNDLBEMM6/https://security.gentoo.org/glsa/201903-18https://usn.ubuntu.com/3755-1/https://www.oracle.com/security-alerts/cpuapr2020.html
2018-01-16
Published