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 "content/browser/webui/url_data_manager_backend.h" | 5 #include "content/browser/webui/url_data_manager_backend.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 #include "net/url_request/url_request_job.h" | 42 #include "net/url_request/url_request_job.h" |
43 #include "net/url_request/url_request_job_factory.h" | 43 #include "net/url_request/url_request_job_factory.h" |
44 #include "url/url_util.h" | 44 #include "url/url_util.h" |
45 | 45 |
46 using appcache::AppCacheService; | 46 using appcache::AppCacheService; |
47 | 47 |
48 namespace content { | 48 namespace content { |
49 | 49 |
50 namespace { | 50 namespace { |
51 | 51 |
52 // TODO(jacobr) remove https://www.google.com when the dependency on the | |
53 // Google Charts API is removed from the Dart Observatory. | |
54 // TODO(tsepez) remove unsafe-eval when bidichecker_packaged.js fixed. | 52 // TODO(tsepez) remove unsafe-eval when bidichecker_packaged.js fixed. |
55 const char kChromeURLContentSecurityPolicyHeaderBase[] = | 53 const char kChromeURLContentSecurityPolicyHeaderBase[] = |
56 "Content-Security-Policy: script-src chrome://resources " | 54 "Content-Security-Policy: script-src chrome://resources " |
57 "'self' https://www.google.com 'unsafe-eval'; "; | 55 "'self' 'unsafe-eval'; "; |
58 | 56 |
59 const char kChromeURLXFrameOptionsHeader[] = "X-Frame-Options: DENY"; | 57 const char kChromeURLXFrameOptionsHeader[] = "X-Frame-Options: DENY"; |
60 | 58 |
61 const int kNoRenderProcessId = -1; | 59 const int kNoRenderProcessId = -1; |
62 | 60 |
63 bool SchemeIsInSchemes(const std::string& scheme, | 61 bool SchemeIsInSchemes(const std::string& scheme, |
64 const std::vector<std::string>& schemes) { | 62 const std::vector<std::string>& schemes) { |
65 return std::find(schemes.begin(), schemes.end(), scheme) != schemes.end(); | 63 return std::find(schemes.begin(), schemes.end(), scheme) != schemes.end(); |
66 } | 64 } |
67 | 65 |
(...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
728 | 726 |
729 } // namespace | 727 } // namespace |
730 | 728 |
731 net::URLRequestJobFactory::ProtocolHandler* | 729 net::URLRequestJobFactory::ProtocolHandler* |
732 CreateDevToolsProtocolHandler(content::ResourceContext* resource_context, | 730 CreateDevToolsProtocolHandler(content::ResourceContext* resource_context, |
733 bool is_incognito) { | 731 bool is_incognito) { |
734 return new DevToolsJobFactory(resource_context, is_incognito); | 732 return new DevToolsJobFactory(resource_context, is_incognito); |
735 } | 733 } |
736 | 734 |
737 } // namespace content | 735 } // namespace content |
OLD | NEW |