aboutsummaryrefslogtreecommitdiffstats
path: root/src/sync-outbox.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2026-09-08 11:15:02 -0700
committerAdam Soltys <[email protected]>2026-09-08 11:15:02 -0700
commit7b444d6f0750b1ff316204dd5ec4425201c480e9 (patch)
treefb6b4a7393b22402d49b91fe98ee89304a2977b6 /src/sync-outbox.js
parent779284629dd30df04b5e594b9d729546e08bbe71 (diff)
downloadcoinosv3-7b444d6f0750b1ff316204dd5ec4425201c480e9.tar.gz
coinosv3-7b444d6f0750b1ff316204dd5ec4425201c480e9.zip
DMs: one nostr identity per wallet (stop the phantom seed-key inbox).
A wallet has two nostr keys — the seed-derived key and, when signed in, the login identity (extension/bunker/passkey/Google). Sending already used one identity, but RECEIVING/advertising used both: startDMs subscribed kind-1059 gift wraps on '#p' for both keys and fetched both keys' inbox relays, and ensureDmRelayList always published a kind-10050 inbox for the seed key even under a login. Result: a login wallet advertised the seed key as a SECOND DM inbox, so the welcomer greeted both keys (duplicate welcome) and a person's DMs split across two identities — one showed up as if from "another user". Collapse to a single DM identity: new dmSubKeys() returns just the login pubkey when signed in, else the seed key, and startDMs subscribes/fetches only that; ensureDmRelayList no longer advertises the seed key when a login identity is active. isMe() and dmDecryptors() stay tolerant of both keys so already-received messages still thread and align. Not a privacy fix — nothing ever leaked to a third party (both keys were the user's own); this removes the confusing second self-identity going forward. (Existing cached DMs to the seed key on a given device don't retro-clean; a chat re-sync/forget clears them.) Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
Diffstat (limited to 'src/sync-outbox.js')
0 files changed, 0 insertions, 0 deletions