remove ft_sha.h from ft_pbkdf2.h
This commit is contained in:
parent
9d2222d60d
commit
6eec5b018d
3 changed files with 11 additions and 3 deletions
|
@ -1,10 +1,14 @@
|
||||||
#include "ft_sha.h"
|
|
||||||
|
#ifndef FT_PBKDF2_H
|
||||||
|
# define FT_PBKDF2_H
|
||||||
|
|
||||||
|
#define FT_PBKDF2_RESULT 32
|
||||||
|
|
||||||
typedef struct s_hmac_sha256_ctx
|
typedef struct s_hmac_sha256_ctx
|
||||||
{
|
{
|
||||||
unsigned char *key;
|
unsigned char *key;
|
||||||
unsigned char *msg;
|
unsigned char *msg;
|
||||||
unsigned char out[FT_SHA256_DIGEST_LENGTH_BYTE];
|
unsigned char out[FT_PBKDF2_RESULT];
|
||||||
unsigned int key_size;
|
unsigned int key_size;
|
||||||
unsigned int msg_size;
|
unsigned int msg_size;
|
||||||
} t_hmac_sha256_ctx;
|
} t_hmac_sha256_ctx;
|
||||||
|
@ -18,3 +22,5 @@ void ft_hmac_sha256
|
||||||
(
|
(
|
||||||
t_hmac_sha256_ctx *ctx
|
t_hmac_sha256_ctx *ctx
|
||||||
);
|
);
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,5 +1,6 @@
|
||||||
#include "ft_pbkdf2.h"
|
#include "ft_pbkdf2.h"
|
||||||
#include "libft.h"
|
#include "libft.h"
|
||||||
|
#include "ft_sha.h"
|
||||||
|
|
||||||
static void set_padding
|
static void set_padding
|
||||||
(
|
(
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
#include "t.h"
|
#include "t.h"
|
||||||
#include "tests.h"
|
#include "tests.h"
|
||||||
#include "ft_pbkdf2.h"
|
#include "ft_pbkdf2.h"
|
||||||
|
#include "ft_sha.h"
|
||||||
|
|
||||||
static int init_hmac_sha256_ctx()
|
static int init_hmac_sha256_ctx()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue