#include "lib.h" void main() { /** read the file */ FILE *fp; int bytes_read; int malloc_size = 62; int line_number = 0; int j; char *string = malloc(malloc_size); char *string2 = malloc(malloc_size); char *cleartext = malloc(malloc_size); char *keys = malloc(255); char single_key; int length; fp = fopen("4.txt", "r"); if (fp == NULL) { printf("Error open file\n"); exit(1); } while (fscanf(fp, "%61c", string) != EOF) { j = decode_hex_string(string, string2); length = brute_force_single_byte_xor(string2, j, keys); if (length > 0) { printf("line %i:\n", line_number); for(j=0;j