WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
217758
referrerpolicy is not honored
https://bugs.webkit.org/show_bug.cgi?id=217758
Summary
referrerpolicy is not honored
maudn@chromium.org
Reported
2020-10-15 09:16:20 PDT
It looks like element-level referrer-policies set via the HTML attribute `referrerpolicy` aren't honored. This can be tested on this [test site](
https://site-one-dot-referrer-demo-280711.ey.r.appspot.com/stuff/detail?tag=red&p=p2
). It looks like the problem has been fixed in Safari 14 (Desktop), but I can still reproduce in Safari 12 on an older iPhone. More details [here](
https://lists.webkit.org/pipermail/webkit-dev/2020-September/031404.html
).
Attachments
Add attachment
proposed patch, testcase, etc.
Alexey Proskuryakov
Comment 1
2020-10-15 17:09:09 PDT
If this only reproduces on a 2 year old release, then I don't see how this is a bug to track here. Can you reproduce on iOS 14? That said, there were other bug reports about referrerpolicy interaction with other features like ITP, including
bug 206957
and
bug 215356
, so maybe this is related? Could you please attach a self contained test that doesn't require for the app spot URL to remain live?
maudn@chromium.org
Comment 2
2020-10-20 03:16:00 PDT
Thanks Alexey! An update: On mac Safari 14.0 with ITP on: (tested on my machine) ---------- Element-level `referrerpolicy` are honored, even `no-referrer-when-downgrade`, on *all* types of elements: iframes, a (navigations), images and scripts. On iOS 14: (tested on BrowserStack) ---------- Two observations: • Element-level `referrerpolicy` are honored, except `no-referrer-when-downgrade` - Meaning, in these cases, the Referer header is only the origin. Which in my understanding may be due to ITP. *But* one other interesting behaviour: When `referrerpolicy` is `no-referrer-when-downgrade` on an `a` element: `document.referrer` is only the origin, but the `Referer` header is the full URL i.e. honors the policy. • This also means that the behaviour is different than on mac, why could this be? I'm testing on BrowserStack, so it could be some special settings. On mac Safari 13 and iOS 13: ---------- Element-level `referrerpolicy` are not honored, even when they're *stricter* than the document's policy. Re: Self-contained test that doesn't require for the app spot URL to remain live. Will post a link here, let me update the code. In the meantime, the appspot URL will remain live!
maudn@chromium.org
Comment 3
2020-10-20 03:23:57 PDT
Note: I see [here](
https://github.com/privacycg/proposals/issues/13#issuecomment-707242581
) that the document.referrer vs Referer header behaviour difference is to be expected.
Radar WebKit Bug Importer
Comment 4
2020-10-22 09:17:15 PDT
<
rdar://problem/70576228
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug