Description
LightRAG provides simple and fast retrieval-augmented generation. Prior to 1.5.5, lightrag_webui/src/components/retrieval/ChatMessage.tsx renders answer and thinking content with react-markdown, rehypeRaw, and skipHtml=false without an HTML sanitizer. An attacker who can add a document can store raw HTML that is returned through the query path and rendered as active content by MessageMarkdown. A user who later retrieves the content can execute attacker-controlled JavaScript through elements such as an iframe srcdoc; the additional Mermaid securityLevel: loose rendering path also injects generated SVG through innerHTML. The script runs in the LightRAG WebUI origin and can read the API token in localStorage and perform API actions as the victim. This issue is fixed in version 1.5.5.
Published: 2026-09-22
Score: 6.1 Medium
EPSS: n/a
KEV: No
Impact: Stored Cross‑Site Scripting (XSS) with access to API token
Action: Immediate Patch
AI Analysis

Impact

A stored XSS flaw exists in the LightRAG WebUI chat responder, allowing an attacker to inject arbitrary HTML or JavaScript into retrieved answers. The injected script is executed in the victim’s browser context, permitting an attacker to read the API token stored in localStorage and perform authenticated API requests as the user. The weakness stems from rendering user‑supplied content with react-markdown and rehypeRaw without an HTML sanitizer.

Affected Systems

LightRAG versions prior to 1.5.5 are affected. The vulnerability is present in the component that renders chat messages and thinking content and is not mitigated in any earlier releases of the product.

Risk and Exploitability

The CVSS score of 6.1 indicates a medium severity. An attacker with the ability to add a document can persist malicious content, and any user retrieving that content will be impacted. The EPSS score is not available, and the vulnerability is not listed in CISA’s KEV catalog, suggesting that large‑scale exploitation is not currently documented. Nevertheless, the attack requires only the insertion of a document, a permission that many users may possess, and does not demand advanced access or code execution on the server side.

Generated by OpenCVE AI on September 22, 2026 at 17:36 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade LightRAG to version 1.5.5 or later, which removes the vulnerable rendering path and adds input sanitization.
  • Ensure that only trusted and validated documents are ingested; implement a review workflow or content filtering before indexing.
  • If an upgrade is infeasible, delete or disable the affected message rendering component, or apply client‑side sanitization to all rendered HTML to block script execution.

Generated by OpenCVE AI on September 22, 2026 at 17:36 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 22 Sep 2026 17:45:00 +0000

Type Values Removed Values Added
First Time appeared Hkuds
Hkuds lightrag
Vendors & Products Hkuds
Hkuds lightrag

Tue, 22 Sep 2026 16:30:00 +0000

Type Values Removed Values Added
Description LightRAG provides simple and fast retrieval-augmented generation. Prior to 1.5.5, lightrag_webui/src/components/retrieval/ChatMessage.tsx renders answer and thinking content with react-markdown, rehypeRaw, and skipHtml=false without an HTML sanitizer. An attacker who can add a document can store raw HTML that is returned through the query path and rendered as active content by MessageMarkdown. A user who later retrieves the content can execute attacker-controlled JavaScript through elements such as an iframe srcdoc; the additional Mermaid securityLevel: loose rendering path also injects generated SVG through innerHTML. The script runs in the LightRAG WebUI origin and can read the API token in localStorage and perform API actions as the victim. This issue is fixed in version 1.5.5.
Title LightRAG: Stored Cross-Site Scripting (XSS) in the LightRAG WebUI chat/answer renderer via ingested content
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 6.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-09-22T16:21:43.846Z

Reserved: 2026-09-04T19:34:03.099Z

Link: CVE-2026-86062

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Deferred

Published: 2026-09-22T17:17:27.863

Modified: 2026-09-22T17:17:28.010

Link: CVE-2026-86062

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-09-22T17:30:18Z

Weaknesses
  • CWE-79

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