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

Unified Diff: chrome/browser/content_settings/cookie_settings.cc

Issue 8479027: Make third-party cookie blocking strict by default (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 9 years, 1 month 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 | « chrome/browser/chrome_browser_main.cc ('k') | chrome/browser/content_settings/cookie_settings_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/content_settings/cookie_settings.cc
diff --git a/chrome/browser/content_settings/cookie_settings.cc b/chrome/browser/content_settings/cookie_settings.cc
index 81af4da3b847d13fc0a5a81cc06bdbcd55e3ae93..4a345d609f106cb31ea311cc858788db46894b7a 100644
--- a/chrome/browser/content_settings/cookie_settings.cc
+++ b/chrome/browser/content_settings/cookie_settings.cc
@@ -219,11 +219,11 @@ ContentSetting CookieSettings::GetCookieSetting(
secondary_pattern == ContentSettingsPattern::Wildcard() &&
ShouldBlockThirdPartyCookies() &&
!first_party_url.SchemeIs(chrome::kExtensionScheme)) {
- bool strict = CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kBlockReadingThirdPartyCookies);
- net::StaticCookiePolicy policy(strict ?
- net::StaticCookiePolicy::BLOCK_ALL_THIRD_PARTY_COOKIES :
- net::StaticCookiePolicy::BLOCK_SETTING_THIRD_PARTY_COOKIES);
+ bool not_strict = CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kOnlyBlockSettingThirdPartyCookies);
+ net::StaticCookiePolicy policy(not_strict ?
+ net::StaticCookiePolicy::BLOCK_SETTING_THIRD_PARTY_COOKIES :
+ net::StaticCookiePolicy::BLOCK_ALL_THIRD_PARTY_COOKIES);
int rv;
if (setting_cookie)
rv = policy.CanSetCookie(url, first_party_url);
« no previous file with comments | « chrome/browser/chrome_browser_main.cc ('k') | chrome/browser/content_settings/cookie_settings_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698