Skip to content
DoS Disclosed report Advanced

Access violation on JS::Zone::Zone at address 0xe5e5e601 after allocation failure on marker->init()

A memory allocation failure during garbage collection marker initialisation leads to an access violation in JS::Zone::Zone when creating new Workers. An attacker could crash the browser by exhausting memory and repeatedly creating Workers.

Irvan Kurniawan Follow

Originally disclosed on Mozilla

  • Fixed in 4 days
  • Paid in 13 days
  • Disclosed after 4 days

After allocate large memory then execute new Worker repeatedly, Firefox able to crash on JS::Zone::Zone(JSRuntime*, JS::shadow::Zone::Kind) at address 0xe5e5e601

I able to reproduce the access violation after commit Bug 1865597 - Add error checking when initializing parallel marking and disable on error

After investigation, I found the memory allocation failure is occur on GC.cpp GCRuntime::updateMarkersVector on if (!marker->init()) { return false; } it return false; when Firefox process OOM. I've attached .patch that simulate the memory allocation failure.

Tested on

  • Firefox Nightly 122.0a1 (2023-12-06) (32-bit) on Windows 11

The original report as published on Mozilla's Bugzilla, by Irvan Kurniawan. Images and videos are our own copies; raw HTML is shown as text. View it on Mozilla's Bugzilla.

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 code did not properly handle the failure of marker->init() during garbage collection, leading to use of an uninitialised or invalid pointer.

Impact

An attacker could crash the browser (denial of service) by causing memory exhaustion and creating Workers.

What the attacker needed

Ability to run JavaScript in Firefox; memory exhaustion

How it was found

  1. Allocate a large amount of memory to cause memory pressure.
  2. Repeatedly execute `new Worker` to create new workers.
  3. Observe the access violation crash at JS::Zone::Zone.

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 runs out of memory, it should handle that gracefully. Here, a failure to set up part of the garbage collector (which cleans up unused memory) was not handled properly, so the browser crashed when trying to create a new background task (a Worker).

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More by Irvan Kurniawan

View all

72 more disclosed reports, best first.

More from Mozilla

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.