diff --git a/keyfile/keyfile.go b/keyfile/keyfile.go index e22be77c..70c54463 100644 --- a/keyfile/keyfile.go +++ b/keyfile/keyfile.go @@ -35,7 +35,7 @@ func CreateKeyFile(pass string) error { } // Derive pubkey - _, pub := btcec.PrivKeyFromBytes(btcec.S256(), priv32[:]) + _, pub := btcec.PrivKeyFromBytes(priv32[:]) salt := new([24]byte) // salt for scrypt / nonce for secretbox dk32 := new([32]byte) // derived key from scrypt @@ -131,6 +131,6 @@ func TestPassword(password string) bool { if err != nil { return false } - _, pub := btcec.PrivKeyFromBytes(btcec.S256(), priv) + _, pub := btcec.PrivKeyFromBytes(priv) return bytes.Equal(loadPublicKey(), pub.SerializeCompressed()) } diff --git a/wallet/signsend.go b/wallet/signsend.go index f1d81599..4fa70bb6 100644 --- a/wallet/signsend.go +++ b/wallet/signsend.go @@ -33,7 +33,7 @@ func (w *Wallet) SignMyInputs(tx *wire.MsgTx, password string) error { return err } - priv, _ := btcec.PrivKeyFromBytes(btcec.S256(), privBytes) + priv, _ := btcec.PrivKeyFromBytes(privBytes) for i := range tx.TxIn { sigStash[i], err = txscript.SignatureScript(tx, i, w.Script, txscript.SigHashAll, priv, true)