Junglewise Threat Intelligence

CVE-2026-54067: SiYuan stored XSS to RCE via CSS snippet breakout

CVE-2026-54067 · Severity: critical · CVSS 9.9 · Published 2026-06-24

Technologies: SiYuan Note SiYuan, SiYuan, github.com/siyuan-note/siyuan/kernel (Go). Vendors: SiYuan Note, SiYuan, Go.

Executive brief

SiYuan, a personal knowledge management system, is vulnerable to a security flaw where malicious code can be hidden within custom CSS snippets. If an attacker gains write access to a synced workspace, they can inject code that automatically executes on all devices connected to that workspace. On desktop versions, this allows the attacker to take full control of the host computer, potentially leading to data theft or complete system compromise.

Technical details

A stored XSS vulnerability exists in SiYuan's `renderSnippet()` function due to improper interpolation of CSS snippets using `insertAdjacentHTML`. An attacker can bypass the `<style>` tag context by including a `</style>` closing tag followed by a malicious HTML payload (e.g., an `<img>` tag with an `onerror` handler). In Electron-based desktop builds, the renderer runs with `nodeIntegration: true`, allowing the injected JavaScript to access Node.js APIs like `child_process` to achieve host Remote Code Execution (RCE). The vulnerability is particularly impactful because snippets are synchronized across workspaces, meaning a single malicious entry can propagate to and execute on all synced peer devices. A patch is available in version 0.0.0-20260628153353-2d5d72223df4.

Affected products

  • siyuan-note SiYuan < 0.0.0-20260628153353-2d5d72223df4

Timeline

  • 2026-04-21: other: Vulnerable version v3.6.5 identified
  • 2026-06-24: advisory: NVD publication date
  • 2026-07-10: patched: GitHub Advisory published and patched version confirmed

References

Related threats