implemented sha2_hasher which supports SHA-256, SHA-384 and SHA-512
This commit is contained in:
@@ -31,7 +31,7 @@ typedef enum pseudo_random_function_t pseudo_random_function_t;
|
||||
/**
|
||||
* @brief Pseudo random function, as in IKEv2 RFC 3.3.2.
|
||||
*
|
||||
* Currently only the following algorithms are implemented and therefore supported:
|
||||
* Currently only the following algorithms are implemented:
|
||||
* - PRF_HMAC_MD5
|
||||
* - PRF_HMAC_SHA1
|
||||
*
|
||||
@@ -39,16 +39,12 @@ typedef enum pseudo_random_function_t pseudo_random_function_t;
|
||||
*/
|
||||
enum pseudo_random_function_t {
|
||||
PRF_UNDEFINED = 1024,
|
||||
/**
|
||||
* Implemented in class hmac_prf_t.
|
||||
*/
|
||||
/** Implemented via hmac_prf_t. */
|
||||
PRF_HMAC_MD5 = 1,
|
||||
/**
|
||||
* Implemented in class hmac_prf_t.
|
||||
*/
|
||||
/** Implemented via hmac_prf_t. */
|
||||
PRF_HMAC_SHA1 = 2,
|
||||
PRF_HMAC_TIGER = 3,
|
||||
PRF_AES128_CBC = 4
|
||||
PRF_AES128_CBC = 4,
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -72,9 +68,8 @@ typedef struct prf_t prf_t;
|
||||
*/
|
||||
struct prf_t {
|
||||
/**
|
||||
* @brief Generates pseudo random bytes and writes them
|
||||
* in the buffer.
|
||||
*
|
||||
* @brief Generates pseudo random bytes and writes them in the buffer.
|
||||
*
|
||||
* @param this calling object
|
||||
* @param seed a chunk containing the seed for the next bytes
|
||||
* @param[out] buffer pointer where the generated bytes will be written
|
||||
|
||||
Reference in New Issue
Block a user