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

kubesec doesn't show any errors when there is no default 'gcloud auth application-default login' #17

Open
ShyykoSerhiy opened this issue Nov 27, 2018 · 3 comments

Comments

@ShyykoSerhiy
Copy link
Contributor

Connected issue #14

@shyiko shyiko closed this as completed in 59b3ccd Dec 18, 2018
shyiko added a commit that referenced this issue Dec 18, 2018
fix: return err when loading of the key fails. Fixes #17.
@shyiko shyiko reopened this Dec 18, 2018
@shyiko
Copy link
Owner

shyiko commented Dec 18, 2018

@ShyykoSerhiy any chance you can attach sample output here?
60b9dc7 has an implication that user is now required to have access to all the keys (not just one of them) to get to the DEK. This needs to be fixed. Having the output of kubesec with and without --debug would really help here.

@shyiko shyiko changed the title Kubesec doesn't show any errors when there is no default 'gcloud auth application-default login' kubesec doesn't show any errors when there is no default 'gcloud auth application-default login' Dec 19, 2018
@toshitanian
Copy link

toshitanian commented Aug 29, 2020

Same here. It took several hours to find that I need to run gcloud auth application-default login to decrypt the secret.
kubesec decrypt xxx.yaml --debug just said that the file can't be decrypted.

Attempting to decrypt DEK with GCP KMS key projects/xxxx/locations/global/keyRings/xxx/cryptoKeys/xxx
Unable to decrypt Data Encryption Key (DEK)

@silviogutierrez
Copy link

@toshitanian : GOOGLE_APPLICATION_CREDENTIALS worked for me.

However, I mostly use the gcloud cli, so I'm used to using CLOUDSDK_AUTH_CREDENTIAL_FILE_OVERRIDE. I kept running into your issue.

Since kubesec uses an sdk, it won't actually respect CLOUDSDK_AUTH_CREDENTIAL_FILE_OVERRIDE. Setting GOOGLE_APPLICATION_CREDENTIALS worked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants