tsha512.h - synk - synchronize files between hosts
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
tsha512.h (519B)
---
1 #include <stdio.h>
2 #include <stddef.h>
3 #include <stdint.h>
4
5 typedef struct sha512_state {
6 uint64_t length, state[8];
7 unsigned long curlen;
8 unsigned char buf[128];
9 } sha512_state;
10
11
12 int sha512_init(sha512_state * md);
13 int sha512_process(sha512_state * md, const unsigned char *in, unsigned long inlen);
14 int sha512_done(sha512_state * md, unsigned char *hash);
15 int sha512_compare(unsigned char *h1, unsigned char *h2);
16 int sha512(FILE *stream, unsigned char *hash);
17 char *sha512_format(unsigned char *hash);