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

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

Issue 1703413002: Move common PVer4 code into a V4ProtocolManagerUtil class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Pass config as pointer, instead of reference Created 4 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 10
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 class ClientSideDetectionService; 51 class ClientSideDetectionService;
52 class DownloadProtectionService; 52 class DownloadProtectionService;
53 struct SafeBrowsingProtocolConfig; 53 struct SafeBrowsingProtocolConfig;
54 class SafeBrowsingDatabaseManager; 54 class SafeBrowsingDatabaseManager;
55 class SafeBrowsingPingManager; 55 class SafeBrowsingPingManager;
56 class SafeBrowsingProtocolManager; 56 class SafeBrowsingProtocolManager;
57 class SafeBrowsingProtocolManagerDelegate; 57 class SafeBrowsingProtocolManagerDelegate;
58 class SafeBrowsingServiceFactory; 58 class SafeBrowsingServiceFactory;
59 class SafeBrowsingUIManager; 59 class SafeBrowsingUIManager;
60 class SafeBrowsingURLRequestContextGetter; 60 class SafeBrowsingURLRequestContextGetter;
61 struct V4GetHashProtocolConfig; 61 struct V4ProtocolConfig;
62 62
63 #if defined(FULL_SAFE_BROWSING) 63 #if defined(FULL_SAFE_BROWSING)
64 class IncidentReportingService; 64 class IncidentReportingService;
65 class OffDomainInclusionDetector; 65 class OffDomainInclusionDetector;
66 class ResourceRequestDetector; 66 class ResourceRequestDetector;
67 #endif 67 #endif
68 68
69 // Construction needs to happen on the main thread. 69 // Construction needs to happen on the main thread.
70 // The SafeBrowsingService owns both the UI and Database managers which do 70 // The SafeBrowsingService owns both the UI and Database managers which do
71 // the heavylifting of safebrowsing service. Both of these managers stay 71 // the heavylifting of safebrowsing service. Both of these managers stay
(...skipping 26 matching lines...) Expand all
98 void ShutDown(); 98 void ShutDown();
99 99
100 // Called on UI thread to decide if the download file's sha256 hash 100 // Called on UI thread to decide if the download file's sha256 hash
101 // should be calculated for safebrowsing. 101 // should be calculated for safebrowsing.
102 bool DownloadBinHashNeeded() const; 102 bool DownloadBinHashNeeded() const;
103 103
104 // Create a protocol config struct. 104 // Create a protocol config struct.
105 virtual SafeBrowsingProtocolConfig GetProtocolConfig() const; 105 virtual SafeBrowsingProtocolConfig GetProtocolConfig() const;
106 106
107 // Create a v4 protocol config struct. 107 // Create a v4 protocol config struct.
108 virtual V4GetHashProtocolConfig GetV4GetHashProtocolConfig() const; 108 virtual V4ProtocolConfig GetV4ProtocolConfig() const;
109 109
110 // Returns the client_name field for both V3 and V4 protocol manager configs. 110 // Returns the client_name field for both V3 and V4 protocol manager configs.
111 std::string GetProtocolConfigClientName() const; 111 std::string GetProtocolConfigClientName() const;
112 112
113 // Get current enabled status. Must be called on IO thread. 113 // Get current enabled status. Must be called on IO thread.
114 bool enabled() const { 114 bool enabled() const {
115 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); 115 DCHECK_CURRENTLY_ON(content::BrowserThread::IO);
116 return enabled_; 116 return enabled_;
117 } 117 }
118 118
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 SafeBrowsingServiceFactory() { } 316 SafeBrowsingServiceFactory() { }
317 virtual ~SafeBrowsingServiceFactory() { } 317 virtual ~SafeBrowsingServiceFactory() { }
318 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0; 318 virtual SafeBrowsingService* CreateSafeBrowsingService() = 0;
319 private: 319 private:
320 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory); 320 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingServiceFactory);
321 }; 321 };
322 322
323 } // namespace safe_browsing 323 } // namespace safe_browsing
324 324
325 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_ 325 #endif // CHROME_BROWSER_SAFE_BROWSING_SAFE_BROWSING_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/local_database_manager.cc ('k') | chrome/browser/safe_browsing/safe_browsing_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698