Skip to content
Memory corruption Advisory Advanced CVE-2020-6492

Google Chrome WebGL code execution vulnerability

A use-after-free flaw in Chrome's ANGLE graphics layer meant a texture object could be deleted and then still referenced during a draw call. An attacker who arranged memory carefully could potentially turn this into arbitrary code execution in the browser process.

Marcin Towalski Follow

Originally disclosed on Cisco Talos

High 8.3 View original

A use-after-free read vulnerability exists in Google Chrome 81.0.4044.138 (Stable), 84.0.4136.5 (Dev) and 84.0.4143.7 (Canary), when a WebGL component fails to properly handle objects in memory. Successful exploitation of this vulnerability can lead to arbitrary code execution in the context of the browser process.

Marcin Towalski, on Cisco Talos

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

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 texture was deleted while a stale pointer to it remained in the active texture cache, so a later draw call synced state on freed memory.

Impact

With proper memory layout manipulation an attacker could gain full control of the use-after-free and potentially achieve arbitrary code execution in the browser process; the crash itself was only reproduced on Windows with hardware 3D acceleration.

What the attacker needed

Victim visits a malicious page; Windows with hardware 3D acceleration

The fix

The vendor fixed it, with the fix landing in Chrome 85.0.4149.0.

How it was found

  1. Bind a texture object in WebGL.
  2. Delete that same texture.
  3. Issue an instanced draw call that still references the deleted texture.

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 texture is a chunk of image data the graphics system keeps in memory. The browser freed that texture but a later drawing command still pointed at the old memory, which is called a use-after-free. If an attacker can put their own data in that freed space, they may be able to control what the browser does next.

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 by Marcin Towalski

View all

12 more disclosed reports, best first.

More from Cisco Talos

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.