Telegram: allowlist senders, fail closed when unset #653

Closed
opened 2026-10-27 13:37:12 +00:00 by sam · 0 comments
Owner

telegram.New is called with a nil allowlist and isChatAllowed returns true when the allowlist is empty, so any Telegram user who finds the bot can talk to it. AllowedChatIDs is not plumbed into config at all. This gates exposing any real tools to the chat agent: with an MCP shell/filesystem server wired, allow-all becomes RCE for arbitrary senders.

Acceptance Criteria

Allowlist is configurable via config.toml. Unset means deny, not allow. Sender identity (user id) is checked, not just chat id, so a group chat cannot be used to bypass it. Rejections are logged with the sender id. Startup logs loudly when the chat gateway is enabled with an empty allowlist.


Imported from beads archie-core-1786637493121-128-2acad290 · GitHub #149 · type task · priority P2 · created 2026-08-08 · closed 2026-08-08

telegram.New is called with a nil allowlist and isChatAllowed returns true when the allowlist is empty, so any Telegram user who finds the bot can talk to it. AllowedChatIDs is not plumbed into config at all. This gates exposing any real tools to the chat agent: with an MCP shell/filesystem server wired, allow-all becomes RCE for arbitrary senders. ### Acceptance Criteria Allowlist is configurable via config.toml. Unset means deny, not allow. Sender identity (user id) is checked, not just chat id, so a group chat cannot be used to bypass it. Rejections are logged with the sender id. Startup logs loudly when the chat gateway is enabled with an empty allowlist. --- _Imported from beads `archie-core-1786637493121-128-2acad290` · GitHub #149 · type task · priority P2 · created 2026-08-08 · closed 2026-08-08_
sam added the mediumtask labels 2026-10-27 13:37:12 +00:00
sam self-assigned this 2026-10-27 13:37:12 +00:00
sam closed this issue 2026-10-27 13:37:12 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sam/archie#653