Blame SOURCES/httpd-2.4.6-r1573626.patch

008793
--- a/modules/proxy/mod_proxy.c	2014/03/03 17:28:10	1573625
008793
+++ b/modules/proxy/mod_proxy.c	2014/03/03 17:28:17	1573626
008793
@@ -927,8 +927,25 @@
008793
     struct dirconn_entry *list = (struct dirconn_entry *)conf->dirconn->elts;
008793
 
008793
     /* is this for us? */
008793
-    if (!r->proxyreq || !r->filename || strncmp(r->filename, "proxy:", 6) != 0)
008793
+    if (!r->filename) {
008793
         return DECLINED;
008793
+    }
008793
+
008793
+    if (!r->proxyreq) {
008793
+        /* We may have forced the proxy handler via config or .htaccess */
008793
+        if (r->handler &&
008793
+            strncmp(r->handler, "proxy:", 6) == 0 &&
008793
+            strncmp(r->filename, "proxy:", 6) != 0) {
008793
+            r->proxyreq = PROXYREQ_REVERSE;
008793
+            r->filename = apr_pstrcat(r->pool, r->handler, r->filename, NULL);
008793
+            apr_table_setn(r->notes, "rewrite-proxy", "1");
008793
+        }
008793
+        else {
008793
+            return DECLINED;
008793
+        }
008793
+    } else if (strncmp(r->filename, "proxy:", 6) != 0) {
008793
+        return DECLINED;
008793
+    }
008793
 
008793
     /* handle max-forwards / OPTIONS / TRACE */
008793
     if ((str = apr_table_get(r->headers_in, "Max-Forwards"))) {