Skip to content

New parameter in redirect uri breaks redirect uri #1017

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

Closed
StefanSzakacs21 opened this issue Feb 3, 2021 · 5 comments
Closed

New parameter in redirect uri breaks redirect uri #1017

StefanSzakacs21 opened this issue Feb 3, 2021 · 5 comments
Labels
bug For tagging faulty or unexpected behavior. investigation-needed Indication that the maintainer or involved community members may need to investigate more.

Comments

@StefanSzakacs21
Copy link

StefanSzakacs21 commented Feb 3, 2021

Describe the bug
Up until now we were getting the usual code, scope, state and session state redirect uri params. After an update on the server we started receiving the "iss" param too. This now breaks the redirect uri, it will append &iss without value to our redirectUri instead of processing it completely and removing it, just as with the other params mentioned above, and hence break the routing. Instead of localhost:4200/logging-in we get localhost:4200/logging-in&iss

To Reproduce
Steps to reproduce the behavior:

  1. Have an extra param sent from the server

Expected behavior
Ignore the extra parameters

Desktop (please complete the following information):

  • OS: macOS
  • Angular 8.2
  • angular-ouath2-oidc: 10.0.3
@jeroenheijmans
Copy link
Collaborator

Just a quick thought, I recall seeing #959, would you reckon that's the same type of issue?

@jeroenheijmans jeroenheijmans added bug For tagging faulty or unexpected behavior. investigation-needed Indication that the maintainer or involved community members may need to investigate more. labels Feb 4, 2021
@StefanSzakacs21
Copy link
Author

Yes, it seems to be the same issue, similarly the parameter's key is taken out and appended to the redirectUri directly, without even a /?, directly with ./logging-in&parameter-name after the params are processed

@ajurge
Copy link

ajurge commented Mar 11, 2021

I also have the same issue with the iss and also client_id query parameters in the redirect response Location header from our oauth server. We are using code flow with PKCE. iss query parameter produces the following error:

 RouterErrorHandler: Error: Cannot match any routes. URL Segment: '&iss'

The URL looks something like this: http://www.app.com/context/&iss=https%3A%2F%2Foauth.server.com%3A443%2Fsecure%2Foauth2&client_id=CLIENT_ID

Since angular-oauth2-oidc only removes the code and state query parameters so I had to implement a workaround into our app and remove iss and client_id . Then everything works.

angular-oauth2-oidc: 10.0.3
angular 11.2.5

@manfredsteyer
Copy link
Owner

Can you please retry it with version 12 (lands later today) and reopen this issue if it is still in place. I have the impression, its gone now.

@ajurge
Copy link

ajurge commented Jul 19, 2021

It works now, thanks for fixing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug For tagging faulty or unexpected behavior. investigation-needed Indication that the maintainer or involved community members may need to investigate more.
Projects
None yet
Development

No branches or pull requests

4 participants