Skip to content
Info disclosure Advisory Advanced CVE-2026-17707

Uninitialized Use in Media (CVE-2026-17707)

A Windows hardware video encoder in Chromium tolerates a timeout when acquiring a keyed mutex on a renderer-supplied texture, so a copy command is silently dropped and the destination texture keeps uninitialised GPU memory. A compromised renderer could then receive a video bitstream containing stale VRAM from other tabs or system graphics.

Google Chrome

Originally disclosed on Chrome VRP

  • Fix shipped in 57 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. Please see https://chromium.googlesource.com/chromium/src/+/main/docs/security/ai-generated-security-bugs-faq.md for more information.

Overview: A potential uninitialized GPU memory disclosure vulnerability exists in MediaFoundationVideoEncodeAccelerator on Windows. The implementation of PerformD3DCopy incorrectly tolerates a WAIT_TIMEOUT status when attempting to acquire a keyed mutex on a renderer-supplied source texture. Consequently, the subsequent CopySubresourceRegion operation is dropped by the Direct3D runtime, leaving the destination texture uninitialized with stale GPU memory that is then compressed into the video bitstream.

Affected files:

  • media/gpu/windows/media_foundation_video_encode_accelerator_win.cc

Estimated timestamp from git blame: 2024-02-21

Description

A potential uninitialized GPU VRAM leak (CWE-908) has been identified in the Windows-specific hardware video encoder interface MediaFoundationVideoEncodeAccelerator.

Root Cause Analysis

In media/gpu/windows/media_foundation_video_encode_accelerator_win.cc, the method InitializeD3DCopying allocates a persistent destination texture copied_d3d11_texture_ on the D3D11 default heap with no initial data:

C++
// media/gpu/windows/media_foundation_video_encode_accelerator_win.cc
D3D11_TEXTURE2D_DESC copy_desc = {
    .Width = static_cast<UINT>(input_visible_size_.width()),
    .Height = static_cast<UINT>(input_visible_size_.height()),
    ...
    .Usage = D3D11_USAGE_DEFAULT,
    .MiscFlags = 0};
ComD3D11Texture2D copied_d3d11_texture;
HRESULT hr = texture_device->CreateTexture2D(&copy_desc, nullptr, // No initial data
                                             &copied_d3d11_texture);
...
copied_d3d11_texture_ = std::move(copied_d3d11_texture);

Because this texture is allocated with Usage = D3D11_USAGE_DEFAULT and no initial data, its initial state consists of undefined GPU VRAM, which can contain residue from other tabs, canvases, or system graphics.

PerformD3DCopy is responsible for copying the incoming video frame into this texture. To synchronize access with the source texture (which may be shared with the renderer), it queries and acquires a keyed mutex:

C++
hr = input_texture->QueryInterface(IID_PPV_ARGS(&keyed_mutex));
if (SUCCEEDED(hr)) {
  constexpr int kMaxSyncTimeMs = 100;
  hr = keyed_mutex->AcquireSync(0, kMaxSyncTimeMs);
  if (hr != S_OK && hr != WAIT_TIMEOUT) {  // BUG: WAIT_TIMEOUT is tolerated
    LOG(ERROR) << "Failed to acquire mutex: " << PrintHr(hr);
    return E_FAIL;
  }
  release_keyed_mutex.emplace(std::move(keyed_mutex), 0);
}
...
device_context->CopySubresourceRegion(copied_d3d11_texture_.Get(), 0, 0, 0,
                                      0, input_texture, 0, &src_box);

If the mutex acquisition times out (WAIT_TIMEOUT), the code incorrectly proceeds. Under the Direct3D 11 API contract, rendering or copy commands (such as CopySubresourceRegion) involving a keyed-mutex-protected texture will be dropped or fail if the corresponding sync lock is not successfully acquired. Because CopySubresourceRegion is a void method, this failure occurs silently. The function then returns S_OK, leaving copied_d3d11_texture_ with its original uninitialized VRAM content.

Subsequently, the uninitialized texture is wrapped and submitted to the hardware encoder MFT via encoder_->ProcessInput(), compressing the stale VRAM contents into the output video bitstream, which is returned to the renderer.

A similar issue is present in PerformD3DScaling where WAIT_TIMEOUT is also tolerated on line 2913. While VideoProcessorBlt returns an HRESULT (and its error status is checked), on some hardware or driver configurations, it may still result in undefined behavior or partial leaks depending on driver handling.


Potential Trigger Steps

Note: These are conceptual steps. Our tooling does not currently have the environment to execute or run active proof-of-concept exploits.

  1. A compromised renderer allocates a DXGI-backed SharedImage with D3D11_RESOURCE_MISC_SHARED_KEYEDMUTEX enabled.
  2. The renderer obtains the shared NT handle and calls AcquireSync(0, INFINITE) on its own device, ensuring the GPU process cannot acquire the mutex within the 100ms timeout window.
  3. The renderer dispatches an Encode Mojo IPC request passing the SharedImage handle.
  4. In the GPU process, MediaFoundationVideoEncodeAccelerator::PerformD3DCopy attempts to acquire the keyed mutex, blocks for 100ms, and returns WAIT_TIMEOUT.
  5. The timeout is tolerated, CopySubresourceRegion is dropped by the Direct3D runtime, and the uninitialized destination texture is passed to the hardware encoder.
  6. The compressed bitstream containing uninitialized GPU memory is received and decoded by the renderer to reconstruct cross-origin VRAM pixels.

Suggested Fix

Strictly check that the keyed mutex is successfully acquired before performing any copy or scaling operations. Any return value other than S_OK (including WAIT_TIMEOUT or WAIT_ABANDONED) should be treated as a failure, and the frame should be rejected/dropped.

For example, align the logic with the correct implementation found in gpu/ipc/common/dxgi_helpers.cc:

C++
// Inside PerformD3DCopy and PerformD3DScaling
hr = keyed_mutex->AcquireSync(0, kMaxSyncTimeMs);
if (hr != S_OK) {
  LOG(ERROR) << "Failed to acquire keyed mutex: " << PrintHr(hr);
  return E_FAIL; // Drop the frame or fail the copy operation securely
}

Evaluated with Chrome root at commit: 9ebf4302210513a012c901d87a2668b3aadf8cc1


Results so far have been promising, but there can be wrong deductions. Feel free to adjust as follows:

  • If you are familiar with the severity guidelines, you may adjust the severity.
  • If this is a false positive, and there's no work to be done, please close as WAI.
  • If there is work to do here but not a vulnerability, please change the issue type to Task/Bug/FR.

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.

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

Likely the mutex acquisition check treats WAIT_TIMEOUT as success, so a copy on a keyed-mutex-protected texture is dropped by the Direct3D runtime while the code still returns success and encodes the uninitialised destination texture.

Impact

A compromised renderer could read stale GPU memory belonging to other tabs or system graphics, though the report notes the steps are conceptual and were not executed.

What the attacker needed

Compromised renderer process; Windows with hardware video encoding; renderer can hold the shared texture mutex

The fix

The keyed mutex acquisition should be treated as failed for any result other than success, including timeout and abandoned, and the frame dropped.

How it was found

  1. A compromised renderer creates a shared image backed by a keyed-mutex texture.
  2. The renderer holds the mutex so the GPU process cannot acquire it within the timeout.
  3. The renderer sends an encode request with the shared image handle.
  4. The GPU process tries to acquire the mutex, times out, and continues anyway.
  5. The copy is dropped and the uninitialised texture is passed to the hardware encoder.
  6. The renderer receives and decodes the bitstream to recover leftover VRAM pixels.

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.

Graphics cards have their own memory, called VRAM, which is reused between programs. This code was meant to copy a video frame into a fresh buffer, but when a lock on the source texture timed out it carried on anyway, so the copy never happened and the buffer still held whatever was left there before. That leftover memory was then encoded as video and handed back, which could expose another program's pixels.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More from Google Chrome

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.