Use after free in Omnibox (CVE-2026-14005)
A raw pointer to an Omnibox autocomplete match was captured across asynchronous clipboard image processing callbacks on Android. If the result set was updated while encoding ran, the match could be destroyed and the callback would then write into freed memory, giving a controlled-free and heap-write primitive in the browser process.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 43 days
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 raw pointer to an AutocompleteMatch is captured in asynchronous callbacks during clipboard image processing on Android. If a result update occurs while the background tasks are running, the underlying match object can be destroyed, leading to a Use-After-Free (UAF) in the browser process.
Affected files:
components/omnibox/browser/clipboard_provider.cccomponents/omnibox/browser/autocomplete_match_android.cccomponents/omnibox/browser/autocomplete_controller.cccomponents/omnibox/browser/autocomplete_result.cc
Estimated timestamp from git blame: Unknown (Google3 checkout)
Summary
A potential Use-After-Free (UAF) vulnerability has been identified in the browser process within the Omnibox's ClipboardProvider on Android. The issue stems from capturing a raw pointer to an AutocompleteMatch object across multiple asynchronous ThreadPool hops. If the Omnibox result set is updated (e.g., due to user typing or an asynchronous provider finishing) while image encoding is in progress, the original match object is destroyed, causing a UAF when the callback returns to the UI thread.
Potential Vulnerability Details
On Android, when a user interacts with a clipboard image suggestion, the native AutocompleteMatch::UpdateWithClipboardContent is invoked. This method passes a raw this pointer to ClipboardProvider::UpdateClipboardMatchWithContent to initiate image processing.
For image matches (CLIPBOARD_IMAGE), this pointer is bound into a chain of callbacks involving two asynchronous round-trips to the ThreadPool:
- Read Phase:
ClipboardAndroid::ReadPngretrieves the raw image data on a background thread. - Encode Phase:
ClipboardProvider::EncodeClipboardImageresizes and encodes the image for search processing on a background thread.
The encoding phase can take a significant amount of time (200-800ms for high-resolution images), creating a large race window. During this window, any event that triggers a result update in the AutocompleteController (such as a character being typed or a network-based provider completing) will invoke AutocompleteController::NotifyChanged.
Inside NotifyChanged, the internal_result_ vector (containing the match object) is replaced. Crucially, this method uses base::ScopedSafetyChecksExclusion, which disables PartitionAlloc's scheduler-loop quarantine, allowing the memory occupied by the destroyed AutocompleteMatch elements to be immediately reclaimed by the allocator.
When the processing callback OnReceiveImageMatchForMatchWithContent eventually executes on the UI thread, it dereferences the dangling match pointer. The code performs move-assignments into the object:
match->destination_url = std::move(optional_match->destination_url);
match->post_content = std::move(optional_match->post_content);
match->search_terms_args = std::move(optional_match->search_terms_args);
Since post_content is a std::unique_ptr, this operation triggers a reset() on the memory address. An attacker who has reclaimed the memory can use this to achieve a controlled-free primitive and a heap write within the unsandboxed browser process.
Potential Steps to Reproduce
- A malicious website writes a high-resolution PNG image to the system clipboard using the
navigator.clipboard.write()API. - The user focuses the Chrome Android omnibox, causing the
ClipboardProviderto generate a suggestion for the image. - The user interacts with the suggestion (e.g., tapping the 'reveal' or 'search' button).
- While the image is being processed asynchronously (the encoding window), the attacker triggers a result update (e.g., by ensuring another asynchronous provider returns data or by the user typing).
AutocompleteControllerdestroys the original match object and reclaims the memory.- The image processing callback executes, dereferencing the dangling pointer and causing memory corruption.
Suggested Fix
Do not use a raw pointer to an AutocompleteMatch across asynchronous boundaries. Instead, use a base::WeakPtr<AutocompleteMatch> (and ensure the AutocompleteMatch remains in a stable memory location) or pass a unique identifier for the match and look it up in the current AutocompleteResult when the callback returns to the UI thread.
Evaluated with Chrome root at commit: 29093e11cf509e3593f6229e4b1b075cca356049
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 a raw `this` pointer to an `AutocompleteMatch` was bound into asynchronous ThreadPool callbacks, so the object could be destroyed by a result update before the callback returned to the UI thread.
Impact
An attacker could achieve a controlled-free primitive and a heap write within the unsandboxed browser process, though the report is a potential issue and does not demonstrate exploitation.
What the attacker needed
Chrome on Android; Victim copies an image to the clipboard; Victim interacts with the omnibox suggestion; Attacker can trigger a result update
The fix
The raw pointer should be replaced with a weak pointer to the match, or a unique identifier looked up in the current result set when the callback returns.
How it was found
- A malicious site writes a high-resolution PNG to the clipboard via the clipboard write API.
- The user focuses the Android omnibox so a suggestion for the image is generated.
- The user interacts with the suggestion, for example tapping reveal or search.
- During the asynchronous encoding window, the attacker triggers a result update.
- The controller destroys the original match and the memory is reclaimed.
- The image processing callback runs and dereferences the dangling pointer, causing memory corruption.
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 you type in the address bar, the browser builds a list of suggestions, and each suggestion is an object in memory. This code kept a direct reference to one suggestion while a slow background job ran, without checking the suggestion still existed; if the list was rebuilt meanwhile, the reference pointed at freed memory and the code wrote into it. Writing into freed memory can let an attacker influence what the program does next.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.