Versions in this module Expand all Collapse all v0 v0.0.42 Aug 12, 2021 Changes in this version + func EcRecover(hash, sig []byte) ([]byte, error) + func Keccak256(data ...[]byte) []byte + func NewPrivateKey(privateKeyBytes []byte) (*ecdsa.PrivateKey, error) + func NewPrivateKeyByHex(privateKeyHex string) (*ecdsa.PrivateKey, error) + func PersonalEcRecover(data []byte, sig []byte) (string, error) + func PersonalSign(message []byte, privateKey string) ([]byte, error) + func PersonalSignByPrivateKey(message []byte, privateKey *ecdsa.PrivateKey) ([]byte, error) + func PubKey2Address(p ecdsa.PublicKey) string + func PubKey2Bytes(pub *ecdsa.PublicKey) []byte + func SigToPub(hash, sig []byte) (*ecdsa.PublicKey, error) + func Sign(hash []byte, prv *ecdsa.PrivateKey) ([]byte, error)