summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-05 08:32:26 +0000
committerjochen@chromium.org <jochen@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-05 08:32:26 +0000
commitab5925d2acd4ba13e80bea026b0e95b43a82d273 (patch)
tree20b5920016f5bd79b1d2f915fd048618120c5b0a
parent8b114c5f3c00188bd69da86f7739cc7fac74b27d (diff)
downloadchromium_src-ab5925d2acd4ba13e80bea026b0e95b43a82d273.zip
chromium_src-ab5925d2acd4ba13e80bea026b0e95b43a82d273.tar.gz
chromium_src-ab5925d2acd4ba13e80bea026b0e95b43a82d273.tar.bz2
Merge 124282 - Disable storing cookies from URLFetchers that run with a profile's cookie jar.
BUG=116253 TEST=none Review URL: https://chromiumcodereview.appspot.com/9545005 TBR=jochen@chromium.org Review URL: https://chromiumcodereview.appspot.com/9600012 git-svn-id: svn://svn.chromium.org/chrome/branches/1025/src@124928 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/alternate_nav_url_fetcher.cc4
-rw-r--r--chrome/browser/autocomplete/search_provider.cc2
-rw-r--r--chrome/browser/autofill/autofill_download.cc2
-rw-r--r--chrome/browser/extensions/webstore_install_helper.cc2
-rw-r--r--chrome/browser/feedback/feedback_util.cc3
-rw-r--r--chrome/browser/importer/toolbar_importer.cc5
-rw-r--r--chrome/browser/profiles/profile_downloader.cc3
-rw-r--r--chrome/browser/search_engines/template_url_fetcher.cc2
-rw-r--r--chrome/browser/spellchecker/spellcheck_host_impl.cc2
9 files changed, 22 insertions, 3 deletions
diff --git a/chrome/browser/alternate_nav_url_fetcher.cc b/chrome/browser/alternate_nav_url_fetcher.cc
index d2bf6f1..08b12f6 100644
--- a/chrome/browser/alternate_nav_url_fetcher.cc
+++ b/chrome/browser/alternate_nav_url_fetcher.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -17,6 +17,7 @@
#include "content/public/browser/web_contents.h"
#include "grit/generated_resources.h"
#include "grit/theme_resources_standard.h"
+#include "net/base/load_flags.h"
#include "net/base/registry_controlled_domain.h"
#include "net/url_request/url_request.h"
#include "ui/base/l10n/l10n_util.h"
@@ -190,6 +191,7 @@ void AlternateNavURLFetcher::StartFetch(NavigationController* controller) {
GURL(alternate_nav_url_), content::URLFetcher::HEAD, this));
fetcher_->SetRequestContext(
controller_->GetBrowserContext()->GetRequestContext());
+ fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
fetcher_->Start();
}
diff --git a/chrome/browser/autocomplete/search_provider.cc b/chrome/browser/autocomplete/search_provider.cc
index 62d5b92..037f020 100644
--- a/chrome/browser/autocomplete/search_provider.cc
+++ b/chrome/browser/autocomplete/search_provider.cc
@@ -32,6 +32,7 @@
#include "googleurl/src/url_util.h"
#include "grit/generated_resources.h"
#include "net/base/escape.h"
+#include "net/base/load_flags.h"
#include "net/http/http_response_headers.h"
#include "net/url_request/url_request_status.h"
#include "ui/base/l10n/l10n_util.h"
@@ -446,6 +447,7 @@ content::URLFetcher* SearchProvider::CreateSuggestFetcher(
content::URLFetcher::GET,
this);
fetcher->SetRequestContext(profile_->GetRequestContext());
+ fetcher->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
fetcher->Start();
return fetcher;
}
diff --git a/chrome/browser/autofill/autofill_download.cc b/chrome/browser/autofill/autofill_download.cc
index f00e1e9..e6cd519 100644
--- a/chrome/browser/autofill/autofill_download.cc
+++ b/chrome/browser/autofill/autofill_download.cc
@@ -20,6 +20,7 @@
#include "chrome/common/pref_names.h"
#include "content/public/common/url_fetcher.h"
#include "googleurl/src/gurl.h"
+#include "net/base/load_flags.h"
#include "net/http/http_response_headers.h"
#include "third_party/libjingle/source/talk/xmllite/xmlparser.h"
@@ -170,6 +171,7 @@ bool AutofillDownloadManager::StartRequest(
fetcher->SetAutomaticallyRetryOn5xx(false);
fetcher->SetRequestContext(request_context);
fetcher->SetUploadData("text/plain", form_xml);
+ fetcher->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
fetcher->Start();
return true;
}
diff --git a/chrome/browser/extensions/webstore_install_helper.cc b/chrome/browser/extensions/webstore_install_helper.cc
index fbc67d3..7f6beb4 100644
--- a/chrome/browser/extensions/webstore_install_helper.cc
+++ b/chrome/browser/extensions/webstore_install_helper.cc
@@ -11,6 +11,7 @@
#include "chrome/common/chrome_utility_messages.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/common/url_fetcher.h"
+#include "net/base/load_flags.h"
#include "net/url_request/url_request_context_getter.h"
#include "net/url_request/url_request_status.h"
@@ -58,6 +59,7 @@ void WebstoreInstallHelper::Start() {
url_fetcher_.reset(content::URLFetcher::Create(
icon_url_, content::URLFetcher::GET, this));
url_fetcher_->SetRequestContext(context_getter_);
+ url_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
url_fetcher_->Start();
// We'll get called back in OnURLFetchComplete.
diff --git a/chrome/browser/feedback/feedback_util.cc b/chrome/browser/feedback/feedback_util.cc
index d08a695..697afb89 100644
--- a/chrome/browser/feedback/feedback_util.cc
+++ b/chrome/browser/feedback/feedback_util.cc
@@ -31,6 +31,7 @@
#include "grit/generated_resources.h"
#include "grit/locale_settings.h"
#include "grit/theme_resources.h"
+#include "net/base/load_flags.h"
#include "net/url_request/url_request_status.h"
#include "ui/base/l10n/l10n_util.h"
#include "unicode/locid.h"
@@ -200,7 +201,7 @@ void FeedbackUtil::SendFeedback(Profile* profile,
post_url, content::URLFetcher::POST,
new FeedbackUtil::PostCleanup(profile, post_body, previous_delay));
fetcher->SetRequestContext(profile->GetRequestContext());
-
+ fetcher->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
fetcher->SetUploadData(std::string(kProtBufMimeType), *post_body);
fetcher->Start();
}
diff --git a/chrome/browser/importer/toolbar_importer.cc b/chrome/browser/importer/toolbar_importer.cc
index 0c7adba..d958638 100644
--- a/chrome/browser/importer/toolbar_importer.cc
+++ b/chrome/browser/importer/toolbar_importer.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -19,6 +19,7 @@
#include "content/public/browser/browser_thread.h"
#include "content/public/common/url_fetcher.h"
#include "grit/generated_resources.h"
+#include "net/base/load_flags.h"
using content::BrowserThread;
@@ -213,6 +214,7 @@ void Toolbar5Importer::GetAuthenticationFromServer() {
token_fetcher_ = content::URLFetcher::Create(
url, content::URLFetcher::GET, this);
token_fetcher_->SetRequestContext(request_context_getter_.get());
+ token_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
token_fetcher_->Start();
}
@@ -247,6 +249,7 @@ void Toolbar5Importer::GetBookmarkDataFromServer(const std::string& response) {
data_fetcher_ = content::URLFetcher::Create(
url, content::URLFetcher::GET, this);
data_fetcher_->SetRequestContext(request_context_getter_.get());
+ data_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
data_fetcher_->Start();
}
diff --git a/chrome/browser/profiles/profile_downloader.cc b/chrome/browser/profiles/profile_downloader.cc
index 8c92f8c..d4726f2 100644
--- a/chrome/browser/profiles/profile_downloader.cc
+++ b/chrome/browser/profiles/profile_downloader.cc
@@ -28,6 +28,7 @@
#include "content/public/browser/notification_types.h"
#include "content/public/common/url_fetcher.h"
#include "googleurl/src/gurl.h"
+#include "net/base/load_flags.h"
#include "skia/ext/image_operations.h"
using content::BrowserThread;
@@ -244,6 +245,7 @@ void ProfileDownloader::StartFetchingImage() {
GURL(kUserEntryURL), content::URLFetcher::GET, this));
user_entry_fetcher_->SetRequestContext(
delegate_->GetBrowserProfile()->GetRequestContext());
+ user_entry_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
if (!auth_token_.empty()) {
user_entry_fetcher_->SetExtraRequestHeaders(
base::StringPrintf(kAuthorizationHeader, auth_token_.c_str()));
@@ -305,6 +307,7 @@ void ProfileDownloader::OnURLFetchComplete(const content::URLFetcher* source) {
GURL(image_url), content::URLFetcher::GET, this));
profile_image_fetcher_->SetRequestContext(
delegate_->GetBrowserProfile()->GetRequestContext());
+ profile_image_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
if (!auth_token_.empty()) {
profile_image_fetcher_->SetExtraRequestHeaders(
base::StringPrintf(kAuthorizationHeader, auth_token_.c_str()));
diff --git a/chrome/browser/search_engines/template_url_fetcher.cc b/chrome/browser/search_engines/template_url_fetcher.cc
index ac3189e..df7ea32 100644
--- a/chrome/browser/search_engines/template_url_fetcher.cc
+++ b/chrome/browser/search_engines/template_url_fetcher.cc
@@ -20,6 +20,7 @@
#include "content/public/browser/notification_source.h"
#include "content/public/common/url_fetcher.h"
#include "content/public/common/url_fetcher_delegate.h"
+#include "net/base/load_flags.h"
#include "net/url_request/url_request_status.h"
// RequestDelegate ------------------------------------------------------------
@@ -100,6 +101,7 @@ TemplateURLFetcher::RequestDelegate::RequestDelegate(
}
url_fetcher_->SetRequestContext(fetcher->profile()->GetRequestContext());
+ url_fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
url_fetcher_->Start();
}
diff --git a/chrome/browser/spellchecker/spellcheck_host_impl.cc b/chrome/browser/spellchecker/spellcheck_host_impl.cc
index 41d93b0..05a2612 100644
--- a/chrome/browser/spellchecker/spellcheck_host_impl.cc
+++ b/chrome/browser/spellchecker/spellcheck_host_impl.cc
@@ -30,6 +30,7 @@
#include "content/public/browser/render_process_host.h"
#include "content/public/common/url_fetcher.h"
#include "googleurl/src/gurl.h"
+#include "net/base/load_flags.h"
#include "net/url_request/url_request_context_getter.h"
#include "third_party/hunspell/google/bdict.h"
#include "ui/base/l10n/l10n_util.h"
@@ -284,6 +285,7 @@ void SpellCheckHostImpl::DownloadDictionary() {
fetcher_.reset(content::URLFetcher::Create(url, content::URLFetcher::GET,
weak_ptr_factory_.GetWeakPtr()));
fetcher_->SetRequestContext(request_context_getter_);
+ fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES);
tried_to_download_ = true;
fetcher_->Start();
request_context_getter_ = NULL;