Skip to content

Commit 8df2476

Browse files
authored
Merge pull request #14553 from karalabe/puppeth-key-check
cmd/puppeth: fix improper key validation for remotes
2 parents 71814bf + ec17006 commit 8df2476

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

cmd/puppeth/module_node.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ func deployNode(client *sshClient, network string, bootv4, bootv5 []string, conf
135135
}
136136
defer client.Run("rm -rf " + workdir)
137137

138-
// Build and deploy the bootnode service
138+
// Build and deploy the boot or seal node service
139139
return nil, client.Stream(fmt.Sprintf("cd %s && docker-compose -p %s up -d --build", workdir, network))
140140
}
141141

cmd/puppeth/wizard_node.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,7 @@ func (w *wizard) deployNode(boot bool) {
109109
} else if w.conf.genesis.Config.Clique != nil {
110110
// If a previous signer was already set, offer to reuse it
111111
if infos.keyJSON != "" {
112-
var key keystore.Key
113-
if err := json.Unmarshal([]byte(infos.keyJSON), &key); err != nil {
112+
if key, err := keystore.DecryptKey([]byte(infos.keyJSON), infos.keyPass); err != nil {
114113
infos.keyJSON, infos.keyPass = "", ""
115114
} else {
116115
fmt.Println()

0 commit comments

Comments
 (0)