Merge "Reprovision on error 10085"
This commit is contained in:
@@ -65,6 +65,10 @@ constexpr int kMaxTerminateCountDown = 5;
|
||||
|
||||
const std::string kStringNotAvailable = "NA";
|
||||
|
||||
// TODO(b/174412779): Remove when b/170704368 is fixed.
|
||||
// This is a Qualcomm specific error code
|
||||
const int kRsaSsaPssSignatureLengthError = 10085;
|
||||
|
||||
// Constants relating to OEMCrypto resource rating tiers. These tables are
|
||||
// ordered by resource rating tier from lowest to highest. These should be
|
||||
// updated whenever the supported range of resource rating tiers changes.
|
||||
@@ -926,6 +930,14 @@ CdmResponseType CryptoSession::PrepareAndSignLicenseRequest(
|
||||
});
|
||||
|
||||
if (OEMCrypto_ERROR_SHORT_BUFFER != sts) {
|
||||
// TODO(b/174412779): Remove when b/170704368 is fixed.
|
||||
// Temporary workaround. If this error is returned the only way to
|
||||
// recover is for the app to reprovision.
|
||||
if (static_cast<int>(sts) == kRsaSsaPssSignatureLengthError) {
|
||||
LOGE("OEMCrypto PrepareAndSignLicenseRequest result = %d",
|
||||
static_cast<int>(sts));
|
||||
return NEED_PROVISIONING;
|
||||
}
|
||||
return MapOEMCryptoResult(sts, GENERATE_SIGNATURE_ERROR,
|
||||
"PrepareAndSignLicenseRequest");
|
||||
}
|
||||
@@ -953,6 +965,14 @@ CdmResponseType CryptoSession::PrepareAndSignLicenseRequest(
|
||||
core_message->resize(core_message_length);
|
||||
return NO_ERROR;
|
||||
}
|
||||
// TODO(b/174412779): Remove when b/170704368 is fixed.
|
||||
// Temporary workaround. If this error is returned the only way to
|
||||
// recover is for the app to reprovision.
|
||||
if (static_cast<int>(sts) == kRsaSsaPssSignatureLengthError) {
|
||||
LOGE("OEMCrypto PrepareAndSignLicenseRequest result = %d",
|
||||
static_cast<int>(sts));
|
||||
return NEED_PROVISIONING;
|
||||
}
|
||||
return MapOEMCryptoResult(sts, GENERATE_SIGNATURE_ERROR,
|
||||
"PrepareAndSignLicenseRequest");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user