Bug 47425
Summary: | Fails to follow HTTP 300 redirect | ||
---|---|---|---|
Product: | WebKit | Reporter: | Joe Nelson <joe> |
Component: | Page Loading | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED INVALID | ||
Severity: | Normal | CC: | annevk, mnot |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Mac | ||
OS: | OS X 10.5 |
Joe Nelson
Safari Version 5.0.2 (5533.18.5) does not follow a 300 redirect for a page served from my localhost.
HTTP details:
Request URL:http://localhost/sales?near=53711&in=Copps
Request Method:GET
Status Code:300 Multiple Choices
Request Headers
Accept:application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent:Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10_5_8; en-us) AppleWebKit/533.18.1 (KHTML, like Gecko) Version/5.0.2 Safari/533.18.5
Response Headers
Cache-Control:public
Connection:Keep-Alive
Content-Encoding:gzip
Content-Length:21
Content-Type:text/html
Date:Fri, 08 Oct 2010 17:50:20 GMT
Expires:Fri, 08 Oct 2010 23:59:59 GMT
Keep-Alive:timeout=5, max=100
Location:/sales?near=53711&in=Copps&at=43.046538+-89.324390
Server:Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.7l DAV/2 PHP/5.3.0
Vary:Accept-Encoding
X-Powered-By:PHP/5.3.0
However, Safari redirects properly when given HTTP code 302.
HTTP details:
equest URL:http://localhost/sales?near=53711&in=Copps
Request Method:GET
Status Code:302 Found
Request Headers
Accept:application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
User-Agent:Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10_5_8; en-us) AppleWebKit/533.18.1 (KHTML, like Gecko) Version/5.0.2 Safari/533.18.5
Response Headers
Cache-Control:public
Connection:Keep-Alive
Content-Encoding:gzip
Content-Length:21
Content-Type:text/html
Date:Fri, 08 Oct 2010 18:08:03 GMT
Expires:Fri, 08 Oct 2010 23:59:59 GMT
Keep-Alive:timeout=5, max=100
Location:/sales?near=53711&in=Copps&at=43.046538+-89.324390
Server:Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.7l DAV/2 PHP/5.3.0
Vary:Accept-Encoding
X-Powered-By:PHP/5.3.0
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Joe Nelson
This may not be a bug; the HTTP/1.1 specification says about code 300
"If the server has a preferred choice of representation, it SHOULD include the specific URI for that representation in the Location field; user agents MAY use the Location field value for automatic redirection. This response is cacheable unless indicated otherwise."
Firefox follows the redirect, so maybe Safari should as well?
Anne van Kesteren
A response needs to be a redirect status as per https://fetch.spec.whatwg.org/#redirect-status in order for it to redirect.