|
SharkSSL C/C++ Reference
TLS, cryptography, certificates, and PSA integration
|
#include "SharkSSL.h"Go to the source code of this file.
Functions | |
| SHARKSSL_API int | SharkSslPSAPBKDF2_derive (U8 *output, const U8 *password, const U8 *salt, psa_algorithm_t alg, U32 passwordLen, U32 saltLen, U32 iterations, U16 outputLen) |
| Derive bytes with PSA PBKDF2-HMAC or PBKDF2-AES-CMAC-PRF-128. More... | |
See Choose a SharkSSL API for build scope and the owning API layer.
| int SharkSslPSAPBKDF2_derive | ( | U8 * | output, |
| const U8 * | password, | ||
| const U8 * | salt, | ||
| psa_algorithm_t | alg, | ||
| U32 | passwordLen, | ||
| U32 | saltLen, | ||
| U32 | iterations, | ||
| U16 | outputLen | ||
| ) |
Derive bytes with PSA PBKDF2-HMAC or PBKDF2-AES-CMAC-PRF-128.
The caller owns output and supplies its exact size in outputLen. Returns zero on success; clears output and returns -1 on failure.
| output | U8 *; required caller-owned buffer of outputLen bytes; cleared on failure after output validation. |
| password | const U8 *; password bytes, or NULL with passwordLen=0. |
| salt | const U8 *; salt bytes, or NULL with saltLen=0. |
| alg | psa_algorithm_t; a supported PSA_ALG_PBKDF2_HMAC(hash), or PSA_ALG_PBKDF2_AES_CMAC_PRF_128 when declared. |
| passwordLen | U32; password byte count. |
| saltLen | U32; salt byte count. |
| iterations | U32; positive iteration count. |
| outputLen | U16; positive requested derived length in bytes. |