Skip to main content

Siyuan CVE-2026-40922

MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-04-16 GitHub_M
5.3
CVSS 4.0 · GitHub Advisory
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Attacker compromises bazaar package
  2. Delivery
    Injects iframe srcdoc with embedded script
  3. Exploit
    Uploads malicious README to package
  4. Install
    User views package in marketplace
  5. C2
    Lute sanitizer fails to block iframe
  6. Execute
    srcdoc payload executes in Electron context
  7. Impact
    Arbitrary code execution with full app privileges

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires: (1) SiYuan versions 3.6.1-3.6.3 running on the user's machine, (2) the bazaar marketplace feature enabled (default in standard installations), (3) the user actively browsing or viewing a malicious bazaar package in the marketplace UI, and (4) the attacker having the ability to publish or modify a bazaar package (either via compromised repository credentials or by creating a new malicious package repository linked to the bazaar). Users with the marketplace feature disabled or who do not browse bazaar packages are not at risk. The vulnerability does not require user interaction beyond viewing the package (no clicking, hovering, or accepting prompts), and exploitation is not restricted to specific SiYuan deployment modes (desktop, portable, or containerized installations are all vulnerable if marketplace is enabled).

Impact

CVSS 5.3 (PR:L/UI:N) indicates low to moderate severity, but the vulnerability carries significantly higher real-world risk. Authentication (PR:L) is required - an attacker must first become a bazaar package author or compromise an existing author's repository - this raises the barrier substantially above random remote exploitation. However, once a malicious package is published, it executes with full application privileges in Electron (arbitrary code execution in client context), not merely data exfiltration. The CVSS vector shows limited scope (S:X not specified as S:C), which may understate impact; a confirmed RCE tag and references to arbitrary code execution suggest the actual impact is higher. UI:N (no user interaction beyond viewing the marketplace) is correct: users need only browse the SiYuan marketplace to trigger execution, a normal workflow. Exploitation requires a non-default configuration (bazaar marketplace enabled and accessible), but this is the intended use case for many users. The incomplete prior fix (CVE-2026-33066) and rapid patch deployment (v3.6.4) suggest the vendor recognizes higher-than-CVSS risk. Real-world priority: HIGH for users who actively use the bazaar marketplace; LOW for isolated or air-gapped deployments. No KEV listing or public POC identified, suggesting targeted rather than mass-exploitation risk.

Exploit ScenarioDerived

An attacker creates or compromises a bazaar package repository and uploads a modified README.md containing an iframe with embedded JavaScript in a srcdoc attribute. When a SiYuan user browses the marketplace and views the package details, the README renders in the marketplace UI. The unsanitized iframe executes, and the embedded script runs with full Electron privileges, allowing the attacker to exfiltrate credentials from the user's vault, modify documents, or install persistence mechanisms.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Apr 17, 2026

SiYuan 3.6.1 through 3.6.3 allows arbitrary code execution when users view malicious bazaar packages in the marketplace UI. The vulnerability stems from an incomplete XSS fix (for CVE-2026-33066) that enabled an HTML sanitizer but failed to block iframe tags with srcdoc attributes containing embedded scripts. A malicious package author can inject JavaScript that executes in the Electron process with full application privileges, compromising the user's machine. The issue is confirmed fixed in version 3.6.4 and no public exploitation has been reported at time of analysis.

RemediationAI

Upgrade immediately to SiYuan version 3.6.4 or later, which includes the corrected HTML sanitizer that now blocks iframe tags or properly sanitizes srcdoc attributes. Users unable to upgrade immediately should disable the bazaar marketplace feature if non-essential: within SiYuan settings, navigate to 'Bazaar' and disable marketplace access until an upgrade is available. Alternatively, restrict network access to the bazaar repository domain (api.github.com, etc.) at the firewall level to prevent marketplace package retrieval, though this blocks all bazaar functionality including community plugins and themes. The vendor's GitHub security advisory (https://github.com/siyuan-note/siyuan/security/advisories/GHSA-8q5w-mmxf-48jg) provides confirmation and deployment guidance.

Affected Packages

go github.com/siyuan-note/siyuan/kernel fix: 0.0.0-20260414013942-62eed37a3263

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in go

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

SiYuan uses the Lute HTML sanitizer to prevent XSS in bazaar README rendering. Lute implements a URL-prefix blocklist mechanism intended to filter dangerous URLs (e.g., javascript:, data:), but this approach assumes all dangerous content flows through URL attributes. The srcdoc attribute of iframe elements is different: it directly embeds raw HTML content rather than a URL reference, bypassing the URL-prefix filter entirely. An attacker can craft an iframe with a srcdoc attribute containing inline JavaScript (e.g., <iframe srcdoc='<script>alert(1)</script>'>) that executes when the iframe is rendered. Because SiYuan's marketplace UI renders README files in an Electron webview with full application privileges rather than in an isolated context, the injected script gains unrestricted access to Node.js APIs, file system, and process management. The root cause is CWE-79 (Improper Neutralization of Input During Web Page Generation), compounded by insufficient allowlist enforcement on HTML tags and attributes.

Know when Siyuan gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

GitHub Advisory PRIMARY 5.3 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
SUSE MEDIUM

Primary rating from GitHub Advisory.

CVSS VectorGitHub Advisory

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
Low
Subsequent system: Integrity
Low
Subsequent system: Availability
None

Lifecycle Timeline

2
CVSS changed
Apr 17, 2026 - 01:22 NVD
5.3 (MEDIUM)
CVE Published
Apr 16, 2026 - 23:14 nvd
MEDIUM 5.3

DescriptionGitHub Advisory

SiYuan is an open-source personal knowledge management system. In versions 3.6.1 through 3.6.3, a prior fix for XSS in bazaar README rendering (incomplete fix for CVE-2026-33066) enabled the Lute HTML sanitizer, but the sanitizer does not block iframe tags, and its URL-prefix blocklist does not effectively filter srcdoc attributes which contain raw HTML rather than URLs. A malicious bazaar package author can include an iframe with a srcdoc attribute containing embedded scripts in their README. When other users view the package in SiYuan's marketplace UI, the payload executes in the Electron context with full application privileges, enabling arbitrary code execution on the user's machine. This issue has been fixed in version 3.6.4.

Threat Intelligence Overview

EPSS Score
0.1%
Top 80% exploitable
Social Media
1
Sightings
Data Quality
4 sources
Confidence: Medium
NVD CVE.org EPSS Vulnrichment Vendor CIRCL GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

Affected Products (CPE)GitHub Advisory

cpe:2.3:a:siyuan-note:siyuan:*:*:*:*:*:*:*:*

More in Siyuan

View all
CVE-2026-69083 CRITICAL POC
9.9 Aug 03

SQL injection in SiYuan's fullTextSearchAssetContent endpoint lets unauthenticated attackers and holders of publish Role

CVE-2026-54067 CRITICAL POC
9.9 Jun 24

Stored cross-site scripting in SiYuan personal knowledge management before 3.7.0 lets an attacker with write access to a

CVE-2026-69084 CRITICAL POC
9.9 Aug 03

SQL injection in SiYuan personal knowledge management (versions <= v3.7.2) lets attackers pass arbitrary SQL statements

CVE-2026-54158 CRITICAL POC
9.9 Jun 24

Stored cross-site scripting in SiYuan's attribute-view (database) cell renderer, affecting all versions prior to 3.7.0,

CVE-2026-69085 CRITICAL POC
9.9 Aug 03

SQL injection in SiYuan personal knowledge-management software (all versions before v3.7.3) lets attackers inject arbitr

CVE-2024-53507 CRITICAL POC
9.8 Nov 29

A SQL injection vulnerability was discovered in Siyuan 3.1.11 in /getHistoryItems. Rated critical severity (CVSS 9.8), t

CVE-2024-53506 CRITICAL POC
9.8 Nov 29

A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the ids array parameter in /batchGetBlockAttrs. R

CVE-2024-53505 CRITICAL POC
9.8 Nov 29

A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the id parameter at /getAssetContent. Rated criti

CVE-2024-53504 CRITICAL POC
9.8 Nov 29

A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the notebook parameter in /searchHistory. Rated c

CVE-2026-23852 CRITICAL POC
9.6 Jan 19

SiYuan personal knowledge management system prior to 3.5.4 has a stored XSS vulnerability (CVSS 9.6) that allows code ex

CVE-2026-56397 CRITICAL POC
9.4 Jun 21

Remote code execution in SiYuan note-taking application (before v3.6.1) allows any malicious Bazaar marketplace package

CVE-2026-54069 CRITICAL POC
9.2 Jun 24

Origin-validation bypass in SiYuan Note (open-source personal knowledge management) before 3.7.0 lets any installed Chro

Vendor StatusVendor

SUSE

Severity: Moderate
Product Status
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP applications 16.1 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP5 Affected
SUSE Linux Enterprise Module for Package Hub 15 SP6 Affected
openSUSE Leap 15.5 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy