File util, generic crypto, and key query

This CL merges several CLs from the widevine repo:

http://go/wvgerrit/18012 Add support for querying allowed usage for key.
http://go/wvgerrit/17971 Add per-origin storage.
http://go/wvgerrit/18152 Add OEMCrypto's generic crypto operations to CDM.
http://go/wvgerrit/17911 QueryKeyControlInfo => QueryOemCryptoSessionId

Note: numbering in wv_cdm_types.h was added in this CL and will be
back ported to wvgerrit in a future CL.

Change-Id: Idb9e9a67e94f62f25dc16c5307f75a08b3430b64
This commit is contained in:
Fred Gylys-Colwell
2016-09-14 12:44:09 -07:00
parent 24124ea6e3
commit eb3f8b786a
56 changed files with 4632 additions and 2083 deletions

View File

@@ -363,6 +363,38 @@ static android::status_t mapCdmResponseType(wvcdm::CdmResponseType res) {
return android::ERROR_DRM_CANNOT_HANDLE;
case wvcdm::INSUFFICIENT_OUTPUT_PROTECTION:
return android::ERROR_DRM_INSUFFICIENT_OUTPUT_PROTECTION;
case wvcdm::SESSION_NOT_FOUND_13:
return kSessionNotFound13;
case wvcdm::SESSION_NOT_FOUND_14:
return kSessionNotFound14;
case wvcdm::SESSION_NOT_FOUND_15:
return kSessionNotFound15;
case wvcdm::SESSION_NOT_FOUND_16:
return kSessionNotFound16;
case wvcdm::KEY_NOT_FOUND_3:
return kKeyNotFound3;
case wvcdm::KEY_NOT_FOUND_4:
return kKeyNotFound4;
case wvcdm::KEY_NOT_FOUND_5:
return kKeyNotFound5;
case wvcdm::KEY_NOT_FOUND_6:
return kKeyNotFound6;
case wvcdm::KEY_ERROR_1:
return kKeyError1;
case wvcdm::KEY_ERROR_2:
return kKeyError2;
case wvcdm::KEY_ERROR_3:
return kKeyError3;
case wvcdm::KEY_ERROR_4:
return kKeyError4;
case wvcdm::INVALID_PARAMETERS_ENG_13:
return kInvalidParametersEng13;
case wvcdm::INVALID_PARAMETERS_ENG_14:
return kInvalidParametersEng14;
case wvcdm::INVALID_PARAMETERS_ENG_15:
return kInvalidParametersEng15;
case wvcdm::INVALID_PARAMETERS_ENG_16:
return kInvalidParametersEng16;
case wvcdm::UNUSED_1:
case wvcdm::UNUSED_2:
case wvcdm::UNUSED_3: