Dash Core Source Documentation (0.16.0.1)

Find detailed information regarding the Dash Core source code.

sph_luffa.h
Go to the documentation of this file.
1 /* $Id: sph_luffa.h 154 2010-04-26 17:00:24Z tp $ */
36 #ifndef SPH_LUFFA_H__
37 #define SPH_LUFFA_H__
38 
39 #ifdef __cplusplus
40 extern "C"{
41 #endif
42 
43 #include <stddef.h>
44 #include <crypto/sph_types.h>
45 
49 #define SPH_SIZE_luffa224 224
50 
54 #define SPH_SIZE_luffa256 256
55 
59 #define SPH_SIZE_luffa384 384
60 
64 #define SPH_SIZE_luffa512 512
65 
76 typedef struct {
77 #ifndef DOXYGEN_IGNORE
78  unsigned char buf[32]; /* first field, for alignment */
79  size_t ptr;
80  sph_u32 V[3][8];
81 #endif
83 
89 
93 typedef struct {
94 #ifndef DOXYGEN_IGNORE
95  unsigned char buf[32]; /* first field, for alignment */
96  size_t ptr;
97  sph_u32 V[4][8];
98 #endif
100 
104 typedef struct {
105 #ifndef DOXYGEN_IGNORE
106  unsigned char buf[32]; /* first field, for alignment */
107  size_t ptr;
108  sph_u32 V[5][8];
109 #endif
111 
118 void sph_luffa224_init(void *cc);
119 
128 void sph_luffa224(void *cc, const void *data, size_t len);
129 
139 void sph_luffa224_close(void *cc, void *dst);
140 
155  void *cc, unsigned ub, unsigned n, void *dst);
156 
163 void sph_luffa256_init(void *cc);
164 
173 void sph_luffa256(void *cc, const void *data, size_t len);
174 
184 void sph_luffa256_close(void *cc, void *dst);
185 
200  void *cc, unsigned ub, unsigned n, void *dst);
201 
208 void sph_luffa384_init(void *cc);
209 
218 void sph_luffa384(void *cc, const void *data, size_t len);
219 
229 void sph_luffa384_close(void *cc, void *dst);
230 
245  void *cc, unsigned ub, unsigned n, void *dst);
246 
253 void sph_luffa512_init(void *cc);
254 
263 void sph_luffa512(void *cc, const void *data, size_t len);
264 
274 void sph_luffa512_close(void *cc, void *dst);
275 
290  void *cc, unsigned ub, unsigned n, void *dst);
291 
292 #ifdef __cplusplus
293 }
294 #endif
295 
296 #endif
void sph_luffa256(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: luffa.c:1338
void sph_luffa224(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: luffa.c:1305
Basic type definitions.
void sph_luffa256_init(void *cc)
Initialize a Luffa-256 context.
Definition: luffa.c:1327
void sph_luffa512_init(void *cc)
Initialize a Luffa-512 context.
Definition: luffa.c:1393
void sph_luffa512_close(void *cc, void *dst)
Terminate the current Luffa-512 computation and output the result into the provided buffer...
Definition: luffa.c:1411
void sph_luffa512(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: luffa.c:1404
This structure is a context for Luffa-224 computations: it contains the intermediate values and some ...
Definition: sph_luffa.h:76
void sph_luffa256_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Add a few additional bits (0 to 7) to the current computation, then terminate it and output the resul...
Definition: luffa.c:1352
This structure is a context for Luffa-384 computations.
Definition: sph_luffa.h:93
void sph_luffa384(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: luffa.c:1371
void sph_luffa224_close(void *cc, void *dst)
Terminate the current Luffa-224 computation and output the result into the provided buffer...
Definition: luffa.c:1312
void sph_luffa512_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Add a few additional bits (0 to 7) to the current computation, then terminate it and output the resul...
Definition: luffa.c:1418
void sph_luffa224_init(void *cc)
Initialize a Luffa-224 context.
Definition: luffa.c:1294
void sph_luffa224_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Add a few additional bits (0 to 7) to the current computation, then terminate it and output the resul...
Definition: luffa.c:1319
void sph_luffa256_close(void *cc, void *dst)
Terminate the current Luffa-256 computation and output the result into the provided buffer...
Definition: luffa.c:1345
This structure is a context for Luffa-512 computations.
Definition: sph_luffa.h:104
unsigned long sph_u32
Definition: sph_types.h:870
sph_luffa224_context sph_luffa256_context
This structure is a context for Luffa-256 computations.
Definition: sph_luffa.h:88
void sph_luffa384_addbits_and_close(void *cc, unsigned ub, unsigned n, void *dst)
Add a few additional bits (0 to 7) to the current computation, then terminate it and output the resul...
Definition: luffa.c:1385
void sph_luffa384_init(void *cc)
Initialize a Luffa-384 context.
Definition: luffa.c:1360
void sph_luffa384_close(void *cc, void *dst)
Terminate the current Luffa-384 computation and output the result into the provided buffer...
Definition: luffa.c:1378
Released under the MIT license