aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornagendra modadugu <ngm@google.com>2016-11-03 00:50:16 +0000
committerandroid-build-merger <android-build-merger@google.com>2016-11-03 00:50:16 +0000
commit0080bf0cc70f84360ccf4dcb044efd738eee082b (patch)
tree439bc2c493a8ad4e98d4ca214ab25fecc2b785d4
parent3c244e57681633c1ddcf6e81fa0f6379aee607d2 (diff)
parent5e61a778981e74e74d500533bf79f9b3e245b581 (diff)
downloadtpm2-0080bf0cc70f84360ccf4dcb044efd738eee082b.tar.gz
tpm: fix assert failure in PCRComputeCurrentDigest am: 07ec984d63 am: c5912a41a9 am: efd9019ab1
am: 5e61a77898 Change-Id: I5d62e87a4653fa27edafbc6b7747f998350aa4f5
-rw-r--r--Object_spt.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Object_spt.c b/Object_spt.c
index dd37f1b..4cf13c7 100644
--- a/Object_spt.c
+++ b/Object_spt.c
@@ -533,6 +533,8 @@ PublicAttributesValidation(
OBJECT *parentObject = NULL;
if(HandleGetType(parentHandle) != TPM_HT_PERMANENT)
parentObject = ObjectGet(parentHandle);
+ if (publicArea->nameAlg == TPM_ALG_NULL)
+ return TPM_RC_HASH;
// Check authPolicy digest consistency
if( publicArea->authPolicy.t.size != 0
&& ( publicArea->authPolicy.t.size