Raven Core  3.0.0
P2P Digital Currency
sph_fugue.h
Go to the documentation of this file.
1 #ifndef SPH_FUGUE_H__
2 #define SPH_FUGUE_H__
3 
4 #include <stddef.h>
5 #include "sph_types.h"
6 
7 #ifdef __cplusplus
8 extern "C"{
9 #endif
10 
11 #define SPH_SIZE_fugue224 224
12 
13 #define SPH_SIZE_fugue256 256
14 
15 #define SPH_SIZE_fugue384 384
16 
17 #define SPH_SIZE_fugue512 512
18 
19 typedef struct {
20 #ifndef DOXYGEN_IGNORE
22  unsigned partial_len;
23  unsigned round_shift;
24  sph_u32 S[36];
25 #if SPH_64
26  sph_u64 bit_count;
27 #else
28  sph_u32 bit_count_high, bit_count_low;
29 #endif
30 #endif
32 
34 
36 
38 
40 
41 void sph_fugue224_init(void *cc);
42 
43 void sph_fugue224(void *cc, const void *data, size_t len);
44 
45 void sph_fugue224_close(void *cc, void *dst);
46 
48  void *cc, unsigned ub, unsigned n, void *dst);
49 
50 void sph_fugue256_init(void *cc);
51 
52 void sph_fugue256(void *cc, const void *data, size_t len);
53 
54 void sph_fugue256_close(void *cc, void *dst);
55 
57  void *cc, unsigned ub, unsigned n, void *dst);
58 
59 void sph_fugue384_init(void *cc);
60 
61 void sph_fugue384(void *cc, const void *data, size_t len);
62 
63 void sph_fugue384_close(void *cc, void *dst);
64 
66  void *cc, unsigned ub, unsigned n, void *dst);
67 
68 void sph_fugue512_init(void *cc);
69 
70 void sph_fugue512(void *cc, const void *data, size_t len);
71 
72 void sph_fugue512_close(void *cc, void *dst);
73 
75  void *cc, unsigned ub, unsigned n, void *dst);
76 
77 #ifdef __cplusplus
78 }
79 #endif
80 
81 #endif
void sph_fugue256(void *cc, const void *data, size_t len)
Definition: sph_fugue.c:1142
sph_fugue_context sph_fugue512_context
Definition: sph_fugue.h:39
Basic type definitions.
void sph_fugue512_close(void *cc, void *dst)
Definition: sph_fugue.c:1196
void sph_fugue384_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Definition: sph_fugue.c:1178
void sph_fugue512_init(void *cc)
Definition: sph_fugue.c:1184
void sph_fugue384_close(void *cc, void *dst)
Definition: sph_fugue.c:1172
void sph_fugue256_close(void *cc, void *dst)
Definition: sph_fugue.c:1148
void sph_fugue256_init(void *cc)
Definition: sph_fugue.c:1136
void sph_fugue384(void *cc, const void *data, size_t len)
Definition: sph_fugue.c:1166
void sph_fugue224_init(void *cc)
Definition: sph_fugue.c:1112
unsigned round_shift
Definition: sph_fugue.h:23
void sph_fugue224_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Definition: sph_fugue.c:1130
void sph_fugue256_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Definition: sph_fugue.c:1154
sph_fugue_context sph_fugue384_context
Definition: sph_fugue.h:37
#define S(x0, x1, x2, x3, cb, r)
Definition: jh.c:494
void sph_fugue384_init(void *cc)
Definition: sph_fugue.c:1160
unsigned partial_len
Definition: sph_fugue.h:22
sph_u32 bit_count_low
Definition: sph_fugue.h:28
void sph_fugue512_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Definition: sph_fugue.c:1202
sph_fugue_context sph_fugue256_context
Definition: sph_fugue.h:35
sph_fugue_context sph_fugue224_context
Definition: sph_fugue.h:33
unsigned long sph_u32
Definition: sph_types.h:870
void sph_fugue512(void *cc, const void *data, size_t len)
Definition: sph_fugue.c:1190
void sph_fugue224_close(void *cc, void *dst)
Definition: sph_fugue.c:1124
sph_u32 partial
Definition: sph_fugue.h:21
void sph_fugue224(void *cc, const void *data, size_t len)
Definition: sph_fugue.c:1118