nginx page caching not working for responses with valid (rfc 1123 compliant) Expires header

Kunal Pariani kpariani at zimbra.com
Tue Mar 10 20:34:45 UTC 2015



----- Original Message -----
From: "Valentin V. Bartenev" <vbart at nginx.com>
To: nginx at nginx.org
Sent: Tuesday, March 10, 2015 1:10:09 PM
Subject: Re: nginx page caching not working for responses with valid (rfc 1123 compliant) Expires header

On Tuesday 10 March 2015 14:42:41 Kunal Pariani wrote:
> Hello, 
> I am on nginx-1.7.1 & trying to use nginx's page caching feature but run into an issue for responses with a valid 'Expires' header which seem to be in the correct rfc 1123 compliant format. Nginx somehow doesn't like it & hence doesn't cache such responses. Is this a bug ? 

>> How is RFC 1123 related to the Expires header?

My bad. I meant RFC 822 https://tools.ietf.org/html/rfc822#section-5.1

[..]
> 2015/03/10 13:58:29 [debug] 17311#0: *7 http proxy header: "Expires: Thu, 9 Apr 2015 19:58:29 GMT"

>> It's wrong, it has only one digit day.  See RFC 7231 for details:
>> https://tools.ietf.org/html/rfc7231#section-7.1.1.1

Aah didn't catch that. So looks like an issue on my upstream. Although throwing some kind of debug here (that its not rfc compliant) would have been helpful. 

Thanks
-Kunal

  wbr, Valentin V. Bartenev

_______________________________________________
nginx mailing list
nginx at nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx



More information about the nginx mailing list