Made encryption work