finish user register and login/logout