aboutsummaryrefslogtreecommitdiffstats
path: root/packages/meshbay-node/tests/test_stream_capacity.py
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-09-10 17:30:22 +0200
committerChristophe Besson <cbesson@gmail.com>2026-09-10 17:30:22 +0200
commit803e654086ac63e2d01fa4eb9cca50a4ebebcb73 (patch)
tree8b79995745bdb19da7fb3ec33b55a68f8cc73676 /packages/meshbay-node/tests/test_stream_capacity.py
parent6cf21a019963468cb853e5c763ef0097115efa46 (diff)
downloadmeshbay-803e654086ac63e2d01fa4eb9cca50a4ebebcb73.tar.gz
fix(node): device messages are authenticated-only, and the code now says so
`device_add_request` and `device_hello` were dispatched behind `and self._nonce_node`, which reads as "pre-proof, once the challenge has gone out" — and is not what happens: both branches sit after the `self._user_id is None` guard, so the nonce is always set by the time either is reached, and a peer that has not finished its handshake gets "Handshake required" instead. The guard is removed rather than the branches moved. Filing a device is not something a peer needs *in order to* prove possession of the group key, which is the only reason anything is served pre-proof: the request is countersigned later by a device already pinned, so requiring the caller to finish its own handshake first costs nothing and keeps the pre-proof surface at three messages. A test drives all six device messages through the real dispatcher on an unauthenticated session, because this is a property of the order of its branches and of nothing else. Node suite 1216 passed. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AsoWC3GmhNdwVFomW3QjH3
Diffstat (limited to 'packages/meshbay-node/tests/test_stream_capacity.py')
0 files changed, 0 insertions, 0 deletions