From 23b4235213962a3b22af44c22eb6cea42b66c1e7 Mon Sep 17 00:00:00 2001 From: Firas Qutishat Date: Fri, 10 Feb 2023 11:31:41 -0500 Subject: [PATCH] fix: key alias Signed-off-by: Firas Qutishat --- pkg/aws/service.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/aws/service.go b/pkg/aws/service.go index 4977855..6210541 100644 --- a/pkg/aws/service.go +++ b/pkg/aws/service.go @@ -248,7 +248,7 @@ func (s *Service) Create(kt arieskms.KeyType) (string, interface{}, error) { aliasPrefix := s.options.KeyAliasPrefix() if strings.TrimSpace(aliasPrefix) != "" { - aliasName := fmt.Sprintf("alias/%s-%s", aliasPrefix, *result.KeyMetadata.KeyId) + aliasName := fmt.Sprintf("alias/%s_%s", aliasPrefix, *result.KeyMetadata.KeyId) _, err = s.client.CreateAlias(context.Background(), &kms.CreateAliasInput{AliasName: &aliasName, TargetKeyId: result.KeyMetadata.KeyId})