Register, signing and sign out working with sessions