highCVSS 8.7Vulnerability

CVE-2026-87995

## Summary Any authenticated user with access to a shared terminal server could get script of their choosing to run in the Open WebUI origin itself. The in-app port preview rendered the content of a previewed port in an iframe whose sandbox always granted `allow-same-origin` alongside `allow-scripts`, and that content is served from a path on the application's own origin, so the sandbox provided no isolation at all. Script served on a previewed port could read the victim's session token and take over the account. ## Preconditions - At least one terminal server configured by an admin (`TERMINAL_SERVER_CONNECTIONS`, empty by default) and reachable by both the attacker and the victim. Deployments with no terminal server configured are not affected. - The attacker needs a normal authenticated account with access to that terminal connection, no admin rights, plus the ability to start a process listening on a port there. - Personal terminals a user configures for themselves are not affected. Those carry an external URL, so the previewed document is cross-origin and the sandbox held. - The victim has to open the port list and click the attacker's port. - `TERMINAL_PROXY_HEADERS` unset and no `CONTENT_SECURITY_POLICY` set, which are the defaults. An operator who had already set a restrictive Content-Security-Policy through either was not exposed, since those headers apply to the proxied response. - The `iframeSandboxAllowSameOrigin` user setting is off by default, but the affected branch ignored it entirely. ## Impact The previewed page runs in the application origin, so it can reach the parent window, read the session token out of `localStorage` and exfiltrate it, which is full account takeover of the victim. If the victim is an admin, or any user holding `workspace.functions`, that takeover extends to server-side code execution through Functions. Serving the page costs the attacker nothing beyond the terminal access they already hold, so the only real barrier is getting

Properties

severity
high
summary
Open WebUI: Same-origin XSS to account takeover via terminal port-preview iframe hardcoding allow-same-origin
epss_score
0.00222
cvss_score
8.7
ghsa_published
2026-09-10T15:10:20Z
source_url
https://github.com/advisories/GHSA-jmc6-2wr8-h3wj
ghsa_updated
2026-09-10T15:10:20Z
ghsa_id
GHSA-jmc6-2wr8-h3wj
cve_id
CVE-2026-87995
cvss_vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N
is_ghsa_only
false
epss_percentile
0.12719

Related Entities (6)

ENRICHED_BY (1)

[Source]FIRST EPSS

VULNERABLE_TO (1)

[Software]pip/open-webui

AFFECTS (1)

[Software]pip/open-webui

HAS_WEAKNESS (2)

[Weakness]Improper Restriction of Rendered UI Layers or Frames
[Weakness]Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

REPORTED_BY (1)

[Source]GitHub Advisory Database

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-87995 (CVSS 8.7) — Ninja Signal Threat Intelligence | Ninja Signal