NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · OpenClaw

CVE-2026-43585: OpenClaw: Gateway HTTP endpoints re-resolve bearer auth after SecretRef rotation

criticalCVSS 4.0 9.2 · 3.1 8.1GHSA-xmxx-7p24-h892

OpenClaw before 2026.4.15 keeps accepting a revoked gateway bearer token after a SecretRef rotation, until the process restarts. The gateway HTTP and WebSocket handlers cached the bearer-auth config at startup. Anyone who still holds the old token keeps access. Upgrade to 2026.4.15.

Published Apr 17, 2026 · Updated May 12, 2026 · Analysis Oct 29, 2026

What an attacker can do

The OpenClaw gateway resolved its bearer-auth configuration once, when the server started, and its HTTP and WebSocket upgrade handlers kept using that value. When an operator rotated the secret behind a SecretRef, the running gateway still accepted the old token. The weakness is classed as use of a key past its expiration date (CWE-324) and operation on a resource after release (CWE-672).

So a token that leaked, was shared with a departed colleague, or was rotated out after an incident stayed valid for the whole life of the process. An attacker needs that old token and network access to the gateway. The attack complexity is high because the token must already be in the attacker's hands, but then the token authorizes gateway requests as before, with high confidentiality, integrity and availability impact. Operators believed the credential was dead, which makes this worse: there is no sign of the problem after a rotation. Long-running gateways that rarely restart are the most exposed.

Who is affected

The openclaw npm package before 2026.4.15, on gateways whose bearer auth comes from a SecretRef that you rotate. Check the version:

npm ls -g openclaw
openclaw --version

Also check how long the gateway process has been running since the last rotation.

openclaw

Ecosystem
npm
Affected
< 2026.4.15
Fixed in
2026.4.15
Check
npm ls openclaw

How to fix it

Upgrade to 2026.4.15:

npm install -g [email protected]

The fix, from PR 66651 (commit acd4e0a32f12e1ad85f3130f63b42443ce90f094), adds getResolvedAuth() in src/gateway/server.impl.ts, backed by the current runtime secret snapshot. src/gateway/server-http.ts calls it for each HTTP request and WebSocket upgrade before the auth checks. A test checks that /ready rejects the old token after rotation. After the upgrade, restart the gateway and rotate the bearer secret once more, since a token that leaked earlier may still be in use.

How to tell if you were hit

Compare gateway access logs against your rotation times: requests that authenticate after a rotation with a client or source address that should no longer have the token point to a stale token. Check how many gateway processes have been running since before the last rotation. The sources give no specific log line. Beam records agent shell commands and file access on the host, which helps you trace what a session using a stale token did.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Summary

Gateway HTTP and WebSocket handlers captured the resolved bearer-auth configuration when the server started. After a SecretRef rotation, the already-running gateway could continue accepting the old bearer token until restart.

Impact

A bearer token that should have been revoked by SecretRef rotation could remain valid on the gateway HTTP and upgrade surfaces for the lifetime of the process. Severity remains high because the old token could continue to authorize gateway requests after operators believed it was rotated out.

Affected versions

  • Affected: < 2026.4.15
  • Patched: 2026.4.15

Fix

OpenClaw 2026.4.15 resolves active gateway auth from the runtime secret snapshot per request and per upgrade instead of using a stale startup-time value.

Verified in v2026.4.15:

  • src/gateway/server.impl.ts exposes getResolvedAuth() backed by the current runtime secret snapshot.
  • src/gateway/server-http.ts calls getResolvedAuth() for each HTTP request and WebSocket upgrade before running auth checks.
  • src/gateway/server-http.probe.test.ts verifies /ready re-resolves bearer auth after rotation and rejects the old token.

Fix commit included in v2026.4.15 and absent from v2026.4.14:

  • acd4e0a32f12e1ad85f3130f63b42443ce90f094 via PR #66651

Thanks to @zsxsoft, Keen Security Lab, and @qclawer for reporting this issue.

Credited to zsxsoft, KeenSecurityLab, qclawer.

Questions

Does restarting the gateway close the hole?

A restart makes the process load the current secret, so the old token stops working. The flaw is that without a restart the old token worked for the process's lifetime. Upgrade anyway.

Which OpenClaw version fixes CVE-2026-43585?

2026.4.15. Everything before it is affected.

Why is attack complexity rated high?

The attacker must already hold a previously valid bearer token. The flaw does not let anyone guess or forge one.

Does this affect WebSocket connections?

Yes. The advisory says both the HTTP handlers and WebSocket upgrade surfaces kept the stale configuration.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More OpenClaw vulnerabilities

All OpenClaw entries