Chromium Code Reviews| Index: chrome/browser/safe_browsing/client_side_detection_host.h |
| diff --git a/chrome/browser/safe_browsing/client_side_detection_host.h b/chrome/browser/safe_browsing/client_side_detection_host.h |
| index c5cf95acbbd3a0a6a589fce8372ee09086564f9f..faa42579835bf66dd1389508d388356587af520f 100644 |
| --- a/chrome/browser/safe_browsing/client_side_detection_host.h |
| +++ b/chrome/browser/safe_browsing/client_side_detection_host.h |
| @@ -79,6 +79,11 @@ class ClientSideDetectionHost : public content::WebContentsObserver, |
| class ShouldClassifyUrlRequest; |
| friend class ShouldClassifyUrlRequest; |
| + // These methods are called when pre-classification checks are done for |
| + // the phishing and malware clasifiers. |
| + void OnPhishingPreClassificationDone(bool should_classify); |
| + void OnMalwarePreClassificationDone(bool should_classify); |
| + |
| // Verdict is an encoded ClientPhishingRequest protocol message. |
| void OnPhishingDetectionDone(const std::string& verdict); |
| @@ -116,6 +121,10 @@ class ClientSideDetectionHost : public content::WebContentsObserver, |
| const content::NotificationSource& source, |
| const content::NotificationDetails& details) OVERRIDE; |
| + // Inherited from WebContentsObserver. This is called once the onload handler |
| + // is called. |
| + virtual void DocumentOnLoadCompletedInMainFrame(int32 page_id); |
|
mattm
2014/02/21 00:35:29
OVERRIDE
noé
2014/02/21 19:04:16
Done.
|
| + |
| // Returns true if the user has seen a regular SafeBrowsing |
| // interstitial for the current page. This is only true if the user has |
| // actually clicked through the warning. This method is called on the UI |
| @@ -126,10 +135,6 @@ class ClientSideDetectionHost : public content::WebContentsObserver, |
| // class. |
| void set_client_side_detection_service(ClientSideDetectionService* service); |
| - // Get/Set malware_killswitch_on_ value. These methods called on UI thread. |
| - bool MalwareKillSwitchIsOn(); |
| - void SetMalwareKillSwitch(bool killswitch_on); |
| - |
| // This pointer may be NULL if client-side phishing detection is disabled. |
| ClientSideDetectionService* csd_service_; |
| // These pointers may be NULL if SafeBrowsing is disabled. |
| @@ -158,6 +163,9 @@ class ClientSideDetectionHost : public content::WebContentsObserver, |
| // Max number of urls we report for each malware IP. |
| static const int kMaxUrlsPerIP; |
| + bool should_extract_malware_features_; |
| + bool should_classify_for_malware_; |
| + |
| base::WeakPtrFactory<ClientSideDetectionHost> weak_factory_; |
| // Unique page ID of the most recent unsafe site that was loaded in this tab |
| @@ -165,14 +173,6 @@ class ClientSideDetectionHost : public content::WebContentsObserver, |
| int unsafe_unique_page_id_; |
| scoped_ptr<SafeBrowsingUIManager::UnsafeResource> unsafe_resource_; |
| - // Whether the malware IP matching feature killswitch is on. |
| - // This should be accessed from UI thread. |
| - bool malware_killswitch_on_; |
| - |
| - // Whether the malware bad ip matching and report feature is enabled. |
| - // This should be accessed from UI thread. |
| - bool malware_report_enabled_; |
| - |
| DISALLOW_COPY_AND_ASSIGN(ClientSideDetectionHost); |
| }; |