SDL_image has a heap buffer overflow READ via unchecked colormap index in XCF loader
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- —
- Confidentiality · integrity · availability
- High · None · Low
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA.
Summary
SDL_image is a library to load images of various formats as SDL surfaces. In do_layer_surface() in src/IMG_xcf.c, pixel index values from decoded XCF tile data are used directly as colormap indices without validating them against the colormap size (cm_num). A crafted .xcf file with a small colormap and out-of-range pixel indices causes heap out-of-bounds reads of up to 762 bytes past the colormap allocation. Both IMAGE_INDEXED code paths are affected (bpp=1 and bpp=2). The leaked heap bytes are written into the output surface pixel data, making them potentially observable in the rendered image. This vulnerability is fixed with commit 996bf12888925932daace576e09c3053410896f8.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| libsdl-org | SDL_image | before 996bf12 | 996bf12 | Patch available | CNA |
- SDL_image Vendorlibsdl-org Affected before 996bf12 Fixed in 996bf12 Patch available CNA
Remediation
- Fix · CNA SDL_image (libsdl-org) Fixed in 996bf12
Vendor assessments
Timeline
- 2026-10-02 Threatist record created from CVE-2026-35444
More libsdl-org vulnerabilities
- TI-2026-81161 Stack out-of-bounds read in SDL_image ILBM loader CVSS 4.0MEDIUM 6.9
- TI-2026-85474 Stack-based buffer overflow in SDL_mixer AIFF decoder CVSS 4.0HIGH 8.5
- TI-2026-85473 Stack-based buffer overflow in SDL_mixer WAV decoder CVSS 4.0HIGH 8.5
Sources
- CVE-2026-35444 · CVE Program
- CVE-2026-35444 · NVD
- FIRST EPSS
- CVE-2026-35444 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences