openclaw - 💡(How to fix) Fix Built-in exec from Control UI always fails with "pairing required" on local Windows gateway, even with auth disabled and full local exec approvals [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#63194Fetched 2026-04-09 07:57:12
View on GitHub
Comments
0
Participants
1
Timeline
2
Reactions
0
Author
Participants
Timeline (top)
labeled ×2

Built-in exec from the local Windows Control UI fails with gateway closed (1008): pairing required even when gateway auth is disabled, device auth is disabled, and local exec approvals are set to full.

Error Message

Key error: Exec approval registration failed: Error: gateway closed (1008): pairing required

Gateway target: ws://127.0.0.1:18789 Source: local loopback Config: E:\OpenClaw_Data\openclaw.json Bind: loopback

Also observed:

  • openclaw approvals get --gateway fails with pairing required
  • local terminal commands work normally
  • Control UI chat works, but built-in exec fails

Root Cause

Built-in exec from the local Windows Control UI fails with gateway closed (1008): pairing required even when gateway auth is disabled, device auth is disabled, and local exec approvals are set to full.

Code Example

Key error:
`Exec approval registration failed: Error: gateway closed (1008): pairing required`

Gateway target: ws://127.0.0.1:18789
Source: local loopback
Config: E:\OpenClaw_Data\openclaw.json
Bind: loopback

Also observed:
- `openclaw approvals get --gateway` fails with `pairing required`
- local terminal commands work normally
- Control UI chat works, but built-in exec fails
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

Built-in exec from the local Windows Control UI fails with gateway closed (1008): pairing required even when gateway auth is disabled, device auth is disabled, and local exec approvals are set to full.

Steps to reproduce

  1. On native Windows, start OpenClaw with a local loopback gateway.
  2. Set gateway.mode=local.
  3. Disable gateway auth and disable Control UI device auth.
  4. Set local exec approvals to full (security=full, ask=off, askFallback=full).
  5. Open the Control UI and start a fresh session.
  6. Trigger built-in exec with a trivial command such as python -c "print('auto-op test ok')" or openclaw status.
  7. Observe the exec request fail with gateway closed (1008): pairing required.

Expected behavior

Built-in exec from the local Control UI session should succeed for trivial local commands, or fail with a more specific authorization error if another trust requirement still applies.

Actual behavior

Built-in exec fails immediately with Exec approval registration failed: Error: gateway closed (1008): pairing required. The local CLI works normally, but the Control UI exec path does not.

OpenClaw version

2026.4.8 (9ece252)

Operating system

Windows 11 25H2 x64

Install method

npm global (npm install -g openclaw@latest --omit=optional), then manually installed missing runtime dependencies

Model

openrouter/xiaomi/mimo-v2-pro

Provider / routing chain

openclaw -> openrouter

Additional provider/model setup details

NOT_ENOUGH_INFO

Logs, screenshots, and evidence

Key error:
`Exec approval registration failed: Error: gateway closed (1008): pairing required`

Gateway target: ws://127.0.0.1:18789
Source: local loopback
Config: E:\OpenClaw_Data\openclaw.json
Bind: loopback

Also observed:
- `openclaw approvals get --gateway` fails with `pairing required`
- local terminal commands work normally
- Control UI chat works, but built-in exec fails

Impact and severity

Affected: local Windows Control UI sessions Severity: High (blocks built-in exec from the Control UI) Frequency: Always in observed attempts Consequence: assistant-side local command execution is unusable from the Control UI even though the gateway is local and approvals were relaxed

Additional information

This setup was migrated from an older machine/state directory.

Current active state dir: E:\OpenClaw_Data Old migrated dir: C:\Users\wan.openclaw

There was previously a warning about multiple state directories. This may be relevant if pairing or trust state survived migration inconsistently.

extent analysis

TL;DR

The most likely fix is to re-pair the gateway or reset the trust state to resolve the "pairing required" error.

Guidance

  • Verify that the gateway mode is correctly set to local and that gateway auth is disabled.
  • Check the openclaw.json config file to ensure that the settings for security, ask, and askFallback are correctly applied.
  • Attempt to reset the trust state by running openclaw approvals reset or re-pairing the gateway using openclaw gateway pair.
  • Investigate the warning about multiple state directories and consider migrating the state directory to a single, consistent location.

Example

No code snippet is provided as the issue does not require a specific code change.

Notes

The issue may be related to the migration of the state directory from an older machine, which could have resulted in inconsistent trust state. Resetting the trust state or re-pairing the gateway may resolve the issue.

Recommendation

Apply a workaround by resetting the trust state or re-pairing the gateway, as the root cause of the issue is likely related to the inconsistent trust state after migration.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Built-in exec from the local Control UI session should succeed for trivial local commands, or fail with a more specific authorization error if another trust requirement still applies.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING