Insufficient validation of untrusted input in WebView (CVE-2026-11007)
A compromised renderer in Android WebView can spoof a flag in Mojo requests to bypass third-party cookie blocking, allowing a third-party iframe to access unpartitioned first-party cookies. This enables cross-site tracking despite the app disabling third-party cookies.
Google Chrome
Originally disclosed on Chrome VRP
- Fix shipped in 2 months
Project Fortify, an experimental security project, has identified the following potential security issue.
Overview: A compromised renderer can bypass Android WebView's third-party cookie blocking policy by spoofing the StorageAccessApiStatus::kAccessViaAPI flag in Mojo requests. This forces AwCookieAccessPolicy to unconditionally allow cookie access, granting a third-party iframe access to its unpartitioned first-party cookies.
Affected files:
android_webview/browser/aw_cookie_access_policy.ccandroid_webview/browser/network_service/aw_proxying_restricted_cookie_manager.cc
Estimated timestamp from git blame: 2025-01-17
A compromised renderer successfully bypasses Android WebView's third-party cookie blocking (setAcceptThirdPartyCookies(false)) by supplying net::StorageAccessApiStatus::kAccessViaAPI over Mojo, allowing cross-site tracking.
Technical Details
Initial WebView proxy architecture and Mojo routing for RestrictedCookieManager and URLLoaderFactory are validated. The WebView network context defaults to allowing cookies, relying entirely on the browser-process proxy (AwProxyingRestrictedCookieManager and AwProxyingURLLoaderFactory) for policy enforcement.
Standard IPC payload delivery is executed by the compromised renderer, sending cookie read/write requests or subresource loads with the storage_access_api_status field manipulated.
The vulnerability materializes directly in AwCookieAccessPolicy::CanAccessCookies (android_webview/browser/aw_cookie_access_policy.cc). When the spoofed kAccessViaAPI flag is evaluated, the code performs the following:
switch (storage_access_api_status) {
case net::StorageAccessApiStatus::kNone:
break;
case net::StorageAccessApiStatus::kAccessViaAPI:
return PrivacySetting::kStateAllowed;
}
// Otherwise, block third-party cookies.
bool should_allow_3pcs = ...
The switch statement immediately returns PrivacySetting::kStateAllowed. This unconditionally bypasses the subsequent should_allow_3pcs check. Consequently, the proxy computes disable_3pcs as false and forwards the request to the network service, which allows the unpartitioned cookie access.
A parallel bypass exists for network requests via URLLoaderFactory::CreateLoaderAndStart. In AwProxyingURLLoaderFactory::ConstructOptions, hasStorageAccess evaluates to true, preventing the proxy from applying the network::mojom::kURLLoadOptionBlockThirdPartyCookies option.
Potential Exploitation Steps
(Note: These are potential steps as the AI agent cannot execute code.)
- Standard setup: An Android app embeds a WebView, calls
setAcceptThirdPartyCookies(false), and loads a third-party iframe. - Renderer compromise is achieved within the third-party iframe.
- Standard proxy interaction applied: The compromised renderer issues a
RestrictedCookieManager::GetAllForUrlorURLLoaderFactory::CreateLoaderAndStartMojo request, settingstorage_access_api_statustokAccessViaAPI. - The proxy evaluates
CanAccessCookies, hits thekAccessViaAPIswitch case, and immediately returnskStateAllowed, finalizing the privacy bypass.
Suggested Fix
Android WebView currently hardcodes the Storage Access API permission to DENIED. Therefore, AwCookieAccessPolicy::CanAccessCookies should not treat kAccessViaAPI as an unconditional allow. The kAccessViaAPI case should either be removed (falling through to the standard 3PC checks) or explicitly treated as kStateDisallowed until the Storage Access API is fully and safely supported in WebView.
Evaluated with Chrome root at commit: 0eb4855bda702feaaa8b899336664f97e3df88b8
Results so far have been promising, but there can be wrong deductions. If this proves to be a false positive, please close as WAI; data from false positives will be used to improve accuracy over time. Please feel free to reach out to me if you have concerns or feedback.
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 code that checks cookie access treats a flag from the renderer (kAccessViaAPI) as an unconditional allow, skipping the normal third-party cookie checks.
What the attacker needed
Android app uses WebView with third-party cookies disabled; Attacker can compromise the renderer
The fix
The kAccessViaAPI case should be removed or treated as disallowed until the Storage Access API is fully supported in WebView.
How it was found
- An Android app embeds a WebView, calls setAcceptThirdPartyCookies(false), and loads a third-party iframe.
- The renderer within the third-party iframe is compromised.
- The compromised renderer sends a Mojo request (e.g., RestrictedCookieManager::GetAllForUrl or URLLoaderFactory::CreateLoaderAndStart) with storage_access_api_status set to kAccessViaAPI.
- The proxy evaluates CanAccessCookies, hits the kAccessViaAPI case, and returns kStateAllowed, bypassing the cookie block.
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.
Android WebView is a component that lets apps show web pages inside them. Normally, an app can tell WebView to block cookies from other websites (third-party cookies) to protect privacy. This report shows that if an attacker can take over the part of WebView that runs web content (the renderer), they can trick WebView into ignoring that block and letting a third-party website read cookies that should be off-limits.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.