kms: KES client should return non-nil error when GenerateKey fails (#12290)

This commit fixes a bug in the KMS KES client integration.
The client should return a non-nil error when the key generation
fails.

Signed-off-by: Andreas Auernhammer <aead@mail.de>
This commit is contained in:
Andreas Auernhammer authored and GitHub committed 2021-05-13 09:11:10 -07:00
1 parent 5c0a7189c7
commit b989e5a514
1 file changed
+1 -1
+1 -1
View File
@@ -115,7 +115,7 @@ func (c *kesClient) GenerateKey(keyID string, ctx Context) (DEK, error) {
}
dek, err := c.client.GenerateKey(context.Background(), keyID, ctxBytes)
if err != nil {
return DEK{}, nil
return DEK{}, err
}
return DEK{
KeyID: keyID,