-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(ADDRESSING): default DNSLink to ipfs:// #150
Conversation
DNSLink resides under `/ipns/` right now, but it is not related to IPNS in any way. We should support `ipns://{fqdn}` for completeness and backward compatibility, however it should be a redirect to `ipfs://{fqdn}`. Address bar should have `ipfs://{fqdn}`. This will solve two HUGE problems: - people being confused why its `ipns://` instead of `ipfs://` - removing the problem of cross-protocol boundary
4b4487d
to
64daf83
Compare
Why is I don't really know enough to confidently offer solutions, but maybe it could be |
|
I'm concerned this will cause more problems than it will solve:
I'm also concerned this doesn't fix the issue. What does this mean for, e.g., javascript-backed requests from If push comes to shove, we could go with something like:
|
@lidel I'm a little confused (sorry for the long response), can you help me understand what are the main issues this helps with? TLDR:
DNSLink can point at an arbitrary path. As far as I can tell the currently supported path types are Is the idea that since currently DNSLink websites (the content ultimately resolved by The point that is starting to crystallize for me here is that given that DNSLink (and IPNS) both take Figuring out the details here is hard, and I imagine asking for |
Thanks for joining the discussion! Main reason is to improve UX/DX of IPFS addressing in web browsersI want to be clear about the motivation for this change. It simplifies things by moving the main use case in browser contexts (DNSLink) to the main protocol handler, removing cognitive overhead when dealing with "IPFS websites". In the browser, the idea is that people don't care about our protocol handler extravaganza and just want to use intuitive DNSLink can still point at arbitrary content paths such as dweb:/{ipfs,ipns,dnslink,etc} does not provide Origin isolation@npfoss @Stebalien @aschmahmann : URIs like this are already listed in existing spec, but won't be useful as canonical addresses in browsers any time soon due to the lack of proper Origin isolation. Making this work requires browser vendors to change some security-sensitive code paths, which is not feasible at this stage. Cross-protocol requestsNote that cross-protocol in IPFS ecosystem means different things than cross-protocol in browser context. Want to make sure we discuss the latter. From the browser perspective, cross-protocol thing happening behind DNSLink is internal to IPFS. Browser asks IPFS for bytes to render, and gets them. The only thing browser cares about now is how to handle requests made by a rendered page to Origins under different protocol (Origin = protocol+hostname+port). What this PR does is to simplify protocol handler for the most popular use case (DNSLink): it removes the question of how to handle requests for Cross-protocol requests, especially to What to do with ipns://It would remain. We would still support DNSLink on it. I imagine loading websites via "raw IPNS" ( Other concerns
Correct, we won't. Proposed change is limited to interop URLs (
Yes, but when/why would browser user make that conversion?
Yes. That is the point. In web browser DNSLink hides it all behind human-readable DNS name.
Sadly no: it does not provide valid Origin separation. See About dweb: above.
Yes, we already struggle with Let me know if I missed the target anywhere. |
My suggestion was |
@Stebalien I see, yes, that would keep hash and protocol name in "Origin" segment, producing URLs like:
While it "solves" cross-protocol and Origin problems, it does it at a cost (ux/performance):
Right now, having a shared TL;DR I am not saying collapsing everything under |
i agree with @Stebalien proposal with some remarks IMO i think DNSLink should be supported everywhere it's just a link, an alias. for protocol handlers using "dns links":
or just for hashes:
for this we actually should own ipfs and ipns TLDs |
Meeting NotesWe had a meeting on 2019-07-31 and discussed pros and cons of this PR.
Conclusion
|
Motivation
Interesting quirk of where we are right now:
DNSLink resides under
/ipns/{fqdn}
, but it is not related to IPNS in any way.I was thinking about the future, when we have protocol handlers in web browsers and what will be shown in address bar.
Then I realized 1:1 mapping will show all DNSLink websites under
ipns://{fqdn}
😱Proposed change
To avoid the future of
ipns://
we need to support DNSlink websites underipfs://{fqdn}
, and makeipns://{fqdn}
a redirect toipfs://{fqdn}
.It is easy to implement:
{cid}
, load it{fqdn}
, resolve it and load the contentThis will solve a set of problems:
ipns://
instead ofipfs://
/ipns/{fqdn}
, but will probably end up switching DNSLink to its own namespace at/dnslink/{fqdn}
(Feature request: add link type/dns/<domain name>
notes#348 (comment)). Detaching default fromipns://
now, saves us headache laterWhat about ipns:// ?
It would remain and work for real IPNS paths. We would still support DNSLink on it, but as a redirect to
ipfs://
URL. I imagine loading websites via "raw IPNS" (ipns://{libp2p-key}
) will be pretty rare event and similar to loading website via raw IP (bad UX, but works without DNS).cc #147