Index: chrome/browser/metrics/variations/variations_seed_store.cc |
diff --git a/chrome/browser/metrics/variations/variations_seed_store.cc b/chrome/browser/metrics/variations/variations_seed_store.cc |
index be775309989c3c1b3aef14a3ec04b1df0458414e..c6a45838a5ed83399bf887bb908ff81cefb37c21 100644 |
--- a/chrome/browser/metrics/variations/variations_seed_store.cc |
+++ b/chrome/browser/metrics/variations/variations_seed_store.cc |
@@ -10,7 +10,11 @@ |
#include "base/prefs/pref_service.h" |
#include "base/sha1.h" |
#include "base/strings/string_number_conversions.h" |
+#include "chrome/browser/browser_process.h" |
grt (UTC plus 2)
2014/10/10 17:45:42
remove these
Georges Khalil
2014/10/10 20:19:31
Done.
|
+#include "chrome/browser/safe_browsing/incident_reporting/add_incident_callback.h" |
+#include "chrome/browser/safe_browsing/safe_browsing_service.h" |
#include "chrome/common/pref_names.h" |
+#include "chrome/common/safe_browsing/csd.pb.h" |
#include "components/variations/proto/variations_seed.pb.h" |
#include "crypto/signature_verifier.h" |
@@ -120,6 +124,7 @@ VariationsSeedStore::~VariationsSeedStore() { |
} |
bool VariationsSeedStore::LoadSeed(variations::VariationsSeed* seed) { |
+ bad_signature_ = std::string(); |
grt (UTC plus 2)
2014/10/10 17:45:42
bad_signature_.clear();
Georges Khalil
2014/10/10 20:19:31
Done.
|
const std::string base64_seed_data = |
local_state_->GetString(prefs::kVariationsSeed); |
if (base64_seed_data.empty()) { |
@@ -150,6 +155,9 @@ bool VariationsSeedStore::LoadSeed(variations::VariationsSeed* seed) { |
<< "with result: " << result << ". Clearing the pref."; |
ClearPrefs(); |
RecordVariationSeedEmptyHistogram(VARIATIONS_SEED_INVALID_SIGNATURE); |
+ // Record the bad signature, to be used later for sending an incident |
grt (UTC plus 2)
2014/10/10 17:45:42
same comment about documenting the current consume
Georges Khalil
2014/10/10 20:19:31
Done.
|
+ // report. |
+ bad_signature_ = base64_seed_signature; |
return false; |
} |
} |