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

Unified Diff: components/cast_certificate/cast_cert_validator.cc

Issue 2205403002: Add production Cast CRL certificate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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/cast_certificate/cast_cert_validator.cc
diff --git a/components/cast_certificate/cast_cert_validator.cc b/components/cast_certificate/cast_cert_validator.cc
index f7c62dd7aff5bc32904119251bc05f78a79ff329..a553fa1f0a8b4c97b945e3f28e8a658c376ce2aa 100644
--- a/components/cast_certificate/cast_cert_validator.cc
+++ b/components/cast_certificate/cast_cert_validator.cc
@@ -55,10 +55,15 @@ class CastTrustStore {
static net::TrustStore& Get() { return GetInstance()->store_; }
+ static void Reinitialize() { GetInstance()->Initialize(); }
eroman 2016/08/03 22:47:58 How about ReinitializeForTest() ? Or make a comme
ryanchung 2016/08/04 18:46:43 Removed this code. It's no longer needed due to th
+
private:
friend struct base::DefaultSingletonTraits<CastTrustStore>;
- CastTrustStore() {
+ CastTrustStore() { Initialize(); }
+
+ void Initialize() {
+ store_.Clear();
AddAnchor(kCastRootCaDer);
AddAnchor(kEurekaRootCaDer);
}
@@ -341,4 +346,8 @@ bool SetTrustAnchorForTest(const std::string& cert) {
return true;
}
+void ResetTrustAnchorForTest() {
+ CastTrustStore::Reinitialize();
+}
+
} // namespace cast_certificate

Powered by Google App Engine
This is Rietveld 408576698