Score:0

ProxyRemote with https remote-server sends GET instead of CONNECT

vn flag

My Apache httpd proxy server has an upstream proxy that only accepts HTTP CONNECT method.

According to https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxyremote

When using https, the requests are forwarded through the remote proxy using the HTTP CONNECT method.

I added the following directive to httpd.conf:

ProxyRemote "*" "https://127.0.0.1:9051"

However, when a client sends a proxy GET request it's not converted to a CONNECT request, but is passed through unchanged.

Did I misunderstand the doc? How to make Apache convert the first proxy request to a site to a CONNECT request to the upstream proxy? Here's the desired conversation with HTTP keepalive:

browser                          Apache                 Upstream
   >> GET http://site-a.com/page1
                                >> CONNECT site-a.com:80
                                       >> GET /page1
   >> GET http://site-b.com/page1
                                >> CONNECT site-b.com:80
                                       >> GET /page1
   >> GET http://site-a.com/page2
                                (reuse existing site-a connection)
                                       >> GET /page2
   >> GET http://site-b.com/page2
                                (reuse existing site-b connection)
                                       >> GET /page2

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.