ID CVE-2016-3074
Summary Integer signedness error in GD Graphics Library 2.1.1 (aka libgd or libgd2) allows remote attackers to cause a denial of service (crash) or potentially execute arbitrary code via crafted compressed gd2 data, which triggers a heap-based buffer overflow.
References
Vulnerable Configurations
  • libgd libgd 2.1.1
    cpe:2.3:a:libgd:libgd:2.1.1
  • Debian Linux 7.0
    cpe:2.3:o:debian:debian_linux:7.0
  • Debian Linux 8.0 (Jessie)
    cpe:2.3:o:debian:debian_linux:8.0
CVSS
Base: 7.5 (as of 04-05-2016 - 08:41)
Impact:
Exploitability:
CWE CWE-189
CAPEC
Access
VectorComplexityAuthentication
NETWORK LOW NONE
Impact
ConfidentialityIntegrityAvailability
PARTIAL PARTIAL PARTIAL
exploit-db via4
description libgd 2.1.1 - Signedness Heap Overflow. CVE-2016-3074. Remote exploit for linux platform
file exploits/linux/remote/39736.txt
id EDB-ID:39736
last seen 2016-04-26
modified 2016-04-26
platform linux
port
published 2016-04-26
reporter Hans Jerry Illikainen
source https://www.exploit-db.com/download/39736/
title libgd 2.1.1 - Signedness Heap Overflow
type remote
nessus via4
  • NASL family FreeBSD Local Security Checks
    NASL id FREEBSD_PKG_5764C63410D211E694FA002590263BF5.NASL
    description The PHP Group reports : - BCMath : - Fixed bug #72093 (bcpowmod accepts negative scale and corrupts _one_ definition). - Exif : - Fixed bug #72094 (Out of bounds heap read access in exif header processing). - GD : - Fixed bug #71912 (libgd: signedness vulnerability). (CVE-2016-3074) - Intl : - Fixed bug #72061 (Out-of-bounds reads in zif_grapheme_stripos with negative offset). - XML : - Fixed bug #72099 (xml_parse_into_struct segmentation fault).
    last seen 2019-02-21
    modified 2018-11-10
    plugin id 90844
    published 2016-05-03
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90844
    title FreeBSD : php -- multiple vulnerabilities (5764c634-10d2-11e6-94fa-002590263bf5)
  • NASL family Gentoo Local Security Checks
    NASL id GENTOO_GLSA-201607-04.NASL
    description The remote host is affected by the vulnerability described in GLSA-201607-04 (GD: Multiple vulnerabilities) Multiple vulnerabilities have been discovered in GD. Please review the CVE identifiers referenced below for details. Impact : A remote attacker could possibly execute arbitrary code with the privileges of the process, or cause a Denial of Service condition. Workaround : There is no known workaround at this time.
    last seen 2019-02-21
    modified 2016-10-10
    plugin id 92348
    published 2016-07-18
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=92348
    title GLSA-201607-04 : GD: Multiple vulnerabilities
  • NASL family Fedora Local Security Checks
    NASL id FEDORA_2016-0C57B12C7B.NASL
    description Security fix for CVE-2016-3074 Note that Tenable Network Security has extracted the preceding description block directly from the Fedora security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen 2019-02-21
    modified 2016-10-18
    plugin id 90948
    published 2016-05-09
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90948
    title Fedora 24 : gd-2.1.1-7.fc24 (2016-0c57b12c7b)
  • NASL family Debian Local Security Checks
    NASL id DEBIAN_DSA-3556.NASL
    description Hans Jerry Illikainen discovered that libgd2, a library for programmatic graphics creation and manipulation, suffers of a signedness vulnerability which may result in a heap overflow when processing specially crafted compressed gd2 data. A remote attacker can take advantage of this flaw to cause an application using the libgd2 library to crash, or potentially, to execute arbitrary code with the privileges of the user running the application.
    last seen 2019-02-21
    modified 2018-11-10
    plugin id 90688
    published 2016-04-25
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90688
    title Debian DSA-3556-1 : libgd2 - security update
  • NASL family Slackware Local Security Checks
    NASL id SLACKWARE_SSA_2016-120-02.NASL
    description New php packages are available for Slackware 14.0, 14.1, and -current to fix security issues.
    last seen 2019-02-21
    modified 2016-10-19
    plugin id 90801
    published 2016-05-02
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90801
    title Slackware 14.0 / 14.1 / current : php (SSA:2016-120-02)
  • NASL family Junos Local Security Checks
    NASL id JUNIPER_JSA10798.NASL
    description According to its self-reported version number, the remote Juniper Junos device is affected by an integer signedness error in the included GD Graphics Library (libgd) when handling compressed GD2 data due to improper validation of user-supplied input. An unauthenticated, remote attacker can exploit this, via specially crafted compressed GD2 data, to cause a heap-based buffer overflow, resulting in a denial of service condition or the execution of arbitrary code.
    last seen 2019-02-21
    modified 2018-07-13
    plugin id 102073
    published 2017-07-31
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=102073
    title Juniper Junos libgd Compressed GD2 Data RCE (JSA10798)
  • NASL family Fedora Local Security Checks
    NASL id FEDORA_2016-5F91F43826.NASL
    description Security fix for CVE-2016-3074 Note that Tenable Network Security has extracted the preceding description block directly from the Fedora security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen 2019-02-21
    modified 2016-10-18
    plugin id 90812
    published 2016-05-02
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90812
    title Fedora 23 : gd-2.1.1-5.fc23 (2016-5f91f43826)
  • NASL family Fedora Local Security Checks
    NASL id FEDORA_2016-7D6CBCADCA.NASL
    description Security fix for CVE-2016-3074 Note that Tenable Network Security has extracted the preceding description block directly from the Fedora update system website. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen 2019-02-21
    modified 2016-10-18
    plugin id 92118
    published 2016-07-14
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=92118
    title Fedora 22 : gd (2016-7d6cbcadca)
  • NASL family Gentoo Local Security Checks
    NASL id GENTOO_GLSA-201611-22.NASL
    description The remote host is affected by the vulnerability described in GLSA-201611-22 (PHP: Multiple vulnerabilities) Multiple vulnerabilities have been discovered in PHP. Please review the CVE identifiers referenced below for details. Impact : An attacker can possibly execute arbitrary code or create a Denial of Service condition. Workaround : There is no known workaround at this time.
    last seen 2019-02-21
    modified 2016-12-01
    plugin id 95421
    published 2016-12-01
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=95421
    title GLSA-201611-22 : PHP: Multiple vulnerabilities (httpoxy)
  • NASL family SuSE Local Security Checks
    NASL id OPENSUSE-2016-703.NASL
    description This update for php5 fixes the following issues : - CVE-2013-7456: imagescale out-of-bounds read (bnc#982009). - CVE-2016-5093: get_icu_value_internal out-of-bounds read (bnc#982010). - CVE-2016-5094: Don't create strings with lengths outside int range (bnc#982011). - CVE-2016-5095: Don't create strings with lengths outside int range (bnc#982012). - CVE-2016-5096: int/size_t confusion in fread (bsc#982013). - CVE-2016-5114: fpm_log.c memory leak and buffer overflow (bnc#982162). - CVE-2015-8877: The gdImageScaleTwoPass function in gd_interpolation.c in the GD Graphics Library (aka libgd), as used in PHP, used inconsistent allocate and free approaches, which allowed remote attackers to cause a denial of service (memory consumption) via a crafted call, as demonstrated by a call to the PHP imagescale function (bsc#981061). - CVE-2015-8876: Zend/zend_exceptions.c in PHP did not validate certain Exception objects, which allowed remote attackers to cause a denial of service (NULL pointer dereference and application crash) or trigger unintended method execution via crafted serialized data (bsc#981049). - CVE-2015-8879: The odbc_bindcols function in ext/odbc/php_odbc.c in PHP mishandled driver behavior for SQL_WVARCHAR columns, which allowed remote attackers to cause a denial of service (application crash) in opportunistic circumstances by leveraging use of the odbc_fetch_array function to access a certain type of Microsoft SQL Server table Aliased: (bsc#981050). - CVE-2015-4116: Use-after-free vulnerability in the spl_ptr_heap_insert function in ext/spl/spl_heap.c in PHP allowed remote attackers to execute arbitrary code by triggering a failed SplMinHeap::compare operation (bsc#980366). - CVE-2015-8874: Stack consumption vulnerability in GD in PHP allowed remote attackers to cause a denial of service via a crafted imagefilltoborder call (bsc#980375). - CVE-2015-8873: Stack consumption vulnerability in Zend/zend_exceptions.c in PHP allowed remote attackers to cause a denial of service (segmentation fault) via recursive method calls (bsc#980373). - CVE-2016-3074: Integer signedness error in GD Graphics Library (aka libgd or libgd2) allowed remote attackers to cause a denial of service (crash) or potentially execute arbitrary code via crafted compressed gd2 data, which triggers a heap-based buffer overflow (bsc#976775).
    last seen 2019-02-21
    modified 2016-10-13
    plugin id 91585
    published 2016-06-14
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=91585
    title openSUSE Security Update : php5 (openSUSE-2016-703)
  • NASL family CGI abuses
    NASL id PHP_5_5_35.NASL
    description According to its banner, the version of PHP running on the remote web server is 5.5.x prior to 5.5.35. It is, therefore, affected by multiple vulnerabilities : - A signedness error exists in the GD Graphics library within file gd_gd2.c due to improper validation of user-supplied input when handling compressed GD2 data. An unauthenticated, remote attacker can exploit this to cause a heap-based buffer overflow, resulting in a denial of service condition or the execution of arbitrary code. (CVE-2016-3074) - An out-of-bounds read error exists within file ext/intl/grapheme/grapheme_string.c when handling negative offsets in the zif_grapheme_stripos() function. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or disclose memory contents. - An out-of-bounds read error exists in the php_str2num() function within file ext/bcmath/bcmath.c when handling negative scales. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - An out-of-bounds read error exists in the exif_read_data() function within file ext/exif/exif.c when handling exif headers. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - A flaw exists in the xml_parse_into_struct() function within file ext/xml/xml.c when handling specially crafted XML contents. An unauthenticated, remote attacker can exploit this to cause a denial of service condition. Note that Nessus has not tested for these issues but has instead relied only on the application's self-reported version number.
    last seen 2019-02-21
    modified 2019-01-02
    plugin id 90920
    published 2016-05-05
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90920
    title PHP 5.5.x < 5.5.35 Multiple Vulnerabilities
  • NASL family Ubuntu Local Security Checks
    NASL id UBUNTU_USN-2987-1.NASL
    description It was discovered that the GD library incorrectly handled certain color tables in XPM images. If a user or automated system were tricked into processing a specially crafted XPM image, an attacker could cause a denial of service. This issue only affected Ubuntu 12.04 LTS and Ubuntu 14.04 LTS. (CVE-2014-2497) It was discovered that the GD library incorrectly handled certain malformed GIF images. If a user or automated system were tricked into processing a specially crafted GIF image, an attacker could cause a denial of service. This issue only affected Ubuntu 12.04 LTS and Ubuntu 14.04 LTS. (CVE-2014-9709) It was discovered that the GD library incorrectly handled memory when using gdImageFillToBorder(). A remote attacker could possibly use this issue to cause a denial of service. (CVE-2015-8874) It was discovered that the GD library incorrectly handled memory when using gdImageScaleTwoPass(). A remote attacker could possibly use this issue to cause a denial of service. This issue only applied to Ubuntu 14.04 LTS, Ubuntu 15.10 and Ubuntu 16.04 LTS. (CVE-2015-8877) Hans Jerry Illikainen discovered that the GD library incorrectly handled certain malformed GD images. If a user or automated system were tricked into processing a specially crafted GD image, an attacker could cause a denial of service or possibly execute arbitrary code. (CVE-2016-3074). Note that Tenable Network Security has extracted the preceding description block directly from the Ubuntu security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen 2019-02-21
    modified 2018-12-01
    plugin id 91423
    published 2016-06-01
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=91423
    title Ubuntu 12.04 LTS / 14.04 LTS / 15.10 / 16.04 LTS : libgd2 vulnerabilities (USN-2987-1)
  • NASL family Debian Local Security Checks
    NASL id DEBIAN_DSA-3602.NASL
    description Several vulnerabilities were found in PHP, a general-purpose scripting language commonly used for web application development. The vulnerabilities are addressed by upgrading PHP to the new upstream version 5.6.22, which includes additional bug fixes. Please refer to the upstream changelog for more information : - https://php.net/ChangeLog-5.php#5.6.21 - https://php.net/ChangeLog-5.php#5.6.22
    last seen 2019-02-21
    modified 2018-12-18
    plugin id 91615
    published 2016-06-15
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=91615
    title Debian DSA-3602-1 : php5 - security update
  • NASL family CGI abuses
    NASL id PHP_7_0_6.NASL
    description According to its banner, the version of PHP running on the remote web server is 7.0.x prior to 7.0.6. It is, therefore, affected by multiple vulnerabilities : - A signedness error exists in the GD Graphics library within file gd_gd2.c due to improper validation of user-supplied input when handling compressed GD2 data. An unauthenticated, remote attacker can exploit this to cause a heap-based buffer overflow, resulting in a denial of service condition or the execution of arbitrary code. (CVE-2016-3074) - An integer overflow condition exists in ZipArchive in the getFromIndex() and getFromName() functions due to improper validation of user-supplied input when handling specially crafted ZIP files. An unauthenticated, remote attacker can exploit this to cause a heap-based buffer overflow, resulting in a denial of service condition or the execution of arbitrary code. (CVE-2016-3078) - An out-of-bounds read error exists within file ext/intl/grapheme/grapheme_string.c when handling negative offsets in the zif_grapheme_stripos() function. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or disclose memory contents. - An out-of-bounds read error exists in the php_str2num() function within file ext/bcmath/bcmath.c when handling negative scales. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - An out-of-bounds read error exists in the exif_read_data() function within file ext/exif/exif.c when handling exif headers. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - A flaw exists in the xml_parse_into_struct() function within file ext/xml/xml.c when handling specially crafted XML contents. An unauthenticated, remote attacker can exploit this to cause a denial of service condition. Note that Nessus has not tested for these issues but has instead relied only on the application's self-reported version number.
    last seen 2019-02-21
    modified 2019-01-02
    plugin id 90922
    published 2016-05-05
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90922
    title PHP 7.0.x < 7.0.6 Multiple Vulnerabilities
  • NASL family Amazon Linux Local Security Checks
    NASL id ALA_ALAS-2016-698.NASL
    description The following security-related issues were resolved : Buffer over-write in finfo_open with malformed magic file (CVE-2015-8865) Signedness vulnerability causing heap overflow in libgd (CVE-2016-3074) Integer overflow in php_raw_url_encode (CVE-2016-4070) Format string vulnerability in php_snmp_error() (CVE-2016-4071) Invalid memory write in phar on filename containing \\0 inside name (CVE-2016-4072) Negative size parameter in memcpy (CVE-2016-4073)
    last seen 2019-02-21
    modified 2018-04-18
    plugin id 90867
    published 2016-05-04
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90867
    title Amazon Linux AMI : php56 / php55 (ALAS-2016-698)
  • NASL family CGI abuses
    NASL id PHP_5_6_21.NASL
    description According to its banner, the version of PHP running on the remote web server is 5.6.x prior to 5.6.21. It is, therefore, affected by multiple vulnerabilities : - A signedness error exists in the GD Graphics library within file gd_gd2.c due to improper validation of user-supplied input when handling compressed GD2 data. An unauthenticated, remote attacker can exploit this to cause a heap-based buffer overflow, resulting in a denial of service condition or the execution of arbitrary code. (CVE-2016-3074) - An out-of-bounds read error exists within file ext/intl/grapheme/grapheme_string.c when handling negative offsets in the zif_grapheme_stripos() function. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or disclose memory contents. - An out-of-bounds read error exists in the php_str2num() function within file ext/bcmath/bcmath.c when handling negative scales. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - An out-of-bounds read error exists in the exif_read_data() function within file ext/exif/exif.c when handling exif headers. An unauthenticated, remote attacker can exploit this to cause a denial of service condition or the disclosure of memory contents. - A flaw exists in the xml_parse_into_struct() function within file ext/xml/xml.c when handling specially crafted XML contents. An unauthenticated, remote attacker can exploit this to cause a denial of service condition. Note that Nessus has not tested for these issues but has instead relied only on the application's self-reported version number.
    last seen 2019-02-21
    modified 2019-01-02
    plugin id 90921
    published 2016-05-05
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=90921
    title PHP 5.6.x < 5.6.21 Multiple Vulnerabilities
  • NASL family SuSE Local Security Checks
    NASL id OPENSUSE-2016-576.NASL
    description This update for php5 fixes the following issues : - CVE-2016-4073: A remote attacker could have caused denial of service, or possibly execute arbitrary code, due to incorrect handling of string length calculations in mb_strcut() (bsc#977003) - CVE-2016-3074: Signedness vulnerability in bundled libgd may have resulted in a heap overflow when processing compressed gd2 data. (boo#976775) - CVE-2015-8867: The PHP function openssl_random_pseudo_bytes() did not return cryptographically secure random bytes (bsc#977005) - CVE-2016-4070: The libxml_disable_entity_loader() setting was shared between threads, which could have resulted in XML external entity injection and entity expansion issues (bsc#976997) - CVE-2015-8866: A remote attacker could have caused denial of service due to incorrect handling of large strings in php_raw_url_encode() (bsc#976996) - CVE-2016-4071: A remote attacker could have caused denial of service, or possibly execute arbitrary code, due to incorrect handling of string formatting in php_snmp_error() (bsc#977000)
    last seen 2019-02-21
    modified 2016-10-13
    plugin id 91071
    published 2016-05-12
    reporter Tenable
    source https://www.tenable.com/plugins/index.php?view=single&id=91071
    title openSUSE Security Update : php5 (openSUSE-2016-576)
  • NASL family Misc.
    NASL id SECURITYCENTER_PHP_5_6_21.NASL
    description