Vishwas Bm
December 14, 2022 05:04AM
Thanks for the response.
What happens when content-length provided in request is greater than the
post body size?
How does nginx handle this case ?
Does it fail with 400 ?

Also how is the truncation/padding done in case of lesser or higher content
length ?

Regards,
Vishwas


On Sun, Dec 11, 2022, 01:52 Maxim Dounin <mdounin@mdounin.ru> wrote:

> Hello!
>
> On Sat, Dec 10, 2022 at 12:03:04PM +0530, Vishwas Bm wrote:
>
> > I am using nginx 1.22.1 and for some requests from client, I am seeing
> > below 400 bad request errors.
> >
> > Below are some error messages:
> >
> > "log":{"message":"225#225: *8413018 client sent invalid method while
> > reading client pipelined request line, client: 10.178.111.18, server: _,
> > request: 'ocality': 'ny','mode': 'proactive','type': 'HSS','service':
> > {'type': 'str','kspaces': [],'prtl': 'nds','traffic_type':
> > 'rst'}}<92>¹ÏNfGå<8d>¹Âø^FÍ^XÌb<9d>jó<91>¸<81>Ô|]\P0Q^P'^\BÝ<93>ÛT±R'"}}
> >
> > {"[ocality\x22: \x22NY\x22,\x22mode\x22: \x22proactive\x22,\x22type\x22:
> > \x22TSS\x22,\x22service\x22: {\x22type\x22:
> > \x22storage\x22,\x22keyspaces\x22: [],\x22protocol\x22:
> > \x22nds\x22,\x22traffic_type\x22:
> >
> \x22rts\x22}}\x92\xB9\xCFNfG\xE5\x8D\xB9\xC2\xF8\x06\xCD\x18\xCCb\x9Dj\xF3\x91\xB8\x81\xD4|]\x5CP0Q\x10\x22\x1CB\xDD\x93\xDBT\xB1R]
> > 400 150 [-] [-] 0 10.577 [] - - - - b1d1932b3a43ced62c2ebfa80d435092"}}
> >
> >
> > Is there any way to decode this or Is the garbled data itself causing
> nginx
> > to say 400 errors ?
> > Can someone help me with this ?
>
> >From the error message it looks like the client incorrectly
> specified Content-Length in the request, so the rest of the
> request body not covered by Content-Length is interpreted as
> another request (and rejected by nginx, because obviously enough
> it is not a valid HTTP request).
>
> --
> Maxim Dounin
> http://mdounin.ru/
> _______________________________________________
> nginx mailing list -- nginx@nginx.org
> To unsubscribe send an email to nginx-leave@nginx.org
>
_______________________________________________
nginx mailing list
nginx@nginx.org
https://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

nginx 400 bad request

Vishwas Bm December 10, 2022 01:36AM

Re: nginx 400 bad request

Maxim Dounin December 10, 2022 03:24PM

Re: nginx 400 bad request

Vishwas Bm December 14, 2022 05:04AM

Re: nginx 400 bad request

Maxim Dounin December 14, 2022 06:52PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 201
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready