TianoCore EDK2 master
|
Go to the source code of this file.
Typedefs | |
typedef VOID * | HASH_API_CONTEXT |
Functions | |
UINTN EFIAPI | HashApiGetContextSize (VOID) |
BOOLEAN EFIAPI | HashApiInit (OUT HASH_API_CONTEXT HashContext) |
BOOLEAN EFIAPI | HashApiDuplicate (IN HASH_API_CONTEXT HashContext, OUT HASH_API_CONTEXT NewHashContext) |
BOOLEAN EFIAPI | HashApiUpdate (IN HASH_API_CONTEXT HashContext, IN VOID *DataToHash, IN UINTN DataToHashLen) |
BOOLEAN EFIAPI | HashApiFinal (IN HASH_API_CONTEXT HashContext, OUT UINT8 *Digest) |
BOOLEAN EFIAPI | HashApiHashAll (IN CONST VOID *DataToHash, IN UINTN DataToHashLen, OUT UINT8 *Digest) |
Unified Hash API Defines
This API when called will calculate the Hash using the hashing algorithm specified by PcdHashApiLibPolicy.
Copyright (c) 2020, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file HashApiLib.h.
typedef VOID* HASH_API_CONTEXT |
Definition at line 15 of file HashApiLib.h.
BOOLEAN EFIAPI HashApiDuplicate | ( | IN HASH_API_CONTEXT | HashContext, |
OUT HASH_API_CONTEXT | NewHashContext | ||
) |
Makes a copy of an existing hash context.
[in] | HashContext | Hash context. |
[out] | NewHashContext | New copy of hash context. |
TRUE | Hash context copy succeeded. |
FALSE | Hash context copy failed. |
Definition at line 120 of file BaseHashApiLib.c.
Hash complete.
[in] | HashContext | Hash context. |
[out] | Digest | Hash Digest. |
TRUE | Hash complete and Digest is returned. |
FALSE | Hash complete unsuccessful. |
Definition at line 214 of file BaseHashApiLib.c.
UINTN EFIAPI HashApiGetContextSize | ( | VOID | ) |
Retrieves the size, in bytes, of the context buffer required for hash operations.
Definition at line 31 of file BaseHashApiLib.c.
BOOLEAN EFIAPI HashApiHashAll | ( | IN CONST VOID * | DataToHash, |
IN UINTN | DataToHashLen, | ||
OUT UINT8 * | Digest | ||
) |
Computes hash message digest of a input data buffer.
[in] | DataToHash | Data to be hashed. |
[in] | DataToHashLen | Data size. |
[out] | Digest | Hash Digest. |
TRUE | Hash digest computation succeeded. |
FALSE | Hash digest computation failed. |
Definition at line 261 of file BaseHashApiLib.c.
BOOLEAN EFIAPI HashApiInit | ( | OUT HASH_API_CONTEXT | HashContext | ) |
Init hash sequence.
[out] | HashContext | Hash context. |
TRUE | Hash start and HashHandle returned. |
FALSE | Hash Init unsuccessful. |
Definition at line 75 of file BaseHashApiLib.c.
BOOLEAN EFIAPI HashApiUpdate | ( | IN HASH_API_CONTEXT | HashContext, |
IN VOID * | DataToHash, | ||
IN UINTN | DataToHashLen | ||
) |
Update hash data.
[in] | HashContext | Hash context. |
[in] | DataToHash | Data to be hashed. |
[in] | DataToHashLen | Data size. |
TRUE | Hash updated. |
FALSE | Hash updated unsuccessful. |
Definition at line 167 of file BaseHashApiLib.c.