Merge pull request #6022 from lollipopman/connect-proxy-host-header Set Host Header to match CONNECT authority target
diff --git a/src/transports/httpclient.c b/src/transports/httpclient.c
index d40c162..5b8949a 100644
--- a/src/transports/httpclient.c
+++ b/src/transports/httpclient.c
@@ -670,7 +670,7 @@ static int generate_connect_request(
git_buf_puts(buf, "\r\n");
git_buf_puts(buf, "Host: ");
- puts_host_and_port(buf, &client->proxy.url, false);
+ puts_host_and_port(buf, &client->server.url, true);
git_buf_puts(buf, "\r\n");
if ((error = apply_proxy_credentials(buf, client, request) < 0))