Simple python cgi question

Lothar Scholz llothar at web.de
Wed Sep 17 19:58:14 EDT 2003


Stephen Boulet <stephen at SPAM.theboulets.IS.BAD.net> wrote in message news:<MHGdnfoYyrH0-fWiXTWc-g at speakeasy.net>...
> First of all, I'm not sure that the easiest way to do this is with 
> python ...
> 
> I'd like to set up a web page that would accept a text file, process it 
> with a local program, and then make available generated pdf and 
> postscript files for downloading.
> 
> I'd like to limit the size of the file to be uploaded.
> 
> I have apache2 already up. Is this a job for (mod_)python?
> 
> -- Stephen

File upload size restriction is a job for apache. If you try to do
this in a CGI handler its to late to protect against "Denial Of
Service" attacks.

With modpython you can check the content-length header and abort
before you process the data.




More information about the Python-list mailing list