Skip to content

fix: preserve gateway device auth when registering MC origin#434

Closed
eloe wants to merge 1 commit intobuilderz-labs:mainfrom
eloe:codex/fix-mc-device-auth-registration
Closed

fix: preserve gateway device auth when registering MC origin#434
eloe wants to merge 1 commit intobuilderz-labs:mainfrom
eloe:codex/fix-mc-device-auth-registration

Conversation

@eloe
Copy link

@eloe eloe commented Mar 17, 2026

Summary

  • preserve gateway.controlUi.dangerouslyDisableDeviceAuth when Mission Control registers its dashboard origin
  • keep registerMcAsDashboard() limited to gateway.controlUi.allowedOrigins
  • add regression coverage to ensure device auth is not weakened and re-registration stays idempotent

Risk Level

Low

Tests

  • pnpm lint
  • pnpm typecheck
  • pnpm test
  • pnpm build
  • pnpm quality:gate

Security Review

This change touches gateway auth posture. The previous behavior could silently set gateway.controlUi.dangerouslyDisableDeviceAuth=true during Mission Control dashboard-origin registration, weakening OpenClaw device authentication. This fix preserves the existing device-auth setting and limits registration to adding the Mission Control origin to gateway.controlUi.allowedOrigins.

Checklist

  • Tests added/updated for the change
  • Lint/typecheck/build passing
  • Security impact reviewed
  • Database migration not applicable

@eloe eloe requested a review from 0xNyk as a code owner March 17, 2026 22:07
@eloe eloe force-pushed the codex/fix-mc-device-auth-registration branch from e5400ce to 430ab9c Compare March 18, 2026 00:28
@0xNyk
Copy link
Member

0xNyk commented Mar 18, 2026

Thanks for the regression coverage here. I didn’t merge this PR directly because main already had the functional hardening in gateway-runtime.ts, and I merged that behavior plus equivalent regression tests in #446. Closing this as superseded by #446 so the history stays focused on the remaining compatibility fix.

@0xNyk 0xNyk closed this Mar 18, 2026
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.

3 participants