def __get_xsrf_server(self):
        rpc_server = GetRpcServer(**self.__rpc_server_args)
        if not rpc_server.authenticated:
            rpc_server._Authenticate()
        try:
            xsrf_token = rpc_server.Send('/' + utils.XSRF_TOKEN,
                                         extra_headers=utils.XSRF_HEADERS)
        except urllib2.HTTPError:
            xsrf_token = None
        return rpc_server, xsrf_token
Gets an authenticated RPC server and XSRF token for API calls.
dataset/ETHPy150Open googlearchive/git-rv/submit.py/SubmitAction.__get_xsrf_server