CVE-2026-41372: OpenClaw: Trailing-dot localhost CDP hosts could bypass remote loopback protections
OpenClaw 2026.4.1 and earlier does not treat a trailing-dot host such as localhost. as loopback. A hostile remote Chrome DevTools Protocol (CDP) discovery response can return that host and pull OpenClaw's authenticated browser control back onto the OpenClaw machine. Upgrade to 2026.4.2.
Published Apr 7, 2026 · Updated May 6, 2026 · Analysis Oct 30, 2026
What an attacker can do
OpenClaw can drive a browser through a remote CDP endpoint. It asks the endpoint for discovery data, and the reply holds a websocket URL. OpenClaw has a rule that rewrites loopback hosts in that reply to the configured remote host, so a remote profile cannot be pointed at the local machine.
The check, parseHostForAddressChecks in src/gateway/net.ts, compared the host as written. A name like localhost. or LOCALHOST... did not match, though it resolves to the local machine. The rewrite was skipped, and the follow-up connection went to localhost on the OpenClaw host.
The attacker needs control of, or a position in front of, the remote CDP discovery response. No credentials or user action are needed. They can then aim authenticated browser control at a localhost service, for example a browser debugging port on the same host, and reach state that is meant to stay local. The CVSS vector shows a changed scope with low confidentiality impact. For teams that let an agent drive a browser, the risk is a local browser session reached through a remote profile.
Who is affected
openclaw on npm, version 2026.4.1 and earlier, for setups that use a remote CDP profile. Check the installed version:
npm ls openclawUse npm ls -g openclaw for a global install. Local-only browser profiles do not use the remote discovery path.
openclaw
- Ecosystem
- npm
- Affected
- <= 2026.4.1
- Fixed in
- 2026.4.2
- Check
npm ls openclaw
How to fix it
Upgrade to openclaw 2026.4.2 or later:
npm install [email protected]Commit 9c22d636697336a6b22b0ae24798d8b8325d7828 lowercases and trims the host and strips all trailing dots before the loopback check, so localhost., LOCALHOST... and similar forms count as loopback. The advisory lists no workaround. Only point remote CDP profiles at endpoints you control.
How to tell if you were hit
Check OpenClaw's browser logs for CDP websocket URLs with a host ending in a dot, such as ws://localhost.:9222, in a remote profile. Review which remote CDP endpoints your profiles use and who runs them. Look for unexpected connections from the OpenClaw process to local debugging ports. The sources give no log line for this exact case.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
Before OpenClaw 2026.4.2, remote CDP discovery could return a trailing-dot localhost host such as localhost. and bypass OpenClaw's loopback-host normalization. That let a non-loopback remote CDP profile pivot the follow-up connection back onto localhost.
Impact
A hostile discovery response could retarget authenticated browser control toward a localhost-resolving endpoint on the OpenClaw host. This weakened the existing remote-CDP loopback protection and could expose localhost-backed browser state.
Affected Packages / Versions
- Package:
openclaw(npm) - Affected versions:
<= 2026.4.1 - Patched versions:
>= 2026.4.2 - Latest published npm version:
2026.4.1
Fix Commit(s)
9c22d636697336a6b22b0ae24798d8b8325d7828— normalize localhost absolute-form CDP hosts before loopback checks
Release Process Note
The fix is present on main and is staged for OpenClaw 2026.4.2. Publish this advisory after the 2026.4.2 npm release is live.
Thanks @smaeljaish771 for reporting.
Credited to smaeljaish771, KeenSecurityLab.
Questions
- Which version fixes CVE-2026-41372?
OpenClaw 2026.4.2. Versions up to and including 2026.4.1 are affected.
- What is a trailing-dot localhost?
A fully qualified form of the name, such as localhost., that still resolves to the local machine. OpenClaw's check did not strip the dot, so it did not see the host as loopback.
- Does the attacker need an account?
No. The vector requires no privileges and no user interaction. They need to influence the CDP discovery response that a remote profile receives.
References
Read for this analysis:
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 entriesCVE-2026-62197
OpenClaw: Browser CDP discovery could accept blocked WebSocket URLs
medium8.5Oct 21, 2026CVE-2026-35630
OpenClaw: QQBot native approval buttons did not enforce configured approver identity
high8.0Jul 2, 2026CVE-2026-53806
OpenClaw: Combined POSIX shell options could confuse exec revalidation
high8.8Jul 2, 2026CVE-2026-53809
OpenClaw: Embedded runner policy could be confused by provider aliases
medium3.8Jul 2, 2026CVE-2026-53810
OpenClaw's marketplace runtime extension metadata could point at unscanned payloads
high8.8Jul 2, 2026CVE-2026-53811
OpenClaw: Matrix allowFrom could bind to mutable display names
high8.8Jul 2, 2026
