From 2930ba4f32680e245c1dae66197153abdf6502a6 Mon Sep 17 00:00:00 2001 From: Benedict Date: Tue, 21 Feb 2017 12:59:34 +0100 Subject: added lib to git and moved set2 to subdir --- lib/lib.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 lib/lib.h (limited to 'lib/lib.h') diff --git a/lib/lib.h b/lib/lib.h new file mode 100644 index 0000000..3e2a309 --- /dev/null +++ b/lib/lib.h @@ -0,0 +1,27 @@ +#ifndef __CRYPTO_LIB__ +#define __CRYPTO_LIB__ + + +#include +#include +#include +#include + +struct key_and_freq { + char key; + int hits; +}; + +void print_char_bit(char); +void xor_string(char *str1, char *key, char *result, int length_key, int length_str1); +void hex_binary_to_string(char *str1, char *result, int length); +int decode_hex_string(char *encode, char* result); +void encode_to_base64(char *encode, char *result); +int decode_base64(char *string1, char *result); +void print_base64_string(char *string); +int hamming_distance_equal_length(char *string1, char *string2, int length); +char brute_force_single_byte_xor(char *string, int length, struct key_and_freq *tmp); +int isprintable(char *string, int length); + + +#endif /* __CYRPTO_LIB__ */ -- cgit v1.2.3-70-g09d2