CVE-2021-40812: libgd Out-of-bounds Read
Vulnerability summary
CVE-2021-40812 is a medium (CVSS 6.5) Out-of-bounds Read vulnerability in libgd. EPSS estimates a 1.66% chance of exploitation in the next 30 days, higher than 76.6% of scored vulnerabilities.
Not severe (CVSS 6.5, network access); no exploitation reported by the 5 checked sources
Source freshness unavailable
How is this decided?Advisory lineage
Upstream 0 · Downstream 2Timeline
- 08-09-2021PublishedVulnerability first disclosed.
- 29-10-2024Last modifiedVulnerability information updated.
Description
The GD Graphics Library (aka LibGD) through 2.3.2 has an out-of-bounds read because of the lack of certain gdGetBuf and gdPutBuf return value checks.
CVSS metrics
5 scores · 4 sources · 2 versions- OSV · UbuntuEcosystem advisory · calculated6.5MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
- OSV · DebianEcosystem advisory · calculated6.5MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
- NVDNIST6.5MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
EPSS trend
Probability
1.66%
Chance of exploitation in the next 30 days
Percentile
77%
Versus all other CVEs
30-day change
No change 0.00 pp
From 1.66% on 04-10-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, no authentication, user interaction (CVSS vector). Other conditions: not stated in public data.
Suse10 products
- gd&distro=SUSE Linux Enterprise Module for Basesystem 15 SP2< 2.2.5-11.3.1
- gd&distro=SUSE Linux Enterprise Module for Basesystem 15 SP3< 2.2.5-11.3.1
- gd&distro=SUSE Linux Enterprise Module for Desktop Applications 15 SP2< 2.2.5-11.3.1
- gd&distro=SUSE Linux Enterprise Module for Desktop Applications 15 SP3< 2.2.5-11.3.1
- gd&distro=SUSE Linux Enterprise Module for Package Hub 15 SP2< 2.2.5-11.3.1
Debian1 product
- libgd2< 2.3.3-1
Libgd1 product
- libgd≤ 2.3.2
Mageia1 product
- libgd< 2.3.1-1.3.mga8
Opensuse1 product
- gd&distro=openSUSE Leap 15.3< 2.2.5-11.3.1
Ubuntu1 product
- libgd2< 2.1.1-4ubuntu0.16.04.12+esm4 | < 2.2.5-4ubuntu0.5+esm3 | < 2.2.5-5.2ubuntu2.4 | < 2.3.0-2ubuntu2.3 | All versions (No fix recorded)
6 vendors · 15 products