Commit Graph

2036 Commits

Author SHA1 Message Date
John Bruce
91059f1d81 Merge "Restore WVCryptoPlugin Unit Tests" into nyc-dev 2016-04-08 18:22:17 +00:00
Jeff Tinker
ec0c0ff78a Merge "Fix StringIndexOutOfBoundsException in MediaDrmAPITest" into nyc-dev
am: 5dd0d2a

* commit '5dd0d2a5ceb7f72d21ac5e224c5b57c0b438c1f2':
  Fix StringIndexOutOfBoundsException in MediaDrmAPITest

Change-Id: I27ebda8cc4642eb0d44edfd0c31358aa052c1d63
2016-04-08 18:16:35 +00:00
Jeff Tinker
5dd0d2a5ce Merge "Fix StringIndexOutOfBoundsException in MediaDrmAPITest" into nyc-dev 2016-04-08 18:05:12 +00:00
Rahul Frias
9c84e74e9f Load keys before sending OnKeyStatusChange notifications am: 7cb83eb
am: 089eb0f

* commit '089eb0f90cc8be269ee088d3a1300aa2f8fa9d67':
  Load keys before sending OnKeyStatusChange notifications

Change-Id: I92f9689c9c2a877a91b073b191e169bbb8aa40e2
2016-04-08 18:00:30 +00:00
Rahul Frias
089eb0f90c Load keys before sending OnKeyStatusChange notifications
am: 7cb83eb

* commit '7cb83eb02e92abb41349acf1e89d0d31a35f531f':
  Load keys before sending OnKeyStatusChange notifications

Change-Id: I851689274b2edc60edab4775aa490fa16d72a0c7
2016-04-08 17:38:01 +00:00
Jeff Tinker
06c45414b5 Fix StringIndexOutOfBoundsException in MediaDrmAPITest
The AES test was useful to verify the framework API changes, but
the decrypt test was not correct.  Removing it for now.

Merge of go/wvgerrit/17472

bug: 27973491
Change-Id: I942fda22072636ea7ce56b992e7d3a60077c0d27
2016-04-08 16:51:22 +00:00
Rahul Frias
7cb83eb02e Load keys before sending OnKeyStatusChange notifications
[ merge of http://go/wvgerrit/17454 ]

When processing a license or renewal, calls to Set/UpdateLicense
update the policy information. A side effect was introduced whereby
updating the policy may cause (expiration, session key state)
notifications to be sent to the listener. Due to the ordering,
the notifications would be sent before the keys were loaded/refreshed,
which caused issues when the notifications were immediately acted upon.
This has now been corrected.

b/27842970

Change-Id: Id81a71ff48edfa9ca0baafc43267995d5a3e80a6
2016-04-07 15:58:45 -07:00
John "Juce" Bruce
a73dc419fd Restore WVCryptoPlugin Unit Tests
(This is a merge of http://go/wvgerrit/17452)

When the Crypto API was updated, several unit tests were removed, as
they did not work with the new API. This patch restores those tests.

Note that this does not add NEW tests for the new functionality
enabled by the API changes. Those will be coming in a separate patch.
This patch merely restores the previous tests and their functionality.

Bug: 26901698
Change-Id: I3315408804bdc6871b58c3620e482bf6d61fe03b
2016-04-07 12:15:12 -07:00
Rahul Frias
0c96da890d Return ERROR_INSUFFICIENT_OUTPUT_PROTECTION when appropriate am: b76eccf
am: af42233

* commit 'af422336a6e47246ce35dc4d334bc3113a6f5f8b':
  Return ERROR_INSUFFICIENT_OUTPUT_PROTECTION when appropriate

Change-Id: I52260ccd31a031cba37ae77a92b1ebd754e30576
2016-04-06 17:31:56 +00:00
Rahul Frias
af422336a6 Return ERROR_INSUFFICIENT_OUTPUT_PROTECTION when appropriate
am: b76eccf

* commit 'b76eccf32d291f7fce03ba82f56ede28b87e3a4e':
  Return ERROR_INSUFFICIENT_OUTPUT_PROTECTION when appropriate

Change-Id: Ifdb9428997757a1114199244699bc15a2eccf14d
2016-04-06 17:26:38 +00:00
Rahul Frias
b76eccf32d Return ERROR_INSUFFICIENT_OUTPUT_PROTECTION when appropriate
[ Merge from http://go/wvgerrit/17429 ]

This is to correct for when HDCP validation failure at the OEMCrypto level
ends up returning a CryptoException through MediaCrypto with error code
Unknown Error (-2998).

b/27849488

Change-Id: Ib3a9b1c3a17b9323f3d079a678cf88dedeec3b4b
2016-04-05 16:44:31 -07:00
John Bruce
e8d4662456 Merge "Move Widevine Unit Tests to Standard gMock" into nyc-dev am: 19c36a6
am: ff896a0

* commit 'ff896a0a9b996ee62c95abd78671a4a0450c56f7':
  Move Widevine Unit Tests to Standard gMock

Change-Id: I5c545c84bbbbd0bf1f87f28b055ed4f24dd1f76f
2016-04-04 23:25:52 +00:00
John "Juce" Bruce
ff896a0a9b Merge "Move Widevine Unit Tests to Standard gMock" into nyc-dev
am: 19c36a6

* commit '19c36a64d61e180a1fb08b4694b67307af58c089':
  Move Widevine Unit Tests to Standard gMock

Change-Id: Ib115baa314284c94b323632a2f491fc13f0de27b
2016-04-04 23:23:17 +00:00
John Bruce
19c36a64d6 Merge "Move Widevine Unit Tests to Standard gMock" into nyc-dev 2016-04-04 23:13:23 +00:00
Jeff Tinker
aea82cd691 Merge "Fix offline playback using widevine sample player" into nyc-dev am: 971d94e
am: a118a8c

* commit 'a118a8c541a22ef06e357b45e6225e73327ee9a1':
  Fix offline playback using widevine sample player

Change-Id: Ib4aa1c75358ee4d4e1efcab3a51ca02ba362c9c0
2016-04-04 21:43:37 +00:00
Jeff Tinker
a118a8c541 Merge "Fix offline playback using widevine sample player" into nyc-dev
am: 971d94e

* commit '971d94e410362192c932c41b9c296c6ead36b88c':
  Fix offline playback using widevine sample player

Change-Id: Ia2e35560e57b8e64215b1192e0c692e98ac4b09b
2016-04-04 21:40:48 +00:00
Jeff Tinker
971d94e410 Merge "Fix offline playback using widevine sample player" into nyc-dev 2016-04-04 21:27:19 +00:00
Jeff Tinker
ad8e58f6f7 Fix offline playback using widevine sample player
Previously the sample player relied on implementation
details of FileDescriptor.toString() to get the low
level int file descriptor, which changed in N release.
This updates the sample player to use a more reliable
method.

bug: 26422357
Change-Id: I73cc759542994a352eae646a3872ee1125445739
2016-04-04 12:13:53 -07:00
Fred Gylys-Colwell
bbe2447e9f Update Mock Android.mk am: c42f1e9
am: aefda18

* commit 'aefda18f5bdb14b6a52be35396b307a127242f6f':
  Update Mock Android.mk

Change-Id: Ied8ae649cba3f01c4c743a69998883519f6c4f6d
2016-04-01 23:37:26 +00:00
Fred Gylys-Colwell
aefda18f5b Update Mock Android.mk
am: c42f1e9

* commit 'c42f1e93729d0f949115d3e8eeb6fe13723f5aa0':
  Update Mock Android.mk

Change-Id: I33113993d5de38becf9bd8611709a5cd9faa2006
2016-04-01 23:32:49 +00:00
Fred Gylys-Colwell
c42f1e9372 Update Mock Android.mk
Merge from widevine repo of http://go/wvgerrit/17393

This CL changes the installation directory for oemcrypto reference
code. In particular, it uses the new build rules to specifies the library
should go in /vendor/lib instead of /system/lib or /vendor/lib64.

This library should not be used on a production device.

b/26425759

Change-Id: I3a58d0d1ddeb5601b0f2f97cc87c2d4a2a41f0d8
2016-04-01 15:57:56 -07:00
John "Juce" Bruce
0555a7c9de Move Widevine Unit Tests to Standard gMock
(In addition to being a merge of http://go/wvgerrit/17394, this commit
updates tests/Android.mk to no longer try to build the private gMock.)

Previously, we maintained our own version of gMock (named libwvgmock
to avoid naming conflicts) and depended on it for our unit tests. Now
that Android has gMock in the externals/ directory and vaage@ has
eliminated the need for us to customize gMock's arity, we can stop
depending on or maintaining our own copy.

Bug: 26907374
Change-Id: Ia01d6c02e2f28a642480d7ef178b9bc3dde6d306
2016-04-01 14:49:43 -07:00
Fred Gylys-Colwell
318e4c3d51 Level 3 OEMCrypto with symbols removed am: 0e929c2
am: de8574b

* commit 'de8574beaead8ad1672dee6cdef8c71053b3fbf2':
  Level 3 OEMCrypto with symbols removed

Change-Id: If1a557d93f3d4044aaac04921e681b9492e02fd3
2016-03-31 02:13:46 +00:00
Fred Gylys-Colwell
de8574beae Level 3 OEMCrypto with symbols removed
am: 0e929c2

* commit '0e929c2ec75be460b31f54cbc246be04c57ab9c5':
  Level 3 OEMCrypto with symbols removed

Change-Id: I64b8b58dfa7657bc031492ee17a057673cec048b
2016-03-31 02:10:59 +00:00
Fred Gylys-Colwell
0e929c2ec7 Level 3 OEMCrypto with symbols removed
Merge from widevine side of http://go/wvgerrit/17355

The previous build of this library had some filenames and linker
symbols left in that should not be leaked.  This build removes them.

Library versions:
level3/mips/libwvlevel3.a  Level3 Library 4465 Mar 30 2016 13:29:24
level3/arm/libwvlevel3.a  Level3 Library 4445 Mar 30 2016 13:23:54
level3/x86/libwvlevel3.a  Level3 Library 4464 Mar 30 2016 13:26:29

b/27831262

Change-Id: I7801c6f953af338f5e80e95aa27098ae4c7a6c93
2016-03-30 15:56:15 -07:00
Rahul Frias
1cb6ba408d Address failures in Widevine CDM extended duration tests
am: e9f1585

* commit 'e9f15858f0abed11367f6307b73eb534ab512ffb':
  Address failures in Widevine CDM extended duration tests
2016-03-28 08:57:31 +00:00
Rahul Frias
e9f15858f0 Address failures in Widevine CDM extended duration tests
[ Merge of http://go/wvgerrit/17250 ]

This appears to be the result of a bad merge.

b/27657766

Change-Id: I890162595623f1c13973cedc17eb611fac7e5535
2016-03-24 13:38:00 -07:00
Fred Gylys-Colwell
3da72c8fdf Turn off mips64 library (second attempt)
am: 9bf25bc

* commit '9bf25bc67f525bc588c7f0294e2b409c9d053db4':
  Turn off mips64 library (second attempt)
2016-03-24 04:13:22 +00:00
Fred Gylys-Colwell
9bf25bc67f Turn off mips64 library (second attempt)
Merge from widevine repo of http://go/wvgerrit/17223/3

This time I mean it.

b/27786231

Change-Id: I8d4d3acf7470c8b5878b90774f97b5fce1011ccf
2016-03-23 20:52:12 -07:00
Fred Gylys-Colwell
42c7cc700c Turn off mips64 library
am: 19cd8db

* commit '19cd8db256a29c1bd6f16b420c0313679dca76ad':
  Turn off mips64 library
2016-03-23 17:51:42 +00:00
Fred Gylys-Colwell
19cd8db256 Turn off mips64 library
Merge from widevine repo of http://go/wvgerrit/17223

This CL turns off the mips64 bit build for widevine.  This is because
the level 3 mips32 library does not build and run correctly for a 64
bit target.

b/27786231

Change-Id: I3388d9ebc80ae3cf477a8a54adfd1f22dfac4dda
2016-03-23 07:54:31 -07:00
Rahul Frias
727960ded4 Merge "Address SessionSharingTest failures from WV request_license_test" into nyc-dev
am: f886f7f

* commit 'f886f7fc3dc541372d2c91bbd6726cee97e9bdbc':
  Address SessionSharingTest failures from WV request_license_test
2016-03-22 17:44:43 +00:00
Fred Gylys-Colwell
04049d8948 Merge "Change an ASSERT to an EXPECT" into nyc-dev
am: 45eeeed

* commit '45eeeed44490d0bc00b396d8276ed5231b4a662b':
  Change an ASSERT to an EXPECT
2016-03-22 17:32:28 +00:00
Rahul Frias
f886f7fc3d Merge "Address SessionSharingTest failures from WV request_license_test" into nyc-dev 2016-03-22 17:31:48 +00:00
Fred Gylys-Colwell
45eeeed444 Merge "Change an ASSERT to an EXPECT" into nyc-dev 2016-03-22 17:21:02 +00:00
Fred Gylys-Colwell
2efc6821d2 Change an ASSERT to an EXPECT
Merge from widevine repo of http://go/wvgerrit/17202

This allows more checks in the test to run.  Returning the correct
error code is less important than the next check, which verifies the
signature was not computed.

This helps diagnose b/21708882, but does not fix it.

b/27787064

Change-Id: I65306c54b77370951bc54e8ef9f6140f58bea32c
2016-03-22 10:12:18 -07:00
Rahul Frias
85d776c8b8 Address SessionSharingTest failures from WV request_license_test
[ Merge of http://go/wvgerrit/17204 ]

Sleep was being employed, to introduce a delay so that one license expired
but the other was still active. The duration was long enough that
occasionally the second license would also expire, causing the test to fail.
Reduce the sleep duration to correct this behaviour.

b/27673513

Change-Id: Ieef9100c98783c16fc5ab8fe345fa1dd26604f18
2016-03-21 15:29:08 -07:00
Fred Gylys-Colwell
38189dd3f7 Merge "Update to OEMCrypto Level 3 Libraries" into nyc-dev
am: ea77e37

* commit 'ea77e37eb78fdc36acfbc5ce560167978151fa8e':
  Update to OEMCrypto Level 3 Libraries
2016-03-21 17:43:56 +00:00
Fred Gylys-Colwell
ea77e37eb7 Merge "Update to OEMCrypto Level 3 Libraries" into nyc-dev 2016-03-21 17:34:21 +00:00
Jeff Tinker
f54adf6b67 Fix some vendor-specific error reporting
am: 65ed606

* commit '65ed60687283dd8165921e42c9e8e3bfcd91c489':
  Fix some vendor-specific error reporting
2016-03-18 21:44:36 +00:00
Jeff Tinker
65ed606872 Fix some vendor-specific error reporting
Some decryption errors were being reported as
vendor-unique diagnostic codes that were not generally
actionable by an app.  Recently a new
MediaCodec.CryptoException code was added so these types
of failures can be reported as ERROR_UNSUPPORTED_OPERATION,
in which case the app can use an alternate DRM
configuration in a way that does not require
vendor-specific handling. This change remaps this class
of decrypt errors to the new error code.

Merge of http://go/wvgerrit/17110

bug: 25929554
Change-Id: Iff44c2f04f9ee28d065fb17d59bca4032c5d55ca
2016-03-18 14:16:16 -07:00
Fred Gylys-Colwell
943044788b Update to OEMCrypto Level 3 Libraries
Merge from widevine of http://go/wvgerrit/17178

These are the OEMCrypto Level 3 libraries, built using a stable
version of GCC and build tools on nyc-dev.  Code changes are just
merged from master.  Aside from build tool updates, the CL contains a
fix for b/26567162.

Current version (as printed by oemcrypto/level3/print-version-strings):
level3/arm/libwvlevel3.a  Level3 Library 4445 Mar 17 2016 14:11:16
level3/x86/libwvlevel3.a  Level3 Library 4464 Mar 17 2016 13:14:40
level3/mips/libwvlevel3.a  Level3 Library 4465 Mar 17 2016 11:34:50

bug: 26917438
bug: 26567162
Change-Id: I07d526f28e61c5a9b66fa59b78041a93a99dc8e6
2016-03-18 11:16:51 -07:00
Fred Gylys-Colwell
9bbfaff2a7 OEMCrypto unit test with sample size = 160N+16
am: 6a10503

* commit '6a10503b61f0585e996d01a80b569d75082b1083':
  OEMCrypto unit test with sample size = 160N+16
2016-03-16 20:34:48 +00:00
Fred Gylys-Colwell
6a10503b61 OEMCrypto unit test with sample size = 160N+16
Merge from widevine of http://go/wvgerrit/17128

This CL adds a unit test for an edge case that would be handled
differently for HLS and CENC standards.  We enforce the CENC standard.

b/27524491

Change-Id: Ie3cdfaac0fe37dd0eb991179fd84f4e113e07dae
2016-03-16 11:48:43 -07:00
Brian Carlstrom
20dd705d96 vendor/widevine: Make Thread::run threadName argument required
am: 8186284683

* commit '8186284683b121141223db557f3875251a4ae7ff':
  vendor/widevine: Make Thread::run threadName argument required
2016-03-14 15:27:11 +00:00
Brian Carlstrom
8186284683 vendor/widevine: Make Thread::run threadName argument required
Bug: 27557176
Change-Id: I652bb1821190a20b059b70b9b8bacd079f731cbb
2016-03-12 16:08:29 -08:00
Rahul Frias
6b26c68426 Merge "Add CDM integration tests for HLS" into nyc-dev
am: 9df35002d6

* commit '9df35002d602925bea7034a7827682bef8f9803a':
  Add CDM integration tests for HLS
2016-03-11 18:15:55 +00:00
Rahul Frias
c874f8e709 Corrections to support HLS
am: cbde9109b6

* commit 'cbde9109b61beac47e93394f3e03b8fb52e8df97':
  Corrections to support HLS
2016-03-11 18:15:55 +00:00
Rahul Frias
9df35002d6 Merge "Add CDM integration tests for HLS" into nyc-dev 2016-03-11 18:08:55 +00:00
Rahul Frias
59580f40ab Add CDM integration tests for HLS
[ Merge of https://go/wvgerrit/17083 ]

b/27559429

Change-Id: I65a0a163e0e14bf711c257d7ab2c9486ec002c07
2016-03-09 01:13:47 -08:00