OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CONTENT_COMMON_RESOURCE_REQUEST_H_ | 5 #ifndef CONTENT_COMMON_RESOURCE_REQUEST_H_ |
6 #define CONTENT_COMMON_RESOURCE_REQUEST_H_ | 6 #define CONTENT_COMMON_RESOURCE_REQUEST_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "base/optional.h" | 12 #include "base/optional.h" |
13 #include "content/common/content_export.h" | 13 #include "content/common/content_export.h" |
14 #include "content/common/navigation_params.h" | 14 #include "content/common/navigation_params.h" |
15 #include "content/common/resource_request_body_impl.h" | 15 #include "content/common/resource_request_body_impl.h" |
16 #include "content/common/service_worker/service_worker_types.h" | 16 #include "content/common/service_worker/service_worker_types.h" |
17 #include "content/public/common/appcache_info.h" | 17 #include "content/public/common/appcache_info.h" |
18 #include "content/public/common/previews_state.h" | 18 #include "content/public/common/previews_state.h" |
19 #include "content/public/common/request_context_frame_type.h" | 19 #include "content/public/common/request_context_frame_type.h" |
20 #include "content/public/common/request_context_type.h" | 20 #include "content/public/common/request_context_type.h" |
21 #include "content/public/common/resource_type.h" | 21 #include "content/public/common/resource_type.h" |
22 #include "net/base/request_priority.h" | 22 #include "net/base/request_priority.h" |
| 23 #include "third_party/WebKit/public/platform/WebInsecureRequestPolicy.h" |
23 #include "third_party/WebKit/public/platform/WebMixedContentContextType.h" | 24 #include "third_party/WebKit/public/platform/WebMixedContentContextType.h" |
24 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" | 25 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" |
25 #include "third_party/WebKit/public/platform/WebReferrerPolicy.h" | 26 #include "third_party/WebKit/public/platform/WebReferrerPolicy.h" |
26 #include "ui/base/page_transition_types.h" | 27 #include "ui/base/page_transition_types.h" |
27 #include "url/gurl.h" | 28 #include "url/gurl.h" |
28 #include "url/origin.h" | 29 #include "url/origin.h" |
29 | 30 |
30 namespace content { | 31 namespace content { |
31 | 32 |
32 struct CONTENT_EXPORT ResourceRequest { | 33 struct CONTENT_EXPORT ResourceRequest { |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 // access to the body of the response that has already been fetched by the | 189 // access to the body of the response that has already been fetched by the |
189 // browser. | 190 // browser. |
190 GURL resource_body_stream_url; | 191 GURL resource_body_stream_url; |
191 | 192 |
192 // Wether or not the initiator of this request is a secure context. | 193 // Wether or not the initiator of this request is a secure context. |
193 bool initiated_in_secure_context = false; | 194 bool initiated_in_secure_context = false; |
194 | 195 |
195 // The response should be downloaded and stored in the network cache, but not | 196 // The response should be downloaded and stored in the network cache, but not |
196 // sent back to the renderer. | 197 // sent back to the renderer. |
197 bool download_to_network_cache_only = false; | 198 bool download_to_network_cache_only = false; |
| 199 |
| 200 // The insecure request policy of the context which triggered this request: |
| 201 // https://w3c.github.io/webappsec-upgrade-insecure-requests/#insecure-request
s-policy |
| 202 blink::WebInsecureRequestPolicy insecure_request_policy = |
| 203 blink::kLeaveInsecureRequestsAlone; |
198 }; | 204 }; |
199 | 205 |
200 } // namespace content | 206 } // namespace content |
201 | 207 |
202 #endif // CONTENT_COMMON_RESOURCE_REQUEST_H_ | 208 #endif // CONTENT_COMMON_RESOURCE_REQUEST_H_ |
OLD | NEW |