insites-consulting / azure-key-vault

Allow secrets to be easily fetched from an Azure Key Vault from within a Laravel application
4 stars 10 forks source link

Fix handling of errors from Azure Key Vault API #13

Closed mrdth closed 1 year ago

mrdth commented 1 year ago

This PR replaces the usage of error.message with error_description in the error response handling in Vault.php to match the Azure Key Vault API response. It fixes the handling of errors when retrieving and setting secrets.

It also also updates the error message in the tests to use the example error response from the Azure documentation: https://learn.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow#error-response-1

fixes #12