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

Extra spaces around equals sign breaks shared credentials file #2281

Closed
cullenmcdermott opened this issue Nov 16, 2018 · 2 comments
Closed
Labels
bug This issue is a bug. investigating This issue is being investigated and/or work is in progress to resolve the issue.

Comments

@cullenmcdermott
Copy link

cullenmcdermott commented Nov 16, 2018

Please fill out the sections below to help us address your issue.

Version of AWS SDK for Go?

1.15.74 (I think)

What issue did you see?

Over in hashicorp/terraform-provider-aws#6462 an issue is being discussed where the shared credentials file is not being read as a valid source for credentials. This appears to be caused by tools that 'pretty print' credentials into the file with extra padding around the =.

Steps to reproduce

A file formatted like this will fail

[saml]
aws_access_key_id        = <access key id>
aws_secret_access_key    = <secret access key>
aws_session_token        = <session token>
aws_security_token       = <security token>
x_principal_arn          = arn:aws:sts::<myarn>
x_security_token_expires = <datetime>

Removing the extra spaces will fix it

[saml]
aws_access_key_id = <access key id>
aws_secret_access_key = <secret access key>
aws_session_token = <session token>
aws_security_token = <security token>
x_principal_arn = arn:aws:sts::<myarn>
x_security_token_expires = <datetime>

This comment addresses the issue: hashicorp/terraform-provider-aws#6462 (comment)

@jasdel jasdel added bug This issue is a bug. investigating This issue is being investigated and/or work is in progress to resolve the issue. labels Nov 16, 2018
@xibz
Copy link
Contributor

xibz commented Nov 16, 2018

Hello @cullenmcdermott, thank you for reaching out to us and reporting this. I've went ahead and created a PR, #2282, that fixes this issue. Please let us know if you have any additional question or issues.

@cullenmcdermott
Copy link
Author

That was so fast! Thanks!

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. investigating This issue is being investigated and/or work is in progress to resolve the issue.
Projects
None yet
Development

No branches or pull requests

3 participants