// Copyright 2022 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "content/browser/preloading/prerender/prerender_navigation_utils.h" #include "net/base/registry_controlled_domains/registry_controlled_domain.h" namespace content::prerender_navigation_utils { // https://wicg.github.io/nav-speculation/prerendering.html#no-bad-navs // > If browsingContext is a top level prerendering browsing context, and any of // the following hold: bool IsDisallowedHttpResponseCode(int response_code) { … } bool IsSameSite(const GURL& target_url, const url::Origin& origin) { … } bool IsSameSiteCrossOrigin(const GURL& target_url, const url::Origin& origin) { … } bool IsCrossSite(const GURL& target_url, const url::Origin& origin) { … } } // namespace content::prerender_navigation_utils