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

Side by Side Diff: content/browser/service_worker/service_worker_controllee_request_handler.h

Issue 1652493002: Use request initiator to check for cross origin requests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 months 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HANDLER _H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HANDLER _H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HANDLER _H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HANDLER _H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 const GURL& original_url_via_service_worker, 100 const GURL& original_url_via_service_worker,
101 blink::WebServiceWorkerResponseType response_type_via_service_worker, 101 blink::WebServiceWorkerResponseType response_type_via_service_worker,
102 base::TimeTicks worker_start_time, 102 base::TimeTicks worker_start_time,
103 base::TimeTicks service_worker_ready_time) override; 103 base::TimeTicks service_worker_ready_time) override;
104 104
105 ServiceWorkerVersion* GetServiceWorkerVersion( 105 ServiceWorkerVersion* GetServiceWorkerVersion(
106 ServiceWorkerMetrics::URLRequestJobResult* result) override; 106 ServiceWorkerMetrics::URLRequestJobResult* result) override;
107 bool RequestStillValid( 107 bool RequestStillValid(
108 ServiceWorkerMetrics::URLRequestJobResult* result) override; 108 ServiceWorkerMetrics::URLRequestJobResult* result) override;
109 void MainResourceLoadFailed() override; 109 void MainResourceLoadFailed() override;
110 GURL GetRequestingOrigin() override;
111 110
112 // Sets |job_| to nullptr, and clears all extra response info associated with 111 // Sets |job_| to nullptr, and clears all extra response info associated with
113 // that job, except for timing information. 112 // that job, except for timing information.
114 void ClearJob(); 113 void ClearJob();
115 114
116 bool is_main_resource_load_; 115 bool is_main_resource_load_;
117 base::WeakPtr<ServiceWorkerURLRequestJob> job_; 116 base::WeakPtr<ServiceWorkerURLRequestJob> job_;
118 FetchRequestMode request_mode_; 117 FetchRequestMode request_mode_;
119 FetchCredentialsMode credentials_mode_; 118 FetchCredentialsMode credentials_mode_;
120 FetchRedirectMode redirect_mode_; 119 FetchRedirectMode redirect_mode_;
(...skipping 18 matching lines...) Expand all
139 base::TimeTicks service_worker_ready_time_; 138 base::TimeTicks service_worker_ready_time_;
140 139
141 base::WeakPtrFactory<ServiceWorkerControlleeRequestHandler> weak_factory_; 140 base::WeakPtrFactory<ServiceWorkerControlleeRequestHandler> weak_factory_;
142 141
143 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerControlleeRequestHandler); 142 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerControlleeRequestHandler);
144 }; 143 };
145 144
146 } // namespace content 145 } // namespace content
147 146
148 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HAND LER_H_ 147 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_CONTROLLEE_REQUEST_HAND LER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698