First published: Fri Oct 20 2023(Updated: )
stb_vorbis is a single file MIT licensed library for processing ogg vorbis files. A crafted file may trigger out of bounds write in `f->vendor[len] = (char)'\0';`. The root cause is that if the len read in `start_decoder` is `-1` and `len + 1` becomes 0 when passed to `setup_malloc`. The `setup_malloc` behaves differently when `f->alloc.alloc_buffer` is pre-allocated. Instead of returning `NULL` as in `malloc` case it shifts the pre-allocated buffer by zero and returns the currently available memory block. This issue may lead to code execution.
Credit: security-advisories@github.com
Affected Software | Affected Version | How to fix |
---|---|---|
Nothings STB | =1.22 |
Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.
CVE-2023-45675 is a vulnerability in the stb_vorbis library that allows for a 0 byte write heap buffer overflow in the start_decoder function.
CVE-2023-45675 has a severity rating of 7.8, which is considered high.
The root cause of CVE-2023-45675 is an out of bounds write in the f->vendor[len] assignment in the start_decoder function.
The stb_vorbis library version 1.22 is affected by CVE-2023-45675.
To fix CVE-2023-45675, it is recommended to update to a patched version of the stb_vorbis library.