Assume Keybox provisioning type if OTA Keybox is supported. am: 581aa1702b
Original change: https://googleplex-android-review.googlesource.com/c/platform/vendor/widevine/+/16058120 Change-Id: I03925f8ffec8ebb690d49db04d637e2f8f2fb15f
This commit is contained in:
@@ -301,6 +301,11 @@ CdmResponseType CryptoSession::GetProvisioningMethod(
|
||||
break;
|
||||
case OEMCrypto_ProvisioningError:
|
||||
default:
|
||||
if (static_cast<int>(method) == 0 && needs_keybox_provisioning_) {
|
||||
LOGW("Overriding provisioning method, assuming keybox");
|
||||
type = kClientTokenKeybox;
|
||||
break;
|
||||
}
|
||||
LOGE("OEMCrypto_GetProvisioningMethod failed: method = %d",
|
||||
static_cast<int>(method));
|
||||
metrics_->oemcrypto_provisioning_method_.SetError(method);
|
||||
|
||||
@@ -162,6 +162,8 @@ CdmResponseType OtaKeyboxProvisioner::GetProvisioningRequest(
|
||||
static_cast<int>(result));
|
||||
client_id->Clear();
|
||||
}
|
||||
LOGI("OTA request generated");
|
||||
LOGV("ota_request_data = %s", b2a_hex(ota_request_data).c_str());
|
||||
OtaRequest* ota_request = prov_request.mutable_android_ota_keybox_request();
|
||||
ota_request->set_ota_request(ota_request_data);
|
||||
|
||||
@@ -255,8 +257,8 @@ CdmResponseType OtaKeyboxProvisioner::HandleProvisioningResponse(
|
||||
const CdmResponseType result = crypto_session_->LoadOtaProvisioning(
|
||||
kProductionKeybox, ota_response_data);
|
||||
if (result == NO_ERROR) {
|
||||
LOGV("OTA response successfully processed: ota_response_data = %s",
|
||||
b2a_hex(ota_response_data).c_str());
|
||||
LOGI("OTA response successfully processed");
|
||||
LOGV("ota_response_data = %s", b2a_hex(ota_response_data).c_str());
|
||||
fallback_policy_->MarkProvisioned();
|
||||
response_received_ = true;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user