Versions in this module Expand all Collapse all v1 v1.1.0 Oct 24, 2023 Changes in this version type Address + func StringToAddress(s string) *Address v1.0.0 Oct 17, 2023 Changes in this version + func DecodeFromBytes[T any](in []byte) (*T, error) + func EncodeToBytes(p interface{}) []byte + func HexToPrivateKey(hexStr string) *ecdsa.PrivateKey + type Address [addressLength]byte + func BytesToAddress(b []byte) *Address + func PublicKeyToAddress(pubkey *ecdsa.PublicKey) *Address + func (a Address) Bytes() []byte + func (a Address) String() string + type CompactPublicKey struct + CurveParams *elliptic.CurveParams + X *big.Int + Y *big.Int + func PublicKeyToCompact(pubkey *ecdsa.PublicKey) *CompactPublicKey + func (cpk *CompactPublicKey) PublicKey() *ecdsa.PublicKey + type Hash [hashLength]byte + func ByteToHash(b []byte) *Hash + func HashData(b []byte) *Hash + func (h Hash) Bytes() []byte + func (h Hash) String() string + type UnlockedAccount struct + func NewUnlockedAccount(privateKey *ecdsa.PrivateKey) *UnlockedAccount + func (ua *UnlockedAccount) Address() *Address + func (ua *UnlockedAccount) PublicKey() *ecdsa.PublicKey + func (ua *UnlockedAccount) Sign(data []byte) (*big.Int, *big.Int, error) + func (ua *UnlockedAccount) Verify(data []byte, r *big.Int, s *big.Int) bool