[Webkit-unassigned] [Bug 242931] New: refreshing a POSTed page shows multiple warning alerts when the POST refresh has redirections
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Jul 19 20:01:05 PDT 2022
https://bugs.webkit.org/show_bug.cgi?id=242931
Bug ID: 242931
Summary: refreshing a POSTed page shows multiple warning alerts
when the POST refresh has redirections
Product: WebKit
Version: Safari 15
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: History
Assignee: webkit-unassigned at lists.webkit.org
Reporter: junytse at gmail.com
Created attachment 461030
--> https://bugs.webkit.org/attachment.cgi?id=461030&action=review
A NodeJS script to run a web server to demo the issue
When the current page comes from a POST request and we refresh the page, an alert "Are you sure you want to send a form again?" will be shown.
However, if we click "Yes" and the resent POST request happens to have redirections (for example, login is requested), each of the redirected page will trigger the "Are you sure you want to send a form again?" alert, even it is a GET request.
To reproduce:
1. use attached nodejs file reproduce.js, run `node reproduce.js`.
2. use Safari to visit http://localhost:8000/
3. click "do POST" button in the page, it submits a POST form, renders a new page http://localhost:8000/do,
4. refresh the web page, "Are you sure you want to send a form again?" alert is shown, click "Yes" to resend the POST request, the response is a 302 redirection to http://localhost:8000/redirect
5. issue here: subsequent redirect request "GET http://localhost:8000/redirect" also trigger "Are you sure you want to send a form again?" alert.
Note that Safari dev inspector cannot show the redirections in step #4 #5, you may need tool like Fiddler/Charles.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20220720/019c0be1/attachment.htm>
More information about the webkit-unassigned
mailing list