Edwin Wong
6fe341c845
Merge "Add arguments to Widevine lshal debug hook."
2020-07-20 22:24:53 +00:00
Edwin Wong
5b8d21164d
Add arguments to Widevine lshal debug hook.
...
Add options to dump Widevine Cdm properties,
Widevine Cdm metrics, or both.
The valid arguments are Cdm Metrics (m|M) or Cdm Properties (p|P).
If no arguments are provided, both Cdm properties and
Cdm metrics will be displayed.
Test: adb shell lshal debug [drm service] [m/p]
adb shell lshal debug android.hardware.drm@1.3::IDrmFactory/widevine
Bug: 154027349
Change-Id: I95c10dd7d4274226936295c73be4eb1612c2ef6a
2020-07-20 13:51:38 -07:00
Rahul Frias
297a289a31
Merge "Correct ordering of test expectations"
2020-07-16 22:45:29 +00:00
Alex Dale
7ce8950c0f
Usage table LRU only retrieves a single entry.
...
[ Merge of http://go/wvgerrit/102167 ]
After changes made to how the usage table is defragged by the CDM,
it was determined that there is no use in selecting more than a single
entry from the usage table to evict. The only failure that can occur
when evicting an entry is if the last entry is in use, in that case,
evicting other entries will still result in a failure.
This change cleans up the LRU algorithm and test cases to reflect
the new functionality.
Bug: 155230578
Test: Linux unit tests
Change-Id: I817c039670d9f72c0e4f6c3fdac45c98ed5b6b21
2020-07-14 18:37:11 -07:00
Rahul Frias
347917e505
Correct ordering of test expectations
...
[ Merge of http://go/wvgerrit/102804 ]
This addresses post-merge review comments.
Bug: 150393659
Test: WV unit/integration tests
Change-Id: I221ed1c82b20bd0c2b0b824a2d52a2dd918fa459
2020-07-14 02:24:41 -07:00
Alex Dale
1d136b4f94
Merge "Re-enabling parallel license tests for L1 and ModMock."
2020-07-10 00:17:53 +00:00
Alex Dale
cf6cf5f4e8
Re-enabling parallel license tests for L1 and ModMock.
...
[ Merge of http://go/wvgerrit/102108 ]
Several tests that make parallel license requests were disabled due
to a flaky server failure unrelated to CDM code. Most of these tests
are now re-enabled to ensure the multi-threaded license requests is
functional on V16.
These tests remains disabled for L3 due to continued flakiness.
Added a lock around the initialization of the SSL library to prevent
issues with license requests getting garbled.
Bug: 137619348
Test: Linux and Android unit tests
Change-Id: Idffaa6039b2bde12613bb5033af32d1af6704c76
2020-07-08 16:44:00 -07:00
John Bruce
5a27d24742
Merge "Memory Leak in CertificateProvisioningTest"
2020-07-08 19:56:04 +00:00
John W. Bruce
5f232c5436
Memory Leak in CertificateProvisioningTest
...
(This is a merge of http://go/wvgerrit/102084 .)
No one was claiming ownership of the metrics object in
CertificateProvisioningTest, resulting in a leak. This patch makes the
test hold onto ownership.
Bug: 159486086
Test: CE CDM Unit Tests
Test: Android Unit Tests
Change-Id: I84710782b7a60d6bd3a7eda981de4f0af877fc39
2020-07-07 15:07:16 -07:00
Robert Shih
1cd67ca8f9
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: f240709ef2 am: 918dba59f1 am: ba2e3e41f8
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Icca161e90011977563be7d02296b005e5edb0828
2020-07-07 00:36:28 +00:00
Robert Shih
83c6e2e9bc
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb am: 231770e40c am: c171cefa91
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Ibabb0adea542229c90afcbfc59dca0a37ad89588
2020-07-07 00:35:51 +00:00
Robert Shih
2ac3a6b623
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb am: 2009155f7e am: deb11efb5f
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: I6df47d941ecea3ad046c90f19bd355767d0e15ab
2020-07-07 00:34:36 +00:00
Robert Shih
ba2e3e41f8
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: f240709ef2 am: 918dba59f1
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Ibb4706058e19d68706ba0fa011554ba2330e8c0e
2020-07-07 00:20:41 +00:00
Robert Shih
c171cefa91
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb am: 231770e40c
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: I72e461c36bf48714648e04b256885d5948a724dc
2020-07-07 00:20:18 +00:00
Robert Shih
deb11efb5f
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb am: 2009155f7e
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: I841154f06f33f926d56dde9e25bb3bf45efad7b6
2020-07-07 00:19:54 +00:00
Robert Shih
231770e40c
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: I94c1340571cffbe834c8ea2576008665d61c08c0
2020-07-06 23:58:19 +00:00
Robert Shih
918dba59f1
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: f240709ef2
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Ic83b03effbc60ba595e83b6348d4abd451b269eb
2020-07-06 23:57:56 +00:00
Robert Shih
2009155f7e
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca am: 0db8b90cdb
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: I10bc5ae45c8f20f0a9b2349c6fa01b8aae0664ae
2020-07-06 23:57:44 +00:00
Robert Shih
f240709ef2
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Ifb1122df9b6098e0d7ce51a7522249693fe40fee
2020-07-06 23:40:18 +00:00
Robert Shih
0db8b90cdb
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED am: da09f4abca
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/12036417
Change-Id: Icc0b7bb24c4058de5786fc7e28a50bbc2aee5f4b
2020-07-06 23:39:43 +00:00
Robert Shih
da09f4abca
GetDecryptHashSupport: recognize OEMCrypto_ERROR_NOT_IMPLEMENTED
...
[ Merge of http://go/wvgerrit/102383 ]
Bug: 153297118
Bug: 160182693
Test: MediaDrmTest#testDecryptHashError
Change-Id: I107668cdd1ab0acda717f184496e569a4f9a8653
2020-06-29 22:19:26 +00:00
Bob Badour
37b8b51a22
Merge "Add METADATA to widevine: widevine=BY_EXCEPTION_ONLY"
2020-06-27 06:54:13 +00:00
Bob Badour
64e02683a0
Add METADATA to widevine: widevine=BY_EXCEPTION_ONLY
...
Bug: 68860345
Bug: 69058154
Bug: 151953481
Test: no code changes
Exempt-From-Owner-Approval: janitorial work
Change-Id: I12e27639e18505ebd3c817fc3c6587203024bc71
2020-06-26 12:29:20 -07:00
John Bruce
38a8b631be
Merge "Rework Device File Matchers to Avoid Buffer Overflow"
2020-06-25 21:58:58 +00:00
Alex Dale
62b95b4b54
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1 am: b535120ccd am: 65211cab08
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I71c97cc16dcb10a4c90551f625663714e000e886
2020-06-25 20:27:59 +00:00
Alex Dale
03dfb757c4
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 62462f4ec5 am: 8453477daa am: a5e30b73a3
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I382d70815918a739dd5e7f4de14d44c007baadbf
2020-06-25 20:27:50 +00:00
Alex Dale
88fba96dfb
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1 am: 52901002a1 am: 33c3fd9085
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I224f1e42089548e2e78318df4c67e650253fde6d
2020-06-25 20:27:27 +00:00
Alex Dale
65211cab08
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1 am: b535120ccd
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I5b906c594c1c3292bdc5aaa20c2071ae56d912a6
2020-06-25 20:03:15 +00:00
Alex Dale
a5e30b73a3
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 62462f4ec5 am: 8453477daa
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: Ic6505cf29342b745a3dfed0047d1e8503b6c6f38
2020-06-25 20:03:02 +00:00
Alex Dale
33c3fd9085
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1 am: 52901002a1
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I4091326a55cc8cb514971b2ea595b10e12f38294
2020-06-25 20:02:55 +00:00
Alex Dale
8453477daa
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 62462f4ec5
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I46c0b2e57cedfdac19b622c9191e604c05301eeb
2020-06-25 19:50:16 +00:00
Alex Dale
b535120ccd
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I2bf4c438575cb22bd350bb9c364a2543f04423d3
2020-06-25 19:50:04 +00:00
Alex Dale
52901002a1
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2 am: 3adda0dfe1
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I2c3237138f100970ab62dddb377122a980a211f1
2020-06-25 19:50:03 +00:00
Alex Dale
3adda0dfe1
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: Ia63d263ae89bc14836704f1dc2d95f5b06590754
2020-06-25 19:39:21 +00:00
Alex Dale
62462f4ec5
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev am: c628c5aca2
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11925460
Change-Id: I9d6813c4a20dbc679c1526f73dc1be5593d2fee5
2020-06-25 19:38:17 +00:00
Alex Dale
c628c5aca2
Merge "Test CDM sessions prevent multiple usage entries." into rvc-dev
2020-06-25 19:25:18 +00:00
John W. Bruce
804c0d470c
Rework Device File Matchers to Avoid Buffer Overflow
...
(This is a merge of http://go/wvgerrit/102104 )
The device file unit tests use some custom matchers that were written
back when we didn't have C++11. Because gMock requires std::tuple to
pass a pointer AND a length to a matcher, these matchers had to estimate
the length of the file. This technically meant they were causing a
benign buffer overrun sometimes.
Since we have C++11 now, we can fix this by using a matcher over a
std::pair of the pointer and length. I also took the opportunity to
refactor the matchers a little. The old matchers had many very specific
overloads and also collided with the names of some standard gMock
matchers. Now there are just two more-general matchers with unique
names.
Test: CE CDM Unit Tests
Test: Android Unit Tests
Bug: 159463905
Change-Id: I758b140226bfe2bae6962ee5c64fd6af186b5819
2020-06-24 14:27:09 -07:00
Alex Dale
6a247ab924
INSUFFICIENT_RESOURCE errors are mapped consistently.
...
[ Merge of http://go/wvgerrit/102109 ]
The CDM was using unique CDM error codes for the various cases
where OEMCrypto would return INSUFFICIENT_RESOURCE. However, these
error codes were being incorrectly mapped at the Android level,
resulting in incorrect errors in the MediaDRM layer.
At no point does the CDM handle different INSUFFICIENT_RESOURCE_x
within the same case, as such the use of unique codes are limited.
This CL removes the unique codes, and unifies them under the same
CDM error code.
This CL also extends SelectKey to handle error codes returned by
LoadEntitledContentKeys.
Bug: 154682842
Test: Unit tests
Change-Id: I319fabf6cac60b0dc19ea891609689daeeaeb435
2020-06-22 16:27:25 -07:00
Rahul Frias
4938628f46
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e am: 999dabbc6e am: cd7be52932
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: If6523b3be0072c73a82737f5d1aadf3526ea54aa
2020-06-22 18:47:27 +00:00
Rahul Frias
f43e898921
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e am: abad87b79f am: a93347ea6d
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: Icbaf28005ac3c386ac51aee0e87e4c76a308c5b2
2020-06-22 18:46:52 +00:00
Rahul Frias
992d54d912
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: dffadd204c am: 61f64a00c6 am: 1b6f50a467
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: Iba9cfe403e14249910d5ba19a3ec4c238d7c09cd
2020-06-22 18:46:13 +00:00
Rahul Frias
cd7be52932
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e am: 999dabbc6e
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: Ibb778d3fe1da64df8bfb048081104ed85f8b4a2c
2020-06-22 18:35:36 +00:00
Rahul Frias
a93347ea6d
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e am: abad87b79f
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: I0bc4b561b9edab32a89fe59d71f9b97bc7a9dbf8
2020-06-22 18:35:20 +00:00
Rahul Frias
1b6f50a467
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: dffadd204c am: 61f64a00c6
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: I1830edae406e16b0c2c47290e660ae5cb3537f04
2020-06-22 18:34:59 +00:00
Rahul Frias
999dabbc6e
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: I6d182f166720bf8a925f6182d03f8ca1150f7ec2
2020-06-22 18:21:54 +00:00
Rahul Frias
abad87b79f
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: 652258d70e
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: I11dff2a7fc64d467cc7e31206b2b3c521c397006
2020-06-22 18:21:38 +00:00
Rahul Frias
61f64a00c6
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138 am: dffadd204c
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: I86a70f3bd0c351932270bfd985fcce6461a1bdbe
2020-06-22 18:21:18 +00:00
Rahul Frias
dffadd204c
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: Ia4c431617789fbbb5f973f076b29408df2b2a2bc
2020-06-22 18:14:28 +00:00
Rahul Frias
652258d70e
Merge "Handle SPOID calculation for L3" into rvc-dev am: 25d1646138
...
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/11736137
Change-Id: Ifb2d04b609a00905c5c42ee629e83674822b64cb
2020-06-22 18:14:27 +00:00
Rahul Frias
25d1646138
Merge "Handle SPOID calculation for L3" into rvc-dev
2020-06-22 18:04:18 +00:00