ouinet icon indicating copy to clipboard operation
ouinet copied to clipboard

Do not cache hop-by-hop HTTP response headers

Open ivilata opened this issue 6 years ago • 2 comments

As explained here, hop-by-hop response headers should not be cached, as they only refer to a single transport-level connection. Unfortunately, the list of preserved headers here includes Connection and Transfer-Encoding.

We should check, before removing Transfer-Encoding from the list, that receiving (say) a text file with Transfer-Encoding: gzip does not result in the body being stored with Gzip compression. Removing Connection is probably safe.

ivilata avatar Oct 01 '18 17:10 ivilata

I've done a little work in this regard here, but I did not think the Transfer-Encoding part as thoroughly as you did, so I may have introduced some new bugs with it :-/

inetic avatar Oct 04 '18 09:10 inetic

I saw the commit but I didn't pay attention to the presence of Transfer-Encoding so yes, that may be a bug now. We may try to ameliorate the situation by sending a TE request header, though chunked encoding should always be available… I don't know to what extent (and how) Boost handles transfer encoding, we may need to do some tests.

ivilata avatar Oct 08 '18 15:10 ivilata