Skip to content

OpenClaw affected by Stored XSS in Control UI via unsanitized assistant name/avatar in inline script injection

Moderate severity GitHub Reviewed Published Feb 18, 2026 in openclaw/openclaw • Updated Feb 20, 2026

Package

npm openclaw (npm)

Affected versions

< 2026.2.15

Patched versions

2026.2.15

Description

Summary

Stored XSS in the OpenClaw Control UI when rendering assistant identity (name/avatar) into an inline <script> tag without script-context-safe escaping. A crafted value containing </script> could break out of the script tag and execute attacker-controlled JavaScript in the Control UI origin.

Affected Packages / Versions

  • Package: openclaw (npm)
  • Affected versions: <= 2026.2.14
  • Fixed in: >= 2026.2.15 (next release; fix is already merged on main)

Details

The gateway Control UI HTML response previously injected assistantName and assistantAvatar directly into an inline <script> block using JSON.stringify(...). JSON.stringify does not prevent </script> from terminating the script element, enabling stored XSS if an operator/admin sets the assistant identity to a malicious string.

OpenClaw’s Control UI is intended for local use only (see SECURITY.md); this advisory’s CVSS reflects a loopback-only/local-access deployment assumption.

Impact

An attacker with the ability to set assistant identity values (config or agent identity) could cause JavaScript execution for Control UI visitors, enabling token/session theft and privileged actions in the UI.

Fix

  • Removed inline script injection and serve bootstrap config from a JSON endpoint.
  • Added a restrictive Content Security Policy for the Control UI (script-src 'self', no inline scripts).

Fix Commit(s)

  • adc818db4a4b3b8d663e7674ef20436947514e1b
  • 3b4096e02e7e335f99f5986ec1bd566e90b14a7e

Release Process Note

This advisory pre-sets the patched version to the planned next release (2026.2.15). Once that version is published to npm, this advisory can be published without further edits.

Thanks @Adam55A-code for reporting.

References

@steipete steipete published to openclaw/openclaw Feb 18, 2026
Published to the GitHub Advisory Database Feb 18, 2026
Reviewed Feb 18, 2026
Published by the National Vulnerability Database Feb 20, 2026
Last updated Feb 20, 2026

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Local
Attack complexity
Low
Privileges required
High
User interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:L/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:N

EPSS score

Exploit Prediction Scoring System (EPSS)

This score estimates the probability of this vulnerability being exploited within the next 30 days. Data provided by FIRST.
(5th percentile)

Weaknesses

Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. Learn more on MITRE.

CVE ID

CVE-2026-27009

GHSA ID

GHSA-37gc-85xm-2ww6

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.