Implement login.