JLSEC-2026-2223: FFmpeg before 9.1 contains an out-of-bounds read vulnerability in xwd_encode_frame() in...
FFmpeg before 9.1 contains an out-of-bounds read vulnerability in xwdencodeframe() in libavcodec/xwdenc.c that copies each RGB24 or BGR24 row using the padded XWD scanline size instead of the pixel row size. Attackers who control the width of video encoded to XWD by an application that supplies tightly packed frames can make the encoder read past the frame buffer, crashing the application or leaking heap contents into the output image.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
julia/FFMPEG_jllto a version that resolves this vulnerability.Fixed in 9.1.0+0 - Upgrade
Upgrade
julia/FFMPEG_nogpl_jllto a version that resolves this vulnerability.Fixed in 9.1.0+0
Event History
Child vulnerabilities
Contains the following vulnerabilities.
Frequently Asked Questions
Which applications are realistically exposed to this issue?
Applications using the affected Julia FFmpeg packages are exposed when they encode attacker-influenced RGB24 or BGR24 video frames to XWD and provide those frames as tightly packed buffers. The impact can be an application crash or heap data disclosure through the generated XWD image.
What must an attacker control to trigger the vulnerability?
The attacker needs to influence the width of video being encoded to XWD. Exploitation also depends on the application supplying tightly packed RGB24 or BGR24 frames to the encoder.
Are all XWD encoding workloads affected?
No. The described condition specifically involves RGB24 or BGR24 input frames that are tightly packed. The issue occurs because the encoder copies using the padded XWD scanline size rather than the pixel row size.
What can be done if upgrading is not immediately possible?
Avoid encoding attacker-controlled RGB24 or BGR24 frames to XWD, particularly where an attacker can influence frame width. Restricting or validating attacker-controlled dimensions can reduce exposure.