← Blog · · df00tech

SiYuan Publish Mode: Unauthenticated Arbitrary SQL Execution via searchEmbedBlock (CVE-2026-69084)

breaking ghsa go CVE-2026-69084

A newly published GitHub Security Advisory (GHSA-vh22-h7hf-www7) discloses CVE-2026-69084, a critical (CVSS 10.0) flaw in SiYuan's kernel affecting the /api/search/searchEmbedBlock endpoint. According to the advisory, this endpoint accepts a client-supplied raw SQL statement and passes it verbatim to the application's main siyuan.db database handle, with no single-statement check, no read-only enforcement, and no admin-role gate. The route is protected only by CheckAuth, which admits the publish-mode Reader role — and when Publish.Auth.Enable is set to false, is reachable by anonymous requests entirely. A public proof-of-concept is reportedly available.

Why It Matters

SiYuan instances running in publish mode with authentication disabled are exposed to unauthenticated, arbitrary SQL execution against the live database. Because the underlying handle is read-write and the driver executes stacked (semicolon-separated) statements, the advisory states this permits cross-notebook read disclosure of document content as well as modification of database content and ATTACH-reachable files — without needing an admin token, CSRF token, or normal write permissions. Encrypted notebooks are reportedly excluded since they use separate per-box databases, and the advisory notes code execution is not reachable in the default build since load_extension is unavailable. Any organization or individual self-hosting SiYuan in publish mode should treat this as a high-priority exposure.

What Defenders Should Do Now

  • Identify any SiYuan deployments, especially those running in publish mode, and check whether Publish.Auth.Enable is set to false — if so, this should be treated as an immediate exposure until patched.
  • Watch kernel/API logs for POST requests to /api/search/searchEmbedBlock, particularly those containing SQL keywords beyond simple SELECT (e.g., ATTACH, UPDATE, INSERT, DELETE, or stacked statements separated by ;) originating from unauthenticated or reader-tier sessions.
  • Compare traffic patterns against the endpoint's guarded siblings (/api/query/sql, fullTextSearchBlock) — requests hitting searchEmbedBlock with SQL-search-style payloads that would be rejected elsewhere are a strong signal of exploitation attempts.
  • As an interim mitigation, restrict or disable publish-mode exposure to untrusted networks, and enable publish authentication if it is currently off, pending an official patch that applies the same CheckSingleStatement/CheckReadonlyStatement/admin-role controls used by comparable endpoints.

This is developing intel based on a same-day advisory; details on an official fix or patched version were not included in the source material reviewed. Track the original disclosure for updates: GHSA-vh22-h7hf-www7.

Get new detections in your inbox

New ATT&CK coverage plus CISA KEV / CVE detection rules, roughly weekly. No spam, unsubscribe anytime.