Welcome! Log In Create A New Profile

Advanced

Re: segfault in nginx 1.2.0 and 1.2.2 when serving 400 error pages via a reverse proxied host

Russell Howe
July 17, 2012 04:26AM
On 13/07/12 22:39, Maxim Dounin wrote:
> Hello!
>
>> whereby we had a config snippet which looked like:
>>
>> error_page 400 @fallback
>
> Don't do that? (c)

Yeah, we stopped doing that pretty quickly once we realised the trouble it was causing.

> The problem with 400 errors is more or less trivial and the above
> link explains it in details. There is no need to debug anything
> here, it's mostly about writing code to handle it. (Or probably
> about writing code to make the above config invalid and/or provide
> a warning.)

Yes, any of these options sounds good to me.

> Note well that handling of 400 errors isn't really good idea even
> with normal uri of an error page, not only with named locations.
> As 400 (Bad request) means bad request and you can't really trust
> anything got from a client. Unless you really understand what are
> you doing and possible implications it's much better idea to let
> nginx return builtin error page.

Agreed, although it was a little surprising that nginx was segfaulting as a result
of poor configuration choices.

I'm surprised that nginx even allows 400's to be proxied to be honest - I can't
really think of a situation where you'd want to do that, unless you were relying
on the content of the 400 response for your application.

I'll try building without optimisation and see if I can trace the source of the
segfault anyway, if only to satisfy my own curiosity.

--
Russell Howe
rhowe@moonfruit.com

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

segfault in nginx 1.2.0 and 1.2.2 when serving 400 error pages via a reverse proxied host

Russell Howe July 12, 2012 12:50PM

Re: segfault in nginx 1.2.0 and 1.2.2 when serving 400 error pages via a reverse proxied host

Maxim Dounin July 13, 2012 05:40PM

Re: segfault in nginx 1.2.0 and 1.2.2 when serving 400 error pages via a reverse proxied host

Russell Howe July 17, 2012 04:26AM

Re: segfault in nginx 1.2.0 and 1.2.2 when serving 400 error pages via a reverse proxied host

Sergey Budnevitch July 15, 2012 04:36AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 153
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