Page MenuHomePhabricator

Add "Referrer-Policy: no-referrer" to standard HTTP headers
ClosedPublic

Authored by epriestley on Feb 27 2018, 8:19 PM.
Tags
None
Referenced Files
F13085842: D19144.diff
Wed, Apr 24, 11:57 PM
F13085841: D19144.diff
Wed, Apr 24, 11:57 PM
Unknown Object (File)
Fri, Apr 19, 7:28 PM
Unknown Object (File)
Thu, Apr 11, 8:14 AM
Unknown Object (File)
Sat, Apr 6, 9:02 PM
Unknown Object (File)
Mar 21 2024, 6:09 AM
Unknown Object (File)
Mar 21 2024, 6:09 AM
Unknown Object (File)
Mar 21 2024, 6:09 AM
Subscribers
None

Details

Summary

Ref T4340. Some browsers respect this header and referrers are a plague upon the earth.

Also, upgrade "never" to the more modern value "no-referrer".

Test Plan

In Safari, Firefox and Chrome, disabled rel="noreferrer" on links and generated a normal link to an external site. Then clicked it and checked if a referrer was sent.

  • Safari respects meta only, but "no-referrer" is fine.
  • Firefox respects both (either the header or meta tag are individually sufficient to stop referrers).
  • Chrome respects both (same as Firefox).

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision was not accepted when it landed; it landed in state Needs Review.Feb 27 2018, 8:59 PM
This revision was automatically updated to reflect the committed changes.