Overview
A second critical vulnerability in SiYuan — disclosed alongside CVE-2026-74799 — enables authenticated attackers to execute stored cross-site scripting (XSS) attacks that achieve full access to the SiYuan kernel API. CVE-2026-74800 carries a CVSS score of 9.0 and affects all SiYuan releases prior to v3.7.4.
The vulnerability stems from missing HTTP response headers when serving user-uploaded file assets, allowing malicious HTML files to execute as web pages within the SiYuan origin.
Vulnerability Details
SiYuan's asset serving endpoint does not include two critical security headers when delivering uploaded files:
Content-Disposition: attachment— which would force browsers to download files rather than render themX-Content-Type-Options: nosniff— which prevents browsers from MIME-sniffing a response away from the declared content type
Without these headers, an authenticated attacker can upload an HTML file disguised as a benign asset (e.g., an attachment or embedded resource). When the workspace owner subsequently opens or previews the asset URL, the browser renders the HTML file as a live web page within the SiYuan application origin.
Attack Chain
1. Attacker (authenticated) uploads malicious.html as an asset
2. Attacker shares a link or embeds the asset URL in a note
3. Workspace owner's browser renders malicious.html in SiYuan origin
4. XSS payload executes with same-origin access to SiYuan's kernel API
5. Attacker achieves full API access: read/write notes, export data, modify settings
Impact
Because SiYuan's kernel API is accessible via JavaScript within the application origin, a successful XSS payload can:
- Exfiltrate all notes and attachments in the workspace
- Modify or delete content across the knowledge base
- Extract stored credentials including auth codes and API keys
- Establish persistent access by modifying application settings or injecting code into templates
- Pivot to CVE-2026-74799 if the pprof endpoints are also exposed
The combination of CVE-2026-74800 (XSS entry point) and CVE-2026-74799 (credential extraction via pprof) creates a particularly dangerous attack chain for compromising SiYuan installations.
Technical Context
Modern browsers rely on Content-Type headers and opt-in security headers to determine how to handle served content. The absence of Content-Disposition: attachment means HTML files are rendered rather than downloaded. The absence of X-Content-Type-Options: nosniff means browsers may interpret ambiguously-typed responses as HTML based on content sniffing heuristics.
In SiYuan's case, uploaded assets are served from the same origin as the application itself, meaning any script executing within a rendered asset HTML file operates with full same-origin privileges — equivalent to JavaScript running within the main SiYuan application.
Fix
The vulnerability is patched in SiYuan v3.7.4, which adds the appropriate Content-Disposition and X-Content-Type-Options headers for all asset serving endpoints.
Remediation
- Update to SiYuan v3.7.4 or later immediately
- If updating is not immediately possible:
- Restrict who can upload assets to the SiYuan workspace
- Avoid opening or previewing asset files uploaded by untrusted parties
- Consider placing a reverse proxy in front of SiYuan that adds security headers globally
- Review uploaded assets for any suspicious HTML files
- Rotate authentication tokens as a precaution if workspace access was shared
Related Vulnerability
This CVE is closely related to CVE-2026-74799 (CVSS 9.3), which exposes unauthenticated pprof debug endpoints in the same SiYuan versions. Both vulnerabilities are fixed in v3.7.4. Organizations running SiYuan should treat these as a pair and apply the update without delay.