Phil Thompson <[EMAIL PROTECTED]> writes:

> >From the code below, I'm expecting the following headers:
>   Host: www.yahoo.com
>   User-Agent: Squid 3.92
> 
> But I'm getting the following (when I use a sniffer):
>   TE: deflate,gzip;q=0.3
>   Connection: TE, close
>   Host: www.yahoo.com
>   User-Agent: Squid 3.92
> 
> Any idea how I can kill the "TE" and "Connection" headers? My use of
> "remove_header" doesn't seem to do any good...

There is actually no easy way to do that.  They are inserted by the
protocol module when it feels they are appropriate.  Can you explain
why you need them to to go away?

The "Connection: close" will go away of you pass the keep_alive option
to the LWP::UserAgent.  If you insist hard on the "TE" header to be
disabled you you try something like:

  push(@LWP::Protocol::http::EXTRA_SOCK_OPTS, SendTE => 0);

before you send your first request.

Regards,
Gisle

Reply via email to