Use after free in Extensions (CVE-2026-12467)
A use-after-free vulnerability exists in Chromium's developerPrivate.updateExtensionConfiguration API where a raw pointer to an Extension object becomes dangling after a synchronous reload frees it, and subsequent operations dereference the freed memory. An attacker who compromises a renderer process hosting an allowlisted developer app could potentially trigger a double-free or arbitrary destructor execution, though exploitation is limited by strict preconditions and task boundary constraints.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 12 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 potential Use-After-Free (UAF) vulnerability exists in the browser process of Chromium within the developerPrivate.updateExtensionConfiguration API. Modifying certain configuration options (like file access or incognito access) synchronously reloads the extension, destroying the heap-allocated Extension object. Subsequent operations in the same execution path then dereference the now-dangling raw pointer.
Affected files:
chrome/browser/extensions/api/developer_private/developer_private_functions.cc
Estimated timestamp from git blame: 2015-03-19
Detailed Description
Within DeveloperPrivateUpdateExtensionConfigurationFunction::Run() (chrome/browser/extensions/api/developer_private/developer_private_functions.cc), a raw pointer to the target Extension is obtained and stored on the stack:
const Extension* extension = GetExtensionById(update.extension_id);
No scoped_refptr is taken to keep the Extension object alive during the function's execution.
When the configuration update contains a change to file_access (line 634) or incognito_access (line 638), the function invokes helper methods that synchronously trigger an extension reload:
util::SetAllowFileAccess(...)->ReloadExtension(...)util::SetIsIncognitoEnabled(...)->ReloadExtensionIfEnabled(...)
For a packed extension (e.g., a Web Store CRX), the reload flow is entirely synchronous:
ExtensionRegistrar::DoReloadExtensiondisables the extension, moving thescoped_refptrreference to thedisabled_extensions_set.ChromeExtensionRegistrarDelegate::LoadExtensionForReloadcallsInstalledLoader(profile_).Load(...)synchronously using cached in-memory manifest data.- This constructs a brand-new
Extensionobject on the heap and adds it viaExtensionRegistrar::AddExtension. ReplaceReloadedExtensionexecutesregistry_->RemoveDisabled(extension->id()), which drops the final reference to the oldExtensionobject, destroying it synchronously.
When control returns to DeveloperPrivateUpdateExtensionConfigurationFunction::Run(), the stack-local extension pointer is dangling. Any subsequent configuration fields present in the same update request (such as user_scripts_access, error_collection, or host_access) will dereference this freed pointer. Most notably, constructing the ScriptingPermissionsModifier on line 659:
ScriptingPermissionsModifier modifier(browser_context(), extension);
creates a temporary scoped_refptr from the dangling raw pointer. This results in an AddRef() operation on freed memory, followed by a Release() on scope exit, potentially leading to a double-free or arbitrary destructor execution.
Potential Steps to Trigger the Vulnerability
Note: Our tooling does not currently have the capability to execute code or run dynamic proofs of concept. The following steps are theoretical and based on manual analysis of the static code flow.
- A victim user must have one of seven deprecated platform apps (such as the Chrome Dev Editor, ID
AE27D69DBE571F4B1694F05C89B710C646792231) and any packed extension installed. - An attacker compromises the renderer process hosting the allowlisted developer app.
- The compromised renderer dispatches a
LocalFrameHost.RequestMojo message callingdeveloperPrivate.updateExtensionConfigurationwithuser_gesture = true, targetextension_id, and bothfile_accessandincognito_accesstoggles set to values that differ from current settings. - In the browser process,
Run()executes, reloads the extension synchronously via the first configuration handler, and frees the oldExtensionheap allocation. - The execution proceeds to the next handlers within the same task, dereferencing the dangling pointer and triggering the Use-After-Free condition.
Limitations on Exploitation
- Task Boundary Constraints: Because the reload and subsequent dereferences occur entirely synchronously within a single UI thread task, the browser does not return to the message loop. Consequently, Mojo message queues cannot be processed in the interim, making it extremely difficult to reliably race and reclaim the freed heap allocation with controlled bytes before the UAF occurs.
- Strict Preconditions: The API is restricted to
chrome://extensions(WebUI, which is trusted) and seven hard-coded developer platform apps which are deprecated and generally inactive.
Suggested Fix
To prevent the UAF, copy the ExtensionId of the target extension and hold a scoped_refptr<const Extension> on the stack, or re-fetch the pointer from the ExtensionRegistry if any operation that can trigger an extension reload has been executed.
Evaluated with Chrome root at commit: d8b226a3be7c9c1ac9240c09e14698866c82e4ac
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
The function stores a raw pointer to an Extension object without taking a reference-counted smart pointer, so a synchronous reload can free the object while the pointer is still used later in the same function.
Impact
An attacker who compromises a renderer process hosting an allowlisted developer app could potentially cause a double-free or arbitrary destructor execution, but exploitation is extremely difficult due to synchronous execution within a single task and strict API access restrictions.
What the attacker needed
Victim has a deprecated platform app installed; victim has a packed extension installed; attacker compromises renderer process
The fix
The function should hold a scoped_refptr to the Extension object or re-fetch the pointer from the registry after any operation that can trigger a reload.
How it was found
- A victim has one of seven deprecated platform apps and any packed extension installed.
- An attacker compromises the renderer process hosting the allowlisted developer app.
- The compromised renderer sends a Mojo message calling developerPrivate.updateExtensionConfiguration with file_access and incognito_access toggles set to different values.
- In the browser process, the function reloads the extension synchronously, freeing the old Extension object.
- Execution continues to later handlers that dereference the dangling pointer, triggering the use-after-free.
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 use-after-free happens when a program frees a chunk of memory but keeps a pointer to it, then later uses that pointer as if the memory still belonged to it. Here, the browser frees an extension object during a reload but continues to use a pointer to the old object, which could let an attacker who already controls part of the browser run harmful code. The attack is hard because the browser does not pause between freeing and reusing the memory, and only a few trusted apps can call the vulnerable function.
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.