nginx proxy and Date header
Frank Liu
gfrankliu at gmail.com
Wed May 22 17:30:57 UTC 2019
Is there a reason why by default nginx doesn't pass the "Date" header from
upstream?
http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_hide_header
https://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html seems to indicate
Date header shouldn't be altered:
The HTTP-date sent in a Date header SHOULD NOT represent a date and time
subsequent to the generation of the message. It SHOULD represent the best
available approximation of the date and time of message generation, unless
the implementation has no means of generating a reasonably accurate date
and time. In theory, the date ought to represent the moment just before the
entity is generated. In practice, the date can be generated at any time
during the message origination without affecting its semantic value.
If nginx, as a proxy, changes the Date header, it may mess up the caching
model of HTTP in some pretty subtle ways in the downstream.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20190522/67cb651f/attachment.html>
More information about the nginx
mailing list