-
Notifications
You must be signed in to change notification settings - Fork 56
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 use Recovery KMS HCL Provider Option #181
Comments
Sorry for the tardy response here @celestialorb - can you retry with the latest provider build? We've updated the go-kms lib within the provider. |
Went through the motions with the latest provider. Some progress has been made in that I can now get the provider to work with the Seems like it has issues if a profile is configured to obtain its credentials via AWS SSO. If I add a new profile on my machine with the access key, secret key, and session token explicitly defined the provider works but using a profile configured to use AWS SSO does not and fails with the same error message originally mentioned. Has this been tested with a profile the utilizes AWS SSO to obtain the credentials? |
Not that I'm aware of, the KMS recovery method uses our KMS wrapping library, which relies on the AWS SDK at the end of the day for credential chains. Reading the docs on AWS SSO, it sounds like you should be prompted for a browser to login through to get your credentials. Do you get that prompt? Can you share the error you receive? FYI @jimlambrt @jefferai Something we may want to look at upstream in the KMS wrapping library. |
The KMS wrapping library uses https://github.com/hashicorp/go-secure-stdlib/tree/main/awsutil for creds, it's not something in the wrapper itself. |
@malnick I should only be prompted when I perform an SSO login (
I am able to authenticate locally in my shell, which was verified by running
I have no other fields specified in the Boundary provider aside from This certainly feels like an issue in an upstream AWS SDK or the SDK version used is a bit old, either that or perhaps some sort of explicit configuration is being passed to the AWS SDK that effectively makes it skip the SSO option? |
Sorry for the very tardy response here but we have an update coming down to move us to v2 of AWS's SDK that may be relevant to this issue: hashicorp/go-secure-stdlib#83 |
Still broken sadly :(
|
Terraform Version
v1.1.5
Affected Resource(s)
Hashicorp Boundary Provider
Terraform Configuration Files
Debug Output
Error: error reading wrappers from "recovery_kms_hcl": Error configuring kms: error fetching AWS KMS wrapping key information: NoCredentialProviders: no valid providers in chain. Deprecated.
Expected Behavior
I would expect the recovery KMS to be able to determine my credentials as I'm using an AWS profile configured via AWS SSO. I have tried explicitly setting the profile in the
kms
stanza as well as explicitly setting an access key id and secret access key. All return the same error. Every set of credentials I've tried all have full admin access as well, though the error message suggests that it can't find the credentials rather than the credentials don't have the proper authorization to read AWS KMS.Actual Behavior
The error above always appears. Configuring credentials for the stanza doesn't seem to work.
Additional Information
Maybe #180 would help?
The text was updated successfully, but these errors were encountered: