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

Unified Diff: components/doodle/doodle_fetcher_impl.cc

Issue 2838713003: [Doodle] Allow cookie authentication (Closed)
Patch Set: review2 Created 3 years, 8 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/doodle/doodle_fetcher_impl.cc
diff --git a/components/doodle/doodle_fetcher_impl.cc b/components/doodle/doodle_fetcher_impl.cc
index b1c8188b88c70b13569db6fa497a296016806a29..0109468a96694f345baa735c09d1957458bb2642 100644
--- a/components/doodle/doodle_fetcher_impl.cc
+++ b/components/doodle/doodle_fetcher_impl.cc
@@ -87,11 +87,14 @@ void DoodleFetcherImpl::FetchDoodle(FinishedCallback callback) {
"currently running Doodle."
trigger:
"Displaying the new tab page on Android."
- data: "None."
+ data:
+ "The user's Google cookies. Used for example to show birthday "
+ "doodles at appropriate times."
destination: GOOGLE_OWNED_SERVICE
}
policy {
- cookies_allowed: false
+ cookies_allowed: true
+ cookies_store: "user"
setting:
"Choosing a non-Google search engine in Chromium settings under "
"'Search Engine' will disable this feature."
@@ -103,9 +106,8 @@ void DoodleFetcherImpl::FetchDoodle(FinishedCallback callback) {
BuildDoodleURL(GetGoogleBaseUrl(), gray_background_, override_url_),
URLFetcher::GET, this, traffic_annotation);
fetcher_->SetRequestContext(download_context_.get());
- fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SEND_COOKIES |
- net::LOAD_DO_NOT_SAVE_COOKIES |
- net::LOAD_DO_NOT_SEND_AUTH_DATA);
+ // TODO(treib): Use OAuth2 authentication instead of cookies. crbug.com/711314
+ fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SEND_AUTH_DATA);
fetcher_->SetAutomaticallyRetryOnNetworkChanges(1);
data_use_measurement::DataUseUserData::AttachToFetcher(
fetcher_.get(), data_use_measurement::DataUseUserData::DOODLE);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698