Giter Site home page Giter Site logo

Comments (8)

BapRx avatar BapRx commented on May 23, 2024 1

Perfect thank you πŸŽ‰

from photoprism-android-client.

Radiokot avatar Radiokot commented on May 23, 2024

Hey there Baptiste.
Is this a standard behavior for Authelia? I don't have it personally, but we've tested the redirect with another PhotoPrism Gallery user who has their library under Authelia.

from photoprism-android-client.

Radiokot avatar Radiokot commented on May 23, 2024

For now, I can suggest configuring Authelia to make redirects for your PhotoPrism library using HTTP codes in the 300 range. Redirects by 401 with Location are not supported by the app's network stack, I can say it right away.

from photoprism-android-client.

BapRx avatar BapRx commented on May 23, 2024

I haven't altered the default response behavior of Authelia and it seems to respond with a 3XX code for GET / OPTION requests per the documentation:

If I understand correctly, Authelia returns a 401 with the header WWW-Authenticate set, since it's a standard maybe the app could catch this?

I'm curious about the other user's setup!

from photoprism-android-client.

Radiokot avatar Radiokot commented on May 23, 2024

Hmm, I think I got what's wrong. You use PhotoPrism credentials along with Authelia while the one who tested this feature had their libarary running in a public mode to avoid double authentication. If you connect to a public library, the first request is GET, however, if there are credentials, it is POST. That's why Authelia responds differently.
Question out of curiosity: why would one want to have 2 authentications one by one for a photo library?

from photoprism-android-client.

Radiokot avatar Radiokot commented on May 23, 2024

Please, try connecting to the library with Authelia and PhotoPrism credentials in this build:
https://send.bitwarden.com/#_hYd9lj5D02iKrEoAUNrwg/YV-QviPYcFXbDxNcICmKyg

from photoprism-android-client.

BapRx avatar BapRx commented on May 23, 2024

Hmm, I think I got what's wrong. You use PhotoPrism credentials along with Authelia while the one who tested this feature had their libarary running in a public mode to avoid double authentication. If you connect to a public library, the first request is GET, however, if there are credentials, it is POST. That's why Authelia responds differently. Question out of curiosity: why would one want to have 2 authentications one by one for a photo library?

Good analysis! I'm indeed running an authenticated Photoprism instance mostly because I'm synchronizing pictures from my devices with an app that doesn't support Authelia and thus I have to bypass the 2nd factor for this specific route. I still want it to be password protected.

Also I'm waiting on these issues to be completed since it's imo the optimal setup photoprism/photoprism#782 / photoprism/photoprism#3943

I just tested the APK you sent me and it's working! Good job and thank you for you reactivity.

Tell me if you need any more test or information.

from photoprism-android-client.

Radiokot avatar Radiokot commented on May 23, 2024

Makes sense indeed πŸ’‘
Thank you for testing, the fix will be included into the next release. Until then, you can use the clone build if you are comfortable with it.

from photoprism-android-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.