External risk intelligence

SiYuan PDF Annotation Script Injection Leading to Remote Code Execution.

CVE advisorySeverity: CRITICAL (CVSS 9.4)

CVE-2026-73041

This vulnerability requires a user to open a specifically annotated PDF within the SiYuan application, which is a local note-taking tool. The attack surface is tied to client-side file processing and user interaction, rather than exposure as a public-facing network service or internet gateway.

Cross-site Scripting

Halo Surface Signal: 1 out of 5 — much less likely to be public-facing.

External exposure likelihood

Horizon Alert

Summary of the vulnerability and why it matters

This advisory highlights a critical vulnerability in SiYuan's PDF annotation feature. When users open a specially crafted PDF, malicious code could be executed, potentially leading to unauthorized access and control of the system. The primary concern is to verify if this type of technology is used within the organization and if any exposure exists.

  • Malicious code in PDF annotations can run scripts.
  • Users opening annotated PDFs are at risk.
  • Confirm relevance and exposure; no immediate broad impact.

Attack Path

How an attacker could exploit the issue

An attacker can inject malicious code into PDF annotation fields using the setFileAnnotation endpoint. When a user opens a specially crafted PDF within SiYuan, this malicious code executes as a script within the application's PDF renderer, granting the attacker full access to the underlying Node.js environment.

  • Requires authenticated access to the setFileAnnotation endpoint.
  • Triggered when a user opens an annotated PDF.
  • Leads to script execution with full Node.js access.

Live Threat

Current exploitation, exposure, and threat context

When a user opens a specially crafted PDF file with an annotation, malicious script could execute, granting an attacker access to the Node.js environment.

  • System data and user data.
  • Opening malicious annotated PDF.
  • Full Node.js environment access.

Operational Fix

Recommended remediation, mitigation, and detection steps

The SiYuan application's handling of PDF annotations presents a critical risk, as unvalidated markup can lead to script execution within the PDF renderer. This scenario typically implicates the owners of the SiYuan application instances, potentially the end-users themselves if self-hosting, or an internal platform team if managed centrally. The immediate practical step is to identify all deployed instances, assess their reachability and business criticality, and then engage the accountable owner to plan remediation, likely involving vendor coordination for a fix or establishing compensating controls.

  • Application owners or platform teams.
  • Verify annotation field validation and reachability.
  • Coordinate vendor update or implement controls.

Supplementary metadata

Validate whether this threat affects your internet-facing exposure.

Halo Threat Intelligence helps prioritize remediation with Halo Surface Signal and H/A/L/O context. Start exposure validation with a free external attack surface trial.

Frequently asked questions

What is SiYuan?

SiYuan is a local-first, privacy-focused note-taking application. It supports features like block-based editing, Markdown rendering, and integrated PDF viewing. Because it is built on web technologies, it includes a Node.js environment to handle backend processes and data management directly on the user's local machine.

What is the weakness class for CVE-2026-73041?

This issue is classified as CWE-79, or Improper Neutralization of Input During Web Page Generation, commonly known as Cross-Site Scripting (XSS). In this specific case, the software fails to properly filter input within PDF annotation fields. Because the application uses a powerful environment for rendering, this flaw allows injected markup to execute as functional scripts rather than just displaying as text.

How is the malicious code triggered?

An attacker must successfully use the setFileAnnotation endpoint to embed malicious markup into a PDF file. The vulnerability does not trigger by simply having the file present on a system. It only activates when a user interacts with the application to open that specific, maliciously annotated PDF document.

Is my organization at risk for CVE-2026-73041?

According to Halo Surface Signal, risk is very unlikely because the vulnerability requires manual user interaction to open a specific file. It is not an internet-facing network service that can be scanned or targeted remotely by an outsider. The danger is localized to the specific device where a user opens an untrusted, crafted PDF file within the application.

What should I do if I use SiYuan?

The most effective first step is to check your current version of SiYuan. Since the vulnerability is fixed in version 3.7.4 and later, you should update your installation immediately. If an update is not currently possible, you should avoid opening PDF files from unknown or untrusted sources within the application until the software can be patched.

References