Dash Core Source Documentation (0.16.0.1)

Find detailed information regarding the Dash Core source code.

sph_cubehash.h
Go to the documentation of this file.
1 /* $Id: sph_cubehash.h 180 2010-05-08 02:29:25Z tp $ */
37 #ifndef SPH_CUBEHASH_H__
38 #define SPH_CUBEHASH_H__
39 
40 #ifdef __cplusplus
41 extern "C"{
42 #endif
43 
44 #include <stddef.h>
45 #include <crypto/sph_types.h>
46 
50 #define SPH_SIZE_cubehash224 224
51 
55 #define SPH_SIZE_cubehash256 256
56 
60 #define SPH_SIZE_cubehash384 384
61 
65 #define SPH_SIZE_cubehash512 512
66 
77 typedef struct {
78 #ifndef DOXYGEN_IGNORE
79  unsigned char buf[32]; /* first field, for alignment */
80  size_t ptr;
81  sph_u32 state[32];
82 #endif
84 
89 
94 
99 
104 
112 void sph_cubehash224_init(void *cc);
113 
122 void sph_cubehash224(void *cc, const void *data, size_t len);
123 
133 void sph_cubehash224_close(void *cc, void *dst);
134 
149  void *cc, unsigned ub, unsigned n, void *dst);
150 
158 void sph_cubehash256_init(void *cc);
159 
168 void sph_cubehash256(void *cc, const void *data, size_t len);
169 
179 void sph_cubehash256_close(void *cc, void *dst);
180 
195  void *cc, unsigned ub, unsigned n, void *dst);
196 
204 void sph_cubehash384_init(void *cc);
205 
214 void sph_cubehash384(void *cc, const void *data, size_t len);
215 
225 void sph_cubehash384_close(void *cc, void *dst);
226 
241  void *cc, unsigned ub, unsigned n, void *dst);
242 
250 void sph_cubehash512_init(void *cc);
251 
260 void sph_cubehash512(void *cc, const void *data, size_t len);
261 
271 void sph_cubehash512_close(void *cc, void *dst);
272 
287  void *cc, unsigned ub, unsigned n, void *dst);
288 #ifdef __cplusplus
289 }
290 #endif
291 
292 #endif
void sph_cubehash384_close(void *cc, void *dst)
Terminate the current CubeHash-384 computation and output the result into the provided buffer...
Definition: cubehash.c:680
void sph_cubehash224_init(void *cc)
Initialize a CubeHash-224 context.
Definition: cubehash.c:608
Basic type definitions.
void sph_cubehash384_init(void *cc)
Initialize a CubeHash-384 context.
Definition: cubehash.c:666
sph_cubehash_context sph_cubehash512_context
Type for a CubeHash-512 context (identical to the common context).
Definition: sph_cubehash.h:103
void sph_cubehash512_close(void *cc, void *dst)
Terminate the current CubeHash-512 computation and output the result into the provided buffer...
Definition: cubehash.c:709
void sph_cubehash384_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: cubehash.c:687
void sph_cubehash512(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: cubehash.c:702
void sph_cubehash256_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: cubehash.c:658
void sph_cubehash224_close(void *cc, void *dst)
Terminate the current CubeHash-224 computation and output the result into the provided buffer...
Definition: cubehash.c:622
void sph_cubehash512_init(void *cc)
Initialize a CubeHash-512 context.
Definition: cubehash.c:695
void sph_cubehash256_close(void *cc, void *dst)
Terminate the current CubeHash-256 computation and output the result into the provided buffer...
Definition: cubehash.c:651
sph_cubehash_context sph_cubehash384_context
Type for a CubeHash-384 context (identical to the common context).
Definition: sph_cubehash.h:98
void sph_cubehash384(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: cubehash.c:673
void sph_cubehash512_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: cubehash.c:716
sph_cubehash_context sph_cubehash224_context
Type for a CubeHash-224 context (identical to the common context).
Definition: sph_cubehash.h:88
void sph_cubehash256(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: cubehash.c:644
unsigned long sph_u32
Definition: sph_types.h:870
sph_cubehash_context sph_cubehash256_context
Type for a CubeHash-256 context (identical to the common context).
Definition: sph_cubehash.h:93
void sph_cubehash224(void *cc, const void *data, size_t len)
Process some data bytes.
Definition: cubehash.c:615
void sph_cubehash224_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: cubehash.c:629
void sph_cubehash256_init(void *cc)
Initialize a CubeHash-256 context.
Definition: cubehash.c:637
This structure is a context for CubeHash computations: it contains the intermediate values and some d...
Definition: sph_cubehash.h:77
Released under the MIT license