Ironed out decryption a bit more, still buggy. Also separated and ghetto namespaced crypt functions in separate header file.