doing authenticating process