Skip to content
Race condition Advisory Advanced CVE-2026-79071

Race condition in GPU (CVE-2026-79071)

A time-of-check to time-of-use flaw in the GPU process's raster decoder allows a compromised renderer to shrink a shared memory size between a yield and resume, causing an integer underflow and out-of-bounds pointer. This lets the GPU process deserialise arbitrary heap memory as paint operations, potentially leaking cross-origin information.

Google Chrome

Originally disclosed on Chrome VRP

  • Fix shipped in 5 months

Project Fortify, an experimental security project, has identified the following potential security issue.

Overview: A TOCTOU vulnerability in RasterDecoderImpl::DoRasterCHROMIUM allows a compromised renderer to cause a size_t underflow and OOB pointer calculation when GPU rasterization yielding is enabled. This results in the GPU process deserializing and executing arbitrary heap memory as PaintOps, leading to an unbounded OOB read and potential cross-origin information leak.

Affected files:

  • gpu/command_buffer/service/raster_decoder.cc
  • gpu/command_buffer/service/command_buffer_service.cc
  • gpu/ipc/service/gpu_channel.cc

Estimated timestamp from git blame: 2025-11-28

Summary

When the kGpuYieldRasterization feature is enabled (e.g., via Finch), RasterDecoderImpl::DoRasterCHROMIUM can yield execution mid-command if the scheduler indicates it should pause rasterization. To support resuming the command later, it saves a byte offset into deferred_raster_paint_buffer_offset_. However, on resumption, the command arguments (including the shared memory size) are re-read from renderer-writable volatile shared memory. A compromised renderer can shrink the raster_shm_size between the yield and the resume, causing a size_t underflow and an out-of-bounds (OOB) pointer calculation.

Technical Details

This is a Time-of-Check to Time-of-Use (TOCTOU) vulnerability existing in the interaction between the command buffer's deferral logic and the handling of the RasterCHROMIUM command in gpu/command_buffer/service/raster_decoder.cc.

Step-by-step Exploitation Scenario (Suggested):

  1. Initial Execution (Yield):

    • A compromised renderer process prepares a large shared memory transfer buffer containing valid cc::PaintOps.
    • The renderer issues a RasterCHROMIUM command, setting the command arguments raster_shm_id to the buffer and raster_shm_size to a large value (e.g., 65536 bytes) in the volatile command buffer.
    • The GPU process reads the RasterCHROMIUM command. RasterDecoderImpl::HandleRasterCHROMIUM reads the arguments directly from the volatile cmd_data provided by the renderer.
    • The decoder calls RasterDecoderImpl::DoRasterCHROMIUM (gpu/command_buffer/service/raster_decoder.cc:3067).
    • DoRasterCHROMIUM maps the transfer buffer using GetSharedMemoryAs<char*>, validating that the 65536 size fits within the transfer buffer. The pointer is stored in paint_buffer_memory.
    • paint_buffer_size is initialized to the requested raster_shm_size (65536).
    • The decoder begins processing paint operations in a while (paint_buffer_size > 0) loop.
    • If client()->ShouldYield() returns true (e.g., after processing 64000 bytes), the decoder saves the current offset (raster_shm_size - paint_buffer_size, which is 64000) into deferred_raster_paint_buffer_offset_ (gpu/command_buffer/service/raster_decoder.cc:3047) and returns error::kDeferCommandUntilLater (gpu/command_buffer/service/raster_decoder.cc:3049).
  2. The Race Window:

    • Because the command was deferred, the command buffer's process_pos pointer is not advanced (gpu/command_buffer/service/raster_decoder.cc:1545). The RasterCHROMIUM command remains in the command buffer to be re-executed on the next pass.
    • The GPU process yields back to the message loop.
    • The compromised renderer observes the stall and modifies the raster_shm_size field in the volatile command buffer to a much smaller value (e.g., 16).
    • The attacker also shrinks the underlying transfer buffer or reallocates it to a smaller size (e.g., 32 bytes).
  3. Resume (The Vulnerability):

    • When the command is resumed, HandleRasterCHROMIUM is called again and re-reads the command arguments from the volatile shared memory. Crucially, it now reads the new, maliciously small raster_shm_size (16).
    • HandleRasterCHROMIUM calls DoRasterCHROMIUM with the new, small size.
    • DoRasterCHROMIUM calls GetSharedMemoryAs<char*> to validate the new size (16 bytes) against the smaller transfer buffer (32 bytes). This check passes.
    • paint_buffer_size is initialized to the new, smaller raster_shm_size (16).
    • The decoder checks deferred_raster_paint_buffer_offset_.has_value(). Since it was set during the yield, this is true.
    • Underflow: The decoder subtracts the saved offset (64000) from the new, small paint_buffer_size (16): paint_buffer_size -= *deferred_raster_paint_buffer_offset_; (gpu/command_buffer/service/raster_decoder.cc:2997). Because paint_buffer_size is an unsigned size_t, this results in an integer underflow, producing a massive positive value (approximately 2^64).
    • OOB Pointer: The decoder advances the pointer by the offset: paint_buffer_memory += *deferred_raster_paint_buffer_offset_; (gpu/command_buffer/service/raster_decoder.cc:2998). Because the new transfer buffer is small, this pointer is pushed far out-of-bounds, landing deep into the GPU process heap.
  4. Exploitation (OOB Read):

    • The decoder enters the while (paint_buffer_size > 0) loop.
    • The OOB pointer and massive paint_buffer_size are passed to cc::PaintOp::Deserialize.
    • The GPU process begins interpreting arbitrary heap memory as serialized PaintOps. Since paint_buffer_size is effectively unbounded, it will keep reading until it crashes or successfully deserializes ops.
    • By controlling the GPU process heap layout, an attacker can position a fake PaintOp header and payload at the OOB location. For example, a fake DrawImageOp could reference a valid gpu::Mailbox corresponding to a cross-origin SharedImage.
    • The deserializer successfully parses the fake PaintOp and returns it.
    • The decoder calls deserialized_op->Raster(raster_canvas_, playback_params), causing the cross-origin image to be drawn to the attacker-controlled raster_canvas_.
    • The renderer can execute a ReadPixels command to read back the canvas's contents, achieving a cross-origin information leak and bypassing the renderer sandbox.

Impact

This is a high-severity (S1) vulnerability in the GPU process. While kGpuYieldRasterization is an active experiment (e.g., via Finch), when enabled, a compromised renderer can leverage this TOCTOU bug to escape the renderer sandbox and leak sensitive cross-origin information from the GPU process.

Suggested Fix

In RasterDecoderImpl::DoRasterCHROMIUM, validate that *deferred_raster_paint_buffer_offset_ <= raster_shm_size before applying the offset upon resumption. If the offset is greater than the newly read raster_shm_size, it indicates a hostile modification of the command buffer arguments between the yield and the resume, and the command should be aborted with an error (e.g., error::kInvalidArguments).

Evaluated with Chrome root at commit: a3f5fcb392f2902650ca2b71820e7e418787e18b


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. Please feel free to reach out to me if you have concerns or feedback.

The original report as published on the Chromium issue tracker. Images and videos are our own copies; raw HTML is shown as text. View it on Chromium issue tracker.

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

The GPU process re-reads command arguments from renderer-writable shared memory after a yield without re-validating that the saved offset is within the new size, leading to an unsigned integer underflow.

Impact

When the kGpuYieldRasterization feature is enabled, a compromised renderer could escape the sandbox and leak cross-origin information from the GPU process.

What the attacker needed

Compromised renderer; kGpuYieldRasterization feature enabled

The fix

The fix should validate that the saved offset is not greater than the newly read shared memory size before applying it, aborting the command if so.

How it was found

  1. A compromised renderer prepares a large shared memory buffer with valid paint operations and issues a RasterCHROMIUM command with a large size.
  2. The GPU process starts processing the command and yields after some bytes, saving the current offset.
  3. The renderer observes the yield and shrinks the raster_shm_size in the command buffer and the underlying transfer buffer.
  4. On resume, the GPU process re-reads the smaller size, subtracts the saved offset causing an underflow, and advances the pointer out-of-bounds.
  5. The GPU process deserialises arbitrary heap memory as paint operations, potentially drawing a cross-origin image to a canvas.
  6. The renderer reads back the canvas contents via ReadPixels, leaking cross-origin information.

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.

A compromised renderer (a part of the browser that draws web pages) can trick the GPU process (which handles graphics) into reading memory outside a buffer. By changing a size value after the GPU process has already checked it, the attacker makes the GPU process read far beyond the intended buffer, potentially exposing data from other websites.

What is Race condition?

Parallel requests reach a state the code assumed could not happen: a coupon used twice, a limit overrun, a check skipped.

More from Google Chrome

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Race conditions

The lesson behind this report.

Parallel requests reach a state the code assumed could not happen: a coupon used twice, a limit overrun, a check skipped.