Overview
S Balance
S Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 1 from a total of 1 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Initialize | 11412846 | 6 days ago | IN | 0 S | 0.00394971 |
Loading...
Loading
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Source Code Verified (Exact Match)
Contract Name:
YieldSyncManager
Compiler Version
v0.8.28+commit.7893614a
Optimization Enabled:
Yes with 200 runs
Other Settings:
cancun EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; import {IVoter} from "contracts/interfaces/IVoter.sol"; import {IBribe} from "contracts/interfaces/IBribe.sol"; import {Clones} from "@openzeppelin/contracts/proxy/Clones.sol"; import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import {ERC20Validation} from "contracts/libraries/ERC20Validation.sol"; import {IYieldSyncVault} from "contracts/interfaces/YieldSync/IYieldSyncVault.sol"; import {EnumerableSet} from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import {Ownable2StepUpgradeable} from "@openzeppelin/contracts-upgradeable/access/Ownable2StepUpgradeable.sol"; import {IYieldSyncManager} from "contracts/interfaces/YieldSync/IYieldSyncManager.sol"; import {IMinter} from "contracts/interfaces/IMinter.sol"; /** * @title Yield Sync Manager * @notice handles managing and distributing YieldSync rewards to bribes * @author @Codeislight1 */ contract YieldSyncManager is IYieldSyncManager, Ownable2StepUpgradeable { using ERC20Validation for address; using EnumerableSet for EnumerableSet.AddressSet; /// @notice VoterV3 contract address IVoter public constant VOTER = IVoter(0xC1AE2779903cfB84CB9DEe5c03EcEAc32dc407F2); /// @notice Minter contract address IMinter public constant MINTER = IMinter(0x8b8c58CC70D13905EbF46c2a5ed1f41D52c83364); /// @notice Vault's implementation address address public immutable VAULT_IMPL; /// @notice gauges's enumerable set EnumerableSet.AddressSet private _gauges; /// @notice Whether the permissionless functionalities are gated bool public isGated; /// @notice Mapping gauge => vault mapping(address => address) public vaults; constructor(address _vaultImpl) { require( IYieldSyncVault(_vaultImpl).initialized(), "!vault implementation" ); VAULT_IMPL = _vaultImpl; } /// @notice Modifier syncs minter active period modifier updatePeriod() { MINTER.update_period(); _; } modifier onlyPublic() { require(!isGated || msg.sender == owner(), "gated"); _; } /// @notice initializes contract state function initialize(address _owner) external initializer { _transferOwnership(_owner); } /// @inheritdoc IYieldSyncManager function addGauges(address[] memory _gaugesArray) external onlyOwner { uint256 len = _gaugesArray.length; for (uint256 i; i < len; i++) { address _gauge = _gaugesArray[i]; require(VOTER.isGauge(_gauge), "!gauge"); require(!_gauges.contains(_gauge), "added gauge"); _gauges.add(_gauge); address _vault = Clones.cloneDeterministic( VAULT_IMPL, bytes32(uint256(uint160(_gauge))) ); IYieldSyncVault(_vault).initialize(address(this)); vaults[_gauge] = _vault; emit GaugeAdded(_gauge, _vault); } } /// @inheritdoc IYieldSyncManager function execute(address _target, bytes calldata _data) external onlyOwner { (bool success, ) = _target.call(_data); require(success, "!CALL"); } /// @inheritdoc IYieldSyncManager function setGated(bool _isGated) external onlyOwner { isGated = _isGated; emit GatedSetted(_isGated); } /// @notice Disables renouncing ownership function renounceOwnership() public view override onlyOwner { require(false, "!renounce"); } /// @inheritdoc IYieldSyncManager function length() external view returns (uint256) { return _gauges.length(); } /// @inheritdoc IYieldSyncManager function isGaugeAdded(address _gauge) external view returns (bool) { return _gauges.contains(_gauge); } /// @inheritdoc IYieldSyncManager function gauges() external view returns (address[] memory) { return _gauges.values(); } /// @inheritdoc IYieldSyncManager function gauges( uint256 _index, uint256 _length ) external view returns (address[] memory result_) { require(_index + _length <= _gauges.length(), "Index out of bounds"); result_ = new address[](_length); for (uint256 i; i < _length; i++) { result_[i] = _gauges.at(_index + i); } return result_; } /// @inheritdoc IYieldSyncManager function distributeAll() external updatePeriod onlyPublic { uint256 _length = _gauges.length(); for (uint256 i; i < _length; i++) { address _gauge = _gauges.at(i); _distribute(_gauge); } } /// @inheritdoc IYieldSyncManager function distribute( uint256 _index, uint256 _length ) external updatePeriod onlyPublic { require(_index + _length <= _gauges.length(), "Index out of bounds"); for (uint256 i; i < _length; i++) { address _gauge = _gauges.at(_index + i); _distribute(_gauge); } } /// @inheritdoc IYieldSyncManager function getAllPendingRewards() external view returns (PendingReward[] memory rewards_) { uint256 _length = _gauges.length(); rewards_ = new PendingReward[](_length); for (uint256 i; i < _length; i++) { address _gauge = _gauges.at(i); rewards_[i] = _getPendingReward(_gauge); } } /// @inheritdoc IYieldSyncManager function getPendingRewards( uint256 _index, uint256 _length ) external view returns (PendingReward[] memory rewards_) { require(_index + _length <= _gauges.length(), "Index out of bounds"); rewards_ = new PendingReward[](_length); for (uint256 i; i < _length; i++) { address _gauge = _gauges.at(_index + i); rewards_[i] = _getPendingReward(_gauge); } } /// @notice Distributes pending reward at vault function _distribute(address _gauge) internal { address _vault = vaults[_gauge]; address _bribe = VOTER.external_bribes(_gauge); uint256 len = IBribe(_bribe).rewardsListLength(); for (uint256 i; i < len; i++) { IERC20 _token = IERC20(IBribe(_bribe).rewardTokens(i)); // Checks token's validity if (!address(_token).isERC20()) continue; IYieldSyncVault(_vault).notifyRewards(_bribe, _token); } } /// @notice Gets pending rewards function _getPendingReward( address _gauge ) internal view returns (PendingReward memory reward_) { address _bribe = VOTER.external_bribes(_gauge); uint256 _length = IBribe(_bribe).rewardsListLength(); reward_.bribe = _bribe; reward_.bribeName = IBribe(_bribe).TYPE(); reward_.rewards = new TokenReward[](_length); for (uint256 i = 0; i < _length; i++) { IERC20 _token = IERC20(IBribe(_bribe).rewardTokens(i)); if (!address(_token).isERC20()) continue; address _vault = vaults[_gauge]; uint256 _reward = _token.balanceOf(_vault); reward_.rewards[i] = TokenReward({ token: address(_token), amount: _reward }); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; interface IVoter { function _ve() external view returns (address); function gauges(address _pair) external view returns (address); function isGauge(address _gauge) external view returns (bool); function poolForGauge(address _gauge) external view returns (address); function factory() external view returns (address); function minter() external view returns (address); function isWhitelisted(address token) external view returns (bool); function notifyRewardAmount(uint amount) external; function distributeAll() external; function distributeFees(address[] memory _gauges) external; function internal_bribes(address _gauge) external view returns (address); function external_bribes(address _gauge) external view returns (address); function usedWeights(uint id) external view returns (uint); function lastVoted(uint id) external view returns (uint); function poolVote( uint id, uint _index ) external view returns (address _pair); function votes(uint id, address _pool) external view returns (uint votes); function poolVoteLength(uint tokenId) external view returns (uint); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; interface IBribe { function _deposit(uint amount, uint tokenId) external; function _withdraw(uint amount, uint tokenId) external; function getRewardForOwner(uint tokenId, address[] memory tokens) external; function getRewardForAddress( address _owner, address[] memory tokens ) external; function rewardsListLength() external view returns (uint256); function rewardTokens(uint256 index) external view returns (address); function TYPE() external view returns (string memory); function notifyRewardAmount(address token, uint amount) external; function left(address token) external view returns (uint); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.8.0) (proxy/Clones.sol) pragma solidity ^0.8.0; /** * @dev https://eips.ethereum.org/EIPS/eip-1167[EIP 1167] is a standard for * deploying minimal proxy contracts, also known as "clones". * * > To simply and cheaply clone contract functionality in an immutable way, this standard specifies * > a minimal bytecode implementation that delegates all calls to a known, fixed address. * * The library includes functions to deploy a proxy using either `create` (traditional deployment) or `create2` * (salted deterministic deployment). It also includes functions to predict the addresses of clones deployed using the * deterministic method. * * _Available since v3.4._ */ library Clones { /** * @dev Deploys and returns the address of a clone that mimics the behaviour of `implementation`. * * This function uses the create opcode, which should never revert. */ function clone(address implementation) internal returns (address instance) { /// @solidity memory-safe-assembly assembly { // Cleans the upper 96 bits of the `implementation` word, then packs the first 3 bytes // of the `implementation` address with the bytecode before the address. mstore(0x00, or(shr(0xe8, shl(0x60, implementation)), 0x3d602d80600a3d3981f3363d3d373d3d3d363d73000000)) // Packs the remaining 17 bytes of `implementation` with the bytecode after the address. mstore(0x20, or(shl(0x78, implementation), 0x5af43d82803e903d91602b57fd5bf3)) instance := create(0, 0x09, 0x37) } require(instance != address(0), "ERC1167: create failed"); } /** * @dev Deploys and returns the address of a clone that mimics the behaviour of `implementation`. * * This function uses the create2 opcode and a `salt` to deterministically deploy * the clone. Using the same `implementation` and `salt` multiple time will revert, since * the clones cannot be deployed twice at the same address. */ function cloneDeterministic(address implementation, bytes32 salt) internal returns (address instance) { /// @solidity memory-safe-assembly assembly { // Cleans the upper 96 bits of the `implementation` word, then packs the first 3 bytes // of the `implementation` address with the bytecode before the address. mstore(0x00, or(shr(0xe8, shl(0x60, implementation)), 0x3d602d80600a3d3981f3363d3d373d3d3d363d73000000)) // Packs the remaining 17 bytes of `implementation` with the bytecode after the address. mstore(0x20, or(shl(0x78, implementation), 0x5af43d82803e903d91602b57fd5bf3)) instance := create2(0, 0x09, 0x37, salt) } require(instance != address(0), "ERC1167: create2 failed"); } /** * @dev Computes the address of a clone deployed using {Clones-cloneDeterministic}. */ function predictDeterministicAddress( address implementation, bytes32 salt, address deployer ) internal pure returns (address predicted) { /// @solidity memory-safe-assembly assembly { let ptr := mload(0x40) mstore(add(ptr, 0x38), deployer) mstore(add(ptr, 0x24), 0x5af43d82803e903d91602b57fd5bf3ff) mstore(add(ptr, 0x14), implementation) mstore(ptr, 0x3d602d80600a3d3981f3363d3d373d3d3d363d73) mstore(add(ptr, 0x58), salt) mstore(add(ptr, 0x78), keccak256(add(ptr, 0x0c), 0x37)) predicted := keccak256(add(ptr, 0x43), 0x55) } } /** * @dev Computes the address of a clone deployed using {Clones-cloneDeterministic}. */ function predictDeterministicAddress(address implementation, bytes32 salt) internal view returns (address predicted) { return predictDeterministicAddress(implementation, salt, address(this)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.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 pragma solidity ^0.8.13; import {IERC20Metadata} from "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol"; /// @notice a library used to validate ERC20 tokens gracefully library ERC20Validation { /// @notice validate token if it's an ERC20 by checking for 'decimals()' /// @param _token token to be validated /// @dev only used when the token is setup unintentially function isERC20(address _token) internal view returns (bool isValid) { if (_token.code.length == 0) return false; try IERC20Metadata(address(_token)).decimals() returns (uint8) { isValid = true; } catch { isValid = false; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; /// @notice Infterface for the IYieldSyncVault interface IYieldSyncVault { /// @notice Returns whether the vault has been initialized function initialized() external view returns (bool); /// @notice Returns the address of the vault owner function owner() external view returns (address); /// @notice Initializes the vault with an owner address /// @param _owner The address to set as the vault owner function initialize(address _owner) external; /// @notice Notifies the bribe with vault accumulated rewards /// @param _bribe The address of the bribe contract being notified function notifyRewards(address _bribe, IERC20 _token) external; /// @notice Executes an arbitrary function call to a target contract /// @param _target The address of the contract to call /// @param _data The calldata to execute on the target contract function execute(address _target, bytes calldata _data) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.8.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. * * ``` * 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.8.0) (access/Ownable2Step.sol) pragma solidity ^0.8.0; import "./OwnableUpgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Contract module which provides 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} and {acceptOwnership}. * * This module is used through inheritance. It will make available all functions * from parent (Ownable). */ abstract contract Ownable2StepUpgradeable is Initializable, OwnableUpgradeable { function __Ownable2Step_init() internal onlyInitializing { __Ownable_init_unchained(); } function __Ownable2Step_init_unchained() internal onlyInitializing { } address private _pendingOwner; event OwnershipTransferStarted(address indexed previousOwner, address indexed newOwner); /** * @dev Returns the address of the pending owner. */ function pendingOwner() public view virtual returns (address) { return _pendingOwner; } /** * @dev Starts the ownership transfer of the contract to a new account. Replaces the pending transfer if there is one. * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual override onlyOwner { _pendingOwner = newOwner; emit OwnershipTransferStarted(owner(), newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`) and deletes any pending owner. * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual override { delete _pendingOwner; super._transferOwnership(newOwner); } /** * @dev The new owner accepts the ownership transfer. */ function acceptOwnership() external { address sender = _msgSender(); require(pendingOwner() == sender, "Ownable2Step: caller is not the new owner"); _transferOwnership(sender); } /** * @dev This empty reserved space is put in place to allow future versions to add new * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ uint256[49] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; /// @notice Infterface for the IYieldSyncManager interface IYieldSyncManager { struct TokenReward { address token; uint256 amount; } struct PendingReward { string bribeName; address bribe; TokenReward[] rewards; } /// @notice Emitted when a gauge is added /// @param _gauge gauge added /// @param _vault deployed vault event GaugeAdded(address _gauge, address _vault); /// @notice Emitted when gated access is updated /// @param _isGated whether the accessis gated event GatedSetted(bool _isGated); /// @notice Adds multiple gauges to the manager /// @param _gaugesArray Array of gauge addresses to add function addGauges(address[] memory _gaugesArray) external; /// @notice Returns the total number of gauges managed function length() external view returns (uint256); /// @notice Returns whether the gauge was already added /// @param _gauge The address of the gauge to check function isGaugeAdded(address _gauge) external view returns (bool); /// @notice Returns all managed gauges function gauges() external view returns (address[] memory); /// @notice Returns a subset of managed gauges /// @param _index Starting index in the gauges array /// @param _length Number of gauges to return function gauges( uint256 _index, uint256 _length ) external view returns (address[] memory result_); /// @notice Distributes accumulated rewards for all gauges function distributeAll() external; /// @notice Distributes rewards for a subset of gauges /// @param _index Starting index in the gauges array /// @param _length Number of gauges to process function distribute(uint256 _index, uint256 _length) external; /// @notice Returns all pending rewards across all gauges /// @return rewards_ Array of pending rewards function getAllPendingRewards() external view returns (PendingReward[] memory rewards_); /// @notice Returns pending rewards for a subset of gauges /// @param _index Starting index in the gauges array /// @param _length Number of gauges to check /// @return rewards_ Array of pending rewards for the specified range function getPendingRewards( uint256 _index, uint256 _length ) external view returns (PendingReward[] memory rewards_); /// @notice Executes an arbitrary function call /// @param _target Address of the contract to call /// @param _data Calldata to execute function execute(address _target, bytes calldata _data) external; /// @notice Sets gated state /// @param _isGated Whether state is gated function setGated(bool _isGated) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.13; interface IMinter { function update_period() external returns (uint); function check() external view returns (bool); function period() external view returns (uint); function active_period() external view returns (uint); }
// 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.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/ContextUpgradeable.sol"; import "../proxy/utils/Initializable.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 OwnableUpgradeable is Initializable, ContextUpgradeable { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ function __Ownable_init() internal onlyInitializing { __Ownable_init_unchained(); } function __Ownable_init_unchained() internal onlyInitializing { _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 anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing 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); } /** * @dev This empty reserved space is put in place to allow future versions to add new * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ uint256[49] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.8.0) (proxy/utils/Initializable.sol) pragma solidity ^0.8.2; import "../../utils/AddressUpgradeable.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] * ``` * 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) || (!AddressUpgradeable.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 Internal function that returns the initialized version. Returns `_initialized` */ function _getInitializedVersion() internal view returns (uint8) { return _initialized; } /** * @dev Internal function that returns the initialized version. Returns `_initializing` */ function _isInitializing() internal view returns (bool) { return _initializing; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; import "../proxy/utils/Initializable.sol"; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with 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 ContextUpgradeable is Initializable { function __Context_init() internal onlyInitializing { } function __Context_init_unchained() internal onlyInitializing { } function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } /** * @dev This empty reserved space is put in place to allow future versions to add new * variables without shifting down storage in the inheritance chain. * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps */ uint256[50] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library AddressUpgradeable { /** * @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 * ==== * * [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://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ 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 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); } } }
{ "remappings": [ "@cryptoalgebra/=node_modules/@cryptoalgebra/", "@ensdomains/=node_modules/@ensdomains/", "@openzeppelin/=node_modules/@openzeppelin/", "@uniswap/=node_modules/@uniswap/", "hardhat-deploy/=node_modules/hardhat-deploy/", "hardhat/=node_modules/hardhat/", "forge-std/=node_modules/forge-std/" ], "optimizer": { "enabled": true, "runs": 200 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "cancun", "viaIR": false, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"address","name":"_vaultImpl","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_isGated","type":"bool"}],"name":"GatedSetted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_gauge","type":"address"},{"indexed":false,"internalType":"address","name":"_vault","type":"address"}],"name":"GaugeAdded","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":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferStarted","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"},{"inputs":[],"name":"MINTER","outputs":[{"internalType":"contract IMinter","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VAULT_IMPL","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VOTER","outputs":[{"internalType":"contract IVoter","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_gaugesArray","type":"address[]"}],"name":"addGauges","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_index","type":"uint256"},{"internalType":"uint256","name":"_length","type":"uint256"}],"name":"distribute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"distributeAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_target","type":"address"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"execute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_index","type":"uint256"},{"internalType":"uint256","name":"_length","type":"uint256"}],"name":"gauges","outputs":[{"internalType":"address[]","name":"result_","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"gauges","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllPendingRewards","outputs":[{"components":[{"internalType":"string","name":"bribeName","type":"string"},{"internalType":"address","name":"bribe","type":"address"},{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct IYieldSyncManager.TokenReward[]","name":"rewards","type":"tuple[]"}],"internalType":"struct IYieldSyncManager.PendingReward[]","name":"rewards_","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_index","type":"uint256"},{"internalType":"uint256","name":"_length","type":"uint256"}],"name":"getPendingRewards","outputs":[{"components":[{"internalType":"string","name":"bribeName","type":"string"},{"internalType":"address","name":"bribe","type":"address"},{"components":[{"internalType":"address","name":"token","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"internalType":"struct IYieldSyncManager.TokenReward[]","name":"rewards","type":"tuple[]"}],"internalType":"struct IYieldSyncManager.PendingReward[]","name":"rewards_","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isGated","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_gauge","type":"address"}],"name":"isGaugeAdded","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"length","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_isGated","type":"bool"}],"name":"setGated","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"vaults","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a060405234801561000f575f5ffd5b50604051611bb9380380611bb983398101604081905261002e916100ef565b806001600160a01b031663158ef93e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561006a573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061008e919061011c565b6100de5760405162461bcd60e51b815260206004820152601560248201527f217661756c7420696d706c656d656e746174696f6e0000000000000000000000604482015260640160405180910390fd5b6001600160a01b031660805261013b565b5f602082840312156100ff575f5ffd5b81516001600160a01b0381168114610115575f5ffd5b9392505050565b5f6020828403121561012c575f5ffd5b81518015158114610115575f5ffd5b608051611a5f61015a5f395f81816102b501526109e40152611a5f5ff3fe608060405234801561000f575f5ffd5b506004361061013d575f3560e01c80638da5cb5b116100b4578063c4d66de811610079578063c4d66de81461029d578063dd23b99d146102b0578063e30c3978146102d7578063e4741da4146102e8578063f2fde38b146102f5578063fe6d812414610308575f5ffd5b80638da5cb5b1461020f5780638ebbfd53146102345780638ebf2fd614610247578063a622ee7c14610262578063bba463da1461028a575f5ffd5b80635a1994c4116101055780635a1994c4146101af578063715018a6146101cf5780637625391a146101d757806379ba5097146101ea578063821bdcf1146101f25780638370078d146101fa575f5ffd5b80631cff79cd146101415780631f7b6d32146101565780633c3a248d14610171578063436596c4146101945780634471e9991461019c575b5f5ffd5b61015461014f366004611593565b610323565b005b61015e6103c8565b6040519081526020015b60405180910390f35b61018461017f366004611613565b6103d8565b6040519015158152602001610168565b6101546103ea565b6101546101aa36600461163b565b6104eb565b6101c26101bd366004611656565b61053a565b6040516101689190611676565b61015461060b565b6101546101e5366004611656565b610649565b610154610772565b6101c26107ec565b6102026107f8565b60405161016891906116c1565b6033546001600160a01b03165b6040516001600160a01b039091168152602001610168565b610154610242366004611805565b6108a8565b61021c73c1ae2779903cfb84cb9dee5c03eceac32dc407f281565b61021c610270366004611613565b609a6020525f90815260409020546001600160a01b031681565b610202610298366004611656565b610ad9565b6101546102ab366004611613565b610bab565b61021c7f000000000000000000000000000000000000000000000000000000000000000081565b6065546001600160a01b031661021c565b6099546101849060ff1681565b610154610303366004611613565b610cb7565b61021c738b8c58cc70d13905ebf46c2a5ed1f41d52c8336481565b61032b610d28565b5f836001600160a01b031683836040516103469291906118b9565b5f604051808303815f865af19150503d805f811461037f576040519150601f19603f3d011682016040523d82523d5f602084013e610384565b606091505b50509050806103c25760405162461bcd60e51b81526020600482015260056024820152640850d0531360da1b60448201526064015b60405180910390fd5b50505050565b5f6103d36097610d82565b905090565b5f6103e4609783610d8b565b92915050565b738b8c58cc70d13905ebf46c2a5ed1f41d52c833646001600160a01b031663ed29fc116040518163ffffffff1660e01b81526004016020604051808303815f875af115801561043b573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061045f91906118c8565b5060995460ff16158061047c57506033546001600160a01b031633145b6104b05760405162461bcd60e51b815260206004820152600560248201526419d85d195960da1b60448201526064016103b9565b5f6104bb6097610d82565b90505f5b818110156104e7575f6104d3609783610daf565b90506104de81610dba565b506001016104bf565b5050565b6104f3610d28565b6099805460ff19168215159081179091556040519081527f225f76ef95066f071aafbeccb060e45a81478decad2bb851b4c4e92752f26ee89060200160405180910390a150565b60606105466097610d82565b61055083856118df565b111561056e5760405162461bcd60e51b81526004016103b9906118fe565b8167ffffffffffffffff811115610587576105876117c0565b6040519080825280602002602001820160405280156105b0578160200160208202803683370190505b5090505f5b82811015610604576105d26105ca82866118df565b609790610daf565b8282815181106105e4576105e461192b565b6001600160a01b03909216602092830291909101909101526001016105b5565b5092915050565b610613610d28565b60405162461bcd60e51b81526020600482015260096024820152682172656e6f756e636560b81b60448201526064016103b9565b565b738b8c58cc70d13905ebf46c2a5ed1f41d52c833646001600160a01b031663ed29fc116040518163ffffffff1660e01b81526004016020604051808303815f875af115801561069a573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106be91906118c8565b5060995460ff1615806106db57506033546001600160a01b031633145b61070f5760405162461bcd60e51b815260206004820152600560248201526419d85d195960da1b60448201526064016103b9565b6107196097610d82565b61072382846118df565b11156107415760405162461bcd60e51b81526004016103b9906118fe565b5f5b8181101561076d575f6107596105ca83866118df565b905061076481610dba565b50600101610743565b505050565b60655433906001600160a01b031681146107e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103b9565b6107e981610fb0565b50565b60606103d36097610fc9565b60605f6108056097610d82565b90508067ffffffffffffffff811115610820576108206117c0565b60405190808252806020026020018201604052801561085957816020015b610846611556565b81526020019060019003908161083e5790505b5091505f5b818110156108a3575f610872609783610daf565b905061087d81610fd5565b84838151811061088f5761088f61192b565b60209081029190910101525060010161085e565b505090565b6108b0610d28565b80515f5b8181101561076d575f8382815181106108cf576108cf61192b565b602090810291909101015160405163aa79979b60e01b81526001600160a01b038216600482015290915073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063aa79979b90602401602060405180830381865afa158015610933573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610957919061193f565b61098c5760405162461bcd60e51b815260206004820152600660248201526521676175676560d01b60448201526064016103b9565b610997609782610d8b565b156109d25760405162461bcd60e51b815260206004820152600b60248201526a616464656420676175676560a81b60448201526064016103b9565b6109dd609782611305565b505f610a127f00000000000000000000000000000000000000000000000000000000000000006001600160a01b038416611319565b60405163189acdbd60e31b81523060048201529091506001600160a01b0382169063c4d66de8906024015f604051808303815f87803b158015610a53575f5ffd5b505af1158015610a65573d5f5f3e3d5ffd5b505050506001600160a01b038281165f818152609a602090815260409182902080546001600160a01b031916948616948517905581519283528201929092527f30f76c775008e3e7351fdc109cbad6654f319035c83d92e5b0701c563bf15489910160405180910390a150506001016108b4565b6060610ae56097610d82565b610aef83856118df565b1115610b0d5760405162461bcd60e51b81526004016103b9906118fe565b8167ffffffffffffffff811115610b2657610b266117c0565b604051908082528060200260200182016040528015610b5f57816020015b610b4c611556565b815260200190600190039081610b445790505b5090505f5b82811015610604575f610b7a6105ca83876118df565b9050610b8581610fd5565b838381518110610b9757610b9761192b565b602090810291909101015250600101610b64565b5f54610100900460ff1615808015610bc957505f54600160ff909116105b80610be25750303b158015610be257505f5460ff166001145b610c455760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103b9565b5f805460ff191660011790558015610c66575f805461ff0019166101001790555b610c6f82610fb0565b80156104e7575f805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b610cbf610d28565b606580546001600160a01b0383166001600160a01b03199091168117909155610cf06033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6033546001600160a01b031633146106475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103b9565b5f6103e4825490565b6001600160a01b0381165f90815260018301602052604081205415155b9392505050565b5f610da883836113b3565b6001600160a01b038181165f818152609a602052604080822054905163ae21c4cb60e01b81526004810193909352909216919073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063ae21c4cb90602401602060405180830381865afa158015610e27573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610e4b919061195a565b90505f816001600160a01b031663e68863966040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e8a573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610eae91906118c8565b90505f5b81811015610fa957604051637bb7bed160e01b8152600481018290525f906001600160a01b03851690637bb7bed190602401602060405180830381865afa158015610eff573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610f23919061195a565b9050610f37816001600160a01b03166113d9565b610f415750610fa1565b604051635b2abb8160e01b81526001600160a01b0385811660048301528281166024830152861690635b2abb81906044015f604051808303815f87803b158015610f89575f5ffd5b505af1158015610f9b573d5f5f3e3d5ffd5b50505050505b600101610eb2565b5050505050565b606580546001600160a01b03191690556107e981611460565b60605f610da8836114b1565b610fdd611556565b60405163ae21c4cb60e01b81526001600160a01b03831660048201525f9073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063ae21c4cb90602401602060405180830381865afa158015611035573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611059919061195a565b90505f816001600160a01b031663e68863966040518163ffffffff1660e01b8152600401602060405180830381865afa158015611098573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906110bc91906118c8565b90508183602001906001600160a01b031690816001600160a01b031681525050816001600160a01b031663bb24fe8a6040518163ffffffff1660e01b81526004015f60405180830381865afa158015611117573d5f5f3e3d5ffd5b505050506040513d5f823e601f3d908101601f1916820160405261113e9190810190611975565b83528067ffffffffffffffff811115611159576111596117c0565b60405190808252806020026020018201604052801561119d57816020015b604080518082019091525f80825260208201528152602001906001900390816111775790505b5060408401525f5b818110156112fd57604051637bb7bed160e01b8152600481018290525f906001600160a01b03851690637bb7bed190602401602060405180830381865afa1580156111f2573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611216919061195a565b905061122a816001600160a01b03166113d9565b61123457506112f5565b6001600160a01b038681165f908152609a60205260408082205490516370a0823160e01b815290831660048201819052928416906370a0823190602401602060405180830381865afa15801561128c573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906112b091906118c8565b90506040518060400160405280846001600160a01b0316815260200182815250876040015185815181106112e6576112e661192b565b60200260200101819052505050505b6001016111a5565b505050919050565b5f610da8836001600160a01b03841661150a565b5f763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c175f526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760095ff590506001600160a01b0381166103e45760405162461bcd60e51b815260206004820152601760248201527f455243313136373a2063726561746532206661696c656400000000000000000060448201526064016103b9565b5f825f0182815481106113c8576113c861192b565b905f5260205f200154905092915050565b5f816001600160a01b03163b5f036113f257505f919050565b816001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa92505050801561144c575060408051601f3d908101601f1916820190925261144991810190611a09565b60015b61145757505f919050565b50600192915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0905f90a35050565b6060815f018054806020026020016040519081016040528092919081815260200182805480156114fe57602002820191905f5260205f20905b8154815260200190600101908083116114ea575b50505050509050919050565b5f81815260018301602052604081205461154f57508154600181810184555f8481526020808220909301849055845484825282860190935260409020919091556103e4565b505f6103e4565b6040518060600160405280606081526020015f6001600160a01b03168152602001606081525090565b6001600160a01b03811681146107e9575f5ffd5b5f5f5f604084860312156115a5575f5ffd5b83356115b08161157f565b9250602084013567ffffffffffffffff8111156115cb575f5ffd5b8401601f810186136115db575f5ffd5b803567ffffffffffffffff8111156115f1575f5ffd5b866020828401011115611602575f5ffd5b939660209190910195509293505050565b5f60208284031215611623575f5ffd5b8135610da88161157f565b80151581146107e9575f5ffd5b5f6020828403121561164b575f5ffd5b8135610da88161162e565b5f5f60408385031215611667575f5ffd5b50508035926020909101359150565b602080825282518282018190525f918401906040840190835b818110156116b65783516001600160a01b031683526020938401939092019160010161168f565b509095945050505050565b5f602082016020835280845180835260408501915060408160051b8601019250602086015f5b828110156117b457603f1987860301845281518051606087528051806060890152806020830160808a015e5f6080828a0181018290526020858101516001600160a01b0316818c0152604095860151601f909401601f19168b018b81038301968c0196909652835191860182815293019491935060a0909101905b8084101561179b57845180516001600160a01b031683526020808201518185015290950194600194909401939250604090910190611762565b50975050506020948501949290920191506001016116e7565b50929695505050505050565b634e487b7160e01b5f52604160045260245ffd5b604051601f8201601f1916810167ffffffffffffffff811182821017156117fd576117fd6117c0565b604052919050565b5f60208284031215611815575f5ffd5b813567ffffffffffffffff81111561182b575f5ffd5b8201601f8101841361183b575f5ffd5b803567ffffffffffffffff811115611855576118556117c0565b8060051b611865602082016117d4565b91825260208184018101929081019087841115611880575f5ffd5b6020850194505b838510156118ae578435925061189c8361157f565b82825260209485019490910190611887565b979650505050505050565b818382375f9101908152919050565b5f602082840312156118d8575f5ffd5b5051919050565b808201808211156103e457634e487b7160e01b5f52601160045260245ffd5b602080825260139082015272496e646578206f7574206f6620626f756e647360681b604082015260600190565b634e487b7160e01b5f52603260045260245ffd5b5f6020828403121561194f575f5ffd5b8151610da88161162e565b5f6020828403121561196a575f5ffd5b8151610da88161157f565b5f60208284031215611985575f5ffd5b815167ffffffffffffffff81111561199b575f5ffd5b8201601f810184136119ab575f5ffd5b805167ffffffffffffffff8111156119c5576119c56117c0565b6119d8601f8201601f19166020016117d4565b8181528560208385010111156119ec575f5ffd5b8160208401602083015e5f91810160200191909152949350505050565b5f60208284031215611a19575f5ffd5b815160ff81168114610da8575f5ffdfea26469706673582212206f12c4bf25f9c3f00a0fb6d85351991934f4529d832fed033a9a0bb3695b6dd264736f6c634300081c0033000000000000000000000000be402808d4c336fde9a1d5857dc55be8d9b3ebb5
Deployed Bytecode
0x608060405234801561000f575f5ffd5b506004361061013d575f3560e01c80638da5cb5b116100b4578063c4d66de811610079578063c4d66de81461029d578063dd23b99d146102b0578063e30c3978146102d7578063e4741da4146102e8578063f2fde38b146102f5578063fe6d812414610308575f5ffd5b80638da5cb5b1461020f5780638ebbfd53146102345780638ebf2fd614610247578063a622ee7c14610262578063bba463da1461028a575f5ffd5b80635a1994c4116101055780635a1994c4146101af578063715018a6146101cf5780637625391a146101d757806379ba5097146101ea578063821bdcf1146101f25780638370078d146101fa575f5ffd5b80631cff79cd146101415780631f7b6d32146101565780633c3a248d14610171578063436596c4146101945780634471e9991461019c575b5f5ffd5b61015461014f366004611593565b610323565b005b61015e6103c8565b6040519081526020015b60405180910390f35b61018461017f366004611613565b6103d8565b6040519015158152602001610168565b6101546103ea565b6101546101aa36600461163b565b6104eb565b6101c26101bd366004611656565b61053a565b6040516101689190611676565b61015461060b565b6101546101e5366004611656565b610649565b610154610772565b6101c26107ec565b6102026107f8565b60405161016891906116c1565b6033546001600160a01b03165b6040516001600160a01b039091168152602001610168565b610154610242366004611805565b6108a8565b61021c73c1ae2779903cfb84cb9dee5c03eceac32dc407f281565b61021c610270366004611613565b609a6020525f90815260409020546001600160a01b031681565b610202610298366004611656565b610ad9565b6101546102ab366004611613565b610bab565b61021c7f000000000000000000000000be402808d4c336fde9a1d5857dc55be8d9b3ebb581565b6065546001600160a01b031661021c565b6099546101849060ff1681565b610154610303366004611613565b610cb7565b61021c738b8c58cc70d13905ebf46c2a5ed1f41d52c8336481565b61032b610d28565b5f836001600160a01b031683836040516103469291906118b9565b5f604051808303815f865af19150503d805f811461037f576040519150601f19603f3d011682016040523d82523d5f602084013e610384565b606091505b50509050806103c25760405162461bcd60e51b81526020600482015260056024820152640850d0531360da1b60448201526064015b60405180910390fd5b50505050565b5f6103d36097610d82565b905090565b5f6103e4609783610d8b565b92915050565b738b8c58cc70d13905ebf46c2a5ed1f41d52c833646001600160a01b031663ed29fc116040518163ffffffff1660e01b81526004016020604051808303815f875af115801561043b573d5f5f3e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061045f91906118c8565b5060995460ff16158061047c57506033546001600160a01b031633145b6104b05760405162461bcd60e51b815260206004820152600560248201526419d85d195960da1b60448201526064016103b9565b5f6104bb6097610d82565b90505f5b818110156104e7575f6104d3609783610daf565b90506104de81610dba565b506001016104bf565b5050565b6104f3610d28565b6099805460ff19168215159081179091556040519081527f225f76ef95066f071aafbeccb060e45a81478decad2bb851b4c4e92752f26ee89060200160405180910390a150565b60606105466097610d82565b61055083856118df565b111561056e5760405162461bcd60e51b81526004016103b9906118fe565b8167ffffffffffffffff811115610587576105876117c0565b6040519080825280602002602001820160405280156105b0578160200160208202803683370190505b5090505f5b82811015610604576105d26105ca82866118df565b609790610daf565b8282815181106105e4576105e461192b565b6001600160a01b03909216602092830291909101909101526001016105b5565b5092915050565b610613610d28565b60405162461bcd60e51b81526020600482015260096024820152682172656e6f756e636560b81b60448201526064016103b9565b565b738b8c58cc70d13905ebf46c2a5ed1f41d52c833646001600160a01b031663ed29fc116040518163ffffffff1660e01b81526004016020604051808303815f875af115801561069a573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106be91906118c8565b5060995460ff1615806106db57506033546001600160a01b031633145b61070f5760405162461bcd60e51b815260206004820152600560248201526419d85d195960da1b60448201526064016103b9565b6107196097610d82565b61072382846118df565b11156107415760405162461bcd60e51b81526004016103b9906118fe565b5f5b8181101561076d575f6107596105ca83866118df565b905061076481610dba565b50600101610743565b505050565b60655433906001600160a01b031681146107e05760405162461bcd60e51b815260206004820152602960248201527f4f776e61626c6532537465703a2063616c6c6572206973206e6f7420746865206044820152683732bb9037bbb732b960b91b60648201526084016103b9565b6107e981610fb0565b50565b60606103d36097610fc9565b60605f6108056097610d82565b90508067ffffffffffffffff811115610820576108206117c0565b60405190808252806020026020018201604052801561085957816020015b610846611556565b81526020019060019003908161083e5790505b5091505f5b818110156108a3575f610872609783610daf565b905061087d81610fd5565b84838151811061088f5761088f61192b565b60209081029190910101525060010161085e565b505090565b6108b0610d28565b80515f5b8181101561076d575f8382815181106108cf576108cf61192b565b602090810291909101015160405163aa79979b60e01b81526001600160a01b038216600482015290915073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063aa79979b90602401602060405180830381865afa158015610933573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610957919061193f565b61098c5760405162461bcd60e51b815260206004820152600660248201526521676175676560d01b60448201526064016103b9565b610997609782610d8b565b156109d25760405162461bcd60e51b815260206004820152600b60248201526a616464656420676175676560a81b60448201526064016103b9565b6109dd609782611305565b505f610a127f000000000000000000000000be402808d4c336fde9a1d5857dc55be8d9b3ebb56001600160a01b038416611319565b60405163189acdbd60e31b81523060048201529091506001600160a01b0382169063c4d66de8906024015f604051808303815f87803b158015610a53575f5ffd5b505af1158015610a65573d5f5f3e3d5ffd5b505050506001600160a01b038281165f818152609a602090815260409182902080546001600160a01b031916948616948517905581519283528201929092527f30f76c775008e3e7351fdc109cbad6654f319035c83d92e5b0701c563bf15489910160405180910390a150506001016108b4565b6060610ae56097610d82565b610aef83856118df565b1115610b0d5760405162461bcd60e51b81526004016103b9906118fe565b8167ffffffffffffffff811115610b2657610b266117c0565b604051908082528060200260200182016040528015610b5f57816020015b610b4c611556565b815260200190600190039081610b445790505b5090505f5b82811015610604575f610b7a6105ca83876118df565b9050610b8581610fd5565b838381518110610b9757610b9761192b565b602090810291909101015250600101610b64565b5f54610100900460ff1615808015610bc957505f54600160ff909116105b80610be25750303b158015610be257505f5460ff166001145b610c455760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016103b9565b5f805460ff191660011790558015610c66575f805461ff0019166101001790555b610c6f82610fb0565b80156104e7575f805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b610cbf610d28565b606580546001600160a01b0383166001600160a01b03199091168117909155610cf06033546001600160a01b031690565b6001600160a01b03167f38d16b8cac22d99fc7c124b9cd0de2d3fa1faef420bfe791d8c362d765e2270060405160405180910390a350565b6033546001600160a01b031633146106475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016103b9565b5f6103e4825490565b6001600160a01b0381165f90815260018301602052604081205415155b9392505050565b5f610da883836113b3565b6001600160a01b038181165f818152609a602052604080822054905163ae21c4cb60e01b81526004810193909352909216919073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063ae21c4cb90602401602060405180830381865afa158015610e27573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610e4b919061195a565b90505f816001600160a01b031663e68863966040518163ffffffff1660e01b8152600401602060405180830381865afa158015610e8a573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610eae91906118c8565b90505f5b81811015610fa957604051637bb7bed160e01b8152600481018290525f906001600160a01b03851690637bb7bed190602401602060405180830381865afa158015610eff573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610f23919061195a565b9050610f37816001600160a01b03166113d9565b610f415750610fa1565b604051635b2abb8160e01b81526001600160a01b0385811660048301528281166024830152861690635b2abb81906044015f604051808303815f87803b158015610f89575f5ffd5b505af1158015610f9b573d5f5f3e3d5ffd5b50505050505b600101610eb2565b5050505050565b606580546001600160a01b03191690556107e981611460565b60605f610da8836114b1565b610fdd611556565b60405163ae21c4cb60e01b81526001600160a01b03831660048201525f9073c1ae2779903cfb84cb9dee5c03eceac32dc407f29063ae21c4cb90602401602060405180830381865afa158015611035573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611059919061195a565b90505f816001600160a01b031663e68863966040518163ffffffff1660e01b8152600401602060405180830381865afa158015611098573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906110bc91906118c8565b90508183602001906001600160a01b031690816001600160a01b031681525050816001600160a01b031663bb24fe8a6040518163ffffffff1660e01b81526004015f60405180830381865afa158015611117573d5f5f3e3d5ffd5b505050506040513d5f823e601f3d908101601f1916820160405261113e9190810190611975565b83528067ffffffffffffffff811115611159576111596117c0565b60405190808252806020026020018201604052801561119d57816020015b604080518082019091525f80825260208201528152602001906001900390816111775790505b5060408401525f5b818110156112fd57604051637bb7bed160e01b8152600481018290525f906001600160a01b03851690637bb7bed190602401602060405180830381865afa1580156111f2573d5f5f3e3d5ffd5b505050506040513d601f19601f82011682018060405250810190611216919061195a565b905061122a816001600160a01b03166113d9565b61123457506112f5565b6001600160a01b038681165f908152609a60205260408082205490516370a0823160e01b815290831660048201819052928416906370a0823190602401602060405180830381865afa15801561128c573d5f5f3e3d5ffd5b505050506040513d601f19601f820116820180604052508101906112b091906118c8565b90506040518060400160405280846001600160a01b0316815260200182815250876040015185815181106112e6576112e661192b565b60200260200101819052505050505b6001016111a5565b505050919050565b5f610da8836001600160a01b03841661150a565b5f763d602d80600a3d3981f3363d3d373d3d3d363d730000008360601b60e81c175f526e5af43d82803e903d91602b57fd5bf38360781b1760205281603760095ff590506001600160a01b0381166103e45760405162461bcd60e51b815260206004820152601760248201527f455243313136373a2063726561746532206661696c656400000000000000000060448201526064016103b9565b5f825f0182815481106113c8576113c861192b565b905f5260205f200154905092915050565b5f816001600160a01b03163b5f036113f257505f919050565b816001600160a01b031663313ce5676040518163ffffffff1660e01b8152600401602060405180830381865afa92505050801561144c575060408051601f3d908101601f1916820190925261144991810190611a09565b60015b61145757505f919050565b50600192915050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0905f90a35050565b6060815f018054806020026020016040519081016040528092919081815260200182805480156114fe57602002820191905f5260205f20905b8154815260200190600101908083116114ea575b50505050509050919050565b5f81815260018301602052604081205461154f57508154600181810184555f8481526020808220909301849055845484825282860190935260409020919091556103e4565b505f6103e4565b6040518060600160405280606081526020015f6001600160a01b03168152602001606081525090565b6001600160a01b03811681146107e9575f5ffd5b5f5f5f604084860312156115a5575f5ffd5b83356115b08161157f565b9250602084013567ffffffffffffffff8111156115cb575f5ffd5b8401601f810186136115db575f5ffd5b803567ffffffffffffffff8111156115f1575f5ffd5b866020828401011115611602575f5ffd5b939660209190910195509293505050565b5f60208284031215611623575f5ffd5b8135610da88161157f565b80151581146107e9575f5ffd5b5f6020828403121561164b575f5ffd5b8135610da88161162e565b5f5f60408385031215611667575f5ffd5b50508035926020909101359150565b602080825282518282018190525f918401906040840190835b818110156116b65783516001600160a01b031683526020938401939092019160010161168f565b509095945050505050565b5f602082016020835280845180835260408501915060408160051b8601019250602086015f5b828110156117b457603f1987860301845281518051606087528051806060890152806020830160808a015e5f6080828a0181018290526020858101516001600160a01b0316818c0152604095860151601f909401601f19168b018b81038301968c0196909652835191860182815293019491935060a0909101905b8084101561179b57845180516001600160a01b031683526020808201518185015290950194600194909401939250604090910190611762565b50975050506020948501949290920191506001016116e7565b50929695505050505050565b634e487b7160e01b5f52604160045260245ffd5b604051601f8201601f1916810167ffffffffffffffff811182821017156117fd576117fd6117c0565b604052919050565b5f60208284031215611815575f5ffd5b813567ffffffffffffffff81111561182b575f5ffd5b8201601f8101841361183b575f5ffd5b803567ffffffffffffffff811115611855576118556117c0565b8060051b611865602082016117d4565b91825260208184018101929081019087841115611880575f5ffd5b6020850194505b838510156118ae578435925061189c8361157f565b82825260209485019490910190611887565b979650505050505050565b818382375f9101908152919050565b5f602082840312156118d8575f5ffd5b5051919050565b808201808211156103e457634e487b7160e01b5f52601160045260245ffd5b602080825260139082015272496e646578206f7574206f6620626f756e647360681b604082015260600190565b634e487b7160e01b5f52603260045260245ffd5b5f6020828403121561194f575f5ffd5b8151610da88161162e565b5f6020828403121561196a575f5ffd5b8151610da88161157f565b5f60208284031215611985575f5ffd5b815167ffffffffffffffff81111561199b575f5ffd5b8201601f810184136119ab575f5ffd5b805167ffffffffffffffff8111156119c5576119c56117c0565b6119d8601f8201601f19166020016117d4565b8181528560208385010111156119ec575f5ffd5b8160208401602083015e5f91810160200191909152949350505050565b5f60208284031215611a19575f5ffd5b815160ff81168114610da8575f5ffdfea26469706673582212206f12c4bf25f9c3f00a0fb6d85351991934f4529d832fed033a9a0bb3695b6dd264736f6c634300081c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000be402808d4c336fde9a1d5857dc55be8d9b3ebb5
-----Decoded View---------------
Arg [0] : _vaultImpl (address): 0xbe402808D4C336FDe9a1d5857dC55Be8D9b3EBB5
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000be402808d4c336fde9a1d5857dc55be8d9b3ebb5
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 35 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
[ 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.