httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 23550] New: - mod_mem_cache replaces HTTP Status 301 with 200
Date Wed, 01 Oct 2003 17:50:14 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23550>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23550

mod_mem_cache replaces HTTP Status 301 with 200

           Summary: mod_mem_cache replaces HTTP Status 301 with 200
           Product: Apache httpd-2.0
           Version: 2.0.47
          Platform: PC
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: Major
          Priority: Other
         Component: mod_cache
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: lengerkeh@sixt.de


When apache is configured as a reverse proxy with mod_mem_cache enabled, it will
cache 301 responses from the backend. Whether this behaviour is desireable or
not, I really do not know, mod_disk_cache for example will not cache these
responses because mod_disk_cache does not cache responses without Content-Length
header set.

Now, when we hit the memory-cached object, mod_mem_cache returns the original
301 response with a replaced HTTP status of 200. This causes clients to not
follow the redirect.

I will try to illustrate this:

request:
    GET /foo HTTP/1.1
    Host: www.foo.tld

1st response, before caching:
    HTTP/1.1 301 Moved Permanently
    Location: http://www.foo.tld/foo/

subsequent response, on same request:
    HTTP/1.1 200 OK
    Location: http://www.foo.tld/foo/

=> Client ignores Location: header

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message