Page MenuHomePhabricator

Remove autodetection for whether links need "noreferrer"
ClosedPublic

Authored by epriestley on Feb 18 2018, 1:09 AM.
Tags
None
Referenced Files
F14492016: D19117.id45811.diff
Thu, Jan 2, 2:43 PM
Unknown Object (File)
Wed, Jan 1, 4:39 PM
Unknown Object (File)
Tue, Dec 31, 6:30 PM
Unknown Object (File)
Mon, Dec 30, 10:23 PM
Unknown Object (File)
Mon, Dec 30, 8:45 PM
Unknown Object (File)
Sun, Dec 29, 4:18 AM
Unknown Object (File)
Thu, Dec 19, 7:09 PM
Unknown Object (File)
Thu, Dec 19, 7:09 PM
Subscribers
None

Details

Summary

Via HackerOne. See https://hackerone.com/reports/317243.

We're still detecting these wrong because browsers treat <a href=" /<newline><tab>\evil.com">click here</a> as a valid protocol-relative link to evil.com.

Just give up and add "noreferrer" at the application level at all callsites, like we do with target="_blank" already.

Test Plan

Added failing tests; ran unit tests. See also next change.

Diff Detail

Repository
rPHU libphutil
Branch
noreferrer
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 19617
Build 26556: Run Core Tests
Build 26555: arc lint + arc unit