Skip to content

fix(ssh): bind relay-era legacy coordinators to their host and cap inbox reads (STA-10765 follow-up) - #29596

Merged
nwparker merged 1 commit into
mainfrom
nwparker/sta-10765-coordinator-host
Oct 16, 2026
Merged

nwparker merged 1 commit into
mainfrom
nwparker/sta-10765-coordinator-host

Conversation

@nwparker

@nwparker nwparker commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 2 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​27 0 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​27
Prod 10 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​39 $\color{#cf222e}{\Huge{\mathbf{−}}}$​11 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​28

ELI5

This is a small hardening follow-up to #29571, which lets terminals started by an older Orca on an SSH host run orca orchestration commands again. It closes two remaining gaps from that PR's security review and fixes one settings message.

What Changed

  • A legacy coordinator must come from its own host. A relay-era terminal is now accepted as a migrated Run's legacy coordinator only when the coordinator's committed record was made from the same SSH host the command came from. Before, the check matched the terminal handle and pane key but not the host, and a pane key alone is not unique across hosts.
  • Inbox reads are bounded. orca orchestration inbox --limit N from a relay-era terminal is clamped to between 1 and 100 rows. Before, the value went straight into the SQL LIMIT, where a negative number means "every row" and a huge one is unbounded.
  • Settings notice. The notice shown when Orca turned "Allow this host's orca CLI to control Orca" off after an update now says the switch also lets older-Orca terminals run orchestration commands, not only drive the browser. Updated in all locales and in the English default.

Why

Both code changes are narrow checks at the bridge's existing admission point (legacy-relay-cli-caller.ts and legacy-relay-cli-server.ts). Nothing else changes for other callers.

Linked Issue

Linear STA-10765 (follow-up to #29571).

Visual Proof

N/A. The only UI change is the wording of an existing settings notice.

Testing

  • Automated tests added/updated

New tests fail on main and pass here: a coordinator record made from another host is refused; --limit -1, 1000000000 and 0 reach the database as 1, 100 and 1. All 84 bridge tests pass, along with pnpm tc:node and check:code-quality:changed. Codex (gpt-6.1-sol, high) found no issues.

Agent skill upstream boundary

  • Not applicable.

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • N/A for screenshots
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote impact considered

… reads, and name orchestration in the reset notice (STA-10765)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant