Documentation ¶
Index ¶
- Variables
- func EvaluatePoly(coefficient []*big.Int, x *big.Int) *big.Int
- func GetRandCoefficients(num int) ([]*big.Int, error)
- func Lagrange(f []*big.Int, x []*big.Int) *big.Int
- func RandFieldElement(c elliptic.Curve) (k *big.Int, err error)
- func SenderEcrecover(sighash, sig []byte) (common.Address, error)
- func TransSignature(R *big.Int, S *big.Int, V uint64) ([]byte, error)
- func UintRand(MaxValue uint64) (uint64, error)
- func ValidatePrivateKey(k *big.Int) bool
- func ValidatePublicKey(k *ecdsa.PublicKey) bool
Constants ¶
This section is empty.
Variables ¶
View Source
var (
Secp256k1N, _ = new(big.Int).SetString("fffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141", 16)
Secp256k1halfN = new(big.Int).Div(Secp256k1N, big.NewInt(2))
)
Functions ¶
func RandFieldElement ¶
randFieldElement returns a random element of the field underlying the given curve using the procedure given in [NSA] A.2.1.
func ValidatePrivateKey ¶
func ValidatePublicKey ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.