Summary: | Mac: <audio> and <video> should send Do Not Track when appropriate | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Jer Noble <jer.noble> | ||||||||
Component: | New Bugs | Assignee: | Jer Noble <jer.noble> | ||||||||
Status: | RESOLVED WONTFIX | ||||||||||
Severity: | Normal | CC: | abecsi, cmarcelo, dglazkov, eric.carlson, feature-media-reviews, japhet, menard, webkit.review.bot, zoltan | ||||||||
Priority: | P2 | ||||||||||
Version: | 528+ (Nightly build) | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Unspecified | ||||||||||
Attachments: |
|
Description
Jer Noble
2012-09-07 11:17:14 PDT
Created attachment 162834 [details]
Patch
Comment on attachment 162834 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=162834&action=review > Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:304 > if ([headerFields.get() count]) > [options.get() setObject:headerFields.get() forKey:@"AVURLAssetHTTPHeaderFieldsKey"]; > + > + if (player()->mediaPlayerClient()->mediaPlayerShouldSendDoNotTrackHTTPHeader()) > + [headerFields.get() setObject:@"1" forKey:@"DNT"]; You should set the DNT header field first or AVURLAssetHTTPHeaderFieldsKey won't be set in the dictionary if there isn't a referrer or a UA header. > LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:8 > + > + Nit: two blank lines? > LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:17 > + > + Ditto. > LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:18 > + error_log(var_export(headers_list(), true)); What does this do? > LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:20 > + > + Nit: two blank lines? > LayoutTests/http/tests/media/video-donottrack.html:11 > +<script src=../../media-resources/video-test.js></script> > +<script src=../../media-resources/media-file.js></script> > +<script> > + function runTest () { Nit: is there any reason this isn't in the <head>? Comment on attachment 162834 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=162834&action=review >> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:304 >> + [headerFields.get() setObject:@"1" forKey:@"DNT"]; > > You should set the DNT header field first or AVURLAssetHTTPHeaderFieldsKey won't be set in the dictionary if there isn't a referrer or a UA header. Sure thing. >> LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:8 >> + > > Nit: two blank lines? I'll condense these. >> LayoutTests/http/tests/media/resources/video-donottrack-check-donottrack.php:18 >> + error_log(var_export(headers_list(), true)); > > What does this do? This was just for debugging purposes, so that run-webkit-httpd would spit out the entire outgoing header array before returning. I'll remove it. Thanks! Created attachment 162852 [details]
Patch
Patch for the EWS bots.
Comment on attachment 162852 [details] Patch Attachment 162852 [details] did not pass qt-wk2-ews (qt): Output: http://queues.webkit.org/results/13772887 Created attachment 162889 [details]
Patch
Fix the Qt build.
Comment on attachment 162889 [details]
Patch
This looks fine to me, but don't you have to skip the new test on some platforms?
Comment on attachment 162889 [details] Patch Attachment 162889 [details] did not pass chromium-ews (chromium-xvfb): Output: http://queues.webkit.org/results/13794258 New failing tests: http/tests/media/video-donottrack.html Committed r128081: <http://trac.webkit.org/changeset/128081> Skipped the new test on & filed the following bugs for other platforms: Chromium: https://bugs.webkit.org/show_bug.cgi?id=96287 GTK: https://bugs.webkit.org/show_bug.cgi?id=96290 Qt: https://bugs.webkit.org/show_bug.cgi?id=96291 EFL: https://bugs.webkit.org/show_bug.cgi?id=96292 Win: https://bugs.webkit.org/show_bug.cgi?id=96293 Rolled out in <http://trac.webkit.org/changeset/128129> |