---
id: "CVE-2026-125246"
page: "https://infrastack.ai/live/CVE-2026-125246"
kind: "vulnerability"
aliases: ["CVE-2026-125246"]
title: "FFmpeg: crafted JPEG stream crashes the process via miscounted stuffing bytes"
severity: "medium"
cvss: 5.7
epss: null
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["ffmpeg", "media-processing", "package", "self-hosted"]
not_affected_if: ["no-untrusted-media", "not-using-cbs-filters"]
published_at: "2026-11-09T19:17:03+00:00"
first_seen_at: "2026-11-09T19:28:21+00:00"
updated_at: "2026-11-09T19:31:56+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-125246", "first_seen_at": "2026-11-09T19:28:21+00:00"}]
exploit_sources: []
---

# FFmpeg: crafted JPEG stream crashes the process via miscounted stuffing bytes

Link for people: https://infrastack.ai/live/CVE-2026-125246 (this .md is for agents)

FFmpeg through 9.0.2 miscounts 0xff stuffing bytes in JPEG scan headers in cbs_jpeg_assemble_fragment(). A crafted JPEG or MJPEG stream triggers an av_assert0 abort, so an attacker can crash any process that processes the file.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Check the installed FFmpeg version with `ffmpeg -version`
- Look for FFmpeg in services that decode or transcode user-supplied JPEG or MJPEG media with CBS-based bitstream filters

## Fix

- Patch: linked from the NVD record (github.com); the fixed version is unknown from the sources

## Timeline

- 2026-11-09T19:28:21+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-125246

## Documents

- [advisory] Third-party advisory: www.vulncheck.com https://www.vulncheck.com/advisories/ffmpeg-through-9.0.2-assertion-failure-dos-via-cbs-jpeg-assemble-fragment
- [fix] Patch: github.com https://github.com/FFmpeg/FFmpeg/commit/ee457fdcdb3a069ef35910a2e1cacff10906b131

## From the sources

FFmpeg through 9.0.2 contains a denial of service vulnerability in cbs_jpeg_assemble_fragment() that miscounts 0xff stuffing bytes in JPEG scan headers. Attackers can supply a crafted JPEG/MJPEG stream with 0xff in the scan header, triggering an av_assert0 abort when CBS-based bitstream filters process it.

---

_Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai_
