SiYuan Vulnerable to Arbitrary File Read via File Copy Functionality
Description
SiYuan is a personal knowledge management system. Versions prior to 3.5.4 contain a logic vulnerability in the /api/file/globalCopyFiles endpoint. The function allows authenticated users to copy files from any location on the server's filesystem into the application's workspace without proper path validation. The vulnerability exists in the api/file.go source code. The function globalCopyFiles accepts a list of source paths (srcs) from the JSON request body. While the code checks if the source file exists using filelock.IsExist(src), it fails to validate whether the source path resides within the authorized workspace directory. Version 3.5.4 patches the issue.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
github.com/siyuan-note/siyuan/kernelGo | < 0.0.0-20260118092521-f8f4b517077b | 0.0.0-20260118092521-f8f4b517077b |
Affected products
3- Range: dev2.0.17-2, v0.1.0, v0.1.1, …
- ghsa-coords2 versionspkg:golang/github.com/siyuan-note/siyuan/kernelpkg:rpm/opensuse/govulncheck-vulndb&distro=openSUSE%20Leap%2015.6
< 0.0.0-20260118092521-f8f4b517077b+ 1 more
- (no CPE)range: < 0.0.0-20260118092521-f8f4b517077b
- (no CPE)range: < 0.0.20260205T172317-150000.1.146.1
Patches
Vulnerability mechanics
References
6- github.com/advisories/GHSA-94c7-g2fj-7682ghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2026-23851ghsaADVISORY
- github.com/siyuan-note/siyuan/commit/b2274baba2e11c8cf8901b0c5c871e5b27f1f6ddghsax_refsource_MISCWEB
- github.com/siyuan-note/siyuan/commit/f8f4b517077b92c90c0d7b51ac11be1b34b273adghsax_refsource_MISCWEB
- github.com/siyuan-note/siyuan/issues/16860ghsax_refsource_MISCWEB
- github.com/siyuan-note/siyuan/security/advisories/GHSA-94c7-g2fj-7682ghsax_refsource_CONFIRMWEB
News mentions
0No linked articles in our index yet.