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

Unified Diff: third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h

Issue 2674973006: Move parsing of referrer policy header values to SecurityPolicy (Closed)
Patch Set: Created 3 years, 10 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
Index: third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h
diff --git a/third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h b/third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h
index 6ff5bc4ec82888b458c9c16eed570629c3840dd4..01ee6a2cac2560cf919e021e4582b69495d702b3 100644
--- a/third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h
+++ b/third_party/WebKit/Source/platform/weborigin/SecurityPolicy.h
@@ -40,6 +40,11 @@ namespace blink {
class KURL;
class SecurityOrigin;
+enum ReferrerPolicyLegacyKeywordsSupport {
+ SupportReferrerPolicyLegacyKeywords,
+ DoNotSupportReferrerPolicyLegacyKeywords,
+};
+
class PLATFORM_EXPORT SecurityPolicy {
STATIC_ONLY(SecurityPolicy);
@@ -81,10 +86,12 @@ class PLATFORM_EXPORT SecurityPolicy {
static bool isUrlWhiteListedTrustworthy(const KURL&);
static bool referrerPolicyFromString(const String& policy,
+ ReferrerPolicyLegacyKeywordsSupport,
ReferrerPolicy* result);
- static bool referrerPolicyFromStringWithLegacyKeywords(
- const String& policy,
- ReferrerPolicy* result);
+
+ static bool referrerPolicyFromHeaderValue(const String& headerValue,
+ ReferrerPolicyLegacyKeywordsSupport,
+ ReferrerPolicy* result);
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698