| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_CLIENT_SIDE_DETECTION_HOST_H_ | 5 #ifndef CHROME_BROWSER_SAFE_BROWSING_CLIENT_SIDE_DETECTION_HOST_H_ |
| 6 #define CHROME_BROWSER_SAFE_BROWSING_CLIENT_SIDE_DETECTION_HOST_H_ | 6 #define CHROME_BROWSER_SAFE_BROWSING_CLIENT_SIDE_DETECTION_HOST_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 // variable. This information will be passed on to the feature extractor. | 114 // variable. This information will be passed on to the feature extractor. |
| 115 scoped_ptr<BrowseInfo> browse_info_; | 115 scoped_ptr<BrowseInfo> browse_info_; |
| 116 // Redirect chain that leads to the first page of the current host. We keep | 116 // Redirect chain that leads to the first page of the current host. We keep |
| 117 // track of this for browse_info_. | 117 // track of this for browse_info_. |
| 118 std::vector<GURL> cur_host_redirects_; | 118 std::vector<GURL> cur_host_redirects_; |
| 119 // Current host, used to help determine cur_host_redirects_. | 119 // Current host, used to help determine cur_host_redirects_. |
| 120 std::string cur_host_; | 120 std::string cur_host_; |
| 121 // Handles registering notifications with the NotificationService. | 121 // Handles registering notifications with the NotificationService. |
| 122 content::NotificationRegistrar registrar_; | 122 content::NotificationRegistrar registrar_; |
| 123 | 123 |
| 124 base::ScopedCallbackFactory<ClientSideDetectionHost> cb_factory_; | 124 base::WeakPtrFactory<ClientSideDetectionHost> weak_factory_; |
| 125 | 125 |
| 126 // Unique page ID of the most recent unsafe site that was loaded in this tab | 126 // Unique page ID of the most recent unsafe site that was loaded in this tab |
| 127 // as well as the UnsafeResource. | 127 // as well as the UnsafeResource. |
| 128 int unsafe_unique_page_id_; | 128 int unsafe_unique_page_id_; |
| 129 scoped_ptr<SafeBrowsingService::UnsafeResource> unsafe_resource_; | 129 scoped_ptr<SafeBrowsingService::UnsafeResource> unsafe_resource_; |
| 130 | 130 |
| 131 DISALLOW_COPY_AND_ASSIGN(ClientSideDetectionHost); | 131 DISALLOW_COPY_AND_ASSIGN(ClientSideDetectionHost); |
| 132 }; | 132 }; |
| 133 | 133 |
| 134 } // namespace safe_browsing | 134 } // namespace safe_browsing |
| 135 | 135 |
| 136 #endif // CHROME_BROWSER_SAFE_BROWSING_CLIENT_SIDE_DETECTION_HOST_H_ | 136 #endif // CHROME_BROWSER_SAFE_BROWSING_CLIENT_SIDE_DETECTION_HOST_H_ |
| OLD | NEW |