-
Notifications
You must be signed in to change notification settings - Fork 594
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Publish by peers #411
Comments
I like this a lot. I see a possible NIP for this as having a standardized very generic {
"kind": 20001,
"content": "<encrypted JSON of the event that is to be republished>",
"tags": [
["p", "<pubkey of the person that is chosen to republish this>"],
["relays", "wss://relay.com", "wss://otherrelay.com", "and so on, there could be many of these"]
]
} Then whenever the chosen republisher sees a note like that they automatically decrypt it using NIP-04 method and publish it to the chosen relays.
People can easily run very lightweight republish services for free and provide anonymity for everybody else. |
What is ["p", "<pubkey of the person that is chosen to republish this>", "encrypted-secret"], |
Something that shouldn't have been present in that comment. I'll remove that. |
Very interesting, but how do we avoid sybil attacks on the "republisher" network? If a large entity just wanted to host tons of republishers, it could read the metadata of most forwarded messages. And as Michael Hayden said, we kill people based on metadata, so I think we should first look into scrubbing the metadata from NIP-4 before implementing this Also, what's there to stop the republishers from simply accepting, then dropping the events? Or what about trying to manipulate the event data? Or the ciphertext? Imo, we grant the republishers a lot of power, since you have to trust them with the entire event. Who says they're going to keep the public key and signature the same? |
|
nip-59 gift-wrap dm's effectively scrub metadata. we should probably "bake that in" as an optional way to dm someone for security-minded people. |
TL;DR:
onion-routing
like events to obscure activity from relaysOne way to increase the privacy of
Encrypted Direct Messages
is for peers to derive new keys when they communicate. See this (draft) issue for more details.Alice
andBob
) can use a new key for each new DMAlice
andBob
are having a private conversationNot all relays can be trusted
However, the relay(s) that
Alice
andBob
are connected to can learn thatAlice
andBob
are chatting.Alice
sends a message toBob
:AB1
,AB2
,AB3
, etc are keys thatAlice
derives in order to communicate with Bob. They areone-use-only
keys.BA1
,BA2
,BA3
, etc are keys thatBob
derives in order to receive messages from Alice. They areone-use-only
keys.The relay can see that
Bob
is subscribed to public keys to whichAlice
sends messages. Therefore it is trivial to deduce thatAlice
andBob
are having a private conversation.Re-publisher
The concept is similar with that of a remailer [1]:
Alice
will NOT publish messages withBob
as the direct destination.Alice
will choose one (or more) of her "contacts" (sayCarol
) to forward the message toBob
:Alice
builds a direct message forCarol
where the content is the fullnostr event
forBob
Carol
decrypts the direct message and publishes thenostr event
to therelay
Carol
to discover that the message is forBob
. The destination is just anone-use-only
public key that cannot be connected to any participant. Only the relay knows thatBob
has a filter for that public key.relay
seesAlice
's message forBob
as coming fromCarol
(from theIP
perspective)Alice
might trust her peers more that she trusts any particular relay.relay
to correlate the messages,Alice
can:nostr event
thatCarol
will ignore (avoid correlation by size)nostr event
forBob
in two or more events sent toCarol
(avoid correlation by size)Carol
is mostly an idle participant then therelay
can easier correlate by frequency. It is desirable forAlice
to choosere-publishers
that are very active (publish a lot).Cross relay re-publisher
The privacy can be increased even more if
Alice
uses one relay to communicate withCarol
(Relay X
), butCarol
uses a different relay (Relay Y
) to forwards thenostr event
toBob
.Relay X
andRelay Y
are not colludingNotes:
kind
forTyped Encrypted Direct Messages
is required in order for clients to easily differentiate between normal messages andre-publish
requests. See this issue.Alice
must make sure thatCarol
is online, but she (Alice
) can use multiplere-publishers
.Bob
advertises which relays it uses, then it is easy forAlice
to find a common peer tore-publish
her message(s)Carol
can accept to be are-publisher
for a "selected list of contacts"/"followers"/"following"/"everyone" etc.Carol
does not have to be in contact withBob
, they just have to share a common relayre-publishers
there are, the more private the DMs becomere-publisher
is very easy. It is a client-side task (in the browser/app). It requires no storage, only bandwidth. Respectable Nostr clients should have the option to also act asre-publishers
.re-publish
botsAlice
->Carol
->Dave
->Bob
, but with each hop there-publishing
becomes less reliable since any hop can go offline at any moment.cashu
[3] could help.re-publishers
can be activated for more sensitive chats onlyttl
(Time To Live)[2] tag for DM events. This wayre-publish
event do not have to be kept for long (only a few minutes)References
[1] Untraceable Electronic Mail, Return Addresses, and Digital Pseudonyms
[2] Time to live
[3] cashu spec
The text was updated successfully, but these errors were encountered: