[squid-users] Empty transfer-encoding header causes 502 response

squid3 at treenet.co.nz squid3 at treenet.co.nz
Tue Oct 25 12:39:04 UTC 2022


On 2022-10-24 13:36, Matthew H wrote:
> Hi,
> 
> I'm using Squid to proxy HTTP requests to another proxy. I can see 
> squid
> sending the request to the parent and getting a response, but it sends 
> the
> client that initiated the request a 502 Bad Gateway response.

That is correct behaviour. Squid does not know how to decode the content 
for delivery.

> 
> On closer inspection it appears the parent proxy is sending an
> empty transfer-encoding header, and this is causing Squid to send a 
> 502. Is
> there any way to ignore this?


This MUST NOT be ignored. The server has explicitly indicated that the 
response content area is encoded, but not how. Squid cannot tell where 
the boundaries of the message content are, nor how to transform it for 
delivery to the client.

Amos


More information about the squid-users mailing list