/**************************************************************************//* *//* Copyright (c) Microsoft Corporation. All rights reserved. *//* *//* This software is licensed under the Microsoft Software License *//* Terms for Microsoft Azure RTOS. Full text of the license can be *//* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA *//* and in the root directory of this software. *//* */.../**************************************************************************/.../**************************************************************************//**************************************************************************//** *//** NetX Crypto Component *//** *//** Transport Layer Security (TLS) *//** */.../**************************************************************************//**************************************************************************/#ifndefSRC_NX_SECURE_PHASH_H_#defineSRC_NX_SECURE_PHASH_H_/* Determine if a C++ compiler is being used. If so, ensure that standard C is used to process the API information. *//* ... */#ifdef__cplusplus/* Yes, C++ compiler is present. Use standard C. */extern"C"{#endif#include"nx_crypto.h"#include"nx_crypto_hmac_sha2.h"#include"nx_crypto_hmac_sha5.h"/**************************************************************************//* *//* COMPONENT DEFINITION RELEASE *//* *//* nx_crypto_phash.h PORTABLE C *//* 6.1 *//* AUTHOR *//* *//* Timothy Stapko, Microsoft Corporation *//* *//* DESCRIPTION *//* *//* This file defines the TLS P-HASH function described in RFCs 2246, *//* 4346, and 5246. It is used in the TLS PRF function as a wrapper to *//* various hash routines to generate arbitrary-length data. *//* *//* RELEASE HISTORY *//* *//* DATE NAME DESCRIPTION *//* *//* 05-19-2020 Timothy Stapko Initial Version 6.0 *//* 09-30-2020 Timothy Stapko Modified comment(s), *//* resulting in version 6.1 *//* */.../**************************************************************************/typedefstructNX_CRYPTO_PHASH_STRUCT{UCHAR*nx_crypto_phash_secret;/* secret */NX_CRYPTO_KEY_SIZEnx_crypto_phash_secret_length;UCHAR*nx_crypto_phash_seed;/* seed */UINTnx_crypto_phash_seed_length;UCHAR*nx_crypto_phash_temp_A;/* the buffer for A(i) */UINTnx_crypto_phash_temp_A_size;NX_CRYPTO_METHOD*nx_crypto_hmac_method;/* hmac method */UCHAR*nx_crypto_hmac_metadata;/* hash_metadata */UINTnx_crypto_hmac_metadata_size;UCHAR*nx_crypto_hmac_output;UINTnx_crypto_hmac_output_size;...}NX_CRYPTO_PHASH;externNX_CRYPTO_METHODcrypto_method_hmac_md5;externNX_CRYPTO_METHODcrypto_method_hmac_sha1;externNX_CRYPTO_METHODcrypto_method_hmac_sha256;externNX_CRYPTO_METHODcrypto_method_hmac_sha384;externNX_CRYPTO_METHODcrypto_method_hmac_sha512;UINT_nx_crypto_phash(NX_CRYPTO_PHASH*phash,UCHAR*output,UINTdesired_length);#ifdef__cplusplus}extern "C" { ... }#endif/* ... */#endif
Details
Show: from
Types: Columns:
All items filtered out
All items filtered out
This file uses the notable symbols shown below. Click anywhere in the file to view more details.