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

Unified Diff: chrome/browser/plugins/plugins_resource_service.cc

Issue 2717473002: Network traffic annotation added to web_resource_service. (Closed)
Patch Set: Annotation updated. Created 3 years, 9 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 | components/web_resource/web_resource_service.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugins/plugins_resource_service.cc
diff --git a/chrome/browser/plugins/plugins_resource_service.cc b/chrome/browser/plugins/plugins_resource_service.cc
index 2910e395cab43859900e34798df7ba39973a1309..6569ed487230c395adda1607b2d970dc8a6c55f9 100644
--- a/chrome/browser/plugins/plugins_resource_service.cc
+++ b/chrome/browser/plugins/plugins_resource_service.cc
@@ -17,6 +17,31 @@
#include "url/gurl.h"
namespace {
+constexpr net::NetworkTrafficAnnotationTag kTrafficAnnotation =
+ net::DefineNetworkTrafficAnnotation("plugins_resource_service", R"(
+ semantics {
+ sender: "Plugins Resource Service"
+ description:
+ "Fetches updates to the list of plugins known to Chromium. For a "
+ "given plugin, this list contains the minimum version not "
+ "containing known security vulnerabilities, and can be used to "
+ "inform the user that their plugins need to be updated."
+ trigger: "Triggered at regular intervals (once per day)."
+ data: "None"
+ destination: GOOGLE_OWNED_SERVICE
+ }
+ policy {
+ cookies_allowed: false
+ setting: "This feature cannot be disabled in settings."
+ policy_exception_justification:
+ "Not implemented. AllowOutdatedPlugins policy silences local "
+ "warnings, but network request to update the list of plugins are "
+ "still sent."
+ })");
+
+} // namespace
+
+namespace {
// Delay on first fetch so we don't interfere with startup.
const int kStartResourceFetchDelayMs = 60 * 1000;
@@ -54,7 +79,8 @@ PluginsResourceService::PluginsResourceService(PrefService* local_state)
kCacheUpdateDelayMs,
g_browser_process->system_request_context(),
switches::kDisableBackgroundNetworking,
- base::Bind(safe_json::SafeJsonParser::Parse)) {}
+ base::Bind(safe_json::SafeJsonParser::Parse),
+ kTrafficAnnotation) {}
void PluginsResourceService::Init() {
const base::DictionaryValue* metadata =
« no previous file with comments | « no previous file | components/web_resource/web_resource_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698