Adding additional logs to the decryption flow

[ Merge of http://go/wvgerrit/111507 ]

Bug: 174195349
Test: WV unit/integration tests
Change-Id: If8eb2c6ba326ed246da7adfa1137e16fe69bb044
This commit is contained in:
Rahul Frias
2020-12-08 10:56:41 -08:00
parent e851d42eb1
commit 53d6db47e5

View File

@@ -740,11 +740,16 @@ CdmResponseType CdmSession::Decrypt(const CdmDecryptionParametersV16& params) {
if (is_protected) {
if (!policy_engine_->CanDecryptContent(params.key_id)) {
if (policy_engine_->IsLicenseForFuture()) return DECRYPT_NOT_READY;
if (!policy_engine_->IsSufficientOutputProtection(params.key_id))
if (!policy_engine_->IsSufficientOutputProtection(params.key_id)) {
LOGE("Key use prohibited as HDCP or resolution requirements not met");
return INSUFFICIENT_OUTPUT_PROTECTION;
}
return NEED_KEY;
}
if (!policy_engine_->CanUseKeyForSecurityLevel(params.key_id)) {
LOGE(
"Key use prohibited as security level requirements in the policy"
" not met");
return KEY_PROHIBITED_FOR_SECURITY_LEVEL;
}
}