chore(crypto): update btcec to v2 (#13513)

Similar to Tendermint's PR,

https://github.com/tendermint/tendermint/pull/9250

Note that crypto/ledger is not updated in this PR, because if its
dependency on the R and S values being exposed by ParseDERSignature.

Updates #13423

Signed-off-by: Elias Naur <elias@orijtech.com>

Signed-off-by: Elias Naur <elias@orijtech.com>
Co-authored-by: Marko <marbar3778@yahoo.com>
This commit is contained in:
Elias Naur
2022-10-17 16:33:43 +02:00
committed by GitHub
co-authored by Marko
parent a34d5b213d
commit ed9cd41396
13 changed files with 75 additions and 51 deletions
+2 -2
View File
@@ -7,7 +7,7 @@ import (
"reflect"
"cosmossdk.io/math"
"github.com/btcsuite/btcd/btcec"
"github.com/btcsuite/btcd/btcec/v2"
rosettatypes "github.com/coinbase/rosetta-sdk-go/types"
abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/crypto"
@@ -649,7 +649,7 @@ func (c converter) PubKey(pubKey *rosettatypes.PublicKey) (cryptotypes.PubKey, e
return nil, crgerrs.WrapError(crgerrs.ErrUnsupportedCurve, "only secp256k1 supported")
}
cmp, err := btcec.ParsePubKey(pubKey.Bytes, btcec.S256())
cmp, err := btcec.ParsePubKey(pubKey.Bytes)
if err != nil {
return nil, crgerrs.WrapError(crgerrs.ErrBadArgument, err.Error())
}