TianoCore EDK2 master
|
#include "TestBaseCryptLib.h"
Go to the source code of this file.
Data Structures | |
struct | HMAC_TEST_CONTEXT |
Macros | |
#define | MAX_DIGEST_SIZE 64 |
Typedefs | |
typedef VOID *(EFIAPI * | EFI_HMAC_NEW) (VOID) |
typedef VOID(EFIAPI * | EFI_HMAC_FREE) (IN VOID *HashContext) |
typedef BOOLEAN(EFIAPI * | EFI_HMAC_INIT) (IN OUT VOID *HashContext, IN CONST UINT8 *Key, IN UINTN KeySize) |
typedef BOOLEAN(EFIAPI * | EFI_HMAC_DUP) (IN CONST VOID *HashContext, OUT VOID *NewHashContext) |
typedef BOOLEAN(EFIAPI * | EFI_HMAC_UPDATE) (IN OUT VOID *HashContext, IN CONST VOID *Data, IN UINTN DataSize) |
typedef BOOLEAN(EFIAPI * | EFI_HMAC_FINAL) (IN OUT VOID *HashContext, OUT UINT8 *HashValue) |
typedef BOOLEAN(EFIAPI * | EFI_HMAC_ALL) (IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HashValue) |
Functions | |
UNIT_TEST_STATUS EFIAPI | TestVerifyHmacPreReq (UNIT_TEST_CONTEXT Context) |
VOID EFIAPI | TestVerifyHmacCleanUp (UNIT_TEST_CONTEXT Context) |
UNIT_TEST_STATUS EFIAPI | TestVerifyHmac (IN UNIT_TEST_CONTEXT Context) |
Application for HMAC Primitives Validation.
Copyright (c) 2010 - 2016, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file HmacTests.c.
#define MAX_DIGEST_SIZE 64 |
Definition at line 14 of file HmacTests.c.
typedef BOOLEAN(EFIAPI * EFI_HMAC_ALL) (IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HashValue) |
Definition at line 127 of file HmacTests.c.
Definition at line 105 of file HmacTests.c.
Definition at line 120 of file HmacTests.c.
typedef VOID(EFIAPI * EFI_HMAC_FREE) (IN VOID *HashContext) |
Definition at line 91 of file HmacTests.c.
typedef BOOLEAN(EFIAPI * EFI_HMAC_INIT) (IN OUT VOID *HashContext, IN CONST UINT8 *Key, IN UINTN KeySize) |
Definition at line 97 of file HmacTests.c.
typedef VOID *(EFIAPI * EFI_HMAC_NEW) (VOID) |
Definition at line 85 of file HmacTests.c.
typedef BOOLEAN(EFIAPI * EFI_HMAC_UPDATE) (IN OUT VOID *HashContext, IN CONST VOID *Data, IN UINTN DataSize) |
Definition at line 112 of file HmacTests.c.
UNIT_TEST_STATUS EFIAPI TestVerifyHmac | ( | IN UNIT_TEST_CONTEXT | Context | ) |
Definition at line 187 of file HmacTests.c.
VOID EFIAPI TestVerifyHmacCleanUp | ( | UNIT_TEST_CONTEXT | Context | ) |
Definition at line 173 of file HmacTests.c.
UNIT_TEST_STATUS EFIAPI TestVerifyHmacPreReq | ( | UNIT_TEST_CONTEXT | Context | ) |
Definition at line 156 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8* HmacData = "Hi There" |
Definition at line 19 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacMd5Digest[] |
Definition at line 31 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacMd5Key[16] |
Definition at line 24 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha1Digest[] |
Definition at line 46 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha1Key[20] |
Definition at line 38 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha256Digest[] |
Definition at line 62 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha256Key[20] |
Definition at line 54 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha384Digest[] |
Definition at line 78 of file HmacTests.c.
GLOBAL_REMOVE_IF_UNREFERENCED CONST UINT8 HmacSha384Key[20] |
Definition at line 70 of file HmacTests.c.
HMAC_TEST_CONTEXT mHmacSha256TestCtx = { SHA256_DIGEST_SIZE, HmacSha256New, HmacSha256Free, HmacSha256SetKey, HmacSha256Duplicate, HmacSha256Update, HmacSha256Final, HmacSha256All, HmacSha256Key, sizeof (HmacSha256Key), HmacSha256Digest } |
Definition at line 151 of file HmacTests.c.
HMAC_TEST_CONTEXT mHmacSha384TestCtx = { SHA384_DIGEST_SIZE, HmacSha384New, HmacSha384Free, HmacSha384SetKey, HmacSha384Duplicate, HmacSha384Update, HmacSha384Final, HmacSha384All, HmacSha384Key, sizeof (HmacSha384Key), HmacSha384Digest } |
Definition at line 152 of file HmacTests.c.
TEST_DESC mHmacTest[] |
Definition at line 234 of file HmacTests.c.
UINTN mHmacTestNum = ARRAY_SIZE (mHmacTest) |
Definition at line 242 of file HmacTests.c.