Description
Buffer overflow in the LWZReadByte function in IMG_gif.c in SDL_image before 1.2.7 allows remote attackers to cause a denial of service (application crash) or possibly execute arbitrary code via a crafted GIF file, a similar issue to CVE-2006-4484. NOTE: some of these details are obtained from third party information.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | sdl-image1.2 | 1.2.6-2 | — |
| Debian 13 | sdl-image1.2 | 1.2.6-2 | — |
| Debian 12 | sdl-image1.2 | 1.2.6-2 | — |
| Debian 4.0 | sdl-image1.2 | 1.2.5-2etch1 | DSA-1493-2, DSA-1493-1 |
| Debian 3.1 | sdl-image1.2 | 1.2.4-1etch1 | DSA-1493-2, DSA-1493-1 |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
Exploit-DB 1
- SDL_image 1.2.6 - Invalid '.GIF' File LWZ Minimum Code Size Remote Buffer Overflow EDB-31054 · dos · Jan 23, 2008 · verified
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Advisories 2
- DSA-1493-2 sdl-image1.2 - arbitrary code execution Debian Security (DSA / DLA) · Mar 9, 2026
- DSA-1493-1 sdl-image1.2 Debian Security (DSA / DLA) · Mar 9, 2026
References
- http://www.libsdl.org/cgi/viewvc.cgi/trunk/SDL_image/IMG_gif.c?r1=2970&r2=3462
- sdlimage-gif-bo(39865) vdb-entry
- 28869 third-party-advisory
- 28850 third-party-advisory
- FEDORA-2008-1208 vendor-advisory
- 28752 third-party-advisory
- https://issues.rpath.com/browse/RPL-2206
- FEDORA-2008-1231 vendor-advisory
- http://bugs.gentoo.org/show_bug.cgi?id=207933
- http://www.libsdl.org/cgi/viewvc.cgi/trunk/SDL_image/CHANGES?revision=3462&view=markup
- 29542 third-party-advisory
- DSA-1493 vendor-advisory
- 27417 vdb-entry
- 28640 third-party-advisory
- http://wiki.rpath.com/Advisories:rPSA-2008-0061
- 20080213 rPSA-2008-0061-1 SDL_image mailing-list
- 28830 third-party-advisory
- 20080123 SDL_Image 1.2.6 and prior GIF handling buffer overflow mailing-list
- GLSA-200802-01 vendor-advisory
- http://vexillium.org/?sec-sdlgif
- USN-595-1 vendor-advisory
- ADV-2008-0266 vdb-entry
- MDVSA-2008:040 vendor-advisory
- 28837 third-party-advisory