Conversation
…tores nothing The Envelope and envelopeHeader docs in crypto.ts, wire.ts and channel.ts still say the relay keeps an ordered log so a reconnecting phone can catch up. The relay never did that: it reads only the sender's device id, stores nothing, and catch-up is the daemon answering the phone's cursors from its own session log. State why sid/seq are cleartext at all (AEAD-bound against re-addressing, readable for diagnosis) and why ctr must be readable (replay window is checked before decryption). Comment-only change, spotted while sketching the multi-machine design in #2.
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.
Comment-only fix, spotted while drafting the multi-machine design sketch in #2.
The
Envelopedocs (crypto.ts,wire.ts) and theenvelopeHeaderdoc (channel.ts) still claim the relay keeps an ordered event log so a reconnecting phone can catch up, and that this is whysid/seqare readable in cleartext. That has never been the relay's job: it reads only the sender's device id for routing, stores nothing, and catch-up is the daemon answering the phone's cursors from its own ordered session log (catchUp).The corrected comments state the real reasons the fields are cleartext:
ctrmust be readable — the per-sender replay window is checked before decryption;sid/seqare AEAD-bound so a captured frame cannot be re-addressed to another session or position; the cleartext copy is useful for diagnosing traffic without the key.No behaviour change; the suite is untouched.