GD Graphics Library up to 2.2.2 gd_gd2.c _gd2GetHeader integer overflow

CVSS Meta Temp Score
CVSS is a standardized scoring system to determine possibilities of attacks. The Temp Score considers temporal factors like disclosure, exploit and countermeasures. The unique Meta Score calculates the average score of different sources to provide a normalized scoring system.
Current Exploit Price (≈)
Our analysts are monitoring exploit markets and are in contact with vulnerability brokers. The range indicates the observed or calculated exploit price to be seen on exploit markets. A good indicator to understand the monetary effort required for and the popularity of an attack.
CTI Interest Score
Our Cyber Threat Intelligence team is monitoring different web sites, mailing lists, exploit markets and social media networks. The CTI Interest Score identifies the interest of attackers and the security community for this specific vulnerability in real-time. A high score indicates an elevated risk to be targeted for this vulnerability.

A vulnerability, which was classified as critical, has been found in GD Graphics Library up to 2.2.2 (Image Processing Software). Affected by this issue is the function _gd2GetHeader of the file gd_gd2.c. The manipulation with an unknown input leads to a integer overflow vulnerability. Using CWE to declare the problem leads to CWE-190. The product performs a calculation that can produce an integer overflow or wraparound, when the logic assumes that the resulting value will always be larger than the original value. This can introduce other weaknesses when the calculation is used for resource management or execution control. Impacted is confidentiality, integrity, and availability.

The weakness was disclosed 08/07/2016 (Website). The advisory is shared for download at This vulnerability is handled as CVE-2016-5766 since 06/23/2016. The attack may be launched remotely. No form of authentication is required for exploitation. Successful exploitation requires user interaction by the victim. There are known technical details, but no exploit is available.

The vulnerability scanner Nessus provides a plugin with the ID 91839 (FreeBSD : php -- multiple vulnerabilities (66d77c58-3b1d-11e6-8e82-002590263bf5)), which helps to determine the existence of the flaw in a target environment. It is assigned to the family FreeBSD Local Security Checks and running in the context l. The commercial vulnerability scanner Qualys is able to test this issue with plugin 196528 (Ubuntu Security Notification for Libgd2 Vulnerabilities (USN-3030-1)).

Upgrading to version 2.2.3 eliminates this vulnerability. A possible mitigation has been published even before and not after the disclosure of the vulnerability.

The vulnerability is also documented in the vulnerability database at Tenable (91839). The entries 90616, 90633, 90634 and 90635 are pretty similar.






CPE 2.3info

CPE 2.2info


VulDB Meta Base Score: 8.8
VulDB Meta Temp Score: 8.6

VulDB Base Score: 8.8
VulDB Temp Score: 8.4
VulDB Vector: 🔍
VulDB Reliability: 🔍

NVD Base Score: 8.8
NVD Vector: 🔍



VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍

NVD Base Score: 🔍


Class: Integer overflow
CWE: CWE-190 / CWE-189
ATT&CK: Unknown

Local: No
Remote: Yes

Availability: 🔍
Status: Not defined

EPSS Score: 🔍
EPSS Percentile: 🔍

Price Prediction: 🔍
Current Price Estimation: 🔍


Nessus ID: 91839
Nessus Name: FreeBSD : php -- multiple vulnerabilities (66d77c58-3b1d-11e6-8e82-002590263bf5)
Nessus File: 🔍
Nessus Risk: 🔍
Nessus Family: 🔍
Nessus Context: 🔍

OpenVAS ID: 841576
OpenVAS Name: Fedora Update for gd FEDORA-2016-a4d48d6fd6
OpenVAS File: 🔍
OpenVAS Family: 🔍

Qualys ID: 🔍
Qualys Name: 🔍

Threat Intelligenceinfo

Interest: 🔍
Active Actors: 🔍
Active APT Groups: 🔍


Recommended: Upgrade
Status: 🔍

0-Day Time: 🔍

Upgrade: GD Graphics Library 2.2.3


06/23/2016 🔍
06/25/2016 +2 days 🔍
06/27/2016 +2 days 🔍
08/07/2016 +41 days 🔍
08/07/2016 +0 days 🔍
08/08/2016 +1 days 🔍
09/13/2022 +2227 days 🔍


Advisory: USN-3030-1
Status: Not defined
Confirmation: 🔍

CVE: CVE-2016-5766 (🔍)
See also: 🔍


Created: 08/08/2016 03:22 PM
Updated: 09/13/2022 09:04 AM
Changes: 08/08/2016 03:22 PM (64), 03/22/2019 08:42 AM (11), 09/13/2022 09:00 AM (4), 09/13/2022 09:04 AM (1)
Complete: 🔍


No comments yet. Languages: en.

Please log in to comment.

Do you want to use VulDB in your project?

Use the official API to access entries easily!