tui: mark friends invite-stale after an F8 prekey rotation #197
Loading…
Reference in a new issue
No description provided.
Delete branch "onionwire/t_bb01043d-f8-rotation-mark-friends-invite-stale-in"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Makes the F8 hard cut legible instead of leaving the next send looking delivered.
What changed (
src/node.rs,src/tui.rs,tests/tui_frames.rs,docs/TUI.md):rotate_prekey()now snapshots the roster into$ONIONWIRE_HOME/invite-stale(header + one hex identity pubkey per line, atomic write). This is derived local state — nosrc/store.rsschema change, no wire field, no new crate. An install that never pressed F8 has no file and marks nobody.Node::invite_stale(pk)/Node::invite_stale_friends()answer "was this friend last bootstrapped before the current prekey existed?".Node::sendandNode::send_oncefail closed withinvite stalefor a pre-rotation friend. Previously the ratchet re-bootstrapped silently from the peer's stored prekey, the frame encoded and looked sent, and the peer could not decrypt it.invite stale, with its own colour token (violet;stalekeeps meaning "the last dial did not answer"). The alert row above the panes carriesinvite stale — F2 to share your new invite, they F3-paste it, recomputed each draw, in the same place asfingerprint_mismatch_banner.add_friend_payload(F3 paste) removes the pubkey from the set, which clears the row marker and unblocks sends.docs/TUI.mddocuments the marker.This does not add in-band revocation or a soft/push prekey rotation —
docs/THREAT_MODEL.md's hard-cut wording stays exactly as it is, and no wire field is added.Evidence
cargo test --locked --target x86_64-unknown-linux-gnu: 38 suites, 577 passed / 0 failed / 4 ignored (network tests).cargo clippy --locked --all-targets --target x86_64-unknown-linux-gnu -- -D warnings: clean.rotating_the_prekey_marks_existing_friends_invite_stale,pasting_a_new_invite_clears_the_invite_stale_marker(node unit tests, red before the change),an_invite_stale_friend_is_marked_apart_from_a_dial_stale_one,the_invite_stale_hint_renders_above_the_panes_at_80_columns(draws the realdraw_main_chromeat 80x24; the rendered row is│ alice invite stale│, the hint row is 62 cells).git diff --stat:docs/TUI.md,src/node.rs,src/tui.rs,tests/tui_frames.rs— nosrc/store.rs.Stacking: base is the
filpadding branch; both cards editsrc/node.rs. Merge order is #196 (filpadding) first, then this PR.