[S4734612] :- Custom IAM Auth Lib Implementation to support STS Regio… #197
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue #, if available:
Description of changes:
Currently AWS IAM Auth library doesn't support STS Regional based custom endpoints and it is taking always public endpoints. So this is difficulty to connect from External Non EC2 instance where it is using assume role credentials to communicate to public endpoints due to firewall / company internal policies. So this custom IAM Auth Lib Implementation help to support STS Regional based endpoints and credentials refresh by addition of below config in the sasl.jaas.config with custom STSAssumeRoleIAMClientCallbackHandler class in the callback handler
sasl.jaas.config = software.amazon.msk.auth.iam.IAMLoginModule required awsRoleArn='awsRoleArn' awsRoleSessionName='awsRoleSessionName' awsStsRegion='awsStsRegion' awsStsRegionalEndpoint='awsStsRegionalEndpoint';
sasl.login.callback.handler.class=software.amazon.msk.auth.iam.STSAssumeRoleIAMClientCallbackHandler
This is used during client authentication and reauthentication
sasl.client.callback.handler.class=software.amazon.msk.auth.iam.STSAssumeRoleIAMClientCallbackHandler
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.