Executive brief
SiYuan is a personal knowledge management system used for organizing notes and data. A security flaw allows a malicious website to take full control of a user's computer if they visit the site while the SiYuan desktop application is running. This could result in the theft of all personal notes, exposure of sensitive configuration data, or the installation of malware on the user's operating system.
Technical details
SiYuan (prior to v3.6.2) implements a permissive Cross-Origin Resource Sharing (CORS) policy in 'kernel/server/serve.go' that sets 'Access-Control-Allow-Origin: *' and 'Access-Control-Allow-Private-Network: true'. This configuration allows external websites to bypass Chrome's Private Network Access protections and make authenticated requests to the local SiYuan API (typically on port 6806) using the user's session cookies. An attacker can use the '/api/snippet/setSnippet' endpoint to inject malicious JavaScript. Because SiYuan is built on Electron with Node.js integration enabled, this injected code executes with full operating system privileges the next time the UI is loaded. The vulnerability also allows for immediate data exfiltration of notes and API tokens.
Affected products
- siyuan-note SiYuan < 3.6.2
Timeline
- 2026-03-18: other: Issue reported to vendor
- 2026-03-28: advisory: GitHub Security Advisory published
- 2026-03-31: patched: Version 3.6.2 released
- 2026-03-31: disclosed: CVE-2026-34449 published