security(telegram): fail closed group allowlist against DM pairing store#25988
Merged
obviyus merged 3 commits intoopenclaw:mainfrom Feb 26, 2026
Merged
security(telegram): fail closed group allowlist against DM pairing store#25988obviyus merged 3 commits intoopenclaw:mainfrom
obviyus merged 3 commits intoopenclaw:mainfrom
Conversation
thebtf
pushed a commit
to thebtf/openclaw
that referenced
this pull request
Feb 25, 2026
openclaw#25988 - openclaw#26229: replace Agent with EnvHttpProxyAgent in global undici dispatcher so HTTP_PROXY/HTTPS_PROXY env vars are respected for all outbound fetch calls (regression fix from openclaw#25682 that overwrote proxy-aware dispatcher) - openclaw#26264: lower text fragment aggregation threshold 4000→3600 chars to reliably catch structured content that Telegram splits at ~3800 chars - openclaw#25988: fail closed group allowlist against DM pairing store — group sender checks now use only explicit groupAllowFrom config, not the DM pairing store (security: DM-paired senders cannot bypass group allowlist)
nikolasdehor
approved these changes
Feb 25, 2026
nikolasdehor
left a comment
There was a problem hiding this comment.
Important security boundary fix. The DM pairing store is a dynamic, user-initiated data source — allowing it to populate the group allowlist means any user who completes DM pairing automatically gains group access, which is a privilege escalation. Switching effectiveGroupAllow from normalizeAllowFromWithStore to normalizeAllowFrom (static config only) in both bot-message-context.ts and helpers.ts correctly isolates the two authorization domains. The test case directly validates the invariant: a sender present in the pairing store but absent from groupAllowFrom is blocked in group context.
56bbd37 to
21dfe5c
Compare
Contributor
|
Landed via temp rebase onto main.
Thanks @bmendonca3! |
2 tasks
execute008
pushed a commit
to execute008/openclaw
that referenced
this pull request
Feb 27, 2026
r4jiv007
pushed a commit
to r4jiv007/openclaw
that referenced
this pull request
Feb 28, 2026
vincentkoc
pushed a commit
to Sid-Qin/openclaw
that referenced
this pull request
Feb 28, 2026
vincentkoc
pushed a commit
to rylena/rylen-openclaw
that referenced
this pull request
Feb 28, 2026
6 tasks
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 1, 2026
…anks @bmendonca3) (cherry picked from commit 3b02985) # Conflicts: # CHANGELOG.md
steipete
pushed a commit
to Sid-Qin/openclaw
that referenced
this pull request
Mar 2, 2026
robertchang-ga
pushed a commit
to robertchang-ga/openclaw
that referenced
this pull request
Mar 2, 2026
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 3, 2026
…anks @bmendonca3) (cherry picked from commit 3b02985) # Conflicts: # CHANGELOG.md
dorgonman
pushed a commit
to kanohorizonia/openclaw
that referenced
this pull request
Mar 3, 2026
zooqueen
pushed a commit
to hanzoai/bot
that referenced
this pull request
Mar 6, 2026
thebenjaminlee
pushed a commit
to escape-velocity-ventures/openclaw
that referenced
this pull request
Mar 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
groupAllowFromand per-group/per-topicallowFrom).Change Type
Scope
src/telegram/bot/helpers.tssrc/telegram/bot-message-context.tssrc/telegram/bot.create-telegram-bot.test.tsSecurity Impact
readChannelAllowFromStore("telegram")) was merged into group sender authorization.groupAllowFromcould still trigger group message handling undergroupPolicy="allowlist".Repro + Verification
Deterministic regression scenario:
groupPolicy: "allowlist"andgroupAllowFrom: ["222222222"].123456789(so it exists in pairing store).123456789.Targeted checks:
Evidence
blocks group sender not in groupAllowFrom even when sender is paired in DM storeHuman Verification
Compatibility / Migration
groupAllowFrom(or group/topicallowFrom).Failure Recovery
Risks and Mitigations
Greptile Summary
Removes DM pairing store fallback from Telegram group sender authorization, preventing unauthorized group access by DM-paired users.
Key Changes:
normalizeAllowFromWithStorewithnormalizeAllowFromin group allowlist evaluation (bot-message-context.ts:198,bot/helpers.ts:52)groupAllowFromor per-group/topicallowFromconfiguration123456789is blocked from group when only222222222is ingroupAllowFromSecurity Context:
This fix mirrors the iMessage pairing-store bypass fix (commit
872079d42) and follows the same fail-closed pattern. The vulnerability allowed senders paired for DM access to trigger bot actions in groups where they should be blocked by allowlist policy.Confidence Score: 5/5
normalizeAllowFromWithStore(which merges DM pairing store) tonormalizeAllowFrom(explicit config only), directly addressing the documented security boundary crossing. The regression test validates the fix, and the pattern matches the proven iMessage fix from commit 872079d. No logic errors or edge cases detected.Last reviewed commit: 8ba4b3a