Implemented the cracker and cleanup functions