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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 10407124: Don't force non-session only cookies to be session only cookies, instead delete on shutdown (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/content_settings/host_content_settings_map.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <set> 7 #include <set>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 884 matching lines...) Expand 10 before | Expand all | Expand 10 after
895 const std::string& cookie_line, 895 const std::string& cookie_line,
896 content::ResourceContext* context, 896 content::ResourceContext* context,
897 int render_process_id, 897 int render_process_id,
898 int render_view_id, 898 int render_view_id,
899 net::CookieOptions* options) { 899 net::CookieOptions* options) {
900 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 900 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
901 ProfileIOData* io_data = ProfileIOData::FromResourceContext(context); 901 ProfileIOData* io_data = ProfileIOData::FromResourceContext(context);
902 CookieSettings* cookie_settings = io_data->GetCookieSettings(); 902 CookieSettings* cookie_settings = io_data->GetCookieSettings();
903 bool allow = cookie_settings->IsSettingCookieAllowed(url, first_party); 903 bool allow = cookie_settings->IsSettingCookieAllowed(url, first_party);
904 904
905 if (cookie_settings->IsCookieSessionOnly(url))
906 options->set_force_session();
907
908 BrowserThread::PostTask( 905 BrowserThread::PostTask(
909 BrowserThread::UI, FROM_HERE, 906 BrowserThread::UI, FROM_HERE,
910 base::Bind(&TabSpecificContentSettings::CookieChanged, render_process_id, 907 base::Bind(&TabSpecificContentSettings::CookieChanged, render_process_id,
911 render_view_id, url, first_party, cookie_line, *options, 908 render_view_id, url, first_party, cookie_line, *options,
912 !allow)); 909 !allow));
913 return allow; 910 return allow;
914 } 911 }
915 912
916 bool ChromeContentBrowserClient::AllowSaveLocalState( 913 bool ChromeContentBrowserClient::AllowSaveLocalState(
917 content::ResourceContext* context) { 914 content::ResourceContext* context) {
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
1615 #if defined(USE_NSS) 1612 #if defined(USE_NSS)
1616 crypto::CryptoModuleBlockingPasswordDelegate* 1613 crypto::CryptoModuleBlockingPasswordDelegate*
1617 ChromeContentBrowserClient::GetCryptoPasswordDelegate( 1614 ChromeContentBrowserClient::GetCryptoPasswordDelegate(
1618 const GURL& url) { 1615 const GURL& url) {
1619 return browser::NewCryptoModuleBlockingDialogDelegate( 1616 return browser::NewCryptoModuleBlockingDialogDelegate(
1620 browser::kCryptoModulePasswordKeygen, url.host()); 1617 browser::kCryptoModulePasswordKeygen, url.host());
1621 } 1618 }
1622 #endif 1619 #endif
1623 1620
1624 } // namespace chrome 1621 } // namespace chrome
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/content_settings/host_content_settings_map.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698