FFmpeg's MagicYUV decoder in libavcodec contains a heap out-of-bounds write ("PixelSmash", CVE-2026-8461) caused by a mismatch between how frame buffers are allocated and how the decoder computes subsampled chroma-plane heights for video slices. Processing a specially crafted AVI, MKV, or MOV file triggers a one-row heap overflow that can be escalated from a crash to reliable remote code execution. Because FFmpeg's libavcodec is embedded in a huge range of software (media servers, file managers, cloud transcoding pipelines, IoT devices), a single malicious ~50 KB video file can compromise any system that processes it — including automatically, via thumbnail generation, metadata extraction, or library-scan features, without the user ever opening the file.
Steps to reproduce:
- Craft an AVI, MKV, or MOV container with a MagicYUV-encoded video stream containing a malformed
slice_heightvalue. - Deliver the file to a target that processes it with a vulnerable FFmpeg/libavcodec build — e.g. upload it to a Jellyfin media server (triggers via automatic library scan) or a Nextcloud instance (triggers via the video preview provider).
- The decoder's chroma-plane height computation overflows the allocated frame buffer by one row per slice, corrupting adjacent heap memory.
- With a crafted overflow payload, this heap corruption is escalated to arbitrary remote code execution on the host.
Workaround: Rebuild FFmpeg with the MagicYUV decoder disabled (--disable-decoder=magicyuv), since it is rarely needed in practice. A minimal 7-line source patch validating slice-height alignment is also available for those who cannot fully upgrade.
Severity: Critical (unauthenticated, no user-interaction-required remote code execution, reachable via automated processing paths like thumbnail/library scans, in a library embedded across a huge swath of widely deployed media software including Jellyfin, mpv, Nextcloud, Immich, OBS, and vLLM)
First seen: 2026-05-13 (reported to FFmpeg security team by JFrog; publicly disclosed 2026-06-22)
Affected product: FFmpeg
Affected platforms: All platforms
Affected versions: FFmpeg versions prior to 8.1.2
Fixed versions: 8.1.2 (released 2026-06-17)
Links:
- AI-Enabled Security Researchers Discover How a Crafted Video Can Provide Attackers Access to Your PC — InfoQ (2026-07)
- PixelSmash (CVE-2026-8461): Critical FFmpeg Flaw — JFrog (2026-06-22)
- FFmpeg fixes PixelSmash flaw in widely used video decoder — BleepingComputer
- FFmpeg PixelSmash Flaw Allows RCE on Video Players, Media Servers, NAS Appliances — SecurityWeek
- FFmpeg PixelSmash Vulnerability Enables Remote Code Execution — eSecurity Planet
- FFmpeg vulnerability 'PixelSmash' could enable RCE via video file — SC World
- Watch video, get pwned: critical FFmpeg vulnerability realizes the worst pirates' fears — Cybernews