Update license proto
[ Merge of http://go/wvgerrit/93506 ] This updates the license_protocol.proto to match the one used by the license service. It introduces new fields such as |soft_enforce_rental_duration|. Additional changes address proto field naming changes. Bug: 139372190 Test: WV android unit/integration tests Change-Id: Id0c38b457e9079c0afc6848c355c07f96a19e073
This commit is contained in:
@@ -37,9 +37,6 @@ const std::string kEmptyString;
|
||||
namespace wvcdm {
|
||||
|
||||
// Protobuf generated classes.
|
||||
using video_widevine::ClientIdentification_ClientCapabilities;
|
||||
using video_widevine::ClientIdentification_NameValue;
|
||||
using video_widevine::DrmDeviceCertificate;
|
||||
using video_widevine::EncryptedClientIdentification;
|
||||
using video_widevine::License;
|
||||
using video_widevine::License_KeyContainer;
|
||||
@@ -47,10 +44,9 @@ using video_widevine::LicenseError;
|
||||
using video_widevine::LicenseIdentification;
|
||||
using video_widevine::LicenseRequest;
|
||||
using video_widevine::LicenseRequest_ContentIdentification;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_CencDeprecated;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_ExistingLicense;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_WebmDeprecated;
|
||||
using video_widevine::SignedDrmDeviceCertificate;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_WebmKeyId;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_WidevinePsshData;
|
||||
using video_widevine::SignedMessage;
|
||||
|
||||
namespace {
|
||||
@@ -1046,31 +1042,31 @@ CdmResponseType CdmLicense::PrepareContentId(
|
||||
license_request->mutable_content_id();
|
||||
|
||||
if (init_data.is_cenc() || init_data.is_hls()) {
|
||||
LicenseRequest_ContentIdentification_CencDeprecated* cenc_content_id =
|
||||
content_id->mutable_cenc_id_deprecated();
|
||||
LicenseRequest_ContentIdentification_WidevinePsshData* widevine_pssh_data =
|
||||
content_id->mutable_widevine_pssh_data();
|
||||
|
||||
if (!init_data.IsEmpty()) {
|
||||
cenc_content_id->add_pssh(init_data.data());
|
||||
widevine_pssh_data->add_pssh_data(init_data.data());
|
||||
} else {
|
||||
LOGE("ISO-CENC init data not available");
|
||||
return CENC_INIT_DATA_UNAVAILABLE;
|
||||
}
|
||||
|
||||
if (!SetTypeAndId(license_type, request_id, cenc_content_id)) {
|
||||
if (!SetTypeAndId(license_type, request_id, widevine_pssh_data)) {
|
||||
return PREPARE_CENC_CONTENT_ID_FAILED;
|
||||
}
|
||||
} else if (init_data.is_webm()) {
|
||||
LicenseRequest_ContentIdentification_WebmDeprecated* webm_content_id =
|
||||
content_id->mutable_webm_id_deprecated();
|
||||
LicenseRequest_ContentIdentification_WebmKeyId* webm_key_id =
|
||||
content_id->mutable_webm_key_id();
|
||||
|
||||
if (!init_data.IsEmpty()) {
|
||||
webm_content_id->set_header(init_data.data());
|
||||
webm_key_id->set_header(init_data.data());
|
||||
} else {
|
||||
LOGE("WebM init data not available");
|
||||
return WEBM_INIT_DATA_UNAVAILABLE;
|
||||
}
|
||||
|
||||
if (!SetTypeAndId(license_type, request_id, webm_content_id)) {
|
||||
if (!SetTypeAndId(license_type, request_id, webm_key_id)) {
|
||||
return PREPARE_WEBM_CONTENT_ID_FAILED;
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user