More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 358 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Withdraw | 19830737 | 245 days ago | IN | 0 ETH | 0.00125593 | ||||
Withdraw | 19830735 | 245 days ago | IN | 0 ETH | 0.0023472 | ||||
Withdraw | 19126758 | 344 days ago | IN | 0 ETH | 0.00932708 | ||||
Withdraw | 19126723 | 344 days ago | IN | 0 ETH | 0.00971267 | ||||
Withdraw | 19126713 | 344 days ago | IN | 0 ETH | 0.01035682 | ||||
Withdraw | 19126700 | 344 days ago | IN | 0 ETH | 0.01197718 | ||||
Withdraw | 18327645 | 456 days ago | IN | 0 ETH | 0.001914 | ||||
Withdraw | 18327618 | 456 days ago | IN | 0 ETH | 0.00198803 | ||||
Withdraw | 18316463 | 457 days ago | IN | 0 ETH | 0.00146289 | ||||
Withdraw | 18289488 | 461 days ago | IN | 0 ETH | 0.00157814 | ||||
Withdraw | 18275516 | 463 days ago | IN | 0 ETH | 0.00131926 | ||||
Withdraw | 18275508 | 463 days ago | IN | 0 ETH | 0.00152353 | ||||
Withdraw | 18275502 | 463 days ago | IN | 0 ETH | 0.00160697 | ||||
Withdraw | 18267531 | 464 days ago | IN | 0 ETH | 0.00189168 | ||||
Withdraw | 18267481 | 464 days ago | IN | 0 ETH | 0.00137062 | ||||
Withdraw | 18267347 | 464 days ago | IN | 0 ETH | 0.00182679 | ||||
Withdraw | 18266958 | 464 days ago | IN | 0 ETH | 0.00210171 | ||||
Withdraw | 18205780 | 473 days ago | IN | 0 ETH | 0.00167962 | ||||
Withdraw | 18054704 | 494 days ago | IN | 0 ETH | 0.00273621 | ||||
Withdraw | 17897640 | 516 days ago | IN | 0 ETH | 0.00290086 | ||||
Withdraw | 17897282 | 516 days ago | IN | 0 ETH | 0.0036611 | ||||
Withdraw | 17723037 | 540 days ago | IN | 0 ETH | 0.00488407 | ||||
Withdraw | 17651444 | 550 days ago | IN | 0 ETH | 0.00310665 | ||||
Withdraw | 17640511 | 552 days ago | IN | 0 ETH | 0.00527918 | ||||
Withdraw | 17618862 | 555 days ago | IN | 0 ETH | 0.00308634 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
Treasury
Compiler Version
v0.8.17+commit.8df45f5f
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
/** * SPDX-License-Identifier: unlicensed */ pragma solidity 0.8.17; import "@uniswap/v2-periphery/contracts/interfaces/IERC20.sol"; import "@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol"; abstract contract Auth { address internal _owner; mapping(address => bool) public isAuthorized; constructor(address owner) { _owner = owner; } modifier onlyOwner() { require(isOwner(msg.sender), "Auth: owner only"); _; } modifier authorized() { require(isAuthorized[msg.sender], "Auth: authorized only"); _; } function setAuthorization(address address_, bool authorization) external onlyOwner { isAuthorized[address_] = authorization; } function isOwner(address account) public view returns (bool) { return account == _owner; } function transferOwnership(address payable newOwner) external onlyOwner { require(newOwner != address(0), "Auth: owner address cannot be zero"); _transferOwnership(newOwner); } function renounceOwnership() external onlyOwner { _transferOwnership(address(0)); } function _transferOwnership(address newOwner) internal { _owner = newOwner; emit OwnershipTransferred(newOwner); } event OwnershipTransferred(address owner); } contract Treasury is Auth { address private constant router = 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D; address private weth; address private token; constructor(address tokenAddress) Auth(msg.sender) { require(tokenAddress != address(0), "VoxNET Treasury: token address cannot be zero"); weth = IUniswapV2Router02(router).WETH(); token = tokenAddress; bool approved = IERC20(token).approve(router, type(uint).max); require(approved == true, "VoxNET Treasury: approve failed"); } function withdraw( address to, uint amount, uint minimum, uint gasFee, uint deadline ) external authorized { if (gasFee == 0) { IERC20(token).transfer(to, amount); } else { address[] memory path = new address[](2); path[0] = token; path[1] = weth; uint[] memory amounts = IUniswapV2Router02(router).swapTokensForExactETH( gasFee, amount, path, msg.sender, deadline ); uint remaining = amount - amounts[0]; require(remaining >= minimum, "VoxNET Treasury: insufficient amount"); bool transferred = IERC20(token).transfer(to, remaining); require(transferred == true, "VoxNET Treasury: transfer failed"); } } }
pragma solidity >=0.6.2; import './IUniswapV2Router01.sol'; interface IUniswapV2Router02 is IUniswapV2Router01 { function removeLiquidityETHSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountETH); function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountETH); function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactETHForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; }
pragma solidity >=0.6.2; interface IUniswapV2Router01 { function factory() external pure returns (address); function WETH() external pure returns (address); function addLiquidity( address tokenA, address tokenB, uint amountADesired, uint amountBDesired, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB, uint liquidity); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); function removeLiquidity( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB); function removeLiquidityETH( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountToken, uint amountETH); function removeLiquidityWithPermit( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountA, uint amountB); function removeLiquidityETHWithPermit( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountToken, uint amountETH); function swapExactTokensForTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapTokensForExactTokens( uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapExactETHForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function swapTokensForExactETH(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapExactTokensForETH(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapETHForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); }
pragma solidity >=0.5.0; interface IERC20 { event Approval(address indexed owner, address indexed spender, uint value); event Transfer(address indexed from, address indexed to, uint value); function name() external view returns (string memory); function symbol() external view returns (string memory); function decimals() external view returns (uint8); function totalSupply() external view returns (uint); function balanceOf(address owner) external view returns (uint); function allowance(address owner, address spender) external view returns (uint); function approve(address spender, uint value) external returns (bool); function transfer(address to, uint value) external returns (bool); function transferFrom(address from, address to, uint value) external returns (bool); }
{ "remappings": [], "optimizer": { "enabled": true, "runs": 200 }, "evmVersion": "london", "libraries": {}, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"owner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isAuthorized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"address_","type":"address"},{"internalType":"bool","name":"authorization","type":"bool"}],"name":"setAuthorization","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"minimum","type":"uint256"},{"internalType":"uint256","name":"gasFee","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b50604051610b21380380610b2183398101604081905261002f91610230565b600080546001600160a01b031916331790556001600160a01b0381166100b25760405162461bcd60e51b815260206004820152602d60248201527f566f784e45542054726561737572793a20746f6b656e2061646472657373206360448201526c616e6e6f74206265207a65726f60981b60648201526084015b60405180910390fd5b737a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa158015610104573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101289190610230565b600280546001600160a01b03199081166001600160a01b039384161790915560038054909116918316918217905560405163095ea7b360e01b8152737a250d5630b4cf539739df2c5dacb4c659f2488d600482015260001960248201526000919063095ea7b3906044016020604051808303816000875af11580156101b1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d59190610260565b90506001811515146102295760405162461bcd60e51b815260206004820152601f60248201527f566f784e45542054726561737572793a20617070726f7665206661696c65640060448201526064016100a9565b5050610282565b60006020828403121561024257600080fd5b81516001600160a01b038116811461025957600080fd5b9392505050565b60006020828403121561027257600080fd5b8151801515811461025957600080fd5b610890806102916000396000f3fe608060405234801561001057600080fd5b50600436106100625760003560e01c80632f54bf6e1461006757806364095b4f1461009d578063715018a6146100b2578063eecea000146100ba578063f2fde38b146100cd578063fe9fbb80146100e0575b600080fd5b6100896100753660046105e2565b6000546001600160a01b0391821691161490565b604051901515815260200160405180910390f35b6100b06100ab366004610606565b610103565b005b6100b0610457565b6100b06100c8366004610658565b61048d565b6100b06100db3660046105e2565b6104e2565b6100896100ee3660046105e2565b60016020526000908152604090205460ff1681565b3360009081526001602052604090205460ff1661015f5760405162461bcd60e51b8152602060048201526015602482015274417574683a20617574686f72697a6564206f6e6c7960581b60448201526064015b60405180910390fd5b816000036101e45760035460405163a9059cbb60e01b81526001600160a01b038781166004830152602482018790529091169063a9059cbb906044016020604051808303816000875af11580156101ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101de9190610691565b50610450565b604080516002808252606082018352600092602083019080368337505060035482519293506001600160a01b031691839150600090610225576102256106c4565b6001600160a01b039283166020918202929092010152600254825191169082906001908110610256576102566106c4565b6001600160a01b0390921660209283029190910190910152604051632512eca560e11b8152600090737a250d5630b4cf539739df2c5dacb4c659f2488d90634a25d94a906102b09087908a90879033908a906004016106da565b6000604051808303816000875af11580156102cf573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526102f7919081019061074b565b905060008160008151811061030e5761030e6106c4565b6020026020010151876103219190610809565b90508581101561037f5760405162461bcd60e51b8152602060048201526024808201527f566f784e45542054726561737572793a20696e73756666696369656e7420616d6044820152631bdd5b9d60e21b6064820152608401610156565b60035460405163a9059cbb60e01b81526001600160a01b038a8116600483015260248201849052600092169063a9059cbb906044016020604051808303816000875af11580156103d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103f79190610691565b905060018115151461044b5760405162461bcd60e51b815260206004820181905260248201527f566f784e45542054726561737572793a207472616e73666572206661696c65646044820152606401610156565b505050505b5050505050565b6000546001600160a01b031633146104815760405162461bcd60e51b815260040161015690610830565b61048b6000610579565b565b6000546001600160a01b031633146104b75760405162461bcd60e51b815260040161015690610830565b6001600160a01b03919091166000908152600160205260409020805460ff1916911515919091179055565b6000546001600160a01b0316331461050c5760405162461bcd60e51b815260040161015690610830565b6001600160a01b03811661056d5760405162461bcd60e51b815260206004820152602260248201527f417574683a206f776e657220616464726573732063616e6e6f74206265207a65604482015261726f60f01b6064820152608401610156565b61057681610579565b50565b600080546001600160a01b0319166001600160a01b0383169081179091556040519081527f04dba622d284ed0014ee4b9a6a68386be1a4c08a4913ae272de89199cc6861639060200160405180910390a150565b6001600160a01b038116811461057657600080fd5b6000602082840312156105f457600080fd5b81356105ff816105cd565b9392505050565b600080600080600060a0868803121561061e57600080fd5b8535610629816105cd565b97602087013597506040870135966060810135965060800135945092505050565b801515811461057657600080fd5b6000806040838503121561066b57600080fd5b8235610676816105cd565b915060208301356106868161064a565b809150509250929050565b6000602082840312156106a357600080fd5b81516105ff8161064a565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b600060a082018783526020878185015260a0604085015281875180845260c086019150828901935060005b8181101561072a5784516001600160a01b031683529383019391830191600101610705565b50506001600160a01b03969096166060850152505050608001529392505050565b6000602080838503121561075e57600080fd5b825167ffffffffffffffff8082111561077657600080fd5b818501915085601f83011261078a57600080fd5b81518181111561079c5761079c6106ae565b8060051b604051601f19603f830116810181811085821117156107c1576107c16106ae565b6040529182528482019250838101850191888311156107df57600080fd5b938501935b828510156107fd578451845293850193928501926107e4565b98975050505050505050565b8181038181111561082a57634e487b7160e01b600052601160045260246000fd5b92915050565b60208082526010908201526f417574683a206f776e6572206f6e6c7960801b60408201526060019056fea2646970667358221220e8a755b79369fd4c4c25d3f31bad0f22e4e316592e48a6d2dff37a7de6bfd91064736f6c63430008110033000000000000000000000000048aa6e69d5117bd665af4128383a6982b8367b3
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100625760003560e01c80632f54bf6e1461006757806364095b4f1461009d578063715018a6146100b2578063eecea000146100ba578063f2fde38b146100cd578063fe9fbb80146100e0575b600080fd5b6100896100753660046105e2565b6000546001600160a01b0391821691161490565b604051901515815260200160405180910390f35b6100b06100ab366004610606565b610103565b005b6100b0610457565b6100b06100c8366004610658565b61048d565b6100b06100db3660046105e2565b6104e2565b6100896100ee3660046105e2565b60016020526000908152604090205460ff1681565b3360009081526001602052604090205460ff1661015f5760405162461bcd60e51b8152602060048201526015602482015274417574683a20617574686f72697a6564206f6e6c7960581b60448201526064015b60405180910390fd5b816000036101e45760035460405163a9059cbb60e01b81526001600160a01b038781166004830152602482018790529091169063a9059cbb906044016020604051808303816000875af11580156101ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101de9190610691565b50610450565b604080516002808252606082018352600092602083019080368337505060035482519293506001600160a01b031691839150600090610225576102256106c4565b6001600160a01b039283166020918202929092010152600254825191169082906001908110610256576102566106c4565b6001600160a01b0390921660209283029190910190910152604051632512eca560e11b8152600090737a250d5630b4cf539739df2c5dacb4c659f2488d90634a25d94a906102b09087908a90879033908a906004016106da565b6000604051808303816000875af11580156102cf573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526102f7919081019061074b565b905060008160008151811061030e5761030e6106c4565b6020026020010151876103219190610809565b90508581101561037f5760405162461bcd60e51b8152602060048201526024808201527f566f784e45542054726561737572793a20696e73756666696369656e7420616d6044820152631bdd5b9d60e21b6064820152608401610156565b60035460405163a9059cbb60e01b81526001600160a01b038a8116600483015260248201849052600092169063a9059cbb906044016020604051808303816000875af11580156103d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103f79190610691565b905060018115151461044b5760405162461bcd60e51b815260206004820181905260248201527f566f784e45542054726561737572793a207472616e73666572206661696c65646044820152606401610156565b505050505b5050505050565b6000546001600160a01b031633146104815760405162461bcd60e51b815260040161015690610830565b61048b6000610579565b565b6000546001600160a01b031633146104b75760405162461bcd60e51b815260040161015690610830565b6001600160a01b03919091166000908152600160205260409020805460ff1916911515919091179055565b6000546001600160a01b0316331461050c5760405162461bcd60e51b815260040161015690610830565b6001600160a01b03811661056d5760405162461bcd60e51b815260206004820152602260248201527f417574683a206f776e657220616464726573732063616e6e6f74206265207a65604482015261726f60f01b6064820152608401610156565b61057681610579565b50565b600080546001600160a01b0319166001600160a01b0383169081179091556040519081527f04dba622d284ed0014ee4b9a6a68386be1a4c08a4913ae272de89199cc6861639060200160405180910390a150565b6001600160a01b038116811461057657600080fd5b6000602082840312156105f457600080fd5b81356105ff816105cd565b9392505050565b600080600080600060a0868803121561061e57600080fd5b8535610629816105cd565b97602087013597506040870135966060810135965060800135945092505050565b801515811461057657600080fd5b6000806040838503121561066b57600080fd5b8235610676816105cd565b915060208301356106868161064a565b809150509250929050565b6000602082840312156106a357600080fd5b81516105ff8161064a565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b600060a082018783526020878185015260a0604085015281875180845260c086019150828901935060005b8181101561072a5784516001600160a01b031683529383019391830191600101610705565b50506001600160a01b03969096166060850152505050608001529392505050565b6000602080838503121561075e57600080fd5b825167ffffffffffffffff8082111561077657600080fd5b818501915085601f83011261078a57600080fd5b81518181111561079c5761079c6106ae565b8060051b604051601f19603f830116810181811085821117156107c1576107c16106ae565b6040529182528482019250838101850191888311156107df57600080fd5b938501935b828510156107fd578451845293850193928501926107e4565b98975050505050505050565b8181038181111561082a57634e487b7160e01b600052601160045260246000fd5b92915050565b60208082526010908201526f417574683a206f776e6572206f6e6c7960801b60408201526060019056fea2646970667358221220e8a755b79369fd4c4c25d3f31bad0f22e4e316592e48a6d2dff37a7de6bfd91064736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000048aa6e69d5117bd665af4128383a6982b8367b3
-----Decoded View---------------
Arg [0] : tokenAddress (address): 0x048Aa6E69D5117BD665aF4128383a6982B8367b3
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000048aa6e69d5117bd665af4128383a6982b8367b3
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|---|---|---|---|---|
ETH | 100.00% | $0.194668 | 10 | $1.95 |
Loading...
Loading
[ 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.