Duplicate Vary: Accept-Encoding header

Hello,

I use nginx/1.4.4 with gunzip = on and gzip_vary = on. This leads to a
duplicate Vary Header.

gzip_vary should do nothing if the header is already present:

[email protected]:~$ curl -I
http://192.168.1.196/home.htmlhttp://213.223.158.196/home.html
HTTP/1.1 200 OK
Server: nginx/1.4.4
Date: Sun, 19 Jan 2014 11:30:59 GMT
Content-Type: text/html
Connection: keep-alive
Vary: Accept-Encoding
Vary: Accept-Encoding
Location: home.html

I have no control of the upstream server it may send a Vary header or
not,
in order to be safe I would like to use gzip_vary = on in order to
prevent
any problems here.

This issue is in standard ngx_http_header_filter_module so can anyone
suggest solution?

Thanks,
Makailol

On 20 January 2014 04:54, Makailol C. [email protected] wrote:

I use nginx/1.4.4 with gunzip = on and gzip_vary = on. This leads to a
duplicate Vary Header.
[snip]
This issue is in standard ngx_http_header_filter_module so can anyone
suggest solution?

Quick question: other than looking untidy, what’s the actual problem
that (does|can) occur when the header is duplicated?

Jonathan

I have just noticed this header duplication but I could not notice any
issue yet.

But I believe, gzip_vary should do nothing if the header is already
present. And it seems like a bug in core header_filter_module .

Makailol

On Mon, Jan 20, 2014 at 1:11 PM, Jonathan M.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs