VU#987105: The nothings stb TrueType library, up to version 1.26, contains a heap buffer overflow vulnerability
A heap-buffer-overflow vulnerability exists in the nothings stb TrueType library, up to version 1.26, that is used for parsing TrueType font files. The vulnerability exists in the stbtt__GetGlyphShapeTT() function within the nothings stb_truetype.h library when parsing malformed TTF (TrueType Font) files. The vulnerability resides in the glyph data parsing path. An attacker can craft a malformed TTF file with an inflated endPtsOfContours value and truncate the remaining glyph data. When an application utilizing stb_truetype.h (such as various game engines or graphics software) attempts to load, bake, or render this malformed font via stbtt_GetGlyphShape(), the parser will attempt to read past the end of the glyph data buffer, triggering the out-of-bounds read.
AI Analysis
Technical Summary
The nothings stb TrueType library up to version 1.26 contains a heap buffer overflow vulnerability (CVE-2026-18497) in the stbtt_GetGlyphShape() function. The vulnerability arises during glyph contour parsing when the function iterates based on the number of contour endpoints specified in endPtsOfContours without validating that the points pointer stays within the glyph data buffer bounds. This can lead to out-of-bounds heap reads when processing malformed TrueType Font files crafted with an excessively large endPtsOfContours value and truncated glyph data. The flaw can cause denial of service via application crashes and may allow reading of adjacent heap memory, leading to potential information disclosure. Attempts to coordinate disclosure with the maintainer were unsuccessful, and no official fix is currently available. Users should monitor the GitHub repository for future patches.
Potential Impact
Exploitation can cause application crashes due to invalid memory reads, resulting in denial of service. Additionally, attackers may read adjacent heap memory, potentially leading to information disclosure. There is no evidence of active exploitation in the wild at this time.
Mitigation Recommendations
No official patch or fix is currently available. The maintainer has publicly stated that security fixes may take significant time or may not be merged. Users should monitor the stb GitHub repository for updates and apply any future fixes once released. If the risk posed by this vulnerability is unacceptable, users are advised to avoid using the stb TrueType library until a fix is available.
VU#987105: The nothings stb TrueType library, up to version 1.26, contains a heap buffer overflow vulnerability
Description
A heap-buffer-overflow vulnerability exists in the nothings stb TrueType library, up to version 1.26, that is used for parsing TrueType font files. The vulnerability exists in the stbtt__GetGlyphShapeTT() function within the nothings stb_truetype.h library when parsing malformed TTF (TrueType Font) files. The vulnerability resides in the glyph data parsing path. An attacker can craft a malformed TTF file with an inflated endPtsOfContours value and truncate the remaining glyph data. When an application utilizing stb_truetype.h (such as various game engines or graphics software) attempts to load, bake, or render this malformed font via stbtt_GetGlyphShape(), the parser will attempt to read past the end of the glyph data buffer, triggering the out-of-bounds read.
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The nothings stb TrueType library up to version 1.26 contains a heap buffer overflow vulnerability (CVE-2026-18497) in the stbtt_GetGlyphShape() function. The vulnerability arises during glyph contour parsing when the function iterates based on the number of contour endpoints specified in endPtsOfContours without validating that the points pointer stays within the glyph data buffer bounds. This can lead to out-of-bounds heap reads when processing malformed TrueType Font files crafted with an excessively large endPtsOfContours value and truncated glyph data. The flaw can cause denial of service via application crashes and may allow reading of adjacent heap memory, leading to potential information disclosure. Attempts to coordinate disclosure with the maintainer were unsuccessful, and no official fix is currently available. Users should monitor the GitHub repository for future patches.
Potential Impact
Exploitation can cause application crashes due to invalid memory reads, resulting in denial of service. Additionally, attackers may read adjacent heap memory, potentially leading to information disclosure. There is no evidence of active exploitation in the wild at this time.
Mitigation Recommendations
No official patch or fix is currently available. The maintainer has publicly stated that security fixes may take significant time or may not be merged. Users should monitor the stb GitHub repository for updates and apply any future fixes once released. If the risk posed by this vulnerability is unacceptable, users are advised to avoid using the stb TrueType library until a fix is available.
Technical Details
- Classification
- {"confidence":0.93,"severitySource":"heuristic","classifier":"rss-v2"}
- Article Source
- {"url":"https://kb.cert.org/vuls/id/987105","fetched":true,"fetchedAt":"2026-08-07T14:24:06.371Z","wordCount":557}
Threat ID: 6a75ea86bf8831d5396f0a8f
Added to database: 08/07/2026, 14:24:06 UTC
Last enriched: 08/07/2026, 14:24:16 UTC
Last updated: 08/07/2026, 21:00:31 UTC
Views: 15
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.