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

Support authentication on global region for AWS IAM (close #758) #763

Closed

Conversation

Amuerte
Copy link

@Amuerte Amuerte commented Mar 4, 2023

This PR enables one to perform AWS IAM authentication when the Vault instance is configured on the Global STS endpoint (us-east-1) and the application is deployed on another region.

@pivotal-cla
Copy link

@Amuerte Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@pivotal-cla
Copy link

@Amuerte Thank you for signing the Contributor License Agreement!

@Amuerte Amuerte changed the title Support authentication on global region for AWS IAM Support authentication on global region for AWS IAM (close #758) Mar 4, 2023
@Amuerte
Copy link
Author

Amuerte commented Mar 4, 2023

Close #758

@Amuerte Amuerte force-pushed the feat/aws-iam-sign-global branch from 7e14733 to d78dd13 Compare March 9, 2023 11:02
Copy link
Member

@mp911de mp911de left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not quite sure this pull request makes sense as all we do is setting a Region

/**
* Build a new {@link AwsIamAuthenticationOptions} instance.
* @return a new {@link AwsIamAuthenticationOptions}.
*/
public AwsIamAuthenticationOptions build() {

Assert.state(this.credentialsProvider != null, "Credentials or CredentialProvider must not be null");
if (useGlobalEndpoint) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If using the global endpoint is merely a matter of providing the right Region, why don't you just call regionProvider(() -> Region.US_EAST_1)?

Copy link
Author

@Amuerte Amuerte Mar 17, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mmh good point you raised here 😅 . By looking more in details, we are blocked because we are using spring-cloud-vault-config to instantiate the AwsIamAuthentication, and it does not offer a way to configure the region.
I will create an issue and a PR there. Sorry for that.

@Amuerte Amuerte closed this Mar 17, 2023
@mp911de mp911de added the status: declined A suggestion or change that we don't feel we should currently apply label Mar 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: declined A suggestion or change that we don't feel we should currently apply
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants