Your nip-65 is good. Simple, straight forward. And solves one of the problems. How do you reliably, in a signed way, state what relays you’re using. But it only works once I already know one of those relays in order to see the message.

What I’m saying, is would it be useful to not just have you spread your 10002 message to multiple relays but also to be able to push it to a DHT, would be useful.

Especially if we get to a world where because of spam, most relays end up with gatekeepers like needing to pay satoshi to join.

Reply to this note

Please Login to reply.

Discussion

Ok but isn't it true that in order to read someone's relay list off of a DHT I have to connect to one of the server serving that DHT? And if so, how is that different from all those servers being nostr relays and serving the same information?

Well with a DHT you connect to one of several known root servers. This is how you bootstrap in to tor, ipfs, or BitTorrent. Then from there that root server keeps a record of other peers and you can start querying.

In this case, the relays hosted by NIP-05 aren’t signed and often aren’t updated. Not as big an issue where folks are hosting it just for themselves like you’re doing’s but for people using the cloud nip-05 services, it is.

I’m pretty sure we could post NIP-65 events to a DHT, it’s signed, so we know somebody didn’t forge it, and then we could allow lookup based on npub.

I want to run my own relay for private purposes and dont trust in any root at all, even with certificates and verification with keypairs. I run my servers at home I can unplug them if I want or get tired. That is the philosophy.

Ok first of all, NIP-05 is out of the question. It's not signed, it's not a contender here. That was just to make it easier to find someone, back when we didn't have better ways. It was my idea to put it into nostr.json in the first place, so I am shooting down my own idea.

My newer idea is expressed in NIP-65, which is just to spread that kind-10002 event to hundreds of relays (while only using a few relays for regular events).

I've always been in favor of relays or servers that specialize in serving kind-10002 events. I was going to suggest if someone does a DHT to put the kind-10002 events in there. Sounds like that is already part of your idea.

It seems that if all the clients move over to publishing into a DHT, then a DHT would have the advantage that all the data would be in it (the hash table being synchronized, I presume), whereas if you just ask a popular relay, it might not know, and you could never know for sure if that was because the relay didn't know or because the data wasn't there. BUT that property doesn't appear unless and until everybody moves to using the DHT. And I'm not sure people will because of the chicken-and-egg problem.

But a DHT seems like (even though it is distributed) a potential single source of failure. If there are "root servers", how many are there? Can they cheat?. Can things be removed from or replaced in a DHT, and if so, cant someone censor data out of it, and then replicate that censorship widely? If not, how is that enforced? I admit to my ignorance on this point.

I think we’re in agreement. If the DHT is setup in such a way that to write to it you need to use your nsec to sign the 10002 post which lists your relays with the lookup based on the npub. DHT’s are particularly censorship resistant, there are lots of kinds of DHT’s and ways to use them. We’d want to have somebody double check and help with its design.

There might even be a good way to take 10002 messages from a relay and push it to the DHT. It has to be signed, so even if the original person who created it doesn’t post it to the DHT with their app, others or relays could. The other half is to then provide a web UI for looking up npubs from the DHT. That way it would work without a chicken and egg problem.

Are you planning to build this? I look forward to seeing how it works out.

I am working on it and would love all the help I can get https://pkarr.nuhvi.com/

I am already getting great results, but will need real stress testing, if you are willing to help testing, please let me know, the code for the server side is almost ready. And the demo web app will be read before Monday, but feel free to watch it as it evolves pkarr.nuhvi.com

signing to write is a must, pow would be good too

100% dht to find relays for npubs