From 4ef800e87127d067ce158216f457e77145c3b393 Mon Sep 17 00:00:00 2001 From: "source@lighttpd.net" Date: Wed, 7 Apr 2010 14:57:34 +0200 Subject: [PATCH] Use HTTP/1.0 in mod_proxy for now, don't forward (Proxy-)?Connection headers --- src/modules/mod_proxy.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/modules/mod_proxy.c b/src/modules/mod_proxy.c index 42481a4..78e1ab7 100644 --- a/src/modules/mod_proxy.c +++ b/src/modules/mod_proxy.c @@ -172,7 +172,8 @@ static void proxy_send_headers(liVRequest *vr, proxy_connection *pcon) { switch (vr->request.http_version) { case LI_HTTP_VERSION_1_1: - g_string_append_len(head, CONST_STR_LEN(" HTTP/1.1\r\n")); + /* g_string_append_len(head, CONST_STR_LEN(" HTTP/1.1\r\n")); */ + g_string_append_len(head, CONST_STR_LEN(" HTTP/1.0\r\n")); break; case LI_HTTP_VERSION_1_0: default: @@ -210,6 +211,8 @@ static void proxy_send_headers(liVRequest *vr, proxy_connection *pcon) { for (iter = g_queue_peek_head_link(&vr->request.headers->entries); iter; iter = g_list_next(iter)) { header = (liHttpHeader*) iter->data; + if (li_http_header_key_is(header, CONST_STR_LEN("Connection"))) continue; + if (li_http_header_key_is(header, CONST_STR_LEN("Proxy-Connection"))) continue; g_string_append_len(head, GSTR_LEN(header->data)); g_string_append_len(head, CONST_STR_LEN("\r\n")); }