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

Side by Side Diff: chrome/browser/safe_browsing/safe_browsing_service.h

Issue 6014003: Intergration of the client-side phishing detection. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Dont DCHECK because some unit tests are failing. Created 9 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // The Safe Browsing service is responsible for downloading anti-phishing and 5 // The Safe Browsing service is responsible for downloading anti-phishing and
6 // anti-malware tables and checking urls against them. 6 // anti-malware tables and checking urls against them.
7 7
8 #ifndef CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 8 #ifndef CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
9 #define CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 9 #define CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
10 #pragma once 10 #pragma once
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 146
147 // Called on the IO thread to cancel a pending check if the result is no 147 // Called on the IO thread to cancel a pending check if the result is no
148 // longer needed. 148 // longer needed.
149 void CancelCheck(Client* client); 149 void CancelCheck(Client* client);
150 150
151 // Called on the IO thread to display an interstitial page. 151 // Called on the IO thread to display an interstitial page.
152 // |url| is the url of the resource that matches a safe browsing list. 152 // |url| is the url of the resource that matches a safe browsing list.
153 // If the request contained a chain of redirects, |url| is the last url 153 // If the request contained a chain of redirects, |url| is the last url
154 // in the chain, and |original_url| is the first one (the root of the 154 // in the chain, and |original_url| is the first one (the root of the
155 // chain). Otherwise, |original_url| = |url|. 155 // chain). Otherwise, |original_url| = |url|.
156 void DisplayBlockingPage(const GURL& url, 156 virtual void DisplayBlockingPage(const GURL& url,
157 const GURL& original_url, 157 const GURL& original_url,
158 ResourceType::Type resource_type, 158 ResourceType::Type resource_type,
159 UrlCheckResult result, 159 UrlCheckResult result,
160 Client* client, 160 Client* client,
161 int render_process_host_id, 161 int render_process_host_id,
162 int render_view_id); 162 int render_view_id);
163 163
164 // Called on the IO thread when the SafeBrowsingProtocolManager has received 164 // Called on the IO thread when the SafeBrowsingProtocolManager has received
165 // the full hash results for prefix hits detected in the database. 165 // the full hash results for prefix hits detected in the database.
166 void HandleGetHashResults( 166 void HandleGetHashResults(
167 SafeBrowsingCheck* check, 167 SafeBrowsingCheck* check,
168 const std::vector<SBFullHashResult>& full_hashes, 168 const std::vector<SBFullHashResult>& full_hashes,
169 bool can_cache); 169 bool can_cache);
170 170
171 // Called on the IO thread. 171 // Called on the IO thread.
172 void HandleChunk(const std::string& list, SBChunkList* chunks); 172 void HandleChunk(const std::string& list, SBChunkList* chunks);
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 class SafeBrowsingServiceFactory { 395 class SafeBrowsingServiceFactory {
396 public: 396 public:
397 SafeBrowsingServiceFactory() { } 397 SafeBrowsingServiceFactory() { }
398 virtual ~SafeBrowsingServiceFactory() { } 398 virtual ~SafeBrowsingServiceFactory() { }
399 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0; 399 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0;
400 private: 400 private:
401 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory); 401 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory);
402 }; 402 };
403 403
404 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 404 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698