You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
server: a queued chord or text can still write after its sender's authority lapses during the RPC connect #545
A queued terminal chord or text passes the attachment, claim and authorization checks inside serialize(...), then waits for the herdr RPC's Unix socket to connect (herdrRpc in server/herdr/client.ts, Bun.connect). If the sender detaches, switches to observe, or has its device revoked during that wait, the request still writes pane.send_keys / pane.send_text when the connection resolves: nothing re-checks authority immediately before sock.write.
The window is the socket connect, normally well under a millisecond on a local herdr, so it is not reachable from the UI in practice. It is the same shape for every RPC the server issues after authorizeSocket, not only keys.
Where
server/index.ts, the keys and input handlers (the checks run before paneSendKeys / paneSendText).
server/herdr/client.ts, herdrRpc: the write happens after the awaited connect.
Possible fix
Carry a guard (a function or an AbortSignal tied to the attachment claim and the connection's authority) into the RPC helper and check it right before sock.write; requests whose authority is gone are dropped and answered input_failed.
Found by
Codex gpt-6.1-sol adversarial review of #508 at 471db0c (Medium). Pre-existing; not changed by #508.
Activity
feat(terminal): customize the mobile key bar (#508)
fix(terminal): recheck the sender's right to type right before herdr …
chore: sync with upstream devswha/herdr-web-ui main (devswha#624, dev…
fix(terminal): recheck mirror secret authority before Enter (#1065)