Commit Graph

2207 Commits

Author SHA1 Message Date
Rahul Frias
ce62e1d7e7 Correct error returned when license is for the future
[ Merge of http://go/wvgerrit/25721 ]

Return CryptoException with errorCode ERROR_NO_KEY when an attempt is made
to make use of a license whose start time is in the future.

Test: Verified by WidevineDashPolicyTests#testL1LicenseStart2030

b/31914841

Change-Id: I2a157c227550a2391b6536365f34f1dfec3dea0c
2017-04-12 13:20:44 -07:00
John Bruce
d7d5715f21 Merge "Always Report OEMCrypto_ERROR_KEY_EXPIRED as NEED_KEY" into oc-dev
am: 1b0d67f368

Change-Id: Ib99df99fbb441f67a4cab52c45095287e05cd532
2017-04-12 18:08:50 +00:00
John Bruce
1b0d67f368 Merge "Always Report OEMCrypto_ERROR_KEY_EXPIRED as NEED_KEY" into oc-dev 2017-04-12 17:48:58 +00:00
Fred Gylys-Colwell
4c5ae08575 Merge "Disable MinVersionNumber13 Test *DO NOT MERGE*" into oc-dev
am: cc28abea0b

Change-Id: I6d284dc2a9dde9b6e4f5b578aa56423d07431a4f
2017-04-12 01:41:53 +00:00
TreeHugger Robot
cc28abea0b Merge "Disable MinVersionNumber13 Test *DO NOT MERGE*" into oc-dev 2017-04-12 01:37:18 +00:00
Fred Gylys-Colwell
565d911792 Merge "Address merge comments" into oc-dev
am: dbaacf9232

Change-Id: Ia8f793fa61b98aa8391468808fa5b75b5ff7c1c1
2017-04-12 00:21:58 +00:00
TreeHugger Robot
dbaacf9232 Merge "Address merge comments" into oc-dev 2017-04-11 23:57:19 +00:00
Rahul Frias
b474ba042e Allow OfflineLicenseRenewal test to be repeatedly invoked
[ Merge of http://go/wvgerrit/25720 ]

Test: Repeatedly invoke WvCdmRequestLicenseTest.OfflineLicenseRenewal

b/28915200

Change-Id: I5be6be02d09ced1a7ba8bac2c8706f199d063db8
2017-04-11 16:40:16 -07:00
Jeff Tinker
70d8036881 Merge "Report binderized vendor service name" into oc-dev
am: eef94c002f

Change-Id: I7b0a17b2cb1328df14cf771ecd01908eb8e3a427
2017-04-11 21:20:11 +00:00
Jeff Tinker
c95756d367 Merge "Add checks for invalid parameters" into oc-dev
am: 9a69579330

Change-Id: Ic1c9fcb851e7c8ce7027ce620c9ac053f24a81b1
2017-04-11 21:20:01 +00:00
TreeHugger Robot
eef94c002f Merge "Report binderized vendor service name" into oc-dev 2017-04-11 21:02:21 +00:00
TreeHugger Robot
9a69579330 Merge "Add checks for invalid parameters" into oc-dev 2017-04-11 21:01:25 +00:00
Fred Gylys-Colwell
f9d08a30a4 Disable MinVersionNumber13 Test *DO NOT MERGE*
Merge from Widevine repo of http://go/wvgerrit/25662

OEMCrypto v13 is required for OC MR1, and is not needed for OC.  This
CL disables the unit tests MinVersionNumber13 for OC.  This CL should
not be merged to master.

b/36866361

Test: all unit tests pass on sailfish.

Change-Id: I04d7b468ac9479257c25519acb6ac13204acabd5
2017-04-10 18:04:58 -07:00
John W. Bruce
7f27e5a266 Always Report OEMCrypto_ERROR_KEY_EXPIRED as NEED_KEY
(This is a merge of wvgerrit/25422)

OEMCrypto_ERROR_KEY_EXPIRED was not always being reported to the higher
layers as a NEED_KEY error, which could cause inconsistent error
handling.

Bug: 28294273
Test: Unit tests
Change-Id: Idf5642ea0f0ba915bc1f53025a1f14691d142aed
2017-04-10 16:49:44 -07:00
Jeff Tinker
bd87217173 Add checks for invalid parameters
Part of VTS test suite validation for
the binderized Widevine service

Test: Drm VTS test

bug:32815560
Change-Id: I0913c0e72487b5fdbf579b9ea3409c13264888fd
2017-04-10 10:06:26 -07:00
Jeff Tinker
dff3a13d6c Report binderized vendor service name
Update the vts vendor module to
return the service name instead of the
default passthrough service name to
support binderized mode.

Part of VTS test suite validation for
the binderized Widevine service

Test: drm vts test

Change-Id: I04c9fa6f66af43db6c405ecc8d714b712d87a45a
related-to-bug:34178477
2017-04-07 18:04:36 -07:00
Steven Moreland
2ab1579826 Fix transitive include.
am: 20f8368f9c

Change-Id: I649ec99177d7b21ce189bc5d132b3fbdb759cd5a
2017-04-07 03:34:08 +00:00
Steven Moreland
20f8368f9c Fix transitive include.
Test: checkbuild
Change-Id: Iea1de496007556d2efac76092ef87ec2ec78b9bf
2017-04-06 17:39:39 -07:00
Jeff Tinker
26b8cac44e Merge "Add additional VTS drm tests for widevine" into oc-dev
am: 70d15e286f

Change-Id: Id5c0ec26a22ca570932a571243bb552fe24fd898
2017-04-06 18:30:16 +00:00
TreeHugger Robot
70d15e286f Merge "Add additional VTS drm tests for widevine" into oc-dev 2017-04-06 18:20:59 +00:00
Scott Randolph
6a7f774237 Use explicit .c_str() for hidl_string
am: cfcdceaa4f

Change-Id: Ief21c8e31a1bbd3e389f70a0c9cfe0b837aece35
2017-04-06 18:14:18 +00:00
Scott Randolph
cfcdceaa4f Use explicit .c_str() for hidl_string
hidl_string no longer will provide an implicit cast to const char* as it
interfers with other expected behaviors of the class.  It now emulated
std::string in requiring a call to .c_str() to get the same behavior.

Bug:  36532780
Test:  Build the tree
Change-Id: I2ce4354619a99d7c5ae8b39762d5506891ccd1ed
2017-04-06 10:58:56 -07:00
Edwin Wong
c719a091fd Merge "Remove dependencies from frameworks C++ containers." into oc-dev
am: 72f89a3b7f

Change-Id: I3904d885c7e8cb45adb5ec3b57921533788871d1
2017-04-06 04:21:57 +00:00
Edwin Wong
72f89a3b7f Merge "Remove dependencies from frameworks C++ containers." into oc-dev 2017-04-06 04:18:27 +00:00
Jeff Tinker
8e3e85f4ce Merge "Fix compiler warnings" into oc-dev
am: 8e041f9fd3

Change-Id: I58aaf075db987532c210f4d46d21ef84b20b7273
2017-04-06 00:31:19 +00:00
TreeHugger Robot
8e041f9fd3 Merge "Fix compiler warnings" into oc-dev 2017-04-06 00:19:38 +00:00
Edwin Wong
d9e7070de7 Remove dependencies from frameworks C++ containers.
Replace AString, KeyedVector, List, String8 and Vector
with stl containers. Remove corresponding frameworks
libraries.

Test: Play Movies & TV (streaming and pinning)
Test: Netflix
Test: unit tests

bug: 34677927
Change-Id: I125f45054987d69bbca59c1ffdcbe8add38c3c13
2017-04-05 22:46:04 +00:00
Jeff Tinker
cfe80bc234 Add additional VTS drm tests for widevine
Also fixes a few cases where invalid inputs were
not checked.

bug: 34178477
Change-Id: I15c1e5f96e0843f484d8d3e29f548eac30d9dd80
2017-04-04 22:38:55 -07:00
Ryan Campbell
f5da7b9786 Merge "Build libvtswidevine to relative directory." into oc-dev
am: 82a0ed59fe

Change-Id: Ie4df8154a9cf9f0f652c5302e9784cc7fd740f30
2017-04-04 23:12:22 +00:00
TreeHugger Robot
82a0ed59fe Merge "Build libvtswidevine to relative directory." into oc-dev 2017-04-04 23:05:29 +00:00
Ryan Campbell
cdaeb0716c Build libvtswidevine to relative directory.
Build libvtswidevine module relative to the directory
drm-vts-test-libs.

Test: make vts; libvtswidevine.so is in correct place.
Bug: 36889176
Bug: 36817233
Change-Id: Iadb5bd6e71a1a7c99a69feff2ecb7bded90af24d
2017-04-04 13:26:01 -07:00
Fred Gylys-Colwell
d0a3568338 Address merge comments
Merge from Widevine repo of http://go/wvgerrit/24723

Several review comments were uncovered in the merge from oc-dev to
master. This CL addresses them.  This is just style changes in test
code.

http://go/wvgerrit/24318
http://go/wvgerrit/24301
http://go/wvgerrit/24316

Test: ran unit tests.

b/36451451

Change-Id: I257f8bf9b4fb5797e3da69578b48cd040cf61bfb
2017-04-04 12:31:59 -07:00
John W. Bruce
d4598279aa Turn on 64-bit Executables on Supported Platforms
am: b99a4c736f

Change-Id: I83842ffe27dc049dd32a4b4351b7ae21a14968e7
2017-04-02 05:29:34 +00:00
John W. Bruce
b99a4c736f Turn on 64-bit Executables on Supported Platforms
This commit changes the unit tests and HAL Service to run as 64-bit on
devices that have enabled 64-bit DRM Plugins.

Bug: 36076017
Test: Turned on the flag for a device and used the file command to
      verify that all binaries were built as 64-bit.
Test: Turned the flag back off and verified that all binaries were built
      as 32-bit. This should affect no current devices.
Change-Id: Ieb7218f15b9359f2038a6f60b8c994b16d2b5b53
2017-04-01 19:05:30 -07:00
Jeff Tinker
749ce0efcf Fix compiler warnings
Formats for size_t were incorrect

Change-Id: Ibdfdd734b9fe9e74e014fe10152ad8b9baf2d6f2
2017-03-31 16:19:41 -07:00
Jeff Tinker
85619457ac Merge "Add checks for invalid parameters" into oc-dev
am: b3ea54b6dc

Change-Id: I6132060ba0e1dd7d77834df95896861594ea3232
2017-03-31 05:33:24 +00:00
Jeff Tinker
c11698cd48 Merge "DRM VTS Vendor module for widevine" into oc-dev
am: 2b49e7c4ec

Change-Id: I90d94e3a306a9c6da1e15b38798fd94d03d4be76
2017-03-31 05:33:22 +00:00
TreeHugger Robot
b3ea54b6dc Merge "Add checks for invalid parameters" into oc-dev 2017-03-31 05:29:54 +00:00
TreeHugger Robot
2b49e7c4ec Merge "DRM VTS Vendor module for widevine" into oc-dev 2017-03-31 05:29:54 +00:00
John Bruce
fb20fb9c69 Merge "Fix & Improve Test-Building and -Running Scripts" into oc-dev
am: 0fba3719e7

Change-Id: I47dc5a5f08f133a18516e5cdf09ad361ef9783b5
2017-03-31 01:06:14 +00:00
John Bruce
0fba3719e7 Merge "Fix & Improve Test-Building and -Running Scripts" into oc-dev 2017-03-31 00:56:55 +00:00
Jeff Tinker
76f43abcbe Add checks for invalid parameters
Part of VTS test suite validation

related-to-bug: 32815560

Test: drm hal vts test
Change-Id: I52be29cd46f535482a761f98acf6ff28870c061c
2017-03-30 16:15:01 -07:00
Jeff Tinker
01cb3cb787 DRM VTS Vendor module for widevine
This module is used with the drm VTS tests as part of HIDL/HAL
testing.  For background reference:
hardware/interfaces/drm/1.0/vts/doc/Drm_Vendor_Modules_v1.pdf

Change-Id: I38eb13696343e08fa2a1758219350d25698bfb7d
related-to-bug: 32815560
2017-03-30 23:07:11 +00:00
John W. Bruce
f2463075ac Fix & Improve Test-Building and -Running Scripts
(This is a merge of wvgerrit/24922)

This contains several fixes and improvements to the
build_and_run_all_unit_tests.sh and run_all_unit_tests.sh scripts:

* All tests are now identified as vendor binaries and thus are stored in
  the /vendor/bin/ directory instead of /system/bin/. Previously, some
  tests had moved to /vendor/bin/ but the scripts had not been updated,
  causing these tests to fail to run.
* The -j parameter can now be passed to build_and_run_all_unit_tests.sh,
  for those who want to speed up their build by using multiple cores.
* The 64-bit library directories are now added to the library search
  path, in anticipation of devices with 64-bit DRM Plugins.
* Checking for Verity protection is now done in
  build_and_run_all_unit_tests.sh (which is the script that actually
  modifies the file system) instead of just in run_all_unit_tests.sh.
* The library search path is no longer set unnecessarily for
  libwvdrmengine_hidl_test.
* The Treble-only tests and non-Treble-only tests now only run on
  devices that meet their respective criteria.

Bug: 36071236
Test: Ran build_and_run_all_unit_tests.sh
Change-Id: Iea236880c4445858111c801dfa278a528bca0f6c
2017-03-29 19:01:04 -07:00
Edwin Wong
e59918c8b1 Fix testOEMCryptoVersion
am: 957d4a30dd

Change-Id: Ia2f9f78ff0741bcb7c7ecd8c348aff0736004050
2017-03-30 01:27:20 +00:00
Edwin Wong
957d4a30dd Fix testOEMCryptoVersion
Merge from go/wvgerrit/24882:

The result of crypto_session.GetApiVersion is misinterpreted.

Test: ANDROID_BUILD_TOP= -gts/tools/gts-tradefed run gts
 -m GtsMediaTestCases --test com.google.android.media.gts.
 MediaDrmTest#testOemCryptoVersion

Test: ANDROID_BUILD_TOP= -gts/tools/gts-tradefed run gts
 -m GtsMediaTestCases --test com.google.android.media.gts.
 MediaDrmTest

bug: 36728950
Change-Id: I72a05608f778fa81689013d3b231010b71329ea1
2017-03-29 15:49:59 -07:00
Fred Gylys-Colwell
dd8979b247 Merge "Disable new unit tests for old oemcrypto" into oc-dev
am: 92dff24180

Change-Id: I26f0e27ef503199c679548fd08780e3ebf191a4b
2017-03-29 20:31:28 +00:00
Fred Gylys-Colwell
92dff24180 Merge "Disable new unit tests for old oemcrypto" into oc-dev 2017-03-29 20:22:23 +00:00
Edwin Wong
03b51678f5 Widevine HAL must not access mediametrics binder service.
am: 54061a8bb8

Change-Id: I3832883c9c20ae248b4501e12b4586f193f60c71
2017-03-29 06:13:09 +00:00
Edwin Wong
54061a8bb8 Widevine HAL must not access mediametrics binder service.
Widevine HAL is not part of framework/system image and thus it is not
permitted to use Binder. Binder-like mechanisms which are permitted are
HwBinder  or VendorBinder (for communications only with vendor image
components).

Remove references to MediaAnalyticsItems used by ami_adapter.*.

Test: Play Movies & TV (streaming and pinned content)
Test: Netflix
Test: Widevine unit tests

bug: 36576915
Change-Id: I786f206c01d7c5ebfce719f3f51f5f7927f0359e
2017-03-28 14:24:02 -07:00