-
Notifications
You must be signed in to change notification settings - Fork 124
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
[BUG] AwsSigv4Signer does not correctly read roles from profile #614
Comments
There's an IMPORTANT note from this article:
And the provided example also has explicit roleAssumer:
So, I don't think this is a bug on the client's Sigv4 Signer's end. It's just how |
Reading the article that you sent, I found another simple convenient and working solution:
This does seem to pick up everything I need. It's just a bit weird that all these providers work slightly different, but yeah, it does not look like an opensearch client signer bug. |
@nick-bir Care to add something to the documentation for the next person? Maybe into https://github.com/opensearch-project/opensearch-js/blob/main/USER_GUIDE.md#authenticate-with-amazon-opensearch-service? |
Reopen this issue to add this edge case to the doc. |
Added #622, please let me know if it looks good to you |
What is the bug?
I am using AwsSigv4Signer lib to sign requests to AWS OSS cluster. I have following setup in my .credentials file:
I am getting error
Profile default requires a role to be assumed, but no role assumption
when I'm trying to connect to OSS with following options:As a workaround I managed to explicitly pass role assumer to the options, but no other aws-sdk v3 or even v2 client requires that, so I assume this is a bug:
How can one reproduce the bug?
What is the expected behavior?
I expect that default role assumer should be used by opensearch client by default, if other assumer was not explicitly passed
What is your host/environment?
mac OS Ventura 13.5
npm 8.19.2
node v18.12.1
opensearch-client 2.3.1
The text was updated successfully, but these errors were encountered: