Skip to content

Commit

Permalink
Do not allow empty password in step cert create ...
Browse files Browse the repository at this point in the history
- unless --no-password --insecure used
  • Loading branch information
dopey committed Nov 26, 2020
1 parent df41f64 commit 1e2fbb0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion command/certificate/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -714,7 +714,8 @@ func savePrivateKey(filename string, priv interface{}, insecure bool) error {
}

var pass []byte
pass, err := ui.PromptPassword("Please enter the password to encrypt the private key")
pass, err := ui.PromptPassword("Please enter the password to encrypt the private key",
ui.WithValidateNotEmpty())
if err != nil {
return errors.Wrap(err, "error reading password")
}
Expand Down

0 comments on commit 1e2fbb0

Please sign in to comment.