-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
aws/session: Add support for chaining source_profile with credential_source #2579
Conversation
Hi, Any update here? 🙂 |
Hi @janario thanks for the ping, this feature request is in our backlog to review. We'll prioritize reviewing this Pr and get feedback to you. |
source_profile
and support for credential_source
Refactors the Session credentials code to be in its own file and adds unit tests for chained assume role. Fixes the SDK's bug not correctly assuming role with "credentials_source" for Environment and ECS roles. Fix aws#2528 For testing support, added the ability to specify the Handlers the SDK should use at the Session Options. This allows the set of handlers to be injected from the very beginning of the sessions credential chain.
I've pushed an update to this PR that refactors the Session's credential logic into its own file, and adds a unit test for chained assume role. This update also adds support for |
@jasdel It seems that the CI test has failed. Is it possible to merge this PR in the near future? |
Adds PR #2579 to pending change log.
Thanks guys I'm looking forward for the release of it |
Relevant changes: * backend/s3: Support for chaining assume IAM role from AWS shared configuration files * backend/s3: Fix AWS shared configuration file credential source not assuming a role with environment and ECS credentials References: * https://github.com/aws/aws-sdk-go/releases/tag/v1.20.0 * aws/aws-sdk-go#2579 * aws/aws-sdk-go#2385 Updated via: ```console $ go get github.com/aws/[email protected] $ go mod tidy $ go mod vendor ```
…fig (aws#2579) Adds support chaining assume role credentials from the shared config/credentials files. This change allows you to create an assume role chain of multiple levels of assumed IAM roles. The config profile the deepest in the chain must use static credentials, or `credential_source`. If the deepest profile doesn't have either of these the session will fail to load. Fixes the SDK's shared config credential source not assuming a role with environment and ECS credentials. EC2 credentials were already supported. Fix aws#2528 Fix aws#2385 Also adds the ability to specify the Handlers the SDK should use at the SessionWithOptions. This allows the a set of handlers to be provided at the very beginning of the session credential chain.
Adds PR aws#2579 to pending change log.
We have a scenario where our the first access will assume one cross account role and after it assume roles for each operation
We tried with the aws cli and everything works fine, but we have some operations that will use the go-sdk (aws-iam-authenticator)
Our conf will be something like:
using the aws cli it works as expected
But when we trigger the
aws-iam-authenticator
This PR makes it possible to chain between multiple profiles and to use the
credential_source