Home
last modified time | relevance | path

Searched refs:HashCtx (Results 1 – 7 of 7) sorted by relevance

/device/linaro/bootloader/edk2/CryptoPkg/Application/Cryptest/
DHashVerify.c89 VOID *HashCtx; in ValidateCryptDigest() local
104 HashCtx = AllocatePool (CtxSize); in ValidateCryptDigest()
107 Status = Md4Init (HashCtx); in ValidateCryptDigest()
114 Status = Md4Update (HashCtx, HashData, DataSize); in ValidateCryptDigest()
121 Status = Md4Final (HashCtx, Digest); in ValidateCryptDigest()
127 FreePool (HashCtx); in ValidateCryptDigest()
156 HashCtx = AllocatePool (CtxSize); in ValidateCryptDigest()
159 Status = Md5Init (HashCtx); in ValidateCryptDigest()
166 Status = Md5Update (HashCtx, HashData, DataSize); in ValidateCryptDigest()
173 Status = Md5Final (HashCtx, Digest); in ValidateCryptDigest()
[all …]
/device/linaro/bootloader/edk2/SecurityPkg/Library/HashLibBaseCryptoRouter/
DHashLibBaseCryptoRouterDxe.c45 HASH_HANDLE *HashCtx; in HashStart() local
53 HashCtx = AllocatePool (sizeof(*HashCtx) * mHashInterfaceCount); in HashStart()
54 ASSERT (HashCtx != NULL); in HashStart()
59 mHashInterface[Index].HashInit (&HashCtx[Index]); in HashStart()
63 *HashHandle = (HASH_HANDLE)HashCtx; in HashStart()
85 HASH_HANDLE *HashCtx; in HashUpdate() local
93 HashCtx = (HASH_HANDLE *)HashHandle; in HashUpdate()
98 mHashInterface[Index].HashUpdate (HashCtx[Index], DataToHash, DataToHashLen); in HashUpdate()
127 HASH_HANDLE *HashCtx; in HashCompleteAndExtend() local
136 HashCtx = (HASH_HANDLE *)HashHandle; in HashCompleteAndExtend()
[all …]
DHashLibBaseCryptoRouterPei.c73 HASH_HANDLE *HashCtx; in HashStart() local
86 HashCtx = AllocatePool (sizeof(*HashCtx) * HashInterfaceHob->HashInterfaceCount); in HashStart()
87 ASSERT (HashCtx != NULL); in HashStart()
92 HashInterfaceHob->HashInterface[Index].HashInit (&HashCtx[Index]); in HashStart()
96 *HashHandle = (HASH_HANDLE)HashCtx; in HashStart()
119 HASH_HANDLE *HashCtx; in HashUpdate() local
132 HashCtx = (HASH_HANDLE *)HashHandle; in HashUpdate()
137 HashInterfaceHob->HashInterface[Index].HashUpdate (HashCtx[Index], DataToHash, DataToHashLen); in HashUpdate()
167 HASH_HANDLE *HashCtx; in HashCompleteAndExtend() local
181 HashCtx = (HASH_HANDLE *)HashHandle; in HashCompleteAndExtend()
[all …]
/device/linaro/bootloader/edk2/SecurityPkg/Hash2DxeCrypto/
DHash2DxeCrypto.c357 VOID *HashCtx; in BaseCrypto2Hash() local
392 HashCtx = AllocatePool (CtxSize); in BaseCrypto2Hash()
393 if (HashCtx == NULL) { in BaseCrypto2Hash()
397 Ret = HashInfo->Init (HashCtx); in BaseCrypto2Hash()
406 Instance->HashContext = HashCtx; in BaseCrypto2Hash()
409 Ret = HashInfo->Update (HashCtx, Message, MessageSize); in BaseCrypto2Hash()
415 Ret = HashInfo->Final (HashCtx, (UINT8 *)Hash->Sha1Hash); in BaseCrypto2Hash()
424 FreePool (HashCtx); in BaseCrypto2Hash()
454 VOID *HashCtx; in BaseCrypto2HashInit() local
487 HashCtx = AllocatePool (CtxSize); in BaseCrypto2HashInit()
[all …]
/device/linaro/bootloader/edk2/SecurityPkg/Pkcs7Verify/Pkcs7VerifyDxe/
DPkcs7VerifyDxe.c49 VOID *HashCtx; in CalculateDataHash() local
53 HashCtx = NULL; in CalculateDataHash()
60 HashCtx = AllocatePool (CtxSize); in CalculateDataHash()
61 if (HashCtx == NULL) { in CalculateDataHash()
64 Status = Sha1Init (HashCtx); in CalculateDataHash()
65 Status = Sha1Update (HashCtx, Data, DataSize); in CalculateDataHash()
66 Status = Sha1Final (HashCtx, HashValue); in CalculateDataHash()
73 HashCtx = AllocatePool (CtxSize); in CalculateDataHash()
74 if (HashCtx == NULL) { in CalculateDataHash()
77 Status = Sha256Init (HashCtx); in CalculateDataHash()
[all …]
/device/linaro/bootloader/edk2/SecurityPkg/Library/DxeImageVerificationLib/
DDxeImageVerificationLib.c300 VOID *HashCtx; in HashPeImage() local
311 HashCtx = NULL; in HashPeImage()
352 HashCtx = AllocatePool (CtxSize); in HashPeImage()
353 if (HashCtx == NULL) { in HashPeImage()
360 Status = mHash[HashAlg].HashInit(HashCtx); in HashPeImage()
410 Status = mHash[HashAlg].HashUpdate(HashCtx, HashBase, HashSize); in HashPeImage()
438 Status = mHash[HashAlg].HashUpdate(HashCtx, HashBase, HashSize); in HashPeImage()
462 Status = mHash[HashAlg].HashUpdate(HashCtx, HashBase, HashSize); in HashPeImage()
487 Status = mHash[HashAlg].HashUpdate(HashCtx, HashBase, HashSize); in HashPeImage()
560 Status = mHash[HashAlg].HashUpdate(HashCtx, HashBase, HashSize); in HashPeImage()
[all …]
/device/linaro/bootloader/edk2/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/
DSecureBootConfigImpl.c1088 VOID *HashCtx; in CalculateCertHash() local
1093 HashCtx = NULL; in CalculateCertHash()
1111 HashCtx = AllocatePool (CtxSize); in CalculateCertHash()
1112 ASSERT (HashCtx != NULL); in CalculateCertHash()
1117 Status = mHash[HashAlg].HashInit (HashCtx); in CalculateCertHash()
1125 Status = mHash[HashAlg].HashUpdate (HashCtx, TBSCert, TBSCertSize); in CalculateCertHash()
1134 Status = mHash[HashAlg].HashFinal (HashCtx, CertHash); in CalculateCertHash()
1137 if (HashCtx != NULL) { in CalculateCertHash()
1138 FreePool (HashCtx); in CalculateCertHash()
1776 VOID *HashCtx; in HashPeImage() local
[all …]