ETH Price: $2,549.46 (-4.08%)

Transaction Decoder

Block:
15807908 at Oct-23-2022 02:45:35 AM +UTC
Transaction Fee:
0.00040311583284304 ETH $1.03
Gas Used:
30,185 Gas / 13.354839584 Gwei

Account State Difference:

  Address   Before After State Difference Code
0x68fBEe07...029c0C389
0.000461484360789754 Eth
Nonce: 3
0.000058368527946714 Eth
Nonce: 4
0.00040311583284304
(builder0x69)
1.469429942639249968 Eth1.469490312639249968 Eth0.00006037

Execution Trace

EIP20.transfer( _to=0xae46E4Af5BEcC3dc4d9C815a2Ea8FFb122dF3785, _value=18885192160000000000 )
{"EIP20.sol":{"content":"/*\nImplements EIP20 token standard: https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md\nOriginal code by Consensys: https://github.com/ConsenSys/Tokens/blob/master/contracts/eip20/EIP20.sol\nWith modifications according to aleph.im needs (batch transfer, permit...)\n.*/\n\n\npragma solidity ^0.5.16;\n\nimport \"./EIP20Interface.sol\";\n\n\ncontract EIP20 is EIP20Interface {\n\n    uint256 constant private MAX_UINT256 = 2**256 - 1;\n    mapping (address =\u003e uint256) public balances;\n    mapping (address =\u003e mapping (address =\u003e uint256)) public allowed;\n    /*\n    NOTE:\n    The following variables are OPTIONAL vanities. One does not have to include them.\n    They allow one to customise the token contract \u0026 in no way influences the core functionality.\n    Some wallets/interfaces might not even bother to look at this information.\n    */\n    string public name;                   //fancy name: eg Simon Bucks\n    uint8 public decimals;                //How many decimals to show.\n    string public symbol;                 //An identifier: eg SBX\n\n    bytes32 public DOMAIN_SEPARATOR;\n    // keccak256(\"Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)\");\n    bytes32 public constant PERMIT_TYPEHASH = 0x6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9;\n\n    mapping(address =\u003e uint) public nonces;\n\n    constructor(\n        uint256 _initialAmount,\n        string memory _tokenName,\n        uint8 _decimalUnits,\n        string memory _tokenSymbol\n    ) public {\n        uint chainId;\n        assembly {\n            chainId := chainid\n        }\n        \n        balances[msg.sender] = _initialAmount;               // Give the creator all initial tokens\n        totalSupply = _initialAmount;                        // Update total supply\n        name = _tokenName;                                   // Set the name for display purposes\n        decimals = _decimalUnits;                            // Amount of decimals for display purposes\n        symbol = _tokenSymbol;                               // Set the symbol for display purposes\n\n        DOMAIN_SEPARATOR = keccak256(\n            abi.encode(\n                keccak256(\u0027EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)\u0027),\n                keccak256(bytes(name)),\n                keccak256(bytes(\u00271\u0027)),\n                chainId,\n                address(this)\n            )\n        );\n    }\n\n    function transfer(address _to, uint256 _value) public returns (bool success) {\n        require(balances[msg.sender] \u003e= _value);\n        balances[msg.sender] -= _value;\n        balances[_to] += _value;\n        emit Transfer(msg.sender, _to, _value); //solhint-disable-line indent, no-unused-vars\n        return true;\n    }\n\n    function transferFrom(address _from, address _to, uint256 _value) public returns (bool success) {\n        uint256 allowance = allowed[_from][msg.sender];\n        require(balances[_from] \u003e= _value \u0026\u0026 allowance \u003e= _value);\n        balances[_to] += _value;\n        balances[_from] -= _value;\n        if (allowance \u003c MAX_UINT256) {\n            allowed[_from][msg.sender] -= _value;\n        }\n        emit Transfer(_from, _to, _value); //solhint-disable-line indent, no-unused-vars\n        return true;\n    }\n\n    function balanceOf(address _owner) public view returns (uint256 balance) {\n        return balances[_owner];\n    }\n\n    function _approve(address owner, address spender, uint value) private {\n        allowed[owner][spender] = value;\n        emit Approval(owner, spender, value);\n    }\n\n    function approve(address _spender, uint256 _value) public returns (bool success) {\n        _approve(msg.sender, _spender, _value);\n        return true;\n    }\n\n    function allowance(address _owner, address _spender) public view returns (uint256 remaining) {\n        return allowed[_owner][_spender];\n    }\n\n    function batchTransfer(address[] memory _targets, uint256[] memory _values) public returns (bool success) {\n        uint8 i = 0;\n        for (i; i \u003c _targets.length; i++) {\n            transfer(_targets[i], _values[i]);\n        }\n        return true;\n    }\n\n    function batchTransferFrom(address _from, address[] memory _targets, uint256[] memory _values) public returns (bool success) {\n        uint8 i = 0;\n        for (i; i \u003c _targets.length; i++) {\n            transferFrom(_from, _targets[i], _values[i]);\n        }\n        return true;\n    }\n\n    function permit(address owner, address spender, uint value, uint deadline, uint8 v, bytes32 r, bytes32 s) external {\n        require(deadline \u003e= block.timestamp, \u0027PERMIT: EXPIRED\u0027);\n        bytes32 digest = keccak256(\n            abi.encodePacked(\n                \u0027\\x19\\x01\u0027,\n                DOMAIN_SEPARATOR,\n                keccak256(abi.encode(PERMIT_TYPEHASH, owner, spender, value, nonces[owner]++, deadline))\n            )\n        );\n        address recoveredAddress = ecrecover(digest, v, r, s);\n        require(recoveredAddress != address(0) \u0026\u0026 recoveredAddress == owner, \u0027PERMIT: INVALID_SIGNATURE\u0027);\n        _approve(owner, spender, value);\n    }\n}\n"},"EIP20Interface.sol":{"content":"// Abstract contract for the full ERC 20 Token standard\n// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md\n// Original code by Consensys: https://github.com/ConsenSys/Tokens/blob/master/contracts/eip20/EIP20Interface.sol\npragma solidity ^0.5.16;\n\n\ncontract EIP20Interface {\n    /* This is a slight change to the ERC20 base standard.\n    function totalSupply() constant returns (uint256 supply);\n    is replaced with:\n    uint256 public totalSupply;\n    This automatically creates a getter function for the totalSupply.\n    This is moved to the base contract since public getter functions are not\n    currently recognised as an implementation of the matching abstract\n    function by the compiler.\n    */\n    /// total amount of tokens\n    uint256 public totalSupply;\n\n    /// @param _owner The address from which the balance will be retrieved\n    /// @return The balance\n    function balanceOf(address _owner) public view returns (uint256 balance);\n\n    /// @notice send `_value` token to `_to` from `msg.sender`\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return Whether the transfer was successful or not\n    function transfer(address _to, uint256 _value) public returns (bool success);\n\n    /// @notice send `_value` token to `_to` from `_from` on the condition it is approved by `_from`\n    /// @param _from The address of the sender\n    /// @param _to The address of the recipient\n    /// @param _value The amount of token to be transferred\n    /// @return Whether the transfer was successful or not\n    function transferFrom(address _from, address _to, uint256 _value) public returns (bool success);\n\n    /// @notice `msg.sender` approves `_spender` to spend `_value` tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @param _value The amount of tokens to be approved for transfer\n    /// @return Whether the approval was successful or not\n    function approve(address _spender, uint256 _value) public returns (bool success);\n\n    /// @param _owner The address of the account owning tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @return Amount of remaining tokens allowed to spent\n    function allowance(address _owner, address _spender) public view returns (uint256 remaining);\n\n    // solhint-disable-next-line no-simple-event-func-name\n    event Transfer(address indexed _from, address indexed _to, uint256 _value);\n    event Approval(address indexed _owner, address indexed _spender, uint256 _value);\n\n\n    function DOMAIN_SEPARATOR() external view returns (bytes32);\n    function PERMIT_TYPEHASH() external pure returns (bytes32);\n    function nonces(address owner) external view returns (uint);\n}\n"}}