Closed Bug 752061 Opened 12 years ago Closed 12 years ago

After POST, server sends a valid redirect to the same page (refreshes the page), but page version which is shown is the version sent to the browser before the POST.

Categories

(Core :: Networking: HTTP, defect)

12 Branch
x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 748647

People

(Reporter: vladas.dirzys, Unassigned)

Details

Attachments

(1 file)

After POST, server sends a valid redirect to the same page (refreshes the page), but page version which is shown is the version sent to the browser before the POST.

Steps to reproduce:

1) GET /index.php

2) POST /index.php -> Location: index.php

3) GET /index.php (location redirect in the post)

=====

Page shown after step 3. is the page loaded in step 1.

Related to: http://support.mozilla.org/en-US/questions/926043
This doesn't have to be a bug depending on the actual http headers.
Please post the post/get requests with full headers (add it as attachment, not as comment).
An attached Http log would be better: https://developer.mozilla.org/en/HTTP_Logging
Attached file http log
1st request/response:

2008451424[100376340]: http request [
2008451424[100376340]:   GET /admin/advert/manage-images/id/13 HTTP/1.1
2008451424[100376340]:   Host: autotop.zf
2008451424[100376340]:   User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:12.0) Gecko/20100101 Firefox/12.0
2008451424[100376340]:   Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
2008451424[100376340]:   Accept-Language: en-us,en;q=0.5
2008451424[100376340]:   Accept-Encoding: gzip, deflate
2008451424[100376340]:   Connection: keep-alive
2008451424[100376340]:   Referer: http://autotop.zf/admin/advert/list
2008451424[100376340]:   Cookie: __utma=152133161.188951318.1335994971.1336079312.1336247591.6; __utmz=152133161.1335994971.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); PHPSESSID=9n4j8l65vbq8nchdm5grsvbmn6; __utmb=152133161.3.10.1336247591; __utmc=152133161
2008451424[100376340]: ]

65961984[1003767c0]: http response [
65961984[1003767c0]:   HTTP/1.1 200 OK
65961984[1003767c0]:   Date: Sat, 05 May 2012 19:53:40 GMT
65961984[1003767c0]:   Server: Apache/2.2.21 (Unix) mod_ssl/2.2.21 OpenSSL/0.9.8r DAV/2 PHP/5.3.8 with Suhosin-Patch
65961984[1003767c0]:   X-Powered-By: PHP/5.3.8
65961984[1003767c0]:   Set-Cookie: zoneId=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT
65961984[1003767c0]:   Expires: Thu, 19 Nov 1981 08:52:00 GMT
65961984[1003767c0]:   Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
65961984[1003767c0]:   Pragma: no-cache
65961984[1003767c0]:   Keep-Alive: timeout=5, max=100
65961984[1003767c0]:   Connection: Keep-Alive
65961984[1003767c0]:   Transfer-Encoding: chunked
65961984[1003767c0]:   Content-Type: text/html
65961984[1003767c0]: ]

2nd request/response:

2008451424[100376340]: http request [
2008451424[100376340]:   POST /admin/advert/manage-images/id/13 HTTP/1.1
2008451424[100376340]:   Host: autotop.zf
2008451424[100376340]:   User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:12.0) Gecko/20100101 Firefox/12.0
2008451424[100376340]:   Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
2008451424[100376340]:   Accept-Language: en-us,en;q=0.5
2008451424[100376340]:   Accept-Encoding: gzip, deflate
2008451424[100376340]:   Connection: keep-alive
2008451424[100376340]:   Referer: http://autotop.zf/admin/advert/manage-images/id/13
2008451424[100376340]:   Cookie: __utma=152133161.188951318.1335994971.1336079312.1336247591.6; __utmz=152133161.1335994971.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); PHPSESSID=9n4j8l65vbq8nchdm5grsvbmn6; __utmb=152133161.4.10.1336247591; __utmc=152133161
2008451424[100376340]: ]

: http response [
65961984[1003767c0]:   HTTP/1.1 302 Found
65961984[1003767c0]:   Date: Sat, 05 May 2012 19:53:52 GMT
65961984[1003767c0]:   Server: Apache/2.2.21 (Unix) mod_ssl/2.2.21 OpenSSL/0.9.8r DAV/2 PHP/5.3.8 with Suhosin-Patch
65961984[1003767c0]:   X-Powered-By: PHP/5.3.8
65961984[1003767c0]:   Set-Cookie: zoneId=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT
65961984[1003767c0]:   Expires: Thu, 19 Nov 1981 08:52:00 GMT
65961984[1003767c0]:   Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
65961984[1003767c0]:   Pragma: no-cache
65961984[1003767c0]:   Location: /admin/advert/manage-images/id/13
65961984[1003767c0]:   Content-Length: 0
65961984[1003767c0]:   Keep-Alive: timeout=5, max=100
65961984[1003767c0]:   Connection: Keep-Alive
65961984[1003767c0]:   Content-Type: text/html
65961984[1003767c0]: ]

3rd request/response (redirect):
2008451424[100376340]: http request [
2008451424[100376340]:   GET /admin/advert/manage-images/id/13 HTTP/1.1
2008451424[100376340]:   Host: autotop.zf
2008451424[100376340]:   User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:12.0) Gecko/20100101 Firefox/12.0
2008451424[100376340]:   Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
2008451424[100376340]:   Accept-Language: en-us,en;q=0.5
2008451424[100376340]:   Accept-Encoding: gzip, deflate
2008451424[100376340]:   Connection: keep-alive
2008451424[100376340]:   Referer: http://autotop.zf/admin/advert/manage-images/id/13
2008451424[100376340]:   Cookie: __utma=152133161.188951318.1335994971.1336079312.1336247591.6; __utmz=152133161.1335994971.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); PHPSESSID=9n4j8l65vbq8nchdm5grsvbmn6; __utmb=152133161.4.10.1336247591; __utmc=152133161
2008451424[100376340]: ]

65961984[1003767c0]: http response [
65961984[1003767c0]:   HTTP/1.1 200 OK
65961984[1003767c0]:   Date: Sat, 05 May 2012 19:53:52 GMT
65961984[1003767c0]:   Server: Apache/2.2.21 (Unix) mod_ssl/2.2.21 OpenSSL/0.9.8r DAV/2 PHP/5.3.8 with Suhosin-Patch
65961984[1003767c0]:   X-Powered-By: PHP/5.3.8
65961984[1003767c0]:   Set-Cookie: zoneId=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT
65961984[1003767c0]:   Expires: Thu, 19 Nov 1981 08:52:00 GMT
65961984[1003767c0]:   Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
65961984[1003767c0]:   Pragma: no-cache
65961984[1003767c0]:   Keep-Alive: timeout=5, max=99
65961984[1003767c0]:   Connection: Keep-Alive
65961984[1003767c0]:   Transfer-Encoding: chunked
65961984[1003767c0]:   Content-Type: text/html
65961984[1003767c0]: ]
I don't see that you get cached content.

After the 302 i see this in the log :
2008451424[100376340]: redirecting to: /admin/advert/manage-images/id/13 [redirection-limit=20]
2008451424[100376340]: uri=http://autotop.zf/admin/advert/manage-images/id/13
2008451424[100376340]: Must validate since response contains 'no-cache' header

and the resource is fetched again ( "3rd request/response (redirect)" in your comment)
Component: General → Networking: HTTP
Product: Firefox → Core
QA Contact: general → networking.http
Reporter: Could you test a nightly build that includes the fix for bug 748647 ?
it works with the nightly build
I'm not 100% sure that this is a dupe of bug 748647 but the chance is very high.
Thanks for the report and for your test with the nightly !
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: