Added sign in / sign out functionality with encryption