Versions in this module Expand all Collapse all v1 v1.0.2 Dec 20, 2016 Changes in this version + var ErrInvalidMsgLen = errors.New("invalid message length for signature recovery") + var ErrInvalidRecoveryID = errors.New("invalid signature recovery id") + var ErrInvalidSignatureLen = errors.New("invalid signature length") + var HalfN *big.Int + var N *big.Int + func GenerateKeyPair() ([]byte, []byte) + func GeneratePubKey(seckey []byte) ([]byte, error) + func RecoverPubkey(msg []byte, sig []byte) ([]byte, error) + func Sign(msg []byte, seckey []byte) ([]byte, error) + func VerifySeckeyValidity(seckey []byte) error + 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) GenerateKey(rand io.Reader) (priv []byte, x, y *big.Int, err error) + 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)