fr0tt / benotes

An open source self hosted notes and bookmarks taking web app.
https://benotes.org
MIT License
718 stars 49 forks source link

iframe #79

Open Famku opened 1 year ago

Famku commented 1 year ago

Hi,

I would like to show Benotes in an iframe.

Unfortunately the login in an iframe doesn't work for me.

Maybe you know a solution?

fr0tt commented 1 year ago

Hi,

just to clarify, you mean you can't login in that case or do you mean in a more general way (because I could imagine that saving the authentication cookie might be difficult in an iframe) ?

Famku commented 1 year ago

Login lets me through but there is no content

chrome console shows me this error (in German, sorry)

Anfrage-URL: http://192.168.1.55:8080/api/auth/me Anfragemethode: GET Statuscode: 401 Unauthorized Remote-Adresse: 192.168.1.55:8080 Richtlinien für Verweis-URL: strict-origin-when-cross-origin

fr0tt commented 1 year ago

Have you tried using Firefox ? It could have something to do with the samesite policy for cookies in Chrome

Famku commented 1 year ago

same issue with Firefox

fr0tt commented 1 year ago

You could try to check if that's actually the cause by disabling it for a brief moment: https://stackoverflow.com/questions/65130753/disable-samesite-cookie-policy-in-firefox-developer-edition