Bug 181594 - [EME] Add layout test for the MSE playback of ClearKey encrypted audio and video
Summary: [EME] Add layout test for the MSE playback of ClearKey encrypted audio and video
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-01-12 07:58 PST by Yacine Bandou
Modified: 2018-01-16 00:17 PST (History)
6 users (show)

See Also:


Attachments
Patch (289.50 KB, patch)
2018-01-12 09:41 PST, Yacine Bandou
no flags Details | Formatted Diff | Diff
Patch (289.50 KB, patch)
2018-01-15 07:18 PST, Yacine Bandou
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yacine Bandou 2018-01-12 07:58:04 PST
Add new layout tests in order to test the playback of ClearKey encrypted content:

- clearKey-cenc-audio-playback-mse : test the MSE playback of ClearKey encrypted audio track wich use the full-sample encryption.

- clearKey-cenc-video-playback-mse : test the MSE playback of ClearKey encrypted video track wich use the sub-sample encryption scheme.
Comment 1 Yacine Bandou 2018-01-12 09:41:08 PST
Created attachment 331208 [details]
Patch
Comment 2 Xabier Rodríguez Calvar 2018-01-15 00:58:05 PST
Comment on attachment 331208 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=331208&action=review

> LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-audio-playback-mse.html:33
> +        let ms = new MediaSourceLoaderSimple(video);

You can probably use const here.

> LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-video-playback-mse.html:17
> +        let emeHandler = new EncryptedMediaHandler(video, videoConf);

You can probably use const here.

> LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-video-playback-mse.html:33
> +        let ms = new MediaSourceLoaderSimple(video);

Ditto.

> LayoutTests/platform/wpe/TestExpectations:1132
> +webkit.org/b/180080 media/encrypted-media/clearKey/clearKey-cenc-audio-playback-mse.html [ Crash ]

?
Comment 3 Yacine Bandou 2018-01-15 06:45:55 PST
(In reply to Xabier Rodríguez Calvar from comment #2)
> Comment on attachment 331208 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=331208&action=review
> 
> > LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-audio-playback-mse.html:33
> > +        let ms = new MediaSourceLoaderSimple(video);
> 
> You can probably use const here.

Yes

> 
> > LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-video-playback-mse.html:17
> > +        let emeHandler = new EncryptedMediaHandler(video, videoConf);
> 
> You can probably use const here.

Yes

> 
> > LayoutTests/media/encrypted-media/clearKey/clearKey-cenc-video-playback-mse.html:33
> > +        let ms = new MediaSourceLoaderSimple(video);
> 
> Ditto.

Yes

> 
> > LayoutTests/platform/wpe/TestExpectations:1132
> > +webkit.org/b/180080 media/encrypted-media/clearKey/clearKey-cenc-audio-playback-mse.html [ Crash ]
> 
> ?

Crash because the content follow the full-sample encryption, thus the subSamplesBuffer is nul

So we crash in this line:

>Source/WebCore/platform/graphics/gstreamer/eme/WebKitClearKeyDecryptorGStreamer.cpp:240
GstMapInfo subSamplesMap;
gboolean subsamplesBufferMapped = gst_buffer_map(subSamplesBuffer, &subSamplesMap, GST_MAP_READ);
Comment 4 Yacine Bandou 2018-01-15 07:18:12 PST
Created attachment 331335 [details]
Patch
Comment 5 WebKit Commit Bot 2018-01-16 00:16:38 PST
Comment on attachment 331335 [details]
Patch

Clearing flags on attachment: 331335

Committed r226966: <https://trac.webkit.org/changeset/226966>
Comment 6 WebKit Commit Bot 2018-01-16 00:16:39 PST
All reviewed patches have been landed.  Closing bug.
Comment 7 Radar WebKit Bug Importer 2018-01-16 00:17:28 PST
<rdar://problem/36536151>