Versions in this module Expand all Collapse all v1 v1.1.0 Jul 26, 2023 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)