Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
Vault
Compiler Version
v0.5.16+commit.9c3226ce
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
pragma solidity 0.5.16; import "@openzeppelin/contracts-ethereum-package/contracts/math/Math.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/math/SafeMath.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/token/ERC20/SafeERC20.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/token/ERC20/ERC20.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/token/ERC20/ERC20Detailed.sol"; import "@openzeppelin/contracts-ethereum-package/contracts/utils/ReentrancyGuard.sol"; import "./interfaces/IStrategy.sol"; import "./interfaces/IController.sol"; import "./interfaces/IVault.sol"; import "./interfaces/IUpgradeSource.sol"; import "./ControllableInit.sol"; import "./VaultStorage.sol"; contract Vault is ERC20, ERC20Detailed, IVault, IUpgradeSource, ControllableInit, VaultStorage, ReentrancyGuard { using SafeERC20 for IERC20; using Address for address; using SafeMath for uint256; event Withdraw(address indexed beneficiary, uint256 amount); event Deposit(address indexed beneficiary, uint256 amount); event Invest(uint256 amount); event StrategyAnnounced(address newStrategy, uint256 time); event StrategyChanged(address newStrategy, address oldStrategy); modifier whenStrategyDefined() { require(address(strategy()) != address(0), "Strategy must be defined"); _; } // Only smart contracts will be affected by this modifier modifier defense() { require( (msg.sender == tx.origin) || // If it is a normal user and not smart contract, // then the requirement will pass IController(controller()).whiteList(msg.sender), "Access denied for caller" ); _; } // the function is name differently to not cause inheritance clash in truffle and allows tests function initializeVault( address _storage, address _underlying, uint256 _toInvestNumerator, uint256 _toInvestDenominator, uint256 _maxDepositCap ) public initializer { require( _toInvestNumerator <= _toInvestDenominator, "cannot invest more than 100%" ); require(_toInvestDenominator != 0, "cannot divide by 0"); ERC20Detailed.initialize( string( abi.encodePacked("FORCE_", ERC20Detailed(_underlying).symbol()) ), string(abi.encodePacked("x", ERC20Detailed(_underlying).symbol())), ERC20Detailed(_underlying).decimals() ); ControllableInit.initialize(_storage); ReentrancyGuard.initialize(); uint256 underlyingUnit = 10**uint256(ERC20Detailed(address(_underlying)).decimals()); uint256 implementationDelay = 12 hours; uint256 strategyChangeDelay = 12 hours; VaultStorage.initialize( _underlying, _toInvestNumerator, _toInvestDenominator, underlyingUnit, _maxDepositCap, implementationDelay, strategyChangeDelay ); } function strategy() public view returns (address) { return _strategy(); } function underlying() public view returns (address) { return _underlying(); } function underlyingUnit() public view returns (uint256) { return _underlyingUnit(); } function vaultFractionToInvestNumerator() public view returns (uint256) { return _vaultFractionToInvestNumerator(); } function vaultFractionToInvestDenominator() public view returns (uint256) { return _vaultFractionToInvestDenominator(); } function totalDeposits() public view returns (uint256) { return _totalDeposits(); } function maxDepositCap() public view returns (uint256) { return _maxDepositCap(); } function nextImplementation() public view returns (address) { return _nextImplementation(); } function nextImplementationTimestamp() public view returns (uint256) { return _nextImplementationTimestamp(); } function nextImplementationDelay() public view returns (uint256) { return _nextImplementationDelay(); } /** * Chooses the best strategy and re-invests. If the strategy did not change, it just calls * forceUnleashed on the current strategy. Call this through controller to claim galactic rewards. */ function forceUnleashed() external whenStrategyDefined onlyControllerOrGovernance { // ensure that new funds are invested too invest(); IStrategy(strategy()).forceUnleashed(); } /* * Returns the cash balance across all users in this contract. */ function underlyingBalanceInVault() public view returns (uint256) { return IERC20(underlying()).balanceOf(address(this)); } /* Returns the current underlying (e.g., DAI's) balance together with * the invested amount (if DAI is invested elsewhere by the strategy). */ function underlyingBalanceWithInvestment() public view returns (uint256) { if (address(strategy()) == address(0)) { // initial state, when not set return underlyingBalanceInVault(); } return underlyingBalanceInVault().add( IStrategy(strategy()).investedUnderlyingBalance() ); } function getPricePerFullShare() public view returns (uint256) { return totalSupply() == 0 ? underlyingUnit() : underlyingUnit().mul(underlyingBalanceWithInvestment()).div( totalSupply() ); } /* get the user's share (in underlying) */ function underlyingBalanceWithInvestmentForHolder(address holder) external view returns (uint256) { if (totalSupply() == 0) { return 0; } return underlyingBalanceWithInvestment().mul(balanceOf(holder)).div( totalSupply() ); } function futureStrategy() public view returns (address) { return _futureStrategy(); } function strategyUpdateTime() public view returns (uint256) { return _strategyUpdateTime(); } function strategyTimeLock() public view returns (uint256) { return _strategyTimeLock(); } function canUpdateStrategy(address _strategy) public view returns (bool) { return strategy() == address(0) || // no strategy was set yet (_strategy == futureStrategy() && block.timestamp > strategyUpdateTime() && strategyUpdateTime() > 0); // or the timelock has passed } /** * Indicates that the strategy update will happen in the future */ function announceStrategyUpdate(address _strategy) public onlyControllerOrGovernance { // records a new timestamp uint256 when = block.timestamp.add(strategyTimeLock()); _setStrategyUpdateTime(when); _setFutureStrategy(_strategy); emit StrategyAnnounced(_strategy, when); } /** * Finalizes (or cancels) the strategy update by resetting the data */ function finalizeStrategyUpdate() public onlyControllerOrGovernance { _setStrategyUpdateTime(0); _setFutureStrategy(address(0)); } function setStrategy(address _strategy) public onlyControllerOrGovernance { require( canUpdateStrategy(_strategy), "The strategy exists and switch timelock did not elapse yet" ); require(_strategy != address(0), "new _strategy cannot be empty"); require( IStrategy(_strategy).underlying() == address(underlying()), "Vault underlying must match Strategy underlying" ); require( IStrategy(_strategy).vault() == address(this), "the strategy does not belong to this vault" ); emit StrategyChanged(_strategy, strategy()); if (address(_strategy) != address(strategy())) { if (address(strategy()) != address(0)) { // if the original strategy (no underscore) is defined IERC20(underlying()).safeApprove(address(strategy()), 0); IStrategy(strategy()).withdrawAllToVault(); } _setStrategy(_strategy); IERC20(underlying()).safeApprove(address(strategy()), 0); IERC20(underlying()).safeApprove(address(strategy()), uint256(~0)); } finalizeStrategyUpdate(); } function setVaultFractionToInvest(uint256 numerator, uint256 denominator) external onlyGovernance { require(denominator > 0, "denominator must be greater than 0"); require( numerator <= denominator, "denominator must be greater than or equal to the numerator" ); _setVaultFractionToInvestNumerator(numerator); _setVaultFractionToInvestDenominator(denominator); } function setMaxDepositCap(uint256 value) external onlyGovernance { return _setMaxDepositCap(value); } function rebalance() external onlyControllerOrGovernance { withdrawAll(); invest(); } function availableToInvestOut() public view returns (uint256) { uint256 wantInvestInTotal = underlyingBalanceWithInvestment() .mul(vaultFractionToInvestNumerator()) .div(vaultFractionToInvestDenominator()); uint256 alreadyInvested = IStrategy(strategy()).investedUnderlyingBalance(); if (alreadyInvested >= wantInvestInTotal) { return 0; } else { uint256 remainingToInvest = wantInvestInTotal.sub(alreadyInvested); return remainingToInvest <= underlyingBalanceInVault() // TODO: we think that the "else" branch of the ternary operation is not // going to get hit ? remainingToInvest : underlyingBalanceInVault(); } } function invest() internal whenStrategyDefined { uint256 availableAmount = availableToInvestOut(); if (availableAmount > 0) { IERC20(underlying()).safeTransfer( address(strategy()), availableAmount ); emit Invest(availableAmount); } } /* * Allows for depositing the underlying asset in exchange for shares. * Approval is assumed. */ function deposit(uint256 amount) external defense { _deposit(amount, msg.sender, msg.sender); } /* * Allows for depositing the underlying asset in exchange for shares * assigned to the holder. * This facilitates depositing for someone else (using DepositHelper) */ function depositFor(uint256 amount, address holder) public defense { _deposit(amount, msg.sender, holder); } function withdrawAll() public onlyControllerOrGovernance whenStrategyDefined { IStrategy(strategy()).withdrawAllToVault(); } function withdraw(uint256 numberOfShares) external defense nonReentrant { require(totalSupply() > 0, "Vault has no shares"); require(numberOfShares > 0, "numberOfShares must be greater than 0"); uint256 totalSupply = totalSupply(); _burn(msg.sender, numberOfShares); uint256 underlyingAmountToWithdraw = underlyingBalanceWithInvestment().mul(numberOfShares).div( totalSupply ); uint256 originalDepositsToWithdraw = _totalDeposits().mul(numberOfShares).div(totalSupply); if (underlyingAmountToWithdraw > underlyingBalanceInVault()) { // withdraw everything from the strategy to accurately check the share value if (numberOfShares == totalSupply) { IStrategy(strategy()).withdrawAllToVault(); } else { uint256 missing = underlyingAmountToWithdraw.sub(underlyingBalanceInVault()); IStrategy(strategy()).withdrawToVault(missing); } // recalculate to improve accuracy underlyingAmountToWithdraw = Math.min( underlyingBalanceWithInvestment().mul(numberOfShares).div( totalSupply ), underlyingBalanceInVault() ); } IERC20(underlying()).safeTransfer( msg.sender, underlyingAmountToWithdraw ); _setTotalDeposits(_totalDeposits().sub(originalDepositsToWithdraw)); // update the withdrawal amount for the holder emit Withdraw(msg.sender, underlyingAmountToWithdraw); } function _deposit( uint256 amount, address sender, address beneficiary ) internal nonReentrant { require(amount > 0, "Cannot deposit 0"); require(beneficiary != address(0), "holder must be defined"); require( maxDepositCap() == 0 || totalDeposits().add(amount) <= maxDepositCap(), "Cannot deposit more than cap" ); if (address(strategy()) != address(0)) { require(IStrategy(strategy()).depositArbCheck(), "Too much arb"); } uint256 toMint = totalSupply() == 0 ? amount : amount.mul(totalSupply()).div( underlyingBalanceWithInvestment() ); _mint(beneficiary, toMint); IERC20(underlying()).safeTransferFrom(sender, address(this), amount); _setTotalDeposits(_totalDeposits().add(amount)); // update the contribution amount for the beneficiary emit Deposit(beneficiary, amount); } /** * Schedules an upgrade for this vault's proxy. */ function scheduleUpgrade(address impl) public onlyGovernance { _setNextImplementation(impl); _setNextImplementationTimestamp( block.timestamp.add(nextImplementationDelay()) ); } function shouldUpgrade() external view returns (bool, address) { return ( nextImplementationTimestamp() != 0 && block.timestamp > nextImplementationTimestamp() && nextImplementation() != address(0), nextImplementation() ); } function finalizeUpgrade() external onlyGovernance { _setNextImplementation(address(0)); _setNextImplementationTimestamp(0); } }
pragma solidity 0.5.16; import "./GovernableInit.sol"; // A clone of Governable supporting the Initializable interface and pattern contract ControllableInit is GovernableInit { constructor() public {} function initialize(address _storage) public initializer { GovernableInit.initialize(_storage); } modifier onlyController() { require( Storage(_storage()).isController(msg.sender), "Not a controller" ); _; } modifier onlyControllerOrGovernance() { require( (Storage(_storage()).isController(msg.sender) || Storage(_storage()).isGovernance(msg.sender)), "The caller must be controller or governance" ); _; } function controller() public view returns (address) { return Storage(_storage()).controller(); } }
pragma solidity 0.5.16; import "@openzeppelin/upgrades/contracts/Initializable.sol"; import "./Storage.sol"; // A clone of Governable supporting the Initializable interface and pattern contract GovernableInit is Initializable { bytes32 internal constant _STORAGE_SLOT = 0xa7ec62784904ff31cbcc32d09932a58e7f1e4476e1d041995b37c917990b16dc; modifier onlyGovernance() { require(Storage(_storage()).isGovernance(msg.sender), "Not governance"); _; } constructor() public { assert( _STORAGE_SLOT == bytes32( uint256(keccak256("eip1967.governableInit.storage")) - 1 ) ); } function initialize(address _store) public initializer { _setStorage(_store); } function _setStorage(address newStorage) private { bytes32 slot = _STORAGE_SLOT; // solhint-disable-next-line no-inline-assembly assembly { sstore(slot, newStorage) } } function setStorage(address _store) public onlyGovernance { require(_store != address(0), "new storage shouldn't be empty"); _setStorage(_store); } function _storage() internal view returns (address str) { bytes32 slot = _STORAGE_SLOT; // solhint-disable-next-line no-inline-assembly assembly { str := sload(slot) } } function governance() public view returns (address) { return Storage(_storage()).governance(); } }
pragma solidity 0.5.16; contract Storage { address public governance; address public controller; constructor() public { governance = msg.sender; } modifier onlyGovernance() { require(isGovernance(msg.sender), "Not governance"); _; } function setGovernance(address _governance) public onlyGovernance { require(_governance != address(0), "new governance shouldn't be empty"); governance = _governance; } function setController(address _controller) public onlyGovernance { require(_controller != address(0), "new controller shouldn't be empty"); controller = _controller; } function isGovernance(address account) public view returns (bool) { return account == governance; } function isController(address account) public view returns (bool) { return account == controller; } }
pragma solidity 0.5.16; import "@openzeppelin/upgrades/contracts/Initializable.sol"; contract VaultStorage is Initializable { bytes32 internal constant _STRATEGY_SLOT = 0xf1a169aa0f736c2813818fdfbdc5755c31e0839c8f49831a16543496b28574ea; bytes32 internal constant _UNDERLYING_SLOT = 0x1994607607e11d53306ef62e45e3bd85762c58d9bf38b5578bc4a258a26a7371; bytes32 internal constant _UNDERLYING_UNIT_SLOT = 0xa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff; bytes32 internal constant _VAULT_FRACTION_TO_INVEST_NUMERATOR_SLOT = 0x39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a; bytes32 internal constant _VAULT_FRACTION_TO_INVEST_DENOMINATOR_SLOT = 0x469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed32308; bytes32 internal constant _NEXT_IMPLEMENTATION_SLOT = 0xb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df; bytes32 internal constant _NEXT_IMPLEMENTATION_TIMESTAMP_SLOT = 0x3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c9; bytes32 internal constant _NEXT_IMPLEMENTATION_DELAY_SLOT = 0x82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf0; bytes32 internal constant _STRATEGY_TIME_LOCK_SLOT = 0x6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b; bytes32 internal constant _FUTURE_STRATEGY_SLOT = 0xb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc8590610; bytes32 internal constant _STRATEGY_UPDATE_TIME_SLOT = 0x56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e72; bytes32 internal constant _TOTAL_DEPOSITS = 0xaf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef213; bytes32 internal constant _MAX_DEPOSIT_CAP = 0x0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e28; constructor() public { assert( _STRATEGY_SLOT == bytes32(uint256(keccak256("eip1967.vaultStorage.strategy")) - 1) ); assert( _UNDERLYING_SLOT == bytes32( uint256(keccak256("eip1967.vaultStorage.underlying")) - 1 ) ); assert( _UNDERLYING_UNIT_SLOT == bytes32( uint256(keccak256("eip1967.vaultStorage.underlyingUnit")) - 1 ) ); assert( _VAULT_FRACTION_TO_INVEST_NUMERATOR_SLOT == bytes32( uint256( keccak256( "eip1967.vaultStorage.vaultFractionToInvestNumerator" ) ) - 1 ) ); assert( _VAULT_FRACTION_TO_INVEST_DENOMINATOR_SLOT == bytes32( uint256( keccak256( "eip1967.vaultStorage.vaultFractionToInvestDenominator" ) ) - 1 ) ); assert( _NEXT_IMPLEMENTATION_SLOT == bytes32( uint256( keccak256("eip1967.vaultStorage.nextImplementation") ) - 1 ) ); assert( _NEXT_IMPLEMENTATION_TIMESTAMP_SLOT == bytes32( uint256( keccak256( "eip1967.vaultStorage.nextImplementationTimestamp" ) ) - 1 ) ); assert( _NEXT_IMPLEMENTATION_DELAY_SLOT == bytes32( uint256( keccak256( "eip1967.vaultStorage.nextImplementationDelay" ) ) - 1 ) ); assert( _STRATEGY_TIME_LOCK_SLOT == bytes32( uint256( keccak256("eip1967.vaultStorage.strategyTimeLock") ) - 1 ) ); assert( _FUTURE_STRATEGY_SLOT == bytes32( uint256(keccak256("eip1967.vaultStorage.futureStrategy")) - 1 ) ); assert( _STRATEGY_UPDATE_TIME_SLOT == bytes32( uint256( keccak256("eip1967.vaultStorage.strategyUpdateTime") ) - 1 ) ); assert( _TOTAL_DEPOSITS == bytes32( uint256(keccak256("eip1967.vaultStorage.totalDeposits")) - 1 ) ); assert( _MAX_DEPOSIT_CAP == bytes32( uint256(keccak256("eip1967.vaultStorage.maxDepositCap")) - 1 ) ); } function initialize( address _underlying, uint256 _toInvestNumerator, uint256 _toInvestDenominator, uint256 _underlyingUnit, uint256 _maxDepositCap_, uint256 _implementationChangeDelay, uint256 _strategyChangeDelay ) public initializer { _setUnderlying(_underlying); _setVaultFractionToInvestNumerator(_toInvestNumerator); _setVaultFractionToInvestDenominator(_toInvestDenominator); _setMaxDepositCap(_maxDepositCap_); _setUnderlyingUnit(_underlyingUnit); _setNextImplementationDelay(_implementationChangeDelay); _setStrategyTimeLock(_strategyChangeDelay); _setStrategyUpdateTime(0); _setFutureStrategy(address(0)); } function _setStrategy(address _address) internal { setAddress(_STRATEGY_SLOT, _address); } function _strategy() internal view returns (address) { return getAddress(_STRATEGY_SLOT); } function _setUnderlying(address _address) internal { setAddress(_UNDERLYING_SLOT, _address); } function _underlying() internal view returns (address) { return getAddress(_UNDERLYING_SLOT); } function _setUnderlyingUnit(uint256 _value) internal { setUint256(_UNDERLYING_UNIT_SLOT, _value); } function _underlyingUnit() internal view returns (uint256) { return getUint256(_UNDERLYING_UNIT_SLOT); } function _setVaultFractionToInvestNumerator(uint256 _value) internal { setUint256(_VAULT_FRACTION_TO_INVEST_NUMERATOR_SLOT, _value); } function _vaultFractionToInvestNumerator() internal view returns (uint256) { return getUint256(_VAULT_FRACTION_TO_INVEST_NUMERATOR_SLOT); } function _setVaultFractionToInvestDenominator(uint256 _value) internal { setUint256(_VAULT_FRACTION_TO_INVEST_DENOMINATOR_SLOT, _value); } function _vaultFractionToInvestDenominator() internal view returns (uint256) { return getUint256(_VAULT_FRACTION_TO_INVEST_DENOMINATOR_SLOT); } function _setTotalDeposits(uint256 _value) internal { setUint256(_TOTAL_DEPOSITS, _value); } function _totalDeposits() internal view returns (uint256) { return getUint256(_TOTAL_DEPOSITS); } function _setMaxDepositCap(uint256 _value) internal { setUint256(_MAX_DEPOSIT_CAP, _value); } function _maxDepositCap() internal view returns (uint256) { return getUint256(_MAX_DEPOSIT_CAP); } function _setNextImplementation(address _address) internal { setAddress(_NEXT_IMPLEMENTATION_SLOT, _address); } function _nextImplementation() internal view returns (address) { return getAddress(_NEXT_IMPLEMENTATION_SLOT); } function _setNextImplementationTimestamp(uint256 _value) internal { setUint256(_NEXT_IMPLEMENTATION_TIMESTAMP_SLOT, _value); } function _nextImplementationTimestamp() internal view returns (uint256) { return getUint256(_NEXT_IMPLEMENTATION_TIMESTAMP_SLOT); } function _setNextImplementationDelay(uint256 _value) internal { setUint256(_NEXT_IMPLEMENTATION_DELAY_SLOT, _value); } function _nextImplementationDelay() internal view returns (uint256) { return getUint256(_NEXT_IMPLEMENTATION_DELAY_SLOT); } function _setStrategyTimeLock(uint256 _value) internal { setUint256(_STRATEGY_TIME_LOCK_SLOT, _value); } function _strategyTimeLock() internal view returns (uint256) { return getUint256(_STRATEGY_TIME_LOCK_SLOT); } function _setFutureStrategy(address _value) internal { setAddress(_FUTURE_STRATEGY_SLOT, _value); } function _futureStrategy() internal view returns (address) { return getAddress(_FUTURE_STRATEGY_SLOT); } function _setStrategyUpdateTime(uint256 _value) internal { setUint256(_STRATEGY_UPDATE_TIME_SLOT, _value); } function _strategyUpdateTime() internal view returns (uint256) { return getUint256(_STRATEGY_UPDATE_TIME_SLOT); } function setAddress(bytes32 slot, address _address) private { // solhint-disable-next-line no-inline-assembly assembly { sstore(slot, _address) } } function setUint256(bytes32 slot, uint256 _value) private { // solhint-disable-next-line no-inline-assembly assembly { sstore(slot, _value) } } function getAddress(bytes32 slot) private view returns (address str) { // solhint-disable-next-line no-inline-assembly assembly { str := sload(slot) } } function getUint256(bytes32 slot) private view returns (uint256 str) { // solhint-disable-next-line no-inline-assembly assembly { str := sload(slot) } } uint256[50] private ______gap; }
pragma solidity 0.5.16; interface IController { function whiteList(address _target) external view returns (bool); function addVaultAndStrategy(address _vault, address _strategy) external; function forceUnleashed(address _vault) external; function hasVault(address _vault) external returns (bool); function salvage(address _token, uint256 amount) external; function salvageStrategy( address _strategy, address _token, uint256 amount ) external; function notifyFee(address _underlying, uint256 fee) external; function profitSharingNumerator() external view returns (uint256); function profitSharingDenominator() external view returns (uint256); function treasury() external view returns (address); }
pragma solidity 0.5.16; interface IStrategy { function unsalvagableTokens(address tokens) external view returns (bool); function governance() external view returns (address); function controller() external view returns (address); function underlying() external view returns (address); function vault() external view returns (address); function withdrawAllToVault() external; function withdrawToVault(uint256 amount) external; function investedUnderlyingBalance() external view returns (uint256); // itsNotMuch() // should only be called by controller function salvage( address recipient, address token, uint256 amount ) external; function forceUnleashed() external; function depositArbCheck() external view returns (bool); }
pragma solidity 0.5.16; interface IUpgradeSource { function shouldUpgrade() external view returns (bool, address); function finalizeUpgrade() external; }
pragma solidity 0.5.16; interface IVault { function underlyingBalanceInVault() external view returns (uint256); function underlyingBalanceWithInvestment() external view returns (uint256); function governance() external view returns (address); function controller() external view returns (address); function underlying() external view returns (address); function strategy() external view returns (address); function setStrategy(address _strategy) external; function setVaultFractionToInvest(uint256 numerator, uint256 denominator) external; function deposit(uint256 amountWei) external; function depositFor(uint256 amountWei, address holder) external; function withdrawAll() external; function withdraw(uint256 numberOfShares) external; function getPricePerFullShare() external view returns (uint256); function underlyingBalanceWithInvestmentForHolder(address holder) external view returns (uint256); // force unleash should be callable only by the controller (by the force unleasher) or by governance function forceUnleashed() external; function rebalance() external; }
pragma solidity ^0.5.0; import "@openzeppelin/upgrades/contracts/Initializable.sol"; /* * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with GSN meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ contract Context is Initializable { // Empty internal constructor, to prevent people from mistakenly deploying // an instance of this contract, which should be used via inheritance. constructor () internal { } // solhint-disable-previous-line no-empty-blocks function _msgSender() internal view returns (address payable) { return msg.sender; } function _msgData() internal view returns (bytes memory) { this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691 return msg.data; } }
pragma solidity ^0.5.0; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { /** * @dev Returns the largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return a >= b ? a : b; } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return a < b ? a : b; } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow, so we distribute return (a / 2) + (b / 2) + ((a % 2 + b % 2) / 2); } }
pragma solidity ^0.5.0; /** * @dev Wrappers over Solidity's arithmetic operations with added overflow * checks. * * Arithmetic operations in Solidity wrap on overflow. This can easily result * in bugs, because programmers usually assume that an overflow raises an * error, which is the standard behavior in high level programming languages. * `SafeMath` restores this intuition by reverting the transaction when an * operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { uint256 c = a + b; require(c >= a, "SafeMath: addition overflow"); return c; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return sub(a, b, "SafeMath: subtraction overflow"); } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * - Subtraction cannot overflow. * * _Available since v2.4.0._ */ function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b <= a, errorMessage); uint256 c = a - b; return c; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) { return 0; } uint256 c = a * b; require(c / a == b, "SafeMath: multiplication overflow"); return c; } /** * @dev Returns the integer division of two unsigned integers. Reverts on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return div(a, b, "SafeMath: division by zero"); } /** * @dev Returns the integer division of two unsigned integers. Reverts with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. * * _Available since v2.4.0._ */ function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { // Solidity only automatically asserts when dividing by 0 require(b > 0, errorMessage); uint256 c = a / b; // assert(a == b * c + a % b); // There is no case in which this doesn't hold return c; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return mod(a, b, "SafeMath: modulo by zero"); } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * Reverts with custom message when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * - The divisor cannot be zero. * * _Available since v2.4.0._ */ function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) { require(b != 0, errorMessage); return a % b; } }
pragma solidity ^0.5.0; import "@openzeppelin/upgrades/contracts/Initializable.sol"; import "../../GSN/Context.sol"; import "./IERC20.sol"; import "../../math/SafeMath.sol"; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20Mintable}. * * TIP: For a detailed writeup see our guide * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * * We have followed general OpenZeppelin guidelines: functions revert instead * of returning `false` on failure. This behavior is nonetheless conventional * and does not conflict with the expectations of ERC20 applications. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to reconstruct the allowance for all accounts just * by listening to said events. Other implementations of the EIP may not emit * these events, as it isn't required by the specification. * * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ contract ERC20 is Initializable, Context, IERC20 { using SafeMath for uint256; mapping (address => uint256) private _balances; mapping (address => mapping (address => uint256)) private _allowances; uint256 private _totalSupply; /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view returns (uint256) { return _balances[account]; } /** * @dev See {IERC20-transfer}. * * Requirements: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address recipient, uint256 amount) public returns (bool) { _transfer(_msgSender(), recipient, amount); return true; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public returns (bool) { _approve(_msgSender(), spender, amount); return true; } /** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}; * * Requirements: * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. * - the caller must have allowance for `sender`'s tokens of at least * `amount`. */ function transferFrom(address sender, address recipient, uint256 amount) public returns (bool) { _transfer(sender, recipient, amount); _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance")); return true; } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. */ function increaseAllowance(address spender, uint256 addedValue) public returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue)); return true; } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least * `subtractedValue`. */ function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero")); return true; } /** * @dev Moves tokens `amount` from `sender` to `recipient`. * * This is internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * * Requirements: * * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */ function _transfer(address sender, address recipient, uint256 amount) internal { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance"); _balances[recipient] = _balances[recipient].add(amount); emit Transfer(sender, recipient, amount); } /** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements * * - `to` cannot be the zero address. */ function _mint(address account, uint256 amount) internal { require(account != address(0), "ERC20: mint to the zero address"); _totalSupply = _totalSupply.add(amount); _balances[account] = _balances[account].add(amount); emit Transfer(address(0), account, amount); } /** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */ function _burn(address account, uint256 amount) internal { require(account != address(0), "ERC20: burn from the zero address"); _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance"); _totalSupply = _totalSupply.sub(amount); emit Transfer(account, address(0), amount); } /** * @dev Sets `amount` as the allowance of `spender` over the `owner`s tokens. * * This is internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ function _approve(address owner, address spender, uint256 amount) internal { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amount); } /** * @dev Destroys `amount` tokens from `account`.`amount` is then deducted * from the caller's allowance. * * See {_burn} and {_approve}. */ function _burnFrom(address account, uint256 amount) internal { _burn(account, amount); _approve(account, _msgSender(), _allowances[account][_msgSender()].sub(amount, "ERC20: burn amount exceeds allowance")); } uint256[50] private ______gap; }
pragma solidity ^0.5.0; import "@openzeppelin/upgrades/contracts/Initializable.sol"; import "./IERC20.sol"; /** * @dev Optional functions from the ERC20 standard. */ contract ERC20Detailed is Initializable, IERC20 { string private _name; string private _symbol; uint8 private _decimals; /** * @dev Sets the values for `name`, `symbol`, and `decimals`. All three of * these values are immutable: they can only be set once during * construction. */ function initialize(string memory name, string memory symbol, uint8 decimals) public initializer { _name = name; _symbol = symbol; _decimals = decimals; } /** * @dev Returns the name of the token. */ function name() public view returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view returns (string memory) { return _symbol; } /** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5,05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ function decimals() public view returns (uint8) { return _decimals; } uint256[50] private ______gap; }
pragma solidity ^0.5.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. Does not include * the optional functions; to access them see {ERC20Detailed}. */ interface IERC20 { /** * @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 `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, 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 `sender` to `recipient` 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 sender, address recipient, uint256 amount) external returns (bool); /** * @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); }
pragma solidity ^0.5.0; import "./IERC20.sol"; import "../../math/SafeMath.sol"; import "../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using SafeMath for uint256; using Address for address; function safeTransfer(IERC20 token, address to, uint256 value) internal { callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } function safeApprove(IERC20 token, address spender, uint256 value) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' // solhint-disable-next-line max-line-length require((value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).add(value); callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal { uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero"); callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } /** * @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. // A Solidity high level call has three parts: // 1. The target address is checked to verify it contains contract code // 2. The call itself is made, and success asserted // 3. The return value is decoded, which in turn checks the size of the returned data. // solhint-disable-next-line max-line-length require(address(token).isContract(), "SafeERC20: call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = address(token).call(data); require(success, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional // solhint-disable-next-line max-line-length require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
pragma solidity ^0.5.5; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ 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); } /** * @dev Converts an `address` into `address payable`. Note that this is * simply a type cast: the actual underlying value is not changed. * * _Available since v2.4.0._ */ function toPayable(address account) internal pure returns (address payable) { return address(uint160(account)); } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. * * _Available since v2.4.0._ */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); // solhint-disable-next-line avoid-call-value (bool success, ) = recipient.call.value(amount)(""); require(success, "Address: unable to send value, recipient may have reverted"); } }
pragma solidity ^0.5.0; import "@openzeppelin/upgrades/contracts/Initializable.sol"; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. */ contract ReentrancyGuard is Initializable { // counter to allow mutex lock with only one SSTORE operation uint256 private _guardCounter; function initialize() public initializer { // The counter starts at one to prevent changing it from zero to a non-zero // value, which is a more expensive operation. _guardCounter = 1; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and make it call a * `private` function that does the actual work. */ modifier nonReentrant() { _guardCounter += 1; uint256 localCounter = _guardCounter; _; require(localCounter == _guardCounter, "ReentrancyGuard: reentrant call"); } uint256[50] private ______gap; }
pragma solidity >=0.4.24 <0.7.0; /** * @title Initializable * * @dev Helper contract to support initializer functions. To use it, replace * the constructor with a function that has the `initializer` modifier. * WARNING: Unlike constructors, initializer functions must be manually * invoked. This applies both to deploying an Initializable contract, as well * as extending an Initializable contract via inheritance. * WARNING: When used with inheritance, manual care must be taken to not invoke * a parent initializer twice, or ensure that all initializers are idempotent, * because this is not dealt with automatically as with constructors. */ contract Initializable { /** * @dev Indicates that the contract has been initialized. */ bool private initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private initializing; /** * @dev Modifier to use in the initializer function of a contract. */ modifier initializer() { require(initializing || isConstructor() || !initialized, "Contract instance has already been initialized"); bool isTopLevelCall = !initializing; if (isTopLevelCall) { initializing = true; initialized = true; } _; if (isTopLevelCall) { initializing = false; } } /// @dev Returns true if and only if the function is running in the constructor function isConstructor() private view returns (bool) { // extcodesize checks the size of the code stored in an address, and // address returns the current address. Since the code is still not // deployed when running a constructor, any checks on its code size will // yield zero, making it an effective way to detect if a contract is // under construction or not. address self = address(this); uint256 cs; assembly { cs := extcodesize(self) } return cs == 0; } // Reserved storage space to allow for layout changes in the future. uint256[50] private ______gap; }
{ "remappings": [], "optimizer": { "enabled": true, "runs": 200 }, "evmVersion": "istanbul", "libraries": {}, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beneficiary","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Invest","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newStrategy","type":"address"},{"indexed":false,"internalType":"uint256","name":"time","type":"uint256"}],"name":"StrategyAnnounced","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newStrategy","type":"address"},{"indexed":false,"internalType":"address","name":"oldStrategy","type":"address"}],"name":"StrategyChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beneficiary","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"constant":true,"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"announceStrategyUpdate","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"availableToInvestOut","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"canUpdateStrategy","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"controller","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"deposit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"holder","type":"address"}],"name":"depositFor","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"finalizeStrategyUpdate","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"finalizeUpgrade","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"forceUnleashed","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"futureStrategy","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getPricePerFullShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"governance","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"uint8","name":"decimals","type":"uint8"}],"name":"initialize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"initialize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_underlying","type":"address"},{"internalType":"uint256","name":"_toInvestNumerator","type":"uint256"},{"internalType":"uint256","name":"_toInvestDenominator","type":"uint256"},{"internalType":"uint256","name":"_underlyingUnit","type":"uint256"},{"internalType":"uint256","name":"_maxDepositCap_","type":"uint256"},{"internalType":"uint256","name":"_implementationChangeDelay","type":"uint256"},{"internalType":"uint256","name":"_strategyChangeDelay","type":"uint256"}],"name":"initialize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_storage","type":"address"}],"name":"initialize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_storage","type":"address"},{"internalType":"address","name":"_underlying","type":"address"},{"internalType":"uint256","name":"_toInvestNumerator","type":"uint256"},{"internalType":"uint256","name":"_toInvestDenominator","type":"uint256"},{"internalType":"uint256","name":"_maxDepositCap","type":"uint256"}],"name":"initializeVault","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"maxDepositCap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"nextImplementation","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"nextImplementationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"nextImplementationTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"rebalance","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"impl","type":"address"}],"name":"scheduleUpgrade","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"setMaxDepositCap","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_store","type":"address"}],"name":"setStorage","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"setStrategy","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"setVaultFractionToInvest","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"shouldUpgrade","outputs":[{"internalType":"bool","name":"","type":"bool"},{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"strategy","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"strategyTimeLock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"strategyUpdateTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalDeposits","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"underlying","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"underlyingBalanceInVault","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"underlyingBalanceWithInvestment","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"holder","type":"address"}],"name":"underlyingBalanceWithInvestmentForHolder","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"underlyingUnit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vaultFractionToInvestDenominator","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vaultFractionToInvestNumerator","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"numberOfShares","type":"uint256"}],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"withdrawAll","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
608060408190527f656970313936372e7661756c7453746f726167652e756e6465726c79696e6700815260019080602362004d3b82396023019050604051809103902060001c0360001b7fa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff60001b146200007557fe5b6001604051808062004c2b603391396033019050604051809103902060001c0360001b7f39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a60001b14620000c457fe5b6001604051808062004c8e603591396035019050604051809103902060001c0360001b7f469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed3230860001b146200011357fe5b6001604051808062004d80602791396027019050604051809103902060001c0360001b7fb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df60001b146200016257fe5b6001604051808062004c5e603091396030019050604051809103902060001c0360001b7f3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c960001b14620001b157fe5b6001604051808062004d0f602c9139602c019050604051809103902060001c0360001b7f82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf060001b146200020057fe5b6001604051808062004cea602591396025019050604051809103902060001c0360001b7f6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b60001b146200024f57fe5b6001604051808062004da7602391396023019050604051809103902060001c0360001b7fb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc859061060001b146200029e57fe5b6001604051808062004cc3602791396027019050604051809103902060001c0360001b7f56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e7260001b14620002ed57fe5b6001604051808062004d5e602291396022019050604051809103902060001c0360001b7faf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef21360001b146200033c57fe5b6001604051808062004c09602291396022019050604051809103902060001c0360001b7f0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e2860001b146200038b57fe5b61486e806200039b6000396000f3fe608060405234801561001057600080fd5b506004361061030c5760003560e01c80638142951a1161019d578063a9059cbb116100e9578063cca7f475116100a2578063eda199aa1161007c578063eda199aa14610959578063f0cf91e714610961578063f2768c1e14610987578063f77c47911461098f5761030c565b8063cca7f47514610906578063dd62ed3e1461090e578063dfed91601461093c5761030c565b8063a9059cbb1461087f578063aa044625146108ab578063b592c390146108b3578063b6b55f25146108bb578063c2baf356146108d8578063c4d66de8146108e05761030c565b806395d89b4111610156578063a457c2d711610130578063a457c2d714610820578063a5b1a24d1461084c578063a83656931461086f578063a8c62e76146108775761030c565b806395d89b41146107e55780639a508c8e146107ed5780639d16acfd146107f55761030c565b80638142951a1461073757806382de9c1b14610781578063853828b6146107895780638cb1d67f146107915780639137c1a7146107b75780639546cc53146107dd5761030c565b806336efd16f1161025c5780635fe51e6d1161021557806377c7b8fc116101ef57806377c7b8fc146107175780637d7c2a1c1461071f5780637d882097146107275780638129fc1c1461072f5761030c565b80635fe51e6d146106e15780636f307dc3146106e957806370a08231146106f15761030c565b806336efd16f1461062f578063395093511461065b5780634af1758b146106875780635392db601461068f57806353ceb01c146106d15780635aa6e675146106d95761030c565b80631624f6c6116102c957806323b872dd116102a357806323b872dd146105985780632e1a7d4d146105ce578063313ce567146105eb57806333a100ca146106095761030c565b80631624f6c61461045a57806318160ddd146105885780631bf8e7be146105905761030c565b806306fdde0314610311578063095ea7b31461038e57806309ff18f0146103ce5780630a6bbeb3146103f25780630ad2239d1461041a5780630c80447a14610434575b600080fd5b610319610997565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561035357818101518382015260200161033b565b50505050905090810190601f1680156103805780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103ba600480360360408110156103a457600080fd5b506001600160a01b038135169060200135610a2e565b604080519115158252519081900360200190f35b6103d6610a4c565b604080516001600160a01b039092168252519081900360200190f35b6104186004803603602081101561040857600080fd5b50356001600160a01b0316610a5b565b005b610422610c25565b60408051918252519081900360200190f35b6104186004803603602081101561044a57600080fd5b50356001600160a01b0316610c2f565b6104186004803603606081101561047057600080fd5b810190602081018135600160201b81111561048a57600080fd5b82018360208201111561049c57600080fd5b803590602001918460018302840111600160201b831117156104bd57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295949360208101935035915050600160201b81111561050f57600080fd5b82018360208201111561052157600080fd5b803590602001918460018302840111600160201b8311171561054257600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505050903560ff169150610d199050565b610422610df5565b610422610dfb565b6103ba600480360360608110156105ae57600080fd5b506001600160a01b03813581169160208101359091169060400135610ea7565b610418600480360360208110156105e457600080fd5b5035610f34565b6105f36112f7565b6040805160ff9092168252519081900360200190f35b6104186004803603602081101561061f57600080fd5b50356001600160a01b0316611300565b6104186004803603604081101561064557600080fd5b50803590602001356001600160a01b03166117a1565b6103ba6004803603604081101561067157600080fd5b506001600160a01b03813516906020013561188b565b6104226118df565b610418600480360360a08110156106a557600080fd5b506001600160a01b038135811691602081013590911690604081013590606081013590608001356118e9565b610422611e60565b6103d6611e6a565b6103d6611edd565b6103d6611ee7565b6104226004803603602081101561070757600080fd5b50356001600160a01b0316611ef1565b610422611f10565b610418611f4a565b6104226120b0565b6104186120ba565b610418600480360360e081101561074d57600080fd5b506001600160a01b038135169060208101359060408101359060608101359060808101359060a08101359060c00135612160565b61042261225c565b610418612266565b610422600480360360208110156107a757600080fd5b50356001600160a01b0316612471565b610418600480360360208110156107cd57600080fd5b50356001600160a01b03166124a6565b6104226125d5565b6103196125df565b610418612640565b6107fd61271f565b6040805192151583526001600160a01b0390911660208301528051918290030190f35b6103ba6004803603604081101561083657600080fd5b506001600160a01b03813516906020013561276b565b6104186004803603604081101561086257600080fd5b50803590602001356127d9565b610422612934565b6103d661293e565b6103ba6004803603604081101561089557600080fd5b506001600160a01b038135169060200135612948565b61042261295c565b610422612966565b610418600480360360208110156108d157600080fd5b5035612a3f565b610422612b29565b610418600480360360208110156108f657600080fd5b50356001600160a01b0316612b88565b610418612c33565b6104226004803603604081101561092457600080fd5b506001600160a01b0381358116916020013516612e32565b6104186004803603602081101561095257600080fd5b5035612e5d565b610418612f31565b6103ba6004803603602081101561097757600080fd5b50356001600160a01b0316613099565b6104226130fa565b6103d6613104565b60688054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610a235780601f106109f857610100808354040283529160200191610a23565b820191906000526020600020905b815481529060010190602001808311610a0657829003601f168201915b505050505090505b90565b6000610a42610a3b613146565b848461314a565b5060015b92915050565b6000610a56613236565b905090565b610a63613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610ab857600080fd5b505afa158015610acc573d6000803e3d6000fd5b505050506040513d6020811015610ae257600080fd5b505180610b745750610af2613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610b4757600080fd5b505afa158015610b5b573d6000803e3d6000fd5b505050506040513d6020811015610b7157600080fd5b50515b610baf5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b6000610bc9610bbc610c25565b429063ffffffff61328616565b9050610bd4816132e7565b610bdd82613311565b604080516001600160a01b03841681526020810183905281517f7d5e1cfe55788983acd19d248da36a27c9413e8e43445ed36a76ae0e741a04ed929181900390910190a15050565b6000610a5661333b565b610c37613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610c8c57600080fd5b505afa158015610ca0573d6000803e3d6000fd5b505050506040513d6020811015610cb657600080fd5b5051610cfa576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b610d0381613366565b610d16610d11610bbc612934565b613390565b50565b600054610100900460ff1680610d325750610d326133ba565b80610d40575060005460ff16155b610d7b5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015610da6576000805460ff1961ff0019909116610100171660011790555b8351610db990606890602087019061446f565b508251610dcd90606990602086019061446f565b50606a805460ff191660ff84161790558015610def576000805461ff00191690555b50505050565b60355490565b600080610e0661293e565b6001600160a01b03161415610e2457610e1d612b29565b9050610a2b565b610a56610e2f61293e565b6001600160a01b03166345d01e4a6040518163ffffffff1660e01b815260040160206040518083038186803b158015610e6757600080fd5b505afa158015610e7b573d6000803e3d6000fd5b505050506040513d6020811015610e9157600080fd5b5051610e9b612b29565b9063ffffffff61328616565b6000610eb48484846133c0565b610f2a84610ec0613146565b610f2585604051806060016040528060288152602001614696602891396001600160a01b038a16600090815260346020526040812090610efe613146565b6001600160a01b03168152602081019190915260400160002054919063ffffffff61351e16565b61314a565b5060019392505050565b33321480610fc75750610f45613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610f9a57600080fd5b505afa158015610fae573d6000803e3d6000fd5b505050506040513d6020811015610fc457600080fd5b50515b611013576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b60cf8054600101908190556000611028610df5565b11611070576040805162461bcd60e51b81526020600482015260136024820152725661756c7420686173206e6f2073686172657360681b604482015290519081900360640190fd5b600082116110af5760405162461bcd60e51b81526004018080602001828103825260258152602001806147266025913960400191505060405180910390fd5b60006110b9610df5565b90506110c533846135b5565b60006110ef826110e3866110d7610dfb565b9063ffffffff6136b116565b9063ffffffff61370a16565b90506000611103836110e3876110d761374c565b905061110d612b29565b821115611221578285141561117b5761112461293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561115e57600080fd5b505af1158015611172573d6000803e3d6000fd5b505050506111fe565b6000611195611188612b29565b849063ffffffff61377716565b905061119f61293e565b6001600160a01b031663ce8c42e8826040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156111e457600080fd5b505af11580156111f8573d6000803e3d6000fd5b50505050505b61121e611211846110e3886110d7610dfb565b611219612b29565b6137b9565b91505b611244338361122e611ee7565b6001600160a01b0316919063ffffffff6137cf16565b61126461125f8261125361374c565b9063ffffffff61377716565b613826565b60408051838152905133917f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364919081900360200190a250505060cf5481146112f3576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b5050565b606a5460ff1690565b611308613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561135d57600080fd5b505afa158015611371573d6000803e3d6000fd5b505050506040513d602081101561138757600080fd5b5051806114195750611397613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156113ec57600080fd5b505afa158015611400573d6000803e3d6000fd5b505050506040513d602081101561141657600080fd5b50515b6114545760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b61145d81613099565b6114985760405162461bcd60e51b815260040180806020018281038252603a8152602001806146ec603a913960400191505060405180910390fd5b6001600160a01b0381166114f3576040805162461bcd60e51b815260206004820152601d60248201527f6e6577205f73747261746567792063616e6e6f7420626520656d707479000000604482015290519081900360640190fd5b6114fb611ee7565b6001600160a01b0316816001600160a01b0316636f307dc36040518163ffffffff1660e01b815260040160206040518083038186803b15801561153d57600080fd5b505afa158015611551573d6000803e3d6000fd5b505050506040513d602081101561156757600080fd5b50516001600160a01b0316146115ae5760405162461bcd60e51b815260040180806020018281038252602f815260200180614646602f913960400191505060405180910390fd5b306001600160a01b0316816001600160a01b031663fbfa77cf6040518163ffffffff1660e01b815260040160206040518083038186803b1580156115f157600080fd5b505afa158015611605573d6000803e3d6000fd5b505050506040513d602081101561161b57600080fd5b50516001600160a01b0316146116625760405162461bcd60e51b815260040180806020018281038252602a8152602001806145bc602a913960400191505060405180910390fd5b7f254c88e7a2ea123aeeb89b7cc413fb949188fefcdb7584c4f3d493294daf65c58161168c61293e565b604080516001600160a01b03938416815291909216602082015281519081900390910190a16116b961293e565b6001600160a01b0316816001600160a01b0316146117995760006116db61293e565b6001600160a01b03161461176f576117146116f461293e565b60006116fe611ee7565b6001600160a01b0316919063ffffffff61385016565b61171c61293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561175657600080fd5b505af115801561176a573d6000803e3d6000fd5b505050505b61177881613963565b6117836116f461293e565b61179961178e61293e565b6000196116fe611ee7565b610d16612f31565b3332148061183457506117b2613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561180757600080fd5b505afa15801561181b573d6000803e3d6000fd5b505050506040513d602081101561183157600080fd5b50515b611880576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b6112f382338361398d565b6000610a42611898613146565b84610f2585603460006118a9613146565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff61328616565b6000610a56613c7b565b600054610100900460ff168061190257506119026133ba565b80611910575060005460ff16155b61194b5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015611976576000805460ff1961ff0019909116610100171660011790555b828411156119cb576040805162461bcd60e51b815260206004820152601c60248201527f63616e6e6f7420696e76657374206d6f7265207468616e203130302500000000604482015290519081900360640190fd5b82611a12576040805162461bcd60e51b8152602060048201526012602482015271063616e6e6f742064697669646520627920360741b604482015290519081900360640190fd5b611db0856001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015611a4e57600080fd5b505afa158015611a62573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611a8b57600080fd5b8101908080516040519392919084600160201b821115611aaa57600080fd5b908301906020820185811115611abf57600080fd5b8251600160201b811182820188101715611ad857600080fd5b82525081516020918201929091019080838360005b83811015611b05578181015183820152602001611aed565b50505050905090810190601f168015611b325780820380516001836020036101000a031916815260200191505b50604052505050604051602001808065464f5243455f60d01b81525060060182805190602001908083835b60208310611b7c5780518252601f199092019160209182019101611b5d565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052866001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015611be957600080fd5b505afa158015611bfd573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611c2657600080fd5b8101908080516040519392919084600160201b821115611c4557600080fd5b908301906020820185811115611c5a57600080fd5b8251600160201b811182820188101715611c7357600080fd5b82525081516020918201929091019080838360005b83811015611ca0578181015183820152602001611c88565b50505050905090810190601f168015611ccd5780820380516001836020036101000a031916815260200191505b506040525050506040516020018080600f60fb1b81525060010182805190602001908083835b60208310611d125780518252601f199092019160209182019101611cf3565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052876001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015611d7f57600080fd5b505afa158015611d93573d6000803e3d6000fd5b505050506040513d6020811015611da957600080fd5b5051610d19565b611db986612b88565b611dc16120ba565b6000856001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015611dfc57600080fd5b505afa158015611e10573d6000803e3d6000fd5b505050506040513d6020811015611e2657600080fd5b505160ff16600a0a905061a8c080611e4388888886898680612160565b5050508015611e58576000805461ff00191690555b505050505050565b6000610a56613ca6565b6000611e74613261565b6001600160a01b0316635aa6e6756040518163ffffffff1660e01b815260040160206040518083038186803b158015611eac57600080fd5b505afa158015611ec0573d6000803e3d6000fd5b505050506040513d6020811015611ed657600080fd5b5051905090565b6000610a56613cd1565b6000610a56613cfc565b6001600160a01b0381166000908152603360205260409020545b919050565b6000611f1a610df5565b15611f4257611f3d611f2a610df5565b6110e3611f35610dfb565b6110d7611e60565b610a56565b610a56611e60565b611f52613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015611fa757600080fd5b505afa158015611fbb573d6000803e3d6000fd5b505050506040513d6020811015611fd157600080fd5b5051806120635750611fe1613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561203657600080fd5b505afa15801561204a573d6000803e3d6000fd5b505050506040513d602081101561206057600080fd5b50515b61209e5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b6120a6612266565b6120ae613d27565b565b6000610a5661374c565b600054610100900460ff16806120d357506120d36133ba565b806120e1575060005460ff16155b61211c5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015612147576000805460ff1961ff0019909116610100171660011790555b600160cf558015610d16576000805461ff001916905550565b600054610100900460ff168061217957506121796133ba565b80612187575060005460ff16155b6121c25760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff161580156121ed576000805460ff1961ff0019909116610100171660011790555b6121f688613de4565b6121ff87613e0e565b61220886613e38565b61221184613e62565b61221a85613e8c565b61222383613eb6565b61222c82613ee0565b61223660006132e7565b6122406000613311565b8015612252576000805461ff00191690555b5050505050505050565b6000610a56613f0a565b61226e613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156122c357600080fd5b505afa1580156122d7573d6000803e3d6000fd5b505050506040513d60208110156122ed57600080fd5b50518061237f57506122fd613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561235257600080fd5b505afa158015612366573d6000803e3d6000fd5b505050506040513d602081101561237c57600080fd5b50515b6123ba5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b60006123c461293e565b6001600160a01b0316141561241b576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b61242361293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561245d57600080fd5b505af1158015610def573d6000803e3d6000fd5b600061247b610df5565b61248757506000611f0b565b610a46612492610df5565b6110e361249e85611ef1565b6110d7610dfb565b6124ae613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561250357600080fd5b505afa158015612517573d6000803e3d6000fd5b505050506040513d602081101561252d57600080fd5b5051612571576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b6001600160a01b0381166125cc576040805162461bcd60e51b815260206004820152601e60248201527f6e65772073746f726167652073686f756c646e277420626520656d7074790000604482015290519081900360640190fd5b610d1681613f35565b6000610a56613f59565b60698054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610a235780601f106109f857610100808354040283529160200191610a23565b612648613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561269d57600080fd5b505afa1580156126b1573d6000803e3d6000fd5b505050506040513d60208110156126c757600080fd5b505161270b576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b6127156000613366565b6120ae6000613390565b60008061272a61225c565b1580159061273e575061273b61225c565b42115b801561275b5750600061274f610a4c565b6001600160a01b031614155b612763610a4c565b915091509091565b6000610a42612778613146565b84610f258560405180606001604052806025815260200161481560259139603460006127a2613146565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff61351e16565b6127e1613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561283657600080fd5b505afa15801561284a573d6000803e3d6000fd5b505050506040513d602081101561286057600080fd5b50516128a4576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b600081116128e35760405162461bcd60e51b81526004018080602001828103825260228152602001806145566022913960400191505060405180910390fd5b808211156129225760405162461bcd60e51b815260040180806020018281038252603a8152602001806145e6603a913960400191505060405180910390fd5b61292b82613e0e565b6112f381613e38565b6000610a56613f84565b6000610a56613faf565b6000610a42612955613146565b84846133c0565b6000610a56613fda565b60008061297f6129746130fa565b6110e361249e6118df565b9050600061298b61293e565b6001600160a01b03166345d01e4a6040518163ffffffff1660e01b815260040160206040518083038186803b1580156129c357600080fd5b505afa1580156129d7573d6000803e3d6000fd5b505050506040513d60208110156129ed57600080fd5b50519050818110612a0357600092505050610a2b565b6000612a15838363ffffffff61377716565b9050612a1f612b29565b811115612a3357612a2e612b29565b612a35565b805b9350505050610a2b565b33321480612ad25750612a50613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612aa557600080fd5b505afa158015612ab9573d6000803e3d6000fd5b505050506040513d6020811015612acf57600080fd5b50515b612b1e576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b610d1681333361398d565b6000612b33611ee7565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015611eac57600080fd5b600054610100900460ff1680612ba15750612ba16133ba565b80612baf575060005460ff16155b612bea5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015612c15576000805460ff1961ff0019909116610100171660011790555b612c1e82614005565b80156112f3576000805461ff00191690555050565b6000612c3d61293e565b6001600160a01b03161415612c94576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b612c9c613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612cf157600080fd5b505afa158015612d05573d6000803e3d6000fd5b505050506040513d6020811015612d1b57600080fd5b505180612dad5750612d2b613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612d8057600080fd5b505afa158015612d94573d6000803e3d6000fd5b505050506040513d6020811015612daa57600080fd5b50515b612de85760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b612df0613d27565b612df861293e565b6001600160a01b031663cca7f4756040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561245d57600080fd5b6001600160a01b03918216600090815260346020908152604080832093909416825291909152205490565b612e65613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612eba57600080fd5b505afa158015612ece573d6000803e3d6000fd5b505050506040513d6020811015612ee457600080fd5b5051612f28576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b610d1681613e62565b612f39613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612f8e57600080fd5b505afa158015612fa2573d6000803e3d6000fd5b505050506040513d6020811015612fb857600080fd5b50518061304a5750612fc8613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561301d57600080fd5b505afa158015613031573d6000803e3d6000fd5b505050506040513d602081101561304757600080fd5b50515b6130855760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b61308f60006132e7565b6120ae6000613311565b6000806130a461293e565b6001600160a01b03161480610a4657506130bc611edd565b6001600160a01b0316826001600160a01b03161480156130e257506130df61295c565b42115b8015610a46575060006130f361295c565b1192915050565b6000610a5661409b565b600061310e613261565b6001600160a01b031663f77c47916040518163ffffffff1660e01b815260040160206040518083038186803b158015611eac57600080fd5b3390565b6001600160a01b03831661318f5760405162461bcd60e51b81526004018080602001828103825260248152602001806147916024913960400191505060405180910390fd5b6001600160a01b0382166131d45760405162461bcd60e51b815260040180806020018281038252602281526020018061459a6022913960400191505060405180910390fd5b6001600160a01b03808416600081815260346020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6000610a567fb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df6140c2565b7fa7ec62784904ff31cbcc32d09932a58e7f1e4476e1d041995b37c917990b16dc5490565b6000828201838110156132e0576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b610d167f56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e72826140c6565b610d167fb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc8590610826140c6565b6000610a567f6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b6140c2565b610d167fb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df826140c6565b610d167f3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c9826140c6565b303b1590565b6001600160a01b0383166134055760405162461bcd60e51b815260040180806020018281038252602581526020018061476c6025913960400191505060405180910390fd5b6001600160a01b03821661344a5760405162461bcd60e51b81526004018080602001828103825260238152602001806145336023913960400191505060405180910390fd5b61348d81604051806060016040528060268152602001614620602691396001600160a01b038616600090815260336020526040902054919063ffffffff61351e16565b6001600160a01b0380851660009081526033602052604080822093909355908416815220546134c2908263ffffffff61328616565b6001600160a01b0380841660008181526033602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b600081848411156135ad5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561357257818101518382015260200161355a565b50505050905090810190601f16801561359f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6001600160a01b0382166135fa5760405162461bcd60e51b815260040180806020018281038252602181526020018061474b6021913960400191505060405180910390fd5b61363d81604051806060016040528060228152602001614578602291396001600160a01b038516600090815260336020526040902054919063ffffffff61351e16565b6001600160a01b038316600090815260336020526040902055603554613669908263ffffffff61377716565b6035556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b6000826136c057506000610a46565b828202828482816136cd57fe5b04146132e05760405162461bcd60e51b81526004018080602001828103825260218152602001806146756021913960400191505060405180910390fd5b60006132e083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506140ca565b6000610a567faf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef2136140c2565b60006132e083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061351e565b60008183106137c857816132e0565b5090919050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261382190849061412f565b505050565b610d167faf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef213826140c6565b8015806138d6575060408051636eb1769f60e11b81523060048201526001600160a01b03848116602483015291519185169163dd62ed3e91604480820192602092909190829003018186803b1580156138a857600080fd5b505afa1580156138bc573d6000803e3d6000fd5b505050506040513d60208110156138d257600080fd5b5051155b6139115760405162461bcd60e51b81526004018080602001828103825260368152602001806147df6036913960400191505060405180910390fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663095ea7b360e01b17905261382190849061412f565b610d167ff1a169aa0f736c2813818fdfbdc5755c31e0839c8f49831a16543496b28574ea826140c6565b60cf805460010190819055836139dd576040805162461bcd60e51b815260206004820152601060248201526f043616e6e6f74206465706f73697420360841b604482015290519081900360640190fd5b6001600160a01b038216613a31576040805162461bcd60e51b81526020600482015260166024820152751a1bdb19195c881b5d5cdd081899481919599a5b995960521b604482015290519081900360640190fd5b613a396125d5565b1580613a575750613a486125d5565b613a5485610e9b6120b0565b11155b613aa8576040805162461bcd60e51b815260206004820152601c60248201527f43616e6e6f74206465706f736974206d6f7265207468616e2063617000000000604482015290519081900360640190fd5b6000613ab261293e565b6001600160a01b031614613b6c57613ac861293e565b6001600160a01b031663c2a2a07b6040518163ffffffff1660e01b815260040160206040518083038186803b158015613b0057600080fd5b505afa158015613b14573d6000803e3d6000fd5b505050506040513d6020811015613b2a57600080fd5b5051613b6c576040805162461bcd60e51b815260206004820152600c60248201526b2a37b79036bab1b41030b93160a11b604482015290519081900360640190fd5b6000613b76610df5565b15613ba357613b9e613b86610dfb565b6110e3613b91610df5565b889063ffffffff6136b116565b613ba5565b845b9050613bb183826142e7565b613bd6843087613bbf611ee7565b6001600160a01b031692919063ffffffff6143d916565b613be561125f86610e9b61374c565b6040805186815290516001600160a01b038516917fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c919081900360200190a25060cf548114610def576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6000610a567f39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a6140c2565b6000610a567fa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff6140c2565b6000610a567fb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc85906106140c2565b6000610a567f1994607607e11d53306ef62e45e3bd85762c58d9bf38b5578bc4a258a26a73716140c2565b6000613d3161293e565b6001600160a01b03161415613d88576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b6000613d92612966565b90508015610d1657613dae613da561293e565b8261122e611ee7565b6040805182815290517fa09b7ae452b7bffb9e204c3a016e80caeecf46f554d112644f36fa114dac6ffa9181900360200190a150565b610d167f1994607607e11d53306ef62e45e3bd85762c58d9bf38b5578bc4a258a26a7371826140c6565b610d167f39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a826140c6565b610d167f469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed32308826140c6565b610d167f0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e28826140c6565b610d167fa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff826140c6565b610d167f82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf0826140c6565b610d167f6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b826140c6565b6000610a567f3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c96140c2565b7fa7ec62784904ff31cbcc32d09932a58e7f1e4476e1d041995b37c917990b16dc55565b6000610a567f0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e286140c2565b6000610a567f82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf06140c2565b6000610a567ff1a169aa0f736c2813818fdfbdc5755c31e0839c8f49831a16543496b28574ea6140c2565b6000610a567f56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e726140c2565b600054610100900460ff168061401e575061401e6133ba565b8061402c575060005460ff16155b6140675760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015614092576000805460ff1961ff0019909116610100171660011790555b612c1e82613f35565b6000610a567f469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed323085b5490565b9055565b600081836141195760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561357257818101518382015260200161355a565b50600083858161412557fe5b0495945050505050565b614141826001600160a01b0316614433565b614192576040805162461bcd60e51b815260206004820152601f60248201527f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e747261637400604482015290519081900360640190fd5b60006060836001600160a01b0316836040518082805190602001908083835b602083106141d05780518252601f1990920191602091820191016141b1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114614232576040519150601f19603f3d011682016040523d82523d6000602084013e614237565b606091505b50915091508161428e576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b805115610def578080602001905160208110156142aa57600080fd5b5051610def5760405162461bcd60e51b815260040180806020018281038252602a8152602001806147b5602a913960400191505060405180910390fd5b6001600160a01b038216614342576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b603554614355908263ffffffff61328616565b6035556001600160a01b038216600090815260336020526040902054614381908263ffffffff61328616565b6001600160a01b03831660008181526033602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052610def90859061412f565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061446757508115155b949350505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106144b057805160ff19168380011785556144dd565b828001600101855582156144dd579182015b828111156144dd5782518255916020019190600101906144c2565b506144e99291506144ed565b5090565b610a2b91905b808211156144e957600081556001016144f356fe5468652063616c6c6572206d75737420626520636f6e74726f6c6c6572206f7220676f7665726e616e636545524332303a207472616e7366657220746f20746865207a65726f206164647265737364656e6f6d696e61746f72206d7573742062652067726561746572207468616e203045524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737374686520737472617465677920646f6573206e6f742062656c6f6e6720746f2074686973207661756c7464656e6f6d696e61746f72206d7573742062652067726561746572207468616e206f7220657175616c20746f20746865206e756d657261746f7245524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e63655661756c7420756e6465726c79696e67206d757374206d6174636820537472617465677920756e6465726c79696e67536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a65645468652073747261746567792065786973747320616e64207377697463682074696d656c6f636b20646964206e6f7420656c61707365207965746e756d6265724f66536861726573206d7573742062652067726561746572207468616e203045524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f20616464726573735361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565645361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa265627a7a72315820fee82ab2daa3b95d6e5bf8dcc990d4a433fe38ea511b97831adcece40e4eec0964736f6c63430005100032656970313936372e7661756c7453746f726167652e6d61784465706f736974436170656970313936372e7661756c7453746f726167652e7661756c744672616374696f6e546f496e766573744e756d657261746f72656970313936372e7661756c7453746f726167652e6e657874496d706c656d656e746174696f6e54696d657374616d70656970313936372e7661756c7453746f726167652e7661756c744672616374696f6e546f496e7665737444656e6f6d696e61746f72656970313936372e7661756c7453746f726167652e737472617465677955706461746554696d65656970313936372e7661756c7453746f726167652e737472617465677954696d654c6f636b656970313936372e7661756c7453746f726167652e6e657874496d706c656d656e746174696f6e44656c6179656970313936372e7661756c7453746f726167652e756e6465726c79696e67556e6974656970313936372e7661756c7453746f726167652e746f74616c4465706f73697473656970313936372e7661756c7453746f726167652e6e657874496d706c656d656e746174696f6e656970313936372e7661756c7453746f726167652e6675747572655374726174656779
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061030c5760003560e01c80638142951a1161019d578063a9059cbb116100e9578063cca7f475116100a2578063eda199aa1161007c578063eda199aa14610959578063f0cf91e714610961578063f2768c1e14610987578063f77c47911461098f5761030c565b8063cca7f47514610906578063dd62ed3e1461090e578063dfed91601461093c5761030c565b8063a9059cbb1461087f578063aa044625146108ab578063b592c390146108b3578063b6b55f25146108bb578063c2baf356146108d8578063c4d66de8146108e05761030c565b806395d89b4111610156578063a457c2d711610130578063a457c2d714610820578063a5b1a24d1461084c578063a83656931461086f578063a8c62e76146108775761030c565b806395d89b41146107e55780639a508c8e146107ed5780639d16acfd146107f55761030c565b80638142951a1461073757806382de9c1b14610781578063853828b6146107895780638cb1d67f146107915780639137c1a7146107b75780639546cc53146107dd5761030c565b806336efd16f1161025c5780635fe51e6d1161021557806377c7b8fc116101ef57806377c7b8fc146107175780637d7c2a1c1461071f5780637d882097146107275780638129fc1c1461072f5761030c565b80635fe51e6d146106e15780636f307dc3146106e957806370a08231146106f15761030c565b806336efd16f1461062f578063395093511461065b5780634af1758b146106875780635392db601461068f57806353ceb01c146106d15780635aa6e675146106d95761030c565b80631624f6c6116102c957806323b872dd116102a357806323b872dd146105985780632e1a7d4d146105ce578063313ce567146105eb57806333a100ca146106095761030c565b80631624f6c61461045a57806318160ddd146105885780631bf8e7be146105905761030c565b806306fdde0314610311578063095ea7b31461038e57806309ff18f0146103ce5780630a6bbeb3146103f25780630ad2239d1461041a5780630c80447a14610434575b600080fd5b610319610997565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561035357818101518382015260200161033b565b50505050905090810190601f1680156103805780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103ba600480360360408110156103a457600080fd5b506001600160a01b038135169060200135610a2e565b604080519115158252519081900360200190f35b6103d6610a4c565b604080516001600160a01b039092168252519081900360200190f35b6104186004803603602081101561040857600080fd5b50356001600160a01b0316610a5b565b005b610422610c25565b60408051918252519081900360200190f35b6104186004803603602081101561044a57600080fd5b50356001600160a01b0316610c2f565b6104186004803603606081101561047057600080fd5b810190602081018135600160201b81111561048a57600080fd5b82018360208201111561049c57600080fd5b803590602001918460018302840111600160201b831117156104bd57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295949360208101935035915050600160201b81111561050f57600080fd5b82018360208201111561052157600080fd5b803590602001918460018302840111600160201b8311171561054257600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505050903560ff169150610d199050565b610422610df5565b610422610dfb565b6103ba600480360360608110156105ae57600080fd5b506001600160a01b03813581169160208101359091169060400135610ea7565b610418600480360360208110156105e457600080fd5b5035610f34565b6105f36112f7565b6040805160ff9092168252519081900360200190f35b6104186004803603602081101561061f57600080fd5b50356001600160a01b0316611300565b6104186004803603604081101561064557600080fd5b50803590602001356001600160a01b03166117a1565b6103ba6004803603604081101561067157600080fd5b506001600160a01b03813516906020013561188b565b6104226118df565b610418600480360360a08110156106a557600080fd5b506001600160a01b038135811691602081013590911690604081013590606081013590608001356118e9565b610422611e60565b6103d6611e6a565b6103d6611edd565b6103d6611ee7565b6104226004803603602081101561070757600080fd5b50356001600160a01b0316611ef1565b610422611f10565b610418611f4a565b6104226120b0565b6104186120ba565b610418600480360360e081101561074d57600080fd5b506001600160a01b038135169060208101359060408101359060608101359060808101359060a08101359060c00135612160565b61042261225c565b610418612266565b610422600480360360208110156107a757600080fd5b50356001600160a01b0316612471565b610418600480360360208110156107cd57600080fd5b50356001600160a01b03166124a6565b6104226125d5565b6103196125df565b610418612640565b6107fd61271f565b6040805192151583526001600160a01b0390911660208301528051918290030190f35b6103ba6004803603604081101561083657600080fd5b506001600160a01b03813516906020013561276b565b6104186004803603604081101561086257600080fd5b50803590602001356127d9565b610422612934565b6103d661293e565b6103ba6004803603604081101561089557600080fd5b506001600160a01b038135169060200135612948565b61042261295c565b610422612966565b610418600480360360208110156108d157600080fd5b5035612a3f565b610422612b29565b610418600480360360208110156108f657600080fd5b50356001600160a01b0316612b88565b610418612c33565b6104226004803603604081101561092457600080fd5b506001600160a01b0381358116916020013516612e32565b6104186004803603602081101561095257600080fd5b5035612e5d565b610418612f31565b6103ba6004803603602081101561097757600080fd5b50356001600160a01b0316613099565b6104226130fa565b6103d6613104565b60688054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610a235780601f106109f857610100808354040283529160200191610a23565b820191906000526020600020905b815481529060010190602001808311610a0657829003601f168201915b505050505090505b90565b6000610a42610a3b613146565b848461314a565b5060015b92915050565b6000610a56613236565b905090565b610a63613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610ab857600080fd5b505afa158015610acc573d6000803e3d6000fd5b505050506040513d6020811015610ae257600080fd5b505180610b745750610af2613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610b4757600080fd5b505afa158015610b5b573d6000803e3d6000fd5b505050506040513d6020811015610b7157600080fd5b50515b610baf5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b6000610bc9610bbc610c25565b429063ffffffff61328616565b9050610bd4816132e7565b610bdd82613311565b604080516001600160a01b03841681526020810183905281517f7d5e1cfe55788983acd19d248da36a27c9413e8e43445ed36a76ae0e741a04ed929181900390910190a15050565b6000610a5661333b565b610c37613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610c8c57600080fd5b505afa158015610ca0573d6000803e3d6000fd5b505050506040513d6020811015610cb657600080fd5b5051610cfa576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b610d0381613366565b610d16610d11610bbc612934565b613390565b50565b600054610100900460ff1680610d325750610d326133ba565b80610d40575060005460ff16155b610d7b5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015610da6576000805460ff1961ff0019909116610100171660011790555b8351610db990606890602087019061446f565b508251610dcd90606990602086019061446f565b50606a805460ff191660ff84161790558015610def576000805461ff00191690555b50505050565b60355490565b600080610e0661293e565b6001600160a01b03161415610e2457610e1d612b29565b9050610a2b565b610a56610e2f61293e565b6001600160a01b03166345d01e4a6040518163ffffffff1660e01b815260040160206040518083038186803b158015610e6757600080fd5b505afa158015610e7b573d6000803e3d6000fd5b505050506040513d6020811015610e9157600080fd5b5051610e9b612b29565b9063ffffffff61328616565b6000610eb48484846133c0565b610f2a84610ec0613146565b610f2585604051806060016040528060288152602001614696602891396001600160a01b038a16600090815260346020526040812090610efe613146565b6001600160a01b03168152602081019190915260400160002054919063ffffffff61351e16565b61314a565b5060019392505050565b33321480610fc75750610f45613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015610f9a57600080fd5b505afa158015610fae573d6000803e3d6000fd5b505050506040513d6020811015610fc457600080fd5b50515b611013576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b60cf8054600101908190556000611028610df5565b11611070576040805162461bcd60e51b81526020600482015260136024820152725661756c7420686173206e6f2073686172657360681b604482015290519081900360640190fd5b600082116110af5760405162461bcd60e51b81526004018080602001828103825260258152602001806147266025913960400191505060405180910390fd5b60006110b9610df5565b90506110c533846135b5565b60006110ef826110e3866110d7610dfb565b9063ffffffff6136b116565b9063ffffffff61370a16565b90506000611103836110e3876110d761374c565b905061110d612b29565b821115611221578285141561117b5761112461293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561115e57600080fd5b505af1158015611172573d6000803e3d6000fd5b505050506111fe565b6000611195611188612b29565b849063ffffffff61377716565b905061119f61293e565b6001600160a01b031663ce8c42e8826040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156111e457600080fd5b505af11580156111f8573d6000803e3d6000fd5b50505050505b61121e611211846110e3886110d7610dfb565b611219612b29565b6137b9565b91505b611244338361122e611ee7565b6001600160a01b0316919063ffffffff6137cf16565b61126461125f8261125361374c565b9063ffffffff61377716565b613826565b60408051838152905133917f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364919081900360200190a250505060cf5481146112f3576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b5050565b606a5460ff1690565b611308613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561135d57600080fd5b505afa158015611371573d6000803e3d6000fd5b505050506040513d602081101561138757600080fd5b5051806114195750611397613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156113ec57600080fd5b505afa158015611400573d6000803e3d6000fd5b505050506040513d602081101561141657600080fd5b50515b6114545760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b61145d81613099565b6114985760405162461bcd60e51b815260040180806020018281038252603a8152602001806146ec603a913960400191505060405180910390fd5b6001600160a01b0381166114f3576040805162461bcd60e51b815260206004820152601d60248201527f6e6577205f73747261746567792063616e6e6f7420626520656d707479000000604482015290519081900360640190fd5b6114fb611ee7565b6001600160a01b0316816001600160a01b0316636f307dc36040518163ffffffff1660e01b815260040160206040518083038186803b15801561153d57600080fd5b505afa158015611551573d6000803e3d6000fd5b505050506040513d602081101561156757600080fd5b50516001600160a01b0316146115ae5760405162461bcd60e51b815260040180806020018281038252602f815260200180614646602f913960400191505060405180910390fd5b306001600160a01b0316816001600160a01b031663fbfa77cf6040518163ffffffff1660e01b815260040160206040518083038186803b1580156115f157600080fd5b505afa158015611605573d6000803e3d6000fd5b505050506040513d602081101561161b57600080fd5b50516001600160a01b0316146116625760405162461bcd60e51b815260040180806020018281038252602a8152602001806145bc602a913960400191505060405180910390fd5b7f254c88e7a2ea123aeeb89b7cc413fb949188fefcdb7584c4f3d493294daf65c58161168c61293e565b604080516001600160a01b03938416815291909216602082015281519081900390910190a16116b961293e565b6001600160a01b0316816001600160a01b0316146117995760006116db61293e565b6001600160a01b03161461176f576117146116f461293e565b60006116fe611ee7565b6001600160a01b0316919063ffffffff61385016565b61171c61293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561175657600080fd5b505af115801561176a573d6000803e3d6000fd5b505050505b61177881613963565b6117836116f461293e565b61179961178e61293e565b6000196116fe611ee7565b610d16612f31565b3332148061183457506117b2613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561180757600080fd5b505afa15801561181b573d6000803e3d6000fd5b505050506040513d602081101561183157600080fd5b50515b611880576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b6112f382338361398d565b6000610a42611898613146565b84610f2585603460006118a9613146565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff61328616565b6000610a56613c7b565b600054610100900460ff168061190257506119026133ba565b80611910575060005460ff16155b61194b5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015611976576000805460ff1961ff0019909116610100171660011790555b828411156119cb576040805162461bcd60e51b815260206004820152601c60248201527f63616e6e6f7420696e76657374206d6f7265207468616e203130302500000000604482015290519081900360640190fd5b82611a12576040805162461bcd60e51b8152602060048201526012602482015271063616e6e6f742064697669646520627920360741b604482015290519081900360640190fd5b611db0856001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015611a4e57600080fd5b505afa158015611a62573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611a8b57600080fd5b8101908080516040519392919084600160201b821115611aaa57600080fd5b908301906020820185811115611abf57600080fd5b8251600160201b811182820188101715611ad857600080fd5b82525081516020918201929091019080838360005b83811015611b05578181015183820152602001611aed565b50505050905090810190601f168015611b325780820380516001836020036101000a031916815260200191505b50604052505050604051602001808065464f5243455f60d01b81525060060182805190602001908083835b60208310611b7c5780518252601f199092019160209182019101611b5d565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052866001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015611be957600080fd5b505afa158015611bfd573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611c2657600080fd5b8101908080516040519392919084600160201b821115611c4557600080fd5b908301906020820185811115611c5a57600080fd5b8251600160201b811182820188101715611c7357600080fd5b82525081516020918201929091019080838360005b83811015611ca0578181015183820152602001611c88565b50505050905090810190601f168015611ccd5780820380516001836020036101000a031916815260200191505b506040525050506040516020018080600f60fb1b81525060010182805190602001908083835b60208310611d125780518252601f199092019160209182019101611cf3565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052876001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015611d7f57600080fd5b505afa158015611d93573d6000803e3d6000fd5b505050506040513d6020811015611da957600080fd5b5051610d19565b611db986612b88565b611dc16120ba565b6000856001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015611dfc57600080fd5b505afa158015611e10573d6000803e3d6000fd5b505050506040513d6020811015611e2657600080fd5b505160ff16600a0a905061a8c080611e4388888886898680612160565b5050508015611e58576000805461ff00191690555b505050505050565b6000610a56613ca6565b6000611e74613261565b6001600160a01b0316635aa6e6756040518163ffffffff1660e01b815260040160206040518083038186803b158015611eac57600080fd5b505afa158015611ec0573d6000803e3d6000fd5b505050506040513d6020811015611ed657600080fd5b5051905090565b6000610a56613cd1565b6000610a56613cfc565b6001600160a01b0381166000908152603360205260409020545b919050565b6000611f1a610df5565b15611f4257611f3d611f2a610df5565b6110e3611f35610dfb565b6110d7611e60565b610a56565b610a56611e60565b611f52613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015611fa757600080fd5b505afa158015611fbb573d6000803e3d6000fd5b505050506040513d6020811015611fd157600080fd5b5051806120635750611fe1613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561203657600080fd5b505afa15801561204a573d6000803e3d6000fd5b505050506040513d602081101561206057600080fd5b50515b61209e5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b6120a6612266565b6120ae613d27565b565b6000610a5661374c565b600054610100900460ff16806120d357506120d36133ba565b806120e1575060005460ff16155b61211c5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015612147576000805460ff1961ff0019909116610100171660011790555b600160cf558015610d16576000805461ff001916905550565b600054610100900460ff168061217957506121796133ba565b80612187575060005460ff16155b6121c25760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff161580156121ed576000805460ff1961ff0019909116610100171660011790555b6121f688613de4565b6121ff87613e0e565b61220886613e38565b61221184613e62565b61221a85613e8c565b61222383613eb6565b61222c82613ee0565b61223660006132e7565b6122406000613311565b8015612252576000805461ff00191690555b5050505050505050565b6000610a56613f0a565b61226e613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156122c357600080fd5b505afa1580156122d7573d6000803e3d6000fd5b505050506040513d60208110156122ed57600080fd5b50518061237f57506122fd613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561235257600080fd5b505afa158015612366573d6000803e3d6000fd5b505050506040513d602081101561237c57600080fd5b50515b6123ba5760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b60006123c461293e565b6001600160a01b0316141561241b576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b61242361293e565b6001600160a01b031663bfd131f16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561245d57600080fd5b505af1158015610def573d6000803e3d6000fd5b600061247b610df5565b61248757506000611f0b565b610a46612492610df5565b6110e361249e85611ef1565b6110d7610dfb565b6124ae613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561250357600080fd5b505afa158015612517573d6000803e3d6000fd5b505050506040513d602081101561252d57600080fd5b5051612571576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b6001600160a01b0381166125cc576040805162461bcd60e51b815260206004820152601e60248201527f6e65772073746f726167652073686f756c646e277420626520656d7074790000604482015290519081900360640190fd5b610d1681613f35565b6000610a56613f59565b60698054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610a235780601f106109f857610100808354040283529160200191610a23565b612648613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561269d57600080fd5b505afa1580156126b1573d6000803e3d6000fd5b505050506040513d60208110156126c757600080fd5b505161270b576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b6127156000613366565b6120ae6000613390565b60008061272a61225c565b1580159061273e575061273b61225c565b42115b801561275b5750600061274f610a4c565b6001600160a01b031614155b612763610a4c565b915091509091565b6000610a42612778613146565b84610f258560405180606001604052806025815260200161481560259139603460006127a2613146565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff61351e16565b6127e1613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561283657600080fd5b505afa15801561284a573d6000803e3d6000fd5b505050506040513d602081101561286057600080fd5b50516128a4576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b600081116128e35760405162461bcd60e51b81526004018080602001828103825260228152602001806145566022913960400191505060405180910390fd5b808211156129225760405162461bcd60e51b815260040180806020018281038252603a8152602001806145e6603a913960400191505060405180910390fd5b61292b82613e0e565b6112f381613e38565b6000610a56613f84565b6000610a56613faf565b6000610a42612955613146565b84846133c0565b6000610a56613fda565b60008061297f6129746130fa565b6110e361249e6118df565b9050600061298b61293e565b6001600160a01b03166345d01e4a6040518163ffffffff1660e01b815260040160206040518083038186803b1580156129c357600080fd5b505afa1580156129d7573d6000803e3d6000fd5b505050506040513d60208110156129ed57600080fd5b50519050818110612a0357600092505050610a2b565b6000612a15838363ffffffff61377716565b9050612a1f612b29565b811115612a3357612a2e612b29565b612a35565b805b9350505050610a2b565b33321480612ad25750612a50613104565b6001600160a01b031663372c12b1336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612aa557600080fd5b505afa158015612ab9573d6000803e3d6000fd5b505050506040513d6020811015612acf57600080fd5b50515b612b1e576040805162461bcd60e51b815260206004820152601860248201527720b1b1b2b9b9903232b734b2b2103337b91031b0b63632b960411b604482015290519081900360640190fd5b610d1681333361398d565b6000612b33611ee7565b6001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015611eac57600080fd5b600054610100900460ff1680612ba15750612ba16133ba565b80612baf575060005460ff16155b612bea5760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015612c15576000805460ff1961ff0019909116610100171660011790555b612c1e82614005565b80156112f3576000805461ff00191690555050565b6000612c3d61293e565b6001600160a01b03161415612c94576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b612c9c613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612cf157600080fd5b505afa158015612d05573d6000803e3d6000fd5b505050506040513d6020811015612d1b57600080fd5b505180612dad5750612d2b613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612d8057600080fd5b505afa158015612d94573d6000803e3d6000fd5b505050506040513d6020811015612daa57600080fd5b50515b612de85760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b612df0613d27565b612df861293e565b6001600160a01b031663cca7f4756040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561245d57600080fd5b6001600160a01b03918216600090815260346020908152604080832093909416825291909152205490565b612e65613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612eba57600080fd5b505afa158015612ece573d6000803e3d6000fd5b505050506040513d6020811015612ee457600080fd5b5051612f28576040805162461bcd60e51b815260206004820152600e60248201526d4e6f7420676f7665726e616e636560901b604482015290519081900360640190fd5b610d1681613e62565b612f39613261565b6001600160a01b031663b429afeb336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612f8e57600080fd5b505afa158015612fa2573d6000803e3d6000fd5b505050506040513d6020811015612fb857600080fd5b50518061304a5750612fc8613261565b6001600160a01b031663dee1f0e4336040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561301d57600080fd5b505afa158015613031573d6000803e3d6000fd5b505050506040513d602081101561304757600080fd5b50515b6130855760405162461bcd60e51b815260040180806020018281038252602b815260200180614508602b913960400191505060405180910390fd5b61308f60006132e7565b6120ae6000613311565b6000806130a461293e565b6001600160a01b03161480610a4657506130bc611edd565b6001600160a01b0316826001600160a01b03161480156130e257506130df61295c565b42115b8015610a46575060006130f361295c565b1192915050565b6000610a5661409b565b600061310e613261565b6001600160a01b031663f77c47916040518163ffffffff1660e01b815260040160206040518083038186803b158015611eac57600080fd5b3390565b6001600160a01b03831661318f5760405162461bcd60e51b81526004018080602001828103825260248152602001806147916024913960400191505060405180910390fd5b6001600160a01b0382166131d45760405162461bcd60e51b815260040180806020018281038252602281526020018061459a6022913960400191505060405180910390fd5b6001600160a01b03808416600081815260346020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6000610a567fb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df6140c2565b7fa7ec62784904ff31cbcc32d09932a58e7f1e4476e1d041995b37c917990b16dc5490565b6000828201838110156132e0576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b610d167f56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e72826140c6565b610d167fb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc8590610826140c6565b6000610a567f6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b6140c2565b610d167fb1acf527cd7cd1668b30e5a9a1c0d845714604de29ce560150922c9d8c0937df826140c6565b610d167f3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c9826140c6565b303b1590565b6001600160a01b0383166134055760405162461bcd60e51b815260040180806020018281038252602581526020018061476c6025913960400191505060405180910390fd5b6001600160a01b03821661344a5760405162461bcd60e51b81526004018080602001828103825260238152602001806145336023913960400191505060405180910390fd5b61348d81604051806060016040528060268152602001614620602691396001600160a01b038616600090815260336020526040902054919063ffffffff61351e16565b6001600160a01b0380851660009081526033602052604080822093909355908416815220546134c2908263ffffffff61328616565b6001600160a01b0380841660008181526033602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b600081848411156135ad5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561357257818101518382015260200161355a565b50505050905090810190601f16801561359f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6001600160a01b0382166135fa5760405162461bcd60e51b815260040180806020018281038252602181526020018061474b6021913960400191505060405180910390fd5b61363d81604051806060016040528060228152602001614578602291396001600160a01b038516600090815260336020526040902054919063ffffffff61351e16565b6001600160a01b038316600090815260336020526040902055603554613669908263ffffffff61377716565b6035556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b6000826136c057506000610a46565b828202828482816136cd57fe5b04146132e05760405162461bcd60e51b81526004018080602001828103825260218152602001806146756021913960400191505060405180910390fd5b60006132e083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506140ca565b6000610a567faf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef2136140c2565b60006132e083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061351e565b60008183106137c857816132e0565b5090919050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261382190849061412f565b505050565b610d167faf765835ed5af0d235b6c686724ad31fa90e06b3daf1c074d6cc398b8fcef213826140c6565b8015806138d6575060408051636eb1769f60e11b81523060048201526001600160a01b03848116602483015291519185169163dd62ed3e91604480820192602092909190829003018186803b1580156138a857600080fd5b505afa1580156138bc573d6000803e3d6000fd5b505050506040513d60208110156138d257600080fd5b5051155b6139115760405162461bcd60e51b81526004018080602001828103825260368152602001806147df6036913960400191505060405180910390fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663095ea7b360e01b17905261382190849061412f565b610d167ff1a169aa0f736c2813818fdfbdc5755c31e0839c8f49831a16543496b28574ea826140c6565b60cf805460010190819055836139dd576040805162461bcd60e51b815260206004820152601060248201526f043616e6e6f74206465706f73697420360841b604482015290519081900360640190fd5b6001600160a01b038216613a31576040805162461bcd60e51b81526020600482015260166024820152751a1bdb19195c881b5d5cdd081899481919599a5b995960521b604482015290519081900360640190fd5b613a396125d5565b1580613a575750613a486125d5565b613a5485610e9b6120b0565b11155b613aa8576040805162461bcd60e51b815260206004820152601c60248201527f43616e6e6f74206465706f736974206d6f7265207468616e2063617000000000604482015290519081900360640190fd5b6000613ab261293e565b6001600160a01b031614613b6c57613ac861293e565b6001600160a01b031663c2a2a07b6040518163ffffffff1660e01b815260040160206040518083038186803b158015613b0057600080fd5b505afa158015613b14573d6000803e3d6000fd5b505050506040513d6020811015613b2a57600080fd5b5051613b6c576040805162461bcd60e51b815260206004820152600c60248201526b2a37b79036bab1b41030b93160a11b604482015290519081900360640190fd5b6000613b76610df5565b15613ba357613b9e613b86610dfb565b6110e3613b91610df5565b889063ffffffff6136b116565b613ba5565b845b9050613bb183826142e7565b613bd6843087613bbf611ee7565b6001600160a01b031692919063ffffffff6143d916565b613be561125f86610e9b61374c565b6040805186815290516001600160a01b038516917fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c919081900360200190a25060cf548114610def576040805162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6000610a567f39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a6140c2565b6000610a567fa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff6140c2565b6000610a567fb441b53a4e42c2ca9182bc7ede99bedba7a5d9360d9dfbd31fa8ee2dc85906106140c2565b6000610a567f1994607607e11d53306ef62e45e3bd85762c58d9bf38b5578bc4a258a26a73716140c2565b6000613d3161293e565b6001600160a01b03161415613d88576040805162461bcd60e51b815260206004820152601860248201527714dd1c985d1959de481b5d5cdd081899481919599a5b995960421b604482015290519081900360640190fd5b6000613d92612966565b90508015610d1657613dae613da561293e565b8261122e611ee7565b6040805182815290517fa09b7ae452b7bffb9e204c3a016e80caeecf46f554d112644f36fa114dac6ffa9181900360200190a150565b610d167f1994607607e11d53306ef62e45e3bd85762c58d9bf38b5578bc4a258a26a7371826140c6565b610d167f39122c9adfb653455d0c05043bd52fcfbc2be864e832efd3abc72ce5a3d7ed5a826140c6565b610d167f469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed32308826140c6565b610d167f0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e28826140c6565b610d167fa66bc57d4b4eed7c7687876ca77997588987307cb13ecc23f5e52725192e5fff826140c6565b610d167f82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf0826140c6565b610d167f6d02338b2e4c913c0f7d380e2798409838a48a2c4d57d52742a808c82d713d8b826140c6565b6000610a567f3bc747f4b148b37be485de3223c90b4468252967d2ea7f9fcbd8b6e653f434c96140c2565b7fa7ec62784904ff31cbcc32d09932a58e7f1e4476e1d041995b37c917990b16dc55565b6000610a567f0df75d4bdb87be8e3e04e1dc08ec1c98ed6c4147138e5789f0bd448c5c8e1e286140c2565b6000610a567f82ddc3be3f0c1a6870327f78f4979a0b37b21b16736ef5be6a7a7a35e530bcf06140c2565b6000610a567ff1a169aa0f736c2813818fdfbdc5755c31e0839c8f49831a16543496b28574ea6140c2565b6000610a567f56e7c0e75875c6497f0de657009613a32558904b5c10771a825cc330feff7e726140c2565b600054610100900460ff168061401e575061401e6133ba565b8061402c575060005460ff16155b6140675760405162461bcd60e51b815260040180806020018281038252602e8152602001806146be602e913960400191505060405180910390fd5b600054610100900460ff16158015614092576000805460ff1961ff0019909116610100171660011790555b612c1e82613f35565b6000610a567f469a3bad2fab7b936c45eecd1f5da52af89cead3e2ed7f732b6f3fc92ed323085b5490565b9055565b600081836141195760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561357257818101518382015260200161355a565b50600083858161412557fe5b0495945050505050565b614141826001600160a01b0316614433565b614192576040805162461bcd60e51b815260206004820152601f60248201527f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e747261637400604482015290519081900360640190fd5b60006060836001600160a01b0316836040518082805190602001908083835b602083106141d05780518252601f1990920191602091820191016141b1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114614232576040519150601f19603f3d011682016040523d82523d6000602084013e614237565b606091505b50915091508161428e576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b805115610def578080602001905160208110156142aa57600080fd5b5051610def5760405162461bcd60e51b815260040180806020018281038252602a8152602001806147b5602a913960400191505060405180910390fd5b6001600160a01b038216614342576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b603554614355908263ffffffff61328616565b6035556001600160a01b038216600090815260336020526040902054614381908263ffffffff61328616565b6001600160a01b03831660008181526033602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b604080516001600160a01b0385811660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052610def90859061412f565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061446757508115155b949350505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106144b057805160ff19168380011785556144dd565b828001600101855582156144dd579182015b828111156144dd5782518255916020019190600101906144c2565b506144e99291506144ed565b5090565b610a2b91905b808211156144e957600081556001016144f356fe5468652063616c6c6572206d75737420626520636f6e74726f6c6c6572206f7220676f7665726e616e636545524332303a207472616e7366657220746f20746865207a65726f206164647265737364656e6f6d696e61746f72206d7573742062652067726561746572207468616e203045524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737374686520737472617465677920646f6573206e6f742062656c6f6e6720746f2074686973207661756c7464656e6f6d696e61746f72206d7573742062652067726561746572207468616e206f7220657175616c20746f20746865206e756d657261746f7245524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e63655661756c7420756e6465726c79696e67206d757374206d6174636820537472617465677920756e6465726c79696e67536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a65645468652073747261746567792065786973747320616e64207377697463682074696d656c6f636b20646964206e6f7420656c61707365207965746e756d6265724f66536861726573206d7573742062652067726561746572207468616e203045524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f20616464726573735361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565645361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa265627a7a72315820fee82ab2daa3b95d6e5bf8dcc990d4a433fe38ea511b97831adcece40e4eec0964736f6c63430005100032
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.