24 #ifndef MBEDTLS_PKCS5_H
25 #define MBEDTLS_PKCS5_H
36 #define MBEDTLS_ERR_PKCS5_BAD_INPUT_DATA -0x2f80
38 #define MBEDTLS_ERR_PKCS5_INVALID_FORMAT -0x2f00
40 #define MBEDTLS_ERR_PKCS5_FEATURE_UNAVAILABLE -0x2e80
42 #define MBEDTLS_ERR_PKCS5_PASSWORD_MISMATCH -0x2e00
44 #define MBEDTLS_PKCS5_DECRYPT 0
45 #define MBEDTLS_PKCS5_ENCRYPT 1
51 #if defined(MBEDTLS_ASN1_PARSE_C)
67 const unsigned char *pwd,
size_t pwdlen,
68 const unsigned char *data,
size_t datalen,
69 unsigned char *output );
88 size_t plen,
const unsigned char *salt,
size_t slen,
89 unsigned int iteration_count,
90 uint32_t key_length,
unsigned char *output );
92 #if defined(MBEDTLS_SELF_TEST)
int mbedtls_pkcs5_pbkdf2_hmac(mbedtls_md_context_t *ctx, const unsigned char *password, size_t plen, const unsigned char *salt, size_t slen, unsigned int iteration_count, uint32_t key_length, unsigned char *output)
PKCS#5 PBKDF2 using HMAC.
Build-time configuration info.
This file contains the generic message-digest wrapper.
int mbedtls_pkcs5_self_test(int verbose)
Checkup routine.
int mbedtls_pkcs5_pbes2(const mbedtls_asn1_buf *pbe_params, int mode, const unsigned char *pwd, size_t pwdlen, const unsigned char *data, size_t datalen, unsigned char *output)
PKCS#5 PBES2 function.