Hi, nostr:nprofile1qqsrhuxx8l9ex335q7he0f09aej04zpazpl0ne2cgukyawd24mayt8gprfmhxue69uhhq7tjv9kkjepwve5kzar2v9nzucm0d5hszxmhwden5te0wfjkccte9emk2um5v4exucn5vvhxxmmd9us2xuyp. I have an idea for using Nostr's existing network architecture to allow for optionally DNS-free relays. It would ideally be applied to Nostr & Blossom.

Relays could have their own Nostr pubkey which they would use to

1. Send a new, IP address location event type to Nostr relays containing their current IPv6 or IPv4 address & port number, &

2. Sign the data they send to clients so that clients can verify that they're receiving the data from the expected relays.

With this setup, for a client to find their DNS-free relays, they would

1. Attempt to connect to their last known IP locations

2. If this fails, they would query all relays they know the location of for the most recent location broadcasts they have

3. Reattempt to connect using the new location data

This way, a relay could run without a domain name of any kind on a non-static IP address that could change at any time. As soon as the relay detects that its IP address has changed, it could broadcast its new location so it could be quickly connected to again.

What are your thoughts?

I like it, but signing every response is a pain, and its utility is relative, since the contained events are signed; so if an IP is reused by a bad actor the worst result would be the receiving of random events inconsistent with the request.

Maybe we can simply add a PING call, that generates a signed "PONG" response, so a client can every now and then verity the relay IP.

Reply to this note

Please Login to reply.

Discussion

Or we can use WebTransports.

Agreed, this part got me wondering.

Thing is, not all request are as explicit such that you know what you are getting is "wrong"; therefor to the extend you rely on the moderation/censorship performed by the relay, this breaks in such an attack.

A handshake and/or periodical check should cover most attacks other than some super sophisticated targeted ones where networks themselves are pwnd, though im not sure about that.

I'd say those would be marginal enough to deem the measure sufficient