Executive brief
FFmpeg, a widely used multimedia framework for processing video and audio, contains a security flaw in its high-quality denoising filter (hqdn3d). An attacker can provide a specially crafted video file that, when processed with specific settings, causes the software to crash or potentially execute unauthorized code. This could lead to a total compromise of the system processing the video or the theft of sensitive data.
Technical details
A heap-based buffer overflow exists in FFmpeg's vf_hqdn3d filter due to improper handling of dynamic frame resolution changes. When filtergraph reinitialization is disabled (via -reinit_filter 0), the vf_hqdn3d.config_input() function may allocate line-history buffers based on an initial small frame size. If a subsequent frame in the same stream has a larger resolution, the denoise_spatial() function writes data into these undersized buffers, leading to an out-of-bounds write. This can result in heap memory corruption, application crashes, or arbitrary code execution. The vulnerability is fixed in commit 5d7112c.
Affected products
- FFmpeg FFmpeg through 8.1.2
Timeline
- 2026-07-12: patched: Fix committed to FFmpeg master branch
- 2026-07-24: disclosed: CVE-2026-66036 published