{"id":"CVE-2026-69085","kind":"vulnerability","aliases":["CVE-2026-69085","GHSA-33jq-p8c2-q3q4","GO-2026-6621"],"related":[],"title":"SiYuan: Unauthenticated SQL injection in searchDocs via unescaped keyword (publish mode): cross-notebook read/write with statement stacking in github.com/siyuan-note/siyuan/kernel","description":"SiYuan before v3.7.3 contains a SQL injection vulnerability in the /api/filetree/searchDocs endpoint, where the caller-supplied keyword parameter is concatenated directly into SQL statements with no escaping or parameter binding. The endpoint is reachable by a publish RoleReader token, or unauthenticated when publish mode is enabled with Publish.Auth.Enable set to false. Because the statement executes on a read-write SQLite handle via a driver that supports stacked (semicolon-separated) statements, an attacker can read and modify database content across all cleartext (non-encrypted) notebooks on the instance.","summary":"SiYuan's kernel has an SQL injection in the /api/filetree/searchDocs endpoint: the keyword parameter is concatenated into SQL without escaping. An attacker can read and modify the database for every unencrypted notebook on the instance, and can do so without logging in when publish mode is on with Publish.Auth.Enable set to false.","severity":"critical","cvss":10.0,"epss":0.01488,"exploited":false,"exploited_at":null,"products":[{"name":"github.com/siyuan-note/siyuan/kernel","fixed":["0.0.0-20260721043339-eef10568384e"],"affected":"< 0.0.0-20260721043339-eef10568384e","ecosystem":"go"}],"ecosystems":["go"],"tags":["go","package","publish-mode","self-hosted","siyuan"],"not_affected_if":["auth-required","encrypted-notebooks-only","managed-hosting","publish-mode-disabled"],"how_to_check":"Check whether publish mode is enabled and whether Publish.Auth.Enable is false in the SiYuan config.\nCheck the installed version of github.com/siyuan-note/siyuan/kernel against the fixed pseudo-version 0.0.0-20260721043339-eef10568384e.","fix":"Upgrade SiYuan to v3.7.3 or later (kernel pseudo-version 0.0.0-20260721043339-eef10568384e or newer).\nEnable publish auth (Publish.Auth.Enable true) and rotate any publish RoleReader tokens if you cannot upgrade right away.","status":"open","published_at":"2026-08-03T14:16:28+00:00","first_seen_at":"2026-10-23T19:13:08+00:00","triaged_at":"2026-10-23T21:43:40+00:00","updated_at":"2026-10-23T21:43:40+00:00","category":"package","confidence":0.85,"triage":{"at":"2026-10-23T21:43:40Z","model":"claude-haiku-5-5","output":{"fix":"Upgrade SiYuan to v3.7.3 or later (kernel pseudo-version 0.0.0-20260721043339-eef10568384e or newer).\nEnable publish auth (Publish.Auth.Enable true) and rotate any publish RoleReader tokens if you cannot upgrade right away.","reach":"internet","impact":"high","summary":"SiYuan's kernel has an SQL injection in the /api/filetree/searchDocs endpoint: the keyword parameter is concatenated into SQL without escaping. An attacker can read and modify the database for every unencrypted notebook on the instance, and can do so without logging in when publish mode is on with Publish.Auth.Enable set to false.","category":"package","who_cares":["siyuan","self-hosted","publish-mode","go"],"confidence":0.85,"needs_auth":"unknown","worst_case":"Unauthenticated attacker reads and rewrites cleartext notebook database contents","analyst_note":"","how_to_check":"Check whether publish mode is enabled and whether Publish.Auth.Enable is false in the SiYuan config.\nCheck the installed version of github.com/siyuan-note/siyuan/kernel against the fixed pseudo-version 0.0.0-20260721043339-eef10568384e.\nunknown","needs_analyst":false,"not_affected_if":["publish-mode-disabled","auth-required","encrypted-notebooks-only","managed-hosting"],"user_interaction":"no","needs_special_setup":"yes","severity_if_unknown":"critical"},"cost_usd":0.000577,"input_tokens":3097,"output_tokens":535,"severity_before":"critical"},"analyst_status":null,"analyst_note":null,"search":"'-2026':24A,32A,35A '-6621':33A '-69085':25A,36A '/api/filetree/searchdocs':58B,111C '/siyuan-note/siyuan/kernel':22A,39A '33jq':28A 'across':182C 'attack':70B,175C 'bind':131C 'caller':116C 'caller-suppli':115C 'cleartext':184C 'concaten':64B,121C 'contain':104C 'content':181C 'cross':13A 'cross-notebook':12A 'cve':23A,34A 'databas':76B,180C 'direct':122C 'driver':166C 'enabl':147C 'encrypt':187C 'endpoint':59B,112C,133C 'escap':68B,128C 'everi':78B 'execut':156C 'fals':100B,152C 'ghsa':27A 'ghsa-33jq-p8c2-q3q4':26A 'github.com':21A,38A 'github.com/siyuan-note/siyuan/kernel':20A,37A 'go':31A,40B 'handl':163C 'host':47B 'inject':4A,55B,107C 'instanc':83B,191C 'kernel':51B 'keyword':9A,61B,118C 'log':89B 'mode':11A,44B,93B,145C 'modifi':74B,179C 'non':186C 'non-encrypt':185C 'notebook':14A,80B,188C 'p8c2':29A 'packag':41B 'paramet':62B,119C,130C 'publish':10A,43B,92B,138C,144C 'publish-mod':42B 'publish.auth.enable':97B,149C 'q3q4':30A 'reachabl':135C 'read':72B,160C,177C 'read-writ':159C 'read/write':15A 'roleread':139C 'searchdoc':6A 'self':46B 'self-host':45B 'semicolon':171C 'semicolon-separ':170C 'separ':172C 'set':98B,150C 'siyuan':1A,48B,49B,101C 'sql':3A,54B,66B,106C,124C 'sqlite':162C 'stack':18A,169C 'statement':17A,125C,155C,173C 'suppli':117C 'support':168C 'token':140C 'unauthent':2A,142C 'unencrypt':79B 'unescap':8A 'v3.7.3':103C 'via':7A,164C 'vulner':108C 'without':67B,88B 'write':161C","nicknames":[],"mitigations":[],"who_affected":null,"tier":null,"verified":{},"analyst_revisit_at":null,"first_public_at":"2026-08-03T14:16:28+00:00","kev":null,"cvss_vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","cvss_by":"disclosure@vulncheck.com","poc_count":0,"sources":[{"source":"govuln","external_id":"GO-2026-6621","url":"https://pkg.go.dev/vuln/GO-2026-6621","severity":null,"published_at":"2026-10-07T14:09:59+00:00","modified_at":"2026-10-07T14:09:59+00:00","first_seen_at":"2026-10-23T19:13:08+00:00","fetched_at":"2026-10-23T19:13:08+00:00","note":null},{"source":"epss","external_id":"CVE-2026-69085","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-69085","severity":null,"published_at":null,"modified_at":null,"first_seen_at":"2026-10-23T19:13:43+00:00","fetched_at":"2026-10-23T19:13:43+00:00","note":null},{"source":"nvd","external_id":"CVE-2026-69085","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-69085","severity":null,"published_at":"2026-08-03T14:16:28+00:00","modified_at":"2026-08-26T17:06:41+00:00","first_seen_at":"2026-10-23T19:35:23+00:00","fetched_at":"2026-10-23T19:35:23+00:00","note":null}],"documents":[],"notice":"Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai"}