Allow connection to relays at local IP addresss #629

Closed
opened 2024-01-20 06:59:31 +13:00 by mikedilger · 1 comment
mikedilger commented 2024-01-20 06:59:31 +13:00 (Migrated from github.com)

Our Url type enforces that the authority (host) is global. We do this to stop the proliferation of invalid URLs in nostr events, in relay lists, in recommended relay URL fields, in nevent1s, etc.

But this means people cannot use wss://localhost:8080/ and connect to their local relay.

We probably need to allow local URLs and apply local/global testing at various points in the code. That might be a lot of points though.

Our `Url` type enforces that the authority (host) is global. We do this to stop the proliferation of invalid URLs in nostr events, in relay lists, in recommended relay URL fields, in nevent1s, etc. But this means people cannot use `wss://localhost:8080/` and connect to their local relay. We probably need to allow local URLs and apply local/global testing at various points in the code. That might be a lot of points though.
mikedilger commented 2024-01-22 11:08:56 +13:00 (Migrated from github.com)

This is a lot of trouble, more than it is worth given someone can put a hostname in their hosts file and map it to a local IP address. Our global check only applies when the URL is specified as an IP address.

This is a lot of trouble, more than it is worth given someone can put a hostname in their hosts file and map it to a local IP address. Our global check only applies when the URL is specified as an IP address.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
nostr/gossip#629
No description provided.