The vulnerability is a Server-Side Request Forgery (SSRF) caused by a Time-of-check Time-of-use (TOCTOU) race condition, specifically through DNS rebinding. The root cause is the inconsistent handling of hostname resolution between the server-side validation logic and the client-side (browser) navigation.
The analysis of the patch 121c452d666d4749744dc2089287d0227aae2ed3 reveals that the core of the vulnerability lies within the assertBrowserNavigationAllowed function in extensions/browser/src/browser/navigation-guard.ts.
Before the patch, this function would perform a server-side check on a given URL's hostname. However, it did not account for the possibility that the browser, when later instructed to navigate to this URL, could resolve the same hostname to a different IP address. An attacker could exploit this by using a malicious DNS server that first provides a public IP to pass the server's check and then provides a private/internal IP to the browser, causing the browser to make a request to an internal service.
The patch addresses this by modifying assertBrowserNavigationAllowed to enforce a stricter policy. In "strict mode" (when private network access is disabled), the function now rejects any navigation URL that uses a hostname, unless that hostname is on an explicit allowlist. It requires the use of IP literals for navigation targets. This prevents the DNS rebinding attack by eliminating the second, uncontrolled DNS resolution by the browser for arbitrary hostnames.
While many other functions were modified in the commit, these changes were primarily to propagate the SSRF policy (ssrfPolicy) down the call stack to ensure the correct policy is available in assertBrowserNavigationAllowed and other CDP-related fetch operations. The fundamental logical flaw, however, was the missing check within assertBrowserNavigationAllowed. Therefore, this function is identified as the vulnerable function.