Interface Internal Types.
Copyright (c) 2017-2018 Microchip Technology Inc. and its subsidiaries.
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "common/include/nm_common.h"
#include "driver/include/m2m_types.h"
Data Structures | |
struct | tstrBuffer |
Macros | |
#define | BIT0 0x00000001 |
#define | BIT1 0x00000002 |
#define | BIT10 0x00000400 |
#define | BIT11 0x00000800 |
#define | BIT12 0x00001000 |
#define | BIT13 0x00002000 |
#define | BIT14 0x00004000 |
#define | BIT15 0x00008000 |
#define | BIT16 0x00010000 |
#define | BIT17 0x00020000 |
#define | BIT18 0x00040000 |
#define | BIT19 0x00080000 |
#define | BIT2 0x00000004 |
#define | BIT20 0x00100000 |
#define | BIT21 0x00200000 |
#define | BIT22 0x00400000 |
#define | BIT23 0x00800000 |
#define | BIT24 0x01000000 |
#define | BIT25 0x02000000 |
#define | BIT26 0x04000000 |
#define | BIT27 0x08000000 |
#define | BIT28 0x10000000 |
#define | BIT29 0x20000000 |
#define | BIT3 0x00000008 |
#define | BIT30 0x40000000 |
#define | BIT31 0x80000000 |
#define | BIT4 0x00000010 |
#define | BIT5 0x00000020 |
#define | BIT6 0x00000040 |
#define | BIT7 0x00000080 |
#define | BIT8 0x00000100 |
#define | BIT9 0x00000200 |
#define | GETU32(BUF, OFFSET) |
#define | HMAC_MD5 hmac_md5 |
#define | HMAC_SHA1 hmac_sha1 |
#define | HMAC_SHA256 Hmac_SHA256 |
#define | HMAC_VECTOR HMAC_Vector |
#define | M2M_DUMP_BUF(name, Buffer, size) |
#define | M2M_FREE(p) free(p) |
#define | M2M_MALLOC_S(s) malloc(s) |
#define | M2M_MEMCMP memcmp |
#define | M2M_MEMCPY memcpy |
#define | M2M_MEMSET memset |
#define | MAX(A, B) (((A) > (B))? (A) : (B)) |
#define | MD4_HASH MD4_Hash |
#define | MD5_HASH MD5_Hash |
#define | MD5_HASH_SW(pCxt, flags, data, dataSz, out) MD5_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
#define | MIN(A, B) (((A) < (B))? (A) : (B)) |
#define | OVERLAY_SEC1_API |
#define | PUTU32(VAL32, BUF, OFFSET) |
#define | SHA1_HASH SHA1_Hash |
#define | SHA1_HASH_SW(pCxt, flags, data, dataSz, out) SHA1_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
#define | SHA224_HASH_SW(pCxt, flags, data, dataSz, out) SHA224_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
#define | SHA256_HASH SHA256_Hash |
#define | SHA256_HASH_SW(pCxt, flags, data, dataSz, out) SHA256_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
#define | SHA384_HASH_SW(pCxt, flags, data, dataSz, out) SHA512_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out, 1) |
#define | SHA512_HASH_SW(pCxt, flags, data, dataSz, out) SHA512_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out, 0) |
#define | SIZE_1024_BITS (128) |
#define | SIZE_128_BITS (16) |
#define | SIZE_1536_BITS (192) |
#define | SIZE_2048_BITS (256) |
#define | SIZE_256_BITS (32) |
#define | SIZE_512_BITS (64) |
#define | TLS_API |
#define | TLS_CLIENT_API |
#define | TLS_ERR TLS_LOG |
#define | TLS_INFO TLS_LOG |
#define | TLS_LOG(...) do{printf(__VA_ARGS__);printf("\r");}while(0) |
#define | X509_GET_SYS_TIME(x) -1 |
Typedefs | |
typedef uint64_t | uint64 |
Enumerations | |
enum | BOOL_T { BFALSE = 0, BTRUE = 1 } |
#define BIT0 0x00000001 |
#define BIT1 0x00000002 |
#define BIT10 0x00000400 |
#define BIT11 0x00000800 |
#define BIT12 0x00001000 |
#define BIT13 0x00002000 |
#define BIT14 0x00004000 |
#define BIT15 0x00008000 |
#define BIT16 0x00010000 |
#define BIT17 0x00020000 |
#define BIT18 0x00040000 |
#define BIT19 0x00080000 |
#define BIT2 0x00000004 |
#define BIT20 0x00100000 |
#define BIT21 0x00200000 |
#define BIT22 0x00400000 |
#define BIT23 0x00800000 |
#define BIT24 0x01000000 |
#define BIT25 0x02000000 |
#define BIT26 0x04000000 |
#define BIT27 0x08000000 |
#define BIT28 0x10000000 |
#define BIT29 0x20000000 |
#define BIT3 0x00000008 |
#define BIT30 0x40000000 |
#define BIT31 0x80000000 |
#define BIT4 0x00000010 |
#define BIT5 0x00000020 |
#define BIT6 0x00000040 |
#define BIT7 0x00000080 |
Referenced by ASN1_GetNextElement().
#define BIT8 0x00000100 |
#define BIT9 0x00000200 |
#define GETU32 | ( | BUF, | |
OFFSET | |||
) |
Referenced by SHA1ProcessBlock().
#define HMAC_MD5 hmac_md5 |
#define HMAC_SHA1 hmac_sha1 |
#define HMAC_SHA256 Hmac_SHA256 |
#define HMAC_VECTOR HMAC_Vector |
#define M2M_DUMP_BUF | ( | name, | |
Buffer, | |||
size | |||
) |
Referenced by X509Cert_Dump().
#define M2M_FREE | ( | p | ) | free(p) |
#define M2M_MEMCMP memcmp |
Referenced by Cert_DecodeAlgID(), Cert_DecodeDistinguishedName(), and Cert_DecodeECCPubKey().
#define M2M_MEMCPY memcpy |
#define M2M_MEMSET memset |
Referenced by HMAC_Vector(), MD4_Hash(), MD5_HashSW(), SHA1_HashSW(), SHA224_HashSW(), SHA256_HashSW(), SHA512_HashSW(), and Sha_HashFinish().
#define MAX | ( | A, | |
B | |||
) | (((A) > (B))? (A) : (B)) |
#define MD4_HASH MD4_Hash |
#define MD5_HASH MD5_Hash |
#define MD5_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | MD5_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
Referenced by MD5_Hash().
#define MIN | ( | A, | |
B | |||
) | (((A) < (B))? (A) : (B)) |
#define OVERLAY_SEC1_API |
#define PUTU32 | ( | VAL32, | |
BUF, | |||
OFFSET | |||
) |
Referenced by SHA1_HashSW(), SHA224_HashSW(), SHA256_HashSW(), and SHA512_HashSW().
#define SHA1_HASH SHA1_Hash |
#define SHA1_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | SHA1_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
Referenced by SHA1_Hash().
#define SHA224_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | SHA224_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
Referenced by SHA224_Hash().
#define SHA256_HASH SHA256_Hash |
#define SHA256_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | SHA256_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out) |
Referenced by SHA256_Hash().
#define SHA384_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | SHA512_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out, 1) |
Referenced by SHA384_Hash().
#define SHA512_HASH_SW | ( | pCxt, | |
flags, | |||
data, | |||
dataSz, | |||
out | |||
) | SHA512_HashSW(&(pCxt)->strSha512, flags, data, dataSz, out, 0) |
Referenced by SHA512_Hash().
#define SIZE_1024_BITS (128) |
#define SIZE_128_BITS (16) |
#define SIZE_1536_BITS (192) |
#define SIZE_2048_BITS (256) |
#define SIZE_256_BITS (32) |
#define SIZE_512_BITS (64) |
#define TLS_API |
#define TLS_CLIENT_API |
#define TLS_ERR TLS_LOG |
Referenced by Cert_DecodeECCPubKey().
#define TLS_INFO TLS_LOG |
Referenced by X509Cert_Dump().
Referenced by X509Cert_Dump().
#define X509_GET_SYS_TIME | ( | x | ) | -1 |
Referenced by Cert_DecodeValidity().
typedef uint64_t uint64 |
enum BOOL_T |