Skip to content
XSS Advisory Advanced CVE-2026-17734

Inappropriate implementation in Autofill (CVE-2026-17734)

The AutofillEvent refill getter cached a JavaScript callback function on a DOM event object that is shared between V8 worlds, so a privileged isolated world could create the cached function first and the main world could then read it. An attacker could use the leaked privileged function to run code in the privileged context, achieving universal cross-site scripting.

Google Chrome

Originally disclosed on Chrome VRP

  • Fix shipped in 4 months

Flapjack (go/flapjack), an LLM-powered vulnerability discovery tool, has identified a security issue and generated a PoC.

d8 variant: 'Asan'

flags: --allow-natives-syntax --omit-quit

Overview: The AutofillEvent::refill getter lazily initializes and caches a JavaScript callback function on the event object. Because DOM events are shared across V8 worlds, accessing this property from a privileged isolated world caches a privileged v8::Function that can subsequently be read by the main world. Attackers can abuse this leaked function to execute arbitrary code in the privileged context, leading to Universal Cross-Site Scripting (UXSS).

Affected files:

  • third_party/blink/renderer/bindings/core/v8/script_function.cc
  • third_party/blink/renderer/core/html/forms/autofill_event.cc

Estimated timestamp from git blame: 2026-01-13

Root Cause

In third_party/blink/renderer/core/html/forms/autofill_event.cc, the refill getter is defined as follows:

C++
V8AutofillRefillCallback* AutofillEvent::refill(ScriptState* script_state) {
  // ...
  if (!refill_callback_) {
    auto* function = MakeGarbageCollected<AutofillRefillFunction>(this);
    refill_callback_ = V8AutofillRefillCallback::Create(
        function->ToV8Function(script_state).template As<v8::Object>());
  }
  return refill_callback_.Get();
}

When refill is first accessed, it creates a v8::Function bound to the caller's ScriptState (which represents a specific v8::Context and DOMWrapperWorld) and caches it in the refill_callback_ member.

Because AutofillEvent is a DOM Event, a single event instance can be observed and accessed from multiple V8 worlds (e.g., an extension's isolated world and the page's main world). If a privileged isolated world accesses event.refill first, a v8::Function belonging to that privileged context is created and cached.

If the main world subsequently accesses event.refill, Blink's bindings layer (ToV8Traits<CallbackInterfaceBase>::ToV8) returns the cached v8::Function. The bindings layer does contain a cross-world check (DCHECK(&callback->GetWorld() == &script_state->World());), but because it is a DCHECK, it is compiled out in release builds. This allows the privileged function to cross the boundary into the unprivileged main world.

Exploitation

Once the unprivileged world obtains a reference to the privileged v8::Function, it can access its constructor property to obtain the privileged world's Function constructor. The attacker can then execute arbitrary code in the privileged context and retrieve its global object by calling:

JavaScript
const privilegedGlobal = leakedFunc.constructor("return this")();

This completely breaks the isolated world security boundary, resulting in UXSS.

Suggested Fix

Do not cache the callback in a C++ member variable (refill_callback_) on the AutofillEvent object, as C++ DOM objects are shared across worlds.

Instead, either:

  1. Return a fresh callback per access: Instantiate and return a new AutofillRefillFunction and V8AutofillRefillCallback every time the refill getter is invoked, using the current caller's ScriptState.
  2. Cache per-world: If caching is strictly necessary for performance or object identity, store the cached callback on the JavaScript wrapper object itself (e.g., using a V8PrivateProperty), which ensures the cache is strictly tied to the specific DOMWrapperWorld reading the property.

Evaluated with Chrome root at commit: a3f5fcb392f2902650ca2b71820e7e418787e18b


The description of the vuln is LLM-generated and can contain mistakes. Your feedback is appreciated, and will help us improve Flapjack over time. The PoC was run in a VM and it seemed to be legit - if not, let us know and we can strengthen our checker.

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 refill getter cached a world-specific v8::Function in a C++ member on a DOM event shared across worlds, and the cross-world check was only a DCHECK compiled out in release builds.

Impact

The isolated world boundary is broken, so page code could run with the privileges of an extension's isolated world (UXSS); the text does not state which browsers or builds were confirmed affected beyond the d8 test.

What the attacker needed

A privileged isolated world reads refill first; page code can access the same event object

The fix

The callback should not be cached on the shared C++ event object; it should be created fresh per access or cached per world on the JavaScript wrapper.

How it was found

  1. Have a privileged isolated world access the event's refill property first, creating and caching a privileged function.
  2. Have the main world then access the same event's refill property to receive the cached privileged function.
  3. Read the function's constructor to obtain the privileged world's Function constructor.
  4. Call that constructor to run code and retrieve the privileged global object.

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 browser page and a browser extension run in separate security zones, and the browser is meant to stop code from one zone reaching into the other. Here a form event object kept a saved copy of a function created in the extension's zone, and the page could pick up that same copy. With it, page code could run inside the extension's more powerful zone, which is called universal cross-site scripting.

What is XSS?

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.

More from Google Chrome

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site scripting (XSS)

The lesson behind this report.

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.