Will DNSLink resolve PeerIDs

I’ve been playing around with p2p-circuit and was wondering if DNSLink will resolve PeerIDs. I’ve only ever seen DNSLink used with IPFS and IPNS but not PeerID. I was thinking they would be handy to use in circuit relay addresses. Instead of

/ipfs/QmRdjvsyoNjA2ZfAQBtQ7A2m5NmtSXLgxE55Brn1AUjZ1v/p2p-circuit/ipfs/QmWiTQoWhJZDxikxHEbjmRiQT4FMgzZS98gfPNJ9GWWuZ8

you could have something like

/ipfs/example1.com/p2p-circuit/ipfs/eample2.com

Sure it ties you to DNS but I’ve been playing around with setting up a local DoH resolver for a custom TLD so it would be something like

/ipfs/peerA.peerid/p2p-circuit/ipfs/peerB.peerid

But it’s just local but I want to use it anywhere I use IPFS so I just setup a node and use p2p http proxy and I can use it as a custom DNS resolver anywhere I want.

One step further it would be nice to store the custom RR’s in IPFS so my DNS server will use the RR’s from some IPNS hash.

EDIT: I found at http://dnslink.io it says " *in the future, the value may be a multi address" any idea if the future has arrived or if not when it might get here?

@zacharywhitley Please have a look, might help : multiaddr/DNSADDR.md at master · multiformats/multiaddr · GitHub

To see dnsaddr at play, simply look at your default bootstrap list: ipfs bootstrap

Just what I was looking for, thanks. IPFS has a lot of little goodies stashed here and there if you know where to look.

1 Like