Improper input validation in WebAppInstalls (CVE-2026-113261)
A PWA manifest's file_handlers field was not properly validated, so a site could supply a key using the Linux x-scheme-handler convention and have it written into the installed .desktop file. This let the installed app register as a handler for arbitrary URL schemes such as mailto, bypassing the protocol_handlers restrictions and user prompts.
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: PWA manifests on Linux can potentially register as handlers for arbitrary URL schemes by misusing the 'file_handlers' field. By providing strings starting with 'x-scheme-handler/', an attacker can bypass the security restrictions and prefixes required by the 'protocol_handlers' API. This may lead to persistent OS-level interception of protocols like 'mailto:' and potential UI spoofing.
Affected files:
chrome/browser/web_applications/os_integration/file_handling_sub_manager.ccchrome/browser/web_applications/web_app_install_utils.ccchrome/browser/web_applications/os_integration/web_app_shortcut_linux.ccchrome/browser/shell_integration_linux.ccnet/base/mime_util.ccthird_party/blink/renderer/modules/manifest/manifest_parser.ccchrome/browser/web_applications/os_integration/web_app_shortcut.ccthird_party/blink/public/mojom/manifest/manifest.mojom
Estimated timestamp from git blame: 2019-12-03
Description
A potential logic vulnerability in the Progressive Web App (PWA) installation process on Linux allows a website to register itself as a handler for arbitrary URL schemes. This bypasses the security restrictions and user permission prompts usually required for protocol handler registration (the protocol_handlers field in the manifest), which enforces safelists and requires custom schemes to be prefixed with web+.
The issue exists because the file_handlers manifest field, intended for MIME type and file extension associations, is not sufficiently validated. On Linux, Chrome integrates these handlers by writing to the MimeType= line of a .desktop file. The browser fails to verify that the keys in the accept map are valid MIME types and do not contain protocol handler registrations using the x-scheme-handler/ convention used by Linux desktop environments.
Technical Details
When a PWA manifest is parsed, the renderer uses net::IsValidTopLevelMimeType() in net/base/mime_util.cc to validate the accept keys in file_handlers. This function accepts any top-level type starting with x- that is at least 3 characters long (e.g., x-scheme-handler).
- Renderer-side Parsing: In
third_party/blink/renderer/modules/manifest/manifest_parser.cc, the parser extracts the MIME type and validates it usingnet::IsValidTopLevelMimeType. A malicious manifest can provide a key like"x-scheme-handler/mailto". - Data Flow: The parsed string is sent to the browser process via Mojo (
blink::mojom::ManifestFileHandler). Inchrome/browser/web_applications/web_app_install_utils.cc, the functionPopulateFileHandlerInfoFromManifestcopies these strings verbatim into theWebAppInstallInfoobject (line 375) without further validation. - OS Integration: During PWA installation on Linux,
web_app_shortcut_linux.cccollects these MIME types and passes them toshell_integration_linux::GetDesktopFileContents. This function writes the attacker-controlled strings into the PWA's.desktopfile (typically in~/.local/share/applications/) usingg_key_file_set_string(line 613).
Because Linux desktop environments (following freedesktop.org standards) use x-scheme-handler/<scheme> entries in the MimeType field of .desktop files to determine protocol handlers, the PWA is successfully registered as a handler for the specified protocol. This registration occurs during initial installation, bypassing the protocol_handlers security model entirely.
Compromised Renderer Variant
In a scenario where the renderer is compromised, an attacker could potentially bypass the renderer-side checks in manifest_parser.cc and provide arbitrary strings to the browser process. This would allow the registration of sensitive MIME types, such as inode/directory, making the PWA a candidate handler for system locations in the OS "Open With" menus.
Impact
This is a persistent OS-level URL scheme and MIME type association vulnerability. A potential attacker could:
- Intercept protocol requests (e.g.,
mailto:,slack:,zoommtg:). - Spoof system "Open With" dialogs.
- Become the default handler for schemes that do not have a prior association on the user's system.
Potential Reproduction Steps
- Host a PWA manifest with the following entry:
{"file_handlers":[{"action":"/handle-mailto","accept":{"x-scheme-handler/mailto":[".eml"]}}]}. - On a Linux system (e.g., Ubuntu with GNOME), navigate to the site in Chrome and click the "Install" button in the omnibox.
- After installation, inspect the generated
.desktopfile in~/.local/share/applications/. Observe that theMimeType=line containsx-scheme-handler/mailto. - Attempt to open a
mailto:link (e.g., viaxdg-open mailto:[email protected]in a terminal). - Observe that the OS offers to open the link with the newly installed PWA.
Suggested Fix
The browser process should perform its own validation of MIME types received from the renderer during PWA installation. Specifically, in chrome/browser/web_applications/web_app_install_utils.cc, the PopulateFileHandlerInfoFromManifest function should verify that the MIME type strings are well-formed and do not contain the x-scheme-handler/ prefix or other sensitive system types.
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 the browser trusted the renderer's MIME type validation, which accepts any top-level type beginning with 'x-', and copied the strings verbatim into the Linux desktop file's MimeType line without checking for the x-scheme-handler convention.
Impact
A malicious PWA could persistently intercept protocol requests such as mailto, slack or zoommtg, spoof system Open With dialogs, and become the default handler for schemes with no prior association; the text notes the OS still offers a choice when a link is opened.
What the attacker needed
Linux desktop with Chrome; victim installs the PWA; attacker hosts a manifest
The fix
The browser process should validate MIME types received from the renderer during installation and reject the x-scheme-handler prefix and other sensitive system types.
How it was found
- Host a PWA manifest whose file_handlers accept map uses an x-scheme-handler key.
- On a Linux desktop, visit the site in Chrome and install the app from the omnibox.
- Inspect the generated .desktop file and note the x-scheme-handler entry on the MimeType line.
- Open a mailto link from the terminal and see the OS offer the new PWA as a handler.
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 install a web app, the browser writes a small file on your computer that tells the operating system what the app can open. Normally a site must ask permission and follow rules before it can claim a link type like email links. Here the browser accepted a specially named file type from the site and passed it straight into that system file, so the app could quietly claim link types it should never have been allowed to claim.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.