mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 04:09:23 +00:00
946 B
946 B
Ethereum
Addresses
Ethereum addresses are 20-byte hashes, identical to Ethereum proper.
In Instructions
In Instructions may be created in one of two ways.
- Have an EOA call
transferortransferFromon an ERC20, appending the encoded InInstruction directly after the calldata.origindefaults to the party transferred from. - Call
inInstructionon the Router.origindefaults tomsg.sender.
Out Instructions
data is limited to 512 bytes.
If data isn't provided or is malformed, ETH transfers will execute with 5,000
gas and token transfers with 100,000 gas.
If data is provided and well-formed, destination is ignored and the Ethereum
Router will construct and call a new contract to proxy the contained calls. The
transfer executes to the constructed contract as above, before the constructed
contract is called with the calls inside data. The sandboxed execution has a
gas limit of 350,000.