Feature Tip: Add private address tag to any address under My Name Tag !
Overview
ETH Balance
0 ETH
Eth Value
$0.00Token Holdings
More Info
Private Name Tags
ContractCreator
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
ParaswapWrapper
Compiler Version
v0.8.10+commit.fc410830
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2024-03-14 */ // SPDX-License-Identifier: MIT pragma solidity =0.8.10; contract MainnetAuthAddresses { address internal constant ADMIN_VAULT_ADDR = 0xCCf3d848e08b94478Ed8f46fFead3008faF581fD; address internal constant DSGUARD_FACTORY_ADDRESS = 0x5a15566417e6C1c9546523066500bDDBc53F88C7; address internal constant ADMIN_ADDR = 0x25eFA336886C74eA8E282ac466BdCd0199f85BB9; // USED IN ADMIN VAULT CONSTRUCTOR address internal constant PROXY_AUTH_ADDRESS = 0x149667b6FAe2c63D1B4317C716b0D0e4d3E2bD70; address internal constant MODULE_AUTH_ADDRESS = 0x7407974DDBF539e552F1d051e44573090912CC3D; } contract AuthHelper is MainnetAuthAddresses { } contract AdminVault is AuthHelper { address public owner; address public admin; error SenderNotAdmin(); constructor() { owner = msg.sender; admin = ADMIN_ADDR; } /// @notice Admin is able to change owner /// @param _owner Address of new owner function changeOwner(address _owner) public { if (admin != msg.sender){ revert SenderNotAdmin(); } owner = _owner; } /// @notice Admin is able to set new admin /// @param _admin Address of multisig that becomes new admin function changeAdmin(address _admin) public { if (admin != msg.sender){ revert SenderNotAdmin(); } admin = _admin; } } interface IERC20 { function name() external view returns (string memory); function symbol() external view returns (string memory); function decimals() external view returns (uint256 digits); function totalSupply() external view returns (uint256 supply); function balanceOf(address _owner) external view returns (uint256 balance); function transfer(address _to, uint256 _value) external returns (bool success); function transferFrom( address _from, address _to, uint256 _value ) external returns (bool success); function approve(address _spender, uint256 _value) external returns (bool success); function allowance(address _owner, address _spender) external view returns (uint256 remaining); event Approval(address indexed _owner, address indexed _spender, uint256 _value); } library Address { //insufficient balance error InsufficientBalance(uint256 available, uint256 required); //unable to send value, recipient may have reverted error SendingValueFail(); //insufficient balance for call error InsufficientBalanceForCall(uint256 available, uint256 required); //call to non-contract error NonContractCall(); function isContract(address account) internal view returns (bool) { // According to EIP-1052, 0x0 is the value returned for not-yet created accounts // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned // for accounts without code, i.e. `keccak256('')` bytes32 codehash; bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470; // solhint-disable-next-line no-inline-assembly assembly { codehash := extcodehash(account) } return (codehash != accountHash && codehash != 0x0); } function sendValue(address payable recipient, uint256 amount) internal { uint256 balance = address(this).balance; if (balance < amount){ revert InsufficientBalance(balance, amount); } // solhint-disable-next-line avoid-low-level-calls, avoid-call-value (bool success, ) = recipient.call{value: amount}(""); if (!(success)){ revert SendingValueFail(); } } function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return _functionCallWithValue(target, data, 0, errorMessage); } function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { uint256 balance = address(this).balance; if (balance < value){ revert InsufficientBalanceForCall(balance, value); } return _functionCallWithValue(target, data, value, errorMessage); } function _functionCallWithValue( address target, bytes memory data, uint256 weiValue, string memory errorMessage ) private returns (bytes memory) { if (!(isContract(target))){ revert NonContractCall(); } // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = target.call{value: weiValue}(data); if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly // solhint-disable-next-line no-inline-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } } library SafeERC20 { using Address for address; /** * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, * non-reverting calls are assumed to be successful. */ function safeTransfer(IERC20 token, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } /** * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. */ function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, * non-reverting calls are assumed to be successful. Compatible with tokens that require the approval to be set to * 0 before setting it to a non-zero value. */ function safeApprove(IERC20 token, address spender, uint256 value) internal { bytes memory approvalCall = abi.encodeWithSelector(token.approve.selector, spender, value); if (!_callOptionalReturnBool(token, approvalCall)) { _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, 0)); _callOptionalReturn(token, approvalCall); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); require(returndata.length == 0 || abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). * * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. */ function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false // and not revert is the subcall reverts. (bool success, bytes memory returndata) = address(token).call(data); return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0; } } contract AdminAuth is AuthHelper { using SafeERC20 for IERC20; AdminVault public constant adminVault = AdminVault(ADMIN_VAULT_ADDR); error SenderNotOwner(); error SenderNotAdmin(); modifier onlyOwner() { if (adminVault.owner() != msg.sender){ revert SenderNotOwner(); } _; } modifier onlyAdmin() { if (adminVault.admin() != msg.sender){ revert SenderNotAdmin(); } _; } /// @notice withdraw stuck funds function withdrawStuckFunds(address _token, address _receiver, uint256 _amount) public onlyOwner { if (_token == 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE) { payable(_receiver).transfer(_amount); } else { IERC20(_token).safeTransfer(_receiver, _amount); } } /// @notice Destroy the contract /// @dev Deprecated method, selfdestruct will soon just send eth function kill() public onlyAdmin { selfdestruct(payable(msg.sender)); } } contract Discount is AdminAuth{ mapping(address => bool) public serviceFeesDisabled; function reenableServiceFee(address _wallet) public onlyOwner{ serviceFeesDisabled[_wallet] = false; } function disableServiceFee(address _wallet) public onlyOwner{ serviceFeesDisabled[_wallet] = true; } } abstract contract IWETH { function allowance(address, address) public virtual view returns (uint256); function balanceOf(address) public virtual view returns (uint256); function approve(address, uint256) public virtual; function transfer(address, uint256) public virtual returns (bool); function transferFrom( address, address, uint256 ) public virtual returns (bool); function deposit() public payable virtual; function withdraw(uint256) public virtual; } library TokenUtils { using SafeERC20 for IERC20; address public constant WETH_ADDR = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2; address public constant ETH_ADDR = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE; /// @dev Only approves the amount if allowance is lower than amount, does not decrease allowance function approveToken( address _tokenAddr, address _to, uint256 _amount ) internal { if (_tokenAddr == ETH_ADDR) return; if (IERC20(_tokenAddr).allowance(address(this), _to) < _amount) { IERC20(_tokenAddr).safeApprove(_to, _amount); } } function pullTokensIfNeeded( address _token, address _from, uint256 _amount ) internal returns (uint256) { // handle max uint amount if (_amount == type(uint256).max) { _amount = getBalance(_token, _from); } if (_from != address(0) && _from != address(this) && _token != ETH_ADDR && _amount != 0) { IERC20(_token).safeTransferFrom(_from, address(this), _amount); } return _amount; } function withdrawTokens( address _token, address _to, uint256 _amount ) internal returns (uint256) { if (_amount == type(uint256).max) { _amount = getBalance(_token, address(this)); } if (_to != address(0) && _to != address(this) && _amount != 0) { if (_token != ETH_ADDR) { IERC20(_token).safeTransfer(_to, _amount); } else { (bool success, ) = _to.call{value: _amount}(""); require(success, "Eth send fail"); } } return _amount; } function depositWeth(uint256 _amount) internal { IWETH(WETH_ADDR).deposit{value: _amount}(); } function withdrawWeth(uint256 _amount) internal { IWETH(WETH_ADDR).withdraw(_amount); } function getBalance(address _tokenAddr, address _acc) internal view returns (uint256) { if (_tokenAddr == ETH_ADDR) { return _acc.balance; } else { return IERC20(_tokenAddr).balanceOf(_acc); } } function getTokenDecimals(address _token) internal view returns (uint256) { if (_token == ETH_ADDR) return 18; return IERC20(_token).decimals(); } } contract DFSExchangeHelper { using TokenUtils for address; error InvalidOffchainData(); error OutOfRangeSlicingError(); //Order success but amount 0 error ZeroTokensSwapped(); using SafeERC20 for IERC20; function sendLeftover( address _srcAddr, address _destAddr, address payable _to ) internal { // clean out any eth leftover TokenUtils.ETH_ADDR.withdrawTokens(_to, type(uint256).max); _srcAddr.withdrawTokens(_to, type(uint256).max); _destAddr.withdrawTokens(_to, type(uint256).max); } function sliceUint(bytes memory bs, uint256 start) internal pure returns (uint256) { if (bs.length < start + 32){ revert OutOfRangeSlicingError(); } uint256 x; assembly { x := mload(add(bs, add(0x20, start))) } return x; } function writeUint256( bytes memory _b, uint256 _index, uint256 _input ) internal pure { if (_b.length < _index + 32) { revert InvalidOffchainData(); } bytes32 input = bytes32(_input); _index += 32; // Read the bytes32 from array memory assembly { mstore(add(_b, _index), input) } } } contract DFSExchangeData { struct OffchainData { address wrapper; // dfs wrapper address for the aggregator (must be in WrapperExchangeRegistry) address exchangeAddr; // exchange address we are calling to execute the order (must be in ExchangeAggregatorRegistry) address allowanceTarget; // exchange aggregator contract we give allowance to uint256 price; // expected price that the aggregator sent us uint256 protocolFee; // deprecated (used as a separate fee amount for 0x v1) bytes callData; // 0ff-chain calldata the aggregator gives to perform the swap } struct ExchangeData { address srcAddr; // source token address (which we're selling) address destAddr; // destination token address (which we're buying) uint256 srcAmount; // amount of source token in token decimals uint256 destAmount; // amount of bought token in token decimals uint256 minPrice; // minPrice we are expecting (checked in DFSExchangeCore) uint256 dfsFeeDivider; // service fee divider address user; // currently deprecated (used to check custom fees for the user) address wrapper; // on-chain wrapper address (must be in WrapperExchangeRegistry) bytes wrapperData; // on-chain additional data for on-chain (uniswap route for example) OffchainData offchainData; // offchain aggregator order } } abstract contract IOffchainWrapper is DFSExchangeData { function takeOrder( ExchangeData memory _exData ) virtual public payable returns (bool success, uint256); } contract ParaswapWrapper is IOffchainWrapper, DFSExchangeHelper, AdminAuth { using TokenUtils for address; using SafeERC20 for IERC20; /// @notice offchainData.callData should be this struct encoded struct ParaswapCalldata{ bytes realCalldata; uint256 offset; } /// @notice Takes order from Paraswap and returns bool indicating if it is successful /// @param _exData Exchange data function takeOrder( ExchangeData memory _exData ) override public payable returns (bool success, uint256) { ParaswapCalldata memory paraswapCalldata = abi.decode(_exData.offchainData.callData, (ParaswapCalldata)); // approve paraswap allowance contract IERC20(_exData.srcAddr).safeApprove(_exData.offchainData.allowanceTarget, _exData.srcAmount); // write in the exact amount we are selling/buying in an order writeUint256(paraswapCalldata.realCalldata, paraswapCalldata.offset, _exData.srcAmount); uint256 tokensBefore = _exData.destAddr.getBalance(address(this)); /// @dev the amount of tokens received is checked in DFSExchangeCore /// @dev Exchange wrapper contracts should not be used on their own (success, ) = _exData.offchainData.exchangeAddr.call(paraswapCalldata.realCalldata); uint256 tokensSwapped = 0; if (success) { // get the current balance of the swapped tokens tokensSwapped = _exData.destAddr.getBalance(address(this)) - tokensBefore; if (tokensSwapped == 0){ revert ZeroTokensSwapped(); } } // returns all funds from src addr, dest addr and eth funds (protocol fee leftovers) sendLeftover(_exData.srcAddr, _exData.destAddr, payable(msg.sender)); return (success, tokensSwapped); } // solhint-disable-next-line no-empty-blocks receive() external virtual payable {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"name":"InvalidOffchainData","type":"error"},{"inputs":[],"name":"NonContractCall","type":"error"},{"inputs":[],"name":"OutOfRangeSlicingError","type":"error"},{"inputs":[],"name":"SenderNotAdmin","type":"error"},{"inputs":[],"name":"SenderNotOwner","type":"error"},{"inputs":[],"name":"ZeroTokensSwapped","type":"error"},{"inputs":[],"name":"adminVault","outputs":[{"internalType":"contract AdminVault","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"kill","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"srcAddr","type":"address"},{"internalType":"address","name":"destAddr","type":"address"},{"internalType":"uint256","name":"srcAmount","type":"uint256"},{"internalType":"uint256","name":"destAmount","type":"uint256"},{"internalType":"uint256","name":"minPrice","type":"uint256"},{"internalType":"uint256","name":"dfsFeeDivider","type":"uint256"},{"internalType":"address","name":"user","type":"address"},{"internalType":"address","name":"wrapper","type":"address"},{"internalType":"bytes","name":"wrapperData","type":"bytes"},{"components":[{"internalType":"address","name":"wrapper","type":"address"},{"internalType":"address","name":"exchangeAddr","type":"address"},{"internalType":"address","name":"allowanceTarget","type":"address"},{"internalType":"uint256","name":"price","type":"uint256"},{"internalType":"uint256","name":"protocolFee","type":"uint256"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct DFSExchangeData.OffchainData","name":"offchainData","type":"tuple"}],"internalType":"struct DFSExchangeData.ExchangeData","name":"_exData","type":"tuple"}],"name":"takeOrder","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_receiver","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdrawStuckFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
608060405234801561001057600080fd5b50611058806100206000396000f3fe6080604052600436106100435760003560e01c806316d2a88c1461004f57806341c0e1b51461007e5780638cedca7114610095578063c579d490146100d557600080fd5b3661004a57005b600080fd5b61006261005d366004610d0e565b6100f5565b6040805192151583526020830191909152015b60405180910390f35b34801561008a57600080fd5b5061009361026b565b005b3480156100a157600080fd5b506100bd73ccf3d848e08b94478ed8f46ffead3008faf581fd81565b6040516001600160a01b039091168152602001610075565b3480156100e157600080fd5b506100936100f0366004610e12565b61032e565b600080600083610120015160a001518060200190518101906101179190610e7f565b905061014884610120015160400151856040015186600001516001600160a01b03166104689092919063ffffffff16565b61015f81600001518260200151866040015161056c565b602084015160009061017a906001600160a01b0316306105c9565b9050846101200151602001516001600160a01b031682600001516040516101a19190610f2f565b6000604051808303816000865af19150503d80600081146101de576040519150601f19603f3d011682016040523d82523d6000602084013e6101e3565b606091505b5050809450506000841561024e576020860151829061020b906001600160a01b0316306105c9565b6102159190610f61565b90508061024e576040517f6a756fbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610261866000015187602001513361068d565b9395939450505050565b336001600160a01b031673ccf3d848e08b94478ed8f46ffead3008faf581fd6001600160a01b031663f851a4406040518163ffffffff1660e01b8152600401602060405180830381865afa1580156102c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102eb9190610f78565b6001600160a01b03161461032b576040517fa6c827a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33ff5b336001600160a01b031673ccf3d848e08b94478ed8f46ffead3008faf581fd6001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561038a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ae9190610f78565b6001600160a01b0316146103ee576040517f19494c8a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6001600160a01b038416141561044f576040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015610449573d6000803e3d6000fd5b50505050565b6104636001600160a01b03841683836106dc565b505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1663095ea7b360e01b1790526104ce8482610725565b610449576040516001600160a01b03841660248201526000604482015261056290859063095ea7b360e01b906064015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526107cd565b61044984826107cd565b610577826020610f9c565b835110156105b1576040517ff340347200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806105bd602084610f9c565b93909301929092525050565b60006001600160a01b03831673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee141561060157506001600160a01b03811631610687565b6040517f70a082310000000000000000000000000000000000000000000000000000000081526001600160a01b0383811660048301528416906370a0823190602401602060405180830381865afa158015610660573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106849190610fb4565b90505b92915050565b6106ae73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee826000196108ba565b506106c56001600160a01b038416826000196108ba565b506104496001600160a01b038316826000196108ba565b6040516001600160a01b0383166024820152604481018290526104639084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064016104fe565b6000806000846001600160a01b0316846040516107429190610f2f565b6000604051808303816000865af19150503d806000811461077f576040519150601f19603f3d011682016040523d82523d6000602084013e610784565b606091505b50915091508180156107ae5750805115806107ae5750808060200190518101906107ae9190610fcd565b80156107c457506000856001600160a01b03163b115b95945050505050565b6000610822826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166109ed9092919063ffffffff16565b90508051600014806108435750808060200190518101906108439190610fcd565b6104635760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b60006000198214156108d3576108d084306105c9565b91505b6001600160a01b038316158015906108f457506001600160a01b0383163014155b80156108ff57508115155b156109e6576001600160a01b03841673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee146109415761093c6001600160a01b03851684846106dc565b6109e6565b6000836001600160a01b03168360405160006040518083038185875af1925050503d806000811461098e576040519150601f19603f3d011682016040523d82523d6000602084013e610993565b606091505b50509050806109e45760405162461bcd60e51b815260206004820152600d60248201527f4574682073656e64206661696c0000000000000000000000000000000000000060448201526064016108b1565b505b5092915050565b60606109fc8484600085610a04565b949350505050565b6060610a0f85610ae1565b610a45576040517f304619b500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080866001600160a01b03168587604051610a619190610f2f565b60006040518083038185875af1925050503d8060008114610a9e576040519150601f19603f3d011682016040523d82523d6000602084013e610aa3565b606091505b50915091508115610ab75791506109fc9050565b805115610ac75780518082602001fd5b8360405162461bcd60e51b81526004016108b19190610fef565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708181148015906109fc575050151592915050565b634e487b7160e01b600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715610b5457610b54610b1a565b60405290565b6040805190810167ffffffffffffffff81118282101715610b5457610b54610b1a565b604051601f8201601f1916810167ffffffffffffffff81118282101715610ba657610ba6610b1a565b604052919050565b6001600160a01b0381168114610bc357600080fd5b50565b8035610bd181610bae565b919050565b600067ffffffffffffffff821115610bf057610bf0610b1a565b50601f01601f191660200190565b600082601f830112610c0f57600080fd5b8135610c22610c1d82610bd6565b610b7d565b818152846020838601011115610c3757600080fd5b816020850160208301376000918101602001919091529392505050565b600060c08284031215610c6657600080fd5b60405160c0810167ffffffffffffffff8282108183111715610c8a57610c8a610b1a565b8160405282935084359150610c9e82610bae565b908252602084013590610cb082610bae565b81602084015260408501359150610cc682610bae565b816040840152606085013560608401526080850135608084015260a0850135915080821115610cf457600080fd5b50610d0185828601610bfe565b60a0830152505092915050565b600060208284031215610d2057600080fd5b813567ffffffffffffffff80821115610d3857600080fd5b908301906101408286031215610d4d57600080fd5b610d55610b30565b610d5e83610bc6565b8152610d6c60208401610bc6565b602082015260408301356040820152606083013560608201526080830135608082015260a083013560a0820152610da560c08401610bc6565b60c0820152610db660e08401610bc6565b60e08201526101008084013583811115610dcf57600080fd5b610ddb88828701610bfe565b8284015250506101208084013583811115610df557600080fd5b610e0188828701610c54565b918301919091525095945050505050565b600080600060608486031215610e2757600080fd5b8335610e3281610bae565b92506020840135610e4281610bae565b929592945050506040919091013590565b60005b83811015610e6e578181015183820152602001610e56565b838111156104495750506000910152565b60006020808385031215610e9257600080fd5b825167ffffffffffffffff80821115610eaa57600080fd5b9084019060408287031215610ebe57600080fd5b610ec6610b5a565b825182811115610ed557600080fd5b83019150601f82018713610ee857600080fd5b8151610ef6610c1d82610bd6565b8181528886838601011115610f0a57600080fd5b610f1982878301888701610e53565b8252509183015192820192909252949350505050565b60008251610f41818460208701610e53565b9190910192915050565b634e487b7160e01b600052601160045260246000fd5b600082821015610f7357610f73610f4b565b500390565b600060208284031215610f8a57600080fd5b8151610f9581610bae565b9392505050565b60008219821115610faf57610faf610f4b565b500190565b600060208284031215610fc657600080fd5b5051919050565b600060208284031215610fdf57600080fd5b81518015158114610f9557600080fd5b602081526000825180602084015261100e816040850160208701610e53565b601f01601f1916919091016040019291505056fea26469706673582212208cdda0ca5b2eed6d5bf37c4f27e520b5c4105ee584257c01aa3466b79ea0da2064736f6c634300080a0033
Deployed Bytecode
0x6080604052600436106100435760003560e01c806316d2a88c1461004f57806341c0e1b51461007e5780638cedca7114610095578063c579d490146100d557600080fd5b3661004a57005b600080fd5b61006261005d366004610d0e565b6100f5565b6040805192151583526020830191909152015b60405180910390f35b34801561008a57600080fd5b5061009361026b565b005b3480156100a157600080fd5b506100bd73ccf3d848e08b94478ed8f46ffead3008faf581fd81565b6040516001600160a01b039091168152602001610075565b3480156100e157600080fd5b506100936100f0366004610e12565b61032e565b600080600083610120015160a001518060200190518101906101179190610e7f565b905061014884610120015160400151856040015186600001516001600160a01b03166104689092919063ffffffff16565b61015f81600001518260200151866040015161056c565b602084015160009061017a906001600160a01b0316306105c9565b9050846101200151602001516001600160a01b031682600001516040516101a19190610f2f565b6000604051808303816000865af19150503d80600081146101de576040519150601f19603f3d011682016040523d82523d6000602084013e6101e3565b606091505b5050809450506000841561024e576020860151829061020b906001600160a01b0316306105c9565b6102159190610f61565b90508061024e576040517f6a756fbe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610261866000015187602001513361068d565b9395939450505050565b336001600160a01b031673ccf3d848e08b94478ed8f46ffead3008faf581fd6001600160a01b031663f851a4406040518163ffffffff1660e01b8152600401602060405180830381865afa1580156102c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102eb9190610f78565b6001600160a01b03161461032b576040517fa6c827a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33ff5b336001600160a01b031673ccf3d848e08b94478ed8f46ffead3008faf581fd6001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561038a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ae9190610f78565b6001600160a01b0316146103ee576040517f19494c8a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6001600160a01b038416141561044f576040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015610449573d6000803e3d6000fd5b50505050565b6104636001600160a01b03841683836106dc565b505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1663095ea7b360e01b1790526104ce8482610725565b610449576040516001600160a01b03841660248201526000604482015261056290859063095ea7b360e01b906064015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526107cd565b61044984826107cd565b610577826020610f9c565b835110156105b1576040517ff340347200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806105bd602084610f9c565b93909301929092525050565b60006001600160a01b03831673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee141561060157506001600160a01b03811631610687565b6040517f70a082310000000000000000000000000000000000000000000000000000000081526001600160a01b0383811660048301528416906370a0823190602401602060405180830381865afa158015610660573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106849190610fb4565b90505b92915050565b6106ae73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee826000196108ba565b506106c56001600160a01b038416826000196108ba565b506104496001600160a01b038316826000196108ba565b6040516001600160a01b0383166024820152604481018290526104639084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064016104fe565b6000806000846001600160a01b0316846040516107429190610f2f565b6000604051808303816000865af19150503d806000811461077f576040519150601f19603f3d011682016040523d82523d6000602084013e610784565b606091505b50915091508180156107ae5750805115806107ae5750808060200190518101906107ae9190610fcd565b80156107c457506000856001600160a01b03163b115b95945050505050565b6000610822826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166109ed9092919063ffffffff16565b90508051600014806108435750808060200190518101906108439190610fcd565b6104635760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b60006000198214156108d3576108d084306105c9565b91505b6001600160a01b038316158015906108f457506001600160a01b0383163014155b80156108ff57508115155b156109e6576001600160a01b03841673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee146109415761093c6001600160a01b03851684846106dc565b6109e6565b6000836001600160a01b03168360405160006040518083038185875af1925050503d806000811461098e576040519150601f19603f3d011682016040523d82523d6000602084013e610993565b606091505b50509050806109e45760405162461bcd60e51b815260206004820152600d60248201527f4574682073656e64206661696c0000000000000000000000000000000000000060448201526064016108b1565b505b5092915050565b60606109fc8484600085610a04565b949350505050565b6060610a0f85610ae1565b610a45576040517f304619b500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080866001600160a01b03168587604051610a619190610f2f565b60006040518083038185875af1925050503d8060008114610a9e576040519150601f19603f3d011682016040523d82523d6000602084013e610aa3565b606091505b50915091508115610ab75791506109fc9050565b805115610ac75780518082602001fd5b8360405162461bcd60e51b81526004016108b19190610fef565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708181148015906109fc575050151592915050565b634e487b7160e01b600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715610b5457610b54610b1a565b60405290565b6040805190810167ffffffffffffffff81118282101715610b5457610b54610b1a565b604051601f8201601f1916810167ffffffffffffffff81118282101715610ba657610ba6610b1a565b604052919050565b6001600160a01b0381168114610bc357600080fd5b50565b8035610bd181610bae565b919050565b600067ffffffffffffffff821115610bf057610bf0610b1a565b50601f01601f191660200190565b600082601f830112610c0f57600080fd5b8135610c22610c1d82610bd6565b610b7d565b818152846020838601011115610c3757600080fd5b816020850160208301376000918101602001919091529392505050565b600060c08284031215610c6657600080fd5b60405160c0810167ffffffffffffffff8282108183111715610c8a57610c8a610b1a565b8160405282935084359150610c9e82610bae565b908252602084013590610cb082610bae565b81602084015260408501359150610cc682610bae565b816040840152606085013560608401526080850135608084015260a0850135915080821115610cf457600080fd5b50610d0185828601610bfe565b60a0830152505092915050565b600060208284031215610d2057600080fd5b813567ffffffffffffffff80821115610d3857600080fd5b908301906101408286031215610d4d57600080fd5b610d55610b30565b610d5e83610bc6565b8152610d6c60208401610bc6565b602082015260408301356040820152606083013560608201526080830135608082015260a083013560a0820152610da560c08401610bc6565b60c0820152610db660e08401610bc6565b60e08201526101008084013583811115610dcf57600080fd5b610ddb88828701610bfe565b8284015250506101208084013583811115610df557600080fd5b610e0188828701610c54565b918301919091525095945050505050565b600080600060608486031215610e2757600080fd5b8335610e3281610bae565b92506020840135610e4281610bae565b929592945050506040919091013590565b60005b83811015610e6e578181015183820152602001610e56565b838111156104495750506000910152565b60006020808385031215610e9257600080fd5b825167ffffffffffffffff80821115610eaa57600080fd5b9084019060408287031215610ebe57600080fd5b610ec6610b5a565b825182811115610ed557600080fd5b83019150601f82018713610ee857600080fd5b8151610ef6610c1d82610bd6565b8181528886838601011115610f0a57600080fd5b610f1982878301888701610e53565b8252509183015192820192909252949350505050565b60008251610f41818460208701610e53565b9190910192915050565b634e487b7160e01b600052601160045260246000fd5b600082821015610f7357610f73610f4b565b500390565b600060208284031215610f8a57600080fd5b8151610f9581610bae565b9392505050565b60008219821115610faf57610faf610f4b565b500190565b600060208284031215610fc657600080fd5b5051919050565b600060208284031215610fdf57600080fd5b81518015158114610f9557600080fd5b602081526000825180602084015261100e816040850160208701610e53565b601f01601f1916919091016040019291505056fea26469706673582212208cdda0ca5b2eed6d5bf37c4f27e520b5c4105ee584257c01aa3466b79ea0da2064736f6c634300080a0033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
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.