Summary
CVE-2026-66012 is a critical missing authorization vulnerability (CWE-862) in SiYuan, an open-source self-hosted personal knowledge management system, affecting all versions prior to v3.7.2. The POST /mcp kernel endpoint lacks the required CheckAdminRole and CheckReadonly middleware guards, exposing 31 Model Context Protocol (MCP) tools — including full workspace file operations — to unauthenticated remote attackers when the Publish server is running in anonymous mode. The vulnerability carries a CVSS v4.0 and CVSS v3.1 base score of 10.0 (Critical).
Technical details
- Root cause: The
POST /mcproute is protected only by the generalmodel.CheckAuthcheck; it is missing bothCheckAdminRoleandCheckReadonlymiddleware gates. The MCP tool dispatcher also ignores caller role restrictions, and the file tool permits workspace-wide read/write/delete operations to non-administrator principals. - Trigger conditions: The Publish server must be enabled in anonymous mode (
Conf.Publish.Enable=trueandConf.Publish.Auth.Enable=false). In this configuration, the Publish reverse proxy automatically attaches an anonymousRoleReaderJWT to proxied requests, granting unauthenticated network access to the/mcpendpoint. - Attack vector: A remote, unauthenticated attacker sends a crafted
POST /mcprequest through the Publish server to invoke any of the 31 exposed MCP tools, including the file tool with list, read, write, delete, rename, and copy actions across the entire workspace. - Impact:
- Credential theft: Reading
conf/conf.jsonexposesaccessAuthCode,api.token, andcookieKeyin plaintext. - Arbitrary file write: An attacker can write, rename, copy, or delete any file within the workspace directory.
- Remote code execution: Planting a malicious plugin in
data/plugins/causes it to execute withnodeIntegration:trueand nocontextIsolationon the next desktop client launch, resulting in full OS-level code execution and administrator takeover. - Data destruction: Arbitrary file deletion across the workspace.
- Credential theft: Reading
Affected software
- SiYuan all versions from initial release through v3.7.1 (inclusive)
- Fixed in v3.7.2
Severity
- CVSS v4.0: 10.0 (Critical) —
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H - CVSS v3.1: 10.0 (Critical) —
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
Mitigation and recommended actions
- Immediate — upgrade: Update SiYuan to v3.7.2 or later, which introduces proper
CheckAdminRoleandCheckReadonlyenforcement on the/mcpendpoint. - If immediate patching is not possible — disable anonymous Publish mode: Set
Conf.Publish.Auth.Enable=trueto require authentication on the Publish server, or disable the Publish server entirely (Conf.Publish.Enable=false). Either configuration removes the unauthenticated path to the/mcpendpoint. - Network mitigation: Restrict external access to SiYuan’s kernel and Publish server ports (default 6806/6808) at the network perimeter until patching is complete.
IONIX Status
The IONIX research team is tracking ongoing exploitation attempts and recommends immediate patching. Potentially affected assets are outlined in this post.

