def connectSSL(self, host, port, factory, contextFactory, timeout=30, bindAddress=None): """@see: twisted.internet.interfaces.IReactorSSL.connectSSL """ assert sslEnabled, "SSL support is not present" c = ssl.Connector(host, port, factory, contextFactory, timeout, bindAddress, self) c.connect() return c
def connectSSL(self, host, port, factory, contextFactory, timeout=30, bindAddress=None): if tls is not None: tlsFactory = tls.TLSMemoryBIOFactory(contextFactory, True, factory) return self.connectTCP(host, port, tlsFactory, timeout, bindAddress) elif ssl is not None: c = ssl.Connector( host, port, factory, contextFactory, timeout, bindAddress, self) c.connect() return c else: assert False, "SSL support is not present"