wisdom-framework / wisdom

A modular and dynamic web framework
http://wisdom-framework.org
Apache License 2.0
88 stars 42 forks source link

Request body truncated when it exceed "request.body.max.size" #535

Closed nicolas-rempulski closed 9 years ago

nicolas-rempulski commented 9 years ago

I ran into an issue regarding requests body size.

Due to request.body.max.size Wisdom may receive a truncated request. If the request body size exceed this threshold, extra content is discarded and the request is still handled by Wisdom as everything went fine.

I think if the request exceed the body size limit, Wisdom should immediatly return a Bad Request "Body size exceeding configuration limit" or throw some kind of exception.

cescoffier commented 9 years ago

I think a "413 - Body size exceeded" message would be ok. (yes there is a status code for this).