Repository navigation
End-to-end encrypted chat and the chat UI wired to the API - #4
Merged
Merged
Conversation
Keys come from one wallet signature, the public key is registered on the Registry, messages are sealed in the browser (NaCl box) and sent as ciphertext. The API only accepts messages between accepted friends (checked on chain). The UI moves from the legacy ChatApp contract to Registry and NodeToken, with friend requests, unlock, sending/failed/retry states and polling.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Registry.register./api/messages, opened in the browser. The server and Neon never see plaintext.ChatAppcontract toRegistryandNodeToken: profiles and friend requests (request, accept, decline) from contract events, messages through the API, an "Unlock messages" step (two signatures, no gas), sending / not sent (Retry, Discard) states and a 4 second poll while the conversation is open.areFriends, positive answers cached 60 s). 403 for a non-friend, 503 if the chain cannot be read; OpenAPI updated.NodeToken; mining is a later feature, so balances are zero.NEXT_PUBLIC_REGISTRY_ADDRESS,NEXT_PUBLIC_TOKEN_ADDRESS,NEXT_PUBLIC_REGISTRY_START_BLOCK(already set on Vercel); the ABI check covers Registry and NodeToken.Tests
node:testtests pass on the in-memory store: 6 crypto (same wallet same keys, both sides open, third party cannot, tampering, unicode) and the API tests including the 403 and 503 paths.Rollout and rollback
Merge deploys to Vercel; the new variables are set. Rollback is a revert of this PR plus restoring the previous deployment.