diff options
author | gab <gab@chromium.org> | 2014-12-02 12:37:17 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-12-02 20:37:39 +0000 |
commit | 086aea5fba7cf5034d0b3d7249170e4d45765b68 (patch) | |
tree | c6fb4c78462b2623d631fa9e2a5a97bf8a7402f3 /chrome | |
parent | 28627f422a9703ce2a355905720586e6aa861f7c (diff) | |
download | chromium_src-086aea5fba7cf5034d0b3d7249170e4d45765b68.zip chromium_src-086aea5fba7cf5034d0b3d7249170e4d45765b68.tar.gz chromium_src-086aea5fba7cf5034d0b3d7249170e4d45765b68.tar.bz2 |
Protect the kGoogleServicesUsername pref.
Also add missing items in the TrackedPreference histograms enum.
(and clean up histogram labels to exclude namespaces)
BUG=438105
TEST=
A) First launch of Chrome with this change should result in a Settings.TrackedPreferenceTrustedInitialized for pref 21.
B) Tampering with google.services.username in Secure Preferences while Chrome isn't running results in the user being signed out on the next launch.
Review URL: https://codereview.chromium.org/775483004
Cr-Commit-Position: refs/heads/master@{#306444}
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/prefs/chrome_pref_service_factory.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/prefs/chrome_pref_service_factory.cc b/chrome/browser/prefs/chrome_pref_service_factory.cc index 865864f..38251e6 100644 --- a/chrome/browser/prefs/chrome_pref_service_factory.cc +++ b/chrome/browser/prefs/chrome_pref_service_factory.cc @@ -198,6 +198,13 @@ const PrefHashFilter::TrackedPreferenceMetadata kTrackedPrefs[] = { PrefHashFilter::TRACKING_STRATEGY_ATOMIC }, #endif + { + 21, prefs::kGoogleServicesUsername, + PrefHashFilter::ENFORCE_ON_LOAD, + PrefHashFilter::TRACKING_STRATEGY_ATOMIC + }, + // See note at top, new items added here also need to be added to + // histograms.xml's TrackedPreference enum. }; // One more than the last tracked preferences ID above. |