Insufficient validation of untrusted input in Cast (CVE-2026-11259)
The Cast Media Controller did not validate image URLs received in MEDIA_STATUS messages from Cast receiver applications. A malicious receiver app could cause the Chrome browser process to make blind GET requests to arbitrary internal addresses, bypassing Local Network Access protections.
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. If you're a feature owner CC-ed on this bug, please do your best to review these reports without the security team.
Overview: The Cast Media Controller does not validate image URLs received in MEDIA_STATUS messages from Cast receiver applications. This potentially allows a malicious receiver app to trigger the Chrome browser process to perform blind GET requests to arbitrary internal addresses (e.g., localhost, private IPs), bypassing Local Network Access (LNA) protections.
Affected files:
chrome/browser/media/router/providers/cast/cast_media_controller.ccchrome/browser/ui/global_media_controls/cast_media_notification_item.cc
Estimated timestamp from git blame: 2024-12-23
Summary
A malicious Cast receiver application can potentially induce the Chrome browser process to issue HTTP/HTTPS GET requests to arbitrary addresses, including localhost (127.0.0.1), RFC1918 private ranges, and cloud metadata endpoints. This is achieved by sending a MEDIA_STATUS message with a crafted media.metadata.images[].url field.
The vulnerability stems from the URL being extracted from the network-provided JSON payload and converted to a GURL without validation (such as checking url.is_valid() or url.SchemeIsHTTPOrHTTPS()). This URL is subsequently downloaded by the CastMediaNotificationItem using a BitmapFetcher backed by a privileged browser-process URLLoaderFactory. Because this browser-initiated request lacks a client_security_state, it bypasses Local Network Access (LNA) enforcement.
Technical Details
1. Lack of URL Validation
In chrome/browser/media/router/providers/cast/cast_media_controller.cc, the UpdateMediaStatus function parses the MEDIA_STATUS message from the Cast receiver. It extracts the image URL from the JSON dictionary and populates the media_status_ object. The URL is instantiated as a GURL directly from the string without verifying its scheme or safety:
// chrome/browser/media/router/providers/cast/cast_media_controller.cc
const std::string* url_string = image_dict.FindString("url");
if (!url_string) continue;
media_status_.images.emplace_back(std::in_place, GURL(*url_string), ...);
2. Mojo Propagation and Automatic Trigger
The unvalidated media_status_ is then sent via a Mojo IPC call to registered observers, including CastMediaNotificationItem. When the status update arrives, CastMediaNotificationItem::OnMediaStatusUpdated automatically triggers a background download of the first image URL to display in the Global Media Controls UI:
// chrome/browser/ui/global_media_controls/cast_media_notification_item.cc
if (status->images.empty()) { ... } else {
image_downloader_.Download(status->images.at(0)->url);
}
3. Privileged Fetching and LNA Bypass
The ImageDownloader uses a BitmapFetcher initialized with GetURLLoaderFactoryForBrowserProcess():
url_loader_factory_(profile->GetDefaultStoragePartition()->GetURLLoaderFactoryForBrowserProcess())
The browser-process URLLoaderFactory is highly privileged. Because the ResourceRequest created by BitmapFetcher does not specify a client_security_state, the network service's LocalNetworkAccessChecker defaults to allowing the request:
// services/network/local_network_access_checker.cc
if (!client_security_state_) {
return Result::kAllowedMissingClientSecurityState;
}
This bypasses standard protections that would prevent web-influenced requests from reaching the local network or loopback interface.
Potential Attack Scenario
- An attacker registers a malicious Cast receiver app and hosts it on their server.
- A victim visits a page controlled by the attacker that uses the Cast Sender SDK to launch the attacker's receiver app ID.
- The victim initiates a Cast session (e.g., by clicking the Cast button and selecting their device).
- The malicious receiver app sends a
MEDIA_STATUSmessage containing an internal URL (e.g.,http://127.0.0.1:9222/json/version). - The Chrome browser process parses the message and automatically fetches the URL. Since the fetcher follows redirects by default, an attacker can also use a 302 redirect from a public HTTPS URL to an internal HTTP URL.
- The browser process executes a blind GET request against the targeted internal service.
Suggested Fix
Add URL validation in CastMediaController::UpdateMediaStatus before adding the image to the media_status_ object. Ensure the URL is valid and uses an allowed scheme:
GURL url(*url_string);
if (!url.is_valid() || !url.SchemeIsHTTPOrHTTPS()) {
continue;
}
media_status_.images.emplace_back(std::in_place, url, GetValidSize(image_dict));
Additionally, consider whether the BitmapFetcher used for media notifications should be restricted from accessing local network addresses, potentially by providing a restricted client_security_state to the URLLoaderFactoryParams or the ResourceRequest.
Evaluated with Chrome root at commit: ff3d2b74fa39431785bd60e51463b08fcc71ee33
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. 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 URL from the network-provided JSON payload was converted to a GURL without validation (such as checking url.is_valid() or url.SchemeIsHTTPOrHTTPS()), and was then fetched by a privileged browser-process URLLoaderFactory that lacked a client_security_state, bypassing Local Network Access enforcement.
Impact
A malicious Cast receiver app could potentially induce the Chrome browser process to issue HTTP/HTTPS GET requests to arbitrary addresses, including localhost, private IP ranges, and cloud metadata endpoints, bypassing Local Network Access protections.
What the attacker needed
Attacker-controlled Cast receiver app; victim visits attacker's page; victim initiates Cast session
The fix
Add URL validation in CastMediaController::UpdateMediaStatus to ensure the URL is valid and uses an allowed scheme, and consider restricting the BitmapFetcher from accessing local network addresses.
How it was found
- An attacker registers a malicious Cast receiver app and hosts it on their server.
- A victim visits a page controlled by the attacker that uses the Cast Sender SDK to launch the attacker's receiver app ID.
- The victim initiates a Cast session (e.g., by clicking the Cast button and selecting their device).
- The malicious receiver app sends a MEDIA_STATUS message containing an internal URL.
- The Chrome browser process parses the message and automatically fetches the URL.
- The browser process executes a blind GET request against the targeted internal service.
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 cast media to a TV, the receiver app can send back information about the media, including image URLs. This report found that Chrome would automatically download those images without checking if the URLs pointed to internal addresses like your router or local services. An attacker could abuse this to make your browser send requests to devices on your local network, potentially revealing information or triggering actions.
What is SSRF?
The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.