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

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

Issue 8468020: Propagate the SafeBrowsing download protection verdict to the DownloadItem. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Add danger state to the download extension API. I couldn't find any static docs for that API. Created 9 years, 1 month 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/safe_browsing/download_protection_service.cc
diff --git a/chrome/browser/safe_browsing/download_protection_service.cc b/chrome/browser/safe_browsing/download_protection_service.cc
index 897d401e144041be6c7026cf2fdc1c6e860988b6..95dfeb55d76d9749bfc8c72dc419f6ec36c1e521 100644
--- a/chrome/browser/safe_browsing/download_protection_service.cc
+++ b/chrome/browser/safe_browsing/download_protection_service.cc
@@ -573,6 +573,8 @@ class DownloadProtectionService::CheckClientDownloadRequest
}
void RecordImprovedProtectionStats(DownloadCheckResultReason reason) {
+ VLOG(2) << "SafeBrowsing download verdict for: "
+ << info_.DebugString() << " verdict:" << reason;
UMA_HISTOGRAM_ENUMERATION("SBClientDownload.CheckDownloadStats",
reason,
REASON_MAX);
@@ -638,6 +640,11 @@ void DownloadProtectionService::CheckDownloadUrl(
base::Bind(&DownloadUrlSBClient::StartCheck, client));
}
+bool DownloadProtectionService::IsSupportedFileType(
+ const FilePath& filename) const {
+ return IsBinaryFile(filename);
+}
+
void DownloadProtectionService::CancelPendingRequests() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
for (std::set<scoped_refptr<CheckClientDownloadRequest> >::iterator it =

Powered by Google App Engine
This is Rietveld 408576698