move hkdf to misc
This commit is contained in:
parent
d0a83df7f8
commit
c0b8774cc1
@ -75,7 +75,6 @@ enum {
|
||||
#include <tomcrypt_misc.h>
|
||||
#include <tomcrypt_argchk.h>
|
||||
#include <tomcrypt_pkcs.h>
|
||||
#include <tomcrypt_hkdf.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -365,13 +365,19 @@
|
||||
|
||||
#endif /* LTC_NO_PKCS */
|
||||
|
||||
/* LTC_HKDF Key Derivation/Expansion stuff */
|
||||
/* misc stuff */
|
||||
#ifndef LTC_NO_MISC
|
||||
|
||||
|
||||
/* Keep LTC_NO_HKDF for compatibility reasons
|
||||
* superseeded by LTC_NO_MISC*/
|
||||
#ifndef LTC_NO_HKDF
|
||||
|
||||
/* LTC_HKDF Key Derivation/Expansion stuff */
|
||||
#define LTC_HKDF
|
||||
|
||||
#endif /* LTC_NO_HKDF */
|
||||
|
||||
#endif /* LTC_NO_MISC */
|
||||
|
||||
/* cleanup */
|
||||
|
||||
#ifdef LTC_MECC
|
||||
|
@ -1,28 +0,0 @@
|
||||
/* LTC_HKDF Header Info */
|
||||
|
||||
/* ===> LTC_HKDF -- RFC5869 HMAC-based Key Derivation Function <=== */
|
||||
#ifdef LTC_HKDF
|
||||
|
||||
int hkdf_test(void);
|
||||
|
||||
int hkdf_extract(int hash_idx,
|
||||
const unsigned char *salt, unsigned long saltlen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long *outlen);
|
||||
|
||||
int hkdf_expand(int hash_idx,
|
||||
const unsigned char *info, unsigned long infolen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long outlen);
|
||||
|
||||
int hkdf(int hash_idx,
|
||||
const unsigned char *salt, unsigned long saltlen,
|
||||
const unsigned char *info, unsigned long infolen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long outlen);
|
||||
|
||||
#endif /* LTC_HKDF */
|
||||
|
||||
/* $Source$ */
|
||||
/* $Revision$ */
|
||||
/* $Date$ */
|
@ -7,6 +7,29 @@ int base64_decode(const unsigned char *in, unsigned long len,
|
||||
unsigned char *out, unsigned long *outlen);
|
||||
#endif
|
||||
|
||||
/* ===> LTC_HKDF -- RFC5869 HMAC-based Key Derivation Function <=== */
|
||||
#ifdef LTC_HKDF
|
||||
|
||||
int hkdf_test(void);
|
||||
|
||||
int hkdf_extract(int hash_idx,
|
||||
const unsigned char *salt, unsigned long saltlen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long *outlen);
|
||||
|
||||
int hkdf_expand(int hash_idx,
|
||||
const unsigned char *info, unsigned long infolen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long outlen);
|
||||
|
||||
int hkdf(int hash_idx,
|
||||
const unsigned char *salt, unsigned long saltlen,
|
||||
const unsigned char *info, unsigned long infolen,
|
||||
const unsigned char *in, unsigned long inlen,
|
||||
unsigned char *out, unsigned long outlen);
|
||||
|
||||
#endif /* LTC_HKDF */
|
||||
|
||||
/* ---- MEM routines ---- */
|
||||
void zeromem(volatile void *dst, size_t len);
|
||||
void burn_stack(unsigned long len);
|
||||
|
Loading…
Reference in New Issue
Block a user