fix: Control UI Insecure Auth Bypass Allows Token-Only Auth Over HTTP#20684
Merged
mbelinky merged 1 commit intoopenclaw:mainfrom Feb 20, 2026
Merged
fix: Control UI Insecure Auth Bypass Allows Token-Only Auth Over HTTP#20684mbelinky merged 1 commit intoopenclaw:mainfrom
mbelinky merged 1 commit intoopenclaw:mainfrom
Conversation
src/security/audit.ts
Outdated
Contributor
There was a problem hiding this comment.
security audit message outdated - allowInsecureAuth no longer skips device identity or pairing after this fix
Suggested change
| "gateway.controlUi.allowInsecureAuth is deprecated and no longer bypasses security checks.", |
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/security/audit.ts
Line: 352
Comment:
security audit message outdated - allowInsecureAuth no longer skips device identity or pairing after this fix
```suggestion
"gateway.controlUi.allowInsecureAuth is deprecated and no longer bypasses security checks.",
```
How can I resolve this? If you propose a fix, please make it concise.b228890 to
ad9be4b
Compare
Contributor
rodrigogs
pushed a commit
to rodrigogs/openclaw
that referenced
this pull request
Feb 20, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
Hansen1018
added a commit
to Hansen1018/openclaw
that referenced
this pull request
Feb 21, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
vincentkoc
pushed a commit
that referenced
this pull request
Feb 21, 2026
…#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
dgarson
pushed a commit
to dgarson/clawdbot
that referenced
this pull request
Feb 21, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
mmyyfirstb
pushed a commit
to mmyyfirstb/openclaw
that referenced
this pull request
Feb 21, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
obviyus
pushed a commit
to guirguispierre/openclaw
that referenced
this pull request
Feb 22, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
mreedr
pushed a commit
to mreedr/openclaw-custom
that referenced
this pull request
Feb 24, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
xianfeng92
pushed a commit
to xianfeng92/openclaw
that referenced
this pull request
Feb 24, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky (cherry picked from commit 40a2926)
6 tasks
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 1, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky (cherry picked from commit 40a2926) # Conflicts: # CHANGELOG.md # src/gateway/server.auth.e2e.test.ts # src/gateway/server/ws-connection/message-handler.ts
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 3, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky (cherry picked from commit 40a2926) # Conflicts: # CHANGELOG.md # src/gateway/server.auth.e2e.test.ts # src/gateway/server/ws-connection/message-handler.ts
This was referenced Mar 5, 2026
zooqueen
pushed a commit
to hanzoai/bot
that referenced
this pull request
Mar 6, 2026
…openclaw#20684) Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: ad9be4b Co-authored-by: coygeek <[email protected]> Co-authored-by: mbelinky <[email protected]> Reviewed-by: @mbelinky
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.
Fix Summary
The
gateway.controlUi.allowInsecureAuthconfiguration option allows the Control UI to authenticate using only a token over unencrypted HTTP, bypassing both device identity verification and the device pairing requirement. This enables man-in-the-middle attacks where an attacker can intercept the token and gain full administrative access to the gateway.Issue Linkage
Fixes #20683
Security Snapshot
Implementation Details
Files Changed
src/gateway/server.auth.e2e.test.ts(+24/-4)src/gateway/server/ws-connection/message-handler.ts(+6/-2)Technical Analysis
When
gateway.controlUi.allowInsecureAuth: trueis set, theallowControlUiBypassflag is set totrueinside the WebSocket handshake handler. This flag suppresses two distinct security checks: (1) the HTTPS/localhost enforcement block that normally rejects non-secure Control UI connections, and (2) the device pairing requirement that gates new devices. The result is that any client presenting a valid shared secret (token or password) is granted full operator-level scopes over an unencrypted HTTP connection. No device identity is registered or verified. Tokens in transit are fully plaintext-exposed.Validation Evidence
pnpm build && pnpm check && pnpm testRisk and Compatibility
non-breaking; no known regression impact
AI-Assisted Disclosure
Greptile Summary
This PR fixes a critical security vulnerability where
gateway.controlUi.allowInsecureAuth: trueallowed Control UI to bypass both HTTPS/localhost enforcement and device pairing requirements, enabling man-in-the-middle attacks over unencrypted HTTP.Changes Made
allowControlUiBypasscalculation to excludeallowInsecureControlUiflag, ensuringallowInsecureAuthno longer bypasses secure-context or device-auth checksallowInsecureAuthis enabledinsecureAuthConfiguredis set during failed handshake attemptsIssues Found
src/security/audit.ts:352still describes the old insecure behavior and needs updating to reflect thatallowInsecureAuthno longer bypasses security checksConfidence Score: 4/5
Last reviewed commit: b228890