Infinite loop of redirects after logging in
See original GitHub issueSo I am trying to make a nextjs project using keycloack as authentication server and I am using this project to make it work, the problem is after I signin it will redirect me in an infinite loop.
steps to reproduce:
Run a Keycloak server and create a client app (The name you enter is the clientID)
Next clone the nextjs demo (From react-oidc) and change settings in the layout component to the links you can find at http://localhost:8080/realms/REALMNAME/.well-known/openid-configuration
Now start the nextjs with “yarn dev” and go to localhost:3001 then login and it wil keep redirecting you
Versions
“@axa-fr/react-oidc”: “^5.11.1”,
Screenshots
Being sent in console every redirect
(laggy video) https://user-images.githubusercontent.com/26123873/178000395-1a0343a2-6741-403a-97ce-d7f496181f03.webm
Expected
Show me te page I have to login for.
Actual
Infinite redirecting
Additional Details
- Installed packages:
"dependencies": {
"@axa-fr/react-oidc": "^5.11.1",
"next": "latest",
"react": "17.0.2",
"react-dom": "17.0.2"
}
Issue Analytics
- State:
- Created a year ago
- Comments:27 (16 by maintainers)
Top GitHub Comments
Ayy, No problem! Thankyou a lot for fixing this, I can finally do some authentication with Keycloak!
Well this issue can be closed since the problem is fixed 😁, but will open a new one since I noticed another problem regarding another issue 😅.
Thank you very much for your vidéo, i think there is another part of the bug here https://github.com/AxaGuilDEv/react-oidc/blob/master/packages/react/src/oidc/core/routes/OidcRoutes.tsx I have to sleep, i will try to fix it tomorrow.