|Wednesday, October 16, 2002|
The socket module that is distributed with OS X's build of Python does not have SSL support. Given that I'm doing a boatload of web services development that is against a server that uses SSL, this is a serious problem (and I have filed a bug report / feature request).
Up until the last few days, my python based services client used a modified Fink based build [modified to enable SSL -- *sigh*] for my work.
Now that I'm actively integrating the Python based web services client into a Cocoa based desktop application via PyObjC, the lack of SSL support in the Apple supplied Python's socket module has become intolerable (pyobjc works fine with the fink python, but I must be able to distribute the client as a standalone tool).
So-- in a similar fashion as to the readline module-- I copied the necessary chunks of code out of the Python 2.2.1 source tree and created a setup.py that builds the socket modules.
- it requires that the existing, non-ssl, _socket.so be moved out of the way or else the default sys.path will cause the non-ssl version to override the newly built ssl version that is found in python's site-package - I had to disable IPv6 support to make it build. I believe this is the same as the "normal" build of Python, but did not confirm. In any case, the module is working well enough for me. Hopefully, it will for others to.
Source is available. To build, simply cd into the resulting directory and type sudo /usr/bin/python setup.py install.
(I have also mirrored the source to the pyobjc page in case our T1 goes down for another day.)
Requires OS X 10.2 and the latest dev tools (August patch)