Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2026-40494— SAIL has heap buffer overflow in TGA RLE decoder — raw packet path missing bounds check

Quick assessment

Affected
HappySeaFox sail
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

SAIL是SAIL开源的一款图像解码库。 SAIL存在安全漏洞,该漏洞源于TGA编解码器的RLE解码器存在不对称边界检查,可能导致堆缓冲区溢出。

CVSS 9.8 · Critical EPSS 0.31% · P24

Possible ATT&CK Techniques 1 AI

T1190 · Exploit Public-Facing Application
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2026-40494

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
SAIL has heap buffer overflow in TGA RLE decoder — raw packet path missing bounds check
Source: CVE Program / CVE List V5
Vulnerability Description
SAIL is a cross-platform library for loading and saving images with support for animation, metadata, and ICC profiles. Prior to commit 45d48d1f2e8e0d73e80bc1fd5310cb57f4547302, the TGA codec's RLE decoder in `tga.c` has an asymmetric bounds check vulnerability. The run-packet path (line 297) correctly clamps the repeat count to the remaining buffer space, but the raw-packet path (line 305-311) has no equivalent bounds check. This allows writing up to 496 bytes of attacker-controlled data past the end of a heap buffer. Commit 45d48d1f2e8e0d73e80bc1fd5310cb57f4547302 patches the issue.
Source: CVE Program / CVE List V5
CVSS Information
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Source: CVE Program / CVE List V5
Vulnerability Type
跨界内存写
Source: CVE Program / CVE List V5
Vulnerability Title
SAIL 安全漏洞
Source: CNNVD (China National Vulnerability Database)
Vulnerability Description
SAIL是SAIL开源的一款图像解码库。 SAIL存在安全漏洞,该漏洞源于TGA编解码器的RLE解码器存在不对称边界检查,可能导致堆缓冲区溢出。
Source: CNNVD (China National Vulnerability Database)
CVSS Information
N/A
Source: CNNVD (China National Vulnerability Database)
Vulnerability Type
N/A
Source: CNNVD (China National Vulnerability Database)

Shenlong Deep Dive — AI Deep Analysis

10-question deep dive: root cause, exploitation, mitigation, urgency. Read summary free, full version requires login.

Affected Products

Vendor Product Affected Versions CPE Subscribe
HappySeaFox sail < 45d48d1f2e8e0d73e80bc1fd5310cb57f4547302 -

II. Public POCs for CVE-2026-40494

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2026-40494

登录查看更多情报信息。

Patches & Fixes for CVE-2026-40494 (1)

Vendor Advisories for CVE-2026-40494 (1)

Same Patch Batch · HappySeaFox · 2026-04-18 · 3 CVEs total

CVE-2026-40493 9.8 CRITICAL SAIL has heap buffer overflow in PSD decoder — bpp mismatch in LAB 16-bit mode
CVE-2026-40492 9.8 CRITICAL SAIL has heap buffer overflow in XWD decoder — bits_per_pixel vs pixmap_depth type confusi

IV. Related Vulnerabilities

V. Comments for CVE-2026-40494

No comments yet


Leave a comment