OLD | NEW |
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 #include "chrome/browser/safe_browsing/ui_manager.h" | 5 #include "chrome/browser/safe_browsing/ui_manager.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/callback.h" | 9 #include "base/callback.h" |
10 #include "base/debug/leak_tracker.h" | 10 #include "base/debug/leak_tracker.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/metrics/histogram_macros.h" | 12 #include "base/metrics/histogram_macros.h" |
13 #include "base/prefs/pref_service.h" | |
14 #include "base/stl_util.h" | 13 #include "base/stl_util.h" |
15 #include "base/strings/string_util.h" | 14 #include "base/strings/string_util.h" |
16 #include "base/threading/thread.h" | 15 #include "base/threading/thread.h" |
17 #include "base/threading/thread_restrictions.h" | 16 #include "base/threading/thread_restrictions.h" |
18 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" | 17 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" |
19 #include "chrome/browser/profiles/profile.h" | 18 #include "chrome/browser/profiles/profile.h" |
20 #include "chrome/browser/safe_browsing/metadata.pb.h" | 19 #include "chrome/browser/safe_browsing/metadata.pb.h" |
21 #include "chrome/browser/safe_browsing/ping_manager.h" | 20 #include "chrome/browser/safe_browsing/ping_manager.h" |
22 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" | 21 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" |
23 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 22 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
24 #include "chrome/browser/safe_browsing/threat_details.h" | 23 #include "chrome/browser/safe_browsing/threat_details.h" |
25 #include "chrome/browser/tab_contents/tab_util.h" | 24 #include "chrome/browser/tab_contents/tab_util.h" |
26 #include "chrome/common/pref_names.h" | 25 #include "chrome/common/pref_names.h" |
| 26 #include "components/prefs/pref_service.h" |
27 #include "content/public/browser/browser_thread.h" | 27 #include "content/public/browser/browser_thread.h" |
28 #include "content/public/browser/navigation_entry.h" | 28 #include "content/public/browser/navigation_entry.h" |
29 #include "content/public/browser/notification_service.h" | 29 #include "content/public/browser/notification_service.h" |
30 #include "content/public/browser/web_contents.h" | 30 #include "content/public/browser/web_contents.h" |
31 #include "ipc/ipc_message.h" | 31 #include "ipc/ipc_message.h" |
32 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" | 32 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
33 #include "net/ssl/ssl_info.h" | 33 #include "net/ssl/ssl_info.h" |
34 #include "net/url_request/url_request_context.h" | 34 #include "net/url_request/url_request_context.h" |
35 #include "net/url_request/url_request_context_getter.h" | 35 #include "net/url_request/url_request_context_getter.h" |
36 | 36 |
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
362 } | 362 } |
363 | 363 |
364 WhitelistUrlSet* site_list = | 364 WhitelistUrlSet* site_list = |
365 static_cast<WhitelistUrlSet*>(web_contents->GetUserData(kWhitelistKey)); | 365 static_cast<WhitelistUrlSet*>(web_contents->GetUserData(kWhitelistKey)); |
366 if (!site_list) | 366 if (!site_list) |
367 return false; | 367 return false; |
368 return site_list->Contains(maybe_whitelisted_url); | 368 return site_list->Contains(maybe_whitelisted_url); |
369 } | 369 } |
370 | 370 |
371 } // namespace safe_browsing | 371 } // namespace safe_browsing |
OLD | NEW |