Commit 63425e8e authored by Sander Striker's avatar Sander Striker
Browse files

Also translate Destination headers when ProxyPassReverse'd

* modules\proxy\mod_proxy_http.c

  (process_proxy_header): reverse map Destination header.

  NOTE: This is some darn nasty looking code...


* modules\proxy\ajp_header.c

  (ajp_unmarshal_response): reverse map Destination header.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@151246 13f79535-47bb-0310-9956-ffa450edef68
parent be9fc2ba
Loading
Loading
Loading
Loading
+4 −2
Changes for modules/proxy/ajp_header.c: 4 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -535,10 +535,12 @@ static apr_status_t ajp_unmarshal_response(ajp_msg_t *msg,
        if (!strcasecmp(stringname, "Set-Cookie")) {
            value = ap_proxy_cookie_reverse_map(r, conf, value);
        }
        /* Location, Content-Location and URI need additional processing */
        /* Location, Content-Location, URI and Destination need additional
         * processing */
        else if (!strcasecmp(stringname, "Location")
                 || !strcasecmp(stringname, "Content-Location")
                 || !strcasecmp(stringname, "URI"))
                 || !strcasecmp(stringname, "URI")
                 || !strcasecmp(stringname, "Destination"))
        {
          value = ap_proxy_location_reverse_map(r, conf, value);
        }
+1 −0
Changes for modules/proxy/mod_proxy_http.c: 1 added line, 0 removed lines.
Original line number Diff line number Diff line
@@ -849,6 +849,7 @@ static void process_proxy_header(request_rec* r, proxy_server_conf* c,
        { "Location", ap_proxy_location_reverse_map } ,
        { "Content-Location", ap_proxy_location_reverse_map } ,
        { "URI", ap_proxy_location_reverse_map } ,
        { "Destination", ap_proxy_location_reverse_map } ,
        { "Set-Cookie", ap_proxy_cookie_reverse_map } ,
        { NULL, NULL }
    } ;