diff options
author | Felix Lange <fjl@users.noreply.github.com> | 2017-02-18 16:24:12 +0800 |
---|---|---|
committer | Jeffrey Wilcke <jeffrey@ethereum.org> | 2017-02-18 16:24:12 +0800 |
commit | 9b0af513867fad4aeb3516e4711dd0ea4f5bc90c (patch) | |
tree | b37d808d57873c6aec550431534e26602dfd0475 /crypto/ecies/params.go | |
parent | bf21549faa7de6e2b920855468b14856c6f503c4 (diff) | |
download | go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar.gz go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar.bz2 go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar.lz go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar.xz go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.tar.zst go-tangerine-9b0af513867fad4aeb3516e4711dd0ea4f5bc90c.zip |
crypto: add btcec fallback for sign/recover without cgo (#3680)
* vendor: add github.com/btcsuite/btcd/btcec
* crypto: add btcec fallback for sign/recover without cgo
This commit adds a non-cgo fallback implementation of secp256k1
operations.
* crypto, core/vm: remove wrappers for sha256, ripemd160
Diffstat (limited to 'crypto/ecies/params.go')
-rw-r--r-- | crypto/ecies/params.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/ecies/params.go b/crypto/ecies/params.go index 511c53ebc..826d90c84 100644 --- a/crypto/ecies/params.go +++ b/crypto/ecies/params.go @@ -42,11 +42,11 @@ import ( "fmt" "hash" - "github.com/ethereum/go-ethereum/crypto/secp256k1" + ethcrypto "github.com/ethereum/go-ethereum/crypto" ) var ( - DefaultCurve = secp256k1.S256() + DefaultCurve = ethcrypto.S256() ErrUnsupportedECDHAlgorithm = fmt.Errorf("ecies: unsupported ECDH algorithm") ErrUnsupportedECIESParameters = fmt.Errorf("ecies: unsupported ECIES parameters") ) @@ -100,7 +100,7 @@ var ( ) var paramsFromCurve = map[elliptic.Curve]*ECIESParams{ - secp256k1.S256(): ECIES_AES128_SHA256, + ethcrypto.S256(): ECIES_AES128_SHA256, elliptic.P256(): ECIES_AES128_SHA256, elliptic.P384(): ECIES_AES256_SHA384, elliptic.P521(): ECIES_AES256_SHA512, |