usememos / memos

An open source, lightweight note-taking service. Easily capture and share your great thoughts.
https://usememos.com
MIT License
30.3k stars 2.27k forks source link

"403 permission denied: access token not found" on memo pages when not logged in #3706

Closed andrigamerita closed 2 months ago

andrigamerita commented 2 months ago

Describe the bug

After updating to v0.22.3 via Docker, I noticed an issue where memos are now inaccessible via their direct URL if not being logged in, even if they are public and get listed in the Explore page. The error "403: permission denied", "access token not found" is shown. This completely breaks sharing.

Looking at the frontend network request, I notice that the client app calls the following backend URL, with the following data, but receives an empty (0 KB) response: POST https://<instance domain>/memos.api.v1.MemoService/GetMemoByUid, body: \u0000\u0000\u0000\u0000\u0018\n\u0016<uid from the url>.

Steps to reproduce

  1. Ensure you are not logged into your memos instance.
  2. Try to open a public memo by its share url, eg. https://<instance domain>/m/<memo uid>; alternatively, go on the Explore page of your Memos instance, and click on the comments button for any listed memo.
  3. Notice how the page loads but no content is shown, and instead the error is present.

The version of Memos you're using.

v0.22.3

Screenshots or additional context

No response

Brx86 commented 2 months ago

Same issue.

boojack commented 2 months ago

Fixed with https://github.com/usememos/memos/commit/17ecfb5cf5732b2a9033bd84d3796709e08f6dfc