Adding CGI-capabilities to a BaseHTTPServer/BaseHTTPRequestHandler-based webserver

Thomas Weholt 2002 at
Sun Feb 2 23:15:58 CET 2003

I got a web-server project based on BaseHTTPServer/BaseHTTPRequestHandler. I
want to add cgi-handling capabilities,  execute perl- or python-scripts and
send the generated content and http-headers to the client. How can I do this
without mixing the two RequestHandlers in the standard-library in an awful
mess? I can restrict things in a number of ways: cgi-scripts must be in a
specified folder ( cgi-bin ), must have cgi-extension etc. to make this

Any ideas?

Best regards,

More information about the Python-list mailing list