Skip to content
This repository has been archived by the owner on Feb 8, 2023. It is now read-only.

(In)transparent ipns redirects for dnslink web sites in gateway #101

Open
jbenet opened this issue Jan 20, 2016 · 4 comments
Open

(In)transparent ipns redirects for dnslink web sites in gateway #101

jbenet opened this issue Jan 20, 2016 · 4 comments

Comments

@jbenet
Copy link
Member

jbenet commented Jan 20, 2016

When showing off that https://ipfs.io is really https://ipfs.io/ipns/ipfs.io many people have said that it's really a non-obvious fact, and that it would really help us (for now) to draw attention to this. I.e. the transparent working is really nice, but it also hides IPFS. We have IPFS-hosted sites that look like regular http sites and draw no difference. (yes, this is a good thing, but it does not help ipfs grow). It also makes some sites viewable through a local ipfs node with browser extensions trickier to find.

So, perhaps we can temporarily (say for 2016) make our ipfs-hosted websites redirect to the proper /ipns/ path under the gateway, instead of the (very nice) transparent hosting:

Notes:

  • This could be done with 302 or 303, so all links would continue to work.
  • This could be done on nginx on our end. or it could be done in go-ipfs so it works everywhere.
  • security issue: since suborigins are not yet deployed, this is origin-policy dangerous. doing this with our sites is totally fine, as we control them (and we dont use any login stuff anywhere yet). doing it with other sites less ok.
  • To address the security issue, and to give users control of this, we could make this redirection happen in the presence or lack of presence of another dns TXT record (like ipfs-gateway-transparent=true or something), or this could be a var placed at the end of the dnslink record: dnslink=/ipfs/<hash> ipfs-gway-transparent

Would love to hear what you think.

cc interested people: @lgierth @diasdavid @dignifiedquire @lidel @Kubuxu

@Kubuxu
Copy link
Member

Kubuxu commented Jan 20, 2016

I would love feature like that. I have few sites on IPFS already and all apart from one can be redirected under ipfs.io only problem is that telling users normal URL to the site is much, much simpler than telling them to type in ipfs.io/ipns/bin.kubuxu.ovh.

@jbenet
Copy link
Member Author

jbenet commented Jan 20, 2016

@Kubuxu this already works today. You can add CNAME or A records to your domain pointing to the gateway, the gateway will transparently serve /ipns/bin.kubuxu.ovh. we do this today with https://ipfs.io and http://dist.ipfs.io (we should make a blog post / guide for this cc @RichardLitt @lgierth)

Here i'm proposing making it less transparent (at least for our sites, and at least for now)

@Kubuxu
Copy link
Member

Kubuxu commented Jan 20, 2016

I know but I want to redirect it under ipfs.io/ipns/bin.kubuxu.ovh, user still has to type bin.kubuxu.ovh but lands on ipfs.io/ipns/bin.kubuxu.ovh and if he wants to share it he copies the ipfs.io/... version.

(Same reason why I always type ipns:bin.kubuxu.ovh in my browser, less typing, sorry that I didn't made myself clear in the first place).

EDIT: CNAME won't work until ipfs/kubo#2191 is merged and deployed.
EDIT2: Also dist.ipfs.io shouldn't be linked with https as the cert does not work for it.
EDIT3: Fixed wrong issue number above.

@jbenet
Copy link
Member Author

jbenet commented Jan 20, 2016

@Kubuxu thanks

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants