Skip to content

The publication for web craftspeople Tuesday, 17 November 2026

Security

Universal XSS Flaw Hits the uBlock Origin Extension

A security flaw let a single click turn the uBlock Origin extension into an entry point for running code on any website. A fix is already out, but the incident reopens the debate over how much trust the most-installed browser extensions deserve.

A security researcher uncovered a critical flaw in uBlock Origin, one of the most widely installed ad-blocking extensions in the world. The bug let a malicious website trick the element picker into injecting a trusted filter capable of running arbitrary code on any site visited afterward. A fix shipped quickly, but the episode shows the attack surface that extensions with broad permissions represent.

The starting point: an exposed internal URL

The extension loads its element picker, the tool used to click an ad to hide it, from an internal page under the moz-extension:// scheme, whose address contains a unique identifier generated at install time. A default filter intercepts fetch calls and fires an XHR request to that same internal address: a third-party site watching for these requests can extract the identifier, the first building block of the attack.

From an invisible click to a trusted filter

Once the identifier is known, the attacking site embeds the picker’s page inside an invisible, zero-opacity iframe. It then talks to it through a MessageChannel to simulate someone creating a blocking rule. The picker normally restricts which filter types it accepts, but inserting a plain line break into the options field is enough to smuggle in a trusted “scriptlet” filter, capable of running JavaScript on any domain.

ComponentRole in the attack chainStatus after the fix
uBlock Origin MV2 (Firefox)Main entry point, exposes the picker pageFixed
uBO Lite (MV3)Affected variant, more limited impactFixed
Added trust tokenThe content script now passes a secret the real picker must echo backDeployed

A fix built on a shared token

The chosen technical response makes a secret token pass between the content script and the picker page: any request that fails to return it is rejected. The related security advisory, GHSA-cmqw-9r2w-6wv2, details the timeline and affected versions. One notable detail from its author: an AI model spotted most of the issue, with human review focused on confirming real-world exploitability.

// Schéma simplifié de la charge envoyée au sélecteur via MessageChannel
channel.port1.postMessage({
  type: "picker:create",
  opt: "important\n!#trusted-scriptlet(inject.js)"
});

An extension installed by default on hundreds of millions of browsers remains, by construction, one of the most profitable targets for anyone chasing universal code execution.

Anyone running uBlock Origin or uBO Lite on Firefox should check that the extension updated itself to a patched version; a manual check in the add-ons manager remains the surest way to confirm it.

What this changes for web teams

For site owners, the episode changes nothing in the short term: exploitation required a click from the victim and targeted the extension itself, not any particular web application. It does serve as a reminder that internal pages exposed by an extension (moz-extension:// or chrome-extension://) deserve the same baseline hardening rigor as any server-side exposed component, whenever they accept postMessage communications without checking their origin. A few days earlier, Chrome, Edge and Firefox had agreed on a shared guide for coding agents built into the browser, a reminder that trust in a browser’s own internal components needs constant verification too.

Key takeaways

The flaw combined three minor weaknesses, a guessable internal URL, an unauthenticated message channel and a filter validation step that a single escape character could bypass, to achieve universal code execution. The fix, built on a shared token, is already available and no active exploitation has been reported.

This kind of report confirms something I keep telling clients during audits: a browser’s most dangerous attack surface is no longer the site being visited, but the stack of extensions running in the background with permissions nobody ever rechecks. I recommend keeping extensions to the strict minimum on machines that handle sensitive access, uBlock Origin included, not because it is any less trustworthy than the rest, but precisely because its popularity makes it the number one target. — Simon Janvier

Further reading

The full technical report, including the discovery timeline and exploit details, is available on its author’s blog.

Read next