Search squid archive

Re: Keep-Alive header not being displayed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 2008-09-13 at 16:28 -0700, JL wrote:

> I understand that the keep-alive header is not suppose to be forwarded
> but is there any way to send custom headers as Alex recommended? So
> basically I want Squid to automatically send HTTP_KEEP_ALIVE = 300
> even if its not getting that information from the client or the
> server. The header just has to be there. Is that possible?

I do not think Squid3 has any configuration options that would allow you
to add custom headers to requests. 

It is possible to hard-code the extra header in Squid sources, of
course. The attached _untested_ patch adds a "Keep-Alive: 300" header,
for example.

It may be easier to add/fake a header on the origin server though, in
Apache config or as a CGI script wrapper.

HTH,

Alex.

=== modified file 'src/http.cc'
--- src/http.cc	2008-06-20 04:43:01 +0000
+++ src/http.cc	2008-09-14 23:21:51 +0000
@@ -1559,6 +1559,8 @@
             hdr_out->putStr(HDR_FRONT_END_HTTPS, "On");
     }
 
+    hdr_out->putStr(HDR_KEEP_ALIVE, "300");
+
     /* Now mangle the headers. */
     if (Config2.onoff.mangle_request_headers)
         httpHdrMangleList(hdr_out, request, ROR_REQUEST);


[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux