Incomplete cleanup in Extensions (CVE-2026-113010)
A logic flaw in the extension event listener cleanup code means that when a filtered listener is removed while an unfiltered listener for the same event still exists, the event stays marked as filtered. A compromised renderer could then cause all future events of that type to be silently dropped for every extension in the profile.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 5 months
Project Fortify, an experimental security project, has identified the following potential security issue. If you're a feature owner CC-ed on this bug, please do your best to review these reports. Please see https://chromium.googlesource.com/chromium/src/+/main/docs/security/ai-generated-security-bugs-faq.md for more information.
Overview: A logic flaw in EventListenerMap::CleanupListener allows a compromised web renderer to permanently prevent delivery of arbitrary unfiltered extension events profile-wide. By adding and then removing a valid filtered listener, a renderer can leave the target event permanently flagged as filtered. Because no matchers remain after removal, all subsequent events of that type are silently dropped instead of being dispatched to unfiltered listeners.
Affected files:
extensions/browser/event_listener_map.cc
Estimated timestamp from git blame: 2020-06-12
Root Cause Analysis
In extensions/browser/event_listener_map.cc, EventListenerMap::CleanupListener is responsible for cleaning up state when an EventListener is removed. Specifically, it decides whether to erase an event name from filtered_events_ by checking whether the listener being removed is the only listener currently registered for that event name:
// extensions/browser/event_listener_map.cc
void EventListenerMap::CleanupListener(EventListener* listener) {
if (listener->matcher_id() == -1) {
return;
}
auto iter = listeners_.find(listener->event_name());
if (iter->second.size() == 1) { // <--- BUG: Counts itself before removal, ignores other listeners' filter status
filtered_events_.erase(iter->first);
}
CHECK_EQ(1u, listeners_by_matcher_id_.erase(listener->matcher_id()));
}
Both removal paths invoke CleanupListener before the listener is actually removed from the vector in the map:
// extensions/browser/event_listener_map.cc: RemoveListener
event_filter_.RemoveEventMatchers(matcher_ids_to_remove);
CleanupListener(it.get()); // size() still includes `it`
std::swap(it, listeners.back());
listeners.pop_back();
The Flaw
If a filtered listener is removed while any other listener (such as a victim extension's unfiltered listener, which has matcher_id() == -1) is registered for the same event, the size of the listener list is 2 (or greater).
As a result, iter->second.size() == 1 evaluates to false, and filtered_events_.erase is skipped. The event name remains permanently in filtered_events_ even though no filtered listeners remain.
Subsequently, during event broadcasting, GetEventListeners sees the event is marked as a "filtered event" and routes it through the filter matching pipeline instead of returning the active unfiltered listeners:
// extensions/browser/event_listener_map.cc: GetEventListeners
if (IsFilteredEvent(event)) { // evaluates to true due to stale entry
std::set<MatcherID> ids = event_filter_.MatchEvent(
event.event_name, *event.filter_info, IPC::mojom::kRoutingIdNone);
for (const MatcherID& id : ids) {
auto it = listeners_by_matcher_id_.find(id);
if (it != listeners_by_matcher_id_.end()) {
interested_listeners.insert(it->second);
}
}
} else {
for (const auto& listener : GetEventListenersByName(event.event_name)) {
interested_listeners.insert(listener.get()); // Never reached
}
}
Since the attacker's matcher was already removed from event_filter_, MatchEvent returns an empty set. The victim's unfiltered listener is completely ignored, and the event is silently dropped.
Potential Attack Scenario
An attacker with control of a compromised sandboxed web renderer could potentially execute the following steps to permanently silence extension events (such as tabs.onUpdated, storage.onChanged, or security/audit-related events) profile-wide:
- Target an event that has an active unfiltered listener registered by a victim extension.
- Bind the
extensions.mojom.EventRouterinterface (exposed to renderers inChromeContentBrowserClientExtensionsPart::ExposeInterfacesToRendererForRenderFrameHost). - Call
AddFilteredListenerForMainThreadwith a valid filter (e.g.,{"url": [{"hostEquals": "attacker.example"}]}), specifying the renderer's own committed origin URL to pass theValidateMainThreadListenerOwnercheck. - This causes
filtered_events_.insert(event_name)to execute, marking the target event as filtered. - Call
RemoveFilteredListenerForMainThread(or terminate/navigate the renderer process, triggeringRenderProcessExited->RemoveListenersForProcess). - Due to the logic bug, the listener is removed, but the event remains permanently in
filtered_events_because the victim's unfiltered listener is still present. - All future dispatches of that event type are permanently blackholed.
Note: Our tooling does not currently have the capability to run code to supply a live proof-of-concept, but static analysis indicates this logic path is fully reachable.
Proposed Fix
Instead of checking iter->second.size() == 1, CleanupListener should determine if any other filtered listeners (listeners where matcher_id() != -1) remain in the listener list for that event name. If no other filtered listeners exist, the event name should be erased from filtered_events_:
void EventListenerMap::CleanupListener(EventListener* listener) {
if (listener->matcher_id() == -1) {
return;
}
auto iter = listeners_.find(listener->event_name());
if (iter != listeners_.end()) {
bool remaining_filtered_listener = false;
for (const auto& remaining : iter->second) {
if (remaining.get() != listener && remaining->matcher_id() != -1) {
remaining_filtered_listener = true;
break;
}
}
if (!remaining_filtered_listener) {
filtered_events_.erase(iter->first);
}
}
CHECK_EQ(1u, listeners_by_matcher_id_.erase(listener->matcher_id()));
}
Evaluated with Chrome root at commit: 208ca3371d87589335b108c431b95a36d768dc47
Results so far have been promising, but there can be wrong deductions. Feel free to adjust as follows:
- If you are familiar with the severity guidelines, you may adjust the severity.
- If this is a false positive, and there's no work to be done, please close as WAI.
- If there is work to do here but not a vulnerability, please change the issue type to Task/Bug/FR.
Data from false positives will be used to improve accuracy over time. And please feel free to reach out to me directly if you have concerns or feedback on the project.
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 cleanup routine decides whether to clear the 'filtered event' marker by counting all listeners for the event rather than checking whether any other filtered listener remains, and it runs before the listener is actually removed.
Impact
A compromised renderer could permanently stop delivery of chosen extension events across the whole profile; the report notes no live proof-of-concept was run and the path is shown only by static analysis.
What the attacker needed
Control of a compromised renderer; a victim extension with an unfiltered listener
The fix
The cleanup should check whether any other filtered listeners remain for the event and only then clear the filtered marker; the report proposes this change but does not say it was applied.
How it was found
- Find an event that a victim extension listens to without a filter.
- Bind the event router interface exposed to renderers.
- Add a filtered listener with a valid filter using the renderer's own origin.
- Remove the filtered listener, or let the renderer process exit.
- The event stays marked as filtered and later dispatches are dropped.
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.
Browser extensions can ask to be told about things like a tab changing. Some ask for only certain events (a filter), others ask for all of them. A mistake in the code that tidies up when a filtered request is removed leaves a note saying the event is still filtered, so the browser stops delivering that event to anyone, including extensions that wanted all of them.
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.