-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Unable to Authenticate using AWS metadata credentials #7397
Comments
Hi @awilkins-frel -- this change in behavior and how to handle it is described on the mailing list at https://groups.google.com/forum/#!msg/vault-tool/ki0GUEu7FFo/QBulNTDtBwAJ |
Thanks that is a great help. What I am a little unclear of is if there is a way to make this work entirely client side at the moment using the vault CLI and vault agent. |
You can simply set the |
Thanks, I can get it to work on the CLI with the parameter, and can now see that has been updated in the docs
adding I was able to get it to work using the environment variable you mentioned, but as it is running as a service I had to add it to systemd by adding I am still struggling slightly to get my head around the reason for this change. Is there a step I am missing that would allow the server to auto detect the region the client is in, or for the client to pass on the region it has used for it's part of the authentication process? |
As per the vault doc, they say if Commands for setting the sts region and endpoint
|
Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior:
On an aws instance not in region with an IAM role assigned
Error authenticating: Error making API request.
URL: PUT http://localhost:8200/v1/auth/aws/login
Code: 400. Errors:
Expected behavior
If everything else is in place - eg vault server has aws credentials, role exists in vault, iam role of instance configured for access to the role, login should succeed
Environment:
Vault server configuration file(s):
Additional context
A couple of intercepted packets between the cli and vault server seem to show what is going wrong here since 1.2.0
this is the iam_request_headers key base64 decoded
running it from cli version before 1.2.0 you see it look like this
In the older version the Credentials had the region of us-east-1 despite the instance being in eu-west-1
It looks to me like the sts end point needs these requests scoped to this region because that is the region it is in even if the instances are not.
The text was updated successfully, but these errors were encountered: