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

Unified Diff: chrome/browser/browsing_data_helper.h

Issue 10413072: Teaching BrowsingDataRemover how to delete application data. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Feedback. Created 8 years, 6 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: chrome/browser/browsing_data_helper.h
diff --git a/chrome/browser/browsing_data_helper.h b/chrome/browser/browsing_data_helper.h
index ea7a486c61d861f091522cba938848586b88fc01..ae05f1c08e59641f0a1c3a4a5ce3bd6aaf75cae8 100644
--- a/chrome/browser/browsing_data_helper.h
+++ b/chrome/browser/browsing_data_helper.h
@@ -16,10 +16,17 @@ namespace WebKit {
class WebString;
}
+class ExtensionSpecialStoragePolicy;
class GURL;
class BrowsingDataHelper {
public:
+ enum OriginSetMask {
+ UNPROTECTED_WEB = 1 << 0, // drive-by web.
+ PROTECTED_WEB = 1 << 1, // hosted applications.
+ EXTENSION = 1 << 2, // chrome-extension://*
+ };
+
// Returns true iff the provided scheme is (really) web safe, and suitable
// for treatment as "browsing data". This relies on the definition of web safe
// in ChildProcessSecurityPolicy, but excluding schemes like
@@ -33,6 +40,11 @@ class BrowsingDataHelper {
static bool IsExtensionScheme(const WebKit::WebString& scheme);
static bool HasExtensionScheme(const GURL& origin);
+ // Returns true if the provided origin matches the provided mask.
+ static bool DoesOriginMatchMask(const GURL& origin,
+ int origin_set_mask,
+ ExtensionSpecialStoragePolicy* policy);
+
private:
DISALLOW_IMPLICIT_CONSTRUCTORS(BrowsingDataHelper);
};

Powered by Google App Engine
This is Rietveld 408576698