[Twisted-Python] strports.service, ssl and forcing client certs

Phil Mayers p.mayers at imperial.ac.uk
Fri Sep 1 08:57:12 MDT 2006


Glenn Hochberg wrote:
>> >>> import twisted.internet.ssl
>> >>> ssl.CertificateOptions()
>> Traceback (most recent call last):
>>   File "<stdin>", line 1, in ?
>> NameError: name 'ssl' is not defined

> Your import statement is not consistent with your usage.  You probably 
> wanted:
> from twisted.internet import ssl

Sorry, ignore the previous reply, I see what you're getting at now. 
However, CertificateOptions still seems to be newer than 2.4.0:


 >>> import twisted.internet.ssl
 >>> twisted.internet.ssl.CertificateOptions()
Traceback (most recent call last):
   File "<stdin>", line 1, in ?
AttributeError: 'module' object has no attribute 'CertificateOptions'
 >>> dir(twisted.internet.ssl)
['Client', 'ClientContextFactory', 'Connector', 'ContextFactory', 
'DefaultOpenSSLContextFactory', 'Port', 'SSL', 'Server', '__all__', 
'__builtins__', '__doc__', '__file__', '__name__', 'address', 'base', 
'components', 'implementedBy', 'implements', 'implementsOnly', 
'interfaces', 'log', 'socket', 'supported', 'tcp']
 >>> twisted.__version__
'2.4.0'

SVN logs look like it was added about a month after the 2.4.0 release?




More information about the Twisted-Python mailing list