Conversation
PR SummaryMedium Risk Overview Hardens Telegram multi-account isolation by dropping inbound messages when a non-default account’s route resolution falls back to Written by Cursor Bugbot for commit 14f324c. This will update automatically on new commits. Configure here. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 14f324cbb7
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| }); | ||
| // Fail closed for named Telegram accounts when route resolution falls back to | ||
| // default-agent routing. This prevents cross-account DM/session contamination. | ||
| if (route.accountId !== DEFAULT_ACCOUNT_ID && route.matchedBy === "default") { |
There was a problem hiding this comment.
Scope non-default fallback drops to multi-account configurations
The new matchedBy === "default" guard drops all inbound traffic for any non-default Telegram account, including valid single-account deployments that only define a named account (for example accounts.opie) and rely on default routing. Because those installs commonly have no bindings, resolveAgentRoute returns matchedBy: "default" and this branch returns null, so every message is silently discarded until users add bindings. Please gate this fail-closed behavior to true multi-account risk cases (or another explicit opt-in), otherwise this change is a hard regression for named single-account setups.
Useful? React with 👍 / 👎.
Greptile SummaryThis PR hardens two security and correctness issues:
Both changes include comprehensive test coverage and documentation updates. The implementation correctly validates parameters before processing and applies the account isolation check early in the message handling pipeline. Confidence Score: 5/5
Last reviewed commit: 14f324c |
Summary
sessions_spawn(target,channel,to,threadId,replyTo,transport) with explicit tool-input errorsmatchedBy=defaultsessions_spawndelivery paramsTesting
Fixes #31000
Fixes #31110