Skip to content

fix(cron): retain host-verified requesters across channels - #201159

Merged
obviyus merged 1 commit into
mainfrom
fix/cron-requester-any-channel
Nov 18, 2026
Merged

obviyus merged 1 commit into
mainfrom
fix/cron-requester-any-channel

Conversation

@obviyus

@obviyus obviyus commented Nov 18, 2026

Copy link
Copy Markdown
Collaborator

Problem

Cron creation retained native requesters only for Telegram and Discord. Other host-authenticated channel owners lost their requester, and Discord used the reply account rather than the verified ingress account.

Change

Build on Vincent Koc's #201008 (febe293): use the shared host-bound command-owner channelPrincipal for every channel, requiring current authority and matching channel, account and sender. Remove channel-name branches and the configured-owner fallback. No schema, protocol or stored-row changes.

Discord uses the same host builder: its monitor provider passes the registered runtime's inbound builder to message and native-command ingress. The legacy path from #150308 (9ee5c26) predates the shared principal and no longer needs a separate authority source.

Removed fallback: The three session-event bindings carry internal_system provenance and cannot enter fresh channel cron capture. System-principal admission and queued owner refresh happen after the original factory capture; queued execution invokes that captured factory with the refreshed live owner check, not createReplyCronAuthorityFactory again. The inbound-tool overlay and followup-run bindings copy the full existing authority, preserving channelPrincipal. None of these bindings needs a newly invented native principal or relied on the removed config fallback for a verified external owner's creation path. Config-only/alias-only ingress and promotion without an originally verified owner deliberately no longer mint creator authority.

Evidence

Regression proof is vitest-source (no build):

  • Red on base f47b5c8655f5: captures a configured slack owner through the real host ingress (default/work) returned no requester despite a verified owner; records a slack owner's origin when creating a job within the visible tool cap failed at the missing host-bound requester.
  • Green: requester suite, 13 tests (8.71s); persisted-job integration, 15 tests (117.76s); prepared-metadata consumer, 1 test (30.47s); media-only/queued-authority consumer, 135 tests (147.64s). These are Vitest-reported file durations; hosted CI seconds are not available. The longer existing suites exercise real persistence, queued execution, grant adoption and account reload rather than replacing those boundaries with mocks. The integration reloads the saved requester, passes trigger evaluation with the account present, rejects an unavailable account, and rejects revoked/non-owner recovery.
  • tsgo:core, tsgo:core:test, changed-file oxfmt/oxlint, check:session-identity-ratchet, and check:lifetime-check-ratchet passed.

Production diff: +17 / -33 (net -16). Discord's old requester path is removed. Alias-only identity and promotion without an originally verified owner no longer mint authority; explicit host-bound Discord owner and revocation coverage remain.

- Use current command-owner principals instead of per-channel requester and configured-owner fallback paths.
- Extend Vincent Koc's #201008 coverage to Slack and Discord account persistence, queued authority, and revoked grants.
@clawsweeper

clawsweeper Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added gateway Gateway runtime size: M labels Nov 18, 2026
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 18, 2026
@obviyus
obviyus merged commit 00be7d5 into main Nov 18, 2026
122 checks passed
@obviyus
obviyus deleted the fix/cron-requester-any-channel branch November 18, 2026 11:40
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 19, 2026
…201159)

Problem: an automation created from a channel chat must remember who created it and on which account, so each run can check that owner. openclaw#201008 fixed this for Telegram with a Telegram-specific branch next to an older Discord-specific path; other channels (Slack, WhatsApp, ...) still saved no creator, and core code branched on channel names.

Fix: the creator comes from the owner identity that the shared channel ingress already verified (`channelPrincipal`, added in openclaw#201008), for every channel. The `discord`/`telegram` branches and the configured-owner fallback are removed. Missing, mismatched, revoked or unverified owner authority still cannot establish ownership.

User impact: automations created by a verified channel owner on any channel keep their creator and account, so their runs pass the account check. A sender recognized as owner only by config/alias matching, without a verified ingress identity, no longer creates automations as owner.

Proof: Slack host-ingress capture (default and work accounts) and persisted origin/requester integration fail on base and pass on head; existing Telegram and Discord cases pass. Builds on Vincent Koc's openclaw#201008.

Co-authored-by: Ayaan Zaidi <[email protected]>
RomneyDa added a commit that referenced this pull request Nov 19, 2026
Problem: an automation created from a channel chat must remember who created it and on which account, so each run can check that owner. #201008 fixed this for Telegram with a Telegram-specific branch next to an older Discord-specific path; other channels (Slack, WhatsApp, ...) still saved no creator, and core code branched on channel names.

Fix: the creator comes from the owner identity that the shared channel ingress already verified (`channelPrincipal`, added in #201008), for every channel. The `discord`/`telegram` branches and the configured-owner fallback are removed. Missing, mismatched, revoked or unverified owner authority still cannot establish ownership.

User impact: automations created by a verified channel owner on any channel keep their creator and account, so their runs pass the account check. A sender recognized as owner only by config/alias matching, without a verified ingress identity, no longer creates automations as owner.

Proof: Slack host-ingress capture (default and work accounts) and persisted origin/requester integration fail on base and pass on head; existing Telegram and Discord cases pass. Builds on Vincent Koc's #201008.

Co-authored-by: Ayaan Zaidi <[email protected]>

(cherry picked from commit 00be7d5)

Co-authored-by: RomneyDa <[email protected]>
github-actions Bot pushed a commit to clawhaven/openclaw that referenced this pull request Nov 23, 2026
…201159)

Problem: an automation created from a channel chat must remember who created it and on which account, so each run can check that owner. openclaw#201008 fixed this for Telegram with a Telegram-specific branch next to an older Discord-specific path; other channels (Slack, WhatsApp, ...) still saved no creator, and core code branched on channel names.

Fix: the creator comes from the owner identity that the shared channel ingress already verified (`channelPrincipal`, added in openclaw#201008), for every channel. The `discord`/`telegram` branches and the configured-owner fallback are removed. Missing, mismatched, revoked or unverified owner authority still cannot establish ownership.

User impact: automations created by a verified channel owner on any channel keep their creator and account, so their runs pass the account check. A sender recognized as owner only by config/alias matching, without a verified ingress identity, no longer creates automations as owner.

Proof: Slack host-ingress capture (default and work accounts) and persisted origin/requester integration fail on base and pass on head; existing Telegram and Discord cases pass. Builds on Vincent Koc's openclaw#201008.

Co-authored-by: Ayaan Zaidi <[email protected]>

Release adaptation: Split coherent23/41 preparation: retained native-account factory, caller and real ingress/queue tests consume preceding principal producer.

(cherry picked from commit 00be7d5)

Co-authored-by: RomneyDa <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. gateway Gateway runtime size: M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant