Got encryption working