Source Code
Overview
ETH Balance
0 ETH
More Info
ContractCreator
Multichain Info
N/A
Latest 1 from a total of 1 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
Value | ||||
---|---|---|---|---|---|---|---|---|---|
0x60806040 | 8283775 | 434 days ago | IN | Create: OffChainAsset | 0 ETH | 0.02234827 |
Loading...
Loading
Contract Name:
OffChainAsset
Compiler Version
v0.8.16+commit.07a7930e
Optimization Enabled:
Yes with 100000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity 0.8.16; pragma experimental ABIEncoderV2; // ==================================================================== // ====================== OffChainAsset.sol ======================== // ==================================================================== /** * @title Off Chain Asset * @author MAXOS Team - https://maxos.finance/ * @dev Representation of an off-chain investment */ import "../Sweep/ISweep.sol"; import "../Utils/Uniswap/V2/TransferHelper.sol"; import "../Common/Owned.sol"; import "../Common/ERC20/IERC20Metadata.sol"; contract OffChainAsset is Owned { IERC20Metadata public usdx; ISweep public sweep; // Variables bool public redeem_mode; uint256 public redeem_amount; uint256 public redeem_time; uint8 public delay; // Days uint256 public current_value; uint256 public valuation_time; address public stabilizer; address public wallet; // Constants uint256 private constant DAY_TIMESTAMP = 24 * 60 * 60; // Events event Deposit(address token, uint256 amount); event Withdraw(uint256 amount); event Payback(address token, uint256 amount); constructor( address _owner, address _wallet, address _stabilizer, address _sweep_address, address _usdx_address ) Owned(_owner) { wallet = _wallet; stabilizer = _stabilizer; sweep = ISweep(_sweep_address); usdx = IERC20Metadata(_usdx_address); redeem_mode = false; } modifier onlyStabilizer() { require(msg.sender == stabilizer, "only stabilizer"); _; } /** * @notice Current Value of investment. */ function currentValue() external view returns (uint256) { return current_value; } /** * @notice isDefaulted * Check whether the redeem is executed. * @return bool True: is defaulted, False: not defaulted. */ function isDefaulted() public view returns (bool) { bool isPassed = redeem_time + (delay * DAY_TIMESTAMP) < block.timestamp; return redeem_mode && isPassed; } /** * @notice Update wallet to send the investment to. * @param _wallet New wallet address. */ function setWallet(address _wallet) public onlyOwner { wallet = _wallet; } /** * @notice Set Delay * @param _delay Days for delay. */ function setDelay(uint8 _delay) external onlyOwner { delay = _delay; } /** * @notice Deposit stable coins into Off Chain asset. * @param token token address to deposit. USDX, SWEEP ... * @param amount The amount of usdx to deposit in the asset. * @dev tracks the time when current_value was updated. */ function deposit(address token, uint256 amount) public onlyStabilizer { require(wallet != address(0), "Invaild Address"); TransferHelper.safeTransferFrom( address(token), stabilizer, wallet, amount ); if(token == address(sweep)) { uint256 sweep_in_usdx = SWEEPinUSDX(amount, sweep.target_price()); current_value += sweep_in_usdx; } else { current_value += amount; } valuation_time = block.timestamp; emit Deposit(token, amount); } /** * @notice Payback stable coins to Stabilizer * @param token token address to payback. USDX, SWEEP ... * @param amount The amount of usdx to payback. */ function payback(address token, uint256 amount) public { require(token == address(sweep) || token == address(usdx), "Invalid Token"); if(token == address(sweep)) { amount = SWEEPinUSDX(amount, sweep.target_price()); } require(redeem_amount <= amount, "Not enough amount"); TransferHelper.safeTransferFrom( address(token), msg.sender, stabilizer, amount ); current_value -= amount; redeem_mode = false; redeem_amount = 0; emit Payback(token, amount); } /** * @notice Withdraw usdx tokens from the asset. * @param amount The amount to withdraw. * @dev tracks the time when current_value was updated. */ function withdraw(uint256 amount) public onlyStabilizer { redeem_amount = amount; redeem_mode = true; redeem_time = block.timestamp; emit Withdraw(amount); } /** * @notice Update Value of investment. * @param _value New value of investment. * @dev tracks the time when current_value was updated. */ function updateValue(uint256 _value) public onlyOwner { current_value = _value; valuation_time = block.timestamp; } /** * @notice Reset the redeem mode. */ function resetRedeem() public onlyOwner { redeem_amount = 0; redeem_mode = false; } /** * @notice SWEEP in USDX * Calculate the amount of USDX that are equivalent to the SWEEP input. * @param amount Amount of SWEEP. * @param price Price of Sweep in USDX. This value is obtained from the AMM. * @return amount of USDX. * @dev 1e6 = PRICE_PRECISION */ function SWEEPinUSDX(uint256 amount, uint256 price) internal view returns (uint256) { return (amount * price * (10**usdx.decimals())) / (10**sweep.decimals() * 1e6); } /** * @notice Withdraw Rewards. * @dev this function was added to generate compatibility with On Chain investment. */ function withdrawRewards(address _owner) public {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity 0.8.16; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity 0.8.16; import "./IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); }
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity 0.8.16; // https://docs.synthetix.io/contracts/Owned contract Owned { address public owner; address public nominatedOwner; event OwnerNominated(address newOwner); event OwnerChanged(address oldOwner, address newOwner); constructor(address _owner) { require(_owner != address(0), "Owner address cannot be 0"); owner = _owner; emit OwnerChanged(address(0), _owner); } modifier onlyOwner() { require( msg.sender == owner, "Only the contract owner may perform this action" ); _; } function nominateNewOwner(address _owner) external onlyOwner { nominatedOwner = _owner; emit OwnerNominated(_owner); } function acceptOwnership() external { require( msg.sender == nominatedOwner, "You must be nominated before you can accept ownership" ); owner = nominatedOwner; nominatedOwner = address(0); emit OwnerChanged(owner, nominatedOwner); } }
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity 0.8.16; interface ISweep { struct Minter { bool is_listed; uint256 max_mint_amount; uint256 minted_amount; } function DEFAULT_ADMIN_ADDRESS() external view returns (address); function balancer() external view returns (address); function treasury() external view returns (address); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function balanceOf(address account) external view returns (uint256); function decimals() external view returns (uint8); function decreaseAllowance(address spender, uint256 subtractedValue) external returns (bool); function isValidMinter(address) external view returns (bool); function amm_price() external view returns (uint256); function increaseAllowance(address spender, uint256 addedValue) external returns (bool); function name() external view returns (string memory); function owner() external view returns (address); function minter_burn_from(uint256 amount) external; function minter_mint(address m_address, uint256 m_amount) external; function minters(address m_address) external returns (Minter memory); function target_price() external view returns (uint256); function interest_rate() external view returns (uint256); function period_time() external view returns (uint256); function step_value() external view returns (uint256); function beginNewPeriod(uint256 interest_rate, uint256 current_target_price, uint256 next_target_price) external; function setUniswapOracle(address _uniswap_oracle_address) external; function setTimelock(address new_timelock) external; function symbol() external view returns (string memory); function timelock_address() external view returns (address); function totalSupply() external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity 0.8.16; // 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, uint 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: APPROVE_FAILED'); } function safeTransfer(address token, address to, uint 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: TRANSFER_FAILED'); } function safeTransferFrom(address token, address from, address to, uint 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: TRANSFER_FROM_FAILED'); } function safeTransferETH(address to, uint value) internal { (bool success,) = to.call{value:value}(new bytes(0)); require(success, 'TransferHelper: ETH_TRANSFER_FAILED'); } }
{ "optimizer": { "enabled": true, "runs": 100000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
[{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_wallet","type":"address"},{"internalType":"address","name":"_stabilizer","type":"address"},{"internalType":"address","name":"_sweep_address","type":"address"},{"internalType":"address","name":"_usdx_address","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnerNominated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Payback","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"currentValue","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"current_value","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"delay","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isDefaulted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"nominateNewOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"nominatedOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"payback","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"redeem_amount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"redeem_mode","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"redeem_time","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"resetRedeem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint8","name":"_delay","type":"uint8"}],"name":"setDelay","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_wallet","type":"address"}],"name":"setWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stabilizer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"sweep","outputs":[{"internalType":"contract ISweep","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"updateValue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"usdx","outputs":[{"internalType":"contract IERC20Metadata","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"valuation_time","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wallet","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"withdrawRewards","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b50604051620017ff380380620017ff833981016040819052620000349162000164565b846001600160a01b038116620000905760405162461bcd60e51b815260206004820152601960248201527f4f776e657220616464726573732063616e6e6f74206265203000000000000000604482015260640160405180910390fd5b600080546001600160a01b0319166001600160a01b03831690811782556040805192835260208301919091527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c910160405180910390a150600a80546001600160a01b039586166001600160a01b0319918216179091556009805494861694821694909417909355600380546002805493871693909516929092179093556001600160a81b031916921691909117905550620001d4565b80516001600160a01b03811681146200015f57600080fd5b919050565b600080600080600060a086880312156200017d57600080fd5b620001888662000147565b9450620001986020870162000147565b9350620001a86040870162000147565b9250620001b86060870162000147565b9150620001c86080870162000147565b90509295509295909350565b61161b80620001e46000396000f3fe608060405234801561001057600080fd5b50600436106101985760003560e01c8063698996f8116100e3578063a38aaa901161008c578063d9ded5e011610066578063d9ded5e01461037a578063deaa59df1461038d578063f4adc2f0146103a057600080fd5b8063a38aaa9014610351578063c9c1ee6114610369578063ca627fe01461037257600080fd5b80637e47961c116100bd5780637e47961c146103085780638612711c146103285780638da5cb5b1461033157600080fd5b8063698996f8146102d95780636a42b8f8146102e157806379ba50971461030057600080fd5b806335faa41611610145578063521eb2731161011f578063521eb2731461028657806353a47bb7146102a6578063573c0bd3146102c657600080fd5b806335faa4161461024257806342d866931461026257806347e7ef241461027357600080fd5b8063311176d711610176578063311176d7146101e1578063345f2ffc1461022657806335ed8ab81461022f57600080fd5b80631627540c1461019d5780632689e595146101b25780632e1a7d4d146101ce575b600080fd5b6101b06101ab3660046112d1565b6103c5565b005b6101bb60055481565b6040519081526020015b60405180910390f35b6101b06101dc3660046112ec565b6104eb565b6002546102019073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101c5565b6101bb60075481565b6101b061023d366004611305565b6105e6565b6003546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101b06102703660046112d1565b50565b6101b0610281366004611305565b61087a565b600a546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6001546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101b06102d43660046112ec565b610ac4565b6007546101bb565b6006546102ee9060ff1681565b60405160ff90911681526020016101c5565b6101b0610b74565b6009546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101bb60045481565b6000546102019073ffffffffffffffffffffffffffffffffffffffff1681565b610359610ca3565b60405190151581526020016101c5565b6101bb60085481565b6101b0610cfc565b6101b061038836600461133e565b610dd2565b6101b061039b3660046112d1565b610ead565b6003546103599074010000000000000000000000000000000000000000900460ff1681565b60005473ffffffffffffffffffffffffffffffffffffffff163314610471576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e000000000000000000000000000000000060648201526084015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce22906020015b60405180910390a150565b60095473ffffffffffffffffffffffffffffffffffffffff16331461056c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f6f6e6c792073746162696c697a657200000000000000000000000000000000006044820152606401610468565b6004819055600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055426005556040517f5b6b431d4476a211bb7d41c20d1aab9ae2321deee0d20be3d9fc9b1093fa6e3d906104e09083815260200190565b60035473ffffffffffffffffffffffffffffffffffffffff83811691161480610629575060025473ffffffffffffffffffffffffffffffffffffffff8381169116145b61068f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f496e76616c696420546f6b656e000000000000000000000000000000000000006044820152606401610468565b60035473ffffffffffffffffffffffffffffffffffffffff9081169083160361074f5761074c81600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4f3641e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610723573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107479190611362565b610f9b565b90505b8060045411156107bb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f4e6f7420656e6f75676820616d6f756e740000000000000000000000000000006044820152606401610468565b6009546107e2908390339073ffffffffffffffffffffffffffffffffffffffff168461110a565b80600760008282546107f491906113aa565b9091555050600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16905560006004556040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527f8c9cdf934f136ab5b80fe11dfd56363fa7544ecb56d4c440c0d8a14d04bfff4a91015b60405180910390a15050565b60095473ffffffffffffffffffffffffffffffffffffffff1633146108fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f6f6e6c792073746162696c697a657200000000000000000000000000000000006044820152606401610468565b600a5473ffffffffffffffffffffffffffffffffffffffff1661097a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f496e7661696c64204164647265737300000000000000000000000000000000006044820152606401610468565b600954600a546109a691849173ffffffffffffffffffffffffffffffffffffffff91821691168461110a565b60035473ffffffffffffffffffffffffffffffffffffffff90811690831603610a5c576000610a3c82600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4f3641e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610723573d6000803e3d6000fd5b90508060076000828254610a5091906113bd565b90915550610a74915050565b8060076000828254610a6e91906113bd565b90915550505b426008556040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c910161086e565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b60075542600855565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c1b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f596f75206d757374206265206e6f6d696e61746564206265666f726520796f7560448201527f2063616e20616363657074206f776e65727368697000000000000000000000006064820152608401610468565b600180546000805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff00000000000000000000000000000000000000009182168117835592169092556040805191825260208201929092527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c910160405180910390a1565b60065460009081904290610cbe90620151809060ff166113d0565b600554610ccb91906113bd565b6003549111915074010000000000000000000000000000000000000000900460ff168015610cf65750805b91505090565b60005473ffffffffffffffffffffffffffffffffffffffff163314610da3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b6000600455600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b60005473ffffffffffffffffffffffffffffffffffffffff163314610e79576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f54576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b600a80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b600354604080517f313ce567000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163313ce5679160048083019260209291908290030181865afa15801561100b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061102f919061140d565b61103a90600a61154a565b61104790620f42406113d0565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d8919061140d565b6110e390600a61154a565b6110ed84866113d0565b6110f791906113d0565b6111019190611559565b90505b92915050565b6040805173ffffffffffffffffffffffffffffffffffffffff85811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f23b872dd0000000000000000000000000000000000000000000000000000000017905291516000928392908816916111a99190611594565b6000604051808303816000865af19150503d80600081146111e6576040519150601f19603f3d011682016040523d82523d6000602084013e6111eb565b606091505b509150915081801561121557508051158061121557508080602001905181019061121591906115c3565b6112a0576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f5472616e7366657248656c7065723a205452414e534645525f46524f4d5f464160448201527f494c4544000000000000000000000000000000000000000000000000000000006064820152608401610468565b505050505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146112cc57600080fd5b919050565b6000602082840312156112e357600080fd5b611101826112a8565b6000602082840312156112fe57600080fd5b5035919050565b6000806040838503121561131857600080fd5b611321836112a8565b946020939093013593505050565b60ff8116811461027057600080fd5b60006020828403121561135057600080fd5b813561135b8161132f565b9392505050565b60006020828403121561137457600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b818103818111156111045761110461137b565b808201808211156111045761110461137b565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156114085761140861137b565b500290565b60006020828403121561141f57600080fd5b815161135b8161132f565b600181815b8085111561148357817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156114695761146961137b565b8085161561147657918102915b93841c939080029061142f565b509250929050565b60008261149a57506001611104565b816114a757506000611104565b81600181146114bd57600281146114c7576114e3565b6001915050611104565b60ff8411156114d8576114d861137b565b50506001821b611104565b5060208310610133831016604e8410600b8410161715611506575081810a611104565b611510838361142a565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156115425761154261137b565b029392505050565b600061110160ff84168361148b565b60008261158f577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000825160005b818110156115b5576020818601810151858301520161159b565b506000920191825250919050565b6000602082840312156115d557600080fd5b8151801515811461135b57600080fdfea2646970667358221220b0c8e77d5512d43e5175e91753eb4a3f62467c178edb80c26e61db672cb988ca64736f6c6343000810003300000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead00000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead000000000000000000000000464d64a24b56681022e4332ea047a03ebbda5a260000000000000000000000004dba82efd938f273c5b8ae6a66d745a48584e6360000000000000000000000009fd21be27a2b059a288229361e2fa632d8d2d074
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101985760003560e01c8063698996f8116100e3578063a38aaa901161008c578063d9ded5e011610066578063d9ded5e01461037a578063deaa59df1461038d578063f4adc2f0146103a057600080fd5b8063a38aaa9014610351578063c9c1ee6114610369578063ca627fe01461037257600080fd5b80637e47961c116100bd5780637e47961c146103085780638612711c146103285780638da5cb5b1461033157600080fd5b8063698996f8146102d95780636a42b8f8146102e157806379ba50971461030057600080fd5b806335faa41611610145578063521eb2731161011f578063521eb2731461028657806353a47bb7146102a6578063573c0bd3146102c657600080fd5b806335faa4161461024257806342d866931461026257806347e7ef241461027357600080fd5b8063311176d711610176578063311176d7146101e1578063345f2ffc1461022657806335ed8ab81461022f57600080fd5b80631627540c1461019d5780632689e595146101b25780632e1a7d4d146101ce575b600080fd5b6101b06101ab3660046112d1565b6103c5565b005b6101bb60055481565b6040519081526020015b60405180910390f35b6101b06101dc3660046112ec565b6104eb565b6002546102019073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101c5565b6101bb60075481565b6101b061023d366004611305565b6105e6565b6003546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101b06102703660046112d1565b50565b6101b0610281366004611305565b61087a565b600a546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6001546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101b06102d43660046112ec565b610ac4565b6007546101bb565b6006546102ee9060ff1681565b60405160ff90911681526020016101c5565b6101b0610b74565b6009546102019073ffffffffffffffffffffffffffffffffffffffff1681565b6101bb60045481565b6000546102019073ffffffffffffffffffffffffffffffffffffffff1681565b610359610ca3565b60405190151581526020016101c5565b6101bb60085481565b6101b0610cfc565b6101b061038836600461133e565b610dd2565b6101b061039b3660046112d1565b610ead565b6003546103599074010000000000000000000000000000000000000000900460ff1681565b60005473ffffffffffffffffffffffffffffffffffffffff163314610471576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e000000000000000000000000000000000060648201526084015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527f906a1c6bd7e3091ea86693dd029a831c19049ce77f1dce2ce0bab1cacbabce22906020015b60405180910390a150565b60095473ffffffffffffffffffffffffffffffffffffffff16331461056c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f6f6e6c792073746162696c697a657200000000000000000000000000000000006044820152606401610468565b6004819055600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055426005556040517f5b6b431d4476a211bb7d41c20d1aab9ae2321deee0d20be3d9fc9b1093fa6e3d906104e09083815260200190565b60035473ffffffffffffffffffffffffffffffffffffffff83811691161480610629575060025473ffffffffffffffffffffffffffffffffffffffff8381169116145b61068f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f496e76616c696420546f6b656e000000000000000000000000000000000000006044820152606401610468565b60035473ffffffffffffffffffffffffffffffffffffffff9081169083160361074f5761074c81600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4f3641e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610723573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107479190611362565b610f9b565b90505b8060045411156107bb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f4e6f7420656e6f75676820616d6f756e740000000000000000000000000000006044820152606401610468565b6009546107e2908390339073ffffffffffffffffffffffffffffffffffffffff168461110a565b80600760008282546107f491906113aa565b9091555050600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16905560006004556040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527f8c9cdf934f136ab5b80fe11dfd56363fa7544ecb56d4c440c0d8a14d04bfff4a91015b60405180910390a15050565b60095473ffffffffffffffffffffffffffffffffffffffff1633146108fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f6f6e6c792073746162696c697a657200000000000000000000000000000000006044820152606401610468565b600a5473ffffffffffffffffffffffffffffffffffffffff1661097a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f496e7661696c64204164647265737300000000000000000000000000000000006044820152606401610468565b600954600a546109a691849173ffffffffffffffffffffffffffffffffffffffff91821691168461110a565b60035473ffffffffffffffffffffffffffffffffffffffff90811690831603610a5c576000610a3c82600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f4f3641e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610723573d6000803e3d6000fd5b90508060076000828254610a5091906113bd565b90915550610a74915050565b8060076000828254610a6e91906113bd565b90915550505b426008556040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c910161086e565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b60075542600855565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c1b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f596f75206d757374206265206e6f6d696e61746564206265666f726520796f7560448201527f2063616e20616363657074206f776e65727368697000000000000000000000006064820152608401610468565b600180546000805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff00000000000000000000000000000000000000009182168117835592169092556040805191825260208201929092527fb532073b38c83145e3e5135377a08bf9aab55bc0fd7c1179cd4fb995d2a5159c910160405180910390a1565b60065460009081904290610cbe90620151809060ff166113d0565b600554610ccb91906113bd565b6003549111915074010000000000000000000000000000000000000000900460ff168015610cf65750805b91505090565b60005473ffffffffffffffffffffffffffffffffffffffff163314610da3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b6000600455600380547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b60005473ffffffffffffffffffffffffffffffffffffffff163314610e79576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f54576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4f6e6c792074686520636f6e7472616374206f776e6572206d6179207065726660448201527f6f726d207468697320616374696f6e00000000000000000000000000000000006064820152608401610468565b600a80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b600354604080517f313ce567000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163313ce5679160048083019260209291908290030181865afa15801561100b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061102f919061140d565b61103a90600a61154a565b61104790620f42406113d0565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d8919061140d565b6110e390600a61154a565b6110ed84866113d0565b6110f791906113d0565b6111019190611559565b90505b92915050565b6040805173ffffffffffffffffffffffffffffffffffffffff85811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f23b872dd0000000000000000000000000000000000000000000000000000000017905291516000928392908816916111a99190611594565b6000604051808303816000865af19150503d80600081146111e6576040519150601f19603f3d011682016040523d82523d6000602084013e6111eb565b606091505b509150915081801561121557508051158061121557508080602001905181019061121591906115c3565b6112a0576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f5472616e7366657248656c7065723a205452414e534645525f46524f4d5f464160448201527f494c4544000000000000000000000000000000000000000000000000000000006064820152608401610468565b505050505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146112cc57600080fd5b919050565b6000602082840312156112e357600080fd5b611101826112a8565b6000602082840312156112fe57600080fd5b5035919050565b6000806040838503121561131857600080fd5b611321836112a8565b946020939093013593505050565b60ff8116811461027057600080fd5b60006020828403121561135057600080fd5b813561135b8161132f565b9392505050565b60006020828403121561137457600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b818103818111156111045761110461137b565b808201808211156111045761110461137b565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156114085761140861137b565b500290565b60006020828403121561141f57600080fd5b815161135b8161132f565b600181815b8085111561148357817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156114695761146961137b565b8085161561147657918102915b93841c939080029061142f565b509250929050565b60008261149a57506001611104565b816114a757506000611104565b81600181146114bd57600281146114c7576114e3565b6001915050611104565b60ff8411156114d8576114d861137b565b50506001821b611104565b5060208310610133831016604e8410600b8410161715611506575081810a611104565b611510838361142a565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156115425761154261137b565b029392505050565b600061110160ff84168361148b565b60008261158f577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000825160005b818110156115b5576020818601810151858301520161159b565b506000920191825250919050565b6000602082840312156115d557600080fd5b8151801515811461135b57600080fdfea2646970667358221220b0c8e77d5512d43e5175e91753eb4a3f62467c178edb80c26e61db672cb988ca64736f6c63430008100033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead00000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead000000000000000000000000464d64a24b56681022e4332ea047a03ebbda5a260000000000000000000000004dba82efd938f273c5b8ae6a66d745a48584e6360000000000000000000000009fd21be27a2b059a288229361e2fa632d8d2d074
-----Decoded View---------------
Arg [0] : _owner (address): 0x93aE1efd2E78028351C080FA0fbBBeF97Ec42EAD
Arg [1] : _wallet (address): 0x93aE1efd2E78028351C080FA0fbBBeF97Ec42EAD
Arg [2] : _stabilizer (address): 0x464D64a24B56681022e4332EA047A03ebbdA5a26
Arg [3] : _sweep_address (address): 0x4dba82EfD938f273C5b8aE6a66D745a48584e636
Arg [4] : _usdx_address (address): 0x9FD21bE27A2B059a288229361E2fA632D8D2d074
-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 00000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead
Arg [1] : 00000000000000000000000093ae1efd2e78028351c080fa0fbbbef97ec42ead
Arg [2] : 000000000000000000000000464d64a24b56681022e4332ea047a03ebbda5a26
Arg [3] : 0000000000000000000000004dba82efd938f273c5b8ae6a66d745a48584e636
Arg [4] : 0000000000000000000000009fd21be27a2b059a288229361e2fa632d8d2d074
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.