Insufficient validation of untrusted input in Codecs (CVE-2026-10966)
The H.265 parser allows a new Sequence Parameter Set (SPS) to replace an existing one without re-validating any Picture Parameter Sets (PPS) that reference it. An attacker could supply a crafted bitstream that causes integer underflows in VAAPI and passes invalid invariants to the Linux kernel via V4L2, potentially leading to out-of-bounds memory accesses and a GPU-to-kernel sandbox escape.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 24 days
Project Fortify, an experimental security project, has identified the following potential security issue. If you're a feature owner CC-ed on this bug, please do your best to review these reports without the Chrome Security team. Please see https://chromium.googlesource.com/chromium/src/+/main/docs/security/ai-generated-security-bugs-faq.md for more information.
Overview: A vulnerability in the H.265 parser allows an attacker to bypass Picture Parameter Set (PPS) validation by replacing an active Sequence Parameter Set (SPS) with a new one that alters Coding Tree Block (CTB) geometry. Because the decoder fails to detect this specific configuration change, an inconsistent SPS/PPS pair is sent to hardware delegates. This results in integer underflows in VAAPI (sending malformed data to drivers) and passes invalid invariants directly to the Linux kernel in V4L2, representing a potential GPU-to-kernel sandbox escape.
Affected files:
media/parsers/h265_parser.ccmedia/gpu/h265_decoder.ccmedia/gpu/vaapi/h265_vaapi_video_decoder_delegate.ccmedia/gpu/windows/d3d11_h265_accelerator.ccmedia/gpu/v4l2/v4l2_video_decoder_delegate_h265.cc
Estimated timestamp from git blame: 2026-03-25
Root Cause
In Chromium's H.265 implementation, H265Parser::ParsePPS() cross-validates several fields against the Sequence Parameter Set (SPS) currently active at the time of parsing. For example, it enforces that pps->num_tile_columns_minus1 is less than sps->pic_width_in_ctbs_y (media/parsers/h265_parser.cc:947).
However, H265Parser::ParseSPS() allows a new SPS with the same sps_seq_parameter_set_id to overwrite an existing one without invalidating or re-validating any Picture Parameter Sets (PPS) that already reference that ID (media/parsers/h265_parser.cc:886).
If an attacker provides an initial SPS/PPS pair that is valid, they can subsequently replace the SPS with a new one that has identical overall picture dimensions (luma samples) but a completely different CTB geometry (e.g., a much larger CTB size, resulting in a tiny pic_width_in_ctbs_y). This renders the existing PPS invalid under the new SPS, effectively bypassing the parser's initial boundary checks.
Missing Re-validation in H265Decoder
When processing a subsequent slice, H265Decoder::ProcessPPS() checks for configuration changes to decide if the decoder needs to be flushed. It calculates is_config_change by comparing pic_size_, profile_, bit_depth_, chroma_sampling_, and max_dpb_size.
Because the attacker carefully kept the overall pic_size_ identical, is_config_change evaluates to false. Consequently, the decoder does not trigger a flush or re-configuration. H265Decoder::StartNewFrame() then proceeds to ship the inconsistent, unvalidated SPS/PPS pair to the hardware accelerator delegate.
Impact on GPU Drivers and Kernel
This validation bypass results in malformed data being passed to platform-specific video decoding delegates:
- VAAPI (
media/gpu/vaapi/h265_vaapi_video_decoder_delegate.cc): Ifpps->uniform_spacing_flagis true, the delegate calculatescolumn_width_minus1(lines 157-164). Becausesps->pic_width_in_ctbs_yis now smaller thanpps->num_tile_columns_minus1 + 1, the integer division evaluates to 0. The subsequent subtraction (0 - 0 - 1) results in-1. This-1wraps around to0xFFFFwhen stored in theuint16_tarraypic_param.column_width_minus1. Submitting a column width of 65535 CTBs to the vendor-supplied User Mode Driver (UMD) will likely cause immediate out-of-bounds memory accesses in the driver. - V4L2 stateless (
media/gpu/v4l2/v4l2_video_decoder_delegate_h265.cc): On ChromeOS ARM devices, inconsistent SPS and PPS control structures (wherenum_tile_columns_minus1 >= sps->pic_width_in_ctbs_y) are copied intov4l2_ctrl_hevc_ppsand sent directly to the Linux kernel via theVIDIOC_S_EXT_CTRLSioctl. The kernel's V4L2 stateless H.265 drivers rely entirely on the userspace client (Chrome) to enforce spec invariants. Providing contradictory structures will cause the kernel to read/write out-of-bounds when computing physical tile memory offsets, representing a potential GPU-sandbox to Kernel privilege escalation.
Potential Steps to Trigger
(Note: These are suggested steps; we do not currently have a working Proof of Concept that executes code.)
- Create an H.265 bitstream embedded in a
<video>tag or via MSE. - Insert an
SPS_NUTNALU (sps_id=0) withpic_width_in_luma_samples=1920and a small CTB size, makingpic_width_in_ctbs_yvery large (e.g., 100). - Insert a
PPS_NUTNALU referencingsps_id=0, settingtiles_enabled_flag=1andnum_tile_columns_minus1=5. - Insert a second
SPS_NUTNALU (sps_id=0) withpic_width_in_luma_samples=1920but a maximum CTB size, makingpic_width_in_ctbs_yvery small (e.g., 1). - Insert a Slice NALU referencing the PPS to force the decoder to process the inconsistent state and pass the malformed parameters to the hardware delegate.
Suggested Fix
In H265Parser::ParseSPS(), when an SPS is replaced, iterate through active_pps_ and either remove or invalidate any PPS that references the replaced sps_seq_parameter_set_id. Alternatively, H265Decoder::ProcessPPS() could be updated to explicitly check for changes in CTB geometry (e.g., sps->pic_width_in_ctbs_y, sps->ctb_log2_size_y) when calculating is_config_change, forcing a decoder flush and proper re-validation.
Evaluated with Chrome root at commit: eca8648a4e1cdfdda68c495a6003059fed641955
Results so far have been promising, but there can be wrong deductions. If this proves to be a false positive, please close as WAI; data from false positives will be used to improve accuracy over time. And please feel free to reach out to me directly if you have concerns or feedback on the project.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the H.265 parser allows an SPS with the same ID to overwrite an existing SPS without invalidating or re-validating any PPS that references that ID, and the decoder's configuration-change check does not detect changes in CTB geometry.
Impact
The validation bypass could cause out-of-bounds memory accesses in the GPU driver and potentially allow a GPU-to-kernel sandbox escape, though no working proof of concept exists yet.
What the attacker needed
Victim opens a crafted video; browser uses H.265 hardware decoding
The fix
The parser should invalidate any PPS that references a replaced SPS, or the decoder should check for changes in CTB geometry when deciding whether to flush.
How it was found
- Create an H.265 bitstream embedded in a video tag or via MSE.
- Insert an SPS NALU with a small CTB size, making pic_width_in_ctbs_y large.
- Insert a PPS NALU referencing that SPS with tiles enabled and multiple tile columns.
- Insert a second SPS NALU with the same ID but a maximum CTB size, making pic_width_in_ctbs_y small.
- Insert a Slice NALU referencing the PPS to force the decoder to process the inconsistent state.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
Video files are made of small chunks called parameter sets that describe how to decode the picture. The decoder checks these chunks against each other, but if one chunk is replaced later, the old checks are not repeated. An attacker could craft a video that tricks the decoder into sending bad numbers to the graphics driver and even the operating system kernel, which might crash the system or let the attacker break out of the browser's security sandbox.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.