From 78fd3cab545b0160bdfee11fd44c4b44d0d53103 Mon Sep 17 00:00:00 2001 From: miampf Date: Thu, 9 Jan 2025 11:52:54 +0100 Subject: [PATCH] use existing `MasterSecret` type --- cli/internal/cmd/ssh.go | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/cli/internal/cmd/ssh.go b/cli/internal/cmd/ssh.go index e2a4ef4b3f..c5085047e4 100644 --- a/cli/internal/cmd/ssh.go +++ b/cli/internal/cmd/ssh.go @@ -24,11 +24,6 @@ import ( "golang.org/x/crypto/ssh" ) -type secret struct { - Key []byte `json:"key,omitempty"` - Salt []byte `json:"salt,omitempty"` -} - var permissions = ssh.Permissions{ Extensions: map[string]string{ "permit-port-forwarding": "yes", @@ -58,7 +53,7 @@ func runSSH(cmd *cobra.Command, _ []string) error { } // NOTE(miampf): Since other KMS aren't fully implemented yet, this commands assumes that the cKMS is used and derives the key accordingly. - var mastersecret secret + var mastersecret uri.MasterSecret if err = fh.ReadJSON(fmt.Sprintf("%s.json", constants.ConstellationMasterSecretStoreName), &mastersecret); err != nil { return fmt.Errorf("Failed to read constellation master secret: %s", err) }