Skip to content
Memory corruption Advisory Advanced CVE-2026-9975

Out of bounds read and write in ANGLE (CVE-2026-9975)

ANGLE's Vulkan backend can fall back to a wider texture format than the one used to allocate an imported external memory object, so it passes a larger allocation size to the Vulkan driver than the imported file descriptor actually backs. Because the size mismatch check is only an ASSERT that is compiled out in release builds, a malicious WebGL page could cause out-of-bounds VRAM reads or writes depending on driver behaviour.

Google Chrome

Originally disclosed on Chrome VRP

  • Fix shipped in 18 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: ANGLE's Vulkan backend may fall back to a wider texture format than the one used to allocate an imported external memory object. This results in passing an allocation size to the Vulkan driver that is larger than the underlying imported file descriptor. The critical check for this mismatch is an ASSERT, which is disabled in release builds, potentially leading to out-of-bounds VRAM access.

Affected files:

  • third_party/angle/src/libANGLE/renderer/vulkan/MemoryObjectVk.cpp
  • third_party/angle/src/libANGLE/renderer/vulkan/TextureVk.cpp
  • third_party/angle/src/libANGLE/renderer/vulkan/vk_format_utils.cpp
  • third_party/angle/src/libANGLE/renderer/vulkan/vk_helpers.cpp
  • third_party/angle/src/libANGLE/renderer/vulkan/vk_utils.cpp
  • gpu/command_buffer/service/shared_image/external_vk_image_backing.cc
  • gpu/command_buffer/service/shared_image/shared_image_format_service_utils.cc

Estimated timestamp from git blame: 2023-12-20

Summary

There is a potential out-of-bounds (OOB) memory access vulnerability in ANGLE's Vulkan backend when handling external memory imports. If a specific texture format is not fully supported by the underlying Vulkan driver, ANGLE falls back to a wider format. This causes ANGLE to require a larger memory allocation than the size of the memory object originally imported from Chromium. Because the size mismatch check is only an ASSERT that compiles out in release builds, ANGLE passes conflicting size information to the Vulkan driver. Depending on how the driver handles this specification violation, it may lead to OOB VRAM read/write access.

Technical Details

The vulnerability occurs due to a disconnect between the memory allocation in Chromium and the texture creation in ANGLE:

  1. Chromium Allocation: In gpu/vulkan/vulkan_image.cc, Chromium allocates N bytes of device memory for a VkImage based on a specific, requested format (e.g., a narrow 16-bit format) and exports a file descriptor (FD).
  2. Import to ANGLE: Chromium passes this FD and the exact size N to ANGLE via glImportMemoryFdEXT (handled in ExternalVkImageBacking::CreateGLTexture). ANGLE stores this size internally as mSize = size; (MemoryObjectVk::importFd).
  3. Format Fallback: When Chromium calls glTexStorageMemFlags2DANGLE to associate the memory with a GL texture, ANGLE evaluates driver support. If the driver doesn't support the required GL operations on the narrow format, ANGLE selects a wider fallback format (e.g., a 32-bit format) in TextureVk::setStorageExternalMemory.
  4. Image Recreation: ANGLE calls MemoryObjectVk::createImage using this wider fallback format. It queries the memory requirements for the new format, which yields a required size M that is larger than the imported size N.
  5. Bypassed Check: The code attempts to verify the sizes match: ASSERT(externalMemoryRequirements.size == mSize); (MemoryObjectVk.cpp:251). Because this is an ASSERT, it is compiled out in production release builds, and the execution continues silently despite M != N.
  6. Vulkan Spec Violation: ANGLE proceeds to call vkAllocateMemory. In FindAndAllocateCompatibleMemory (vk_utils.cpp), it sets allocInfo.allocationSize = M, while passing the FD (which only backs N bytes) via the pNext chain (VkImportMemoryFdInfoKHR). This violates the Vulkan specification, which requires allocationSize to exactly match the imported memory size.

Impact

The impact heavily depends on the behavior of the specific, often proprietary, Vulkan driver (e.g., Qualcomm Adreno, ARM Mali). If the driver blindly trusts allocationSize = M and maps M bytes into the GPU page tables, the M - N bytes will likely map to adjacent, unassociated physical VRAM pages. When the GPU hardware processes WebGL commands based on the 32-bit format layout, it will read or write past the end of the intended buffer into this M - N region. This can lead to arbitrary VRAM data leaks (cross-origin textures) or corruption of GPU state. Since the GPU process is unsandboxed on platforms like Android, this is a critical security risk.

Potential Steps to Trigger

Note: These are theoretical steps; a functional exploit has not been verified.

  1. From a compromised renderer process or malicious WebGL page, request a SharedImage with a narrow format (e.g., 16-bit RGBA_4444) and usage flags that require GL interop (e.g., renderability).
  2. Bind this SharedImage to a WebGL texture.
  3. Ensure this is run on a device where the Vulkan driver triggers ANGLE's format fallback for the chosen format (i.e., it lacks native COLOR_ATTACHMENT support for the narrow format but supports a wider 32-bit fallback).
  4. Issue WebGL draw or read calls targeting this texture to force the GPU to access the out-of-bounds M - N region.

Suggested Fix

Convert the ASSERT in MemoryObjectVk::createImage to a hard runtime check that executes in release builds. If externalMemoryRequirements.size != mSize, the function should gracefully fail and return an error (e.g., angle::Result::Stop), preventing the invalid vkAllocateMemory call.

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.

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 format fallback path changes the required allocation size after import, and the only guard against the mismatch is an ASSERT that is removed in release builds.

Impact

Depending on how the driver handles the specification violation, this could leak arbitrary VRAM data such as cross-origin textures or corrupt GPU state, and the GPU process is unsandboxed on platforms like Android; the report notes a functional exploit has not been verified.

What the attacker needed

Malicious WebGL page or compromised renderer; driver lacking native support for the narrow format; device with a Vulkan driver that trusts allocationSize

The fix

The ASSERT should be replaced with a hard runtime check that fails gracefully when the required size differs from the imported size, before any allocation call is made.

How it was found

  1. Request a SharedImage with a narrow format and usage flags requiring GL interop, from a malicious WebGL page or compromised renderer.
  2. Bind that SharedImage to a WebGL texture.
  3. Run on a device whose Vulkan driver triggers ANGLE's format fallback for that format.
  4. Issue WebGL draw or read calls against the texture to force access to the out-of-bounds region.

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 web page can ask the browser's graphics layer to use a texture in a certain format. If the graphics driver cannot handle that exact format, the code quietly switches to a bigger one, but the memory behind it was only sized for the smaller one. A safety check that would have caught this is switched off in the builds people actually use, so the graphics card may read or write past the end of the buffer.

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.

More from Google Chrome

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.