Commit Graph

4700 Commits

Author SHA1 Message Date
Cong Lin
0f32446ee7 Upgrade L3 to v16 and update Android.bp files
Merging CL:
* http://go/wvgerrit/108203
* http://go/wvgerrit/103904 (changes to L3 source files excluded)

Also added ODK dependency which is required by L3 v16.
Do not replace constant sizeof() with a hard-coded value in L3 library because it is target-specific.

Test: Unit tests on gLinux
    jenkins/linux_unit_tests
    jenkins/ce_cdm_tests
Test: Unit tests on Pixel 4(flame-userdebug, rvc-qpr-dev)
    vendor/widevine/libwvdrmengine/build_and_run_all_unit_tests.sh
Test: Manual ExoPlayer L1/L3 playback tests (flame-userdebug)
    WV: Secure HD/SD (cenc,MP4,H264)
    WV: Secure HD/SD (cbc1,MP4,H264)
    WV: Secure HD/SD (cbcs,MP4,H264)
Test: Widevine GTS tests(bramble-userdebug, master)
    http://ab/I23800006571451275
Bug: 136317881
Bug: 139814713
Bug: 173331251
Change-Id: I1656e83a74a0eaf650f55f5e2388819bf5020c0d
2020-11-17 23:28:51 +00:00
Bill Rassieur
a8524e9199 Merge sc-d1-dev 6958804 into master.
Change-Id: Iee3e24dd0df718b2d6d25e42ab948662057fd80a
BUG:171916167
2020-11-07 19:14:17 +00:00
Edwin Wong
bbb3677d3c Merge "Build metrics_dump tool in Android." 2020-11-07 07:21:50 +00:00
Cong Lin
878495fd24 [automerger skipped] Upgrade L3 to v16 and update android makefiles [DO NOT MERGE] am: 2f08c48e94 am: 739ae08bb3 -s ours am: 1a57d8179f
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12868368

Change-Id: I3b75c7e34e8342bfd0a20abd88c6279152a8afe4
2020-11-05 02:51:25 +00:00
Cong Lin
1a57d8179f [automerger skipped] Upgrade L3 to v16 and update android makefiles [DO NOT MERGE] am: 2f08c48e94 am: 739ae08bb3 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12868368

Change-Id: Iaec55ceec6785e1f3282b0b877ef22f71e6135cf
2020-11-05 02:17:15 +00:00
Cong Lin
739ae08bb3 Upgrade L3 to v16 and update android makefiles [DO NOT MERGE] am: 2f08c48e94
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12868368

Change-Id: Iacd880e4efcb8bb15247407714b1f6f832b67e1a
2020-11-05 01:47:34 +00:00
Cong Lin
2f08c48e94 Upgrade L3 to v16 and update android makefiles [DO NOT MERGE]
Merging CL:
https://widevine-internal-review.googlesource.com/c/cdm/+/108203
and
https://widevine-internal-review.git.corp.google.com/c/cdm/+/103904 (changes to the L3 source files are excluded)

Generated L3 v16 for Android and added ODK dependency required by L3 v16.

Test: Unit tests on gLinux
    jenkins/linux_unit_tests
    jenkins/ce_cdm_tests
Test: Unit tests on Pixel 4(flame-userdebug, rvc-qpr-dev)
    vendor/widevine/libwvdrmengine/build_and_run_all_unit_tests.sh
Test: Manual ExoPlayer playback tests on Pixel 4(flame-userdebug) for L1 and L3
    WV: Secure HD/SD (cenc,MP4,H264)
    WV: Secure HD/SD (cbc1,MP4,H264)
    WV: Secure HD/SD (cbcs,MP4,H264)
Test: Widevine GTS tests(bramble-userdebug, rvc-qpr-dev)
    https://android-build.googleplex.com/builds/tests/view?invocationId=I35000006266076664&testResultId=TR45714199883476235
    (Note: the two failures are due to GTS/http issue and not related/specific to L3 and the change)
Bug: 136317881
Bug: 139814713
Change-Id: If3d4999ca3b725eab76c41588f202beec3873928
2020-11-04 18:53:04 +00:00
Rahul Frias
63dfc73ea0 Sign fake license request if usage tables are not supported am: ea2b3d3178
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12967007

Change-Id: I9224c53533b83ac64904eaf8fd60e773a8864675
2020-11-03 21:01:47 +00:00
Rahul Frias
4a90728e38 Skip LicenseRenewalSpecifiedServer for local license server am: 95ff0f14fd
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12967004

Change-Id: I2d14047d74d13b118777f415c3ca0137a1cac559
2020-11-03 21:01:46 +00:00
Rahul Frias
9c36513f98 Merge changes I7cd424ae,I20f5d6a9 am: eee7a4edd7
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12967146

Change-Id: I0c31082a67f25478f85a5a495da8205c7084b6aa
2020-11-03 21:01:36 +00:00
Rahul Frias
ea2b3d3178 Sign fake license request if usage tables are not supported
Merge of http://go/wvgerrit/106823

Previously, we worked around a problem by signing a fake license
request when a license did not have a usage entry. However, this was
inside a conditional that the device did support usage tables. This CL
moves that code outside the conditional so that a fake license is
signed whenever the license does not have an entry.

Bug: 169591716
Test: unit and integration tests
Change-Id: Ic4d1a91af63503722b088a136c0a8dca9746a962
2020-11-03 20:12:34 +00:00
Rahul Frias
95ff0f14fd Skip LicenseRenewalSpecifiedServer for local license server
Merge of http://go/wvgerrit/105063

When running the local license server, the license does not contain a
URL for the renewal, or it is mangled. We only need to run this test
if we are running against UAT or UAT Nightly.

Bug: only found when debugging
Test: Ran tests with local license server
Change-Id: Ic84fcf9033b945a176119639a21104e4d42258a9
2020-11-03 20:12:17 +00:00
Rahul Frias
eee7a4edd7 Merge changes I7cd424ae,I20f5d6a9
* changes:
  Add Duration Use Case integration tests
  Add some policy integration tests
2020-11-03 20:11:23 +00:00
Edwin Wong
d5d0652d4f Build metrics_dump tool in Android.
Replace Makefile with Android.bp.
Remove duplication of protos in proto directory.

Since we are now building the metrics_dump tool
under Android, use frameworks metrics.proto
directly. Also, reference cdm's wv_metrics.proto
from the cdm directory instead of creating a
subset in proto directory.

bug: 161783052
bug: 170607430

Test: build
  m -j128 metrics_dump
Test: metrics_dump [bugreport from adt-3-r.zip]
Test: metrics_dump [bugreport from sabrina-q.gz]
Test: metrics_dump --widevine [adb shell dumpsys media.metrics output]
Change-Id: I82c7e723453ac2a6335cb2bb732a376d535b9ea3
2020-11-03 10:19:32 -08:00
Alex Dale
c23f6ac08c Merge "Include "origin" in license request client ID" am: cbb1d11a72
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12969258

Change-Id: I466e31c2a19e6d2e0da84154039360a70e418671
2020-11-03 01:42:39 +00:00
Rahul Frias
27a41b9ff1 Merge "Address test failures" am: 37be367712
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12403057

Change-Id: Idf87988d39055b9147114ad13adc578972e49c9b
2020-11-03 01:42:10 +00:00
TreeHugger Robot
74d0322a5d Merge "Avoid setting OEMCrypto_Algorithm enum vars with invalid values" am: 4447748573
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12626650

Change-Id: I2a59d90719110e979da24c067ee25d80c70c6190
2020-11-03 01:40:47 +00:00
Alex Dale
cbb1d11a72 Merge "Include "origin" in license request client ID" 2020-11-03 00:52:45 +00:00
Rahul Frias
37be367712 Merge "Address test failures" 2020-11-03 00:52:05 +00:00
TreeHugger Robot
4447748573 Merge "Avoid setting OEMCrypto_Algorithm enum vars with invalid values" 2020-11-03 00:49:11 +00:00
Rahul Frias
b1f54bbba8 Add Duration Use Case integration tests
Cherry pick from http://go/wvgerrit/102986, rvc-dev branch of
http://go/wvgerrit/105825, rvc-widevine-release of http://go/ag/12561661

This CL adds several integration tests that match the duration use
cases. The test classes are designed for the core cdm, but the test
cases match those found in oemcrypto/odk/test/odk_timer_test.cpp.

See this document for a list of use cases:
libwvdrmengine/docs/License_Duration_and_Renewal.pdf

Test: Ran the tests against v16 OEMCrypto. Some fail against v15.
Bug: 161463952
Change-Id: I7cd424ae241d3897fbd06956e87dd9da0752cb6d
2020-11-02 23:10:41 +00:00
Rahul Frias
d1dff772d3 Add some policy integration tests
Cherry-pick from branch rvc-dev of http://go/wvgerrit/105824 and
rvc-widevine-release http://go/ag/12561660

This adds two policy integration tests to verify that we are handling offline
licenses correctly.

Bug: 161023174
Bug: 129301787
Test: WV unit/integration tests
Change-Id: I20f5d6a9fbfd2ff8cff361e1005e45b46c700704
2020-11-02 00:44:02 -08:00
TreeHugger Robot
440fa8e164 Merge "Fix OpenSSL Builds" am: 712784055b
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12905382

Change-Id: Ie4bcf32c77bf2963edee97d375fcde28e46f460f
2020-10-29 01:23:34 +00:00
Alex Dale
4028784836 Include "origin" in license request client ID
[ Merge of http://go/wvgerrit/108823 ]

Android CDM will include the session origin in the client info
component of the client ID of a license request.

The "origin" is only to be included on Android CDM, and not the CE
CDM.  The origin is provided to the license request via the app
parameters in the WVDrmPlugin.

A separate GTS test is in development and will be submitted to the
Android media GTS test set.

Bug: 164549928
Test: Manual test and GTS test
Change-Id: I67f8b064b2aefdc08328ea14551d4aa4cb57023d
2020-10-28 17:29:18 -07:00
TreeHugger Robot
712784055b Merge "Fix OpenSSL Builds" 2020-10-28 21:47:37 +00:00
Rahul Frias
42ecc6404b Address test failures
[ Merge of http://go/wvgerrit/104584 ]

This corrects failures in
* WVDrmPluginTest.ReturnsL3SpoidsWhenL3ProvisionedUsingL3Spoid
* WVDrmPluginTest.ReturnsL3SpoidsWhenL3Unprovisioned
* WVDrmPluginTest.ReturnsL1SpoidsWhenL3ProvisionedUsingL1Spoid

and a warning in
* PolicyEngineTest.PlaybackOk_RentalAndLicense0_WithPlaybackBeforeLicense_V15

Bug: 163542905
Test: WVDrmPluginTest and PolicyEngineTest
Change-Id: I3e7799175b7b289fafd2caf88bd5df4123b88973
2020-10-27 02:23:59 -07:00
Baligh Uddin
9415e9a70c [automerger skipped] Cleanup references to system/core/base -> system/libbase am: 673ca3c689 am: 2ccfaeac56 -s ours am: 43f6d79ffa -s ours
am skip reason: Change-Id I3412348b28b56b13702af14ce77238fac506efdd with SHA-1 fa9ce28dd3 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12917865

Change-Id: I2bd2b7440b227903e685cd3ecef17ed9a5c94a14
2020-10-26 23:42:34 +00:00
Baligh Uddin
43f6d79ffa [automerger skipped] Cleanup references to system/core/base -> system/libbase am: 673ca3c689 am: 2ccfaeac56 -s ours
am skip reason: Change-Id I3412348b28b56b13702af14ce77238fac506efdd with SHA-1 fa9ce28dd3 is in history

Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12917865

Change-Id: Iada7de0093fff3dd77571fd6029a1c6de9e58be9
2020-10-26 23:25:27 +00:00
Baligh Uddin
2ccfaeac56 Cleanup references to system/core/base -> system/libbase am: 673ca3c689
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12917865

Change-Id: I6b48816ef96567b7c7f8aff643706f624b46a1b9
2020-10-26 23:12:52 +00:00
Baligh Uddin
563d681033 Cleanup references to system/core/base -> system/libbase am: fa9ce28dd3
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12917859

Change-Id: I5b70d4775d84af64c809d6f75eb8af6390f82cce
2020-10-26 14:27:39 +00:00
Baligh Uddin
673ca3c689 Cleanup references to system/core/base -> system/libbase
BUG: 157656545
Test: TH
Merged-In: I3412348b28b56b13702af14ce77238fac506efdd
Change-Id: I9398826834a360afdf973c94afb11edcd65a6779
2020-10-26 03:32:32 +00:00
Baligh Uddin
fa9ce28dd3 Cleanup references to system/core/base -> system/libbase
BUG: 157656545
Test: TH
Change-Id: I3412348b28b56b13702af14ce77238fac506efdd
2020-10-25 18:23:39 +00:00
John W. Bruce
0f2a4a40dc Fix OpenSSL Builds
(This is a merge of the parts of http://go/wvgerrit/105985 that affect
Android.)

This patch fixes some files that, after recent changes, were no longer
building when using OpenSSL instead of BoringSSL. <memory> was missing
in a header, and a function whose return type is different on OpenSSL
was tripping up the format-string warnings.

Bug: 168553979
Test: jenkins/ce_cdm_tests
Test: Android CDM Build
Change-Id: Id6a33d0ce0d3cbe5fe33b3f22aa3ee6b03ac76dd
2020-10-22 18:00:09 -07:00
Rahul Frias
5151daec19 Avoid setting OEMCrypto_Algorithm enum vars with invalid values
[ Merge of http://go/wvgerrit/106203 ]

CdmSigningAlgorithm are converted into OEMCrypto_Algorithm enums
before being passed as parameters to OEMCrypto generic crypto functions.
The OEMCrypto_Algorithm variables should never be set to values not
specified in the enum declaration.

These private methods have also been moved to the anonymous namespace.

Bug: 168774486
Test: WV unit/integration tests
Change-Id: Ie570a3cf4447b6c133076baa0909d562824c8e4a
2020-10-22 16:39:19 -07:00
Rahul Frias
1bf0360d22 Merge changes I9a4977fd,I8ae5a10c,I0f9e6445 am: 1381746ecb
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12886534

Change-Id: I97cfa7efe2bb3e60051b0fe42fd319c51b9ed775
2020-10-22 10:41:25 +00:00
Rahul Frias
1381746ecb Merge changes I9a4977fd,I8ae5a10c,I0f9e6445
* changes:
  Update Widevine Copyright header
  Update Widevine Copyright header for core CDM
  Update Widevine Copyright header for android
2020-10-22 10:24:45 +00:00
TreeHugger Robot
fc374516b1 Merge "Merge recent doc changes for OEMCrypto" am: a53fb38be1
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12566583

Change-Id: I138fafceca64b76a712b17caf2a960d7c579683f
2020-10-22 00:12:20 +00:00
TreeHugger Robot
a53fb38be1 Merge "Merge recent doc changes for OEMCrypto" 2020-10-21 23:15:27 +00:00
Rahul Frias
53019f0459 Update Widevine Copyright header
[ Merge of http://go/wvgerrit/108103 ]

The Widevine License Agreement has been renamed to use inclusive
language. This covers files in the cdm, linux, platform, util directory
in addition to some other files.

Bug: 168562298
Test: verified compilation (comment only change)
Change-Id: I9a4977fd4c2ad951769b6be84263f81bd0f22678
2020-10-21 12:54:20 -07:00
Rahul Frias
6a1f050ffc Update Widevine Copyright header for core CDM
[ Merge of http://go/wvgerrit/108064 ]

The Widevine License Agreement has been renamed to use inclusive
language. This covers files in the core directory.

Bug: 168562298
Test: verified compilation (comment only change)
Change-Id: I8ae5a10cbfdf7faae6a2735e57b33729763f10b8
2020-10-21 12:05:05 -07:00
Rahul Frias
ec8bed38f4 Update Widevine Copyright header for android
[ Merge of http://go/wvgerrit/108084 ]

The Widevine License Agreement has been renamed to use inclusive
language. This covers files in the android directory.

Bug: 168562298
Test: verified compilation (comment only change)
Change-Id: I0f9e6445e0168ebe85425baeb81371e182e5a39c
2020-10-21 02:49:05 -07:00
Alex Dale
8dec2e38d8 Merge "Query analog output capabilities." am: 471e8c900d
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12850663

Change-Id: Ifff6d5613417954dc4b3541e6d97049b220d5ace
2020-10-19 23:28:08 +00:00
Alex Dale
471e8c900d Merge "Query analog output capabilities." 2020-10-19 23:01:32 +00:00
John Bruce
7ee2c28ab7 Merge changes I9432dd26,Id52b8c38 am: cc715b479d
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12776079

Change-Id: Ic2b17ebd656e832dcf5775de49a1200bac4fcedf
2020-10-19 19:51:22 +00:00
John Bruce
cc715b479d Merge changes I9432dd26,Id52b8c38
* changes:
  Allow 1 or 2 GetOEMPublicCertificate Calls in Metrics Tests
  Fix TimeRollbackPrevention Test
2020-10-19 19:35:40 +00:00
Alex Dale
fb847c4704 Query analog output capabilities.
[ Merge of http://go/wvgerrit/107763 ]

This CL enables the ability to query the CDM for the analog output
capabilites of the device.  Due to the number of possibilities that
OEMCrypto can report, two queries are exposed:
- Output capabilities: None, Supported, CGMS-C, Unknown
- Can disable: True, False, Unknown

Bug: 168322023
Test: Android integration test
Change-Id: I8036a89237d698f170d2c1901c41d1d6b708c917
2020-10-15 17:46:13 -07:00
Ian Baker
a9228a2be6 Merge "Update GtsExoPlayerTestCases class name in WV script" am: be0218e48f
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12717348

Change-Id: If28baa470493585cc1948d3089b4c1034f3796e2
2020-10-15 11:37:51 +00:00
Ian Baker
be0218e48f Merge "Update GtsExoPlayerTestCases class name in WV script" 2020-10-15 11:14:48 +00:00
Rahul Frias
5bd5e1d749 Merge "Avoid passing device ID when unused" am: bab666ecdc
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12545178

Change-Id: I29890a006c552897ccce70118c24b251c0674119
2020-10-11 23:47:34 +00:00
Rahul Frias
bab666ecdc Merge "Avoid passing device ID when unused" 2020-10-11 23:34:17 +00:00