]> git.ozlabs.org Git - ccan/blob - ccan/antithread/examples/md5_finder.h
display a-z index for module search and some fixes
[ccan] / ccan / antithread / examples / md5_finder.h
1 #ifndef MD5_FINDER_H
2 #define MD5_FINDER_H
3 #include <stdint.h>
4 #include <stdbool.h>
5
6 #define MD5_HASH_WORDS          4
7
8 #define u32 uint32_t
9 #define u64 uint64_t
10 #define u8 uint8_t
11
12 struct md5_search {
13         u32 mask[MD5_HASH_WORDS];
14         u32 md5[MD5_HASH_WORDS];
15         bool success;
16         unsigned int num_tries;
17         unsigned int num_bytes;
18         u8 *pattern;
19 };
20
21 /* Child writes this value initially to say "ready". */
22 #define INITIAL_POINTER ((void *)1)
23
24 #endif /* MD5_FINDER_H */