ipfs / infra

Tools and systems for the IPFS community
MIT License
132 stars 41 forks source link

Add dweb.link to publicsuffix.org #476

Closed lidel closed 5 years ago

lidel commented 5 years ago

Parent issues: https://github.com/ipfs/ipfs/issues/337, https://github.com/ipfs/in-web-browsers/issues/89 cc https://github.com/ipfs/infra/issues/391, https://github.com/ipfs/infra/issues/81, https://github.com/ipfs/go-ipfs/issues/5982, https://github.com/ipfs-shipyard/ipfs-companion/issues/527, @mburns, @lgierth, @Stebalien

Context

As noted in https://github.com/ipfs/infra/issues/81, we will be setting up cid-in-subdomain proxying at <cidv1b32>.ipfs.dweb.link

I believe getting it right means adding it to The Public Suffix List (publicsuffix.org), to ensure websites loaded via dweb.link gateway can't interfere with each other's cookies.

Proposal

Changes I want to submit in a PR to publicsuffix/list are in lidel/list#dweb.link branch:

Add public suffix entries for dweb.link

Anyone can effectively create the following subdomains by adding content to IPFS:

*.ipfs.dweb.link (eg: bafybeiemxf5abjwjbikoz4mc3a3dla6ual3jsgpdr4cjr3oz3evfyavhwq.ipfs.dweb.link)

Other protocols will be supported in the future, for example:

*.dat.dweb.link (eg: 778f8d955175c92e4ced5e4f5563f69bfec0c86cc6f670352c457943666fe639.dat.dweb.link)

To ensure websites loaded via dweb.link gateway can't interfere with each other's cookies, I suggest adding the following public suffix record:

*.dweb.link

Tasks

Based on https://github.com/publicsuffix/list/wiki/Guidelines#submitting-amendments I've split this endeavor into small subtasks:

mburns commented 5 years ago

I've actually got this ball rolling already: https://github.com/publicsuffix/list/pull/766

Happy to tweak my PR to match yours (apex + subdomains vs your use of wildcard, etc)

lidel commented 5 years ago

@mburns :man_facepalming: I probably made a typo in search and that is why I did not found already existing PR – sorry! I am closing this in favour of https://github.com/ipfs/infra/issues/83#issuecomment-460615452

ps. If we swap subdomains with wildcard it will save us time waiting for another PR when we want to add a gateway for dat or something else – but its up to you :)