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

CVE-2026-28464: OpenClaw has non-constant-time token comparison in hooks authentication

highCVSS 4.0 8.2 · 3.1 5.9GHSA-jmm5-fvh5-gf4p

OpenClaw compared the hooks token with an ordinary string comparison, which leaks timing information. An attacker with network access to the hooks endpoint could, with many requests, infer the token. Versions before 2026.2.12 are affected. Upgrade the `openclaw` npm package to 2026.2.12 and rotate the hooks token.

Published Mar 2, 2026 · Updated Mar 6, 2026 · Analysis Oct 31, 2026

What an attacker can do

The gateway checked the hook token in src/gateway/server-http.ts with a plain !==. That comparison stops at the first differing character, so the response time depends slightly on how much of the guess is correct. An attacker who sends a great number of guesses and measures response times could recover the token one character at a time (CWE-208).

The advisory is frank about the limits. It typically requires the hooks endpoint to be exposed to an untrusted network and a large number of requests, and real-world latency and jitter make reliable measurement difficult. That is why the CVSS vectors rate attack complexity as high.

If the attack succeeds, the attacker holds the hooks token. That lets them call the hooks endpoint as an authorized caller, which can trigger agent actions in deployments where hooks are wired to agents. The advisory scores the impact as confidentiality only. It does not say the flaw is exploited in the wild. Deployments with hooks bound to loopback or a private network face little practical risk.

Who is affected

Affected: the openclaw npm package before 2026.2.12, where the hooks endpoint is enabled and reachable from an untrusted network. Setups with no hooks endpoint, or one limited to a trusted network, are much less exposed.

Check the version:

npm ls openclaw

For a global install, use npm ls -g openclaw.

openclaw

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

How to fix it

Upgrade to openclaw 2026.2.12 or later:

npm install [email protected]

The fix (commit 113ebfd6) adds a safeEqualSecret helper built on crypto.timingSafeEqual, used for the hook token, the gateway token and password, and device tokens. It also rate-limits failed hook authentication per client: after 20 failures in 60 seconds, the server answers 429 with a Retry-After header.

If you cannot upgrade right away, restrict network access to the hooks endpoint. After updating, rotate the hooks token, since an old one may have leaked.

How to tell if you were hit

Look in gateway and reverse-proxy access logs for long runs of failed requests to the hooks endpoint from one address, with 401 responses and bodies of similar size. A timing attack needs thousands of near-identical requests. After the fix, such bursts show up as 429 responses. If you saw bursts before upgrading, rotate the hooks token and review what the hooks endpoint triggered.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Summary

OpenClaw hooks previously compared the provided hook token using a regular string comparison. Because this comparison is not constant-time, an attacker with network access to the hooks endpoint could potentially use timing measurements across many requests to gradually infer the token.

In practice, this typically requires hooks to be exposed to an untrusted network and a large number of requests; real-world latency and jitter can make reliable measurement difficult.

Affected Packages / Versions

  • openclaw (npm): < 2026.2.12

Patched Versions

  • openclaw (npm): >= 2026.2.12

Mitigations

  • Upgrade to openclaw >= 2026.2.12.
  • If users cannot upgrade immediately: restrict network access to the hooks endpoint and rotate the hooks token after updating.

Fix Commit(s)

  • 113ebfd6a23c4beb8a575d48f7482593254506ec

OpenClaw thanks @akhmittra for reporting.

Credited to akhmittra.

Questions

Is CVE-2026-28464 practical to exploit?

The advisory says it typically needs the hooks endpoint exposed to an untrusted network and a large number of requests, and jitter makes measurement difficult. It is real but hard.

What should I do if I cannot upgrade immediately?

Restrict network access to the hooks endpoint. After you update, rotate the hooks token.

Which version fixes it?

2026.2.12. Earlier versions are affected.

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