CVE-2026-66394

SiYuan before v3.7.3 Stored and Reflected XSS via SVG Sanitizer Bypass

Published Jul 27, 2026 CVSS 4.0 · 9.3 Critical EPSS < 1% KEV · Not listed
Description
SiYuan before v3.7.3 contains stored and reflected cross-site scripting vulnerabilities in SVG sanitization that allows authenticated attackers to execute scripts by bypassing the HTML parser-based cleaner. Attackers can hide script tags within desc, style, or noscript elements which the HTML parser treats as raw text but browsers interpret as executable SVG content when served as image/svg+xml, enabling script execution in the application origin.

Analysis

AI-generated

Technical impact

SiYuan before version 3.7.3 contains a stored and reflected cross‑site scripting (CWE‑79) flaw in its SVG handling routine. The sanitizer that normally removes potentially dangerous markup fails to strip script tags placed inside desc, style, or noscript elements of an SVG. When these SVG files are served with the MIME type image/svg+xml, browsers treat the hidden script content as executable SVG elements, allowing an attacker to run arbitrary JavaScript within the context of the application origin. An attacker who can authenticate to the system can embed such an SVG in a note or upload it, and any authenticated viewer of that note will execute the injected script. This yields full abuse of the victim’s browser, enabling credential theft, session hijacking, or defacement.

Affected Systems

The vulnerability affects the SiYuan note‑taking application, released by vendor siyuan-note. All releases prior to version 3.7.3 are vulnerable. Versions 3.7.3 and later contain the corrected SVG sanitizer and are not affected. No other versions are listed as affected.

Risk and Exploitability

With a CVSS score of 9.3 the risk is considered Critical. The EPSS score is < 1%, indicating a very low probability of exploitation, and the vulnerability is not listed in CISA’s KEV catalog, suggesting no known exploits yet. The likely attack vector requires an authenticated user to upload or embed a malicious SVG file, benefiting from the application’s trust in authenticated content. Once uploaded, any other authenticated user who views the note triggers script execution. Therefore, the exploit is realistic in environments where users can share notes or where administrators use the application to host information freely.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade SiYuan to the latest version (v3.7.3 or later) to receive the updated SVG sanitizer.
  • If an upgrade is not immediately possible, block or delete all SVG files that contain <script>, <desc>, <style>, or <noscript> elements, or configure the application to strip these tags on upload.
  • As a containment measure, search the database for SVG content and remove or replace embedded scripts before restoring or sharing the notes.
  • Configure the web server or application to serve SVGs with strict Content Security Policy headers that disallow inline scripts and to enforce the correct MIME type.

Generated by OpenCVE AI on August 4, 2026 at 13:56 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
First Time appeared B3log
B3log siyuan
CPEs cpe:2.3:a:b3log:siyuan:*:*:*:*:*:*:*:*
Vendors & Products B3log
B3log siyuan
Type Values Removed Values Added
First Time appeared Siyuan
Siyuan siyuan
Vendors & Products Siyuan
Siyuan siyuan
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description SiYuan before v3.7.3 contains stored and reflected cross-site scripting vulnerabilities in SVG sanitization that allows authenticated attackers to execute scripts by bypassing the HTML parser-based cleaner. Attackers can hide script tags within desc, style, or noscript elements which the HTML parser treats as raw text but browsers interpret as executable SVG content when served as image/svg+xml, enabling script execution in the application origin.
Title SiYuan before v3.7.3 Stored and Reflected XSS via SVG Sanitizer Bypass
Weaknesses CWE-79
References
Metrics cvssV3_1

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

cvssV4_0

{'score': 9.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N'}

Weaknesses
  • CWE-79

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

Sources

Status
PUBLISHED
Assigner
VulnCheck
Published
Updated
Oct 8, 2026, 3:24 PM
Reserved
Jul 26, 2026, 12:22 PM
Status
Deferred
Published
Jul 27, 2026, 4:18 PM
Modified
Oct 24, 2026, 1:10 PM