newbie ?s

V

Venkat B

Hi folks,

I'm looking build a CGI-capable SSL-enabled web-server around Python 2.4 on
Linux.
It is to handle ~25 hits possibly arriving "at once". Content is non-static
and built by the execution of py cgi-scripts talking to a few backend
processes.

1) I was wondering if anyone has opinions on the ability of CGIHTTPServer (a
forking variant) to be able to handle this.
2) If so, would something like pyOpenSSL be useful to make such a webserver
SSL-enabled.

I checked out John Goerzen's book: Foundations of Python Network Programming
(ISBN 1590593715) and searched around. While I found how one can write py
scripts that could communicate with SSL-enabled webservers, tips on building
SSL-enabled webservers isn't obvious.

I was hoping to build a cleaner solution around the CGIHTTPServer variant
instead of say something like mini-httpd/OpenSSL/Python. I'd appreciate any
pointers.

TIA,
/venkat
 
P

Paul Rubin

Venkat B said:
I'm looking build a CGI-capable SSL-enabled web-server around Python 2.4 on
Linux.
It is to handle ~25 hits possibly arriving "at once". Content is non-static
and built by the execution of py cgi-scripts talking to a few backend
processes.

1) I was wondering if anyone has opinions on the ability of CGIHTTPServer (a
forking variant) to be able to handle this.

Why not use apache?
2) If so, would something like pyOpenSSL be useful to make such a webserver
SSL-enabled.

I haven't used pyOpenSSL but I don't see any other way to do it. Well
maybe mxCrypto which I haven't used either. The SSL socket library
doesn't understand certificates.
 
P

Peter Hansen

Venkat said:
Hi folks,

I'm looking build a CGI-capable SSL-enabled web-server around Python 2.4 on
Linux.
It is to handle ~25 hits possibly arriving "at once". Content is non-static
and built by the execution of py cgi-scripts talking to a few backend
processes.

Twisted? I'm not sure what, if anything, it has in the
way of CGI support, but that could probably be hacked
on pretty darn quick if you needed. At least Twisted
has support for server-side SSL (i.e. it can deal with
certificates).

-Peter
 
S

Steve Holden

Venkat said:
Hi folks,

I'm looking build a CGI-capable SSL-enabled web-server around Python 2.4 on
Linux.
It is to handle ~25 hits possibly arriving "at once". Content is non-static
and built by the execution of py cgi-scripts talking to a few backend
processes.

1) I was wondering if anyone has opinions on the ability of CGIHTTPServer (a
forking variant) to be able to handle this.

I wouldn't even consider it. The *HTTPServer modules aren't really
intended to be much beyond a proof-of-concept, IMHO. Certainly you'd be
likely to stress the system having 25 requests arrive in a bunch, though
a modern computer would probably handle it.
2) If so, would something like pyOpenSSL be useful to make such a webserver
SSL-enabled.
There is a *lot* to do to SSL-enable a server. Since you advertise
yourself as a newbie, I'd suggest there were better places to focus your
efforts.
I checked out John Goerzen's book: Foundations of Python Network Programming
(ISBN 1590593715) and searched around. While I found how one can write py
scripts that could communicate with SSL-enabled webservers, tips on building
SSL-enabled webservers isn't obvious.

I was hoping to build a cleaner solution around the CGIHTTPServer variant
instead of say something like mini-httpd/OpenSSL/Python. I'd appreciate any
pointers.
I believe the Twisted package may be your best alternative, though this
is at best hearsay since I am not (yet) an active user.

regards
Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,190
Latest member
ClayE7480

Latest Threads

Top