Summary: | Open Link in New Tab does not send referer header | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | mskelton@widen.com <mark.skelton> | ||||
Component: | Page Loading | Assignee: | Nobody <webkit-unassigned> | ||||
Status: | RESOLVED MOVED | ||||||
Severity: | Normal | CC: | achristensen, beidson, bfulgham, cdumez, webkit-bug-importer | ||||
Priority: | P2 | Keywords: | InRadar | ||||
Version: | Safari 15 | ||||||
Hardware: | Mac (Intel) | ||||||
OS: | macOS 11 | ||||||
URL: | https://mskelton.github.io/chromium-bug | ||||||
Attachments: |
|
Description
mskelton@widen.com
2021-12-20 06:35:04 PST
It is not clear to me here that this is a bug and that we are expected to send a referrer header here. How is that different from copying the link URL, opening a new tab and pasting the URL in the URL bar (which is basically what this menu action does)? (In reply to Chris Dumez from comment #2) > It is not clear to me here that this is a bug and that we are expected to > send a referrer header here. > > How is that different from copying the link URL, opening a new tab and > pasting the URL in the URL bar (which is basically what this menu action > does)? Other browsers correctly attach the Referer header when opening links in a new tab (save for a minor bug in Chrome) so I would hope Webkit would follow suit to be consistent. (In reply to Mark Skelton from comment #3) > (In reply to Chris Dumez from comment #2) > > It is not clear to me here that this is a bug and that we are expected to > > send a referrer header here. > > > > How is that different from copying the link URL, opening a new tab and > > pasting the URL in the URL bar (which is basically what this menu action > > does)? > > Other browsers correctly attach the Referer header when opening links in a > new tab (save for a minor bug in Chrome) so I would hope Webkit would follow > suit to be consistent. Yes, if other browsers do so, it is pretty good justification for us to do the same indeed. Ok, here is a better test repro: - https://codepen.io/cdumez/pen/poWKzxV 1. Right-click link > open in new tab 2. Notice that there is no referrer printed out in Safari but there is one in both Chrome and Firefox. (In reply to Chris Dumez from comment #5) > Ok, here is a better test repro: > - https://codepen.io/cdumez/pen/poWKzxV > > 1. Right-click link > open in new tab > 2. Notice that there is no referrer printed out in Safari but there is one > in both Chrome and Firefox. This appears to be a Safari issue though, not a WebKit one. If I use WebKit's mini browser and click "open in new window", then I see a referrer. The problem is that Safari hijacks the context menu and has its own actions in there. Those "Open Link in..." actions do not send a referrer header. This is actually: <rdar://3413260> It is apparently standard Safari behavior since 2003. Mark: Just to be clear, you are reporting a problem in the Safari client of WebKit, which chooses to implement its own 'Open Link In' behavior that does not include the header. I am resolving this as 'Moved', since it needs to be fixed in the Safari client. That problem is tracked in Safari under rdar://3413260. |