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

CVE-2026-32913: OpenClaw: fetch-guard forwards custom authorization headers across cross-origin redirects

highCVSS 4.0 8.8 · 3.1 9.3GHSA-6mgf-v5j7-45cr

OpenClaw's fetchWithSsrFGuard followed cross-origin redirects and removed only four headers (Authorization, Proxy-Authorization, Cookie, Cookie2). Custom credential headers such as X-Api-Key or Private-Token went on to the new origin. openclaw 2026.3.2 and earlier are affected; 2026.3.7 is patched.

Published Mar 9, 2026 · Updated Mar 30, 2026 · Analysis Oct 31, 2026

What an attacker can do

fetchWithSsrFGuard is the guarded fetch that OpenClaw callers use for outbound requests. When a response redirected to a different origin, it stripped a short denylist and kept every other caller-supplied header. Any API key or token carried in a non-standard header therefore reached whichever host the redirect named.

An attacker needs a remote service that can make a request redirect across origins: a server the agent is told to fetch from, or a compromised endpoint. They then collect the key from the redirected request. The result is exposure of API keys, bearer-style custom headers and private token headers meant only for the original destination (CWE-522, with an incomplete denylist as the root cause, CWE-184). The advisory scores confidentiality impact as high. No account or user interaction is needed.

Who is affected

The openclaw npm package, up to and including 2026.3.2. The advisory data names 2026.3.7 as the patched release, published on March 8, 2026. The impact applies to calls that attach custom credential headers to guarded fetches.

npm ls -g openclaw
openclaw --version

openclaw

Ecosystem
npm
Affected
<= 2026.3.2
Fixed in
2026.3.7
Check
npm ls openclaw

How to fix it

Upgrade to openclaw 2026.3.7 or later.

npm install -g [email protected]

The fix (commit 4671537) swaps the denylist for an allowlist. On a cross-origin redirect only these headers survive: accept, accept-encoding, accept-language, cache-control, content-language, content-type, if-match, if-modified-since, if-none-match, if-unmodified-since, pragma, range and user-agent. Everything else, including X-Api-Key and Private-Token, is dropped. The sources give no workaround; rotate keys that may have gone to an untrusted host.

How to tell if you were hit

Review outbound request logs for redirects from the services OpenClaw calls to hosts you do not recognize, and for requests to those hosts that carry X-Api-Key, Private-Token or similar headers. Check the provider side for use of your API keys from unfamiliar addresses. Beam records agent shell commands and MCP tool calls, which can show which fetches an agent made, though the leaked header itself is visible only in network logs.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

OpenClaw's fetchWithSsrFGuard(...) followed cross-origin redirects while preserving arbitrary caller-supplied headers except for a narrow denylist (Authorization, Proxy-Authorization, Cookie, Cookie2). This allowed custom authorization headers such as X-Api-Key, Private-Token, and similar sensitive headers to be forwarded to a different origin after a redirect.

The fix switches cross-origin redirect handling from a narrow sensitive-header denylist to a safe-header allowlist, so only benign headers such as content negotiation and cache validators survive an origin change.

Affected Packages / Versions

  • Package: openclaw (npm)
  • Affected versions: <= 2026.3.2
  • Patched version: 2026.3.7
  • Latest published npm version at patch time: 2026.3.2

Impact

A remote service that could trigger a redirect across origins could receive custom authorization credentials attached by OpenClaw callers. This can expose API keys, bearer-style custom headers, or private token headers intended only for the original destination.

Fix Commit(s)

  • 46715371b0612a6f9114dffd1466941ac476cef5

Verification

  • pnpm check passed
  • pnpm test:fast passed
  • Focused redirect regression tests passed
  • pnpm exec vitest run --config vitest.gateway.config.ts still has unrelated current-main failures in src/gateway/server-channels.test.ts and src/gateway/server-methods/agents-mutate.test.ts

Release Process Note

npm 2026.3.7 was published on March 8, 2026. This advisory is fixed in the released package.

Thanks @Rickidevs for reporting.

Credited to Rickidevs.

Questions

Which headers leaked in CVE-2026-32913?

Any custom header other than Authorization, Proxy-Authorization, Cookie and Cookie2, for example X-Api-Key and Private-Token.

Which version fixes it?

openclaw 2026.3.7. Versions up to 2026.3.2 are affected.

How does the fix work?

It uses a safe-header allowlist on cross-origin redirects, so only benign headers like accept, content-type and cache validators are kept.

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