Overview
S Balance
0 S
S Value
-More Info
Private Name Tags
ContractCreator
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 Name:
BundleRegistry
Compiler Version
v0.8.12+commit.f00d7308
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: BUSL-1.1 pragma solidity 0.8.12; // Proxy Support import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol"; import { IBundleRegistry } from "./interfaces/IBundleRegistry.sol"; contract BundleRegistry is IBundleRegistry, Initializable, OwnableUpgradeable, UUPSUpgradeable, PausableUpgradeable { /// @custom:oz-upgrades-unsafe-allow constructor constructor() initializer() {} // Storage mapping(bytes32 => DataSourceAdapter) public bundles; function initialize() public initializer { __UUPSUpgradeable_init(); __Ownable_init(); __Pausable_init(); } /// @dev Registers an execution bundle, making data accessible to nodes. /// Once registered, each bundle is immutable. /// Only the contract owner can change it, and they can only /// deactivate/reactivate it if necessary. /// @param _bundle The bundle of the transformation module. /// @param _source The source of the transformation module source (e.g. "The Graph" or "Twitter") /// @param _host The host of the transformation module source (e.g. "Uniswap" or "@random-twitter-username") /// @param _output The output type of the adapter, example: OHLC, OHLCV, SingleValue, etc. /// @param _active Determines if the adapter is active or not, allows for inactive sources /// to be deprecated, vaults can pause based on this function register( string memory _bundle, string memory _source, string memory _host, string memory _output, string memory _infoHash, bool _active ) external whenNotPaused { require(isIPFS(_bundle), "Bundle must be an IPFS CID hash"); bytes32 bundleHash = keccak256( abi.encode(_bundle, _source, _host, _output) ); // Check that bundle does not yet have an author--proxy // to check whether the bundle was already registered. require( bundles[bundleHash].author == address(0), "Bundle already registered" ); // Record bundle bundles[bundleHash] = DataSourceAdapter({ bundle: _bundle, source: _source, host: _host, output: _output, info: _infoHash, active: _active, author: _msgSender() }); // Emit the event that the bundle was created emit BundleRegistered( bundleHash, _bundle, _host, _source, _output, _infoHash, _active, msg.sender ); } function _authorizeUpgrade( address newImplementation ) internal override onlyOwner {} function pause() external onlyOwner { _pause(); } /// @dev onlyOwner function to deprecate (or reactivate) an existing adapter. /// @param _adapter The key of the adapter to pause. /// @param _remainActive Whether to pause or unpause; false to pause. function setAdapterState( bytes32 _adapter, bool _remainActive ) external onlyOwner { bundles[_adapter].active = _remainActive; emit BundleStateChange(_adapter, _remainActive); } /// @dev Checks if the passed string is a IPFS link or not. /// @param source String that needs to checked. /// @return true if the string passed is IPFS, else it will return false. function isIPFS(string memory source) internal pure returns (bool) { bytes memory sourceToBytes = bytes(source); require(sourceToBytes.length == 46, "Length"); bytes memory firstChar = new bytes(1); bytes memory secondChar = new bytes(1); bytes memory lastChar = new bytes(1); firstChar[0] = sourceToBytes[0]; secondChar[0] = sourceToBytes[1]; lastChar[0] = sourceToBytes[45]; return keccak256(firstChar) == keccak256(bytes("Q")) && keccak256(secondChar) == keccak256(bytes("m")) && (keccak256(lastChar) != keccak256(bytes("O")) && keccak256(lastChar) != keccak256(bytes("I")) && keccak256(lastChar) != keccak256(bytes("l"))); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (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 { __Context_init_unchained(); __Ownable_init_unchained(); } function __Ownable_init_unchained() internal onlyInitializing { _transferOwnership(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { 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); } uint256[49] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (proxy/ERC1967/ERC1967Upgrade.sol) pragma solidity ^0.8.2; import "../beacon/IBeaconUpgradeable.sol"; import "../../utils/AddressUpgradeable.sol"; import "../../utils/StorageSlotUpgradeable.sol"; import "../utils/Initializable.sol"; /** * @dev This abstract contract provides getters and event emitting update functions for * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots. * * _Available since v4.1._ * * @custom:oz-upgrades-unsafe-allow delegatecall */ abstract contract ERC1967UpgradeUpgradeable is Initializable { function __ERC1967Upgrade_init() internal onlyInitializing { __ERC1967Upgrade_init_unchained(); } function __ERC1967Upgrade_init_unchained() internal onlyInitializing { } // This is the keccak-256 hash of "eip1967.proxy.rollback" subtracted by 1 bytes32 private constant _ROLLBACK_SLOT = 0x4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143; /** * @dev Storage slot with the address of the current implementation. * This is the keccak-256 hash of "eip1967.proxy.implementation" subtracted by 1, and is * validated in the constructor. */ bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; /** * @dev Emitted when the implementation is upgraded. */ event Upgraded(address indexed implementation); /** * @dev Returns the current implementation address. */ function _getImplementation() internal view returns (address) { return StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value; } /** * @dev Stores a new address in the EIP1967 implementation slot. */ function _setImplementation(address newImplementation) private { require(AddressUpgradeable.isContract(newImplementation), "ERC1967: new implementation is not a contract"); StorageSlotUpgradeable.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; } /** * @dev Perform implementation upgrade * * Emits an {Upgraded} event. */ function _upgradeTo(address newImplementation) internal { _setImplementation(newImplementation); emit Upgraded(newImplementation); } /** * @dev Perform implementation upgrade with additional setup call. * * Emits an {Upgraded} event. */ function _upgradeToAndCall( address newImplementation, bytes memory data, bool forceCall ) internal { _upgradeTo(newImplementation); if (data.length > 0 || forceCall) { _functionDelegateCall(newImplementation, data); } } /** * @dev Perform implementation upgrade with security checks for UUPS proxies, and additional setup call. * * Emits an {Upgraded} event. */ function _upgradeToAndCallSecure( address newImplementation, bytes memory data, bool forceCall ) internal { address oldImplementation = _getImplementation(); // Initial upgrade and setup call _setImplementation(newImplementation); if (data.length > 0 || forceCall) { _functionDelegateCall(newImplementation, data); } // Perform rollback test if not already in progress StorageSlotUpgradeable.BooleanSlot storage rollbackTesting = StorageSlotUpgradeable.getBooleanSlot(_ROLLBACK_SLOT); if (!rollbackTesting.value) { // Trigger rollback using upgradeTo from the new implementation rollbackTesting.value = true; _functionDelegateCall( newImplementation, abi.encodeWithSignature("upgradeTo(address)", oldImplementation) ); rollbackTesting.value = false; // Check rollback was effective require(oldImplementation == _getImplementation(), "ERC1967Upgrade: upgrade breaks further upgrades"); // Finally reset to the new implementation and log the upgrade _upgradeTo(newImplementation); } } /** * @dev Storage slot with the admin of the contract. * This is the keccak-256 hash of "eip1967.proxy.admin" subtracted by 1, and is * validated in the constructor. */ bytes32 internal constant _ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103; /** * @dev Emitted when the admin account has changed. */ event AdminChanged(address previousAdmin, address newAdmin); /** * @dev Returns the current admin. */ function _getAdmin() internal view returns (address) { return StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value; } /** * @dev Stores a new address in the EIP1967 admin slot. */ function _setAdmin(address newAdmin) private { require(newAdmin != address(0), "ERC1967: new admin is the zero address"); StorageSlotUpgradeable.getAddressSlot(_ADMIN_SLOT).value = newAdmin; } /** * @dev Changes the admin of the proxy. * * Emits an {AdminChanged} event. */ function _changeAdmin(address newAdmin) internal { emit AdminChanged(_getAdmin(), newAdmin); _setAdmin(newAdmin); } /** * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy. * This is bytes32(uint256(keccak256('eip1967.proxy.beacon')) - 1)) and is validated in the constructor. */ bytes32 internal constant _BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50; /** * @dev Emitted when the beacon is upgraded. */ event BeaconUpgraded(address indexed beacon); /** * @dev Returns the current beacon. */ function _getBeacon() internal view returns (address) { return StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value; } /** * @dev Stores a new beacon in the EIP1967 beacon slot. */ function _setBeacon(address newBeacon) private { require(AddressUpgradeable.isContract(newBeacon), "ERC1967: new beacon is not a contract"); require( AddressUpgradeable.isContract(IBeaconUpgradeable(newBeacon).implementation()), "ERC1967: beacon implementation is not a contract" ); StorageSlotUpgradeable.getAddressSlot(_BEACON_SLOT).value = newBeacon; } /** * @dev Perform beacon upgrade with additional setup call. Note: This upgrades the address of the beacon, it does * not upgrade the implementation contained in the beacon (see {UpgradeableBeacon-_setImplementation} for that). * * Emits a {BeaconUpgraded} event. */ function _upgradeBeaconToAndCall( address newBeacon, bytes memory data, bool forceCall ) internal { _setBeacon(newBeacon); emit BeaconUpgraded(newBeacon); if (data.length > 0 || forceCall) { _functionDelegateCall(IBeaconUpgradeable(newBeacon).implementation(), data); } } /** * @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) private returns (bytes memory) { require(AddressUpgradeable.isContract(target), "Address: delegate call to non-contract"); // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returndata) = target.delegatecall(data); return AddressUpgradeable.verifyCallResult(success, returndata, "Address: low-level delegate call failed"); } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (proxy/beacon/IBeacon.sol) pragma solidity ^0.8.0; /** * @dev This is the interface that {BeaconProxy} expects of its beacon. */ interface IBeaconUpgradeable { /** * @dev Must return an address that can be used as a delegate call target. * * {BeaconProxy} will check that this address is a contract. */ function implementation() external view returns (address); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (proxy/utils/Initializable.sol) pragma solidity ^0.8.0; 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 a proxied contract can't have 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. * * 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 initialize the implementation contract, you can either invoke the * initializer manually, or you can include a constructor to automatically mark it as initialized when it is deployed: * * [.hljs-theme-light.nopadding] * ``` * /// @custom:oz-upgrades-unsafe-allow constructor * constructor() initializer {} * ``` * ==== */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. */ bool private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Modifier to protect an initializer function from being invoked twice. */ modifier initializer() { // If the contract is initializing we ignore whether _initialized is set in order to support multiple // inheritance patterns, but we only do this in the context of a constructor, because in other contexts the // contract may have been reentered. require(_initializing ? _isConstructor() : !_initialized, "Initializable: contract is already initialized"); bool isTopLevelCall = !_initializing; if (isTopLevelCall) { _initializing = true; _initialized = true; } _; if (isTopLevelCall) { _initializing = false; } } /** * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the * {initializer} modifier, directly or indirectly. */ modifier onlyInitializing() { require(_initializing, "Initializable: contract is not initializing"); _; } function _isConstructor() private view returns (bool) { return !AddressUpgradeable.isContract(address(this)); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (proxy/utils/UUPSUpgradeable.sol) pragma solidity ^0.8.0; import "../ERC1967/ERC1967UpgradeUpgradeable.sol"; import "./Initializable.sol"; /** * @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an * {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy. * * A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is * reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing * `UUPSUpgradeable` with a custom implementation of upgrades. * * The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism. * * _Available since v4.1._ */ abstract contract UUPSUpgradeable is Initializable, ERC1967UpgradeUpgradeable { function __UUPSUpgradeable_init() internal onlyInitializing { __ERC1967Upgrade_init_unchained(); __UUPSUpgradeable_init_unchained(); } function __UUPSUpgradeable_init_unchained() internal onlyInitializing { } /// @custom:oz-upgrades-unsafe-allow state-variable-immutable state-variable-assignment address private immutable __self = address(this); /** * @dev Check that the execution is being performed through a delegatecall call and that the execution context is * a proxy contract with an implementation (as defined in ERC1967) pointing to self. This should only be the case * for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a * function through ERC1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to * fail. */ modifier onlyProxy() { require(address(this) != __self, "Function must be called through delegatecall"); require(_getImplementation() == __self, "Function must be called through active proxy"); _; } /** * @dev Upgrade the implementation of the proxy to `newImplementation`. * * Calls {_authorizeUpgrade}. * * Emits an {Upgraded} event. */ function upgradeTo(address newImplementation) external virtual onlyProxy { _authorizeUpgrade(newImplementation); _upgradeToAndCallSecure(newImplementation, new bytes(0), false); } /** * @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call * encoded in `data`. * * Calls {_authorizeUpgrade}. * * Emits an {Upgraded} event. */ function upgradeToAndCall(address newImplementation, bytes memory data) external payable virtual onlyProxy { _authorizeUpgrade(newImplementation); _upgradeToAndCallSecure(newImplementation, data, true); } /** * @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by * {upgradeTo} and {upgradeToAndCall}. * * Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}. * * ```solidity * function _authorizeUpgrade(address) internal override onlyOwner {} * ``` */ function _authorizeUpgrade(address newImplementation) internal virtual; uint256[50] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/Pausable.sol) pragma solidity ^0.8.0; import "../utils/ContextUpgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract PausableUpgradeable is Initializable, ContextUpgradeable { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ function __Pausable_init() internal onlyInitializing { __Context_init_unchained(); __Pausable_init_unchained(); } function __Pausable_init_unchained() internal onlyInitializing { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } uint256[49] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Address.sol) pragma solidity ^0.8.0; /** * @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 * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 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 functionCall(target, data, "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"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(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) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason 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 { // 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 assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// 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 { __Context_init_unchained(); } 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; } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/StorageSlot.sol) pragma solidity ^0.8.0; /** * @dev Library for reading and writing primitive types to specific storage slots. * * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. * This library helps with reading and writing to such slots without the need for inline assembly. * * The functions in this library return Slot structs that contain a `value` member that can be used to read or write. * * Example usage to set ERC1967 implementation slot: * ``` * contract ERC1967 { * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; * * function _getImplementation() internal view returns (address) { * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; * } * * function _setImplementation(address newImplementation) internal { * require(Address.isContract(newImplementation), "ERC1967: new implementation is not a contract"); * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; * } * } * ``` * * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._ */ library StorageSlotUpgradeable { struct AddressSlot { address value; } struct BooleanSlot { bool value; } struct Bytes32Slot { bytes32 value; } struct Uint256Slot { uint256 value; } /** * @dev Returns an `AddressSlot` with member `value` located at `slot`. */ function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) { assembly { r.slot := slot } } /** * @dev Returns an `BooleanSlot` with member `value` located at `slot`. */ function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) { assembly { r.slot := slot } } /** * @dev Returns an `Bytes32Slot` with member `value` located at `slot`. */ function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) { assembly { r.slot := slot } } /** * @dev Returns an `Uint256Slot` with member `value` located at `slot`. */ function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) { assembly { r.slot := slot } } }
// SPDX-License-Identifier: BUSL-1.1 pragma solidity 0.8.12; interface IBundleRegistry { // Need to update contract! // Data Source Adapter // source: Source name, example: TheGraph // host: Host url or ip, example: https://api.thegraph.com/subgraphs/name/uniswap/uniswap-v3 // output: The output type of the adapter, example: OHLC, OHLCV, SingleValue, etc. // bundle: (cid example: QmVj...DAwMA) // active: determines if the adapter is active or not, allows for inactive sources to be deprecated, vaults can pause based on this struct DataSourceAdapter { string bundle; string source; string host; string output; string info; bool active; address author; } event BundleRegistered( bytes32 hash, string bundle, string host, string source, string output, string infoHash, bool active, address creator ); event BundleStateChange(bytes32 hash, bool toggle); /// @dev Registers an execution bundle, printing an NFT and mapping to execution bundle and host. /// @param _bundle the bundle of the transformation module. /// @param _source The host of the transformation module source (e.g. "Uniswap") /// @param _host The host of the transformation module source (e.g. "Uniswap") /// @param _output The output type of the adapter, example: OHLC, OHLCV, SingleValue, etc. /// @param _active determines if the adapter is active or not, allows for inactive sources to be deprecated, vaults can pause based on this function register( string memory _bundle, string memory _source, string memory _host, string memory _output, string memory _infoHash, bool _active ) external; /// @dev Pauses the registeration of bundles function pause() external; function setAdapterState(bytes32 _adapter, bool _remainActive) external; }
{ "evmVersion": "london", "libraries": {}, "metadata": { "bytecodeHash": "ipfs", "useLiteralContent": true }, "optimizer": { "enabled": true, "runs": 10 }, "remappings": [], "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"previousAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"AdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"beacon","type":"address"}],"name":"BeaconUpgraded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":false,"internalType":"string","name":"bundle","type":"string"},{"indexed":false,"internalType":"string","name":"host","type":"string"},{"indexed":false,"internalType":"string","name":"source","type":"string"},{"indexed":false,"internalType":"string","name":"output","type":"string"},{"indexed":false,"internalType":"string","name":"infoHash","type":"string"},{"indexed":false,"internalType":"bool","name":"active","type":"bool"},{"indexed":false,"internalType":"address","name":"creator","type":"address"}],"name":"BundleRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"hash","type":"bytes32"},{"indexed":false,"internalType":"bool","name":"toggle","type":"bool"}],"name":"BundleStateChange","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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"bundles","outputs":[{"internalType":"string","name":"bundle","type":"string"},{"internalType":"string","name":"source","type":"string"},{"internalType":"string","name":"host","type":"string"},{"internalType":"string","name":"output","type":"string"},{"internalType":"string","name":"info","type":"string"},{"internalType":"bool","name":"active","type":"bool"},{"internalType":"address","name":"author","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"_bundle","type":"string"},{"internalType":"string","name":"_source","type":"string"},{"internalType":"string","name":"_host","type":"string"},{"internalType":"string","name":"_output","type":"string"},{"internalType":"string","name":"_infoHash","type":"string"},{"internalType":"bool","name":"_active","type":"bool"}],"name":"register","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_adapter","type":"bytes32"},{"internalType":"bool","name":"_remainActive","type":"bool"}],"name":"setAdapterState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"}],"name":"upgradeTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"stateMutability":"payable","type":"function"}]
Contract Creation Code
60a0604052306080523480156200001557600080fd5b50600054610100900460ff16620000335760005460ff16156200003d565b6200003d620000e2565b620000a55760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840160405180910390fd5b600054610100900460ff16158015620000c8576000805461ffff19166101011790555b8015620000db576000805461ff00191690555b5062000106565b6000620000fa306200010060201b62000b531760201c565b15905090565b3b151590565b608051611af062000137600039600081816101ed01528181610236015281816102bf01526102ff0152611af06000f3fe60806040526004361061008c5760003560e01c80633659cfe6146100915780634f1ef286146100b35780635c975abb146100c6578063715018a6146100ee5780638129fc1c146101035780638456cb59146101185780638da5cb5b1461012d57806393862c3b1461014f578063bb33fc5a14610182578063e46ce338146101a2578063f2fde38b146101c2575b600080fd5b34801561009d57600080fd5b506100b16100ac36600461147b565b6101e2565b005b6100b16100c1366004611521565b6102b4565b3480156100d257600080fd5b5060c95460ff1660405190151581526020015b60405180910390f35b3480156100fa57600080fd5b506100b161036e565b34801561010f57600080fd5b506100b16103a9565b34801561012457600080fd5b506100b1610479565b34801561013957600080fd5b506101426104b0565b6040516100e59190611582565b34801561015b57600080fd5b5061016f61016a366004611596565b6104bf565b6040516100e5979695949392919061160b565b34801561018e57600080fd5b506100b161019d3660046116c1565b6107af565b3480156101ae57600080fd5b506100b16101bd3660046117a1565b610a2b565b3480156101ce57600080fd5b506100b16101dd36600461147b565b610ab6565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614156102345760405162461bcd60e51b815260040161022b906117cd565b60405180910390fd5b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316610266610b59565b6001600160a01b03161461028c5760405162461bcd60e51b815260040161022b90611807565b61029581610b75565b604080516000808252602082019092526102b191839190610ba4565b50565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614156102fd5760405162461bcd60e51b815260040161022b906117cd565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031661032f610b59565b6001600160a01b0316146103555760405162461bcd60e51b815260040161022b90611807565b61035e82610b75565b61036a82826001610ba4565b5050565b336103776104b0565b6001600160a01b03161461039d5760405162461bcd60e51b815260040161022b90611841565b6103a76000610ceb565b565b600054610100900460ff166103c45760005460ff16156103c8565b303b155b61042b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161022b565b600054610100900460ff1615801561044d576000805461ffff19166101011790555b610455610d3d565b61045d610d74565b610465610dab565b80156102b1576000805461ff001916905550565b336104826104b0565b6001600160a01b0316146104a85760405162461bcd60e51b815260040161022b90611841565b6103a7610de2565b6033546001600160a01b031690565b60fb602052600090815260409020805481906104da90611876565b80601f016020809104026020016040519081016040528092919081815260200182805461050690611876565b80156105535780601f1061052857610100808354040283529160200191610553565b820191906000526020600020905b81548152906001019060200180831161053657829003601f168201915b50505050509080600101805461056890611876565b80601f016020809104026020016040519081016040528092919081815260200182805461059490611876565b80156105e15780601f106105b6576101008083540402835291602001916105e1565b820191906000526020600020905b8154815290600101906020018083116105c457829003601f168201915b5050505050908060020180546105f690611876565b80601f016020809104026020016040519081016040528092919081815260200182805461062290611876565b801561066f5780601f106106445761010080835404028352916020019161066f565b820191906000526020600020905b81548152906001019060200180831161065257829003601f168201915b50505050509080600301805461068490611876565b80601f01602080910402602001604051908101604052809291908181526020018280546106b090611876565b80156106fd5780601f106106d2576101008083540402835291602001916106fd565b820191906000526020600020905b8154815290600101906020018083116106e057829003601f168201915b50505050509080600401805461071290611876565b80601f016020809104026020016040519081016040528092919081815260200182805461073e90611876565b801561078b5780601f106107605761010080835404028352916020019161078b565b820191906000526020600020905b81548152906001019060200180831161076e57829003601f168201915b5050506005909301549192505060ff8116906001600160a01b036101009091041687565b60c95460ff16156107d25760405162461bcd60e51b815260040161022b906118b1565b6107db86610e51565b6108275760405162461bcd60e51b815260206004820152601f60248201527f42756e646c65206d75737420626520616e204950465320434944206861736800604482015260640161022b565b60008686868660405160200161084094939291906118db565b60408051601f198184030181529181528151602092830120600081815260fb90935291206005015490915061010090046001600160a01b0316156108c25760405162461bcd60e51b8152602060048201526019602482015278109d5b991b1948185b1c9958591e481c9959da5cdd195c9959603a1b604482015260640161022b565b6040518060e0016040528088815260200187815260200186815260200185815260200184815260200183151581526020016108fa3390565b6001600160a01b03169052600082815260fb6020908152604090912082518051919261092b928492909101906113c6565b50602082810151805161094492600185019201906113c6565b50604082015180516109609160028401916020909101906113c6565b506060820151805161097c9160038401916020909101906113c6565b50608082015180516109989160048401916020909101906113c6565b5060a08201516005909101805460c0909301516001600160a01b031661010002610100600160a81b0319921515929092166001600160a81b0319909316929092171790556040517f5fefd2860204ab13d9368d6ab8443f8309bb482e9a1e8e0bc446b23bec45526a90610a1a9083908a9089908b908a908a908a903390611933565b60405180910390a150505050505050565b33610a346104b0565b6001600160a01b031614610a5a5760405162461bcd60e51b815260040161022b90611841565b600082815260fb6020908152604091829020600501805460ff19168415159081179091558251858152918201527fc80d6f7f8fc35e11b52ccc6cf7c43f25a29550fa950ab77a857c56557d065faf910160405180910390a15050565b33610abf6104b0565b6001600160a01b031614610ae55760405162461bcd60e51b815260040161022b90611841565b6001600160a01b038116610b4a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161022b565b6102b181610ceb565b3b151590565b600080516020611a74833981519152546001600160a01b031690565b33610b7e6104b0565b6001600160a01b0316146102b15760405162461bcd60e51b815260040161022b90611841565b6000610bae610b59565b9050610bb98461113e565b600083511180610bc65750815b15610bd757610bd584846111d1565b505b7f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143805460ff16610ce457805460ff19166001178155604051610c52908690610c23908590602401611582565b60408051601f198184030181529190526020810180516001600160e01b0316631b2ce7f360e11b1790526111d1565b50805460ff19168155610c63610b59565b6001600160a01b0316826001600160a01b031614610cdb5760405162461bcd60e51b815260206004820152602f60248201527f45524331393637557067726164653a207570677261646520627265616b73206660448201526e75727468657220757067726164657360881b606482015260840161022b565b610ce4856112bc565b5050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610d645760405162461bcd60e51b815260040161022b906119c3565b610d6c6112fc565b6103a76112fc565b600054610100900460ff16610d9b5760405162461bcd60e51b815260040161022b906119c3565b610da36112fc565b6103a7611323565b600054610100900460ff16610dd25760405162461bcd60e51b815260040161022b906119c3565b610dda6112fc565b6103a7611353565b60c95460ff1615610e055760405162461bcd60e51b815260040161022b906118b1565b60c9805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610e3a3390565b604051610e479190611582565b60405180910390a1565b80516000908290602e14610e905760405162461bcd60e51b8152602060048201526006602482015265098cadccee8d60d31b604482015260640161022b565b604080516001808252818301909252600091602082018180368337505060408051600180825281830190925292935060009291506020820181803683375050604080516001808252818301909252929350600092915060208201818036833701905050905083600081518110610f0857610f08611a0e565b602001015160f81c60f81b83600081518110610f2657610f26611a0e565b60200101906001600160f81b031916908160001a90535083600181518110610f5057610f50611a0e565b602001015160f81c60f81b82600081518110610f6e57610f6e611a0e565b60200101906001600160f81b031916908160001a90535083602d81518110610f9857610f98611a0e565b602001015160f81c60f81b81600081518110610fb657610fb6611a0e565b60200101906001600160f81b031916908160001a9053506040805180820190915260018152605160f81b6020918201528351908401207ffbf3cc6079e09a6a2a778706898aef91b633ff613801d212e0afe7f411ddb1d214801561105757506040805180820190915260018152606d60f81b6020918201528251908301207fdaba8c984363447d18bf8210079973ac8fc1ce76864315b5baacf246bf6e72f6145b801561113457506040805180820190915260018152604f60f81b6020918201528151908201207fc669aa98d5975cc43653c879a18d9bc4aa8bf51e69f61aeb1d7769216f98009a148015906110ea57506040805180820190915260018152604960f81b6020918201528151908201207f8d61ecf6e15472e15b1a0f63cd77f62aa57e6edcd3871d7a841f1056fb42b21614155b801561113457506040805180820190915260018152601b60fa1b6020918201528151908201207f6a0d259bd4fb907339fd7c65a133083c1e9554f2ca6325b806612c8df6d7df2214155b9695505050505050565b803b6111a25760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b606482015260840161022b565b600080516020611a7483398151915280546001600160a01b0319166001600160a01b0392909216919091179055565b6060823b6112305760405162461bcd60e51b815260206004820152602660248201527f416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f6044820152651b9d1c9858dd60d21b606482015260840161022b565b600080846001600160a01b03168460405161124b9190611a24565b600060405180830381855af49150503d8060008114611286576040519150601f19603f3d011682016040523d82523d6000602084013e61128b565b606091505b50915091506112b38282604051806060016040528060278152602001611a9460279139611386565b95945050505050565b6112c58161113e565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b600054610100900460ff166103a75760405162461bcd60e51b815260040161022b906119c3565b600054610100900460ff1661134a5760405162461bcd60e51b815260040161022b906119c3565b6103a733610ceb565b600054610100900460ff1661137a5760405162461bcd60e51b815260040161022b906119c3565b60c9805460ff19169055565b606083156113955750816113bf565b8251156113a55782518084602001fd5b8160405162461bcd60e51b815260040161022b9190611a40565b9392505050565b8280546113d290611876565b90600052602060002090601f0160209004810192826113f4576000855561143a565b82601f1061140d57805160ff191683800117855561143a565b8280016001018555821561143a579182015b8281111561143a57825182559160200191906001019061141f565b5061144692915061144a565b5090565b5b80821115611446576000815560010161144b565b80356001600160a01b038116811461147657600080fd5b919050565b60006020828403121561148d57600080fd5b6113bf8261145f565b634e487b7160e01b600052604160045260246000fd5b60006001600160401b03808411156114c6576114c6611496565b604051601f8501601f19908116603f011681019082821181831017156114ee576114ee611496565b8160405280935085815286868601111561150757600080fd5b858560208301376000602087830101525050509392505050565b6000806040838503121561153457600080fd5b61153d8361145f565b915060208301356001600160401b0381111561155857600080fd5b8301601f8101851361156957600080fd5b611578858235602084016114ac565b9150509250929050565b6001600160a01b0391909116815260200190565b6000602082840312156115a857600080fd5b5035919050565b60005b838110156115ca5781810151838201526020016115b2565b838111156115d9576000848401525b50505050565b600081518084526115f78160208601602086016115af565b601f01601f19169290920160200192915050565b60e08152600061161e60e083018a6115df565b8281036020840152611630818a6115df565b9050828103604084015261164481896115df565b9050828103606084015261165881886115df565b9050828103608084015261166c81876115df565b94151560a084015250506001600160a01b039190911660c09091015295945050505050565b600082601f8301126116a257600080fd5b6113bf838335602085016114ac565b8035801515811461147657600080fd5b60008060008060008060c087890312156116da57600080fd5b86356001600160401b03808211156116f157600080fd5b6116fd8a838b01611691565b9750602089013591508082111561171357600080fd5b61171f8a838b01611691565b9650604089013591508082111561173557600080fd5b6117418a838b01611691565b9550606089013591508082111561175757600080fd5b6117638a838b01611691565b9450608089013591508082111561177957600080fd5b5061178689828a01611691565b92505061179560a088016116b1565b90509295509295509295565b600080604083850312156117b457600080fd5b823591506117c4602084016116b1565b90509250929050565b6020808252602c90820152600080516020611a5483398151915260408201526b19195b1959d85d1958d85b1b60a21b606082015260800190565b6020808252602c90820152600080516020611a5483398151915260408201526b6163746976652070726f787960a01b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600181811c9082168061188a57607f821691505b602082108114156118ab57634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b6080815260006118ee60808301876115df565b828103602084015261190081876115df565b9050828103604084015261191481866115df565b9050828103606084015261192881856115df565b979650505050505050565b60006101008a835280602084015261194d8184018b6115df565b90508281036040840152611961818a6115df565b9050828103606084015261197581896115df565b9050828103608084015261198981886115df565b905082810360a084015261199d81876115df565b94151560c084015250506001600160a01b039190911660e0909101529695505050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b60008251611a368184602087016115af565b9190910192915050565b6020815260006113bf60208301846115df56fe46756e6374696f6e206d7573742062652063616c6c6564207468726f75676820360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220affdc1cb1be86959328c500ba2818bc00b3504b1e340ccde823475ec49c9872464736f6c634300080c0033
Deployed Bytecode
0x60806040526004361061008c5760003560e01c80633659cfe6146100915780634f1ef286146100b35780635c975abb146100c6578063715018a6146100ee5780638129fc1c146101035780638456cb59146101185780638da5cb5b1461012d57806393862c3b1461014f578063bb33fc5a14610182578063e46ce338146101a2578063f2fde38b146101c2575b600080fd5b34801561009d57600080fd5b506100b16100ac36600461147b565b6101e2565b005b6100b16100c1366004611521565b6102b4565b3480156100d257600080fd5b5060c95460ff1660405190151581526020015b60405180910390f35b3480156100fa57600080fd5b506100b161036e565b34801561010f57600080fd5b506100b16103a9565b34801561012457600080fd5b506100b1610479565b34801561013957600080fd5b506101426104b0565b6040516100e59190611582565b34801561015b57600080fd5b5061016f61016a366004611596565b6104bf565b6040516100e5979695949392919061160b565b34801561018e57600080fd5b506100b161019d3660046116c1565b6107af565b3480156101ae57600080fd5b506100b16101bd3660046117a1565b610a2b565b3480156101ce57600080fd5b506100b16101dd36600461147b565b610ab6565b306001600160a01b037f0000000000000000000000008bd01b4ece9a81fb93e899d435ce700a1c4fa08a1614156102345760405162461bcd60e51b815260040161022b906117cd565b60405180910390fd5b7f0000000000000000000000008bd01b4ece9a81fb93e899d435ce700a1c4fa08a6001600160a01b0316610266610b59565b6001600160a01b03161461028c5760405162461bcd60e51b815260040161022b90611807565b61029581610b75565b604080516000808252602082019092526102b191839190610ba4565b50565b306001600160a01b037f0000000000000000000000008bd01b4ece9a81fb93e899d435ce700a1c4fa08a1614156102fd5760405162461bcd60e51b815260040161022b906117cd565b7f0000000000000000000000008bd01b4ece9a81fb93e899d435ce700a1c4fa08a6001600160a01b031661032f610b59565b6001600160a01b0316146103555760405162461bcd60e51b815260040161022b90611807565b61035e82610b75565b61036a82826001610ba4565b5050565b336103776104b0565b6001600160a01b03161461039d5760405162461bcd60e51b815260040161022b90611841565b6103a76000610ceb565b565b600054610100900460ff166103c45760005460ff16156103c8565b303b155b61042b5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161022b565b600054610100900460ff1615801561044d576000805461ffff19166101011790555b610455610d3d565b61045d610d74565b610465610dab565b80156102b1576000805461ff001916905550565b336104826104b0565b6001600160a01b0316146104a85760405162461bcd60e51b815260040161022b90611841565b6103a7610de2565b6033546001600160a01b031690565b60fb602052600090815260409020805481906104da90611876565b80601f016020809104026020016040519081016040528092919081815260200182805461050690611876565b80156105535780601f1061052857610100808354040283529160200191610553565b820191906000526020600020905b81548152906001019060200180831161053657829003601f168201915b50505050509080600101805461056890611876565b80601f016020809104026020016040519081016040528092919081815260200182805461059490611876565b80156105e15780601f106105b6576101008083540402835291602001916105e1565b820191906000526020600020905b8154815290600101906020018083116105c457829003601f168201915b5050505050908060020180546105f690611876565b80601f016020809104026020016040519081016040528092919081815260200182805461062290611876565b801561066f5780601f106106445761010080835404028352916020019161066f565b820191906000526020600020905b81548152906001019060200180831161065257829003601f168201915b50505050509080600301805461068490611876565b80601f01602080910402602001604051908101604052809291908181526020018280546106b090611876565b80156106fd5780601f106106d2576101008083540402835291602001916106fd565b820191906000526020600020905b8154815290600101906020018083116106e057829003601f168201915b50505050509080600401805461071290611876565b80601f016020809104026020016040519081016040528092919081815260200182805461073e90611876565b801561078b5780601f106107605761010080835404028352916020019161078b565b820191906000526020600020905b81548152906001019060200180831161076e57829003601f168201915b5050506005909301549192505060ff8116906001600160a01b036101009091041687565b60c95460ff16156107d25760405162461bcd60e51b815260040161022b906118b1565b6107db86610e51565b6108275760405162461bcd60e51b815260206004820152601f60248201527f42756e646c65206d75737420626520616e204950465320434944206861736800604482015260640161022b565b60008686868660405160200161084094939291906118db565b60408051601f198184030181529181528151602092830120600081815260fb90935291206005015490915061010090046001600160a01b0316156108c25760405162461bcd60e51b8152602060048201526019602482015278109d5b991b1948185b1c9958591e481c9959da5cdd195c9959603a1b604482015260640161022b565b6040518060e0016040528088815260200187815260200186815260200185815260200184815260200183151581526020016108fa3390565b6001600160a01b03169052600082815260fb6020908152604090912082518051919261092b928492909101906113c6565b50602082810151805161094492600185019201906113c6565b50604082015180516109609160028401916020909101906113c6565b506060820151805161097c9160038401916020909101906113c6565b50608082015180516109989160048401916020909101906113c6565b5060a08201516005909101805460c0909301516001600160a01b031661010002610100600160a81b0319921515929092166001600160a81b0319909316929092171790556040517f5fefd2860204ab13d9368d6ab8443f8309bb482e9a1e8e0bc446b23bec45526a90610a1a9083908a9089908b908a908a908a903390611933565b60405180910390a150505050505050565b33610a346104b0565b6001600160a01b031614610a5a5760405162461bcd60e51b815260040161022b90611841565b600082815260fb6020908152604091829020600501805460ff19168415159081179091558251858152918201527fc80d6f7f8fc35e11b52ccc6cf7c43f25a29550fa950ab77a857c56557d065faf910160405180910390a15050565b33610abf6104b0565b6001600160a01b031614610ae55760405162461bcd60e51b815260040161022b90611841565b6001600160a01b038116610b4a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161022b565b6102b181610ceb565b3b151590565b600080516020611a74833981519152546001600160a01b031690565b33610b7e6104b0565b6001600160a01b0316146102b15760405162461bcd60e51b815260040161022b90611841565b6000610bae610b59565b9050610bb98461113e565b600083511180610bc65750815b15610bd757610bd584846111d1565b505b7f4910fdfa16fed3260ed0e7147f7cc6da11a60208b5b9406d12a635614ffd9143805460ff16610ce457805460ff19166001178155604051610c52908690610c23908590602401611582565b60408051601f198184030181529190526020810180516001600160e01b0316631b2ce7f360e11b1790526111d1565b50805460ff19168155610c63610b59565b6001600160a01b0316826001600160a01b031614610cdb5760405162461bcd60e51b815260206004820152602f60248201527f45524331393637557067726164653a207570677261646520627265616b73206660448201526e75727468657220757067726164657360881b606482015260840161022b565b610ce4856112bc565b5050505050565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff16610d645760405162461bcd60e51b815260040161022b906119c3565b610d6c6112fc565b6103a76112fc565b600054610100900460ff16610d9b5760405162461bcd60e51b815260040161022b906119c3565b610da36112fc565b6103a7611323565b600054610100900460ff16610dd25760405162461bcd60e51b815260040161022b906119c3565b610dda6112fc565b6103a7611353565b60c95460ff1615610e055760405162461bcd60e51b815260040161022b906118b1565b60c9805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610e3a3390565b604051610e479190611582565b60405180910390a1565b80516000908290602e14610e905760405162461bcd60e51b8152602060048201526006602482015265098cadccee8d60d31b604482015260640161022b565b604080516001808252818301909252600091602082018180368337505060408051600180825281830190925292935060009291506020820181803683375050604080516001808252818301909252929350600092915060208201818036833701905050905083600081518110610f0857610f08611a0e565b602001015160f81c60f81b83600081518110610f2657610f26611a0e565b60200101906001600160f81b031916908160001a90535083600181518110610f5057610f50611a0e565b602001015160f81c60f81b82600081518110610f6e57610f6e611a0e565b60200101906001600160f81b031916908160001a90535083602d81518110610f9857610f98611a0e565b602001015160f81c60f81b81600081518110610fb657610fb6611a0e565b60200101906001600160f81b031916908160001a9053506040805180820190915260018152605160f81b6020918201528351908401207ffbf3cc6079e09a6a2a778706898aef91b633ff613801d212e0afe7f411ddb1d214801561105757506040805180820190915260018152606d60f81b6020918201528251908301207fdaba8c984363447d18bf8210079973ac8fc1ce76864315b5baacf246bf6e72f6145b801561113457506040805180820190915260018152604f60f81b6020918201528151908201207fc669aa98d5975cc43653c879a18d9bc4aa8bf51e69f61aeb1d7769216f98009a148015906110ea57506040805180820190915260018152604960f81b6020918201528151908201207f8d61ecf6e15472e15b1a0f63cd77f62aa57e6edcd3871d7a841f1056fb42b21614155b801561113457506040805180820190915260018152601b60fa1b6020918201528151908201207f6a0d259bd4fb907339fd7c65a133083c1e9554f2ca6325b806612c8df6d7df2214155b9695505050505050565b803b6111a25760405162461bcd60e51b815260206004820152602d60248201527f455243313936373a206e657720696d706c656d656e746174696f6e206973206e60448201526c1bdd08184818dbdb9d1c9858dd609a1b606482015260840161022b565b600080516020611a7483398151915280546001600160a01b0319166001600160a01b0392909216919091179055565b6060823b6112305760405162461bcd60e51b815260206004820152602660248201527f416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f6044820152651b9d1c9858dd60d21b606482015260840161022b565b600080846001600160a01b03168460405161124b9190611a24565b600060405180830381855af49150503d8060008114611286576040519150601f19603f3d011682016040523d82523d6000602084013e61128b565b606091505b50915091506112b38282604051806060016040528060278152602001611a9460279139611386565b95945050505050565b6112c58161113e565b6040516001600160a01b038216907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a250565b600054610100900460ff166103a75760405162461bcd60e51b815260040161022b906119c3565b600054610100900460ff1661134a5760405162461bcd60e51b815260040161022b906119c3565b6103a733610ceb565b600054610100900460ff1661137a5760405162461bcd60e51b815260040161022b906119c3565b60c9805460ff19169055565b606083156113955750816113bf565b8251156113a55782518084602001fd5b8160405162461bcd60e51b815260040161022b9190611a40565b9392505050565b8280546113d290611876565b90600052602060002090601f0160209004810192826113f4576000855561143a565b82601f1061140d57805160ff191683800117855561143a565b8280016001018555821561143a579182015b8281111561143a57825182559160200191906001019061141f565b5061144692915061144a565b5090565b5b80821115611446576000815560010161144b565b80356001600160a01b038116811461147657600080fd5b919050565b60006020828403121561148d57600080fd5b6113bf8261145f565b634e487b7160e01b600052604160045260246000fd5b60006001600160401b03808411156114c6576114c6611496565b604051601f8501601f19908116603f011681019082821181831017156114ee576114ee611496565b8160405280935085815286868601111561150757600080fd5b858560208301376000602087830101525050509392505050565b6000806040838503121561153457600080fd5b61153d8361145f565b915060208301356001600160401b0381111561155857600080fd5b8301601f8101851361156957600080fd5b611578858235602084016114ac565b9150509250929050565b6001600160a01b0391909116815260200190565b6000602082840312156115a857600080fd5b5035919050565b60005b838110156115ca5781810151838201526020016115b2565b838111156115d9576000848401525b50505050565b600081518084526115f78160208601602086016115af565b601f01601f19169290920160200192915050565b60e08152600061161e60e083018a6115df565b8281036020840152611630818a6115df565b9050828103604084015261164481896115df565b9050828103606084015261165881886115df565b9050828103608084015261166c81876115df565b94151560a084015250506001600160a01b039190911660c09091015295945050505050565b600082601f8301126116a257600080fd5b6113bf838335602085016114ac565b8035801515811461147657600080fd5b60008060008060008060c087890312156116da57600080fd5b86356001600160401b03808211156116f157600080fd5b6116fd8a838b01611691565b9750602089013591508082111561171357600080fd5b61171f8a838b01611691565b9650604089013591508082111561173557600080fd5b6117418a838b01611691565b9550606089013591508082111561175757600080fd5b6117638a838b01611691565b9450608089013591508082111561177957600080fd5b5061178689828a01611691565b92505061179560a088016116b1565b90509295509295509295565b600080604083850312156117b457600080fd5b823591506117c4602084016116b1565b90509250929050565b6020808252602c90820152600080516020611a5483398151915260408201526b19195b1959d85d1958d85b1b60a21b606082015260800190565b6020808252602c90820152600080516020611a5483398151915260408201526b6163746976652070726f787960a01b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600181811c9082168061188a57607f821691505b602082108114156118ab57634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526010908201526f14185d5cd8589b194e881c185d5cd95960821b604082015260600190565b6080815260006118ee60808301876115df565b828103602084015261190081876115df565b9050828103604084015261191481866115df565b9050828103606084015261192881856115df565b979650505050505050565b60006101008a835280602084015261194d8184018b6115df565b90508281036040840152611961818a6115df565b9050828103606084015261197581896115df565b9050828103608084015261198981886115df565b905082810360a084015261199d81876115df565b94151560c084015250506001600160a01b039190911660e0909101529695505050505050565b6020808252602b908201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960408201526a6e697469616c697a696e6760a81b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b60008251611a368184602087016115af565b9190910192915050565b6020815260006113bf60208301846115df56fe46756e6374696f6e206d7573742062652063616c6c6564207468726f75676820360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a2646970667358221220affdc1cb1be86959328c500ba2818bc00b3504b1e340ccde823475ec49c9872464736f6c634300080c0033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
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.