repo.or.cz
/
delutions.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Add phnxdeco with debian patch set (version 0.33-3).
[delutions.git]
/
tc
/
crypt.h
blob
f824c08c3600504b76beb75bbcb6524268012c21
1
2
3
typedef
struct
hash_desc
{
4
int
(*
init
)(
hash_ctx
)
5
6
int
(*
digest
)(
uint8_t
*
key
,
uint32_t
key_len
,
uint8_t
*
text
,
uint32_t
text_len
,
uint8_t
*
ret_buffer
);
//??
7
uint32_t
digest_sz
;
// ret_buffer must be at least this size.
8
uint32_t
block_sz
;
//??
9
uint16_t
ctx_sz
;
10
}
hash_t
;
11
12
13
hash_t sha1
= {
14
15
16
17
18
// sha-1
19
// digest_sz = 20
20
// block_sz = 64
21
22
// sha512
23
// digest_sz = 64
24
// block_sz = 128
25
26
// RIPMD-160
27
// digest_sz =
28
// block_sz =
29
30
// Whirlpool
31
// digest_sz = 64
32
// block_sz = 64
33
34
// HMAC
35
// sha1
36
//
37
//
38
39
// sha512
40
//
41
//
42
43
// whirlpool
44
//
45
//
46
47
// ripmd-160
48
//
49
//
50
51
// PBKDF2?