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_PROTOCOL_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_H_ |
6 #define CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_H_ | 6 #define CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 // A class that implements Chrome's interface with the SafeBrowsing protocol. | 9 // A class that implements Chrome's interface with the SafeBrowsing protocol. |
10 // The SafeBrowsingProtocolManager handles formatting and making requests of, | 10 // The SafeBrowsingProtocolManager handles formatting and making requests of, |
11 // and handling responses from, Google's SafeBrowsing servers. This class uses | 11 // and handling responses from, Google's SafeBrowsing servers. This class uses |
12 // The SafeBrowsingProtocolParser class to do the actual parsing. | 12 // The SafeBrowsingProtocolParser class to do the actual parsing. |
13 | 13 |
14 #include <deque> | 14 #include <deque> |
15 #include <set> | 15 #include <set> |
16 #include <string> | 16 #include <string> |
17 #include <vector> | 17 #include <vector> |
18 | 18 |
19 #include "base/gtest_prod_util.h" | 19 #include "base/gtest_prod_util.h" |
20 #include "base/hash_tables.h" | 20 #include "base/hash_tables.h" |
21 #include "base/memory/scoped_ptr.h" | 21 #include "base/memory/scoped_ptr.h" |
22 #include "base/time.h" | 22 #include "base/time.h" |
23 #include "base/timer.h" | 23 #include "base/timer.h" |
24 #include "chrome/browser/safe_browsing/chunk_range.h" | 24 #include "chrome/browser/safe_browsing/chunk_range.h" |
25 #include "chrome/browser/safe_browsing/protocol_parser.h" | 25 #include "chrome/browser/safe_browsing/protocol_parser.h" |
26 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 26 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
27 #include "chrome/browser/safe_browsing/safe_browsing_util.h" | 27 #include "chrome/browser/safe_browsing/safe_browsing_util.h" |
28 #include "chrome/common/net/url_fetcher.h" | 28 #include "content/common/url_fetcher.h" |
29 | 29 |
30 namespace net { | 30 namespace net { |
31 class URLRequestStatus; | 31 class URLRequestStatus; |
32 } // namespace net | 32 } // namespace net |
33 | 33 |
34 #if defined(COMPILER_GCC) | 34 #if defined(COMPILER_GCC) |
35 // Allows us to use URLFetchers in a hash_map with gcc (MSVC is okay without | 35 // Allows us to use URLFetchers in a hash_map with gcc (MSVC is okay without |
36 // specifying this). | 36 // specifying this). |
37 namespace __gnu_cxx { | 37 namespace __gnu_cxx { |
38 template<> | 38 template<> |
(...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
407 std::string https_url_prefix_; | 407 std::string https_url_prefix_; |
408 | 408 |
409 // When true, protocol manager will not start an update unless | 409 // When true, protocol manager will not start an update unless |
410 // ForceScheduleNextUpdate() is called. This is set for testing purpose. | 410 // ForceScheduleNextUpdate() is called. This is set for testing purpose. |
411 bool disable_auto_update_; | 411 bool disable_auto_update_; |
412 | 412 |
413 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingProtocolManager); | 413 DISALLOW_COPY_AND_ASSIGN(SafeBrowsingProtocolManager); |
414 }; | 414 }; |
415 | 415 |
416 #endif // CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_H_ | 416 #endif // CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_H_ |
OLD | NEW |