Impact
A Local File Inclusion flaw in Trilium Notes allows an authenticated user to specify an arbitrary file’s path via the uploadModifiedFileToAttachment API. Upon submission, the server replaces an attachment’s content with the contents of that file. The subsequent download endpoint then serves the file contents, exposing sensitive data such as SSH keys, credentials, configuration files, and operating system files. Because these files can contain sensitive credentials, the vulnerability can lead to data compromise and, as noted in the advisory, potentially enable remote code execution on the host and compromise co‑hosted applications. The weakness is reflected in CWE‑22 (Path Traversal) and CWE‑73 (Improper Checking or Handling of File Paths).
Affected Systems
Trilium Notes versions 0.102.1 and earlier, distributed by TriliumNext, are affected. The flaw exists in the uploadModifiedFileToAttachment function invoked when a POST request is made to /api/attachments/{attachmentId}/upload-modified-file. The issue was addressed in release 0.102.2. Users running older versions should be aware that any authenticated session can trigger the vulnerability.
Risk and Exploitability
The CVSS score of 6.8 indicates a moderate to high severity. No EPSS data is available, and the vulnerability is not listed in the CISA KEV catalog. The exploit requires authentication, so an attacker must first obtain valid user credentials. Once authenticated, the attacker can use the targeted API to read arbitrary files, potentially escalating to remote code execution if sensitive files are compromised. Because the attack vector is through a legitimate, authenticated endpoint, the risk remains significant for exposed instances.
OpenCVE Enrichment