Closed GoogleCodeExporter closed 8 years ago
Hello !
Thank you very much for the report, we will investigate quickly.
Unfortunately, I was not able to reproduce it with a quick testing session,
hope I will have some spare time tonight to play with it ;)
Could you please try to remove naxsi from configuration and see if it happens
again ?
(As I don't see any reference to naxsi in the stacktrace, I would dare to
suspect nginx itself)
If you are around, could you join #naxsi on freenode so we can discuss the
potential issue ?
Best regards,
Original comment by ori...@gmail.com
on 16 Oct 2012 at 2:02
When I turned off the naxsi (comment out one "include" in nginx.conf and
sites-enabled/site) the error does not occur.
I have just checked another configuration: Naxsi on (learning mode), turned off
the proxy to the backend application (nginx serving only a few static files),
and also the problem does NOT occur (I've generated about 1k queries and see
still no error).
So the problem seems to be related to naxsi + proxy connections. Maybe I'm
wrong, but think that my configuration of reverse-proxy function is correct..
Although it is little complicated.
I do not use irc and I'm not members of freenode, but tomorrow or the day after
tomorrow I'll try to find the time to change that.
Best regards,
Jack
Original comment by ja.luc...@zhr.pl
on 16 Oct 2012 at 2:44
Thanks for that quick answer, I'll try to make some tries in this direction.
Nice finding by the way, don't know yet who's to blame : naxsi or nginx, maybe
both ;)
Original comment by ori...@gmail.com
on 16 Oct 2012 at 2:58
I am experiencing the same problem. I am using nginx + naxsi in a reverse proxy
configuration.
The problem occurs when naxsi's rules are being hit. If I disable naxsi or
whitelist all the rules the problem goes away.
Original comment by carlos.l...@gmail.com
on 24 Oct 2012 at 5:20
[deleted comment]
Looks like I found a workaround.
The transfer of three "proxy_set_header" directives from global "server"
section to the "location /" caused the errors no longer appear:
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Url-Scheme $scheme;
Tested with 5k queries "blocked" by naxsi in LearningMode, and is OK. In normal
(block) mode still allways work correctly too.
I have not found a reason for my original configuration would be flawed, but it
seems that some of the variables in the header should be modified only for
proxy section (section "location /" directing to @upstream) and should not be
modified for local files. Perhaps it is more correct configuration, but it
doesn't explain, why without naxsi it work good, and with naxsi caused "worker
process # exited on signal 11".
Any idea to confirm this in a different way than the experimentally? Any
sources about correct place for proxy_set_header directives?
On the internet (http://lmgtfy.com/?q=proxy_set_header+nginx+signal+11) I saw
that on BSD with other modules (not naxsi) people have also had a problem with
"exited on signal 11" with "proxy_set_header" in "location", so I'm afraid that
I have not found a solution, but only a workaround.
Below part of my current configuration.
Best regards,
Jack
#########################
/etc/nginx/sites-enabled/site
server {
(..)
proxy_set_header X-Forwarded-Proto https;
proxy_set_header Host $host;
proxy_redirect off;
#proxy_set_header X-Real-IP $remote_addr;
#proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
#proxy_set_header X-Url-Scheme $scheme;
location / {
include /etc/nginx/naxsi_my.rules;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Url-Scheme $scheme;
try_files $uri @upstream;
}
(..)
}
######################################
Original comment by ja.luc...@zhr.pl
on 25 Oct 2012 at 9:12
Hello,
I've just commited a patch that should fix this issue.
Could you try it and tell us if everything is working fine ?
Original comment by sephirot...@gmail.com
on 26 Oct 2012 at 9:17
It seems to have solved the problem. I've been testing for several hours now
and not a single crash :)
Thank you!
Best regards,
Carlos
Original comment by carlos.l...@gmail.com
on 26 Oct 2012 at 4:45
Original comment by sephirot...@gmail.com
on 26 Oct 2012 at 4:48
Original issue reported on code.google.com by
ja.luc...@zhr.pl
on 16 Oct 2012 at 1:48Attachments: