Index: components/cryptauth/cryptauth_device_manager.cc |
diff --git a/components/cryptauth/cryptauth_device_manager.cc b/components/cryptauth/cryptauth_device_manager.cc |
index 0fa6a825e5ffe02728812f02d36dd642d6b22ef3..aab93a18e11db59b8db6318875175922e917d260 100644 |
--- a/components/cryptauth/cryptauth_device_manager.cc |
+++ b/components/cryptauth/cryptauth_device_manager.cc |
@@ -18,6 +18,7 @@ |
#include "components/prefs/pref_service.h" |
#include "components/prefs/scoped_user_pref_update.h" |
#include "components/proximity_auth/logging/logging.h" |
+#include "net/traffic_annotation/network_traffic_annotation.h" |
namespace cryptauth { |
@@ -541,11 +542,33 @@ void CryptAuthDeviceManager::OnSyncRequested( |
GetMyDevicesRequest request; |
request.set_invocation_reason(invocation_reason); |
request.set_allow_stale_read(is_sync_speculative); |
+ net::PartialNetworkTrafficAnnotationTag partial_traffic_annotation = |
+ net::DefinePartialNetworkTrafficAnnotation("cryptauth_get_my_devices", |
+ "oauth2_api_call_flow", R"( |
+ semantics { |
+ sender: "CryptAuth Device Manager" |
+ description: |
+ "Gets a list of the devices registered (for the same user) on " |
msramek
2017/06/28 08:40:55
Ditto here.
Ramin Halavati
2017/06/30 11:51:36
Acknowledged.
|
+ "CryptAuth." |
+ trigger: "Once every day, or by API request." |
+ data: "OAuth 2.0 token." |
+ destination: GOOGLE_OWNED_SERVICE |
+ } |
+ policy { |
+ setting: "This feature cannot be disabled in settings." |
msramek
2017/06/28 08:40:55
nit: Consistency. The previous annotation tended t
Ramin Halavati
2017/06/28 09:21:29
Done.
|
+ chrome_policy { |
+ SigninAllowed { |
+ SigninAllowed: false |
+ } |
+ } |
+ })"); |
cryptauth_client_->GetMyDevices( |
- request, base::Bind(&CryptAuthDeviceManager::OnGetMyDevicesSuccess, |
- weak_ptr_factory_.GetWeakPtr()), |
+ request, |
+ base::Bind(&CryptAuthDeviceManager::OnGetMyDevicesSuccess, |
+ weak_ptr_factory_.GetWeakPtr()), |
base::Bind(&CryptAuthDeviceManager::OnGetMyDevicesFailure, |
- weak_ptr_factory_.GetWeakPtr())); |
+ weak_ptr_factory_.GetWeakPtr()), |
+ partial_traffic_annotation); |
} |
} // namespace cryptauth |