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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_util.cc

Issue 7863006: Add a whitelist for the new binary download protection. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address Matt's comment. Created 9 years, 3 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
« no previous file with comments | « chrome/browser/safe_browsing/safe_browsing_util.h ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/safe_browsing/safe_browsing_util.cc
diff --git a/chrome/browser/safe_browsing/safe_browsing_util.cc b/chrome/browser/safe_browsing/safe_browsing_util.cc
index bb13a0077f3c2d6d1fbb31dc6f46926935831d47..8503913dde1d8baf5418b24f800c1521c27b47b5 100644
--- a/chrome/browser/safe_browsing/safe_browsing_util.cc
+++ b/chrome/browser/safe_browsing/safe_browsing_util.cc
@@ -170,6 +170,7 @@ const char kPhishingList[] = "goog-phish-shavar";
const char kBinUrlList[] = "goog-badbinurl-shavar";
const char kBinHashList[] = "goog-badbin-digestvar";
const char kCsdWhiteList[] = "goog-csdwhite-sha256";
+const char kDownloadWhiteList[] = "goog-downloadwhite-digest256";
int GetListId(const std::string& name) {
int id;
@@ -183,6 +184,8 @@ int GetListId(const std::string& name) {
id = BINHASH;
} else if (name == safe_browsing_util::kCsdWhiteList) {
id = CSDWHITELIST;
+ } else if (name == safe_browsing_util::kDownloadWhiteList) {
+ id = DOWNLOADWHITELIST;
} else {
id = INVALID;
}
@@ -206,6 +209,9 @@ bool GetListName(int list_id, std::string* list) {
case CSDWHITELIST:
*list = safe_browsing_util::kCsdWhiteList;
break;
+ case DOWNLOADWHITELIST:
+ *list = safe_browsing_util::kDownloadWhiteList;
+ break;
default:
return false;
}
« no previous file with comments | « chrome/browser/safe_browsing/safe_browsing_util.h ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698