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

sso-session config file section doen't work. #5153

Open
steffakasid opened this issue Jan 26, 2024 · 5 comments
Open

sso-session config file section doen't work. #5153

steffakasid opened this issue Jan 26, 2024 · 5 comments
Assignees
Labels
bug This issue is a bug. p2 This is a standard priority issue

Comments

@steffakasid
Copy link

Describe the bug

I want to use the following config but it doesn't work with aws-sdk-go (even when it works fine with aws cli).

[default]
cli_pager=
output = json
region = eu-central-1
sso_session = mysession
sso_account_id = 12345

[profile iat]
cli_pager=
retry_mode = adaptive
max_attempts = 20
output = json
region = eu-central-1
sso_session = mysession
sso_account_id = 12345

[profile prod]
cli_pager=
retry_mode = adaptive
max_attempts = 20
output = jsonac
region = eu-central-1
sso_session = mysession
sso_account_id = 12345

# not used by gomplate, thefore we can't use it
[sso-session mysession]
sso_region = eu-central-1
sso_start_url = https://d-99671a01cd.awsapps.com/start
sso_role_name = ServiceTeamAdmin

I receive the following error:
code: InvalidRequestException, message: RoleName must be supplied in the queryString params, fault: client

Tested with:

  • eksctl (0.167.0-dev+4280da7cd.2023-12-22T09:42:18Z)
  • gomplate (4.0.0-pre-2)
  • awsclean (0.16)

Expected Behavior

aws-sdk-go should work with sso-session.

Current Behavior

I receive the following error:
code: InvalidRequestException, message: RoleName must be supplied in the queryString params, fault: client

Reproduction Steps

  • create a ~/.aws/config like described
  • do aws sso login
  • use aws-sdk-go to do aws stuff e.g. awsclean ami --dry-run --older-then 1d

Possible Solution

No response

Additional Information/Context

No response

SDK version used

v1.21.1

Environment details (Version of Go (go version)? OS name and version, etc.)

go version 1.19, uname -r 5.15.145-95.156.amzn2.x86_64

@RanVaknin
Copy link
Contributor

Hi @steffakasid ,

I know we did some work regarding sso session in #4917 #4885 #4875
I also see that you are using SDK version v1.21.1 that was released 5 years ago. Can you please update your SDK version and try again?

Thanks,
Ran~

@RanVaknin RanVaknin self-assigned this Mar 8, 2024
@RanVaknin RanVaknin added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. p2 This is a standard priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Mar 8, 2024
Copy link

This issue has not received a response in 1 week. If you want to keep this issue open, please just leave a comment below and auto-close will be canceled.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Mar 19, 2024
@steffakasid
Copy link
Author

I'll try to take a look today.

Regards
Steffeen

@github-actions github-actions bot removed closing-soon This issue will automatically close in 4 days unless further comments are made. response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. labels Mar 20, 2024
@lucix-aws lucix-aws added the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. label Mar 20, 2024
@steffakasid
Copy link
Author

HI,

I just had a look with github.com/aws/aws-sdk-go-v2 v1.25.2. It somehow seems to work but I get the following error: " message: RoleName must be supplied in the queryString params" is this an issue from my ~/.aws/config or from my code?

Regards
Steff

@Tiwat2540k
Copy link

@github-actions github-actions bot removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. label Mar 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. p2 This is a standard priority issue
Projects
None yet
Development

No branches or pull requests

4 participants