Title: [226965] trunk
Revision
226965
Author
[email protected]
Date
2018-01-16 00:13:04 -0800 (Tue, 16 Jan 2018)

Log Message

[WPE] Two clearkey tests failing since r226621
https://bugs.webkit.org/show_bug.cgi?id=181532

Patch by Yacine Bandou <[email protected]> on 2018-01-16
Reviewed by Xabier Rodriguez-Calvar.

Source/WebCore:

Whith a fake initData, we can have a pssh size nul, thus we should check it.
We saw this issue in the subtest "initData longer than 64Kb characters" in
the clearkey-generate-request-disallowed-input layout test.

* platform/encryptedmedia/clearkey/CDMClearKey.cpp:
(WebCore::extractKeyidsLocationFromCencInitData):

LayoutTests:

* platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input-expected.txt:
* platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-unique-origin-expected.txt:
    Since r226621 initDataType "cenc" is supported in clearKey, so we should update the expected result of these tests.

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (226964 => 226965)


--- trunk/LayoutTests/ChangeLog	2018-01-16 08:04:12 UTC (rev 226964)
+++ trunk/LayoutTests/ChangeLog	2018-01-16 08:13:04 UTC (rev 226965)
@@ -1,5 +1,16 @@
 2018-01-16  Yacine Bandou  <[email protected]>
 
+        [WPE] Two clearkey tests failing since r226621
+        https://bugs.webkit.org/show_bug.cgi?id=181532
+
+        Reviewed by Xabier Rodriguez-Calvar.
+
+        * platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input-expected.txt:
+        * platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-unique-origin-expected.txt:
+            Since r226621 initDataType "cenc" is supported in clearKey, so we should update the expected result of these tests.
+
+2018-01-16  Yacine Bandou  <[email protected]>
+
         [EME] some fixes in clearKey-encrypted-cenc-event LayoutTest
         https://bugs.webkit.org/show_bug.cgi?id=181526
 

Modified: trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input-expected.txt (226964 => 226965)


--- trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input-expected.txt	2018-01-16 08:04:12 UTC (rev 226964)
+++ trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-generate-request-disallowed-input-expected.txt	2018-01-16 08:13:04 UTC (rev 226965)
@@ -1,5 +1,8 @@
 
+FAIL org.w3.clearkey, temporary, cenc, initData longer than 64Kb characters assert_equals: expected "TypeError" but got "NotSupportedError"
 PASS org.w3.clearkey, temporary, keyids, initData longer than 64Kb characters 
+FAIL org.w3.clearkey, temporary, cenc, invalid initdata (invalid pssh) assert_equals: expected "TypeError" but got "NotSupportedError"
+FAIL org.w3.clearkey, temporary, cenc, invalid initdata (not pssh) assert_equals: expected "TypeError" but got "NotSupportedError"
 FAIL org.w3.clearkey, temporary, keyids, invalid initdata (too short key ID) assert_unreached: generateRequest() succeeded unexpectedly Reached unreachable code
 FAIL org.w3.clearkey, temporary, keyids, invalid initdata (too long key ID) assert_unreached: generateRequest() succeeded unexpectedly Reached unreachable code
 

Modified: trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-unique-origin-expected.txt (226964 => 226965)


--- trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-unique-origin-expected.txt	2018-01-16 08:04:12 UTC (rev 226964)
+++ trunk/LayoutTests/platform/wpe/imported/w3c/web-platform-tests/encrypted-media/clearkey-mp4-unique-origin-expected.txt	2018-01-16 08:13:04 UTC (rev 226965)
@@ -1,3 +1,4 @@
 
-FAIL Unique origin is unable to create MediaKeys promise_test: Unhandled rejection with value: object "NotSupportedError: The operation is not supported."
+FAIL Unique origin is unable to create MediaKeys assert_equals: expected "failed" but got "allowed"
 
+

Modified: trunk/Source/WebCore/ChangeLog (226964 => 226965)


--- trunk/Source/WebCore/ChangeLog	2018-01-16 08:04:12 UTC (rev 226964)
+++ trunk/Source/WebCore/ChangeLog	2018-01-16 08:13:04 UTC (rev 226965)
@@ -1,3 +1,17 @@
+2018-01-16  Yacine Bandou  <[email protected]>
+
+        [WPE] Two clearkey tests failing since r226621
+        https://bugs.webkit.org/show_bug.cgi?id=181532
+
+        Reviewed by Xabier Rodriguez-Calvar.
+
+        Whith a fake initData, we can have a pssh size nul, thus we should check it.
+        We saw this issue in the subtest "initData longer than 64Kb characters" in
+        the clearkey-generate-request-disallowed-input layout test.
+
+        * platform/encryptedmedia/clearkey/CDMClearKey.cpp:
+        (WebCore::extractKeyidsLocationFromCencInitData):
+
 2018-01-15  Yoav Weiss  <[email protected]>
 
         Support for preconnect Link headers

Modified: trunk/Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.cpp (226964 => 226965)


--- trunk/Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.cpp	2018-01-16 08:04:12 UTC (rev 226964)
+++ trunk/Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.cpp	2018-01-16 08:13:04 UTC (rev 226965)
@@ -187,6 +187,10 @@
 
         psshSize = data[index + 2] * 256 + data[index + 3];
 
+        // Check the pssh size
+        if (!psshSize)
+            return keyIdsMap;
+
         // 12 = BMFF box header + Full box header.
         if (!memcmp(&data[index + 12], clearKeyCencSystemId, clearKeyCencSystemIdSize)) {
             foundPssh = true;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to