api

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: Apache-2.0 Imports: 34 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckTimeouts

func CheckTimeouts(logger zerolog.Logger, timeouts *rpc.HTTPTimeouts)

CheckTimeouts ensures that timeout values are meaningful

func NewHTTPServer

func NewHTTPServer(logger zerolog.Logger, timeouts rpc.HTTPTimeouts) *httpServer

func SupportedAPIs

func SupportedAPIs(blockChainAPI *BlockChainAPI, streamAPI *StreamAPI, pullAPI *PullAPI) []rpc.API

Types

type AccessListResult

type AccessListResult struct {
	Accesslist *types.AccessList `json:"accessList"`
	Error      string            `json:"error,omitempty"`
	GasUsed    hexutil.Uint64    `json:"gasUsed"`
}

AccessListResult returns an optional accesslist It's the result of the `debug_createAccessList` RPC call. It contains an error if the transaction itself failed.

type AccountResult

type AccountResult struct {
	Address      common.Address  `json:"address"`
	AccountProof []string        `json:"accountProof"`
	Balance      *hexutil.Big    `json:"balance"`
	CodeHash     common.Hash     `json:"codeHash"`
	Nonce        hexutil.Uint64  `json:"nonce"`
	StorageHash  common.Hash     `json:"storageHash"`
	StorageProof []StorageResult `json:"storageProof"`
}

AccountResult structs for GetProof

type Block

type Block struct {
	Number           hexutil.Uint64   `json:"number"`
	Hash             common.Hash      `json:"hash"`
	ParentHash       common.Hash      `json:"parentHash"`
	Nonce            types.BlockNonce `json:"nonce"`
	Sha3Uncles       common.Hash      `json:"sha3Uncles"`
	LogsBloom        hexutil.Bytes    `json:"logsBloom"`
	TransactionsRoot common.Hash      `json:"transactionsRoot"`
	StateRoot        common.Hash      `json:"stateRoot"`
	ReceiptsRoot     common.Hash      `json:"receiptsRoot"`
	Miner            common.Address   `json:"miner"`
	Difficulty       hexutil.Uint64   `json:"difficulty"`
	TotalDifficulty  hexutil.Uint64   `json:"totalDifficulty"`
	ExtraData        hexutil.Bytes    `json:"extraData"`
	Size             hexutil.Uint64   `json:"size"`
	GasLimit         hexutil.Uint64   `json:"gasLimit"`
	GasUsed          hexutil.Uint64   `json:"gasUsed"`
	Timestamp        hexutil.Uint64   `json:"timestamp"`
	Transactions     interface{}      `json:"transactions"`
	Uncles           []common.Hash    `json:"uncles"`
	MixHash          common.Hash      `json:"mixHash"`
}

type BlockChainAPI

type BlockChainAPI struct {
	// contains filtered or unexported fields
}

func NewBlockChainAPI

func NewBlockChainAPI(
	logger zerolog.Logger,
	config *config.Config,
	evm requester.Requester,
	blocks storage.BlockIndexer,
	transactions storage.TransactionIndexer,
	receipts storage.ReceiptIndexer,
	accounts storage.AccountIndexer,
	indexingResumedHeight uint64,
) *BlockChainAPI

func (*BlockChainAPI) Accounts

func (b *BlockChainAPI) Accounts() []common.Address

Accounts returns the collection of accounts this node manages.

func (*BlockChainAPI) BlockNumber

func (b *BlockChainAPI) BlockNumber() (hexutil.Uint64, error)

BlockNumber returns the block number of the chain head.

func (*BlockChainAPI) Call

func (b *BlockChainAPI) Call(
	ctx context.Context,
	args TransactionArgs,
	blockNumberOrHash *rpc.BlockNumberOrHash,
	overrides *StateOverride,
	blockOverrides *BlockOverrides,
) (hexutil.Bytes, error)

Call executes the given transaction on the state for the given block number. Additionally, the caller can specify a batch of contract for fields overriding. Note, this function doesn't make and changes in the state/blockchain and is useful to execute and retrieve values.

func (*BlockChainAPI) ChainId

func (b *BlockChainAPI) ChainId() *hexutil.Big

ChainId is the EIP-155 replay-protection chain id for the current Ethereum chain config.

Note, this method does not conform to EIP-695 because the configured chain ID is always returned, regardless of the current head block. We used to return an error when the chain wasn't synced up to a block where EIP-155 is enabled, but this behavior caused issues in CL clients.

func (*BlockChainAPI) Coinbase

func (b *BlockChainAPI) Coinbase() (common.Address, error)

Coinbase is the address that mining rewards will be sent to (alias for Etherbase).

func (*BlockChainAPI) CreateAccessList

func (b *BlockChainAPI) CreateAccessList(
	ctx context.Context,
	args TransactionArgs,
	blockNumberOrHash *rpc.BlockNumberOrHash,
) (*AccessListResult, error)

CreateAccessList creates an EIP-2930 type AccessList for the given transaction. Reexec and blockNumberOrHash can be specified to create the accessList on top of a certain state.

func (*BlockChainAPI) EstimateGas

func (b *BlockChainAPI) EstimateGas(
	ctx context.Context,
	args TransactionArgs,
	blockNumberOrHash *rpc.BlockNumberOrHash,
	overrides *StateOverride,
) (hexutil.Uint64, error)

EstimateGas returns the lowest possible gas limit that allows the transaction to run successfully at block `blockNrOrHash`, or the latest block if `blockNrOrHash` is unspecified. It returns error if the transaction would revert or if there are unexpected failures. The returned value is capped by both `args.Gas` (if non-nil & non-zero) and the backend's RPCGasCap configuration (if non-zero).

func (*BlockChainAPI) FeeHistory

func (b *BlockChainAPI) FeeHistory(
	ctx context.Context,
	blockCount math.HexOrDecimal64,
	lastBlock rpc.BlockNumber,
	rewardPercentiles []float64,
) (*FeeHistoryResult, error)

FeeHistory returns transaction base fee per gas and effective priority fee per gas for the requested/supported block range. blockCount: Requested range of blocks. Clients will return less than the requested range if not all blocks are available. lastBlock: Highest block of the requested range. rewardPercentiles: A monotonically increasing list of percentile values. For each block in the requested range, the transactions will be sorted in ascending order by effective tip per gas and the coresponding effective tip for the percentile will be determined, accounting for gas consumed.

func (*BlockChainAPI) GasPrice

func (b *BlockChainAPI) GasPrice(ctx context.Context) (*hexutil.Big, error)

GasPrice returns a suggestion for a gas price for legacy transactions.

func (*BlockChainAPI) GetBalance

func (b *BlockChainAPI) GetBalance(
	ctx context.Context,
	address common.Address,
	blockNumberOrHash *rpc.BlockNumberOrHash,
) (*hexutil.Big, error)

GetBalance returns the amount of wei for the given address in the state of the given block number. The rpc.LatestBlockNumber and rpc.PendingBlockNumber meta block numbers are also allowed.

func (*BlockChainAPI) GetBlockByHash

func (b *BlockChainAPI) GetBlockByHash(
	ctx context.Context,
	hash common.Hash,
	fullTx bool,
) (*Block, error)

GetBlockByHash returns the requested block. When fullTx is true all transactions in the block are returned in full detail, otherwise only the transaction hash is returned.

func (*BlockChainAPI) GetBlockByNumber

func (b *BlockChainAPI) GetBlockByNumber(
	ctx context.Context,
	blockNumber rpc.BlockNumber,
	fullTx bool,
) (*Block, error)

GetBlockByNumber returns the requested canonical block.

  • When blockNr is -1 the chain pending block is returned.
  • When blockNr is -2 the chain latest block is returned.
  • When blockNr is -3 the chain finalized block is returned.
  • When blockNr is -4 the chain safe block is returned.
  • When fullTx is true all transactions in the block are returned, otherwise only the transaction hash is returned.

func (*BlockChainAPI) GetBlockReceipts

func (b *BlockChainAPI) GetBlockReceipts(
	ctx context.Context,
	numHash rpc.BlockNumberOrHash,
) ([]*types.Receipt, error)

GetBlockReceipts returns the block receipts for the given block hash or number or tag.

func (*BlockChainAPI) GetBlockTransactionCountByHash

func (b *BlockChainAPI) GetBlockTransactionCountByHash(
	ctx context.Context,
	blockHash common.Hash,
) (*hexutil.Uint, error)

GetBlockTransactionCountByHash returns the number of transactions in the block with the given hash.

func (*BlockChainAPI) GetBlockTransactionCountByNumber

func (b *BlockChainAPI) GetBlockTransactionCountByNumber(
	ctx context.Context,
	blockNumber rpc.BlockNumber,
) (*hexutil.Uint, error)

GetBlockTransactionCountByNumber returns the number of transactions in the block with the given block number.

func (*BlockChainAPI) GetCode

func (b *BlockChainAPI) GetCode(
	ctx context.Context,
	address common.Address,
	blockNumberOrHash *rpc.BlockNumberOrHash,
) (hexutil.Bytes, error)

GetCode returns the code stored at the given address in the state for the given block number.

func (*BlockChainAPI) GetLogs

func (b *BlockChainAPI) GetLogs(
	ctx context.Context,
	criteria filters.FilterCriteria,
) ([]*types.Log, error)

GetLogs returns logs matching the given argument that are stored within the state.

func (*BlockChainAPI) GetProof

func (b *BlockChainAPI) GetProof(
	ctx context.Context,
	address common.Address,
	storageKeys []string,
	blockNumberOrHash rpc.BlockNumberOrHash,
) (*AccountResult, error)

GetProof returns the Merkle-proof for a given account and optionally some storage keys.

func (*BlockChainAPI) GetStorageAt

func (b *BlockChainAPI) GetStorageAt(
	ctx context.Context,
	address common.Address,
	storageSlot string,
	blockNumberOrHash *rpc.BlockNumberOrHash,
) (hexutil.Bytes, error)

GetStorageAt returns the storage from the state at the given address, key and block number. The rpc.LatestBlockNumber and rpc.PendingBlockNumber meta block numbers are also allowed.

func (*BlockChainAPI) GetTransactionByBlockHashAndIndex

func (b *BlockChainAPI) GetTransactionByBlockHashAndIndex(
	ctx context.Context,
	blockHash common.Hash,
	index hexutil.Uint,
) (*Transaction, error)

GetTransactionByBlockHashAndIndex returns the transaction for the given block hash and index.

func (*BlockChainAPI) GetTransactionByBlockNumberAndIndex

func (b *BlockChainAPI) GetTransactionByBlockNumberAndIndex(
	ctx context.Context,
	blockNumber rpc.BlockNumber,
	index hexutil.Uint,
) (*Transaction, error)

GetTransactionByBlockNumberAndIndex returns the transaction for the given block number and index.

func (*BlockChainAPI) GetTransactionByHash

func (b *BlockChainAPI) GetTransactionByHash(
	ctx context.Context,
	hash common.Hash,
) (*Transaction, error)

GetTransactionByHash returns the transaction for the given hash

func (*BlockChainAPI) GetTransactionCount

func (b *BlockChainAPI) GetTransactionCount(
	ctx context.Context,
	address common.Address,
	blockNumberOrHash *rpc.BlockNumberOrHash,
) (*hexutil.Uint64, error)

GetTransactionCount returns the number of transactions the given address has sent for the given block number.

func (*BlockChainAPI) GetTransactionReceipt

func (b *BlockChainAPI) GetTransactionReceipt(
	ctx context.Context,
	hash common.Hash,
) (map[string]interface{}, error)

GetTransactionReceipt returns the transaction receipt for the given transaction hash.

func (*BlockChainAPI) GetUncleByBlockHashAndIndex

func (b *BlockChainAPI) GetUncleByBlockHashAndIndex(
	ctx context.Context,
	blockHash common.Hash,
	index hexutil.Uint,
) (map[string]interface{}, error)

GetUncleByBlockHashAndIndex returns the uncle block for the given block hash and index.

func (*BlockChainAPI) GetUncleByBlockNumberAndIndex

func (b *BlockChainAPI) GetUncleByBlockNumberAndIndex(
	ctx context.Context,
	blockNumber rpc.BlockNumber,
	index hexutil.Uint,
) (map[string]interface{}, error)

GetUncleByBlockNumberAndIndex returns the uncle block for the given block hash and index.

func (*BlockChainAPI) GetUncleCountByBlockHash

func (b *BlockChainAPI) GetUncleCountByBlockHash(
	ctx context.Context,
	blockHash common.Hash,
) *hexutil.Uint

GetUncleCountByBlockHash returns number of uncles in the block for the given block hash

func (*BlockChainAPI) GetUncleCountByBlockNumber

func (b *BlockChainAPI) GetUncleCountByBlockNumber(
	ctx context.Context,
	blockNumber rpc.BlockNumber,
) *hexutil.Uint

GetUncleCountByBlockNumber returns number of uncles in the block for the given block number

func (*BlockChainAPI) Hashrate added in v0.5.0

func (b *BlockChainAPI) Hashrate() hexutil.Uint64

Hashrate returns the number of hashes per second that the node is mining with. This can only return true for proof-of-work networks and may not be available in some clients since The Merge.

func (*BlockChainAPI) MaxPriorityFeePerGas

func (b *BlockChainAPI) MaxPriorityFeePerGas(ctx context.Context) (*hexutil.Big, error)

MaxPriorityFeePerGas returns a suggestion for a gas tip cap for dynamic fee transactions.

func (*BlockChainAPI) Mining added in v0.5.0

func (b *BlockChainAPI) Mining() bool

Mining returns true if client is actively mining new blocks. This can only return true for proof-of-work networks and may not be available in some clients since The Merge.

func (*BlockChainAPI) SendRawTransaction

func (b *BlockChainAPI) SendRawTransaction(
	ctx context.Context,
	input hexutil.Bytes,
) (common.Hash, error)

SendRawTransaction will add the signed transaction to the transaction pool. The sender is responsible for signing the transaction and using the correct nonce.

func (*BlockChainAPI) SendTransaction

func (b *BlockChainAPI) SendTransaction(
	ctx context.Context,
	args TransactionArgs,
) (common.Hash, error)

SendTransaction creates a transaction for the given argument, sign it and submit it to the transaction pool.

func (*BlockChainAPI) Sign

func (b *BlockChainAPI) Sign(
	addr common.Address,
	data hexutil.Bytes,
) (hexutil.Bytes, error)

Sign calculates an ECDSA signature for: keccak256("\x19Ethereum Signed Message:\n" + len(message) + message).

Note, the produced signature conforms to the secp256k1 curve R, S and V values, where the V value will be 27 or 28 for legacy reasons.

The account associated with addr must be unlocked.

https://github.com/ethereum/wiki/wiki/JSON-RPC#eth_sign

func (*BlockChainAPI) SignTransaction

func (b *BlockChainAPI) SignTransaction(
	ctx context.Context,
	args TransactionArgs,
) (*SignTransactionResult, error)

SignTransaction will sign the given transaction with the from account. The node needs to have the private key of the account corresponding with the given from address and it needs to be unlocked.

func (*BlockChainAPI) Syncing

func (b *BlockChainAPI) Syncing() (interface{}, error)

Syncing returns false in case the node is currently not syncing with the network. It can be up-to-date or has not yet received the latest block headers from its peers. In case it is synchronizing: - startingBlock: block number this node started to synchronize from - currentBlock: block number this node is currently importing - highestBlock: block number of the highest block header this node has received from peers

type BlockOverrides

type BlockOverrides struct {
	Number      *hexutil.Big
	Difficulty  *hexutil.Big
	Time        *hexutil.Uint64
	GasLimit    *hexutil.Uint64
	Coinbase    *common.Address
	Random      *common.Hash
	BaseFee     *hexutil.Big
	BlobBaseFee *hexutil.Big
}

BlockOverrides is a set of header fields to override.

type FeeHistoryResult

type FeeHistoryResult struct {
	OldestBlock  *hexutil.Big     `json:"oldestBlock"`
	Reward       [][]*hexutil.Big `json:"reward,omitempty"`
	BaseFee      []*hexutil.Big   `json:"baseFeePerGas,omitempty"`
	GasUsedRatio []float64        `json:"gasUsedRatio"`
}

type NetAPI

type NetAPI struct{}

NetAPI offers network related RPC methods

func (*NetAPI) Listening

func (s *NetAPI) Listening() bool

Listening returns an indication if the node is listening for network connections.

func (*NetAPI) PeerCount

func (s *NetAPI) PeerCount() hexutil.Uint

PeerCount returns the number of connected peers

func (*NetAPI) Version

func (s *NetAPI) Version() string

Version returns the current ethereum protocol version.

type OverrideAccount

type OverrideAccount struct {
	Nonce     *hexutil.Uint64              `json:"nonce"`
	Code      *hexutil.Bytes               `json:"code"`
	Balance   **hexutil.Big                `json:"balance"`
	State     *map[common.Hash]common.Hash `json:"state"`
	StateDiff *map[common.Hash]common.Hash `json:"stateDiff"`
}

OverrideAccount indicates the overriding fields of account during the execution of a message call. Note, state and stateDiff can't be specified at the same time. If state is set, message execution will only use the data in the given state. Otherwise if statDiff is set, all diff will be applied first and then execute the call message.

type PullAPI added in v0.4.0

type PullAPI struct {
	// contains filtered or unexported fields
}

func NewPullAPI added in v0.4.0

func NewPullAPI(
	logger zerolog.Logger,
	config *config.Config,
	blocks storage.BlockIndexer,
	transactions storage.TransactionIndexer,
	receipts storage.ReceiptIndexer,
) *PullAPI

func (*PullAPI) GetFilterChanges added in v0.4.0

func (api *PullAPI) GetFilterChanges(id rpc.ID) (any, error)

GetFilterChanges returns the logs for the filter with the given id since last time it was called. This can be used for polling.

For pending transaction and block filters the result is []common.Hash. (pending)Log filters return []Log.

func (*PullAPI) GetFilterLogs added in v0.4.0

func (api *PullAPI) GetFilterLogs(
	ctx context.Context,
	id rpc.ID,
) ([]*gethTypes.Log, error)

GetFilterLogs returns the logs for the filter with the given id. If the filter could not be found, `nil` is returned.

func (*PullAPI) NewBlockFilter added in v0.4.0

func (api *PullAPI) NewBlockFilter() (rpc.ID, error)

NewBlockFilter creates a filter that fetches blocks that are imported into the chain. It is part of the filter package since polling goes with eth_getFilterChanges.

func (*PullAPI) NewFilter added in v0.4.0

func (api *PullAPI) NewFilter(criteria filters.FilterCriteria) (rpc.ID, error)

NewFilter creates a new filter and returns the filter id. It can be used to retrieve logs when the state changes. This method cannot be used to fetch logs that are already stored in the state.

Default criteria for the from and to block are "latest". Using "latest" as block number will return logs for mined blocks. Using "pending" as block number returns logs for not yet mined (pending) blocks. In case logs are removed (chain reorg) previously returned logs are returned again but with the removed property set to true.

In case "fromBlock" > "toBlock" an error is returned.

func (*PullAPI) NewPendingTransactionFilter added in v0.4.0

func (api *PullAPI) NewPendingTransactionFilter(fullTx *bool) (rpc.ID, error)

NewPendingTransactionFilter creates a filter that fetches pending transactions as transactions enter the pending state.

It is part of the filter package because this filter can be used through the `eth_getFilterChanges` polling method that is also used for log filters.

func (*PullAPI) UninstallFilter added in v0.4.0

func (api *PullAPI) UninstallFilter(id rpc.ID) bool

type SignTransactionResult

type SignTransactionResult struct {
	Raw hexutil.Bytes      `json:"raw"`
	Tx  *types.Transaction `json:"tx"`
}

SignTransactionResult represents a RLP encoded signed transaction.

type StateOverride

type StateOverride map[common.Address]OverrideAccount

StateOverride is the collection of overridden accounts.

type StorageResult

type StorageResult struct {
	Key   string       `json:"key"`
	Value *hexutil.Big `json:"value"`
	Proof []string     `json:"proof"`
}

type StreamAPI added in v0.6.0

type StreamAPI struct {
	// contains filtered or unexported fields
}

func NewStreamAPI added in v0.6.0

func NewStreamAPI(
	logger zerolog.Logger,
	config *config.Config,
	blocks storage.BlockIndexer,
	transactions storage.TransactionIndexer,
	receipts storage.ReceiptIndexer,
	blocksBroadcaster *engine.Broadcaster,
	transactionsBroadcaster *engine.Broadcaster,
	logsBroadcaster *engine.Broadcaster,
) *StreamAPI

func (*StreamAPI) Logs added in v0.6.0

func (s *StreamAPI) Logs(ctx context.Context, criteria filters.FilterCriteria) (*rpc.Subscription, error)

Logs creates a subscription that fires for all new log that match the given filter criteria.

func (*StreamAPI) NewHeads added in v0.6.0

func (s *StreamAPI) NewHeads(ctx context.Context) (*rpc.Subscription, error)

NewHeads send a notification each time a new block is appended to the chain.

func (*StreamAPI) NewPendingTransactions added in v0.6.0

func (s *StreamAPI) NewPendingTransactions(ctx context.Context, fullTx *bool) (*rpc.Subscription, error)

NewPendingTransactions creates a subscription that is triggered each time a transaction enters the transaction pool. If fullTx is true the full tx is sent to the client, otherwise the hash is sent.

type SyncStatus added in v0.6.0

type SyncStatus struct {
	StartingBlock hexutil.Uint64 `json:"startingBlock"`
	CurrentBlock  hexutil.Uint64 `json:"currentBlock"`
	HighestBlock  hexutil.Uint64 `json:"highestBlock"`
}

type Transaction added in v0.6.0

type Transaction struct {
	BlockHash           *common.Hash             `json:"blockHash"`
	BlockNumber         *hexutil.Big             `json:"blockNumber"`
	From                common.MixedcaseAddress  `json:"from"`
	Gas                 hexutil.Uint64           `json:"gas"`
	GasPrice            *hexutil.Big             `json:"gasPrice"`
	GasFeeCap           *hexutil.Big             `json:"maxFeePerGas,omitempty"`
	GasTipCap           *hexutil.Big             `json:"maxPriorityFeePerGas,omitempty"`
	MaxFeePerBlobGas    *hexutil.Big             `json:"maxFeePerBlobGas,omitempty"`
	Hash                common.Hash              `json:"hash"`
	Input               hexutil.Bytes            `json:"input"`
	Nonce               hexutil.Uint64           `json:"nonce"`
	To                  *common.MixedcaseAddress `json:"to"`
	TransactionIndex    *hexutil.Uint64          `json:"transactionIndex"`
	Value               *hexutil.Big             `json:"value"`
	Type                hexutil.Uint64           `json:"type"`
	Accesses            *types.AccessList        `json:"accessList,omitempty"`
	ChainID             *hexutil.Big             `json:"chainId,omitempty"`
	BlobVersionedHashes []common.Hash            `json:"blobVersionedHashes,omitempty"`
	V                   *hexutil.Big             `json:"v"`
	R                   *hexutil.Big             `json:"r"`
	S                   *hexutil.Big             `json:"s"`
	YParity             *hexutil.Uint64          `json:"yParity,omitempty"`
}

Transaction represents a transaction that will serialize to the RPC representation of a transaction

func NewTransaction added in v0.6.0

func NewTransaction(tx models.Transaction, receipt types.Receipt) (*Transaction, error)

type TransactionArgs

type TransactionArgs struct {
	From                 *common.Address `json:"from"`
	To                   *common.Address `json:"to"`
	Gas                  *hexutil.Uint64 `json:"gas"`
	GasPrice             *hexutil.Big    `json:"gasPrice"`
	MaxFeePerGas         *hexutil.Big    `json:"maxFeePerGas"`
	MaxPriorityFeePerGas *hexutil.Big    `json:"maxPriorityFeePerGas"`
	Value                *hexutil.Big    `json:"value"`
	Nonce                *hexutil.Uint64 `json:"nonce"`

	// We accept "data" and "input" for backwards-compatibility reasons.
	// "input" is the newer name and should be preferred by clients.
	// Issue detail: https://github.com/ethereum/go-ethereum/issues/15628
	Data  *hexutil.Bytes `json:"data"`
	Input *hexutil.Bytes `json:"input"`

	// Introduced by AccessListTxType transaction.
	AccessList *types.AccessList `json:"accessList,omitempty"`
	ChainID    *hexutil.Big      `json:"chainId,omitempty"`
}

TransactionArgs represents the arguments to construct a new transaction or a message call.

type Web3API

type Web3API struct{}

Web3API offers helper utils

func (*Web3API) ClientVersion

func (s *Web3API) ClientVersion() string

ClientVersion returns the node name

func (*Web3API) Sha3

func (s *Web3API) Sha3(input hexutil.Bytes) hexutil.Bytes

Sha3 applies the ethereum sha3 implementation on the input. It assumes the input is hex encoded.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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