vault-action icon indicating copy to clipboard operation
vault-action copied to clipboard

Log error messages on authentication errors

Open Centzilius opened this issue 4 years ago • 3 comments

Since the got node-module throws an error on HTTP 400 we need to catch that to show the original error message from vault.

This should at least partly fix #273

Centzilius avatar Nov 12 '21 11:11 Centzilius

CLA assistant check
All committers have signed the CLA.

hashicorp-cla avatar Nov 12 '21 11:11 hashicorp-cla

Using this version of the action instead of the latest official one made me fix the error I've been struggling with for hours in 10 seconds. Thanks a lot! Better error messages are badly needed when debugging roles :)

I had a partly wrong repository name in bound_claims...

gazab avatar Dec 03 '21 15:12 gazab

Using this version of the action instead of the latest official one made me fix the error I've been struggling with for hours in 10 seconds. Thanks a lot! Better error messages are badly needed when debugging roles :)

I had a partly wrong repository name in bound_claims...

@gazab So you were able to track the error down and get it working? I've tried using this branch and I do see it reporting Error: Unable to retrieve token from jwt's login endpoint. rather than the generic HTTP 400 error but I'm not certain if the issue I'm dealing with is in the action config or the JWT config on Vault itself.

jbouse avatar Jan 05 '22 07:01 jbouse

Hi, @Centzilius. Thanks for this contribution! We're planning to take #409 at this point. Let me know your thoughts on this.

austingebauer avatar Jan 17 '23 16:01 austingebauer

As long as we get a solution merged for the problem its fine with me. It would've been great to have some feedback on why this PR was not taken into account in 2021 for the future.

Centzilius avatar Jan 17 '23 17:01 Centzilius

@Centzilius - Unfortunately, I'm looking at this repository with fresh eyes and don't have context as to why this wasn't taken in the past. I decided the other PR was favorable by looking at each side-by-side. The other PR avoids the need to enable debug logging and includes a more detailed error message. I'm happy to consider this PR in favor of the other if given reasons that this is better for users 🙂

austingebauer avatar Jan 17 '23 19:01 austingebauer

I'm going to close this since https://github.com/hashicorp/vault-action/pull/409 has been merged. Thanks again!

austingebauer avatar Jan 24 '23 00:01 austingebauer