CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-72799

CVE-2026-72799: Missing Authorization in SiYuan Filetree Path-Resolution API

Alon Barad
Alon Barad
Software Engineer

Sep 5, 2026·7 min read·19 visits

Executive Summary (TL;DR)

Unauthenticated remote attackers can query specific path-resolution APIs in SiYuan to discover the structures, names, and IDs of private, hidden, or password-protected documents when deployed in public publish mode.

SiYuan before v3.7.4 fails to enforce publish-access filters on five filetree path-resolution endpoints, allowing unauthenticated attackers to reconstruct private directory layouts and map document structures.

Vulnerability Overview

SiYuan is a local-first personal knowledge management system developed in Go and TypeScript. It supports a publish mode, allowing users to share specific notebooks and documents with the public or with authenticated readers. To protect sensitive information, users can restrict pages by setting their status to hidden, password-protected, or fully disabled for publication.

The core file-management backend, implemented as a Go service running on the Gin HTTP framework, is responsible for processing document hierarchies and serving filetrees. When publish mode is enabled without password authentication, the application exposes API endpoints intended to assist the frontend in resolving filetree paths. These endpoints resolve internal document identifiers (IDs) into human-readable hierarchical paths and vice versa.

In versions prior to v3.7.4, the application fails to validate whether the requested resources are authorized for the calling context. Because of this omission, any unauthenticated network actor can query these endpoints directly. The lack of authorization checks exposes metadata representing the entire structure of the personal knowledge base, including documents explicitly marked as private.

Root Cause Analysis

The root cause of CVE-2026-72799 lies in a missing authorization check within the handlers defined in kernel/api/filetree.go. When an API request is received, the handler processes the incoming payload and queries the database or memory-mapped index (BlockTree) without verifying the client's current authorization level against the target resource's publication properties. The application assumes that any client allowed to access the basic read-only context is also allowed to resolve paths for all existing IDs.

Specifically, the affected endpoints include /api/filetree/getFullHPathByID, /api/filetree/getHPathByID, /api/filetree/getPathByID, /api/filetree/getIDsByHPath, and /api/filetree/getHPathByPath. These endpoints perform direct lookups in the internal SQLite database or the structured Go models. These lookups are performed without filtering results based on whether the containing notebook or the individual document is flagged as hidden, password-protected, or forbidden from being published.

This behavior allows unauthorized users to perform targeted queries. An attacker with access to a single valid ID or human-readable path can traverse the entire parent and child relationships of that node. Because document IDs are generated using predictable timestamp patterns, attackers can brute-force the ID space or sequentially resolve metadata to extract the exact logical structure of folders and files.

Code-Level Analysis and Patch Verification

To resolve the vulnerability, the developers introduced strict role context and publish-access validation checks inside the kernel/api/filetree.go handler methods. The fix utilizes the model.IsReadOnlyRoleContext(c) helper function to detect whether the current HTTP request originates from an unauthenticated or read-only reader session. If a read-only context is active, the application fetches the active publication configuration using model.GetPublishAccess() and enforces permissions.

// Code snippet showing the added validation in getHPathByID
if model.IsReadOnlyRoleContext(c) {
	publishAccess := model.GetPublishAccess()
	if !model.CheckBlockIdMetadataAccessableByPublishAccess(c, publishAccess, id) {
		ret.Code = -1
		ret.Msg = model.ErrTreeNotFound.Error()
		return
	}
}

The check calls CheckBlockIdMetadataAccessableByPublishAccess, which maps to the underlying database and checks if the path or box ID is marked as disabled or password-protected. If the validation fails, the API responds with a generic error message indicating that the tree or block was not found, preventing metadata leakage.

// The array filter implementation introduced to protect bulk path resolutions
func filterFileTreePathsByPublishMetadataAccess(c *gin.Context, paths []string) (ret []string) {
	if !model.IsReadOnlyRoleContext(c) {
		return paths
	}
	ids := make([]string, 0, len(paths))
	for _, p := range paths {
		ids = append(ids, util.GetTreeID(p))
	}
	blockTrees := treenode.GetBlockTrees(ids)
	publishAccess := model.GetPublishAccess()
	ret = make([]string, 0, len(paths))
	for i, p := range paths {
		if model.CheckBlockTreeMetadataAccessableByPublishAccess(c, publishAccess, blockTrees[ids[i]]) {
			ret = append(ret, p)
		}
	}
	return
}

This filter resolves the IDs from each path, loads the cached BlockTree records, and evaluates access permissions on each item individually. For documents that are password-protected, the verification routine CheckBlockTreeMetadataAccessableByPublishAccess ensures that the client possesses the correct authorization cookie value via CheckPublishAuthCookie before returning the metadata.

Exploitation Methodology

Exploitation of CVE-2026-72799 is straightforward and requires no active user interaction or elevated privileges. An attacker only needs network-level access to the target SiYuan instance when it is configured in publish mode with public access allowed. By sending a crafted HTTP POST request containing a known or predicted document ID, the attacker can verify the existence and retrieve the hierarchical path of the document.

The attack begins with reconnaissance to find exposed SiYuan instances. Once identified, the attacker targets the /api/filetree/getFullHPathByID endpoint with structural or guessable document IDs, which are typically formatted with a prefix based on the creation timestamp. If the server is vulnerable, it responds with the full structural path containing sensitive directory names and private file titles.

To discover all files within a private directory, the attacker can leverage the /api/filetree/getIDsByHPath endpoint. By specifying a known or leaked path prefix, the API returns a complete array of document IDs under that directory. The attacker can then programmatically iterate through these retrieved IDs to reconstruct the entire document hierarchy of the host system.

Security Impact Assessment

The vulnerability carries a CVSS v4.0 base score of 6.9 and a CVSS v3.1 base score of 5.8, reflecting its impact on confidentiality. Although the vulnerability does not allow direct remote code execution or modification of data, the leakage of document metadata represents a significant privacy and security risk. This is particularly critical because personal knowledge bases often contain sensitive personal, corporate, or financial details.

An attacker exploiting this flaw can map the entire logical layout of private notebooks, revealing restricted project directories, client lists, internal system designs, or credential archives. Knowledge of document titles and their paths can also expose security-sensitive terms that are meant to be kept hidden, such as directories labeled with internal server names, proprietary codebases, or key management folders.

Furthermore, this metadata leakage undermines the efficacy of document password protections. While an attacker cannot directly read the raw markdown contents of a password-protected document through these endpoints, learning the precise document titles and directory locations provides valuable targets for secondary attacks. These secondary attacks include credential stuffing or spear-phishing campaigns tailored to the revealed hierarchy.

Remediation and Defense

The most effective remediation is upgrading all SiYuan instances to version v3.7.4 or higher, which properly implements server-side authorization validations on all filetree APIs. If upgrading is not immediately feasible, administrators must implement network-level or application-level mitigations to prevent unauthorized access.

Administrators should configure the application to enable publish authentication by setting Publish.Auth.Enable to true. This action enforces password verification before allowing any access to the endpoints. Additionally, implementing a reverse proxy such as Nginx or Caddy is highly recommended to block external access to the /api/filetree/* endpoints from untrusted networks.

> [!NOTE] > Restricting API access via a reverse proxy may impact some frontend editing and navigation functionalities for legitimate remote users, but it serves as an effective temporary mitigation until the software can be patched.

To detect exploitation attempts, security operations teams should analyze reverse proxy or web server access logs. They should search for sequential POST requests to /api/filetree/getFullHPathByID or similar endpoints originating from unexpected IP addresses, which typically indicate automated mapping and enumeration scripts.

Official Patches

siyuan-noteCode patch addressing unauthorized access to filetree APIs

Fix Analysis (1)

Technical Appendix

CVSS Score
6.9/ 10
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N
EPSS Probability
0.24%
Top 85% most exploited

Affected Systems

SiYuan Personal Knowledge Management System

Affected Versions Detail

Product
Affected Versions
Fixed Version
SiYuan
siyuan-note
< v3.7.4v3.7.4
AttributeDetail
CWE IDCWE-862
Attack VectorNetwork
CVSS v4.06.9
EPSS Score0.00237 (Percentile: 14.53%)
ImpactInformation Disclosure / Metadata Leakage
Exploit StatusProof-of-Concept / Patch-based Analysis
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1083File and Directory Discovery
Discovery
T1068Exploitation for Privilege Escalation
Privilege Escalation
CWE-862
Missing Authorization

The software does not perform an authorization check when an actor attempts to access a resource or perform an action, allowing the actor to view restricted data.

Known Exploits & Detection

GitHub Security AdvisoryDescription of the affected endpoints and vulnerable configurations.

Vulnerability Timeline

Official fix committed to repository
2026-07-24
Security Advisory GHSA-5w7r-f4cg-rqq7 published and CVE-2026-72799 assigned
2026-08-12
VulnCheck publishes vulnerability profile
2026-08-12
National Vulnerability Database processes CVE record
2026-08-26

References & Sources

  • [1]GitHub Security Advisory GHSA-5w7r-f4cg-rqq7
  • [2]Fix Commit 5bae092
  • [3]CVE-2026-72799 on CVE.org

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 minutes ago•CVE-2026-109619
9.2

CVE-2026-109619: Remote Code Execution in PHP Core via Stale Global State Memory Corruption (PHP2Shell)

CVE-2026-109619 (PHP2Shell) is a critical Use-After-Free vulnerability in the core PHP engine caused by improper global state cleanup during out-of-memory exception handling across persistent worker requests.

Alon Barad
Alon Barad
1 views•6 min read
•5 minutes ago•CVE-2026-113721
4.5

CVE-2026-113721: Unsafe Link Resolution in virtualenv File Generation

In Python virtualenv prior to version 21.14.9, activation script generators and configuration writers use Path.exists() before writing files. Because Path.exists() resolves symbolic links, it returns False for dangling symlinks. Consequently, virtualenv skips unlinking pre-planted symbolic links or hard links, writing data directly to target locations outside the intended virtual environment directory.

Amit Schendel
Amit Schendel
1 views•5 min read
•9 days ago•CVE-2026-87697
8.8

CVE-2026-87697: Untrusted Deserialization in .NET PresentationCore Clipboard Handling

A remote code execution vulnerability exists in Microsoft .NET due to untrusted data deserialization within the PresentationCore component. The flaw stems from implicit auto-conversion flags during clipboard data retrieval operations.

Alon Barad
Alon Barad
31 views•5 min read
•9 days ago•CVE-2026-70007
8.8

CVE-2026-70007: Out-of-Bounds Write Vulnerability in .NET Framework and WPF Subsystem

An out-of-bounds write vulnerability in Microsoft .NET Framework, .NET runtime, and Visual Studio allows unauthenticated remote attackers to execute arbitrary code via crafted pixel-shader bytecode or auto-converted clipboard payloads.

Amit Schendel
Amit Schendel
19 views•6 min read
•10 days ago•CVE-2026-70186
7.5

CVE-2026-70186: ASP.NET Core Denial of Service Vulnerability via Framework Deadlock

ASP.NET Core contains a thread deadlock vulnerability (CWE-833) that allows an unauthenticated remote attacker to cause a denial of service over the network by exhausting server thread pool resources.

Amit Schendel
Amit Schendel
18 views•5 min read
•10 days ago•CVE-2026-70035
8.8

CVE-2026-70035: Insecure Deserialization Remote Code Execution in Microsoft .NET Framework and .NET Runtime

CVE-2026-70035 is a high-severity Remote Code Execution (RCE) vulnerability in Microsoft .NET Framework, .NET runtime, and Visual Studio caused by improper handling during the deserialization of untrusted data (CWE-502). An unauthenticated attacker can execute arbitrary code within the context of the affected process by delivering a crafted serialized payload.

Amit Schendel
Amit Schendel
24 views•6 min read