ThorVG: Out-of-bounds Read in SFNT/TTF Font Loader via Memory API
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 1.0.7
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
Summary
ThorVG, a vector graphics engine, is affected in its SFNT/TTF font loading code, where loading a font that is shorter than four bytes directly from memory can read past the end of the buffer. The impact is that a malformed font may crash the application using ThorVG or leak nearby heap memory.
Summarized by anthropic/claude-haiku-5.5. Verify details against the original sources.
Read the original description
Thor Vector Graphics (ThorVG) is a production-ready vector graphics engine. Prior to 1.0.7, the `SFNT/TTF` font loader's `SfntLoader::gen` function in `tvgSfntLoader.cpp` reads `data[0] through data[3]` to identify the font type without first checking that the input buffer contains at least four bytes. Loading an undersized font directly from memory through public APIs such as `tvg::Text::load` causes an out-of-bounds read. Loading through a file path using `mmap` can mask the read because of page alignment; the memory-loading API directly exposes it. Depending on memory layout, a malformed short font may crash the consuming application or disclose adjacent heap memory. This issue is fixed in version 1.0.7.
Timeline
- CVE published
- First seen by cve.now
Affected versions
- thorvg thorvg
fixed in 1.0.7