Skip to content
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

fix redirect url param handling #10

Merged
merged 3 commits into from Mar 5, 2019

Conversation

dt-rush
Copy link
Contributor

@dt-rush dt-rush commented Dec 6, 2018

See issue #9

@dt-rush dt-rush closed this Dec 6, 2018
@dt-rush dt-rush reopened this Dec 6, 2018
@dt-rush dt-rush changed the base branch from master to migration December 6, 2018 16:50
@dt-rush
Copy link
Contributor Author

dt-rush commented Dec 6, 2018

Requesting review from @JoelSpeed

Thanks for pushing this forward!

@dt-rush
Copy link
Contributor Author

dt-rush commented Dec 9, 2018

See the corresponding issue I had opened on the old, dead repo before I realized it was dead for some extra context. This PR not only fixes the user-supplied redirect URL not being honoured, but it also actually uses it for both forming the request to the auth server and for listening for the callback on the appropriate path. In OAuth, "redirect URL/path" and "callback URL/path" are not distinct - the former is how the spec calls it, and the latter is what it colloquially goes by for some people.

@JoelSpeed
Copy link
Member

Hi @dt-rush, thanks for submitting this PR,

I've had a quick look over the PR and initially I agree with the proposed change, I'm at Kubecon this week and would like to have a further look into the code before accepting the PR.

I also plan to get #7 merged before accepting any additional PRs so please bear with me on that

@dt-rush
Copy link
Contributor Author

dt-rush commented Dec 11, 2018

@JoelSpeed no sweat! I've used the git diff as a patch for my deployment.

JoelSpeed
JoelSpeed previously approved these changes Jan 20, 2019
Copy link
Member

@JoelSpeed JoelSpeed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is the correct behaviour, looks like the flag's value is just being blatantly ignored at the moment and it's been this way for a very long time looking at the blame. When the proxy-prefix flag was introduced this flag was overwritten and it's been broken since. Thanks for the fix!

@JoelSpeed
Copy link
Member

You'll want to rebase onto master to allow pick up the linting changes that have been merged to fix the CI

@JoelSpeed
Copy link
Member

Would you please also add a note in the changelog file to mention that you've fixed the behaviour of this flag

@JoelSpeed JoelSpeed dismissed their stale review January 22, 2019 12:00

Needs rebase and changelog updating

@Ghazgkull
Copy link

@dt-rush Thanks for putting together this PR. This bug is affecting me as well and I'd love to see it merged.

@JoelSpeed As a motivated user, is there anything I can do to help get this PR merged?

@dt-rush dt-rush requested a review from a team February 28, 2019 18:06
@dt-rush
Copy link
Contributor Author

dt-rush commented Feb 28, 2019

@Ghazgkull I just rebased on master. Until this is merged, I've been simply using a patch which applies the changes to the source before building the binary.

@JoelSpeed, could we try to merge this now?

@dt-rush
Copy link
Contributor Author

dt-rush commented Feb 28, 2019

(Note: lint is failing in the travis build, but it complains about so many files that I suspect this is a goal for the repo, not a standard which we're currently meeting)

@ploxiln
Copy link
Contributor

ploxiln commented Feb 28, 2019

you should change the merge-target branch from "migration" to "master"

@dt-rush dt-rush changed the base branch from migration to master February 28, 2019 18:13
JoelSpeed
JoelSpeed previously approved these changes Feb 28, 2019
@JoelSpeed
Copy link
Member

One final thing before this gets merged, could you please add a note to the Changelog describing the change you have made (Please see existing entries for the format)

@Ghazgkull
Copy link

@JoelSpeed Looks like @dt-rush submitted new changes which include the Changelog updates. Thanks, folks!

Copy link
Member

@JoelSpeed JoelSpeed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks @dt-rush

aigarius pushed a commit to aigarius/oauth2_proxy that referenced this pull request Mar 8, 2019
* Added conditional to prevent user-supplied redirect URL getting
clobbered

Change-type: patch

* use redirectURL as OAuthCallbackURL (as it should be!)

Change-type: patch
@JoelSpeed JoelSpeed mentioned this pull request Mar 12, 2019
3 tasks
michael-freidgeim-webjet pushed a commit to MNF/oauth2-proxy that referenced this pull request Sep 4, 2021
vjacynycz referenced this pull request in vjacynycz/oauth2-proxy Jul 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants