forked from albertobsd/keyhunt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrmd160.h
50 lines (38 loc) · 1.03 KB
/
rmd160.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/* RMD160.H - header file for RMD160.C
*/
#ifndef _RMD160_H_
#define _RMD160_H_
#include <stdint.h>
#include <sys/types.h>
#define RMD160_BLOCKBYTES 64
#define RMD160_BLOCKWORDS 16
#define RMD160_HASHBYTES 20
#define RMD160_HASHWORDS 5
/* For compatibility */
#define RIPEMD160_BLOCKBYTES 64
#define RIPEMD160_BLOCKWORDS 16
#define RIPEMD160_HASHBYTES 20
#define RIPEMD160_HASHWORDS 5
/* RIPEMD160 context. */
typedef struct RMD160Context {
uint32_t key[RIPEMD160_BLOCKWORDS];
uint32_t iv[RIPEMD160_HASHWORDS];
uint32_t bytesHi, bytesLo;
} RMD160_CTX;
#define RIPEMD160Context RMD160Context
#ifdef _WIN64
#else
#include <sys/cdefs.h>
__BEGIN_DECLS
#endif
void RMD160Init(RMD160_CTX *);
void RMD160Update(RMD160_CTX *, const unsigned char *, unsigned int);
void RMD160Final(unsigned char [RMD160_HASHBYTES], RMD160_CTX *);
char * RMD160End(RMD160_CTX *, char *);
char * RMD160File(const char *, char *);
void RMD160Data(const unsigned char *, unsigned int, char *);
#ifdef _WIN64
#else
__END_DECLS
#endif
#endif /* _RMD160_H_ */