411 Length Required error

Igor Sysoev is at rambler-co.ru
Mon Dec 1 17:38:31 MSK 2008

On Tue, Dec 02, 2008 at 01:34:36AM +1100, Dave Cheney wrote:

> It sounds like that browser is not spec compliant. You may have to  
> fake a body by sending a form encoded parameter just to generate a  
> dummy body.

It seems that Apache allowed always such requests (POSTs without
Content-Length). I'm not sure should I add this ?

> On 29/11/2008, at 1:15 PM, Rocky Zhang <lists at ruby-forum.com> wrote:
> >Unfortunately I found that when I use POST method to request an AJAX
> >function, the browser sends a request with neither body nor
> >"Content-Length: 0".
> >
> >Igor Sysoev wrote:
> >>On Fri, Nov 28, 2008 at 04:26:29PM +0100, Rocky Zhang wrote:
> >>
> >>>Yes. If there is no chunked body, it works fine. If there is, we  
> >>>could
> >>>check its request header information and close it if we haven't
> >>>implemented chunked body feature. Could we patch it?
> >>
> >>I do not understand what yuo want to get.
> >>
> >>Currently nginx does not support a chunked request body and returns
> >>411 error code for such requests.
> >>
> >>Also nginx returns the 411 error if a POST/PUT request has no
> >>"Content-Length".
> >>If the request has no body, then it must send "Content-Length: 0".

Igor Sysoev

More information about the nginx mailing list