mirror of
https://github.com/btcsuite/btcd.git
synced 2025-02-23 14:40:44 +01:00
Merge pull request #2022 from wydengyre/bip-340-signing
schnorr: bip-340 compliant signing
This commit is contained in:
commit
40d7a0a06c
1 changed files with 1 additions and 4 deletions
|
@ -174,10 +174,7 @@ func schnorrVerify(sig *Signature, hash []byte, pubKeyBytes []byte) error {
|
|||
)
|
||||
|
||||
var e btcec.ModNScalar
|
||||
if overflow := e.SetBytes((*[32]byte)(commitment)); overflow != 0 {
|
||||
str := "hash of (r || P || m) too big"
|
||||
return signatureError(ecdsa_schnorr.ErrSchnorrHashValue, str)
|
||||
}
|
||||
e.SetBytes((*[32]byte)(commitment))
|
||||
|
||||
// Negate e here so we can use AddNonConst below to subtract the s*G
|
||||
// point from e*P.
|
||||
|
|
Loading…
Add table
Reference in a new issue