-
Notifications
You must be signed in to change notification settings - Fork 686
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OAuthService config is null after the page is reloaded #872
Comments
I don't believe this should happen, or that it does happen in e.g. in my own sample application. I'd suspect something specific to your application. Could you create a minimized version (reproducible scenario) from your, for a community member to look at? |
@axell9641 Same issue here, seems like password flow has been broken.
|
Ah yeah, I don't ever use Password Flow. However, OP doesn't mention it, so we might be looking at two different issues. @axell9641 did you use Password Flow too? |
@jeroenheijmans no. I'm using the implicit flow |
Thanks for this info and for the workaround. I'll look into this asap. |
I don't think I can provide an example since the url generated by stackblitz will have to be registered on my adfs server. Now I don't get any error and the user is correctly redirected to the This is my AuthConfig
Do you have any idea what could be causing this ? |
@manfredsteyer , @jeroenheijmans Could anyone please confirm to me whether it is normal that If I refresh the page(By pressing F5) and then logout, the
|
See my initial comment: this is unexpected, and as far as I know this does not happen in my own applications. |
OK, thank you. I'm going to take a look this branch in your example and then try to create an example with my own configuration , but using your indentity server and see if I can reproduce the error. |
I cloned the repo corresponding to the implicit flow, installed the required packages, and run the application, but when I try to login I get this error: I'm not sure if the configuration that is place is correct, or if I have to change something. I'd really appreciate if you could shed some light on this. |
Another thing I noticed is that you never called the |
I cannot find where you inject that dependency,but I guess that's a matter of preference. |
They get injected into the library's I wasn't aware that my sample's implicit flow was broken, I that seems to be because the demo.identityserver.io instance removed that client recently. You could try to use this config instead though your mileage may vary. |
@jeroenheijmans I changed the previous configuration for the one you recommended.
Is there anything else I need to add so that the user can be redirected back once they have been logged out? P.S. I thought that to use the implicit flow you needed to add this to the config : |
Your screenshot does say "Click here to return to the client...", non? If you want your Identity Server to automatically redirect users back, I think you must configure that in your IDS. |
Yeah I know it says that, but among the example servers you have, is there any that has that option already configured? The ADFS server I'm using already does. That's why I'm trying to recreate the issue I described above with a server that supports the logout redirection. That's why I was talking about the |
Original Poster, did you ever figure this out? I'm going back over the thread above, but can't see much else the community here could do to help at this point... |
Any updates on this issue? |
I think the Original Poster @axell9641 abandoned this issue, or maybe worked around it. I will close this issue since interaction died down. @pyronlaboratory if you were pinging because you had similar symptoms, I recommend opening up a fresh issue with your specific scenario and steps to reproduce the error, so the community can give it a fresh look. |
I'm trying to logout using the logOut method provided by OAuthService.
Everything works fine, but if for some reason the user reloads the page (e.g. by pressing F5) before they try to log out, I get this message:
ERROR TypeError: Cannot read property 'customTokenParameters' of null at OAuthService.logOut (angular-oauth2-oidc.js:2128)
I double-checked and all the information stored in "Session Storage" is removed, but the user is not redirected to the logoutUrl because of the error described above.
I also did a little bit of debugging in the logOut method and that's when I found that the config property is null as it is shown in the following image:
Is this the expected behavior? Should I call the configure method again if the config is null ?
The text was updated successfully, but these errors were encountered: