Versions in this module Expand all Collapse all v1 v1.8.13 Apr 15, 2022 v1.8.12 Apr 15, 2022 Changes in this version + var ErrInvalidKey = errors.New("invalid private key") + var ErrInvalidMsgLen = errors.New("invalid message length, need 32 bytes") + var ErrInvalidPubkey = errors.New("invalid public key") + var ErrInvalidRecoveryID = errors.New("invalid signature recovery id") + var ErrInvalidSignatureLen = errors.New("invalid signature length") + var ErrRecoverFailed = errors.New("recovery failed") + var ErrSignFailed = errors.New("signing failed") + func CompressPubkey(x, y *big.Int) []byte + func DecompressPubkey(pubkey []byte) (x, y *big.Int) + func RecoverPubkey(msg []byte, sig []byte) ([]byte, error) + func Sign(msg []byte, seckey []byte) ([]byte, error) + func VerifySignature(pubkey, msg, signature []byte) bool + type BitCurve struct + B *big.Int + BitSize int + Gx *big.Int + Gy *big.Int + N *big.Int + P *big.Int + func S256() *BitCurve + func (BitCurve *BitCurve) Add(x1, y1, x2, y2 *big.Int) (*big.Int, *big.Int) + func (BitCurve *BitCurve) Double(x1, y1 *big.Int) (*big.Int, *big.Int) + func (BitCurve *BitCurve) IsOnCurve(x, y *big.Int) bool + func (BitCurve *BitCurve) Marshal(x, y *big.Int) []byte + func (BitCurve *BitCurve) Params() *elliptic.CurveParams + func (BitCurve *BitCurve) ScalarBaseMult(k []byte) (*big.Int, *big.Int) + func (BitCurve *BitCurve) ScalarMult(Bx, By *big.Int, scalar []byte) (*big.Int, *big.Int) + func (BitCurve *BitCurve) Unmarshal(data []byte) (x, y *big.Int)