проблема с proxe_pass и заменой uri

Andrew Sitnikov sitnikov at infonet.ee
Sun Jul 12 14:06:25 MSD 2009


Hello ,

  location /secure {
        proxy_pass http://x.x.x.x:80/;
        proxy_set_header Host $subdomain;

        proxy_redirect  off;
        proxy_buffering off;

        set $cc "";

        if ($query_string ~ "cc=([^&]+)") {
            set $cc $1;
        }

        #cc_key  9670611978959046;
        #cc_data $cc;
    }

    запросы
    http://host.com/secure
    http://host.com/secure?foo=bar

    уходят на backend правильно

    2009/07/12 13:02:23 [debug] 26244#0: *8 http proxy header:
    "GET /?foo=bar HTTP/1.0
    Host: *******
    Connection: close


    но запрос
    http://host.com/secure?сс=bar

    уходит вот в таком виде
    2009/07/12 13:03:45 [debug] 26244#0: *12 http proxy header:
    "GET //secure?cc=bar HTTP/1.0
    Host: *******
    Connection: close

    проверял на 0.6.38 и 0.7.61



-- 
Best regards,
 Andrew                          mailto:sitnikov at infonet.ee






More information about the nginx-ru mailing list