Insufficient policy enforcement in WebUI (CVE-2024-3847)
The Content Security Policy for chrome://whats-new/ allowed any HTTPS page to be embedded in an iframe, not just the intended google.com/chrome/whats-new/ page. An attacker could exploit this to load their own site inside the chrome://whats-new/ frame, potentially for phishing.
- Fix shipped in 55 days
Security Bug
Please READ THIS FAQ before filing a bug: https://chromium.googlesource.com/chromium/src/+/HEAD/docs/security/faq.md
Please see the following link for instructions on filing security bugs: https://www.chromium.org/Home/chromium-security/reporting-security-bugs
Reports may be eligible for reward payments under the Chrome VRP: https://g.co/chrome/vrp
NOTE: Security bugs are normally made public once a fix has been widely deployed.
VULNERABILITY DETAILS In https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/webui/whats_new/whats_new_ui.cc;l=47-51?q=kOpenAISettings&ss=chromium, the Content Security Policy child-src directive is set to be "child-src chrome://webui-test https: google.com/chrome/whats-new/;". The comment above indicates the intent might have been to allow google.com/chrome/whats-new/ over HTTPS to load in an iframe on chrome://whats-new/, but in reality this CSP allows any HTTPS page to load in an iframe on chrome://whats-new/.
This means for instance if an attacker has an XSS or is able to insert a link on google.com/chrome/whats-new/ to their site, their site would load inside chrome://whats-new/. Since chrome://whats-new/ is what is shown in the URL bar, the attacker can abuse this for phishing.
Perhaps this was intentional but I'm not sure why this page needs to allow loading any HTTPS page. The guidelines in https://chromium.googlesource.com/chromium/src/+/main/docs/webui_explainer.md#Security-considerations state: "WebUIs have a default Content Security Policy which disallows embedding any frames. If you want to include any web content in an you will need to update the policy for your WebUI. When doing so, allow only known origins and avoid making the policy more permissive than strictly necessary."
VERSION Chrome Version: Version 122.0.6261.112 (Official Build) (arm64) stable Operating System: Macos 14.4 (23E214)
REPRODUCTION CASE Please include a demonstration of the security bug, such as an attached HTML or binary file that reproduces the bug when loaded in Chrome. PLEASE make the file as small as possible and remove any content not required to demonstrate the bug, or any personal or confidential information.
Please attach files directly, not in zip or other archive formats, and if you've created a demonstration site please also attach the files needed to reproduce the demonstration locally.
Here are steps to checking that this CSP indeed allows loading an arbitrary HTTPS site
- Open chrome://whats-new/ in Chrome.
- Open the devtools console and execute the following:
const i = document.createElement('iframe')
i.src = 'https://example.com'
document.body.appendChild(i)
Note the iframe is loaded without any CSP errors. Screenshot attached.
FOR CRASHES, PLEASE INCLUDE THE FOLLOWING ADDITIONAL INFORMATION Type of crash: [tab, browser, etc.] Crash State: [see link above: stack trace with symbols, registers, exception record] Client ID (if relevant): [see link above]
CREDIT INFORMATION Externally reported security bugs may appear in Chrome release notes. If this bug is included, how would you like to be credited? Reporter credit: Yan Zhu
Context
Chrome ships a number of built-in pages under the chrome:// scheme, collectively called WebUI. One of them is chrome://whats-new/, the page that presents the "What's new" content after a Chrome update. Because it is a privileged origin rendered by the browser itself, anything that loads inside it inherits the trust users place in the chrome:// URL shown in the address bar.
WebUI pages are protected by a default Content Security Policy that disallows embedding frames. A page that needs to embed external content has to relax that policy explicitly, and the Chromium WebUI guidance quoted in the report asks authors to allow only known origins and to avoid making the policy more permissive than strictly necessary.
The report concerns the child-src directive configured for chrome://whats-new/, defined in chrome/browser/ui/webui/whats_new/whats_new_ui.cc.
Setup
The issue was reproduced on a stable desktop build:
| Item | Value |
|---|---|
| Chrome version | 122.0.6261.112 (Official Build) (arm64) stable |
| Operating system | macOS 14.4 (23E214) |
No account, extension or special configuration is needed. The only tool is the DevTools console on the chrome://whats-new/ page itself.
Finding it
While reading the WebUI source, the researcher looked at the CSP configured for the What's New page. The child-src directive is set to:
child-src chrome://webui-test https: google.com/chrome/whats-new/;
A comment above the directive suggests the intent was to allow google.com/chrome/whats-new/ to be loaded over HTTPS in an iframe on chrome://whats-new/. The directive does not express that intent. In CSP source lists, https: is a scheme source that matches any HTTPS origin, so the policy permits any HTTPS page to be framed by chrome://whats-new/. The google.com/chrome/whats-new/ entry is a host source with a path, and it does not narrow the scheme source that sits beside it.
The researcher questioned why the page would need to allow loading any HTTPS page at all. The relevant guidance from the WebUI security documentation is quoted directly: WebUIs have a default CSP that disallows embedding any frames, and a WebUI that needs to include web content must update the policy, allowing only known origins and avoiding a policy more permissive than necessary.
Exploitation
Step 1: Open the privileged page
Navigate to chrome://whats-new/ in Chrome. This is the page whose origin appears in the URL bar and whose CSP is being tested.
Step 2: Attempt to frame an arbitrary HTTPS origin
In the DevTools console on that page, run:
const i = document.createElement('iframe')
i.src = 'https://example.com'
document.body.appendChild(i)
The script creates an iframe, points it at https://example.com, and appends it to the page body. If the CSP were enforcing the intended restriction, the frame would be blocked and a CSP violation would be reported in the console. Instead, the iframe loads with no CSP errors, which shows that an arbitrary HTTPS origin is accepted as a child frame of chrome://whats-new/.
Root cause
The mistake is in the CSP source list itself. The author appears to have written a scheme source (https:) alongside a specific host and path (google.com/chrome/whats-new/), likely believing the host entry constrained the scheme entry. It does not: each source in the list is an independent allowance, and https: on its own matches every HTTPS origin. The page therefore permits framing of any HTTPS site rather than only the intended Google path.
The default WebUI policy that disallows framing was relaxed for this page, so the usual defence did not apply. The permissive directive replaced it, and nothing else in the page's policy narrowed the allowance.
Impact
The practical consequence is that an attacker-controlled HTTPS page can be displayed inside chrome://whats-new/, while the URL bar continues to show the chrome://whats-new/ origin. The researcher describes two ways an attacker could reach that position: an XSS on google.com/chrome/whats-new/, or the ability to insert a link on that page pointing to their own site. In either case the attacker's site would load inside the privileged page.
That mismatch between the displayed chrome:// origin and the framed content can be abused for phishing: a victim sees a trusted browser URL while interacting with attacker content. The report frames this as the primary risk and does not claim code execution or access to browser internals.
Fix
The report does not describe the change that was made. The WebUI guidance it quotes asks authors to allow only known origins and keep the policy as restrictive as necessary.
Variants to test
- Other scheme sources in WebUI policies. Search WebUI CSP definitions for bare scheme sources such as
https:,http:or*inchild-src,frame-srcordefault-src. A positive result is achrome://page that frames an arbitrary origin of that scheme without a CSP error. - Host sources with paths next to broader entries. Look for directives that combine a specific host and path with a wider source, as here. A positive result is that the wider source, not the narrow one, determines what loads.
- Other privileged pages that embed web content. Any
chrome://page that intentionally frames external content is a candidate. A positive result is a frame whose origin is not on the intended allowlist appearing under the privileged URL. - Test-only origins in production policies. The
chrome://webui-testentry in this directive is worth checking elsewhere: a test origin left in a shipped policy may widen what can be framed. A positive result is a production page accepting frames from a test origin.
Hunting notes
This class of bug hides in configuration rather than in request handling, so it is found by reading source: WebUI CSP definitions, the comments above them, and the gap between the stated intent and the directive actually written. The signal during review is a source list that mixes a broad scheme source with a specific host and path, or a comment describing a narrow allowance that the directive does not implement.
Verification is cheap and needs no tooling beyond DevTools: create an iframe pointing at an unrelated origin on the privileged page and watch the console. A frame that loads without a CSP violation is the proof. The researcher showed impact by explaining the URL-bar deception and the phishing scenario, and by tying the finding to the project's own published WebUI security guidance, which makes the deviation from intended behaviour explicit for the triager.
What happened, in plain words
Chrome has a set of built-in pages that start with chrome://. One of them is chrome://whats-new/, the page that shows you what changed after Chrome updates. Because the browser itself draws this page, the address bar shows a chrome:// address, and people naturally trust it.
Chrome normally blocks other websites from being shown inside these built-in pages. A page that really needs to show outside content has to say so explicitly, and the rules say it should only allow the specific sites it needs. The What's New page did say so, but it wrote the rule in a way that allowed any secure website at all, not just the one intended. The researcher showed that an unrelated site could be loaded inside chrome://whats-new/ while the address bar still showed the trusted chrome:// address. That mismatch can be used for phishing: a victim sees a trusted browser address while looking at content the attacker controls.
Context
Chrome ships a number of built-in pages under the chrome:// scheme, collectively called WebUI. A scheme is the first part of a web address, the bit before ://, such as https or chrome. WebUI pages are drawn by the browser itself rather than fetched from the internet, which is why they get special trust.
One of these pages is chrome://whats-new/, the page that presents the "What's new" content after a Chrome update. Because it is a privileged origin rendered by the browser itself, anything that loads inside it inherits the trust users place in the chrome:// URL shown in the address bar. An origin is the combination of scheme, host and port that a browser uses to decide what a page is allowed to touch; two pages with the same origin are treated as the same site.
WebUI pages are protected by a default Content Security Policy that disallows embedding frames. A Content Security Policy, usually shortened to CSP, is a set of instructions a page sends to the browser saying which sources of content are allowed. A frame, or iframe, is a window inside a page that shows another page. The default policy says, in effect, "no other page may be shown inside this one". A page that needs to embed external content has to relax that policy explicitly, and the Chromium WebUI guidance quoted in the report asks authors to allow only known origins and to avoid making the policy more permissive than strictly necessary.
The report concerns the child-src directive configured for chrome://whats-new/, defined in chrome/browser/ui/webui/whats_new/whats_new_ui.cc. A directive is one line of a CSP that covers one kind of content; child-src covers frames and similar embedded content. The file path is where the source code that sets this policy lives.
Setup
The issue was reproduced on a stable desktop build:
| Item | Value |
|---|---|
| Chrome version | 122.0.6261.112 (Official Build) (arm64) stable |
| Operating system | macOS 14.4 (23E214) |
Stable means the ordinary public release of Chrome, not a test or developer build. arm64 refers to the processor type. No account, extension or special configuration is needed. The only tool is the DevTools console on the chrome://whats-new/ page itself. DevTools is the set of developer tools built into Chrome; its console is a place where you can type JavaScript commands and see the results. JavaScript is the programming language that web pages run in the browser.
Finding it
While reading the WebUI source, the researcher looked at the CSP configured for the What's New page. The child-src directive is set to:
child-src chrome://webui-test https: google.com/chrome/whats-new/;
This line lists three things that are allowed to appear as a child frame. chrome://webui-test is a test origin, presumably used for test content. https: is a scheme source: it matches any address that uses HTTPS, the secure version of the web protocol, no matter which website it is. google.com/chrome/whats-new/ is a host source with a path: it names one specific site and one specific folder on it. The semicolon at the end marks the end of the directive.
A comment above the directive suggests the intent was to allow google.com/chrome/whats-new/ to be loaded over HTTPS in an iframe on chrome://whats-new/. A comment is text in the source code meant for humans; the browser ignores it. The directive does not express that intent. In CSP source lists, https: is a scheme source that matches any HTTPS origin, so the policy permits any HTTPS page to be framed by chrome://whats-new/. The google.com/chrome/whats-new/ entry is a host source with a path, and it does not narrow the scheme source that sits beside it. Each item in the list is an independent permission, like a guest list where writing "anyone with a ticket" next to one person's name still lets in anyone with a ticket.
The researcher questioned why the page would need to allow loading any HTTPS page at all. The relevant guidance from the WebUI security documentation is quoted directly: WebUIs have a default CSP that disallows embedding any frames, and a WebUI that needs to include web content must update the policy, allowing only known origins and avoiding a policy more permissive than necessary.
Exploitation
Step 1: Open the privileged page
Navigate to chrome://whats-new/ in Chrome. This is the page whose origin appears in the URL bar and whose CSP is being tested. Opening it first puts you in the right context, because the console runs commands as that page.
Step 2: Attempt to frame an arbitrary HTTPS origin
In the DevTools console on that page, run:
const i = document.createElement('iframe')
i.src = 'https://example.com'
document.body.appendChild(i)
Line by line:
const i = document.createElement('iframe')creates a new frame element in memory and stores it in a variable calledi. Nothing is visible yet; the frame exists only as an object in the script.i.src = 'https://example.com'tells the frame which address to load.example.comis a neutral example site, unrelated to Google or Chrome.document.body.appendChild(i)attaches the frame to the visible page, which is the moment the browser tries to load the address and checks it against the CSP.
The script creates an iframe, points it at https://example.com, and appends it to the page body. If the CSP were enforcing the intended restriction, the frame would be blocked and a CSP violation would be reported in the console. A CSP violation is an error message the browser prints when a page tries to load something the policy forbids. Instead, the iframe loads with no CSP errors, which shows that an arbitrary HTTPS origin is accepted as a child frame of chrome://whats-new/.
Root cause
The mistake is in the CSP source list itself. The author appears to have written a scheme source (https:) alongside a specific host and path (google.com/chrome/whats-new/), likely believing the host entry constrained the scheme entry. It does not: each source in the list is an independent allowance, and https: on its own matches every HTTPS origin. The page therefore permits framing of any HTTPS site rather than only the intended Google path.
The default WebUI policy that disallows framing was relaxed for this page, so the usual defence did not apply. The permissive directive replaced it, and nothing else in the page's policy narrowed the allowance.
Impact
The practical consequence is that an attacker-controlled HTTPS page can be displayed inside chrome://whats-new/, while the URL bar continues to show the chrome://whats-new/ origin. The researcher describes two ways an attacker could reach that position: an XSS on google.com/chrome/whats-new/, or the ability to insert a link on that page pointing to their own site. XSS, short for cross-site scripting, is when an attacker manages to get their own code to run on someone else's page. In either case the attacker's site would load inside the privileged page.
That mismatch between the displayed chrome:// origin and the framed content can be abused for phishing: a victim sees a trusted browser URL while interacting with attacker content. Phishing is tricking someone into trusting a page that only looks legitimate. The report frames this as the primary risk and does not claim code execution or access to browser internals. A bounty is a payment a company makes to someone who reports a security problem responsibly.
Fix
The report does not describe the change that was made. The WebUI guidance it quotes asks authors to allow only known origins and keep the policy as restrictive as necessary.
Variants to test
- Other scheme sources in WebUI policies. Search WebUI CSP definitions for bare scheme sources such as
https:,http:or*inchild-src,frame-srcordefault-src. A positive result is achrome://page that frames an arbitrary origin of that scheme without a CSP error.frame-srcanddefault-srcare other CSP directives that control frames and fallback rules respectively;*is a wildcard meaning anything. - Host sources with paths next to broader entries. Look for directives that combine a specific host and path with a wider source, as here. A positive result is that the wider source, not the narrow one, determines what loads.
- Other privileged pages that embed web content. Any
chrome://page that intentionally frames external content is a candidate. A positive result is a frame whose origin is not on the intended allowlist appearing under the privileged URL. An allowlist is the list of things a policy permits. - Test-only origins in production policies. The
chrome://webui-testentry in this directive is worth checking elsewhere: a test origin left in a shipped policy may widen what can be framed. A positive result is a production page accepting frames from a test origin. Production means the version real users run, as opposed to a test build.
Hunting notes
This class of bug hides in configuration rather than in request handling, so it is found by reading source: WebUI CSP definitions, the comments above them, and the gap between the stated intent and the directive actually written. The signal during review is a source list that mixes a broad scheme source with a specific host and path, or a comment describing a narrow allowance that the directive does not implement.
Verification is cheap and needs no tooling beyond DevTools: create an iframe pointing at an unrelated origin on the privileged page and watch the console. A frame that loads without a CSP violation is the proof. The researcher showed impact by explaining the URL-bar deception and the phishing scenario, and by tying the finding to the project's own published WebUI security guidance, which makes the deviation from intended behaviour explicit for the triager. A triager is the person at the company who reviews a report and decides what to do with it.
Glossary
- WebUI: Chrome's built-in pages that start with
chrome://and are drawn by the browser itself. - Scheme: the first part of a web address, before
://, such ashttpsorchrome. - Origin: the combination of scheme, host and port that identifies a page and decides what it may access.
- Content Security Policy (CSP): instructions from a page telling the browser which sources of content are allowed.
- Directive: one line of a CSP covering one kind of content, such as
child-srcfor frames. - child-src: the CSP directive that controls which pages may be embedded as frames.
- frame-src: a CSP directive that controls frame sources, similar in purpose to
child-src. - default-src: a CSP directive used as a fallback when a more specific directive is absent.
- iframe: a window inside a page that shows another page.
- Scheme source: a CSP entry like
https:that matches any address using that scheme. - Host source: a CSP entry naming a specific site, optionally with a path.
- Wildcard (
*): a symbol meaning "anything" in a policy. - Allowlist: the list of things a policy permits.
- DevTools: the developer tools built into Chrome, including a console for running JavaScript.
- JavaScript: the programming language web pages run in the browser.
- XSS (cross-site scripting): getting an attacker's code to run on someone else's page.
- Phishing: tricking someone into trusting a page that only looks legitimate.
- Stable: the ordinary public release of Chrome, as opposed to a test build.
- arm64: a type of processor architecture.
- Production: the version real users run.
- Triager: the person at a company who reviews a security report and decides what to do with it.
- Bounty: a payment made for a responsibly reported security problem.
- Chrome VRP: Chrome's Vulnerability Reward Program, which pays for security reports.
- CVE: a public identifier assigned to a known security vulnerability.