CVE-2026-25539 SiYuan has Arbitrary File Write via /api/file/copyFile leading to RCE

Critical 9.1 Published Updated

Authenticated attackers can write files to arbitrary locations via the copyFile API, enabling remote code execution by modifying system files.

Exploited in the wild
Not known
Login needed
An administrator
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2026-25539?

CVE-2026-25539 is a critical path traversal vulnerability in B3log Siyuan, published on 4 Feb 2026. An attacker needs administrator access to exploit it, with no action from the victim.

Official description

SiYuan is a personal knowledge management system. Prior to version 3.5.5, the /api/file/copyFile endpoint does not validate the dest parameter, allowing authenticated users to write files to arbitrary locations on the filesystem. This can lead to Remote Code Execution (RCE) by writing to sensitive locations such as cron jobs, SSH authorized_keys, or shell configuration files. This issue has been patched in version 3.5.5.

Weakness: CWE-22

Which versions are affected by CVE-2026-25539?

3 open source packages ship an affected version, including github.com/siyuan-note/siyuan/kernel. It affects 1 product.

PackageAffectedFixed in
github.com/siyuan-note/siyuan/kernel GoAll versionsNone
github.com/siyuan-note/siyuan/kernel GoAll versions to 0.0.0-20260126094835-d5d10dd41b0cNone
github.com/siyuan-note/siyuan/kernel GoAll versions to 0.0.0-20260126094835-d5d10dd41b0cNone

Products include B3log Siyuan.

How do I fix CVE-2026-25539?

No fix has been published for CVE-2026-25539 yet. Limit exposure of the affected software until one is available.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2026-25539 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-25539 exists.

All B3log Siyuan vulnerabilities

Sources

Also known as GHSA-c4jr-5q7w-f6r9, GO-2026-4387.

Is CVE-2026-25539 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free