[Mongrel] Limit Request Body Size (Disallow very large File-uploads)

Stephan Wehner stephanwehner at gmail.com
Fri Jun 12 11:07:29 EDT 2009

On Fri, Jun 12, 2009 at 6:46 AM, gollomm<gollomm at gmail.com> wrote:
> Hello all,
> For the last couple of days I was trying to get my
> Apache/mod_proxy/mongrel setup to limit the size of the request body.
> The setup is as follows:
> 1.) Apache acts as a reverse proxy by facilitating mod_rewrite and mod_proxy
> 2.) Requests for non-static files are passed on to a mongrel_cluster
> 3.) We use mongrel for our Ruby on Rails application



> Note that due to some restrictions we are unable to use
> Apache/Passenger for our production deployment.
> Is there a way to tell mongrel to skip requests which exceed a certain
> limit (say 20MB) and return a 400 (Bad Request) response or the like?
> I have tried to use the LimitRequestBody directive of Apache httpd,
> but this obviously does not work, since Apache httpd passes most of
> it's requests directly on to mongrel. Thanks for your help!
> Regards,
> Severin
> _______________________________________________
> Mongrel-users mailing list
> Mongrel-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/mongrel-users

Stephan Wehner

-> http://stephan.sugarmotor.org (blog and homepage)
-> http://www.thrackle.org
-> http://www.buckmaster.ca
-> http://www.trafficlife.com
-> http://stephansmap.org -- http://blog.stephansmap.org

More information about the Mongrel-users mailing list