go-dnslink
                                
                                
                                
                                    go-dnslink copied to clipboard
                            
                            
                            
                        Ignore non-IPFS content paths in DNSLink records
DNSLink currently returns the first non /dns-prefixed dnslink which means that per domain it is possible to use dnslink for only one "protocol". In order for dnslink to become useful for different decentralized protocols (hyper/dat, earthlink, etc.) it would need an option to specify a particular protocol to be looked for. Would you be open to a PR adding an option to this repo, defaulting to IPFS?
(Related issue on js-dnslink: here)
Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review. In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment. Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:
- "Priority" labels will show how urgent this is for the team.
 - "Status" labels will show if this is ready to be worked on, blocked, or in progress.
 - "Need" labels will indicate if additional input or analysis is required.
 
Finally, remember to use https://discuss.ipfs.io if you just need general support.
Yes, a PR would be welcome. However, the PR should go into go-namesys as that is the more used library for dnslink at the moment.
@aschmahmann Probably somewhere here: https://github.com/ipfs/go-namesys/blob/2454122ef30efa1f4f86ffab33ea34b05eb848fe/dns.go#L171-L178, right?
@martinheidegger yes, we want to skip records where does not start with /ipns/ or /ipfs/ (right now it errors). Adding strings.HasPrefix  check should do the trick.
We should  also interpret /dnslink as /ipns and try to resolve it to the final form.