wv hidl: map CdmResponseType to drm@1.4 Status
Bug: 162255728 Test: VtsHalDrmV1_4TargetTest Change-Id: Icc96c17f38218475efc7489348b75c9978f16b01
This commit is contained in:
@@ -302,7 +302,6 @@ Status_V1_2 WVCryptoPlugin::attemptDecrypt(
|
||||
mSessionId.c_str(),
|
||||
hasProtectedData ? "with" : "without",
|
||||
res);
|
||||
bool actionableError = true;
|
||||
switch (res) {
|
||||
case wvcdm::INSUFFICIENT_CRYPTO_RESOURCES:
|
||||
errorDetailMsg->assign(
|
||||
@@ -335,17 +334,10 @@ Status_V1_2 WVCryptoPlugin::attemptDecrypt(
|
||||
"Error decrypting data: key prohibited for security level");
|
||||
break;
|
||||
default:
|
||||
actionableError = false;
|
||||
break;
|
||||
}
|
||||
|
||||
if (actionableError) {
|
||||
// This error is actionable by the app and should be passed up.
|
||||
return mapCdmResponseType_1_2(res);
|
||||
} else {
|
||||
// Swallow the specifics of other errors to obscure decrypt internals.
|
||||
return Status_V1_2::ERROR_DRM_UNKNOWN;
|
||||
}
|
||||
return mapCdmResponseType<Status_V1_2>(res);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user