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

Adding Support for Temporary Credentials (Session Token) in credentials_file_provider() #280

Closed
CurryEleison opened this issue Apr 17, 2020 · 6 comments
Assignees
Labels
bug 🐞 Something isn't working

Comments

@CurryEleison
Copy link

CurryEleison commented Apr 17, 2020

Paws supports temporary AWS credentials with session tokens except in the case where credentials are provided in a credentials file. Unfortunately for me, that's where my session token is stored :)

I think it would be an easy improvement. In the credentials_file_provider() method of credential_providers.R we just need to read out the session token with

session_token <- credentials[[aws_profile]]$aws_session_token

and pass the result to creds().

For context, the case where session token is stored in the environment was improved in #185, and there's an excellent workaround in #210 , so this is clearly not a high priority -- it would just make authentication a little more consistent.

@adambanker
Copy link
Member

Thank you for submitting the issue! This looks like an oversight on our part, but your proposed fix looks like it should solve the issue. I can implement the fix and put it in the next Paws update unless you would prefer to submit your own pull request.

@CurryEleison
Copy link
Author

Thanks! It's probably going to be faster/better if you implement it :)

@adambanker
Copy link
Member

Hello, the fix is now available on GitHub. You can get the fixed version by running devtools::install_github("paws-r/paws/paws.common"). It will be available on CRAN in the next release, but you may have to wait a few weeks for that since there is a limit to how often they accept updates.

@CurryEleison
Copy link
Author

That seems to work perfectly! I did some manual testing in various scenarios and everything worked as expected. Thanks!

@davidkretch
Copy link
Member

Hello, this bug fix is now in the version on CRAN. Let us know if we can close this issue.

Thank you!

@CurryEleison
Copy link
Author

Just did some manual tests on this from CRAN and it works perfectly 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐞 Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants