[bls] Improve sanitization for bls key passphrase too

pull/223/head
Janet Liang 5 years ago
parent bafa409e03
commit 881b3ca520
  1. 1
      pkg/keys/bls.go

@ -208,6 +208,7 @@ func VerifyBLS(blsPubKey string, blsPubKeyDir string) (shard.BLSSignature, error
}
cleanPass := strings.TrimSpace(string(pass))
cleanPass = strings.ReplaceAll(cleanPass, "\t", "")
decryptedPrivateKeyBytes, err := decrypt(encryptedPrivateKeyBytes, cleanPass)
if err != nil {
return sig, err

Loading…
Cancel
Save