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

Unified Diff: net/cookies/canonical_cookie.cc

Issue 1131963003: Switch //net functions to use SchemeIsCryptographic() instead of SchemeIsSecure(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing. Created 5 years, 7 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: net/cookies/canonical_cookie.cc
diff --git a/net/cookies/canonical_cookie.cc b/net/cookies/canonical_cookie.cc
index d9579767584b959bf51284260c6a97f34443db9f..eae8298fc78e69eb4225739c5c220222012068f4 100644
--- a/net/cookies/canonical_cookie.cc
+++ b/net/cookies/canonical_cookie.cc
@@ -186,7 +186,7 @@ std::string CanonicalCookie::GetCookieSourceFromURL(const GURL& url) {
url::Replacements<char> replacements;
replacements.ClearPort();
- if (url.SchemeIsSecure())
+ if (url.SchemeIsCryptographic())
replacements.SetScheme("http", url::Component(0, 4));
return url.GetOrigin().ReplaceComponents(replacements).spec();
@@ -394,7 +394,7 @@ bool CanonicalCookie::IncludeForRequestURL(const GURL& url,
return false;
// Secure cookies should not be included in requests for URLs with an
// insecure scheme.
- if (IsSecure() && !url.SchemeIsSecure())
+ if (IsSecure() && !url.SchemeIsCryptographic())
return false;
// Don't include cookies for requests that don't apply to the cookie domain.
if (!IsDomainMatch(url.host()))

Powered by Google App Engine
This is Rietveld 408576698