A security flaw in uBlock Origin's Firefox extension could have allowed a malicious website to manipulate the ad blocker's element-picker interface and install a trusted filter that ran JavaScript on another site. The researcher who reported the issue says it has now been fixed.

The problem affected the Manifest V2 edition of uBlock Origin on Firefox. A related but less serious issue also affected uBlock Origin Lite, which uses the newer Manifest V3 extension framework. Exploitation required a user interaction, making the primary finding a one-click universal cross-site scripting issue rather than a fully automatic attack.

The element picker normally lets a user select part of a page and create a blocking rule without opening the extension's settings. Its interface is loaded into the current page from an internal browser-extension address and communicates with uBlock Origin's background process. According to the researcher's account, the interface accepted messages that an attacker-controlled page could construct.

An attacker first needed the random internal identifier assigned to the extension by Firefox. The researcher demonstrated that a site could recover that value through the behavior of an existing filter and a hooked request. With the identifier, the site could embed the picker interface in a frame and send it commands. The page could then supply crafted filter data containing a newline, bypassing the picker's normal restrictions and inserting an additional trusted scriptlet filter.

That trust distinction raised the severity. Filters created through the picker were treated as trusted until uBlock Origin recompiled its custom filters. Trusted scriptlets can inject code into pages. A hostile site could therefore arrange for JavaScript to execute in the security context of a different domain after persuading the user to click an obscured or overlaid picker control.

The disclosed fix adds an authentication value shared between the legitimate content script and the picker, preventing an arbitrary page from initiating the same conversation. The researcher's description also notes that changing custom filters could clear the injected filter's trusted state, but says an attacker could open the target page immediately, so that behavior was not an adequate defense.

The finding illustrates a recurring browser-extension risk: an interface designed to operate with elevated privileges must authenticate messages even when it is displayed inside ordinary web content. It also shows how separate behaviors—identifier disclosure, embeddable extension resources and permissive message handling—can combine into a cross-site compromise even when no single step initially appears decisive.