我们有一个用户输入凭据的页面。然后用户被重定向到登录页面,但我们最近发现在Safari 5.1上没有发生重定向,并报告为状态码为-1的HTTP GET:
Request URL:https://whatever.com/home.asp
Request Method:GET
Status Code:-1
Request Headers
Accept:text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Encoding:gzip, deflate
Accept-Language:en-US
Origin:https://whatever.com
Referer:https://whatever.com/logon.asp?CTAuthMode=BASIC&language=en&CT_ORIG_URL=https%3A%2F%2Fsubdomain.whatever.com%3A443%2Fyadda%2FDefault.aspx&ct_orig_uri=https%3A%2F%2Fsubdomain.whatever.com%3A443%2Fyadda%2FDefault.aspx
User-Agent:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/534.50 (KHTML, like Gecko) Version/5.1 Safari/534.50
Safari中的实际响应内容是:
<head><title>Object moved</title></head>
<body><h1>Object Moved</h1>This object may be found <a HREF="https://whatever.com/logon.asp">here</a>.</body>
HTTP/1.1 302 Object moved
Cache-Control: private
Content-Length: 167
Content-Type: text/html
Location: https://subdomain.whatever.com/yadda/Default.aspx
Server: Microsoft-IIS/7.0
X-Powered-By: ASP.NET
<head><title>Object moved</title></head>
<body><h1>Object Moved</h1>This object may be found <a HREF="https://subdomain.whatever.com/yadda/Default.aspx">here</a>.</body>
Firefox报告的内容不同:
Status: 302 Object moved
Domain: whatever.com
Size: 167 B
但是当您在Firebug中查看实际响应的HTML时,它会显示实际着陆页大小约为13.6 Kb。
有没有人在Safari中看到过这种行为?它发生在Windows(XP&amp; 7)和Mac上,所以问题似乎与Safari本身有关。我不知道这是我的Safari版本的特定错误,还是旧版本的Safari有同样的问题。
非常感谢任何解决此问题的建议。
答案 0 :(得分:0)
这是Safari 5.1的一个错误。升级到版本5.1.1修复了问题