Some commands in DxeTcg2PhysicalPresenceLib accept
AuthSession as input parameter and copy to local
command buffer. After use, this AuthSession content
should be zeroed, because there might be some secrete
there.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: "Yao, Jiewen" <jiewen.yao@intel.com>
Reviewed-by: "Zhang, Chao B" <chao.b.zhang@intel.com>
);\r
DEBUG ((EFI_D_INFO, "Tpm2PcrAllocate - %r\n", Status));\r
if (EFI_ERROR (Status)) {\r
);\r
DEBUG ((EFI_D_INFO, "Tpm2PcrAllocate - %r\n", Status));\r
if (EFI_ERROR (Status)) {\r
}\r
\r
DEBUG ((EFI_D_INFO, "AllocationSuccess - %02x\n", AllocationSuccess));\r
}\r
\r
DEBUG ((EFI_D_INFO, "AllocationSuccess - %02x\n", AllocationSuccess));\r
DEBUG ((EFI_D_INFO, "SizeNeeded - %08x\n", SizeNeeded));\r
DEBUG ((EFI_D_INFO, "SizeAvailable - %08x\n", SizeAvailable));\r
\r
DEBUG ((EFI_D_INFO, "SizeNeeded - %08x\n", SizeNeeded));\r
DEBUG ((EFI_D_INFO, "SizeAvailable - %08x\n", SizeAvailable));\r
\r
+Done:\r
+ ZeroMem(&LocalAuthSession.hmac, sizeof(LocalAuthSession.hmac));\r
+ return Status;\r
\r
Status = Tpm2ChangeEPS (TPM_RH_PLATFORM, AuthSession);\r
DEBUG ((EFI_D_INFO, "Tpm2ChangeEPS - %r\n", Status));\r
\r
Status = Tpm2ChangeEPS (TPM_RH_PLATFORM, AuthSession);\r
DEBUG ((EFI_D_INFO, "Tpm2ChangeEPS - %r\n", Status));\r
+\r
+ ZeroMem(&LocalAuthSession.hmac, sizeof(LocalAuthSession.hmac));\r