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

Unified Diff: components/signin/core/browser/gaia_cookie_manager_service.cc

Issue 2797173003: Network traffic annotation added to gaia_cookie_manager_service. (Closed)
Patch Set: 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/signin/core/browser/gaia_cookie_manager_service.cc
diff --git a/components/signin/core/browser/gaia_cookie_manager_service.cc b/components/signin/core/browser/gaia_cookie_manager_service.cc
index a3aa65fe8ee2c95e6fe3d8ab3455e108b0d0a89c..7774c4b5fbf2ed68f8ffb98582e1240ad95216dd 100644
--- a/components/signin/core/browser/gaia_cookie_manager_service.cc
+++ b/components/signin/core/browser/gaia_cookie_manager_service.cc
@@ -25,6 +25,7 @@
#include "google_apis/gaia/oauth2_token_service.h"
#include "net/base/load_flags.h"
#include "net/http/http_status_code.h"
+#include "net/traffic_annotation/network_traffic_annotation.h"
#include "net/url_request/url_fetcher.h"
#include "net/url_request/url_fetcher_delegate.h"
@@ -213,8 +214,29 @@ void GaiaCookieManagerService::ExternalCcResultFetcher::
std::unique_ptr<net::URLFetcher>
GaiaCookieManagerService::ExternalCcResultFetcher::CreateFetcher(
const GURL& url) {
- std::unique_ptr<net::URLFetcher> fetcher =
- net::URLFetcher::Create(0, url, net::URLFetcher::GET, this);
+ net::NetworkTrafficAnnotationTag traffic_annotation =
+ net::DefineNetworkTrafficAnnotation("...", R"(
msarda 2017/04/24 12:01:52 gaia_cookie_manager::external_cc_result
Ramin Halavati 2017/04/25 05:22:28 Done.
+ semantics {
+ sender: "..."
msarda 2017/04/24 12:01:52 GaiaCookieManagerService::ExternalCcResultFetcher
Ramin Halavati 2017/04/25 05:22:28 We usually use shorter names, representing the com
msarda 2017/04/25 07:50:49 SGTM.
Ramin Halavati 2017/04/25 07:56:26 Acknowledged.
+ description: "..."
msarda 2017/04/24 12:01:52 GaiaCookieManager::ExternalCcResultFetcher is used
Ramin Halavati 2017/04/25 05:22:28 Done.
+ trigger: "..."
msarda 2017/04/24 12:01:52 GaiaCookieManager::ExternalCcResultFetcher is used
Ramin Halavati 2017/04/25 05:22:28 Done.
+ data: "..."
msarda 2017/04/24 12:01:52 No user-specific data (see https://cs.chromium.org
Ramin Halavati 2017/04/25 05:22:28 Isn't there anything else sent? If yes, please bri
msarda 2017/04/25 07:50:49 I read again the code in https://cs.chromium.org/c
Ramin Halavati 2017/04/25 07:56:26 Thank you for confirmation.
+ destination: WEBSITE/GOOGLE_OWNED_SERVICE/OTHER
msarda 2017/04/24 12:01:52 GOOGLE_OWNED_SERVICE
Ramin Halavati 2017/04/25 05:22:28 Done.
+ }
+ policy {
+ cookies_allowed: false/true
msarda 2017/04/24 12:01:52 false.
Ramin Halavati 2017/04/25 05:22:28 Done.
+ cookies_store: "..."
+ setting: "..."
msarda 2017/04/24 12:01:52 This feature cannot be disabled.
Ramin Halavati 2017/04/25 05:22:28 Done.
+ chrome_policy {
+ [POLICY_NAME] {
msarda 2017/04/24 12:01:52 This feature cannot be enabled or disabled by poli
Ramin Halavati 2017/04/25 05:22:29 Done.
+ policy_options {mode: MANDATORY/RECOMMENDED/UNSET}
+ [POLICY_NAME]: ... //(value to disable it)
+ }
+ }
+ policy_exception_justification: "..."
msarda 2017/04/24 12:01:52 Not implemented. Disabling GaiaCookieManager would
Ramin Halavati 2017/04/25 05:22:29 Done.
+ })");
+ std::unique_ptr<net::URLFetcher> fetcher = net::URLFetcher::Create(
+ 0, url, net::URLFetcher::GET, this, traffic_annotation);
fetcher->SetRequestContext(helper_->request_context());
fetcher->SetLoadFlags(net::LOAD_DO_NOT_SEND_COOKIES |
net::LOAD_DO_NOT_SAVE_COOKIES);
« 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