nginx 0.7.53: port_in_redirect ignored
Igor Sysoev
is at rambler-co.ru
Tue Apr 28 10:19:33 MSD 2009
On Mon, Apr 27, 2009 at 10:40:37PM -0400, Floren Munteanu wrote:
> Hi all,
>
> I upgraded this morning to 0.7.53 version, thanks Igor. I have an issue
> with the port_in_redirect set to off, it would not hide the actual port.
> I run nginx on a CentOS 5.3 x64 machine, no apache installed or other
> fancy software beside PHP 5.2.9 and MySQL 5.1.33. It is set as a
> proxy_pass on ports 8000 and 8001.
>
> I tried to setup port_in_redirect off in http, server and location. Same
> results.
> Right now it is set at http level. Try this:
> Type in your browser: axivo.com, it will bring you to the right site.
> Then, try axivo.com/test, it will direct you to an URL with port on
> it... In root and /test dir are 2 plain index.html files.
>
> Does anyone else have any issues with it? If you don't please let me
> know your setup.
The attached patch fixes the bug appeared in 0.7.39.
--
Igor Sysoev
http://sysoev.ru/en/
-------------- next part --------------
Index: src/http/ngx_http_header_filter_module.c
===================================================================
--- src/http/ngx_http_header_filter_module.c (revision 2082)
+++ src/http/ngx_http_header_filter_module.c (working copy)
@@ -357,6 +357,9 @@
else
#endif
port = (port == 80) ? 0 : port;
+
+ } else {
+ port = 0;
}
if (port) {
More information about the nginx
mailing list