zadam / trilium

Build your personal knowledge base with Trilium Notes
GNU Affero General Public License v3.0
27.41k stars 1.93k forks source link

(Bug report) Title of protected note is visible when linked into shared note #4801

Open LokiLuciferase opened 5 months ago

LokiLuciferase commented 5 months ago

Trilium Version

0.63.7

What operating system are you using?

Other Linux

What is your setup?

Server access only

Operating System Version

Arch Linux

Description

According to the docs, the title of a shared note is supposed to be part of the encrypted content of a protected note and the note is unloaded from the browser upon closing of the protected session. However when viewing a shared note in the browser which contains a link to a protected note, the plain text title is visible.

I can confirm this only happens if the protected note is linked into the shared note while the protected session is active (not, for example when linking the protected note in by targeting tags while the protected session is closed).

Steps to reproduce

  1. create a new note to be shared later
  2. hit "protect the note" on some other note, thereby entering a protected session
  3. While still in the protected session, link the protected note inside the to be shared note with @
  4. close protected session
  5. share the to be shared note
  6. open the shared link - the title of the shared note is visible in plain text (while in trilium it is, correctly, obscured).

View from inside trilium: image

Shared note in browser: image

Error logs

No response

edit: clarified the steps to reproduce since the order of events seems to be important