Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: content/browser/loader/resource_request_info_impl.h

Issue 2445993006: [WIP] Upgrade-insecure-request: upgrade insecurely-redirected requests.
Patch Set: bugfix Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 5 #ifndef CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
6 #define CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 6 #define CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 bool do_not_prompt_for_login, 63 bool do_not_prompt_for_login,
64 blink::WebReferrerPolicy referrer_policy, 64 blink::WebReferrerPolicy referrer_policy,
65 blink::WebPageVisibilityState visibility_state, 65 blink::WebPageVisibilityState visibility_state,
66 ResourceContext* context, 66 ResourceContext* context,
67 base::WeakPtr<ResourceMessageFilter> filter, 67 base::WeakPtr<ResourceMessageFilter> filter,
68 bool report_raw_headers, 68 bool report_raw_headers,
69 bool is_async, 69 bool is_async,
70 bool is_using_lofi, 70 bool is_using_lofi,
71 const std::string& original_headers, 71 const std::string& original_headers,
72 const scoped_refptr<ResourceRequestBodyImpl> body, 72 const scoped_refptr<ResourceRequestBodyImpl> body,
73 bool initiated_in_secure_context); 73 bool initiated_in_secure_context,
74 blink::WebInsecureRequestPolicy insecure_request_policy);
74 ~ResourceRequestInfoImpl() override; 75 ~ResourceRequestInfoImpl() override;
75 76
76 // ResourceRequestInfo implementation: 77 // ResourceRequestInfo implementation:
77 WebContentsGetter GetWebContentsGetterForRequest() const override; 78 WebContentsGetter GetWebContentsGetterForRequest() const override;
78 ResourceContext* GetContext() const override; 79 ResourceContext* GetContext() const override;
79 int GetChildID() const override; 80 int GetChildID() const override;
80 int GetRouteID() const override; 81 int GetRouteID() const override;
81 int GetOriginPID() const override; 82 int GetOriginPID() const override;
82 int GetRenderFrameID() const override; 83 int GetRenderFrameID() const override;
83 int GetFrameTreeNodeId() const override; 84 int GetFrameTreeNodeId() const override;
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 } 191 }
191 void set_initiated_in_secure_context_for_testing(bool secure) { 192 void set_initiated_in_secure_context_for_testing(bool secure) {
192 initiated_in_secure_context_ = secure; 193 initiated_in_secure_context_ = secure;
193 } 194 }
194 195
195 void set_navigation_ui_data( 196 void set_navigation_ui_data(
196 std::unique_ptr<NavigationUIData> navigation_ui_data) { 197 std::unique_ptr<NavigationUIData> navigation_ui_data) {
197 navigation_ui_data_ = std::move(navigation_ui_data); 198 navigation_ui_data_ = std::move(navigation_ui_data);
198 } 199 }
199 200
201 blink::WebInsecureRequestPolicy insecure_request_policy() const {
202 return insecure_request_policy_;
203 }
204
200 // PlzNavigate: used in navigations to store the ServiceWorkerContext, since 205 // PlzNavigate: used in navigations to store the ServiceWorkerContext, since
201 // the ResourceMessageFilter will be null in this case. All other requests 206 // the ResourceMessageFilter will be null in this case. All other requests
202 // should access the ServiceWorkerContext through the ResourceMessageFilter. 207 // should access the ServiceWorkerContext through the ResourceMessageFilter.
203 void set_service_worker_context( 208 void set_service_worker_context(
204 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context) { 209 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context) {
205 service_worker_context_ = service_worker_context; 210 service_worker_context_ = service_worker_context;
206 } 211 }
207 ServiceWorkerContextWrapper* service_worker_context() const { 212 ServiceWorkerContextWrapper* service_worker_context() const {
208 return service_worker_context_.get(); 213 return service_worker_context_.get();
209 } 214 }
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 // exits during a transfer. 250 // exits during a transfer.
246 base::WeakPtr<ResourceMessageFilter> filter_; 251 base::WeakPtr<ResourceMessageFilter> filter_;
247 bool report_raw_headers_; 252 bool report_raw_headers_;
248 bool is_async_; 253 bool is_async_;
249 bool is_using_lofi_; 254 bool is_using_lofi_;
250 const std::string original_headers_; 255 const std::string original_headers_;
251 scoped_refptr<ResourceRequestBodyImpl> body_; 256 scoped_refptr<ResourceRequestBodyImpl> body_;
252 bool initiated_in_secure_context_; 257 bool initiated_in_secure_context_;
253 std::unique_ptr<NavigationUIData> navigation_ui_data_; 258 std::unique_ptr<NavigationUIData> navigation_ui_data_;
254 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_; 259 scoped_refptr<ServiceWorkerContextWrapper> service_worker_context_;
260 blink::WebInsecureRequestPolicy insecure_request_policy_;
261
255 262
256 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl); 263 DISALLOW_COPY_AND_ASSIGN(ResourceRequestInfoImpl);
257 }; 264 };
258 265
259 } // namespace content 266 } // namespace content
260 267
261 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_ 268 #endif // CONTENT_BROWSER_LOADER_RESOURCE_REQUEST_INFO_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/loader/resource_dispatcher_host_unittest.cc ('k') | content/browser/loader/resource_request_info_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698