Added encryption code to fork.