Repository navigation
Description
Bug type
Behavior bug (incorrect output/state without crash)
Beta release blocker
No
Summary
CLI commands including openclaw browser doctor, openclaw gateway health, and openclaw channels status fail with GatewaySecretRefUnavailableError when gateway.auth.password is configured via SecretRef, while openclaw gateway status --deep reports the gateway as healthy and reachable.
Steps to reproduce
- Configure OpenClaw with
gateway.auth.passwordstored as a SecretRef. - Start the gateway and verify it is running:
openclaw gateway status --deep - Run:
openclaw gateway health - Observe:
GatewaySecretRefUnavailableError - Run:
openclaw browser doctor
or
openclaw channels status - Observe the same
GatewaySecretRefUnavailableError. - Run:
openclaw gateway status --deep - Observe that the gateway reports:
- Runtime: running
- Connectivity probe: ok
- Capability: admin-capable
Expected behavior
Commands that communicate with a healthy local gateway should resolve SecretRef-backed gateway credentials the same way as openclaw gateway status --deep and should not fail with GatewaySecretRefUnavailableError.
Actual behavior
openclaw gateway health, openclaw browser doctor, and openclaw channels status fail with:
GatewaySecretRefUnavailableError: gateway.auth.password is configured as a secret reference but is unavailable in this command path.
At the same time, openclaw gateway status --deep reports:
- Runtime: running
- Connectivity probe: ok
- Capability: admin-capable
The issue was observed with gateway.auth.password configured as a SecretRef.
OpenClaw version
2026.6.5
Operating system
Linux Mint 22.3 (based on Ubuntu 24.04 LTS)
Install method
npm global install
Model
google/gemini-3.1-pro-preview
Provider / routing chain
OpenRouter -> Google Gemini
Additional provider/model setup details
Issue reproduces before any model inference occurs. The problem appears related to SecretRef-backed gateway authentication resolution in CLI commands.
Logs, screenshots, and evidence
openclaw gateway health
GatewaySecretRefUnavailableError: gateway.auth.password is configured as a secret reference but is unavailable in this command path.
Fix: set OPENCLAW_GATEWAY_TOKEN/OPENCLAW_GATEWAY_PASSWORD, pass explicit --token/--password,
or run a gateway command path that resolves secret references before credential selection.
openclaw channels status
Gateway not reachable: gateway.auth.password is configured as a secret reference but is unavailable in this command path.
openclaw browser doctor
FAIL gateway: GatewaySecretRefUnavailableError: gateway.auth.password is configured as a secret reference but is unavailable in this command path.
<img width="1920" height="1080" alt="Image" src="https://github.com/user-attachments/assets/d6e99f27-588f-4619-a677-83e50abb624d" />
<img width="1920" height="1080" alt="Image" src="https://github.com/user-attachments/assets/86768883-fb61-4290-8c84-bbe3b36a6eb3" />
<img width="1920" height="1080" alt="Image" src="https://github.com/user-attachments/assets/f6e4d396-65e4-4270-982b-d94d5be9e95a" />Impact and severity
Operators using SecretRef-backed gateway authentication may be unable to use gateway-dependent CLI commands even when the gateway is healthy and reachable. The issue affects diagnostics and browser/channel tooling and can make a healthy installation appear broken.
Additional information
The gateway password is configured as a SecretRef and intentionally not stored in plaintext. This installation uses Bitwarden Secrets Manager. The gateway starts successfully, reports healthy status via openclaw gateway status --deep, and Google Chat functions correctly, but several CLI commands fail with GatewaySecretRefUnavailableError.
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
clawsweeper commentedon Jun 10, 2026
Codex review: keeping this open for maintainer follow-up; there is still a little grit to resolve. Reviewed June 11, 2026, 6:18 PM ET / 22:18 UTC.
Summary
Codex review failed: retryable codex transport failure (exit 1).
Reproducibility: unclear. The review failed before ClawSweeper could establish a reproduction path.
Ways to help us reproduce this
Next step
Review did not complete, so no work-lane recommendation was made.
Review details
Best possible solution:
Retry the Codex review after fixing the execution failure.
Do we have a high-confidence way to reproduce the issue?
Unclear. The review failed before ClawSweeper could establish a reproduction path.
Is this the best way to solve the issue?
Unclear. Retry the review first so ClawSweeper can evaluate the actual issue and fix direction.
AGENTS.md: unclear because the file could not be read completely.
Remaining risk / open question:
Codex review notes: model internal, reasoning high; reviewed against 301213a05f2f.
Label changes
Label changes:
issue-rating: 🦪 silver shellfish: Current issue advisory state selects this label.clawsweeper:needs-info: Current issue advisory state selects this label.P2: Current review triage priority is none.clawsweeper:no-new-fix-pr: Current issue advisory state no longer selects this label.clawsweeper:needs-maintainer-review: Current issue advisory state no longer selects this label.clawsweeper:needs-live-repro: Current issue advisory state no longer selects this label.impact:security: Current review selected no impact labels.impact:auth-provider: Current review selected no impact labels.issue-rating: 🐚 platinum hermit: Current issue advisory state no longer selects this label.Evidence reviewed
What I checked:
Likely related people:
How this review workflow works
@clawsweeper re-reviewcomments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.@clawsweeper re-reviewor@clawsweeper re-runon an open PR or issue to request a fresh review only.@clawsweeper reviewto request a fresh review only.@clawsweeper autofix,@clawsweeper automerge,@clawsweeper fix ci, or@clawsweeper address review.@clawsweeper explainto ask for more context, or@clawsweeper stopto stop active automation.harjothkhara commentedon Jun 10, 2026
Root cause + scope mapping for #91815
Traced this on
main@bf89552e67. The split is in how each command handles an unresolvablegateway.auth.passwordSecretRef:openclaw gateway status --deeptolerates it because the probe path uses the Safe resolverresolveGatewayProbeAuthSafeWithSecretInputs(src/gateway/probe-auth.ts), which catchesGatewaySecretRefUnavailableError, warns "SecretRef is unresolved in this command path; probing without configured auth credentials," and degrades to an unauthenticated probe.openclaw gateway health,openclaw channels status, andopenclaw browser doctorall reach the gateway via the strictcallGateway→resolveGatewayCredentialsWithSecretInputs(src/gateway/call.ts), which propagatesGatewaySecretRefUnavailableErrorand hard-fails. Call sites:src/cli/daemon-cli/probe.ts(health RPC),src/commands/channels/status.ts:243, andextensions/browser→callGatewayFromCli(plugin SDK) forbrowser doctor.This looks like the same class addressed for
doctorin00067563a6(fix(doctor): handle gateway SecretRefs in auth checks) — i.e. don't hard-fail on an unavailable gateway SecretRef; report a read-only warning and continue, with exec-backed refs gated behind an explicit--allow-exec. That commit covered thedoctor --linthealth surface but not these three read-only status commands.Before proposing a patch, I'd like to confirm the intended contract for these three commands when
gateway.auth.passwordis a SecretRef that can't be resolved in the command's context:status --deep— emit the same "unresolved in this command path" warning and run the degraded/unauthenticated path (smallest change: route them throughresolveGatewayProbeAuthSafe*/ catch-and-warn aroundcallGateway).OPENCLAW_GATEWAY_PASSWORD/--password) instead of a rawGatewaySecretRefUnavailableError.And: should exec-backed refs here require the same
--allow-execopt-in introduced in00067563a6?Happy to send a PR once the desired behavior is confirmed. (Note: a faithful real-behavior proof for exec-backed refs needs live secret-provider infra; I can cover file/env-backed SecretRefs locally.)
mattsfraser commentedon Jun 10, 2026
Additional context: this appears to be a regression after updating to OpenClaw
2026.6.5.Before the update, this installation was operating with
gateway.auth.passwordconfigured as a SecretRef backed by Bitwarden Secrets Manager. After updating to2026.6.5, the gateway itself still starts successfully andopenclaw gateway status --deepreports the gateway as running, reachable, and admin-capable, but several gateway-dependent CLI commands now fail withGatewaySecretRefUnavailableError.The important point is that this setup is intentionally not using a plaintext gateway password in ordinary config. The gateway credential is meant to remain SecretRef-backed. So from an operator perspective, the failure is not that the gateway is down; it is that some CLI command paths appear unable to resolve or tolerate the SecretRef-backed gateway credential after the update.
The affected commands observed so far include:
The working/contrasting command is:
That command continues to report the gateway as healthy/reachable/admin-capable.
So I think the core issue is correctly described as a command-path inconsistency/regression around SecretRef-backed
gateway.auth.passwordhandling in2026.6.5.I am not requesting a workaround that stores the gateway password in plaintext or bypasses Bitwarden Secrets Manager. The desired behavior is that SecretRef-backed gateway auth remains supported, and that read-only diagnostic/status commands either:
gateway status --deep, orGatewaySecretRefUnavailableError.Happy to provide more terminal output if helpful.
joshavant commentedon Jun 12, 2026
Thanks for the clear report and follow-up context, @mattsfraser.
This was fixed by #92290. The issue was the split you described: the Gateway process could start with the SecretRef-backed
gateway.auth.password, andopenclaw gateway status --deepused the safe probe path, but several diagnostic/read-only commands still went through strict client-side Gateway credential resolution and surfacedGatewaySecretRefUnavailableError.The fix keeps strict Gateway RPC calls fail-closed, but updates the diagnostic paths to handle this state cleanly:
openclaw health/openclaw gateway healthnow report the Gateway as reachable but requiring credentials.openclaw channels statusnow falls back to config-only output with an auth-unavailable message instead of saying the Gateway is unreachable.openclaw browser doctornow shows a readable SecretRef auth diagnostic.openclaw doctor --allow-execnow treats the reachable Gateway as healthy-but-unauthenticated instead of reporting a raw health failure.We verified this against a real Gateway setup with the env SecretRef visible only to the Gateway process, matching the command-path inconsistency from the report.