Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Unified Diff: third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp

Issue 2393633006: Send net's ReferrerPolicy back to Blink while following redirects (Closed)
Patch Set: Remove unnecessary referrer calculation in DocumentThreadableLoader Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/security/referrerPolicyHeader/resources/redirect-to.php ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp
diff --git a/third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp b/third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp
index c63f603fee78b093d90822ea278b0da6c81d9050..1e741c89bf7955cd48ff808201406e438f7a863f 100644
--- a/third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp
+++ b/third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp
@@ -370,9 +370,7 @@ void DocumentThreadableLoader::makeCrossOriginAccessRequest(
? WebURLRequest::FetchCredentialsModeInclude
: WebURLRequest::FetchCredentialsModeOmit);
if (m_didRedirect) {
- crossOriginRequest.setHTTPReferrer(SecurityPolicy::generateReferrer(
- m_referrerAfterRedirect.referrerPolicy, crossOriginRequest.url(),
- m_referrerAfterRedirect.referrer));
+ crossOriginRequest.setHTTPReferrer(m_referrerAfterRedirect);
}
loadRequest(crossOriginRequest, crossOriginOptions);
} else {
@@ -391,9 +389,7 @@ void DocumentThreadableLoader::makeCrossOriginAccessRequest(
m_actualOptions = crossOriginOptions;
if (m_didRedirect) {
- m_actualRequest.setHTTPReferrer(SecurityPolicy::generateReferrer(
- m_referrerAfterRedirect.referrerPolicy, m_actualRequest.url(),
- m_referrerAfterRedirect.referrer));
+ m_actualRequest.setHTTPReferrer(m_referrerAfterRedirect);
}
bool shouldForcePreflight =
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/security/referrerPolicyHeader/resources/redirect-to.php ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698