ethereum

package
v0.0.0-...-8896b81 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildErc20Data

func BuildErc20Data(toAddress common.Address, amount *big.Int) []byte

func BuildErc721Data

func BuildErc721Data(fromAddress, toAddress common.Address, tokenId *big.Int) []byte

func CreateAddressFromPrivateKey

func CreateAddressFromPrivateKey(priKey *ecdsa.PrivateKey) (string, string, error)

func OfflineSignTx

func OfflineSignTx(txData *types.DynamicFeeTx, privateKey string, chainId *big.Int) (string, string, error)

func PublicKeyToAddress

func PublicKeyToAddress(publicKey string) (string, error)

Types

type EthAddress

type EthAddress struct {
	PrivateKey string `json:"private_key"`
	PublicKey  string `json:"public_key"`
	Address    string `json:"address"`
}

func CreateAddressByKeyPairs

func CreateAddressByKeyPairs() (*EthAddress, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL