aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/secp256k1
diff options
context:
space:
mode:
authorkiel barry <kiel.j.barry@gmail.com>2018-05-09 07:17:09 +0800
committerFelix Lange <fjl@users.noreply.github.com>2018-05-09 07:17:09 +0800
commitba975dc0931b9f2962b2f163675772458ed339fd (patch)
tree9e2e4d2265cfdad52289d15abcc9f2b56fcddebe /crypto/secp256k1
parenteab6e5a317acf67409f82bc5c1f4d959413dfd47 (diff)
downloadgo-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar.gz
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar.bz2
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar.lz
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar.xz
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.tar.zst
go-tangerine-ba975dc0931b9f2962b2f163675772458ed339fd.zip
crypto: fix golint warnings (#16710)
Diffstat (limited to 'crypto/secp256k1')
-rw-r--r--crypto/secp256k1/curve.go2
-rw-r--r--crypto/secp256k1/secp256_test.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/crypto/secp256k1/curve.go b/crypto/secp256k1/curve.go
index f51be5e35..6fdf2be6a 100644
--- a/crypto/secp256k1/curve.go
+++ b/crypto/secp256k1/curve.go
@@ -77,7 +77,7 @@ func (BitCurve *BitCurve) Params() *elliptic.CurveParams {
}
}
-// IsOnBitCurve returns true if the given (x,y) lies on the BitCurve.
+// IsOnCurve returns true if the given (x,y) lies on the BitCurve.
func (BitCurve *BitCurve) IsOnCurve(x, y *big.Int) bool {
// y² = x³ + b
y2 := new(big.Int).Mul(y, y) //y²
diff --git a/crypto/secp256k1/secp256_test.go b/crypto/secp256k1/secp256_test.go
index f6582ecd5..b608bcfcf 100644
--- a/crypto/secp256k1/secp256_test.go
+++ b/crypto/secp256k1/secp256_test.go
@@ -49,7 +49,7 @@ func randSig() []byte {
// tests for malleability
// highest bit of signature ECDSA s value must be 0, in the 33th byte
func compactSigCheck(t *testing.T, sig []byte) {
- var b int = int(sig[32])
+ var b = int(sig[32])
if b < 0 {
t.Errorf("highest bit is negative: %d", b)
}