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

govCloud requires alternate federation URL #533

Open
archoversight opened this issue Aug 7, 2020 · 6 comments · May be fixed by #557
Open

govCloud requires alternate federation URL #533

archoversight opened this issue Aug 7, 2020 · 6 comments · May be fixed by #557

Comments

@archoversight
Copy link
Contributor

Hello,

I am attempting to use saml2aws console to login directly to the AWS console after doing the authentication dance, however it is taking me to AWS Commercial for the federation endpoint, rather than to the govCloud endpoint.

https://signin.amazonaws-us-gov.com/federation

I have set my region to us-gov-west-1 and that works fine for logging in (the default does not work because once again it tries to exchange the SAML assertion at the wrong STS endpoint), but it seems that the federation URL is hardcoded and is not switched depending on the environment.

@archoversight
Copy link
Contributor Author

Here's the list of govCloud specific endpoints: https://docs.aws.amazon.com/govcloud-us/latest/UserGuide/using-govcloud-endpoints.html

@aghassemlouei
Copy link

This issue is also affecting us; would appreciate any assistance in closing this gap.

@zpriddy
Copy link

zpriddy commented Aug 12, 2020

Same for us as well.

@duckfez
Copy link
Contributor

duckfez commented Sep 12, 2020

I can make this work with the tiniest diff -- https://gist.github.com/duckfez/c346dcff94d7b2379e7cf52c38630c9c. But, then it doesn't work for the commercial regions. It seems to me like the right thing to do is probably to update .../commands/console.go to do some parsing of the value of region in the config, and if the region is clearly a govcloud one, then use the right value(s) for it.

I'll attempt a PR?

duckfez pushed a commit to duckfez/saml2aws that referenced this issue Sep 13, 2020
use region= in config file as hint for where to open
the console at.
@duckfez duckfez linked a pull request Sep 13, 2020 that will close this issue
@duckfez
Copy link
Contributor

duckfez commented Sep 13, 2020

My PR seems to fix this for govcloud. I tried to make it also work for AWS China partitions, but I don't have ability to test there.

@neptune19821220
Copy link

Hi, is there any update for this issue?

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 a pull request may close this issue.

5 participants