pod-browser icon indicating copy to clipboard operation
pod-browser copied to clipboard

Feature Request: Support one WebID with multiple pods requiring different IdP's

Open chalford opened this issue 3 years ago • 3 comments

Hi, thanks for the awesome app! My setup is as follows. I have an Inrupt Pod Spaces pod, where my WebID is stored in the usual //profile/card#me URI. I have also installed the Community Solid Server locally, and have used to create another pod, but using the same WebID. Happily, once I'd added the solid:oidcIssuer triple for my local CSS installation to my WebID document, Pod Browser allowed me to log in with CSS.

However, by default, PodBrowser tried to load resources from my Inrupt Pod Spaces pod. Unsurprisingly, my authentication token from my local CSS installation isn't valid, and all resources return a 401 error. To try and correct this, I added a space:storage triple pointing to my pod on my local CSS installation, hoping that PodBrowser would allow me to select my pod from a dropdown or something.

Am I doing something wrong here, or is support for multiple pods in a WebID a feature request? I did notice a "Change pod" dropdown when I'm logged in via the Inrupt Pod Spaces OIDC issuer, but I don't get that far when I log in with local CSS.

chalford avatar Mar 19 '22 21:03 chalford

There is a dropdown now in the UI, though it'll typically default to the first pod found, rather than prompting on login.

Screenshot 2022-03-22 at 18 09 28

ThisIsMissEm avatar Mar 22 '22 17:03 ThisIsMissEm

Thank you. I guess part of my request is for some way to select the pod you want to access (perhaps using the list from space:storage triples in your WebID) when the PodBrowser isn't loading correctly. In my situation, I logged into the PodBrowser with my local CSS Pod, but it automatically chose my Inrupt Pod Spaces Pod to display. This results in a spinning circle (as my local CSS pod access token isn't valid), and I don't get access to the drop down you show above.

chalford avatar Mar 22 '22 17:03 chalford

The current pod selection "algorithm" in pod browser is pretty simplistic, we just take the first pod we find: https://github.com/inrupt/pod-browser/blob/main/components/pages/index/index.jsx

There is a minor improvement to use the new getPodUrlAll API instead of our custom hook — but that won't fix the different authentication providers for different pods — it's just a code cleanup matter and is behind upgrading the SDK which we have in our backlog.

I'll mention this as a feature request to the team, but one WebID, multiple pods, different authentication really isn't a use case that we support right now.

ThisIsMissEm avatar Mar 22 '22 19:03 ThisIsMissEm

Supporting one WebID but multiple pod storage providers requiring different IdPs is not something we can support at the moment (support would mean scanning your WebID for a space:storage IRI for which we can issue a request to, which takes a simplistic implementation we current have for default pod selection from 1 request (get your WebID, select the first value) to 1+N requests, where N is the number of space:storage values in your WebID.

Perhaps there could be a UI change here where by if we find multiple pods, we list them out and allow you to choose, but this isn't something we'll be implementing right now.

ThisIsMissEm avatar Jan 05 '23 19:01 ThisIsMissEm