Skip to content
Memory corruption Advisory Advanced CVE-2020-15972CVE-2021-21114

GHSL-2020-167: Use-after-free (UaF) in Chrome AudioHandler - CVE-2020-15972, CVE-2021-21114

A use-after-free existed in Chrome's AudioHandler because processing methods were not protected by the same lock used when clearing handlers during teardown. An attacker could trigger the race by getting a victim to visit a malicious website, leading to memory corruption in the sandboxed renderer.

m-y-mo Follow

Originally disclosed on GitHub Security Lab

The tear down mutex removed in this commit [1] does not only protect against UaF issues with the BaseAudioContext (which is what the self-referencing patch fixed), but also race conditions where AudioHandlers may still be processing while the ClearHandlersToBeDeleted method is removing the renderingorphanhandlers. As…

m-y-mo, on GitHub Security Lab

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 removal of a teardown mutex left AudioHandler processing methods unprotected against ClearHandlersToBeDeleted, allowing a handler to be freed while still in use.

Impact

A use-after-free in the sandboxed renderer process could be triggered by visiting a malicious website, though the text does not claim escape from the sandbox.

What the attacker needed

Victim visits a malicious website; Chrome browser

The fix

The issue was fixed in Chrome 86.0.4240.75, reverted due to a deadlock, and fixed again in 87.0.4280.141.

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.

When a program frees a piece of memory but keeps using it, that is called a use-after-free. Here, Chrome's audio code could delete an audio handler while another part of the code was still working with it, because the two paths did not share a lock. A malicious web page could set up the timing so this happened, which can crash the browser or potentially let an attacker run code inside the sandboxed renderer.

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 m-y-mo

View all

64 more disclosed reports, best first.

More from GitHub Security Lab

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.