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

Unified Diff: extensions/browser/content_verifier.h

Issue 2801583003: developerPrivate.repair: Skip not-corrupted and policy extensions (Closed)
Patch Set: adress comments Created 3 years, 8 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: extensions/browser/content_verifier.h
diff --git a/extensions/browser/content_verifier.h b/extensions/browser/content_verifier.h
index ffb6d065ec6a5fa4fe9a0b12dbcb2dfe63e55b21..6d31f692b8429ffaf402ec5da79176b2068f2929 100644
--- a/extensions/browser/content_verifier.h
+++ b/extensions/browser/content_verifier.h
@@ -30,6 +30,7 @@ namespace extensions {
class Extension;
class ContentHashFetcher;
class ContentVerifierIOData;
+class ManagementPolicy;
// Used for managing overall content verification - both fetching content
// hashes as needed, and supplying job objects to verify file contents as they
@@ -42,6 +43,12 @@ class ContentVerifier : public base::RefCountedThreadSafe<ContentVerifier>,
virtual void OnFetchComplete(const std::string& extension_id,
bool success) = 0;
};
+ // Returns true if content verifier should repair the extension (|id|) if it
+ // became courrpted.
+ // Note that this method doesn't check whether |id| is corrupted or not.
+ static bool ShouldRepairIfCorrupted(const ManagementPolicy* management_policy,
+ const Extension* id);
+
static void SetObserverForTests(TestObserver* observer);
ContentVerifier(content::BrowserContext* context,

Powered by Google App Engine
This is Rietveld 408576698