'Start the Authentication Agent thread task'

def run(self):

    self.authenticator.start()
    self.started.set()
    zap = self.authenticator.zap_socket
    poller = zmq.Poller()
    poller.register(self.pipe, zmq.POLLIN)
    poller.register(zap, zmq.POLLIN)
    while True:
        try:
            socks = dict(poller.poll())
        except zmq.ZMQError:
            break
        if ((self.pipe in socks) and (socks[self.pipe] == zmq.POLLIN)):
            terminate = self._handle_pipe()
            if terminate:
                break
        if ((zap in socks) and (socks[zap] == zmq.POLLIN)):
            self._handle_zap()
    self.pipe.close()
    self.authenticator.stop()
