summaryrefslogtreecommitdiffstats
path: root/external_libs/python/zmq/auth/ioloop.py
diff options
context:
space:
mode:
authorHanoh Haim <hhaim@cisco.com>2015-08-26 15:50:06 +0300
committerHanoh Haim <hhaim@cisco.com>2015-08-26 15:50:06 +0300
commit53f0e28d7f30c7175cbb15884c309613593859d8 (patch)
treee75ff499233519baa6c50c60fa0c726da7b42e03 /external_libs/python/zmq/auth/ioloop.py
parenta628a35b10fbd38211c353f506a8c49c2cc3dd7e (diff)
parent00d6f001971b324bb9c884aaf0384a4cee076550 (diff)
Merge branch 'lib_fix'
Diffstat (limited to 'external_libs/python/zmq/auth/ioloop.py')
-rw-r--r--external_libs/python/zmq/auth/ioloop.py34
1 files changed, 0 insertions, 34 deletions
diff --git a/external_libs/python/zmq/auth/ioloop.py b/external_libs/python/zmq/auth/ioloop.py
deleted file mode 100644
index 1f448b47..00000000
--- a/external_libs/python/zmq/auth/ioloop.py
+++ /dev/null
@@ -1,34 +0,0 @@
-"""ZAP Authenticator integrated with the tornado IOLoop.
-
-.. versionadded:: 14.1
-"""
-
-# Copyright (C) PyZMQ Developers
-# Distributed under the terms of the Modified BSD License.
-
-from zmq.eventloop import ioloop, zmqstream
-from .base import Authenticator
-
-
-class IOLoopAuthenticator(Authenticator):
- """ZAP authentication for use in the tornado IOLoop"""
-
- def __init__(self, context=None, encoding='utf-8', log=None, io_loop=None):
- super(IOLoopAuthenticator, self).__init__(context)
- self.zap_stream = None
- self.io_loop = io_loop or ioloop.IOLoop.instance()
-
- def start(self):
- """Start ZAP authentication"""
- super(IOLoopAuthenticator, self).start()
- self.zap_stream = zmqstream.ZMQStream(self.zap_socket, self.io_loop)
- self.zap_stream.on_recv(self.handle_zap_message)
-
- def stop(self):
- """Stop ZAP authentication"""
- if self.zap_stream:
- self.zap_stream.close()
- self.zap_stream = None
- super(IOLoopAuthenticator, self).stop()
-
-__all__ = ['IOLoopAuthenticator']