amoscardino / linkthing

A client app for linkding built with Ionic.
MIT License
65 stars 1 forks source link

Trouble with linkding behind authentication #35

Closed dineshhmn closed 5 months ago

dineshhmn commented 1 year ago

Hi amoscardino,

Firstly, I really appreciate the app being available for iOS devices and I thank you for the time that you put into it.

I have linkding set up being Authelia ( a reason for me to choose linkding was that it handled user management using the auth service).

When I try to set the app with my public URL, it just freezes with a black screen. When I try my local URL, the user not being in Linkding database gives me a login error.

My guess is that the app is having some trouble going through the auth service. Any chance that functionality can be added?

Thank you once again for the app.

amoscardino commented 1 year ago

I'm not familiar with Authelia so I'm not sure what could be going wrong here. Are you still able to get an API token from the linkding web UI? That token is the key to making the API work as it's the only authentication method supported.

dineshhmn commented 1 year ago

Authelia is Single Sign On service that can be used along with a reverse proxy. More info here: https://github.com/authelia/authelia. You log into Authelia, and dont log into linkding. To be able to reach the endpoint you need to sign into Authelia, and then get redirected to linkding.

This makes things convenient because linkding's users are the same as authelia.

It is something that is supported by linkding (as mentioned here: https://github.com/sissbruecker/linkding/blob/master/docs/Options.md#ld_enable_auth_proxy). I hope you can also support it.

PS: While using the chrome extension, you have to first sign into Authelia, only then can you linkding. Otherwise you get an error. My guess is the SSO credentials are saved on chrome's cache thats why its working. I hope this helps.

Thank you.

chrisb86 commented 10 months ago

I use linkding with Authelia behind traefik.

For the /api path I disabled SSO because the communication with the API is authenticated by the API key anyways.

Since this change, LinkThing works as expected.

amoscardino commented 5 months ago

I'm going to close this issue since I don't believe there's anything I can do for it.