SiYuan
CVE-2026-40318
HIGH
Severity by source
AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:L/A:H
Network endpoint reachable with low-privilege publish/reader access (PR:L); a flaw in the av component deletes files owned by the whole app (S:C); deletion harms integrity partially (I:L) and availability heavily (A:H), no confidentiality impact.
Primary rating from GitHub Advisory.
CVSS VectorGitHub Advisory
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:L/A:H
Lifecycle Timeline
4DescriptionGitHub Advisory
SiYuan is an open-source personal knowledge management system. In versions 3.6.3 and prior, the /api/av/removeUnusedAttributeView endpoint constructs a filesystem path using the user-controlled id parameter without validation or path boundary enforcement. An attacker can inject path traversal sequences such as ../ into the id value to escape the intended directory and delete arbitrary .json files on the server, including global configuration files and workspace metadata. This issue has been fixed in version 3.6.4.
AnalysisAI
Arbitrary server-side file deletion in SiYuan (b3log/SiYuan) versions 3.6.3 and prior lets a low-privileged actor with access to the /api/av/removeUnusedAttributeView endpoint - such as a Reader-role or publish context - supply an id parameter containing ../ sequences to escape the storage/av directory and delete any .json file on the server, including conf/conf.json and workspace metadata. The GitHub Security Advisory (GHSA-vw86-c94w-v3x4) includes step-by-step reproduction, so publicly available exploit code exists, but there is no public exploit identified as weaponized and SSVC exploitation status is 'none'; EPSS is low at 0.06%. Fixed in version 3.6.4.
Technical ContextAI
SiYuan is an open-source, self-hosted personal knowledge management system written in Go (kernel package github.com/siyuan-note/siyuan/kernel). The flaw is a classic path-traversal root cause: the handler builds a filesystem path with filepath.Join(util.DataDir, "storage", "av", id+".json") using the untrusted id directly, with no normalization, format validation, or boundary check that the resolved path stays under storage/av. filepath.Join collapses ../ segments, so an id like ../../../conf/conf resolves to conf/conf.json outside the intended directory. NVD classes this as CWE-24 (Path Traversal '../filedir'), while the vendor advisory cites the parent class CWE-22 (Improper Limitation of a Pathname to a Restricted Directory); both describe the same directory-escape defect. The affected package is cpe:2.3:a:b3log:siyuan.
RemediationAI
Vendor-released patch: upgrade to SiYuan 3.6.4, which adds input validation and directory-boundary enforcement (per the advisory, allowing only valid Attribute View IDs, rejecting traversal sequences, and checking the resolved path stays under storage/av); see https://github.com/siyuan-note/siyuan/releases/tag/v3.6.4 and https://github.com/siyuan-note/siyuan/security/advisories/GHSA-vw86-c94w-v3x4. If you cannot upgrade immediately, the most effective compensating control is to disable or firewall the publish/reader service so the /api/av/removeUnusedAttributeView endpoint is unreachable by untrusted users - trade-off: this removes public read/publish functionality. Where publish must remain on, restrict access to the endpoint at a reverse proxy (block or authenticate requests to /api/av/removeUnusedAttributeView) and place the instance behind a VPN or IP allowlist; trade-off is added access friction. Ensure regular backups of the workspace data and conf directories so a successful deletion of conf/conf.json or workspace metadata can be recovered without full re-setup.
A SQL injection vulnerability was discovered in Siyuan 3.1.11 in /getHistoryItems. Rated critical severity (CVSS 9.8), t
A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the ids array parameter in /batchGetBlockAttrs. R
A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the id parameter at /getAssetContent. Rated criti
A SQL injection vulnerability has been identified in Siyuan 3.1.11 via the notebook parameter in /searchHistory. Rated c
SiYuan personal knowledge management system prior to 3.5.4 has a stored XSS vulnerability (CVSS 9.6) that allows code ex
Origin-validation bypass in SiYuan Note (open-source personal knowledge management) before 3.7.0 lets any installed Chro
Reflected XSS in SiYuan knowledge management before 3.5.9.
SiYuan knowledge management system prior to 3.5.5 has a path traversal in /api/file/copyFile allowing arbitrary file ope
SiYuan version 3.0.3 allows executing arbitrary commands on the server. Rated critical severity (CVSS 9.0), this vulnera
SQL injection in SiYuan prior to version 3.6.0 allows any authenticated user, including those with read-only access, to
Cross-site scripting (XSS) in SiYuan personal knowledge management system versions 3.6.0-3.6.1 allows remote attackers t
Arbitrary file disclosure in SiYuan personal knowledge management system before 3.7.0 lets an unauthenticated remote att
Same weakness CWE-24 – Path Traversal: '../filedir'
View allSame technique Path Traversal
View allVendor StatusVendor
SUSE
Severity: Important| 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 |
| openSUSE Leap 15.6 | Affected |
Share
External POC / Exploit Code
Leaving vuln.today
GHSA-vw86-c94w-v3x4