EIP1559Signer

Git Source

Functions

encodeUnsignedTx

Encode an unsigned EIP-1559 transaction for signing

function encodeUnsignedTx(EIP1559Tx memory rawTx) internal pure returns (bytes memory);

Parameters

NameTypeDescription
rawTxEIP1559TxTransaction to encode

encodeSignedTx

Encode a signed EIP-1559 transaction

function encodeSignedTx(EIP1559Tx memory rawTx, SignatureRSV memory rsv) internal pure returns (bytes memory);

Parameters

NameTypeDescription
rawTxEIP1559TxTransaction which was signed
rsvSignatureRSVR, S & V parameters of signature

signRawTx

Sign a raw transaction

function signRawTx(EIP1559Tx memory rawTx, address pubkeyAddr, bytes32 secretKey)
    internal
    view
    returns (SignatureRSV memory ret);

Parameters

NameTypeDescription
rawTxEIP1559TxTransaction to sign
pubkeyAddraddressEthereum address of secret key
secretKeybytes32Secret key used to sign

sign

Sign a transaction, returning it in EIP-1559 encoded form

function sign(address publicAddress, bytes32 secretKey, EIP1559Tx memory transaction)
    internal
    view
    returns (bytes memory);

Parameters

NameTypeDescription
publicAddressaddressEthereum address of secret key
secretKeybytes32Secret key used to sign
transactionEIP1559TxTransaction to sign

Structs

EIP1559Tx

struct EIP1559Tx {
    uint64 nonce;
    uint256 maxPriorityFeePerGas;
    uint256 maxFeePerGas;
    uint64 gasLimit;
    address to;
    uint256 value;
    bytes data;
    EIPTypes.AccessList accessList;
    uint256 chainId;
}