summaryrefslogtreecommitdiff
path: root/src/leap/mx
diff options
context:
space:
mode:
authorIsis Lovecruft <isis@torproject.org>2013-01-31 07:36:06 +0000
committerIsis Lovecruft <isis@torproject.org>2013-01-31 07:36:06 +0000
commit2b6e5408048a458e2c7f447e44d3829cb552a737 (patch)
tree1af60d023de801e12a9e4ef4add5b29dbe96ef7e /src/leap/mx
parentfa684009c191227a6e5c05771099c956cd1985ad (diff)
Add callbacks to AliasResolverFactory, these need to be hooked to
couchdb.ConnectedCouchDB().
Diffstat (limited to 'src/leap/mx')
-rw-r--r--src/leap/mx/alias_resolver.py21
1 files changed, 19 insertions, 2 deletions
diff --git a/src/leap/mx/alias_resolver.py b/src/leap/mx/alias_resolver.py
index 4867893..44cb44d 100644
--- a/src/leap/mx/alias_resolver.py
+++ b/src/leap/mx/alias_resolver.py
@@ -221,18 +221,35 @@ class AliasResolverFactory(postfix.PostfixTCPMapDeferringDictServerFactory):
if net.checkIPaddress(addr):
self.addr = address._IPAddress('TCP', addr, int(port))
else:
- log.debug("Using default address for Postfix: 127.0.0.1:%s" % port)
+ log.msg("Using default address: 127.0.0.1:%s" % port)
self.addr = address._IPAddress('TCP', '127.0.0.1', int(port))
+ log.msg("To configure Postfix to query this alias_resolver,")
+ log.msg("you should do:")
+ log.msg(" $ postconf -e 'check_recipient_access = tcp:%s:%d"
+ % (addr, port))
+
def buildProtocol(self):
"""
- Create an instance of the :class:`PostfixAliasResolver` server.
+ Create an instance of the :class:`AliasResolver` server.
"""
proto = self.protocol()
proto.timeout = self.timeout
proto.factory = self
return proto
+ def get(self, *args, **kwargs):
+ """
+ xxx connect me to the couchdb
+ """
+ pass
+
+ def put(self, *args, **kwargs):
+ """
+ xxx connect me to the couchdb
+ """
+ pass
+
if __name__ == "__main__":