---
id: "CVE-2026-125202"
page: "https://infrastack.ai/live/CVE-2026-125202"
kind: "vulnerability"
aliases: ["CVE-2026-125202"]
title: "FFmpeg: crafted HEVC stream overflows heap during VAAPI hardware decoding"
severity: "high"
cvss: 7.3
epss: null
exploited: false
status: "open"
category: "package"
products: [{"name": "ffmpeg", "fixed": [], "affected": "<= 9.0.2", "ecosystem": "vendor"}]
ecosystems: []
tags: ["ffmpeg", "hevc", "libavcodec", "media-processing", "package", "vaapi"]
not_affected_if: ["no-untrusted-hevc-input", "software-decoding-only"]
published_at: "2026-11-09T19:16:56+00:00"
first_seen_at: "2026-11-09T19:28:18+00:00"
updated_at: "2026-11-09T19:35:05+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-125202", "first_seen_at": "2026-11-09T19:28:18+00:00"}, {"source": "analyst", "url": "https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25136", "first_seen_at": "2026-11-09T19:35:05+00:00", "cites": ["https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25136"]}]
exploit_sources: []
---

# FFmpeg: crafted HEVC stream overflows heap during VAAPI hardware decoding

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

FFmpeg through 9.0.2 has a heap buffer overflow in the VAAPI HEVC decoder, where unbounded PPS tile counts are copied into fixed-size arrays. An attacker who supplies a crafted HEVC video can corrupt memory in applications that decode with VAAPI.

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

## Affected

- vendor:ffmpeg affected <= 9.0.2 fixed no fixed version listed

## How to check

- Run `ffmpeg -version`; versions up to and including 9.0.2 are affected per VulnCheck
- Only builds with VAAPI enabled and HEVC decoded via VAAPI (`-hwaccel vaapi`, or an app using libavcodec's VAAPI hwaccel) reach vaapi_hevc_start_frame()
- Also check apps that bundle libavcodec (media servers, transcoders, thumbnailers) that accept untrusted HEVC on Linux with Intel/AMD GPUs
- Workaround until a release: use software decoding for untrusted HEVC (omit -hwaccel vaapi)

## Fix

No release contains a fix yet. Upstream PR 25136 (unmerged, open, milestone 9.1) has a VAAPI HEVC commit 3cd298c0d8 that rejects tile counts the picture parameters cannot hold.

## Timeline

- 2026-11-09T19:28:18+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-125202
- 2026-11-09T19:35:05+00:00 analyst https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25136 — Read VulnCheck advisory (via WebFetch) and upstream PR 25136. No fixed release; PR unmerged. No PoC, no exploitation seen. Not verified: no vendor advisory. Exa and X not checked (credits out). Local attack vector per CVSS 4.0.

## Documents

- [advisory] Third-party advisory: www.vulncheck.com https://www.vulncheck.com/advisories/ffmpeg-through-9.0.2-heap-buffer-overflow-via-hevc-vaapi-tile-arrays
- [fix] FFmpeg PR 25136: libavcodec fixes (HEVC/AV1 hwaccel tile arrays, Vulkan) - open https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25136

## From the sources

FFmpeg through 9.0.2 contains a heap buffer overflow vulnerability in vaapi_hevc_start_frame() in libavcodec/vaapi_hevc.c that copies unbounded PPS tile counts into fixed-size arrays. Attackers can supply a crafted HEVC bitstream with a large picture and many tiles to write controlled 16-bit values past heap-allocated hwaccel data, corrupting memory in applications decoding with VAAPI.

---

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