Uninitialized resource in Video (CVE-2026-106261)
A rounding inconsistency in libvpx's VP8 decoder lets a crafted bitstream skip writing chroma planes for certain macroblocks, and because Chrome allocates VP8 frame buffers without zeroing them, uninitialised renderer heap memory is returned. An attacker could read that memory through WebCodecs, giving a heap leak that could help bypass ASLR.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 6 months
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 rounding inconsistency in libvpx's VP8 decoder can cause it to skip writing to chroma planes for specific macroblocks. Because VP8 frame buffers are not zero-initialized, this can leak renderer heap memory via WebCodecs.
Affected files:
third_party/libvpx/source/libvpx/vp8/common/reconinter.cthird_party/libvpx/source/libvpx/vp8/decoder/decodeframe.cthird_party/libvpx/source/libvpx/vp8/common/alloccommon.cthird_party/libvpx/source/libvpx/vpx_scale/generic/yv12config.c
Estimated timestamp from git blame: 2019-05-02
Description
There is a potential uninitialized heap memory disclosure vulnerability in the libvpx VP8 decoder. It is possible to craft a VP8 bitstream that causes the decoder to bypass writing to the U and V (chroma) planes for specific macroblocks. Because Chrome's libvpx integration for VP8 allocates frame buffers using malloc (via vpx_memalign) without zero-initialization, these unwritten planes will contain uninitialized memory from the renderer process heap. This memory is subsequently copied into a media::VideoFrame and can be extracted using WebCodecs APIs (e.g., VideoFrame.copyTo), providing an attacker with a reliable renderer heap leak, which is a powerful primitive for bypassing ASLR.
Technical Details
The vulnerability stems from an inconsistency in motion vector bounds checking between luma and chroma prediction in vp8_build_inter16x16_predictors_mb (third_party/libvpx/source/libvpx/vp8/common/reconinter.c).
- Version 3 Bitstream: An attacker provides a VP8 bitstream with
version = 3, which enables full-pixel motion vectors (cm->full_pixel = 1) and sets the subpixel maskxd->fullpixel_mask = ~7(0xFFFFFFF8). - Left-Edge Macroblock: The attacker targets a macroblock at the extreme left edge of the frame (
xd->mb_to_left_edge = 0). - Luma Motion Vector Check: The attacker encodes a luma motion vector of exactly
mv.col = -152. During Luma clamping (clamp_mv_to_umv_border), the boundary check isif (mv->col < (xd->mb_to_left_edge - (19 << 3))). Since19 << 3 = 152, this evaluates toif (-152 < -152). This is false, so the luma MV is not clamped. - Chroma MV Derivation: The chroma MV is derived by adding a rounding bias and halving:
(-152 + -1) / 2 = -76. - Mask Application: The full pixel mask is applied:
-76 & ~7evaluates to-80. - Chroma Bounds Check Failure: The decoder performs a bounds check on the derived chroma MV:
if (2 * _16x16mv.as_mv.col < (x->mb_to_left_edge - (19 << 3))). This evaluates toif (2 * -80 < -152), which is-160 < -152. This is TRUE. - Early Return: The check failure triggers an early
return;(line 340), entirely skipping the prediction functions that write to thedst_uanddst_vchroma buffers. - Bypassing Subsequent Writes: By setting
mb_skip_coeff = 1and ensuring loop filtering is disabled (filter_level = 0), the attacker guarantees no residual IDCT or loop filter operations touch these uninitialized blocks. - Information Disclosure: The
vpx_image_tcontaining uninitialized memory is returned to Chrome. Inmedia::VpxVideoDecoder::CopyVpxImageToVideoFrame,libyuv::CopyPlanecopies the uninitialized data into amedia::VideoFrame, which the attacker can extract usingVideoFrame.copyTo().
Potential Steps to Reproduce
Note: These are potential steps as our tooling agent cannot execute code to verify the exploit end-to-end.
- In a malicious webpage, instantiate a WebCodecs
VideoDecoderfor thevp8codec. - Feed it a crafted VP8 bitstream with
version = 3specified in the frame header. - Ensure the bitstream contains a macroblock at column
0with a luma motion vector of-152. - Set
mb_skip_coeff = 1andfilter_level = 0for this macroblock. - Wait for the
VideoFrameto be output by the decoder. - Call
VideoFrame.copyTo()and inspect the U and V planes in the resultingArrayBufferto read raw renderer heap memory.
Suggested Fix
Chrome's vpx_video_decoder.cc should be updated to use a zero-initialized FrameBufferPool for VP8 decoding, similar to how it currently configures external buffers for VP9 (using vpx_codec_set_frame_buffer_functions). Alternatively, libvpx should be patched to either correctly clamp the luma motion vector to prevent the chroma bounds check failure, or to explicitly zero the chroma planes before returning early.
Evaluated with Chrome root at commit: 7353d249d9cacf9c7218e1d7b8a39cf39c72d646
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 a mismatch between the luma motion-vector clamp and the chroma bounds check, combined with frame buffers that are allocated without zero-initialisation, so an early return leaves chroma planes unwritten.
Impact
An attacker could obtain a reliable renderer heap leak, which is a powerful primitive for bypassing ASLR; the report notes the steps are potential and were not verified end-to-end.
What the attacker needed
Victim loads a malicious webpage; browser supports WebCodecs VP8 decoding
The fix
Chrome should use a zero-initialised frame buffer pool for VP8 decoding, or libvpx should be patched to clamp the luma motion vector correctly or zero the chroma planes before the early return.
How it was found
- Create a WebCodecs VideoDecoder for the vp8 codec in a malicious page.
- Feed it a crafted VP8 bitstream whose frame header declares version 3.
- Include a macroblock at column 0 with a luma motion vector of -152.
- Set mb_skip_coeff to 1 and filter_level to 0 for that macroblock.
- Wait for the decoder to output a VideoFrame.
- Call VideoFrame.copyTo() and inspect the U and V planes to read heap memory.
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.
When a video is decoded, the decoder normally fills every part of the picture buffer with pixels. Here, a specially crafted video file makes the decoder skip filling some colour (chroma) parts of the picture. Those parts still hold whatever was left in the program's memory from earlier, so the attacker can read leftover memory that was never meant to be shown.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.