TAMULib / dspace-angular

DSpace 7.x (and above) User Interface built on Angular.io
https://wiki.lyrasis.org/display/DSDOC7x/
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

External Login (Shibboleth and EntraId) often fails to load correctly #85

Open wwelling opened 5 months ago

wwelling commented 5 months ago

After logging in through an identity provider the UI errors. It appears to be a race condition.

This is rendered in the login model: undefined doesn't contain the link authn

There are errors in the console:

main.f7193ce80585402a.js:1 
 No _links section found at https://oaktrust-pre.library.tamu.edu/server/api

Error: undefined doesn't contain the link authn
    at main.f7193ce80585402a.js:1:538685
    at main.f7193ce80585402a.js:1:2944996
    at l._next (main.f7193ce80585402a.js:1:2941016)
    at l.next (main.f7193ce80585402a.js:1:2929816)
    at main.f7193ce80585402a.js:1:2944989
    at l._next (main.f7193ce80585402a.js:1:2941016)
    at l.next (main.f7193ce80585402a.js:1:2929816)
    at main.f7193ce80585402a.js:1:2949271
    at l._next (main.f7193ce80585402a.js:1:2941016)
    at l.next (main.f7193ce80585402a.js:1:2929816)

It occurs regularly enough and requires a page refresh to function correctly.

JamesS-TAMU commented 5 months ago

Just to provide some additional info:

I've experienced this undefined doesn't contain the link authn randomly with either/both oaktrust dev and oaktrust pre when logging in using either OIDC or Shib. Sometimes refreshing, trying in Chrome incognito or Edge InPrivate would work, other times not. And sometimes login would work on oaktrust dev but at the same time not on oaktrust pre or vice versa. The two shibboleth service providers and their virtual host configs are also identical (besides the URL). So I had always thought it was due to cookie/cache.

It seems to also behave a bit differently when you're connect VPN or not.