Пример #1
0
 def __init__(self, serverName, serverPort, proxyPort, trainer):
     proxyArgs = (serverName, serverPort, trainer)
     Dibbler.Listener.__init__(self, proxyPort, BayesSMTPProxy, proxyArgs)
     print "SMTP Listener on port %s is proxying %s:%d" % (_addressPortStr(proxyPort), serverName, serverPort)
Пример #2
0
 def __init__(self, serverName, serverPort, proxyPort, trainer):
     proxyArgs = (serverName, serverPort, trainer)
     Dibbler.Listener.__init__(self, proxyPort, BayesSMTPProxy, proxyArgs)
     print 'SMTP Listener on port %s is proxying %s:%d' % \
            (_addressPortStr(proxyPort), serverName, serverPort)
Пример #3
0
 def __init__(self, serverName, serverPort, proxyPort, spam, unsure):
     proxyArgs = (serverName, serverPort, spam, unsure)
     Dibbler.Listener.__init__(self, proxyPort, RedirectingBayesProxy,
                               proxyArgs)
     print 'Listener on port %s is proxying %s:%d' % \
            (_addressPortStr(proxyPort), serverName, serverPort)
Пример #4
0
 def __init__(self, serverName, serverPort, proxyPort, spam, unsure):
     proxyArgs = (serverName, serverPort, spam, unsure)
     Dibbler.Listener.__init__(self, proxyPort, RedirectingBayesProxy,
                               proxyArgs)
     print 'Listener on port %s is proxying %s:%d' % \
            (_addressPortStr(proxyPort), serverName, serverPort)
Пример #5
0
        return response

class  RedirectingBayesProxyListener (Dibbler.Listener) :
	"""Listens for incoming email client connections and spins off
    RedirectingBayesProxy objects to serve them.
    """
	    def __init__(self, serverName, serverPort, proxyPort, spam, unsure):

        proxyArgs = (serverName, serverPort, spam, unsure)

        Dibbler.Listener.__init__(self, proxyPort, RedirectingBayesProxy,
                                  proxyArgs)

        print('Listener on port %s is proxying %s:%d' % \
               (_addressPortStr(proxyPort), serverName, serverPort))

class  IMAPState (State) :
	def __init__(self):

        State.__init__(self)

        self.totalIMAPSessions = 0

        self.activeIMAPSessions = 0
 def createWorkers(self):

        """There aren't many workers in an IMAP State - most of the
        work is done elsewhere.  We do need to load the classifier,
        though, and build the status strings."""