Let Origin header honor referrer policy for non CORS request#908
Let Origin header honor referrer policy for non CORS request#908annevk merged 7 commits intowhatwg:masterfrom
Conversation
|
I think we should only take this into account when setting the Also, for some cross-origin navigation requests the |
Okay, it's fair.
For form POST navigation, Was I missing something? |
|
Sorry for naive questions:
|
Please see https://un5h208565ak8emkwgjjkgb49yug.julianrbryant.com/show_bug.cgi?id=1504085#c7
Please see web-platform-tests/wpt#15937 (comment) |
|
CORS is something both sides opt into so it seems reasonable that in that case we leak the origin. We previously decided that the Referrer Policy would not influence CORS for that reason. However, Origin is also used outside of CORS and we have not effectively dealt with it there. |
|
Thank you. |
annevk
left a comment
There was a problem hiding this comment.
Thanks for the update, this mostly looks good to me now except for some minor things. Test coverage is good and I think other browsers are on board as well. I can take care of filing bugs on them once we land this.
For the branching on referrer policy adding "Otherwise" and "Do nothing." as its steps might also be good, to be explicit about that scenario.
And we should add a Note explaining why we adhere to Referrer Policy only sometimes. I can also take that on before I merge this unless you want to give it a go.
|
I'm with you for the view of websocket. I addressed this with my new patch.
Thanks for taking care of filing bug. FWIW, we also need a bug for navigation from
This issue is gone since I change the structure
Thanks for taking care of the note. |
annevk
left a comment
There was a problem hiding this comment.
Noticed a few issues unfortunately. I also added a note, please let me know if that looks good to you.
annevk
left a comment
There was a problem hiding this comment.
I think this is all good now. Anyone have any final thoughts? @JuniorHsu are you happy with the nits I pushed?
|
@annevk Yes, I'm happy :) Thanks for those tremendous help! |
Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsu@gmail.com> Co-authored-by: Anne van Kesteren <annevk@annevk.nl>
|
And thank you for pushing this through @JuniorHsu! |
Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsu@gmail.com> Co-authored-by: Anne van Kesteren <annevk@annevk.nl>
…ith the Referrer Policy, a=testonly Automatic update from web-platform-tests Fetch: Origin outside of CORS Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsu@gmail.com> Co-authored-by: Anne van Kesteren <annevk@annevk.nl> -- wpt-commits: ef44bff0adaa07f2e420a0cbc1bc493cd5786656 wpt-pr: 14260
…ith the Referrer Policy, a=testonly Automatic update from web-platform-tests Fetch: Origin outside of CORS Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsu@gmail.com> Co-authored-by: Anne van Kesteren <annevk@annevk.nl> -- wpt-commits: ef44bff0adaa07f2e420a0cbc1bc493cd5786656 wpt-pr: 14260
…ith the Referrer Policy, a=testonly Automatic update from web-platform-tests Fetch: Origin outside of CORS Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsugmail.com> Co-authored-by: Anne van Kesteren <annevkannevk.nl> -- wpt-commits: ef44bff0adaa07f2e420a0cbc1bc493cd5786656 wpt-pr: 14260 UltraBlame original commit: add3ec0537b40f72caa6316e0f0cccf5d1da0198
…ith the Referrer Policy, a=testonly Automatic update from web-platform-tests Fetch: Origin outside of CORS Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsugmail.com> Co-authored-by: Anne van Kesteren <annevkannevk.nl> -- wpt-commits: ef44bff0adaa07f2e420a0cbc1bc493cd5786656 wpt-pr: 14260 UltraBlame original commit: add3ec0537b40f72caa6316e0f0cccf5d1da0198
…ith the Referrer Policy, a=testonly Automatic update from web-platform-tests Fetch: Origin outside of CORS Ensure we have more coverage for how to set the Origin header outside of CORS. And also how its value is impacted by Referrer Policy. Fetch change: whatwg/fetch#908. Co-authored-by: Junior Hsu <cuveehsugmail.com> Co-authored-by: Anne van Kesteren <annevkannevk.nl> -- wpt-commits: ef44bff0adaa07f2e420a0cbc1bc493cd5786656 wpt-pr: 14260 UltraBlame original commit: add3ec0537b40f72caa6316e0f0cccf5d1da0198
Let Origin header honor referrer policy for non CORS request
Tests: web-platform-tests/wpt#14260
Preview | Diff