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

Unified Diff: media/blink/buffered_resource_loader.h

Issue 1220963004: Check the response URL origin in BufferedDataSource to avoid mixing cross-origin responses. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: incorporated hubbe's comment Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/blink/buffered_data_source_unittest.cc ('k') | media/blink/buffered_resource_loader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/buffered_resource_loader.h
diff --git a/media/blink/buffered_resource_loader.h b/media/blink/buffered_resource_loader.h
index cb0272063ec61f9ab7819ca0417a6102556c9c4f..6e466a37b0c80cea6b5c8802ab51e65d285c5f7a 100644
--- a/media/blink/buffered_resource_loader.h
+++ b/media/blink/buffered_resource_loader.h
@@ -205,6 +205,11 @@ class MEDIA_EXPORT BufferedResourceLoader
// playback rate).
void CancelUponDeferral();
+ // Returns the original URL of the response. If the request is redirected to
+ // another URL it is the URL after redirected. If the response is generated in
+ // a Service Worker it is empty.
+ const GURL response_original_url() const { return response_original_url_; }
+
private:
friend class BufferedDataSourceTest;
friend class BufferedResourceLoaderTest;
@@ -316,6 +321,8 @@ class MEDIA_EXPORT BufferedResourceLoader
// Playback rate of the media.
double playback_rate_;
+ GURL response_original_url_;
+
scoped_refptr<MediaLog> media_log_;
bool cancel_upon_deferral_;
« no previous file with comments | « media/blink/buffered_data_source_unittest.cc ('k') | media/blink/buffered_resource_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698