Summary: | Konqueror does not send If-None-Match & If-Modified-Since in response to ETag & Last-Modified | ||
---|---|---|---|
Product: | [Frameworks and Libraries] kio | Reporter: | anze <anzenews> |
Component: | http | Assignee: | kdelibs bugs <kdelibs-bugs> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | CC: | adawit, patrickdk |
Priority: | NOR | ||
Version: | 4.2.0 | ||
Target Milestone: | --- | ||
Platform: | Debian stable | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
anze
2008-02-17 02:20:20 UTC
Update: the page is not even saved in cache with above headers. Without Cache-Control and Pragma headers the page is saved in cache, but Konqueror still doesn't use If-None-Match when checking for a new copy. I do not see in the w3c http 1.1 definition (http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html) the Cache-Control: post-check=0, pre-check=0. Anyway, if the content expires only 1 second after it is sent by the server, it should be asked again by the browser (after 1 second). I have this same issue, using 4.2.4 on ubuntu. Firefox has no issues for both of the samples below, sending If-Modified-Since, or If-None-Exist on it's requests. So with firefox/ie I get 304 and no content, but with kronqueror I get the whole picture again. The point of the Expires/Cache-Control is to allow content caching but still verify with the webserver so I know if it's been updated and to check permissions. GET /showpic.php?UID=22337 HTTP/1.1 Host: images.digitalexpressions.nu Connection: Keep-Alive User-Agent: Mozilla/5.0 (compatible; Konqueror/4.2; Linux) KHTML/4.2.4 (like Gecko) Referer: http://www.digitalexpressions.nu:80/viewdiary.php?DID=22179 Accept: image/png, image/jpeg, video/x-mng, image/jp2, image/gif;q=0.5,*/*;q=0.1 Accept-Encoding: x-gzip, x-deflate, gzip, deflate Accept-Charset: utf-8, utf-8;q=0.5, *;q=0.5 Accept-Language: en-US, en Cookie: DESID=f74c233873432f7d6c86a428620b4732 HTTP/1.1 200 OK X-Powered-By: PHP/4.4.3 Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Cache-Control: no-cache, must-revalidate, post-check=864000, pre-check=864000 Last-Modified: Thu, 28 May 2009 23:52:24 GMT Content-Type: image/jpeg Content-Length: 50123 Date: Sat, 03 Oct 2009 18:15:34 GMT Server: lighttpd/1.4.23 GET /showpic.php?UID=22337 HTTP/1.1 Host: images.digitalexpressions.nu Connection: Keep-Alive User-Agent: Mozilla/5.0 (compatible; Konqueror/4.2; Linux) KHTML/4.2.4 (like Gecko) Referer: http://www.digitalexpressions.nu:80/viewdiary.php?DID=22179 Accept: image/png, image/jpeg, video/x-mng, image/jp2, image/gif;q=0.5,*/*;q=0.1 Accept-Encoding: x-gzip, x-deflate, gzip, deflate Accept-Charset: utf-8, utf-8;q=0.5, *;q=0.5 Accept-Language: en-US, en Cookie: DESID=f74c233873432f7d6c86a428620b4732 HTTP/1.1 200 OK X-Powered-By: PHP/4.4.3 Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Cache-Control: no-cache, must-revalidate, post-check=864000, pre-check=864000 Last-Modified: Thu, 28 May 2009 23:52:24 GMT Content-Type: image/jpeg Content-Length: 50123 Date: Sat, 03 Oct 2009 18:15:34 GMT (In reply to comment #3) > I have this same issue, using 4.2.4 on ubuntu. > > Firefox has no issues for both of the samples below, sending If-Modified-Since, > or If-None-Exist on it's requests. So with firefox/ie I get 304 and no content, > but with kronqueror I get the whole picture again. > The point of the Expires/Cache-Control is to allow content caching but still > verify with the webserver so I know if it's been updated and to check > permissions. > > GET /showpic.php?UID=22337 HTTP/1.1 > Host: images.digitalexpressions.nu > Connection: Keep-Alive > User-Agent: Mozilla/5.0 (compatible; Konqueror/4.2; Linux) KHTML/4.2.4 (like > Gecko) > Referer: http://www.digitalexpressions.nu:80/viewdiary.php?DID=22179 > Accept: image/png, image/jpeg, video/x-mng, image/jp2, > image/gif;q=0.5,*/*;q=0.1 > Accept-Encoding: x-gzip, x-deflate, gzip, deflate > Accept-Charset: utf-8, utf-8;q=0.5, *;q=0.5 > Accept-Language: en-US, en > Cookie: DESID=f74c233873432f7d6c86a428620b4732 > > HTTP/1.1 200 OK > X-Powered-By: PHP/4.4.3 > Expires: Thu, 19 Nov 1981 08:52:00 GMT > Pragma: no-cache > Cache-Control: no-cache, must-revalidate, post-check=864000, pre-check=864000 > Last-Modified: Thu, 28 May 2009 23:52:24 GMT > Content-Type: image/jpeg > Content-Length: 50123 > Date: Sat, 03 Oct 2009 18:15:34 GMT > Server: lighttpd/1.4.23 > > GET /showpic.php?UID=22337 HTTP/1.1 > Host: images.digitalexpressions.nu > Connection: Keep-Alive > User-Agent: Mozilla/5.0 (compatible; Konqueror/4.2; Linux) KHTML/4.2.4 (like > Gecko) > Referer: http://www.digitalexpressions.nu:80/viewdiary.php?DID=22179 > Accept: image/png, image/jpeg, video/x-mng, image/jp2, > image/gif;q=0.5,*/*;q=0.1 > Accept-Encoding: x-gzip, x-deflate, gzip, deflate > Accept-Charset: utf-8, utf-8;q=0.5, *;q=0.5 > Accept-Language: en-US, en > Cookie: DESID=f74c233873432f7d6c86a428620b4732 > > HTTP/1.1 200 OK > X-Powered-By: PHP/4.4.3 > Expires: Thu, 19 Nov 1981 08:52:00 GMT > Pragma: no-cache > Cache-Control: no-cache, must-revalidate, post-check=864000, pre-check=864000 > Last-Modified: Thu, 28 May 2009 23:52:24 GMT > Content-Type: image/jpeg > Content-Length: 50123 > Date: Sat, 03 Oct 2009 18:15:34 GMT If Firefox caches such content, then you need to report that to them. There is no way it should cache a content that includes not one, not two, but three header directives telling you not to cache the content! Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Cache-Control: no-cache, must-revalidate, post-check=864000, pre-check=864000 |