OLD | NEW |
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 #ifndef CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ | 5 #ifndef CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ |
6 #define CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ | 6 #define CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 // A class that encapsulates the detailed malware reports sent when | 9 // A class that encapsulates the detailed malware reports sent when |
10 // users opt-in to do so from the malware warning page. | 10 // users opt-in to do so from the malware warning page. |
11 | 11 |
12 // An instance of this class is generated when a malware warning page | 12 // An instance of this class is generated when a malware warning page |
13 // is shown (SafeBrowsingBlockingPage). It is passed on to the | 13 // is shown (SafeBrowsingBlockingPage). It is passed on to the |
14 // SafeBrowsing service when the warning goes away. | 14 // SafeBrowsing service when the warning goes away. |
15 | 15 |
16 #include <string> | 16 #include <string> |
17 #include <vector> | 17 #include <vector> |
18 | 18 |
19 #include "base/hash_tables.h" | 19 #include "base/hash_tables.h" |
20 #include "base/linked_ptr.h" | 20 #include "base/linked_ptr.h" |
21 #include "base/scoped_ptr.h" | 21 #include "base/scoped_ptr.h" |
22 #include "chrome/browser/safe_browsing/report.pb.h" | 22 #include "chrome/browser/safe_browsing/report.pb.h" |
23 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 23 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
24 #include "chrome/browser/tab_contents/tab_contents_observer.h" | 24 #include "content/browser/tab_contents/tab_contents_observer.h" |
25 | 25 |
26 class TabContents; | 26 class TabContents; |
27 struct ViewHostMsg_MalwareDOMDetails_Params; | 27 struct ViewHostMsg_MalwareDOMDetails_Params; |
28 | 28 |
29 class MalwareDetailsFactory; | 29 class MalwareDetailsFactory; |
30 | 30 |
31 class MalwareDetails : public base::RefCountedThreadSafe<MalwareDetails>, | 31 class MalwareDetails : public base::RefCountedThreadSafe<MalwareDetails>, |
32 public TabContentsObserver { | 32 public TabContentsObserver { |
33 public: | 33 public: |
34 // Constructs a new MalwareDetails instance, using the factory. | 34 // Constructs a new MalwareDetails instance, using the factory. |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 class MalwareDetailsFactory { | 116 class MalwareDetailsFactory { |
117 public: | 117 public: |
118 virtual ~MalwareDetailsFactory() { } | 118 virtual ~MalwareDetailsFactory() { } |
119 | 119 |
120 virtual MalwareDetails* CreateMalwareDetails( | 120 virtual MalwareDetails* CreateMalwareDetails( |
121 TabContents* tab_contents, | 121 TabContents* tab_contents, |
122 const SafeBrowsingService::UnsafeResource& unsafe_resource) = 0; | 122 const SafeBrowsingService::UnsafeResource& unsafe_resource) = 0; |
123 }; | 123 }; |
124 | 124 |
125 #endif // CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ | 125 #endif // CHROME_BROWSER_SAFE_BROWSING_MALWARE_DETAILS_H_ |
OLD | NEW |