diff options
author | panayiotis@google.com <panayiotis@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-12 23:59:51 +0000 |
---|---|---|
committer | panayiotis@google.com <panayiotis@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-12 23:59:51 +0000 |
commit | ee4d3e80cfae83eeffe4e3f0c0d35ee5840ad575 (patch) | |
tree | 26783476d530c04f54738c88a7d59f92a738532b /chrome/browser/safe_browsing/protocol_manager.cc | |
parent | a3ed663e7ad9cff70a5893851714bc702f70391d (diff) | |
download | chromium_src-ee4d3e80cfae83eeffe4e3f0c0d35ee5840ad575.zip chromium_src-ee4d3e80cfae83eeffe4e3f0c0d35ee5840ad575.tar.gz chromium_src-ee4d3e80cfae83eeffe4e3f0c0d35ee5840ad575.tar.bz2 |
Report malware redirectors as well.
BUG=none
TEST=unit_tests
Review URL: http://codereview.chromium.org/3028040
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55966 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/safe_browsing/protocol_manager.cc')
-rw-r--r-- | chrome/browser/safe_browsing/protocol_manager.cc | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/chrome/browser/safe_browsing/protocol_manager.cc b/chrome/browser/safe_browsing/protocol_manager.cc index 23ed348..611349b 100644 --- a/chrome/browser/safe_browsing/protocol_manager.cc +++ b/chrome/browser/safe_browsing/protocol_manager.cc @@ -589,8 +589,10 @@ void SafeBrowsingProtocolManager::OnChunkInserted() { void SafeBrowsingProtocolManager::ReportMalware(const GURL& malware_url, const GURL& page_url, - const GURL& referrer_url) { - GURL report_url = MalwareReportUrl(malware_url, page_url, referrer_url); + const GURL& referrer_url, + bool is_subresource) { + GURL report_url = MalwareReportUrl(malware_url, page_url, referrer_url, + is_subresource); URLFetcher* report = new URLFetcher(report_url, URLFetcher::GET, this); report->set_load_flags(net::LOAD_DISABLE_CACHE); report->set_request_context(request_context_getter_); @@ -680,13 +682,14 @@ GURL SafeBrowsingProtocolManager::MacKeyUrl() const { GURL SafeBrowsingProtocolManager::MalwareReportUrl( const GURL& malware_url, const GURL& page_url, - const GURL& referrer_url) const { + const GURL& referrer_url, bool is_subresource) const { std::string url = ComposeUrl(info_url_prefix_, "report", client_name_, version_, additional_query_); - return GURL(StringPrintf("%s&evts=malblhit&evtd=%s&evtr=%s&evhr=%s", + return GURL(StringPrintf("%s&evts=malblhit&evtd=%s&evtr=%s&evhr=%s&evtb=%d", url.c_str(), EscapeQueryParamValue(malware_url.spec(), true).c_str(), EscapeQueryParamValue(page_url.spec(), true).c_str(), - EscapeQueryParamValue(referrer_url.spec(), true).c_str())); + EscapeQueryParamValue(referrer_url.spec(), true).c_str(), + is_subresource)); } GURL SafeBrowsingProtocolManager::NextChunkUrl(const std::string& url) const { |