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

Unified Diff: components/proximity_auth/webui/reachable_phone_flow.cc

Issue 2888053003: Network traffic annotation added to OAuth2ApiCallFlow and its subclasses. (Closed)
Patch Set: Annotations updated. Created 3 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 side-by-side diff with in-line comments
Download patch
Index: components/proximity_auth/webui/reachable_phone_flow.cc
diff --git a/components/proximity_auth/webui/reachable_phone_flow.cc b/components/proximity_auth/webui/reachable_phone_flow.cc
index c518216409de8cf803eb8c49493e2791a6816260..0b6a7849b29cd83415c4d75c06b2bb6da889bb24 100644
--- a/components/proximity_auth/webui/reachable_phone_flow.cc
+++ b/components/proximity_auth/webui/reachable_phone_flow.cc
@@ -13,6 +13,7 @@
#include "components/cryptauth/cryptauth_client.h"
#include "components/cryptauth/proto/cryptauth_api.pb.h"
#include "components/proximity_auth/logging/logging.h"
+#include "net/traffic_annotation/network_traffic_annotation.h"
namespace proximity_auth {
@@ -43,11 +44,33 @@ void ReachablePhoneFlow::Run(const ReachablePhonesCallback& callback) {
// Ping the user's devices to update themselves with CryptAuth.
cryptauth::SendDeviceSyncTickleRequest tickle_request;
tickle_request.set_tickle_type(cryptauth::UPDATE_ENROLLMENT);
+ net::PartialNetworkTrafficAnnotationTag partial_traffic_annotation =
+ net::DefinePartialNetworkTrafficAnnotation("...", "oauth2_api_call_flow",
sacomoto 2017/06/19 18:25:39 cryptauth_device_sync_tickle
Ramin Halavati 2017/06/20 05:35:34 Done.
+ R"(
+ semantics {
+ sender: "..."
sacomoto 2017/06/19 18:25:39 EasyUnlock Debug UI
Ramin Halavati 2017/06/20 05:35:34 Done.
+ description: "..."
sacomoto 2017/06/19 18:25:39 Triggers a sync on all other device (for the same
Ramin Halavati 2017/06/20 05:35:34 Done.
+ trigger: "..."
sacomoto 2017/06/19 18:25:39 User manually open the EasyUnlock debug UI.
Ramin Halavati 2017/06/20 05:35:34 Done.
+ data: "..."
sacomoto 2017/06/19 18:25:39 The device public key.
Ramin Halavati 2017/06/20 05:35:34 Done.
+ destination: GOOGLE_OWNED_SERVICE
+ }
+ policy {
+ setting: "..."
sacomoto 2017/06/19 18:25:39 This feature cannot be disabled in settings, but t
Ramin Halavati 2017/06/20 05:35:34 Done.
+ chrome_policy {
+ [POLICY_NAME] {
sacomoto 2017/06/19 18:25:38 SigninAllowed
Ramin Halavati 2017/06/20 05:35:34 Done.
+ policy_options {mode: MANDATORY/RECOMMENDED/UNSET}
+ [POLICY_NAME]: ... //(value to disable it)
sacomoto 2017/06/19 18:25:39 SigninAllowed: false
Ramin Halavati 2017/06/20 05:35:34 Done.
+ }
+ }
+ policy_exception_justification: "..."
+ })");
client_->SendDeviceSyncTickle(
- tickle_request, base::Bind(&ReachablePhoneFlow::OnSyncTickleSuccess,
- weak_ptr_factory_.GetWeakPtr()),
+ tickle_request,
+ base::Bind(&ReachablePhoneFlow::OnSyncTickleSuccess,
+ weak_ptr_factory_.GetWeakPtr()),
base::Bind(&ReachablePhoneFlow::OnApiCallError,
- weak_ptr_factory_.GetWeakPtr()));
+ weak_ptr_factory_.GetWeakPtr()),
+ partial_traffic_annotation);
}
void ReachablePhoneFlow::OnSyncTickleSuccess(

Powered by Google App Engine
This is Rietveld 408576698