Overview
S Balance
0 S
S Value
$0.00More Info
Private Name Tags
ContractCreator
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Latest 1 internal transaction
Parent Transaction Hash | Block | From | To | |||
---|---|---|---|---|---|---|
5114324 | 7 days ago | Contract Creation | 0 S |
Loading...
Loading
Contract Name:
MetaRouterGateway
Compiler Version
v0.8.19+commit.7dd6d404
Optimization Enabled:
Yes with 2000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-3.0 pragma solidity ^0.8.0; import "@uniswap/lib/contracts/libraries/TransferHelper.sol"; /** * @title MetaRouterGateway * @notice During the `metaRoute` transaction `MetaRouter` (only) claims user's tokens * from `MetaRoutetGateway` contract and then operates with them. */ contract MetaRouterGateway { address public immutable metaRouter; modifier onlyMetarouter() { require(metaRouter == msg.sender, "Symb: caller is not the metarouter"); _; } constructor(address _metaRouter) { metaRouter = _metaRouter; } function claimTokens( address _token, address _from, uint256 _amount ) external onlyMetarouter { TransferHelper.safeTransferFrom(_token, _from, metaRouter, _amount); } }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity >=0.6.0; // helper methods for interacting with ERC20 tokens and sending ETH that do not consistently return true/false library TransferHelper { function safeApprove( address token, address to, uint256 value ) internal { // bytes4(keccak256(bytes('approve(address,uint256)'))); (bool success, bytes memory data) = token.call(abi.encodeWithSelector(0x095ea7b3, to, value)); require( success && (data.length == 0 || abi.decode(data, (bool))), 'TransferHelper::safeApprove: approve failed' ); } function safeTransfer( address token, address to, uint256 value ) internal { // bytes4(keccak256(bytes('transfer(address,uint256)'))); (bool success, bytes memory data) = token.call(abi.encodeWithSelector(0xa9059cbb, to, value)); require( success && (data.length == 0 || abi.decode(data, (bool))), 'TransferHelper::safeTransfer: transfer failed' ); } function safeTransferFrom( address token, address from, address to, uint256 value ) internal { // bytes4(keccak256(bytes('transferFrom(address,address,uint256)'))); (bool success, bytes memory data) = token.call(abi.encodeWithSelector(0x23b872dd, from, to, value)); require( success && (data.length == 0 || abi.decode(data, (bool))), 'TransferHelper::transferFrom: transferFrom failed' ); } function safeTransferETH(address to, uint256 value) internal { (bool success, ) = to.call{value: value}(new bytes(0)); require(success, 'TransferHelper::safeTransferETH: ETH transfer failed'); } }
{ "viaIR": true, "optimizer": { "enabled": true, "runs": 2000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_metaRouter","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_from","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"claimTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"metaRouter","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a03461006f57601f61041438819003918201601f19168301916001600160401b038311848410176100745780849260209460405283398101031261006f57516001600160a01b038116810361006f57608052604051610389908161008b82396080518181816066015260d50152f35b600080fd5b634e487b7160e01b600052604160045260246000fdfe608060408181526004918236101561001657600080fd5b600092833560e01c9182639fc314c81461008e57505063dbec15bb1461003b57600080fd5b3461008a578160031936011261008a576020905173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152f35b5080fd5b9150913461034f57606060031936011261034f5773ffffffffffffffffffffffffffffffffffffffff918335838116810361034b57602493843590808216809203610347577f000000000000000000000000000000000000000000000000000000000000000016923384036102c7575083519260208401917f23b872dd00000000000000000000000000000000000000000000000000000000835286850152604484015260443560648401526064835260a083019267ffffffffffffffff93818110858211176102b557855251879283929083905af1903d156102ad573d81811161029b578351917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81601f85011601168301908382109082111761028957845281523d86602083013e5b8161024d575b50156101cb578380f35b60849291602060319251937f08c379a00000000000000000000000000000000000000000000000000000000085528401528201527f5472616e7366657248656c7065723a3a7472616e7366657246726f6d3a20747260448201527f616e7366657246726f6d206661696c65640000000000000000000000000000006064820152fd5b8051801592508215610262575b5050386101c1565b81925090602091810103126102855760200151801515810361028557388061025a565b8480fd5b8588604189634e487b7160e01b835252fd5b8487604188634e487b7160e01b835252fd5b5060606101bb565b868960418a634e487b7160e01b835252fd5b8060228760208a7f08c379a000000000000000000000000000000000000000000000000000000000608496528401528201527f53796d623a2063616c6c6572206973206e6f7420746865206d657461726f757460448201527f65720000000000000000000000000000000000000000000000000000000000006064820152fd5b8780fd5b8580fd5b8380fdfea26469706673582212209687b8b71f09666b6e9bfc783feec19346340094ca8cf0d17818f12086e4de7e64736f6c63430008130033000000000000000000000000da8057acb94905eb6025120cb2c38415fd81bfeb
Deployed Bytecode
0x608060408181526004918236101561001657600080fd5b600092833560e01c9182639fc314c81461008e57505063dbec15bb1461003b57600080fd5b3461008a578160031936011261008a576020905173ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000da8057acb94905eb6025120cb2c38415fd81bfeb168152f35b5080fd5b9150913461034f57606060031936011261034f5773ffffffffffffffffffffffffffffffffffffffff918335838116810361034b57602493843590808216809203610347577f000000000000000000000000da8057acb94905eb6025120cb2c38415fd81bfeb16923384036102c7575083519260208401917f23b872dd00000000000000000000000000000000000000000000000000000000835286850152604484015260443560648401526064835260a083019267ffffffffffffffff93818110858211176102b557855251879283929083905af1903d156102ad573d81811161029b578351917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f81601f85011601168301908382109082111761028957845281523d86602083013e5b8161024d575b50156101cb578380f35b60849291602060319251937f08c379a00000000000000000000000000000000000000000000000000000000085528401528201527f5472616e7366657248656c7065723a3a7472616e7366657246726f6d3a20747260448201527f616e7366657246726f6d206661696c65640000000000000000000000000000006064820152fd5b8051801592508215610262575b5050386101c1565b81925090602091810103126102855760200151801515810361028557388061025a565b8480fd5b8588604189634e487b7160e01b835252fd5b8487604188634e487b7160e01b835252fd5b5060606101bb565b868960418a634e487b7160e01b835252fd5b8060228760208a7f08c379a000000000000000000000000000000000000000000000000000000000608496528401528201527f53796d623a2063616c6c6572206973206e6f7420746865206d657461726f757460448201527f65720000000000000000000000000000000000000000000000000000000000006064820152fd5b8780fd5b8580fd5b8380fdfea26469706673582212209687b8b71f09666b6e9bfc783feec19346340094ca8cf0d17818f12086e4de7e64736f6c63430008130033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000da8057acb94905eb6025120cb2c38415fd81bfeb
-----Decoded View---------------
Arg [0] : _metaRouter (address): 0xda8057acB94905eb6025120cB2c38415Fd81BfEB
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000da8057acb94905eb6025120cb2c38415fd81bfeb
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.