Feature Tip: Add private address tag to any address under My Name Tag !
Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 27 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Transfer Ownersh... | 19079734 | 383 days ago | IN | 0 ETH | 0.00037269 | ||||
Set Weight Updat... | 19079677 | 383 days ago | IN | 0 ETH | 0.00061009 | ||||
Set Pause Manage... | 19079657 | 383 days ago | IN | 0 ETH | 0.00098127 | ||||
Set Pause Manage... | 19079653 | 383 days ago | IN | 0 ETH | 0.00098127 | ||||
Set Pause Manage... | 19079651 | 383 days ago | IN | 0 ETH | 0.00098127 | ||||
Set Pause Manage... | 19079649 | 383 days ago | IN | 0 ETH | 0.00098112 | ||||
Set Pause Manage... | 19079647 | 383 days ago | IN | 0 ETH | 0.00120357 | ||||
Set Price Oracle | 19079522 | 383 days ago | IN | 0 ETH | 0.00036444 | ||||
Set Fee Recipien... | 19079373 | 383 days ago | IN | 0 ETH | 0.00056882 | ||||
Add Pool | 19079301 | 383 days ago | IN | 0 ETH | 0.00202152 | ||||
Add Pool | 19079299 | 383 days ago | IN | 0 ETH | 0.00202152 | ||||
Set Minimum Tain... | 19079286 | 383 days ago | IN | 0 ETH | 0.00122372 | ||||
Set Minimum Tain... | 19079282 | 383 days ago | IN | 0 ETH | 0.00142724 | ||||
Set Minimum Tain... | 19079273 | 383 days ago | IN | 0 ETH | 0.00131038 | ||||
Update Weights | 19079229 | 383 days ago | IN | 0 ETH | 0.0221747 | ||||
Update Weights | 19079166 | 383 days ago | IN | 0 ETH | 0.01984643 | ||||
Add Pool | 19070851 | 384 days ago | IN | 0 ETH | 0.00385054 | ||||
Update Weights | 19070844 | 384 days ago | IN | 0 ETH | 0.02406131 | ||||
Set Inflation Ma... | 19070687 | 384 days ago | IN | 0 ETH | 0.00066717 | ||||
Set Default Pool... | 19070217 | 384 days ago | IN | 0 ETH | 0.00132792 | ||||
Set Price Oracle | 19036227 | 389 days ago | IN | 0 ETH | 0.0018988 | ||||
Set Convex Handl... | 19036192 | 389 days ago | IN | 0 ETH | 0.00189384 | ||||
Set Curve Handle... | 19036186 | 389 days ago | IN | 0 ETH | 0.00189644 | ||||
Initialize | 19036178 | 389 days ago | IN | 0 ETH | 0.00204468 | ||||
Set Inflation Ma... | 19036159 | 389 days ago | IN | 0 ETH | 0.00121304 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
Controller
Compiler Version
v0.8.17+commit.8df45f5f
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "IERC20Metadata.sol"; import "EnumerableSet.sol"; import "Ownable.sol"; import "Initializable.sol"; import "ScaledMath.sol"; import "IController.sol"; import "ILpTokenStaker.sol"; import "IPoolAdapter.sol"; import "IFeeRecipient.sol"; import "ILpToken.sol"; import "IBooster.sol"; import "IBonding.sol"; contract Controller is IController, Ownable, Initializable { using EnumerableSet for EnumerableSet.AddressSet; using ScaledMath for uint256; uint256 public constant MAX_WEIGHT_UPDATE_MIN_DELAY = 21 days; uint256 public constant MIN_WEIGHT_UPDATE_MIN_DELAY = 1 days; uint256 internal constant _MAX_TAINTED_USD_AMOUNT = 10_000e18; EnumerableSet.AddressSet internal _pools; EnumerableSet.AddressSet internal _activePools; EnumerableSet.AddressSet internal _pauseManagers; EnumerableSet.AddressSet internal _multiDepositsWithdrawsWhitelist; mapping(address => uint256) internal _minimumTaintedTransferAmount; address public immutable cncToken; address public override convexBooster = address(0xF403C135812408BFbE8713b5A23a04b3D48AAE31); address public override curveHandler; address public override convexHandler; IGenericOracle public override priceOracle; ICurveRegistryCache public override curveRegistryCache; IInflationManager public override inflationManager; ILpTokenStaker public override lpTokenStaker; IBonding public override bonding; IFeeRecipient public override feeRecipient; mapping(address => IPoolAdapter) internal _customPoolAdapters; IPoolAdapter public override defaultPoolAdapter; uint256 public weightUpdateMinDelay; mapping(address => uint256) public lastWeightUpdate; constructor(address cncToken_, address curveRegistryCacheAddress_) { cncToken = cncToken_; curveRegistryCache = ICurveRegistryCache(curveRegistryCacheAddress_); } function initialize(address _lpTokenStaker) external onlyOwner initializer { lpTokenStaker = ILpTokenStaker(_lpTokenStaker); } /// @notice shut downs the current lp token staker and sets a new one function switchLpTokenStaker(address _lpTokenStaker) external onlyOwner { lpTokenStaker.shutdown(); lpTokenStaker = ILpTokenStaker(_lpTokenStaker); for (uint256 i; i < _pools.length(); i++) { lpTokenStaker.checkpoint(_pools.at(i)); } } function listPools() external view override returns (address[] memory) { return _pools.values(); } function listActivePools() external view override returns (address[] memory) { return _activePools.values(); } function addPool(address poolAddress) external override onlyOwner { require(_pools.add(poolAddress), "failed to add pool"); require(_activePools.add(poolAddress), "failed to add pool"); lpTokenStaker.checkpoint(poolAddress); emit PoolAdded(poolAddress); } function removePool(address poolAddress) external override onlyOwner { require(_pools.remove(poolAddress), "failed to remove pool"); require(!_activePools.contains(poolAddress), "shutdown the pool before removing it"); emit PoolRemoved(poolAddress); } function shutdownPool(address poolAddress) external override onlyOwner { require(_activePools.remove(poolAddress), "failed to remove pool"); IConicPool(poolAddress).shutdownPool(); inflationManager.updatePoolWeights(); emit PoolShutdown(poolAddress); } function isPool(address poolAddress) external view override returns (bool) { return _pools.contains(poolAddress); } function isActivePool(address poolAddress) external view override returns (bool) { return _activePools.contains(poolAddress); } function updateWeights(WeightUpdate memory update) public override onlyOwner { require( lastWeightUpdate[update.conicPoolAddress] + weightUpdateMinDelay < block.timestamp, "weight update delay not elapsed" ); IConicPool(update.conicPoolAddress).updateWeights(update.weights); lastWeightUpdate[update.conicPoolAddress] = block.timestamp; } function updateAllWeights(WeightUpdate[] memory weights) external override onlyOwner { for (uint256 i; i < weights.length; i++) { updateWeights(weights[i]); } } function setConvexBooster(address _convexBooster) external override onlyOwner { require(IBooster(convexBooster).isShutdown(), "current booster is not shutdown"); require(_convexBooster != convexBooster, "same convex booster"); convexBooster = _convexBooster; emit ConvexBoosterSet(_convexBooster); } function setCurveHandler(address _curveHandler) external override onlyOwner { require(_curveHandler != curveHandler, "same curve handler"); curveHandler = _curveHandler; emit CurveHandlerSet(_curveHandler); } function setConvexHandler(address _convexHandler) external override onlyOwner { require(_convexHandler != convexHandler, "same convex handler"); convexHandler = _convexHandler; emit ConvexHandlerSet(_convexHandler); } function setInflationManager(address manager) external onlyOwner { require(manager != address(0), "cannot set to zero address"); require(manager != address(inflationManager), "same inflation manager"); inflationManager = IInflationManager(manager); emit InflationManagerSet(manager); } function setPriceOracle(address oracle) external override onlyOwner { require(oracle != address(0), "cannot set to zero address"); require(oracle != address(priceOracle), "same price oracle"); priceOracle = IGenericOracle(oracle); emit PriceOracleSet(oracle); } function setCurveRegistryCache(address curveRegistryCache_) external override onlyOwner { require(curveRegistryCache_ != address(0), "cannot set to zero address"); require(curveRegistryCache_ != address(curveRegistryCache), "same curve registry cache"); curveRegistryCache = ICurveRegistryCache(curveRegistryCache_); emit CurveRegistryCacheSet(curveRegistryCache_); } function poolAdapterFor(address pool) external view override returns (IPoolAdapter) { IPoolAdapter adapter = _customPoolAdapters[pool]; return address(adapter) == address(0) ? defaultPoolAdapter : adapter; } function setDefaultPoolAdapter(address poolAdapter) external override onlyOwner { require(poolAdapter != address(0), "cannot set to zero address"); require(poolAdapter != address(defaultPoolAdapter), "same default pool adapter"); defaultPoolAdapter = IPoolAdapter(poolAdapter); emit DefaultPoolAdapterSet(poolAdapter); } function setCustomPoolAdapter(address pool, address poolAdapter) external override onlyOwner { require(poolAdapter != address(_customPoolAdapters[pool]), "same custom pool adapter"); _customPoolAdapters[pool] = IPoolAdapter(poolAdapter); emit CustomPoolAdapterSet(pool, poolAdapter); } function setBonding(address _bonding) external override onlyOwner { require(address(_bonding) != address(0), "cannot set to zero address"); require(address(_bonding) != address(bonding), "same bonding"); bonding = IBonding(_bonding); emit BondingSet(_bonding); } function setFeeRecipient(address _feeRecipient) external override onlyOwner { require(address(_feeRecipient) != address(0), "cannot set to zero address"); require(address(_feeRecipient) != address(feeRecipient), "same fee recipient"); feeRecipient = IFeeRecipient(_feeRecipient); emit FeeRecipientSet(_feeRecipient); } function setWeightUpdateMinDelay(uint256 delay) external override onlyOwner { require(delay < MAX_WEIGHT_UPDATE_MIN_DELAY, "delay too long"); require(delay > MIN_WEIGHT_UPDATE_MIN_DELAY, "delay too short"); require(delay != weightUpdateMinDelay, "same delay"); weightUpdateMinDelay = delay; emit WeightUpdateMinDelaySet(delay); } function isPauseManager(address account) external view override returns (bool) { return _pauseManagers.contains(account); } function listPauseManagers() external view override returns (address[] memory) { return _pauseManagers.values(); } function setPauseManager(address account, bool isManager) external override onlyOwner { bool changed = isManager ? _pauseManagers.add(account) : _pauseManagers.remove(account); if (changed) emit PauseManagerSet(account, isManager); } function setAllowedMultipleDepositsWithdraws(address account, bool allowed) external onlyOwner { bool changed; if (allowed) changed = _multiDepositsWithdrawsWhitelist.add(account); else changed = _multiDepositsWithdrawsWhitelist.remove(account); if (changed) emit MultiDepositsWithdrawsWhitelistSet(account, allowed); } function isAllowedMultipleDepositsWithdraws(address account) external view returns (bool) { return _multiDepositsWithdrawsWhitelist.contains(account); } function getMultipleDepositsWithdrawsWhitelist() external view returns (address[] memory) { return _multiDepositsWithdrawsWhitelist.values(); } function setMinimumTaintedTransferAmount( address token, uint256 amount ) external override onlyOwner { require(amount != _minimumTaintedTransferAmount[token], "same amount"); address conicPool = ILpToken(token).minter(); IERC20Metadata underlying = IConicPool(conicPool).underlying(); uint256 underlyingPrice = priceOracle.getUSDPrice(address(underlying)); uint256 scaledAmount = amount.convertScale(underlying.decimals(), 18); uint256 usdAmount = scaledAmount.mulDown(underlyingPrice); require(usdAmount <= _MAX_TAINTED_USD_AMOUNT, "amount too high"); _minimumTaintedTransferAmount[token] = amount; emit MinimumTaintedTransferAmountSet(token, amount); } function getMinimumTaintedTransferAmount(address token) external view returns (uint256) { return _minimumTaintedTransferAmount[token]; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity ^0.8.0; import "IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 amount) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (utils/structs/EnumerableSet.sol) // This file was procedurally generated from scripts/generate/templates/EnumerableSet.js. pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ```solidity * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. * * [WARNING] * ==== * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure * unusable. * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info. * * In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an * array of EnumerableSet. * ==== */ library EnumerableSet { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastValue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastValue; // Update the index for the moved value set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { bytes32[] memory store = _values(set._inner); bytes32[] memory result; /// @solidity memory-safe-assembly assembly { result := store } return result; } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; /// @solidity memory-safe-assembly assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values in the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; /// @solidity memory-safe-assembly assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @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 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. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (proxy/utils/Initializable.sol) pragma solidity ^0.8.2; import "Address.sol"; /** * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in * case an upgrade adds a module that needs to be initialized. * * For example: * * [.hljs-theme-light.nopadding] * ```solidity * contract MyToken is ERC20Upgradeable { * function initialize() initializer public { * __ERC20_init("MyToken", "MTK"); * } * } * * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable { * function initializeV2() reinitializer(2) public { * __ERC20Permit_init("MyToken"); * } * } * ``` * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. * * [CAUTION] * ==== * Avoid leaving a contract uninitialized. * * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed: * * [.hljs-theme-light.nopadding] * ``` * /// @custom:oz-upgrades-unsafe-allow constructor * constructor() { * _disableInitializers(); * } * ``` * ==== */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. * @custom:oz-retyped-from bool */ uint8 private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Triggered when the contract has been initialized or reinitialized. */ event Initialized(uint8 version); /** * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope, * `onlyInitializing` functions can be used to initialize parent contracts. * * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a * constructor. * * Emits an {Initialized} event. */ modifier initializer() { bool isTopLevelCall = !_initializing; require( (isTopLevelCall && _initialized < 1) || (!Address.isContract(address(this)) && _initialized == 1), "Initializable: contract is already initialized" ); _initialized = 1; if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _initializing = false; emit Initialized(1); } } /** * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be * used to initialize parent contracts. * * A reinitializer may be used after the original initialization step. This is essential to configure modules that * are added through upgrades and that require initialization. * * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer` * cannot be nested. If one is invoked in the context of another, execution will revert. * * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in * a contract, executing them in the right order is up to the developer or operator. * * WARNING: setting the version to 255 will prevent any future reinitialization. * * Emits an {Initialized} event. */ modifier reinitializer(uint8 version) { require(!_initializing && _initialized < version, "Initializable: contract is already initialized"); _initialized = version; _initializing = true; _; _initializing = false; emit Initialized(version); } /** * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the * {initializer} and {reinitializer} modifiers, directly or indirectly. */ modifier onlyInitializing() { require(_initializing, "Initializable: contract is not initializing"); _; } /** * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call. * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized * to any version. It is recommended to use this to lock implementation contracts that are designed to be called * through proxies. * * Emits an {Initialized} event the first time it is successfully executed. */ function _disableInitializers() internal virtual { require(!_initializing, "Initializable: contract is initializing"); if (_initialized != type(uint8).max) { _initialized = type(uint8).max; emit Initialized(type(uint8).max); } } /** * @dev Returns the highest version that has been initialized. See {reinitializer}. */ function _getInitializedVersion() internal view returns (uint8) { return _initialized; } /** * @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}. */ function _isInitializing() internal view returns (bool) { return _initializing; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @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 * * Furthermore, `isContract` will also return true if the target contract within * the same transaction is already scheduled for destruction by `SELFDESTRUCT`, * which only has an effect at the end of a transaction. * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @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://consensys.net/diligence/blog/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.8.0/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata, errorMessage); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract. * * _Available since v4.8._ */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata, string memory errorMessage ) internal view returns (bytes memory) { if (success) { if (returndata.length == 0) { // only check isContract if the call was successful and the return data is empty // otherwise we already know that it was a contract require(isContract(target), "Address: call to non-contract"); } return returndata; } else { _revert(returndata, errorMessage); } } /** * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason or using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { _revert(returndata, errorMessage); } } function _revert(bytes memory returndata, string memory errorMessage) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; library ScaledMath { uint256 internal constant DECIMALS = 18; uint256 internal constant ONE = 10 ** DECIMALS; function mulDown(uint256 a, uint256 b) internal pure returns (uint256) { return (a * b) / ONE; } function mulDown(uint256 a, uint256 b, uint256 decimals) internal pure returns (uint256) { return (a * b) / (10 ** decimals); } function divDown(uint256 a, uint256 b) internal pure returns (uint256) { return (a * ONE) / b; } function divDown(uint256 a, uint256 b, uint256 decimals) internal pure returns (uint256) { return (a * 10 ** decimals) / b; } function divUp(uint256 a, uint256 b) internal pure returns (uint256) { if (a == 0) { return 0; } return ((a * ONE) - 1) / b + 1; } function mulDown(int256 a, int256 b) internal pure returns (int256) { return (a * b) / int256(ONE); } function mulDownUint128(uint128 a, uint128 b) internal pure returns (uint128) { return (a * b) / uint128(ONE); } function mulDown(int256 a, int256 b, uint256 decimals) internal pure returns (int256) { return (a * b) / int256(10 ** decimals); } function divDown(int256 a, int256 b) internal pure returns (int256) { return (a * int256(ONE)) / b; } function divDownUint128(uint128 a, uint128 b) internal pure returns (uint128) { return (a * uint128(ONE)) / b; } function divDown(int256 a, int256 b, uint256 decimals) internal pure returns (int256) { return (a * int256(10 ** decimals)) / b; } function convertScale( uint256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (uint256) { if (fromDecimals == toDecimals) return a; if (fromDecimals > toDecimals) return downscale(a, fromDecimals, toDecimals); return upscale(a, fromDecimals, toDecimals); } function convertScale( int256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (int256) { if (fromDecimals == toDecimals) return a; if (fromDecimals > toDecimals) return downscale(a, fromDecimals, toDecimals); return upscale(a, fromDecimals, toDecimals); } function upscale( uint256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (uint256) { return a * (10 ** (toDecimals - fromDecimals)); } function downscale( uint256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (uint256) { return a / (10 ** (fromDecimals - toDecimals)); } function upscale( int256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (int256) { return a * int256(10 ** (toDecimals - fromDecimals)); } function downscale( int256 a, uint8 fromDecimals, uint8 toDecimals ) internal pure returns (int256) { return a / int256(10 ** (fromDecimals - toDecimals)); } function intPow(uint256 a, uint256 n) internal pure returns (uint256) { uint256 result = ONE; for (uint256 i; i < n; ) { result = mulDown(result, a); unchecked { ++i; } } return result; } function absSub(uint256 a, uint256 b) internal pure returns (uint256) { unchecked { return a >= b ? a - b : b - a; } } function max(uint256 a, uint256 b) internal pure returns (uint256) { return a >= b ? a : b; } function min(uint256 a, uint256 b) internal pure returns (uint256) { return a <= b ? a : b; } }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "IConicPoolWeightManagement.sol"; import "IConicPool.sol"; import "IGenericOracle.sol"; import "IInflationManager.sol"; import "ILpTokenStaker.sol"; import "IBonding.sol"; import "IPoolAdapter.sol"; import "IFeeRecipient.sol"; import "ICurveRegistryCache.sol"; interface IController { event PoolAdded(address indexed pool); event PoolRemoved(address indexed pool); event PoolShutdown(address indexed pool); event ConvexBoosterSet(address convexBooster); event CurveHandlerSet(address curveHandler); event ConvexHandlerSet(address convexHandler); event CurveRegistryCacheSet(address curveRegistryCache); event InflationManagerSet(address inflationManager); event BondingSet(address bonding); event FeeRecipientSet(address feeRecipient); event PriceOracleSet(address priceOracle); event WeightUpdateMinDelaySet(uint256 weightUpdateMinDelay); event PauseManagerSet(address indexed manager, bool isManager); event MultiDepositsWithdrawsWhitelistSet(address pool, bool allowed); event MinimumTaintedTransferAmountSet(address indexed token, uint256 amount); event DefaultPoolAdapterSet(address poolAdapter); event CustomPoolAdapterSet(address indexed pool, address poolAdapter); struct WeightUpdate { address conicPoolAddress; IConicPoolWeightManagement.PoolWeight[] weights; } function initialize(address _lpTokenStaker) external; // inflation manager function inflationManager() external view returns (IInflationManager); function setInflationManager(address manager) external; // views function curveRegistryCache() external view returns (ICurveRegistryCache); // pool adapter function poolAdapterFor(address pool) external view returns (IPoolAdapter); function defaultPoolAdapter() external view returns (IPoolAdapter); function setDefaultPoolAdapter(address poolAdapter) external; function setCustomPoolAdapter(address pool, address poolAdapter) external; /// lp token staker function switchLpTokenStaker(address _lpTokenStaker) external; function lpTokenStaker() external view returns (ILpTokenStaker); // bonding function bonding() external view returns (IBonding); function setBonding(address _bonding) external; // fees function feeRecipient() external view returns (IFeeRecipient); function setFeeRecipient(address _feeRecipient) external; // oracle function priceOracle() external view returns (IGenericOracle); function setPriceOracle(address oracle) external; // pool functions function listPools() external view returns (address[] memory); function listActivePools() external view returns (address[] memory); function isPool(address poolAddress) external view returns (bool); function isActivePool(address poolAddress) external view returns (bool); function addPool(address poolAddress) external; function shutdownPool(address poolAddress) external; function removePool(address poolAddress) external; function cncToken() external view returns (address); function lastWeightUpdate(address poolAddress) external view returns (uint256); function updateWeights(WeightUpdate memory update) external; function updateAllWeights(WeightUpdate[] memory weights) external; // handler functions function convexBooster() external view returns (address); function curveHandler() external view returns (address); function convexHandler() external view returns (address); function setConvexBooster(address _convexBooster) external; function setCurveHandler(address _curveHandler) external; function setConvexHandler(address _convexHandler) external; function setCurveRegistryCache(address curveRegistryCache_) external; function setWeightUpdateMinDelay(uint256 delay) external; function isPauseManager(address account) external view returns (bool); function listPauseManagers() external view returns (address[] memory); function setPauseManager(address account, bool isManager) external; // deposit/withdrawal whitelist function isAllowedMultipleDepositsWithdraws(address poolAddress) external view returns (bool); function setAllowedMultipleDepositsWithdraws(address account, bool allowed) external; function getMultipleDepositsWithdrawsWhitelist() external view returns (address[] memory); // tainted transfer amount function setMinimumTaintedTransferAmount(address token, uint256 amount) external; function getMinimumTaintedTransferAmount(address token) external view returns (uint256); // constants function MAX_WEIGHT_UPDATE_MIN_DELAY() external view returns (uint256); function MIN_WEIGHT_UPDATE_MIN_DELAY() external view returns (uint256); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IConicPoolWeightManagement { struct PoolWeight { address poolAddress; uint256 weight; } function addPool(address pool) external; function removePool(address pool) external; function updateWeights(PoolWeight[] memory poolWeights) external; function handleDepeggedCurvePool(address curvePool_) external; function handleInvalidConvexPid(address pool) external returns (uint256); function allPools() external view returns (address[] memory); function poolsCount() external view returns (uint256); function getPoolAtIndex(uint256 _index) external view returns (address); function getWeight(address curvePool) external view returns (uint256); function getWeights() external view returns (PoolWeight[] memory); function isRegisteredPool(address _pool) external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "ILpToken.sol"; import "IRewardManager.sol"; import "IOracle.sol"; import "IController.sol"; import "IPausable.sol"; import "IConicPoolWeightManagement.sol"; interface IConicPool is IConicPoolWeightManagement, IPausable { event Deposit( address indexed sender, address indexed receiver, uint256 depositedAmount, uint256 lpReceived ); event Withdraw(address indexed account, uint256 amount); event NewWeight(address indexed curvePool, uint256 newWeight); event NewMaxIdleCurveLpRatio(uint256 newRatio); event ClaimedRewards(uint256 claimedCrv, uint256 claimedCvx); event HandledDepeggedCurvePool(address curvePool_); event HandledInvalidConvexPid(address curvePool_, uint256 pid_); event CurvePoolAdded(address curvePool_); event CurvePoolRemoved(address curvePool_); event Shutdown(); event DepegThresholdUpdated(uint256 newThreshold); event MaxDeviationUpdated(uint256 newMaxDeviation); event RebalancingRewardsEnabledSet(bool enabled); event EmergencyRebalancingRewardFactorUpdated(uint256 factor); struct PoolWithAmount { address poolAddress; uint256 amount; } function underlying() external view returns (IERC20Metadata); function lpToken() external view returns (ILpToken); function rewardManager() external view returns (IRewardManager); function depegThreshold() external view returns (uint256); function maxIdleCurveLpRatio() external view returns (uint256); function setMaxIdleCurveLpRatio(uint256 value) external; function setMaxDeviation(uint256 maxDeviation_) external; function updateDepegThreshold(uint256 value) external; function depositFor( address _account, uint256 _amount, uint256 _minLpReceived, bool stake ) external returns (uint256); function deposit(uint256 _amount, uint256 _minLpReceived) external returns (uint256); function deposit( uint256 _amount, uint256 _minLpReceived, bool stake ) external returns (uint256); function exchangeRate() external view returns (uint256); function usdExchangeRate() external view returns (uint256); function unstakeAndWithdraw(uint256 _amount, uint256 _minAmount) external returns (uint256); function unstakeAndWithdraw( uint256 _amount, uint256 _minAmount, address _to ) external returns (uint256); function withdraw(uint256 _amount, uint256 _minAmount) external returns (uint256); function withdraw(uint256 _amount, uint256 _minAmount, address _to) external returns (uint256); function getAllocatedUnderlying() external view returns (PoolWithAmount[] memory); function rebalancingRewardActive() external view returns (bool); function totalDeviationAfterWeightUpdate() external view returns (uint256); function computeTotalDeviation() external view returns (uint256); /// @notice returns the total amount of funds held by this pool in terms of underlying function totalUnderlying() external view returns (uint256); function getTotalAndPerPoolUnderlying() external view returns ( uint256 totalUnderlying_, uint256 totalAllocated_, uint256[] memory perPoolUnderlying_ ); /// @notice same as `totalUnderlying` but returns a cached version /// that might be slightly outdated if oracle prices have changed /// @dev this is useful in cases where we want to reduce gas usage and do /// not need a precise value function cachedTotalUnderlying() external view returns (uint256); function updateRewardSpendingApproval(address token, bool approved) external; function shutdownPool() external; function isShutdown() external view returns (bool); function isBalanced() external view returns (bool); function rebalancingRewardsEnabled() external view returns (bool); function setRebalancingRewardsEnabled(bool enabled) external; function getAllUnderlyingCoins() external view returns (address[] memory result); function rebalancingRewardsFactor() external view returns (uint256); function rebalancingRewardsActivatedAt() external view returns (uint64); function getWeights() external view returns (PoolWeight[] memory); function runSanityChecks() external; }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "IERC20Metadata.sol"; interface ILpToken is IERC20Metadata { function minter() external view returns (address); function mint(address account, uint256 amount, address ubo) external returns (uint256); function burn(address _owner, uint256 _amount, address ubo) external returns (uint256); function taint(address from, address to, uint256 amount) external; }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IRewardManager { event ClaimedRewards(uint256 claimedCrv, uint256 claimedCvx); event SoldRewardTokens(uint256 targetTokenReceived); event ExtraRewardAdded(address reward); event ExtraRewardRemoved(address reward); event ExtraRewardsCurvePoolSet(address extraReward, address curvePool); event FeesSet(uint256 feePercentage); event FeesEnabled(uint256 feePercentage); event EarningsClaimed( address indexed claimedBy, uint256 cncEarned, uint256 crvEarned, uint256 cvxEarned ); function accountCheckpoint(address account) external; function poolCheckpoint() external returns (bool); function addExtraReward(address reward) external returns (bool); function addBatchExtraRewards(address[] memory rewards) external; function conicPool() external view returns (address); function setFeePercentage(uint256 _feePercentage) external; function claimableRewards( address account ) external view returns (uint256 cncRewards, uint256 crvRewards, uint256 cvxRewards); function claimEarnings() external returns (uint256, uint256, uint256); function claimPoolEarningsAndSellRewardTokens() external; function feePercentage() external view returns (uint256); function feesEnabled() external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IOracle { event TokenUpdated(address indexed token, address feed, uint256 maxDelay, bool isEthPrice); /// @notice returns the price in USD of symbol. function getUSDPrice(address token) external view returns (uint256); /// @notice returns if the given token is supported for pricing. function isTokenSupported(address token) external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "Ownable.sol"; import "IController.sol"; interface IPausable { event Paused(uint256 pausedUntil); event PauseDurationSet(uint256 pauseDuration); function controller() external view returns (IController); function pausedUntil() external view returns (uint256); function pauseDuration() external view returns (uint256); function isPaused() external view returns (bool); function setPauseDuration(uint256 _pauseDuration) external; function pause() external; }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "IOracle.sol"; interface IGenericOracle is IOracle { /// @notice returns the oracle to be used to price `token` function getOracle(address token) external view returns (IOracle); /// @notice converts the price of an LP token to the given underlying function curveLpToUnderlying( address curveLpToken, address underlying, uint256 curveLpAmount ) external view returns (uint256); /// @notice same as above but avoids fetching the underlying price again function curveLpToUnderlying( address curveLpToken, address underlying, uint256 curveLpAmount, uint256 underlyingPrice ) external view returns (uint256); /// @notice converts the price an underlying asset to a given Curve LP token function underlyingToCurveLp( address underlying, address curveLpToken, uint256 underlyingAmount ) external view returns (uint256); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IInflationManager { event TokensClaimed(address indexed pool, uint256 cncAmount); event RebalancingRewardHandlerAdded(address indexed pool, address indexed handler); event RebalancingRewardHandlerRemoved(address indexed pool, address indexed handler); event PoolWeightsUpdated(); function executeInflationRateUpdate() external; function updatePoolWeights() external; /// @notice returns the weights of the Conic pools to know how much inflation /// each of them will receive, as well as the total amount of USD value in all the pools function computePoolWeights() external view returns (address[] memory _pools, uint256[] memory poolWeights, uint256 totalUSDValue); function computePoolWeight( address pool ) external view returns (uint256 poolWeight, uint256 totalUSDValue); function currentInflationRate() external view returns (uint256); function getCurrentPoolInflationRate(address pool) external view returns (uint256); function handleRebalancingRewards( address account, uint256 deviationBefore, uint256 deviationAfter ) external; function addPoolRebalancingRewardHandler( address poolAddress, address rebalancingRewardHandler ) external; function removePoolRebalancingRewardHandler( address poolAddress, address rebalancingRewardHandler ) external; function rebalancingRewardHandlers( address poolAddress ) external view returns (address[] memory); function hasPoolRebalancingRewardHandler( address poolAddress, address handler ) external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface ILpTokenStaker { event LpTokenStaked(address indexed account, uint256 amount); event LpTokenUnstaked(address indexed account, uint256 amount); event TokensClaimed(address indexed pool, uint256 cncAmount); event Shutdown(); function stake(uint256 amount, address conicPool) external; function unstake(uint256 amount, address conicPool) external; function stakeFor(uint256 amount, address conicPool, address account) external; function unstakeFor(uint256 amount, address conicPool, address account) external; function unstakeFrom(uint256 amount, address account) external; function getUserBalanceForPool( address conicPool, address account ) external view returns (uint256); function getBalanceForPool(address conicPool) external view returns (uint256); function updateBoost(address user) external; function claimCNCRewardsForPool(address pool) external; function claimableCnc(address pool) external view returns (uint256); function checkpoint(address pool) external returns (uint256); function shutdown() external; function getBoost(address user) external view returns (uint256); function isShutdown() external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IBonding { event CncStartPriceSet(uint256 startPrice); event PriceIncreaseFactorSet(uint256 factor); event MinBondingAmountSet(uint256 amount); event Bonded( address indexed account, address indexed recipient, uint256 lpTokenAmount, uint256 cncReceived, uint256 lockTime ); event DebtPoolSet(address indexed pool); event DebtPoolFeesClaimed(uint256 crvAmount, uint256 cvxAmount, uint256 cncAmount); event StreamClaimed(address indexed account, uint256 amount); event BondingStarted(uint256 amount, uint256 epochs); event RemainingCNCRecovered(uint256 amount); function startBonding() external; function setCncStartPrice(uint256 _cncStartPrice) external; function setCncPriceIncreaseFactor(uint256 _priceIncreaseFactor) external; function setMinBondingAmount(uint256 _minBondingAmount) external; function setDebtPool(address _debtPool) external; function bondCncCrvUsd( uint256 lpTokenAmount, uint256 minCncReceived, uint64 cncLockTime ) external returns (uint256); function recoverRemainingCNC() external; function claimStream() external; function claimFeesForDebtPool() external; function streamCheckpoint() external; function accountCheckpoint(address account) external; function computeCurrentCncBondPrice() external view returns (uint256); function cncAvailable() external view returns (uint256); function cncBondPrice() external view returns (uint256); function bondCncCrvUsdFor( uint256 lpTokenAmount, uint256 minCncReceived, uint64 cncLockTime, address recipient ) external returns (uint256); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IPoolAdapter { /// @notice This is to set which LP token price the value computation should use /// `Latest` uses a freshly computed price /// `Cached` uses the price in cache /// `Minimum` uses the minimum of these two enum PriceMode { Latest, Cached, Minimum } /// @notice Deposit `underlyingAmount` of `underlying` into `pool` /// @dev This function should be written with the assumption that it will be delegate-called into function deposit(address pool, address underlying, uint256 underlyingAmount) external; /// @notice Withdraw `underlyingAmount` of `underlying` from `pool` /// @dev This function should be written with the assumption that it will be delegate-called into function withdraw(address pool, address underlying, uint256 underlyingAmount) external; /// @notice Returns the amount of of assets that `conicPool` holds in `pool`, in terms of USD function computePoolValueInUSD( address conicPool, address pool ) external view returns (uint256 usdAmount); /// @notice Updates the price caches of the given pools function updatePriceCache(address pool) external; /// @notice Returns the amount of of assets that `conicPool` holds in `pool`, in terms of USD /// using the given price mode function computePoolValueInUSD( address conicPool, address pool, PriceMode priceMode ) external view returns (uint256 usdAmount); /// @notice Returns the amount of of assets that `conicPool` holds in `pool`, in terms of underlying function computePoolValueInUnderlying( address conicPool, address pool, address underlying, uint256 underlyingPrice ) external view returns (uint256 underlyingAmount); /// @notice Returns the amount of of assets that `conicPool` holds in `pool`, in terms of underlying /// using the given price mode function computePoolValueInUnderlying( address conicPool, address pool, address underlying, uint256 underlyingPrice, PriceMode priceMode ) external view returns (uint256 underlyingAmount); /// @notice Claim earnings of `conicPool` from `pool` function claimEarnings(address conicPool, address pool) external; /// @notice Returns the LP token of a given `pool` function lpToken(address pool) external view returns (address); /// @notice Returns true if `pool` supports `asset` function supportsAsset(address pool, address asset) external view returns (bool); /// @notice Returns the amount of CRV earned by `pool` on Convex function getCRVEarnedOnConvex( address account, address curvePool ) external view returns (uint256); /// @notice Executes a sanity check, e.g. checking for reentrancy function executeSanityCheck(address pool) external; /// @notice returns all the underlying coins of the pool function getAllUnderlyingCoins(address pool) external view returns (address[] memory); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; interface IFeeRecipient { event FeesReceived(address indexed sender, uint256 crvAmount, uint256 cvxAmount); function receiveFees(uint256 amountCrv, uint256 amountCvx) external; }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "IBooster.sol"; import "CurvePoolUtils.sol"; interface ICurveRegistryCache { event PoolInitialized(address indexed pool, uint256 indexed pid); function BOOSTER() external view returns (IBooster); function initPool(address pool_) external; function initPool(address pool_, uint256 pid_) external; function lpToken(address pool_) external view returns (address); function assetType(address pool_) external view returns (CurvePoolUtils.AssetType); function isRegistered(address pool_) external view returns (bool); function hasCoinDirectly(address pool_, address coin_) external view returns (bool); function hasCoinAnywhere(address pool_, address coin_) external view returns (bool); function basePool(address pool_) external view returns (address); function coinIndex(address pool_, address coin_) external view returns (int128); function nCoins(address pool_) external view returns (uint256); function coinIndices( address pool_, address from_, address to_ ) external view returns (int128, int128, bool); function decimals(address pool_) external view returns (uint256[] memory); function interfaceVersion(address pool_) external view returns (uint256); function poolFromLpToken(address lpToken_) external view returns (address); function coins(address pool_) external view returns (address[] memory); function getPid(address _pool) external view returns (uint256); function getRewardPool(address _pool) external view returns (address); function isShutdownPid(uint256 pid_) external view returns (bool); /// @notice this returns the underlying coins of a pool, including the underlying of the base pool /// if the given pool is a meta pool /// This does not return the LP token of the base pool as an underlying /// e.g. if the pool is 3CrvFrax, this will return FRAX, DAI, USDC, USDT function getAllUnderlyingCoins(address pool) external view returns (address[] memory); }
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.17; interface IBooster { function poolInfo( uint256 pid ) external view returns ( address lpToken, address token, address gauge, address crvRewards, address stash, bool shutdown ); function poolLength() external view returns (uint256); function deposit(uint256 _pid, uint256 _amount, bool _stake) external returns (bool); function withdraw(uint256 _pid, uint256 _amount) external returns (bool); function withdrawAll(uint256 _pid) external returns (bool); function depositAll(uint256 _pid, bool _stake) external returns (bool); function earmarkRewards(uint256 _pid) external returns (bool); function isShutdown() external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later pragma solidity 0.8.17; import "ICurvePoolV2.sol"; import "ICurvePoolV1.sol"; import "ScaledMath.sol"; library CurvePoolUtils { using ScaledMath for uint256; error NotWithinThreshold(address pool, uint256 assetA, uint256 assetB); /// @dev by default, allow for 30 bps deviation regardless of pool fees uint256 internal constant _DEFAULT_IMBALANCE_BUFFER = 30e14; /// @dev Curve scales the `fee` by 1e10 uint8 internal constant _CURVE_POOL_FEE_DECIMALS = 10; /// @dev allow imbalance to be buffer + 3x the fee, e.g. if fee is 3.6 bps and buffer is 30 bps, allow 40.8 bps uint256 internal constant _FEE_IMBALANCE_MULTIPLIER = 3; enum AssetType { USD, ETH, BTC, OTHER, CRYPTO } struct PoolMeta { address pool; uint256 numberOfCoins; AssetType assetType; uint256[] decimals; uint256[] prices; uint256[] imbalanceBuffers; } function ensurePoolBalanced(PoolMeta memory poolMeta) internal view { uint256 poolFee = ICurvePoolV1(poolMeta.pool).fee().convertScale( _CURVE_POOL_FEE_DECIMALS, 18 ); for (uint256 i = 0; i < poolMeta.numberOfCoins - 1; i++) { uint256 fromDecimals = poolMeta.decimals[i]; uint256 fromBalance = 10 ** fromDecimals; uint256 fromPrice = poolMeta.prices[i]; for (uint256 j = i + 1; j < poolMeta.numberOfCoins; j++) { uint256 toDecimals = poolMeta.decimals[j]; uint256 toPrice = poolMeta.prices[j]; uint256 toExpectedUnscaled = (fromBalance * fromPrice) / toPrice; uint256 toExpected = toExpectedUnscaled.convertScale( uint8(fromDecimals), uint8(toDecimals) ); uint256 toActual; if (poolMeta.assetType == AssetType.CRYPTO) { // Handling crypto pools toActual = ICurvePoolV2(poolMeta.pool).get_dy(i, j, fromBalance); } else { // Handling other pools toActual = ICurvePoolV1(poolMeta.pool).get_dy( int128(uint128(i)), int128(uint128(j)), fromBalance ); } uint256 _maxImbalanceBuffer = poolMeta.imbalanceBuffers[i].max( poolMeta.imbalanceBuffers[j] ); if (!_isWithinThreshold(toExpected, toActual, poolFee, _maxImbalanceBuffer)) revert NotWithinThreshold(poolMeta.pool, i, j); } } } function _isWithinThreshold( uint256 a, uint256 b, uint256 poolFee, uint256 imbalanceBuffer ) internal pure returns (bool) { if (imbalanceBuffer == 0) imbalanceBuffer = _DEFAULT_IMBALANCE_BUFFER; uint256 imbalanceTreshold = imbalanceBuffer + poolFee * _FEE_IMBALANCE_MULTIPLIER; if (a > b) return (a - b).divDown(a) <= imbalanceTreshold; return (b - a).divDown(b) <= imbalanceTreshold; } }
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.17; interface ICurvePoolV2 { function token() external view returns (address); function coins(uint256 i) external view returns (address); function factory() external view returns (address); function exchange( uint256 i, uint256 j, uint256 dx, uint256 min_dy, bool use_eth, address receiver ) external returns (uint256); function exchange_underlying( uint256 i, uint256 j, uint256 dx, uint256 min_dy, address receiver ) external returns (uint256); function add_liquidity( uint256[2] memory amounts, uint256 min_mint_amount, bool use_eth, address receiver ) external returns (uint256); function add_liquidity( uint256[2] memory amounts, uint256 min_mint_amount ) external returns (uint256); function add_liquidity( uint256[3] memory amounts, uint256 min_mint_amount, bool use_eth, address receiver ) external returns (uint256); function add_liquidity( uint256[3] memory amounts, uint256 min_mint_amount ) external returns (uint256); function remove_liquidity( uint256 _amount, uint256[2] memory min_amounts, bool use_eth, address receiver ) external; function remove_liquidity(uint256 _amount, uint256[2] memory min_amounts) external; function remove_liquidity( uint256 _amount, uint256[3] memory min_amounts, bool use_eth, address receiver ) external; function remove_liquidity(uint256 _amount, uint256[3] memory min_amounts) external; function remove_liquidity_one_coin( uint256 token_amount, uint256 i, uint256 min_amount, bool use_eth, address receiver ) external returns (uint256); function get_dy(uint256 i, uint256 j, uint256 dx) external view returns (uint256); function calc_token_amount(uint256[] memory amounts) external view returns (uint256); function calc_withdraw_one_coin( uint256 token_amount, uint256 i ) external view returns (uint256); function get_virtual_price() external view returns (uint256); }
// SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.17; interface ICurvePoolV1 { function get_virtual_price() external view returns (uint256); function add_liquidity(uint256[8] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[7] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[6] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[5] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[4] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[3] calldata amounts, uint256 min_mint_amount) external; function add_liquidity(uint256[2] calldata amounts, uint256 min_mint_amount) external; function remove_liquidity_imbalance( uint256[4] calldata amounts, uint256 max_burn_amount ) external; function remove_liquidity_imbalance( uint256[3] calldata amounts, uint256 max_burn_amount ) external; function remove_liquidity_imbalance( uint256[2] calldata amounts, uint256 max_burn_amount ) external; function lp_token() external view returns (address); function A_PRECISION() external view returns (uint256); function A_precise() external view returns (uint256); function remove_liquidity(uint256 _amount, uint256[3] calldata min_amounts) external; function exchange( int128 from, int128 to, uint256 _from_amount, uint256 _min_to_amount ) external; function coins(uint256 i) external view returns (address); function balances(uint256 i) external view returns (uint256); function get_dy(int128 i, int128 j, uint256 _dx) external view returns (uint256); function calc_token_amount( uint256[4] calldata amounts, bool deposit ) external view returns (uint256); function calc_token_amount( uint256[3] calldata amounts, bool deposit ) external view returns (uint256); function calc_token_amount( uint256[2] calldata amounts, bool deposit ) external view returns (uint256); function calc_withdraw_one_coin( uint256 _token_amount, int128 i ) external view returns (uint256); function remove_liquidity_one_coin( uint256 _token_amount, int128 i, uint256 min_amount ) external; function fee() external view returns (uint256); }
{ "evmVersion": "london", "optimizer": { "enabled": true, "runs": 200 }, "libraries": { "Controller.sol": {} }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"cncToken_","type":"address"},{"internalType":"address","name":"curveRegistryCacheAddress_","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"bonding","type":"address"}],"name":"BondingSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"convexBooster","type":"address"}],"name":"ConvexBoosterSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"convexHandler","type":"address"}],"name":"ConvexHandlerSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"curveHandler","type":"address"}],"name":"CurveHandlerSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"curveRegistryCache","type":"address"}],"name":"CurveRegistryCacheSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"},{"indexed":false,"internalType":"address","name":"poolAdapter","type":"address"}],"name":"CustomPoolAdapterSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"poolAdapter","type":"address"}],"name":"DefaultPoolAdapterSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"feeRecipient","type":"address"}],"name":"FeeRecipientSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"inflationManager","type":"address"}],"name":"InflationManagerSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MinimumTaintedTransferAmountSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"pool","type":"address"},{"indexed":false,"internalType":"bool","name":"allowed","type":"bool"}],"name":"MultiDepositsWithdrawsWhitelistSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"manager","type":"address"},{"indexed":false,"internalType":"bool","name":"isManager","type":"bool"}],"name":"PauseManagerSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"}],"name":"PoolAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"}],"name":"PoolRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"}],"name":"PoolShutdown","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"priceOracle","type":"address"}],"name":"PriceOracleSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"weightUpdateMinDelay","type":"uint256"}],"name":"WeightUpdateMinDelaySet","type":"event"},{"inputs":[],"name":"MAX_WEIGHT_UPDATE_MIN_DELAY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_WEIGHT_UPDATE_MIN_DELAY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"poolAddress","type":"address"}],"name":"addPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"bonding","outputs":[{"internalType":"contract IBonding","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cncToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"convexBooster","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"convexHandler","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"curveHandler","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"curveRegistryCache","outputs":[{"internalType":"contract ICurveRegistryCache","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"defaultPoolAdapter","outputs":[{"internalType":"contract IPoolAdapter","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeRecipient","outputs":[{"internalType":"contract IFeeRecipient","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"getMinimumTaintedTransferAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMultipleDepositsWithdrawsWhitelist","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inflationManager","outputs":[{"internalType":"contract IInflationManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_lpTokenStaker","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"poolAddress","type":"address"}],"name":"isActivePool","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isAllowedMultipleDepositsWithdraws","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isPauseManager","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"poolAddress","type":"address"}],"name":"isPool","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastWeightUpdate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"listActivePools","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"listPauseManagers","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"listPools","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lpTokenStaker","outputs":[{"internalType":"contract ILpTokenStaker","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"poolAdapterFor","outputs":[{"internalType":"contract IPoolAdapter","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"priceOracle","outputs":[{"internalType":"contract IGenericOracle","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"poolAddress","type":"address"}],"name":"removePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bool","name":"allowed","type":"bool"}],"name":"setAllowedMultipleDepositsWithdraws","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_bonding","type":"address"}],"name":"setBonding","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_convexBooster","type":"address"}],"name":"setConvexBooster","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_convexHandler","type":"address"}],"name":"setConvexHandler","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_curveHandler","type":"address"}],"name":"setCurveHandler","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"curveRegistryCache_","type":"address"}],"name":"setCurveRegistryCache","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"},{"internalType":"address","name":"poolAdapter","type":"address"}],"name":"setCustomPoolAdapter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"poolAdapter","type":"address"}],"name":"setDefaultPoolAdapter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeRecipient","type":"address"}],"name":"setFeeRecipient","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"manager","type":"address"}],"name":"setInflationManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"setMinimumTaintedTransferAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bool","name":"isManager","type":"bool"}],"name":"setPauseManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"oracle","type":"address"}],"name":"setPriceOracle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"delay","type":"uint256"}],"name":"setWeightUpdateMinDelay","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"poolAddress","type":"address"}],"name":"shutdownPool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_lpTokenStaker","type":"address"}],"name":"switchLpTokenStaker","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"conicPoolAddress","type":"address"},{"components":[{"internalType":"address","name":"poolAddress","type":"address"},{"internalType":"uint256","name":"weight","type":"uint256"}],"internalType":"struct IConicPoolWeightManagement.PoolWeight[]","name":"weights","type":"tuple[]"}],"internalType":"struct IController.WeightUpdate[]","name":"weights","type":"tuple[]"}],"name":"updateAllWeights","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"conicPoolAddress","type":"address"},{"components":[{"internalType":"address","name":"poolAddress","type":"address"},{"internalType":"uint256","name":"weight","type":"uint256"}],"internalType":"struct IConicPoolWeightManagement.PoolWeight[]","name":"weights","type":"tuple[]"}],"internalType":"struct IController.WeightUpdate","name":"update","type":"tuple"}],"name":"updateWeights","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"weightUpdateMinDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a0604052600a80546001600160a01b03191673f403c135812408bfbe8713b5a23a04b3d48aae311790553480156200003757600080fd5b50604051620027f1380380620027f18339810160408190526200005a91620000fb565b62000065336200008e565b6001600160a01b03918216608052600e80546001600160a01b0319169190921617905562000133565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80516001600160a01b0381168114620000f657600080fd5b919050565b600080604083850312156200010f57600080fd5b6200011a83620000de565b91506200012a60208401620000de565b90509250929050565b6080516126a26200014f600039600061048f01526126a26000f3fe608060405234801561001057600080fd5b50600436106102bb5760003560e01c8063715018a6116101825780639f82b217116100e9578063d6d7537e116100a2578063e17a803d1161007c578063e17a803d14610647578063e74b981b1461065a578063f2fde38b1461066d578063fa5d10581461068057600080fd5b8063d6d7537e1461060e578063d914cd4b14610621578063dbcd89fa1461063457600080fd5b80639f82b217146105a5578063b050ecb8146105b8578063b1bd815b146105cb578063ba3c2847146105de578063c3bb30b5146105e8578063c4d66de8146105fb57600080fd5b8063827edb8f1161013b578063827edb8f1461053e57806388beb5d5146105515780638da5cb5b1461056457806398457559146105755780639c306073146105885780639ee861571461059257600080fd5b8063715018a6146104cc57806371b1b460146104d457806372b11179146104fd5780637f4c43ac146105055780638097354f1461051857806381e0f7651461052b57600080fd5b8063469048401161022657806355eb6b35116101df57806355eb6b35146104515780635a991917146104645780635b16ebb714610477578063645d28a81461048a57806364b0aa94146104b157806368795862146104c457600080fd5b806346904840146103cf57806348439e7e146103e25780634eb3ffc3146103f557806350fa7c3e1461041857806352e3d3311461042b578063530e784f1461043e57600080fd5b80632630c12f116102785780632630c12f146103455780632cdacb50146103705780633693dd6814610383578063388793ed146103965780633b7d0946146103a95780633c355c4c146103bc57600080fd5b80630589c0bd146102c057806308502197146102de5780630e2cf72d1461030c578063100f285914610321578063172cc335146103295780631988a1071461033c575b600080fd5b6102c8610693565b6040516102d59190612000565b60405180910390f35b6102fe6102ec366004612062565b60166020526000908152604090205481565b6040519081526020016102d5565b61031f61031a36600461207f565b6106a4565b005b6102c86107b2565b61031f610337366004612062565b6107be565b6102fe60155481565b600d54610358906001600160a01b031681565b6040516001600160a01b0390911681526020016102d5565b600a54610358906001600160a01b031681565b601454610358906001600160a01b031681565b61031f6103a43660046120a6565b610887565b61031f6103b7366004612062565b610906565b61031f6103ca3660046120a6565b6109f8565b601254610358906001600160a01b031681565b601054610358906001600160a01b031681565b610408610403366004612062565b610a74565b60405190151581526020016102d5565b61031f610426366004612062565b610a87565b61031f610439366004612062565b610b61565b61031f61044c366004612062565b610c3b565b61035861045f366004612062565b610d09565b600b54610358906001600160a01b031681565b610408610485366004612062565b610d46565b6103587f000000000000000000000000000000000000000000000000000000000000000081565b61031f6104bf366004612062565b610d53565b6102c8610e9c565b61031f610ea8565b6102fe6104e2366004612062565b6001600160a01b031660009081526009602052604090205490565b6102c8610ebc565b61031f610513366004612062565b610ec8565b610408610526366004612062565b610f9b565b61031f610539366004612255565b610fa8565b61031f61054c366004612062565b610ff4565b61031f61055f366004612062565b61112d565b6000546001600160a01b0316610358565b601154610358906001600160a01b031681565b6102fe621baf8081565b61031f6105a0366004612306565b6111d7565b600e54610358906001600160a01b031681565b600c54610358906001600160a01b031681565b61031f6105d9366004612332565b61149e565b6102fe6201518081565b61031f6105f6366004612062565b611579565b61031f610609366004612062565b6116e6565b61040861061c366004612062565b61182d565b61031f61062f366004612062565b61183a565b600f54610358906001600160a01b031681565b61031f610655366004612360565b611982565b61031f610668366004612062565b611a81565b61031f61067b366004612062565b611b50565b61031f61068e366004612062565b611bc9565b606061069f6005611c72565b905090565b6106ac611c7f565b621baf8081106106f45760405162461bcd60e51b815260206004820152600e60248201526d64656c617920746f6f206c6f6e6760901b60448201526064015b60405180910390fd5b6201518081116107385760405162461bcd60e51b815260206004820152600f60248201526e19195b185e481d1bdbc81cda1bdc9d608a1b60448201526064016106eb565b60155481036107765760405162461bcd60e51b815260206004820152600a60248201526973616d652064656c617960b01b60448201526064016106eb565b60158190556040518181527f4cbbfb8b36940e62c2ed74c76e6470d94fe291696433dab19272e011ed311588906020015b60405180910390a150565b606061069f6007611c72565b6107c6611c7f565b6001600160a01b0381166107ec5760405162461bcd60e51b81526004016106eb90612395565b6011546001600160a01b03908116908216036108395760405162461bcd60e51b815260206004820152600c60248201526b73616d6520626f6e64696e6760a01b60448201526064016106eb565b601180546001600160a01b0319166001600160a01b0383169081179091556040519081527f031579ee5e04b0905c1e20ecbaa48c4a65ff836ea81eb46e5a0c47295e07404f906020016107a7565b61088f611c7f565b600081156108a9576108a2600784611cd9565b90506108b7565b6108b4600784611cee565b90505b801561090157604080516001600160a01b038516815283151560208201527f3847778f66347b91d6d6d7ecc6a686b0798b29405595fca791ee2fbb28e0f09b910160405180910390a15b505050565b61090e611c7f565b610919600182611cee565b61095d5760405162461bcd60e51b815260206004820152601560248201527419985a5b1959081d1bc81c995b5bdd99481c1bdbdb605a1b60448201526064016106eb565b610968600382611d03565b156109c15760405162461bcd60e51b8152602060048201526024808201527f73687574646f776e2074686520706f6f6c206265666f72652072656d6f76696e60448201526319c81a5d60e21b60648201526084016106eb565b6040516001600160a01b038216907f4106dfdaa577573db51c0ca93f766dbedfa0758faa2e7f5bcdb7c142be803c3f90600090a250565b610a00611c7f565b600081610a1757610a12600584611cee565b610a22565b610a22600584611cd9565b9050801561090157826001600160a01b03167f6e08c212f0c3f8318d18fdd0fac7505eddc2807d9a2cf0131886b4798c0f14b283604051610a67911515815260200190565b60405180910390a2505050565b6000610a81600583611d03565b92915050565b610a8f611c7f565b6001600160a01b038116610ab55760405162461bcd60e51b81526004016106eb90612395565b6014546001600160a01b0390811690821603610b135760405162461bcd60e51b815260206004820152601960248201527f73616d652064656661756c7420706f6f6c20616461707465720000000000000060448201526064016106eb565b601480546001600160a01b0319166001600160a01b0383169081179091556040519081527fa7f1d9ca15550452fa843fbd95689ebd62fc20be7f3778ed32a5481652599a14906020016107a7565b610b69611c7f565b6001600160a01b038116610b8f5760405162461bcd60e51b81526004016106eb90612395565b600e546001600160a01b0390811690821603610bed5760405162461bcd60e51b815260206004820152601960248201527f73616d652063757276652072656769737472792063616368650000000000000060448201526064016106eb565b600e80546001600160a01b0319166001600160a01b0383169081179091556040519081527f804d6412ec50674626ecd09727ed034ced85412d702250057e5a869d9d82392d906020016107a7565b610c43611c7f565b6001600160a01b038116610c695760405162461bcd60e51b81526004016106eb90612395565b600d546001600160a01b0390811690821603610cbb5760405162461bcd60e51b815260206004820152601160248201527073616d65207072696365206f7261636c6560781b60448201526064016106eb565b600d80546001600160a01b0319166001600160a01b0383169081179091556040519081527f6536690106168bdf4ba72c128a053d817999b1db90cae23f139b293bf862cb75906020016107a7565b6001600160a01b038082166000908152601360205260408120549091168015610d325780610d3f565b6014546001600160a01b03165b9392505050565b6000610a81600183611d03565b610d5b611c7f565b610d66600382611cee565b610daa5760405162461bcd60e51b815260206004820152601560248201527419985a5b1959081d1bc81c995b5bdd99481c1bdbdb605a1b60448201526064016106eb565b806001600160a01b031663d6038dc66040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610de557600080fd5b505af1158015610df9573d6000803e3d6000fd5b50505050600f60009054906101000a90046001600160a01b03166001600160a01b0316633dc4f7de6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610e4d57600080fd5b505af1158015610e61573d6000803e3d6000fd5b50506040516001600160a01b03841692507f1b2b64a5d6ff166112cd9f1d7e3a30ad9a1e236c68c0c58c965368f3b56d542c9150600090a250565b606061069f6001611c72565b610eb0611c7f565b610eba6000611d25565b565b606061069f6003611c72565b610ed0611c7f565b6001600160a01b038116610ef65760405162461bcd60e51b81526004016106eb90612395565b600f546001600160a01b0390811690821603610f4d5760405162461bcd60e51b815260206004820152601660248201527539b0b6b29034b7333630ba34b7b71036b0b730b3b2b960511b60448201526064016106eb565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f1807368dab7e70053cc95c16cee46c8b354ce67fa6610400c469d35b56620140906020016107a7565b6000610a81600383611d03565b610fb0611c7f565b60005b8151811015610ff057610fde828281518110610fd157610fd16123cc565b6020026020010151611982565b80610fe8816123f8565b915050610fb3565b5050565b610ffc611c7f565b601060009054906101000a90046001600160a01b03166001600160a01b031663fc0e74d16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561104c57600080fd5b505af1158015611060573d6000803e3d6000fd5b5050601080546001600160a01b0319166001600160a01b03851617905550600090505b61108d6001611d75565b811015610ff0576010546001600160a01b031663a972985e6110b0600184611d7f565b6040516001600160e01b031960e084901b1681526001600160a01b0390911660048201526024016020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a9190612411565b5080611125816123f8565b915050611083565b611135611c7f565b600c546001600160a01b03908116908216036111895760405162461bcd60e51b815260206004820152601360248201527239b0b6b29031b7b73b32bc103430b7323632b960691b60448201526064016106eb565b600c80546001600160a01b0319166001600160a01b0383169081179091556040519081527f78c0d5a329a7d476b56bc10ad7e2fd11a0433fb6f1ffd12b28b3b3a7ce5cdba9906020016107a7565b6111df611c7f565b6001600160a01b03821660009081526009602052604090205481036112345760405162461bcd60e51b815260206004820152600b60248201526a1cd85b5948185b5bdd5b9d60aa1b60448201526064016106eb565b6000826001600160a01b031663075461726040518163ffffffff1660e01b8152600401602060405180830381865afa158015611274573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611298919061242a565b90506000816001600160a01b0316636f307dc36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112fe919061242a565b600d54604051638b2f0f4f60e01b81526001600160a01b03808416600483015292935060009290911690638b2f0f4f90602401602060405180830381865afa15801561134e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113729190612411565b905060006113e4836001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113b7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113db9190612447565b86906012611d8b565b905060006113f28284611dd4565b905069021e19e0c9bab24000008111156114405760405162461bcd60e51b815260206004820152600f60248201526e0c2dadeeadce840e8dede40d0d2ced608b1b60448201526064016106eb565b6001600160a01b03871660008181526009602052604090819020889055517f880ef00c8805fc02a281172ffb91adb25137e2e692d9f0b24e13382e0d107ff19061148d9089815260200190565b60405180910390a250505050505050565b6114a6611c7f565b6001600160a01b038083166000908152601360205260409020548116908216036115125760405162461bcd60e51b815260206004820152601860248201527f73616d6520637573746f6d20706f6f6c2061646170746572000000000000000060448201526064016106eb565b6001600160a01b0382811660008181526013602090815260409182902080546001600160a01b0319169486169485179055905192835290917f2f17401e7e83797c1ca2deb3077675db760b04f2e49c233e908c3ebc68c7ca1b910160405180910390a25050565b611581611c7f565b600a60009054906101000a90046001600160a01b03166001600160a01b031663bf86d6906040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f8919061246a565b6116445760405162461bcd60e51b815260206004820152601f60248201527f63757272656e7420626f6f73746572206973206e6f742073687574646f776e0060448201526064016106eb565b600a546001600160a01b03908116908216036116985760405162461bcd60e51b815260206004820152601360248201527239b0b6b29031b7b73b32bc103137b7b9ba32b960691b60448201526064016106eb565b600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f753f93638ea37a2df364592f0884f853232995f9d2834affdeb30031ab97b376906020016107a7565b6116ee611c7f565b600054600160a81b900460ff161580801561171657506000546001600160a01b90910460ff16105b806117375750303b1580156117375750600054600160a01b900460ff166001145b61179a5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016106eb565b6000805460ff60a01b1916600160a01b17905580156117c7576000805460ff60a81b1916600160a81b1790555b601080546001600160a01b0319166001600160a01b0384161790558015610ff0576000805460ff60a81b19169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000610a81600783611d03565b611842611c7f565b61184d600182611cd9565b61188e5760405162461bcd60e51b815260206004820152601260248201527119985a5b1959081d1bc8185919081c1bdbdb60721b60448201526064016106eb565b611899600382611cd9565b6118da5760405162461bcd60e51b815260206004820152601260248201527119985a5b1959081d1bc8185919081c1bdbdb60721b60448201526064016106eb565b6010546040516354b94c2f60e11b81526001600160a01b0383811660048301529091169063a972985e906024016020604051808303816000875af1158015611926573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061194a9190612411565b506040516001600160a01b038216907f73cca62ab1b520c9715bf4e6c71e3e518c754e7148f65102f43289a7df0efea690600090a250565b61198a611c7f565b60155481516001600160a01b031660009081526016602052604090205442916119b291612487565b106119ff5760405162461bcd60e51b815260206004820152601f60248201527f776569676874207570646174652064656c6179206e6f7420656c61707365640060448201526064016106eb565b80516020820151604051638dbfb25b60e01b81526001600160a01b0390921691638dbfb25b91611a319160040161249a565b600060405180830381600087803b158015611a4b57600080fd5b505af1158015611a5f573d6000803e3d6000fd5b505091516001600160a01b031660009081526016602052604090204290555050565b611a89611c7f565b6001600160a01b038116611aaf5760405162461bcd60e51b81526004016106eb90612395565b6012546001600160a01b0390811690821603611b025760405162461bcd60e51b81526020600482015260126024820152711cd85b5948199959481c9958da5c1a595b9d60721b60448201526064016106eb565b601280546001600160a01b0319166001600160a01b0383169081179091556040519081527fbf9a9534339a9d6b81696e05dcfb614b7dc518a31d48be3cfb757988381fb323906020016107a7565b611b58611c7f565b6001600160a01b038116611bbd5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016106eb565b611bc681611d25565b50565b611bd1611c7f565b600b546001600160a01b0390811690821603611c245760405162461bcd60e51b815260206004820152601260248201527139b0b6b29031bab93b32903430b7323632b960711b60448201526064016106eb565b600b80546001600160a01b0319166001600160a01b0383169081179091556040519081527f40f17cc99608acc0aa583a98bd741564e79111d55e65adc0399f400a707d4831906020016107a7565b60606000610d3f83611df6565b6000546001600160a01b03163314610eba5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016106eb565b6000610d3f836001600160a01b038416611e52565b6000610d3f836001600160a01b038416611ea1565b6001600160a01b03811660009081526001830160205260408120541515610d3f565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000610a81825490565b6000610d3f8383611f94565b60008160ff168360ff1603611da1575082610d3f565b8160ff168360ff161115611dc157611dba848484611fbe565b9050610d3f565b611dcc848484611fdf565b949350505050565b6000611de26012600a6125d6565b611dec83856125e2565b610d3f91906125f9565b606081600001805480602002602001604051908101604052809291908181526020018280548015611e4657602002820191906000526020600020905b815481526020019060010190808311611e32575b50505050509050919050565b6000818152600183016020526040812054611e9957508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a81565b506000610a81565b60008181526001830160205260408120548015611f8a576000611ec560018361261b565b8554909150600090611ed99060019061261b565b9050818114611f3e576000866000018281548110611ef957611ef96123cc565b9060005260206000200154905080876000018481548110611f1c57611f1c6123cc565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611f4f57611f4f61262e565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a81565b6000915050610a81565b6000826000018281548110611fab57611fab6123cc565b9060005260206000200154905092915050565b6000611fca8284612644565b611fd590600a61265d565b611dcc90856125f9565b6000611feb8383612644565b611ff690600a61265d565b611dcc90856125e2565b6020808252825182820181905260009190848201906040850190845b818110156120415783516001600160a01b03168352928401929184019160010161201c565b50909695505050505050565b6001600160a01b0381168114611bc657600080fd5b60006020828403121561207457600080fd5b8135610d3f8161204d565b60006020828403121561209157600080fd5b5035919050565b8015158114611bc657600080fd5b600080604083850312156120b957600080fd5b82356120c48161204d565b915060208301356120d481612098565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715612118576121186120df565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715612147576121476120df565b604052919050565b600067ffffffffffffffff821115612169576121696120df565b5060051b60200190565b6000604080838503121561218657600080fd5b61218e6120f5565b9150823561219b8161204d565b825260208381013567ffffffffffffffff8111156121b857600080fd5b8401601f810186136121c957600080fd5b80356121dc6121d78261214f565b61211e565b81815260069190911b820183019083810190888311156121fb57600080fd5b928401925b828410156122445785848a0312156122185760008081fd5b6122206120f5565b843561222b8161204d565b8152848601358682015282529285019290840190612200565b808588015250505050505092915050565b6000602080838503121561226857600080fd5b823567ffffffffffffffff8082111561228057600080fd5b818501915085601f83011261229457600080fd5b81356122a26121d78261214f565b81815260059190911b830184019084810190888311156122c157600080fd5b8585015b838110156122f9578035858111156122dd5760008081fd5b6122eb8b89838a0101612173565b8452509186019186016122c5565b5098975050505050505050565b6000806040838503121561231957600080fd5b82356123248161204d565b946020939093013593505050565b6000806040838503121561234557600080fd5b82356123508161204d565b915060208301356120d48161204d565b60006020828403121561237257600080fd5b813567ffffffffffffffff81111561238957600080fd5b611dcc84828501612173565b6020808252601a908201527f63616e6e6f742073657420746f207a65726f2061646472657373000000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006001820161240a5761240a6123e2565b5060010190565b60006020828403121561242357600080fd5b5051919050565b60006020828403121561243c57600080fd5b8151610d3f8161204d565b60006020828403121561245957600080fd5b815160ff81168114610d3f57600080fd5b60006020828403121561247c57600080fd5b8151610d3f81612098565b80820180821115610a8157610a816123e2565b602080825282518282018190526000919060409081850190868401855b828110156124e557815180516001600160a01b031685528601518685015292840192908501906001016124b7565b5091979650505050505050565b600181815b8085111561252d578160001904821115612513576125136123e2565b8085161561252057918102915b93841c93908002906124f7565b509250929050565b60008261254457506001610a81565b8161255157506000610a81565b816001811461256757600281146125715761258d565b6001915050610a81565b60ff841115612582576125826123e2565b50506001821b610a81565b5060208310610133831016604e8410600b84101617156125b0575081810a610a81565b6125ba83836124f2565b80600019048211156125ce576125ce6123e2565b029392505050565b6000610d3f8383612535565b8082028115828204841417610a8157610a816123e2565b60008261261657634e487b7160e01b600052601260045260246000fd5b500490565b81810381811115610a8157610a816123e2565b634e487b7160e01b600052603160045260246000fd5b60ff8281168282160390811115610a8157610a816123e2565b6000610d3f60ff84168361253556fea26469706673582212203ae909580b7eeb77da9f9353bea14543049be254b8feb8961fd99f423380e37e64736f6c634300081100330000000000000000000000009ae380f0272e2162340a5bb646c354271c0f5cfc00000000000000000000000029e06bba53f73e271859214d9d87a1be636273c0
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102bb5760003560e01c8063715018a6116101825780639f82b217116100e9578063d6d7537e116100a2578063e17a803d1161007c578063e17a803d14610647578063e74b981b1461065a578063f2fde38b1461066d578063fa5d10581461068057600080fd5b8063d6d7537e1461060e578063d914cd4b14610621578063dbcd89fa1461063457600080fd5b80639f82b217146105a5578063b050ecb8146105b8578063b1bd815b146105cb578063ba3c2847146105de578063c3bb30b5146105e8578063c4d66de8146105fb57600080fd5b8063827edb8f1161013b578063827edb8f1461053e57806388beb5d5146105515780638da5cb5b1461056457806398457559146105755780639c306073146105885780639ee861571461059257600080fd5b8063715018a6146104cc57806371b1b460146104d457806372b11179146104fd5780637f4c43ac146105055780638097354f1461051857806381e0f7651461052b57600080fd5b8063469048401161022657806355eb6b35116101df57806355eb6b35146104515780635a991917146104645780635b16ebb714610477578063645d28a81461048a57806364b0aa94146104b157806368795862146104c457600080fd5b806346904840146103cf57806348439e7e146103e25780634eb3ffc3146103f557806350fa7c3e1461041857806352e3d3311461042b578063530e784f1461043e57600080fd5b80632630c12f116102785780632630c12f146103455780632cdacb50146103705780633693dd6814610383578063388793ed146103965780633b7d0946146103a95780633c355c4c146103bc57600080fd5b80630589c0bd146102c057806308502197146102de5780630e2cf72d1461030c578063100f285914610321578063172cc335146103295780631988a1071461033c575b600080fd5b6102c8610693565b6040516102d59190612000565b60405180910390f35b6102fe6102ec366004612062565b60166020526000908152604090205481565b6040519081526020016102d5565b61031f61031a36600461207f565b6106a4565b005b6102c86107b2565b61031f610337366004612062565b6107be565b6102fe60155481565b600d54610358906001600160a01b031681565b6040516001600160a01b0390911681526020016102d5565b600a54610358906001600160a01b031681565b601454610358906001600160a01b031681565b61031f6103a43660046120a6565b610887565b61031f6103b7366004612062565b610906565b61031f6103ca3660046120a6565b6109f8565b601254610358906001600160a01b031681565b601054610358906001600160a01b031681565b610408610403366004612062565b610a74565b60405190151581526020016102d5565b61031f610426366004612062565b610a87565b61031f610439366004612062565b610b61565b61031f61044c366004612062565b610c3b565b61035861045f366004612062565b610d09565b600b54610358906001600160a01b031681565b610408610485366004612062565b610d46565b6103587f0000000000000000000000009ae380f0272e2162340a5bb646c354271c0f5cfc81565b61031f6104bf366004612062565b610d53565b6102c8610e9c565b61031f610ea8565b6102fe6104e2366004612062565b6001600160a01b031660009081526009602052604090205490565b6102c8610ebc565b61031f610513366004612062565b610ec8565b610408610526366004612062565b610f9b565b61031f610539366004612255565b610fa8565b61031f61054c366004612062565b610ff4565b61031f61055f366004612062565b61112d565b6000546001600160a01b0316610358565b601154610358906001600160a01b031681565b6102fe621baf8081565b61031f6105a0366004612306565b6111d7565b600e54610358906001600160a01b031681565b600c54610358906001600160a01b031681565b61031f6105d9366004612332565b61149e565b6102fe6201518081565b61031f6105f6366004612062565b611579565b61031f610609366004612062565b6116e6565b61040861061c366004612062565b61182d565b61031f61062f366004612062565b61183a565b600f54610358906001600160a01b031681565b61031f610655366004612360565b611982565b61031f610668366004612062565b611a81565b61031f61067b366004612062565b611b50565b61031f61068e366004612062565b611bc9565b606061069f6005611c72565b905090565b6106ac611c7f565b621baf8081106106f45760405162461bcd60e51b815260206004820152600e60248201526d64656c617920746f6f206c6f6e6760901b60448201526064015b60405180910390fd5b6201518081116107385760405162461bcd60e51b815260206004820152600f60248201526e19195b185e481d1bdbc81cda1bdc9d608a1b60448201526064016106eb565b60155481036107765760405162461bcd60e51b815260206004820152600a60248201526973616d652064656c617960b01b60448201526064016106eb565b60158190556040518181527f4cbbfb8b36940e62c2ed74c76e6470d94fe291696433dab19272e011ed311588906020015b60405180910390a150565b606061069f6007611c72565b6107c6611c7f565b6001600160a01b0381166107ec5760405162461bcd60e51b81526004016106eb90612395565b6011546001600160a01b03908116908216036108395760405162461bcd60e51b815260206004820152600c60248201526b73616d6520626f6e64696e6760a01b60448201526064016106eb565b601180546001600160a01b0319166001600160a01b0383169081179091556040519081527f031579ee5e04b0905c1e20ecbaa48c4a65ff836ea81eb46e5a0c47295e07404f906020016107a7565b61088f611c7f565b600081156108a9576108a2600784611cd9565b90506108b7565b6108b4600784611cee565b90505b801561090157604080516001600160a01b038516815283151560208201527f3847778f66347b91d6d6d7ecc6a686b0798b29405595fca791ee2fbb28e0f09b910160405180910390a15b505050565b61090e611c7f565b610919600182611cee565b61095d5760405162461bcd60e51b815260206004820152601560248201527419985a5b1959081d1bc81c995b5bdd99481c1bdbdb605a1b60448201526064016106eb565b610968600382611d03565b156109c15760405162461bcd60e51b8152602060048201526024808201527f73687574646f776e2074686520706f6f6c206265666f72652072656d6f76696e60448201526319c81a5d60e21b60648201526084016106eb565b6040516001600160a01b038216907f4106dfdaa577573db51c0ca93f766dbedfa0758faa2e7f5bcdb7c142be803c3f90600090a250565b610a00611c7f565b600081610a1757610a12600584611cee565b610a22565b610a22600584611cd9565b9050801561090157826001600160a01b03167f6e08c212f0c3f8318d18fdd0fac7505eddc2807d9a2cf0131886b4798c0f14b283604051610a67911515815260200190565b60405180910390a2505050565b6000610a81600583611d03565b92915050565b610a8f611c7f565b6001600160a01b038116610ab55760405162461bcd60e51b81526004016106eb90612395565b6014546001600160a01b0390811690821603610b135760405162461bcd60e51b815260206004820152601960248201527f73616d652064656661756c7420706f6f6c20616461707465720000000000000060448201526064016106eb565b601480546001600160a01b0319166001600160a01b0383169081179091556040519081527fa7f1d9ca15550452fa843fbd95689ebd62fc20be7f3778ed32a5481652599a14906020016107a7565b610b69611c7f565b6001600160a01b038116610b8f5760405162461bcd60e51b81526004016106eb90612395565b600e546001600160a01b0390811690821603610bed5760405162461bcd60e51b815260206004820152601960248201527f73616d652063757276652072656769737472792063616368650000000000000060448201526064016106eb565b600e80546001600160a01b0319166001600160a01b0383169081179091556040519081527f804d6412ec50674626ecd09727ed034ced85412d702250057e5a869d9d82392d906020016107a7565b610c43611c7f565b6001600160a01b038116610c695760405162461bcd60e51b81526004016106eb90612395565b600d546001600160a01b0390811690821603610cbb5760405162461bcd60e51b815260206004820152601160248201527073616d65207072696365206f7261636c6560781b60448201526064016106eb565b600d80546001600160a01b0319166001600160a01b0383169081179091556040519081527f6536690106168bdf4ba72c128a053d817999b1db90cae23f139b293bf862cb75906020016107a7565b6001600160a01b038082166000908152601360205260408120549091168015610d325780610d3f565b6014546001600160a01b03165b9392505050565b6000610a81600183611d03565b610d5b611c7f565b610d66600382611cee565b610daa5760405162461bcd60e51b815260206004820152601560248201527419985a5b1959081d1bc81c995b5bdd99481c1bdbdb605a1b60448201526064016106eb565b806001600160a01b031663d6038dc66040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610de557600080fd5b505af1158015610df9573d6000803e3d6000fd5b50505050600f60009054906101000a90046001600160a01b03166001600160a01b0316633dc4f7de6040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610e4d57600080fd5b505af1158015610e61573d6000803e3d6000fd5b50506040516001600160a01b03841692507f1b2b64a5d6ff166112cd9f1d7e3a30ad9a1e236c68c0c58c965368f3b56d542c9150600090a250565b606061069f6001611c72565b610eb0611c7f565b610eba6000611d25565b565b606061069f6003611c72565b610ed0611c7f565b6001600160a01b038116610ef65760405162461bcd60e51b81526004016106eb90612395565b600f546001600160a01b0390811690821603610f4d5760405162461bcd60e51b815260206004820152601660248201527539b0b6b29034b7333630ba34b7b71036b0b730b3b2b960511b60448201526064016106eb565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f1807368dab7e70053cc95c16cee46c8b354ce67fa6610400c469d35b56620140906020016107a7565b6000610a81600383611d03565b610fb0611c7f565b60005b8151811015610ff057610fde828281518110610fd157610fd16123cc565b6020026020010151611982565b80610fe8816123f8565b915050610fb3565b5050565b610ffc611c7f565b601060009054906101000a90046001600160a01b03166001600160a01b031663fc0e74d16040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561104c57600080fd5b505af1158015611060573d6000803e3d6000fd5b5050601080546001600160a01b0319166001600160a01b03851617905550600090505b61108d6001611d75565b811015610ff0576010546001600160a01b031663a972985e6110b0600184611d7f565b6040516001600160e01b031960e084901b1681526001600160a01b0390911660048201526024016020604051808303816000875af11580156110f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061111a9190612411565b5080611125816123f8565b915050611083565b611135611c7f565b600c546001600160a01b03908116908216036111895760405162461bcd60e51b815260206004820152601360248201527239b0b6b29031b7b73b32bc103430b7323632b960691b60448201526064016106eb565b600c80546001600160a01b0319166001600160a01b0383169081179091556040519081527f78c0d5a329a7d476b56bc10ad7e2fd11a0433fb6f1ffd12b28b3b3a7ce5cdba9906020016107a7565b6111df611c7f565b6001600160a01b03821660009081526009602052604090205481036112345760405162461bcd60e51b815260206004820152600b60248201526a1cd85b5948185b5bdd5b9d60aa1b60448201526064016106eb565b6000826001600160a01b031663075461726040518163ffffffff1660e01b8152600401602060405180830381865afa158015611274573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611298919061242a565b90506000816001600160a01b0316636f307dc36040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112da573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112fe919061242a565b600d54604051638b2f0f4f60e01b81526001600160a01b03808416600483015292935060009290911690638b2f0f4f90602401602060405180830381865afa15801561134e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113729190612411565b905060006113e4836001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa1580156113b7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113db9190612447565b86906012611d8b565b905060006113f28284611dd4565b905069021e19e0c9bab24000008111156114405760405162461bcd60e51b815260206004820152600f60248201526e0c2dadeeadce840e8dede40d0d2ced608b1b60448201526064016106eb565b6001600160a01b03871660008181526009602052604090819020889055517f880ef00c8805fc02a281172ffb91adb25137e2e692d9f0b24e13382e0d107ff19061148d9089815260200190565b60405180910390a250505050505050565b6114a6611c7f565b6001600160a01b038083166000908152601360205260409020548116908216036115125760405162461bcd60e51b815260206004820152601860248201527f73616d6520637573746f6d20706f6f6c2061646170746572000000000000000060448201526064016106eb565b6001600160a01b0382811660008181526013602090815260409182902080546001600160a01b0319169486169485179055905192835290917f2f17401e7e83797c1ca2deb3077675db760b04f2e49c233e908c3ebc68c7ca1b910160405180910390a25050565b611581611c7f565b600a60009054906101000a90046001600160a01b03166001600160a01b031663bf86d6906040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f8919061246a565b6116445760405162461bcd60e51b815260206004820152601f60248201527f63757272656e7420626f6f73746572206973206e6f742073687574646f776e0060448201526064016106eb565b600a546001600160a01b03908116908216036116985760405162461bcd60e51b815260206004820152601360248201527239b0b6b29031b7b73b32bc103137b7b9ba32b960691b60448201526064016106eb565b600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f753f93638ea37a2df364592f0884f853232995f9d2834affdeb30031ab97b376906020016107a7565b6116ee611c7f565b600054600160a81b900460ff161580801561171657506000546001600160a01b90910460ff16105b806117375750303b1580156117375750600054600160a01b900460ff166001145b61179a5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016106eb565b6000805460ff60a01b1916600160a01b17905580156117c7576000805460ff60a81b1916600160a81b1790555b601080546001600160a01b0319166001600160a01b0384161790558015610ff0576000805460ff60a81b19169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000610a81600783611d03565b611842611c7f565b61184d600182611cd9565b61188e5760405162461bcd60e51b815260206004820152601260248201527119985a5b1959081d1bc8185919081c1bdbdb60721b60448201526064016106eb565b611899600382611cd9565b6118da5760405162461bcd60e51b815260206004820152601260248201527119985a5b1959081d1bc8185919081c1bdbdb60721b60448201526064016106eb565b6010546040516354b94c2f60e11b81526001600160a01b0383811660048301529091169063a972985e906024016020604051808303816000875af1158015611926573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061194a9190612411565b506040516001600160a01b038216907f73cca62ab1b520c9715bf4e6c71e3e518c754e7148f65102f43289a7df0efea690600090a250565b61198a611c7f565b60155481516001600160a01b031660009081526016602052604090205442916119b291612487565b106119ff5760405162461bcd60e51b815260206004820152601f60248201527f776569676874207570646174652064656c6179206e6f7420656c61707365640060448201526064016106eb565b80516020820151604051638dbfb25b60e01b81526001600160a01b0390921691638dbfb25b91611a319160040161249a565b600060405180830381600087803b158015611a4b57600080fd5b505af1158015611a5f573d6000803e3d6000fd5b505091516001600160a01b031660009081526016602052604090204290555050565b611a89611c7f565b6001600160a01b038116611aaf5760405162461bcd60e51b81526004016106eb90612395565b6012546001600160a01b0390811690821603611b025760405162461bcd60e51b81526020600482015260126024820152711cd85b5948199959481c9958da5c1a595b9d60721b60448201526064016106eb565b601280546001600160a01b0319166001600160a01b0383169081179091556040519081527fbf9a9534339a9d6b81696e05dcfb614b7dc518a31d48be3cfb757988381fb323906020016107a7565b611b58611c7f565b6001600160a01b038116611bbd5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016106eb565b611bc681611d25565b50565b611bd1611c7f565b600b546001600160a01b0390811690821603611c245760405162461bcd60e51b815260206004820152601260248201527139b0b6b29031bab93b32903430b7323632b960711b60448201526064016106eb565b600b80546001600160a01b0319166001600160a01b0383169081179091556040519081527f40f17cc99608acc0aa583a98bd741564e79111d55e65adc0399f400a707d4831906020016107a7565b60606000610d3f83611df6565b6000546001600160a01b03163314610eba5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016106eb565b6000610d3f836001600160a01b038416611e52565b6000610d3f836001600160a01b038416611ea1565b6001600160a01b03811660009081526001830160205260408120541515610d3f565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000610a81825490565b6000610d3f8383611f94565b60008160ff168360ff1603611da1575082610d3f565b8160ff168360ff161115611dc157611dba848484611fbe565b9050610d3f565b611dcc848484611fdf565b949350505050565b6000611de26012600a6125d6565b611dec83856125e2565b610d3f91906125f9565b606081600001805480602002602001604051908101604052809291908181526020018280548015611e4657602002820191906000526020600020905b815481526020019060010190808311611e32575b50505050509050919050565b6000818152600183016020526040812054611e9957508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a81565b506000610a81565b60008181526001830160205260408120548015611f8a576000611ec560018361261b565b8554909150600090611ed99060019061261b565b9050818114611f3e576000866000018281548110611ef957611ef96123cc565b9060005260206000200154905080876000018481548110611f1c57611f1c6123cc565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080611f4f57611f4f61262e565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a81565b6000915050610a81565b6000826000018281548110611fab57611fab6123cc565b9060005260206000200154905092915050565b6000611fca8284612644565b611fd590600a61265d565b611dcc90856125f9565b6000611feb8383612644565b611ff690600a61265d565b611dcc90856125e2565b6020808252825182820181905260009190848201906040850190845b818110156120415783516001600160a01b03168352928401929184019160010161201c565b50909695505050505050565b6001600160a01b0381168114611bc657600080fd5b60006020828403121561207457600080fd5b8135610d3f8161204d565b60006020828403121561209157600080fd5b5035919050565b8015158114611bc657600080fd5b600080604083850312156120b957600080fd5b82356120c48161204d565b915060208301356120d481612098565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715612118576121186120df565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715612147576121476120df565b604052919050565b600067ffffffffffffffff821115612169576121696120df565b5060051b60200190565b6000604080838503121561218657600080fd5b61218e6120f5565b9150823561219b8161204d565b825260208381013567ffffffffffffffff8111156121b857600080fd5b8401601f810186136121c957600080fd5b80356121dc6121d78261214f565b61211e565b81815260069190911b820183019083810190888311156121fb57600080fd5b928401925b828410156122445785848a0312156122185760008081fd5b6122206120f5565b843561222b8161204d565b8152848601358682015282529285019290840190612200565b808588015250505050505092915050565b6000602080838503121561226857600080fd5b823567ffffffffffffffff8082111561228057600080fd5b818501915085601f83011261229457600080fd5b81356122a26121d78261214f565b81815260059190911b830184019084810190888311156122c157600080fd5b8585015b838110156122f9578035858111156122dd5760008081fd5b6122eb8b89838a0101612173565b8452509186019186016122c5565b5098975050505050505050565b6000806040838503121561231957600080fd5b82356123248161204d565b946020939093013593505050565b6000806040838503121561234557600080fd5b82356123508161204d565b915060208301356120d48161204d565b60006020828403121561237257600080fd5b813567ffffffffffffffff81111561238957600080fd5b611dcc84828501612173565b6020808252601a908201527f63616e6e6f742073657420746f207a65726f2061646472657373000000000000604082015260600190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006001820161240a5761240a6123e2565b5060010190565b60006020828403121561242357600080fd5b5051919050565b60006020828403121561243c57600080fd5b8151610d3f8161204d565b60006020828403121561245957600080fd5b815160ff81168114610d3f57600080fd5b60006020828403121561247c57600080fd5b8151610d3f81612098565b80820180821115610a8157610a816123e2565b602080825282518282018190526000919060409081850190868401855b828110156124e557815180516001600160a01b031685528601518685015292840192908501906001016124b7565b5091979650505050505050565b600181815b8085111561252d578160001904821115612513576125136123e2565b8085161561252057918102915b93841c93908002906124f7565b509250929050565b60008261254457506001610a81565b8161255157506000610a81565b816001811461256757600281146125715761258d565b6001915050610a81565b60ff841115612582576125826123e2565b50506001821b610a81565b5060208310610133831016604e8410600b84101617156125b0575081810a610a81565b6125ba83836124f2565b80600019048211156125ce576125ce6123e2565b029392505050565b6000610d3f8383612535565b8082028115828204841417610a8157610a816123e2565b60008261261657634e487b7160e01b600052601260045260246000fd5b500490565b81810381811115610a8157610a816123e2565b634e487b7160e01b600052603160045260246000fd5b60ff8281168282160390811115610a8157610a816123e2565b6000610d3f60ff84168361253556fea26469706673582212203ae909580b7eeb77da9f9353bea14543049be254b8feb8961fd99f423380e37e64736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000009ae380f0272e2162340a5bb646c354271c0f5cfc00000000000000000000000029e06bba53f73e271859214d9d87a1be636273c0
-----Decoded View---------------
Arg [0] : cncToken_ (address): 0x9aE380F0272E2162340a5bB646c354271c0F5cFC
Arg [1] : curveRegistryCacheAddress_ (address): 0x29E06bBA53f73E271859214D9D87a1bE636273C0
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000009ae380f0272e2162340a5bb646c354271c0f5cfc
Arg [1] : 00000000000000000000000029e06bba53f73e271859214d9d87a1be636273c0
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.