Check SSO not working
See original GitHub issueI’m trying to use
await keycloak.init({
config: {
url: 'url',
realm: 'realm',
clientId: clientId'
},
initOptions: {
onLoad: 'check-sso',
checkLoginIframe: false
}
});
But it is still being redirected to login.
http://localhost:4200/#error=login_required&state=67f53f12-206c-44b9-83be-7eef7c982ce4
It also doesn’t work with the example provided.
Issue Analytics
- State:
- Created 6 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
SSO does not work and users are getting prompted for ...
Under Advanced, check the state of Enable Integrated Windows Authentication. Ensure that the option is enabled or checked. · Go to the Security...
Read more >[keycloak-user] check-sso not working as expected with iframe
As I've seen that the check-sso would use iframe > in a hidden request but if it is not working as expected than...
Read more >Keycloak check-sso create - javascript - Stack Overflow
I'm trying to make some public pages, so I'm using 'check-sso'. If I have understood correctly, if the user is not logged-in, ...
Read more >Troubleshoot single sign-on (SSO) - Google Support
This problem is almost certainly due to a configuration issue in the Identity Provider. Check your Identity Provider logs and make sure that...
Read more >Keycloak- silent check sso is not working - adapter-javascript
Hi, I have configured keycloak-js for my project. I configured silent check sso for my project but it is being redirected to the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hello @bpalermo,
Besides using
onLoad: 'check-sso'
you have to specify what url patterns must be excluded from the bearer interceptor, using thebearerExcludedUrls
property.So if you want to exclude the pages ending with main you have to use it:
The reason it redirects to the login page is that the KeycloakBearerInterceptor sends a request to renew the token and as the user is not authenticated it will be redirected to the login page.
About your comment:
In the next major version I will think about it. I will also improve the documentation to clarify some aspects of the library.
Thanks!
What does mean main$, and bearerExcludedUrls: is to exclude from API call URLs or routing defined in angular-routes?