Initial commit.
[hondza-y36pr2.git] / crc32 / crc32.h
blobccfc82a6899afb3634cff14fee499ec0735b1ba2
1 /*
2 * This is a tiny implementation of CRC-32.
4 * Written by Solar Designer <solar at openwall.com> in 1998, revised in
5 * 2005 for use in John the Ripper, and placed in the public domain.
6 * There's absolutely no warranty.
7 */
9 #ifndef _JOHN_CRC32_H
10 #define _JOHN_CRC32_H
12 typedef unsigned int crc32_t;
14 extern void crc32_init(crc32_t *value);
15 #define crc32_start crc32_init
17 extern void crc32_update(crc32_t *value, const void *data, const unsigned int size);
18 #define crc32_process crc32_update
20 extern void crc32_final(crc32_t *value, unsigned char *out);
21 #define crc32_finish
23 extern void crc32_final2(crc32_t *value, unsigned char *out);
24 #define crc32_finish2
26 #endif