Skip to content
Access control Advisory Advanced CVE-2026-79008

Improper input validation in GPU (CVE-2026-79008)

An untrusted renderer could request a native OpenGLES2 context type, causing shaders to be compiled under the GLES2 specification instead of WebGL. This disabled safety mitigations such as output variable zero-initialisation and struct nesting limits, potentially exposing stale GPU memory or crashing the native driver.

Google Chrome

Originally disclosed on Chrome VRP

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

Overview: An untrusted renderer can potentially bypass WebGL-specific shader sanitization by requesting an kOpenGLES2 context type. On configurations utilizing the validating command decoder, this causes the ANGLE translator to compile shaders under the SH_GLES2_SPEC specification instead of WebGL specifications. As a result, critical safety mitigations such as output variable zero-initialization and structure nesting depth limits are disabled.

Affected files:

  • gpu/command_buffer/service/gles2_cmd_decoder.cc
  • gpu/command_buffer/service/shader_translator.cc
  • gpu/ipc/service/gpu_channel.cc

Estimated timestamp from git blame: 2015-09-22

Potential Security Impact

When a renderer requests a GLES command buffer, it can specify a context_type in mojom::GLESCreationAttribs (such as ContextType::kOpenGLES2). On configurations where the validating command decoder is active (e.g., certain Android devices running on blocklisted drivers), the GPU process initializes a GLES2DecoderImpl using CONTEXT_TYPE_OPENGLES2.

This selection propagates to GLES2DecoderImpl::InitializeShaderTranslator (in gpu/command_buffer/service/gles2_cmd_decoder.cc), mapping the shader compiler specification to SH_GLES2_SPEC instead of SH_WEBGL_SPEC or SH_WEBGL2_SPEC:

C++
// gpu/command_buffer/service/gles2_cmd_decoder.cc
switch (feature_info_->context_type()) {
  case CONTEXT_TYPE_WEBGL1:  shader_spec = SH_WEBGL_SPEC;  ... break;
  case CONTEXT_TYPE_WEBGL2:  shader_spec = SH_WEBGL2_SPEC; ... break;
  case CONTEXT_TYPE_OPENGLES2:
    shader_spec = SH_GLES2_SPEC;
    ...
    break;

Compiling under SH_GLES2_SPEC disables multiple critical security mitigations enforced under WebGL specifications:

  1. Zero-Initialization of Outputs (initOutputVariables): In ShaderTranslator::Init (gpu/command_buffer/service/shader_translator.cc), output-variable zero-initialization is only configured for WebGL specs:

    C++
    switch (shader_spec) {
      case SH_WEBGL_SPEC:
      case SH_WEBGL2_SPEC:
        compile_options_.initOutputVariables = true;
        break;
      default:
        break;  // Bypassed under SH_GLES2_SPEC
    }
    

    Without zero-initialization, uninitialized fragment or varying outputs can potentially contain stale graphics memory, risking the exposure of cross-origin GPU frame data via glReadPixels or sampling operations.

  2. Bypass of Struct Nesting Limits: ANGLE's nesting limits check in ParseContext.cpp is bypassed under SH_GLES2_SPEC:

    C++
    void TParseContext::checkIsBelowStructNestingLimit(const TSourceLoc &line, const TField &field) {
        if (!sh::IsWebGLBasedSpec(mShaderSpec)) {
            return; // Bypassed under SH_GLES2_SPEC
        }
        ...
    }
    

    An attacker can potentially construct deeply nested struct declarations that are parsed and forwarded directly to the native vendor GPU driver compiler. This bypasses the protections designed to prevent native compiler stack overflows and driver crashes.

  3. Loop Indexing and Identifier Validation Bypass: WebGL-specific validation checks, loop limitations, and identifier constraints are ignored because they are gated behind WebGL specifications.

Potential Attack Scenario

Note: Our analysis is based on static code review; we do not currently have a running proof-of-concept exploit.

  1. A compromised renderer process calls mojom::GpuChannel::CreateCommandBuffer with init_params->attribs set to mojom::ContextCreationAttribs::NewGles(mojom::GLESCreationAttribs{.context_type = mojom::ContextType::kOpenGLES2, ...}).
  2. The GPU process initializes a GLES2DecoderImpl with the CONTEXT_TYPE_OPENGLES2 specification.
  3. The attacker submits a custom fragment shader that declares but does not write to its output variables. Because initOutputVariables is false, compilation does not inject zero-initialization, potentially allowing stale GPU memory to be read back.
  4. Alternatively, the attacker compiles a shader containing deeply nested structures to attempt to trigger a crash or memory corruption in the native vendor GPU driver compiler.

Suggested Remediation

Restrict untrusted renderers from requesting native OpenGLES contexts. In gpu/ipc/service/gpu_channel.cc (within GpuChannel::CreateCommandBuffer) or in GLES2CommandBufferStub::Initialize, validate that attribs.context_type can only be CONTEXT_TYPE_OPENGLES2 or CONTEXT_TYPE_OPENGLES3 if the calling process is trusted (e.g., check is_gpu_host_ or a similar privilege flag). Otherwise, reject context creation or force the specification to fall back to a WebGL context type.

Evaluated with Chrome root at commit: b1520ef4a76878853a31f0943b565e42060edec8


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

The GPU process trusted the context type supplied by the renderer and mapped it directly to a shader compiler specification, without checking whether the caller was privileged to request a native OpenGLES context.

Impact

On affected configurations, an attacker could potentially read stale GPU memory across origins or crash the native GPU driver compiler; the report is based on static review and has no running proof of concept.

What the attacker needed

Compromised renderer process; validating command decoder active; blocklisted GPU driver configuration

The fix

Untrusted renderers should be prevented from requesting native OpenGLES context types, either by validating the caller's privilege before creating the command buffer or by forcing a fallback to a WebGL context type.

How it was found

  1. A compromised renderer calls CreateCommandBuffer with a GLES creation attribute whose context type is OpenGLES2.
  2. The GPU process initialises a decoder using the OpenGLES2 context type.
  3. The attacker submits a fragment shader that declares output variables but does not write to them.
  4. Because zero-initialisation is disabled, stale GPU memory may be read back.
  5. Alternatively, the attacker submits a shader with deeply nested structs to try to crash the native driver compiler.

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.

WebGL is a browser feature that lets websites run small programs on the graphics card. Browsers add extra safety checks to these programs because they come from untrusted websites. This report found that a website could ask for a different, less-checked type of graphics context, so some of those safety checks were skipped.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More from Google Chrome

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.