Merges to android Pi release (part 2)
These are a set of CLs merged from the wv cdm repo to the android repo. * Update service certificate. Author: Gene Morgan <gmorgan@google.com> [ Merge of http://go/wvgerrit/28065 ] The updated service certificate fixes a number of failing tests. There are still some that fail, apparently due to mismatches with key set IDs and usage tables. Also updated QA server URL to point to QA proxy (although neither can be used by this client). Also fixed segfault in CdmTest.ListUsageRecords. * Add CDM APIs for Handling Service Certificates. Author: Gene Morgan <gmorgan@google.com> [ Merge of http://go/wvgerrit/28064 ] The responsibility for managing Service Certificates has been moved out of the CDM. Instead, provide CDM and CdmEngine methods to generate a service certificate request message, and handle a service certificate response. The API client can use these calls if it needs to get the service certificate from the License Server. These functions assume the request and response are base64 (web-safe) encoded (see b/37481392). Not all servers are operating this way yet. Any adaptations for non-compliant servers is handled outside the CDM. See test WvCdmEnginePreProvTest::ServiceCertificateRequestResponse in cdm_engine_test.cpp for an example of this. These changes also eliminate the stored init_data and deferred license type which were used to perform a service certificate request during a license request. * Fix and rename ClosesSessionWithoutReturningError test. Author: Edwin Wong <edwinwong@google.com> [ Merge of http://go/wvgerrit/27880 ] ClosesSessionWithoutReturningError should not check for Status::OK since it is expecting an error code back. The test is renamed to ClosesSessionWithError. Test: libwvdrmdrmplugin_hidl_test BUG: 62205215 * Get rid of default service certificate. Author: Gene Morgan <gmorgan@google.com> [ Merge of http://go/wvgerrit/27981 ] Instead, we need at least two service certs - one for the QA/Test servers, and one for UAT (and prod?) There are still some issues around the signature verififcation of the service cert, and in license_unittest.cpp, the use of the default service cert has been commented out. I don't know why this test needs a service cert. If it really does, then the same mechanism that is used elsewhere for selecting a specific server type will be needed here. BUG: 71650075 Test: Not currently passing. Will be addressed in a subsequent commit in the chain. Change-Id: Ieab815fb202c809ad5714cd0364c4bdfa068f77d
This commit is contained in:
@@ -322,18 +322,12 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
break;
|
||||
case USAGE_INFO_NOT_FOUND: *os << "USAGE_INFO_NOT_FOUND";
|
||||
break;
|
||||
case LICENSE_RENEWAL_SERVICE_CERTIFICATE_GENERATION_ERROR:
|
||||
*os << "LICENSE_RENEWAL_SERVICE_CERTIFICATE_GENERATION_ERROR";
|
||||
break;
|
||||
case EMPTY_PROVISIONING_CERTIFICATE_2:
|
||||
*os << "EMPTY_PROVISIONING_CERTIFICATE_2";
|
||||
break;
|
||||
case PARSE_SERVICE_CERTIFICATE_ERROR:
|
||||
*os << "PARSE_SERVICE_CERTIFICATE_ERROR";
|
||||
break;
|
||||
case SERVICE_CERTIFICATE_TYPE_ERROR:
|
||||
*os << "SERVICE_CERTIFICATE_TYPE_ERROR";
|
||||
break;
|
||||
case CLIENT_ID_GENERATE_RANDOM_ERROR:
|
||||
*os << "CLIENT_ID_GENERATE_RANDOM_ERROR";
|
||||
break;
|
||||
@@ -358,9 +352,6 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
break;
|
||||
case INVALID_PARAMETERS_LIC_7: *os << "INVALID_PARAMETERS_LIC_7";
|
||||
break;
|
||||
case LICENSE_REQUEST_SERVICE_CERTIFICATE_GENERATION_ERROR:
|
||||
*os << "LICENSE_REQUEST_SERVICE_CERTIFICATE_GENERATION_ERROR";
|
||||
break;
|
||||
case CENC_INIT_DATA_UNAVAILABLE: *os << "CENC_INIT_DATA_UNAVAILABLE";
|
||||
break;
|
||||
case PREPARE_CENC_CONTENT_ID_FAILED:
|
||||
@@ -456,6 +447,8 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_18: *os << "INVALID_PARAMETERS_ENG_18";
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_19: *os << "INVALID_PARAMETERS_ENG_19";
|
||||
break;
|
||||
case CERT_PROVISIONING_CLIENT_TOKEN_ERROR_1:
|
||||
*os << "CERT_PROVISIONING_CLIENT_TOKEN_ERROR_1";
|
||||
break;
|
||||
@@ -499,8 +492,6 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
case LOAD_USAGE_ENTRY_UNKNOWN_ERROR:
|
||||
*os << "LOAD_USAGE_ENTRY_UNKNOWN_ERROR";
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_19: *os << "INVALID_PARAMETERS_ENG_19";
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_20: *os << "INVALID_PARAMETERS_ENG_20";
|
||||
break;
|
||||
case UPDATE_USAGE_ENTRY_UNKNOWN_ERROR:
|
||||
@@ -519,8 +510,9 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
case COPY_OLD_USAGE_ENTRY_UNKNOWN_ERROR:
|
||||
*os << "COPY_OLD_USAGE_ENTRY_UNKNOWN_ERROR";
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_23:
|
||||
*os << "INVALID_PARAMETERS_ENG_23";
|
||||
case INVALID_PARAMETERS_ENG_23: *os << "INVALID_PARAMETERS_ENG_23";
|
||||
break;
|
||||
case INVALID_PARAMETERS_ENG_24: *os << "INVALID_PARAMETERS_ENG_24";
|
||||
break;
|
||||
case USAGE_INFORMATION_SUPPORT_FAILED:
|
||||
*os << "USAGE_INFORMATION_SUPPORT_FAILED";
|
||||
@@ -584,7 +576,22 @@ void PrintTo(const enum CdmResponseType& value, ::std::ostream* os) {
|
||||
break;
|
||||
case DELETE_USAGE_ERROR_3: *os << "DELETE_USAGE_ERROR_3";
|
||||
break;
|
||||
|
||||
case PRIVACY_MODE_ERROR_1: *os << "PRIVACY_MODE_ERROR_1";
|
||||
break;
|
||||
case PRIVACY_MODE_ERROR_2: *os << "PRIVACY_MODE_ERROR_2";
|
||||
break;
|
||||
case PRIVACY_MODE_ERROR_3: *os << "PRIVACY_MODE_ERROR_3";
|
||||
break;
|
||||
case EMPTY_RESPONSE_ERROR_1: *os << "EMPTY_RESPONSE_ERROR_1";
|
||||
break;
|
||||
case PARSE_RESPONSE_ERROR_1: *os << "PARSE_RESPONSE_ERROR_1";
|
||||
break;
|
||||
case PARSE_RESPONSE_ERROR_2: *os << "PARSE_RESPONSE_ERROR_2";
|
||||
break;
|
||||
case PARSE_RESPONSE_ERROR_3: *os << "PARSE_RESPONSE_ERROR_3";
|
||||
break;
|
||||
case PARSE_RESPONSE_ERROR_4: *os << "PARSE_RESPONSE_ERROR_4";
|
||||
break;
|
||||
default:
|
||||
*os << "Unknown CdmResponseType";
|
||||
break;
|
||||
@@ -599,8 +606,6 @@ void PrintTo(const enum CdmLicenseType& value, ::std::ostream* os) {
|
||||
break;
|
||||
case kLicenseTypeRelease: *os << "kLicenseTypeRelease";
|
||||
break;
|
||||
case kLicenseTypeDeferred: *os << "kLicenseTypeDeferred";
|
||||
break;
|
||||
default:
|
||||
*os << "Unknown CdmLicenseType";
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user