CVE-2026-125255: FFmpeg use-after-free in MJPEG decoder with hardware acceleration

CVE-2026-125255 · Severity: medium · CVSS 5.3 · Published 2026-11-09

FFmpeg is a multimedia library used by many applications to decode video formats. A use-after-free vulnerability in its MJPEG decoder can be triggered by crafted video streams, allowing attackers to crash applications or leak sensitive data from memory. The issue occurs when hardware video acceleration (like NVIDIA's NVDEC) is in use.

Technologies: Ffmpeg. Vendors: Ffmpeg.

Quick answers

Is CVE-2026-125255 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-125255 being exploited in the wild.
How severe is CVE-2026-125255?
Medium severity, with a CVSS score of 5.3, published 9 November 2026.
Which products and versions are affected?
Ffmpeg through 9.0.2.
Is there a fix for CVE-2026-125255?
Yes: fixed in FFmpeg 9.1. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-125255 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-125255?
Check whether you run Ffmpeg at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • Fixed in: FFmpeg 9.1

Technical details

A use-after-free exists in libavcodec/mjpegdec.c where the ff_mjpeg_decode_sof() function passes a stale raw_image_buffer pointer to hwaccel decoders after the buffer has been freed. The vulnerability is triggered by sending a Start-of-Frame (SOF) marker without a preceding Start-of-Image (SOI) marker in an MJPEG stream. Attackers can supply crafted MJPEG streams to cause heap buffer reads or application crashes.

Affected products

  • FFmpeg FFmpeg through 9.0.2

Timeline

  • 2026-11-09: disclosed
  • 2026-10-27: patched

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.