[Twisted-Python] Serving web content over SSL
Can anybody provide a working, simple example of a SSL-capable web-server using Twisted ? Any hints or clues regarding installation of openssl or other required library is also interesting. Thanks in advance, Thomas
Thomas Weholt wrote:
Can anybody provide a working, simple example of a SSL-capable web-server using Twisted ? Any hints or clues regarding installation of openssl or other required library is also interesting.
twisted-web deb http://twistedmatrix.com/~moshez/apt/ ./ cvs -d :ext:cvs.twistedmatrix.com:/cvs co TwistedWebDeb Put this in /etc/twisted-web/local.d/20ssl from twisted.internet import reactor, ssl from twisted.web import static, server port = 443 ctx = ssl.DefaultOpenSSLContextFactory( '/etc/twisted-web/ssl/private/privkey.pem', '/etc/twisted-web/ssl/cert.pem') application.listenSSL(port, site, ctx) Of course, you'll need to create the SSL key with openssl.
On Wed, 2003-10-01 at 02:43, Tommi Virtanen wrote:
twisted-web
While we're on the topic, I mentioned in IRC this morning that twisted-web is now failing to load because it's running twistd with the --quiet flag, which was one of several removed in the twistd refactor. I asked whether I should post this to the tracker (meaning twistd needs to support --quiet) or whether Moshe would just fix twisted-web. I got no definitive answer. Maybe I'll get one here. -- Alex Levy WWW: http://mesozoic.geecs.org "Never let your sense of morals prevent you from doing what is right." -- Salvor Hardin, Isaac Asimov's _Foundation_
participants (3)
-
Alex Levy
-
Thomas Weholt
-
Tommi Virtanen