Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Latest 1 internal transaction
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
16990588 | 632 days ago | Contract Creation | 0 ETH |
Loading...
Loading
Contract Name:
Allowlist
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 10000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; // Want to launch your own collection? // Check out https://buildship.xyz // // ,:loxO0KXXc // ,cdOKKKOxol:lKWl // ;oOXKko:, ;KNc // 'ox0X0d: cNK, // ',' ;xXX0x: dWk // ,cdO0KKKKKXKo, ,0Nl // ;oOXKko:,;kWMNl dWO' // ,o0XKd:' oNMMK: cXX: // 'ckNNk: ;KMN0c cXXl // 'OWMMWKOdl;' cl; oXXc // ;cclldxOKXKkl, ;kNO; // ;cdk0kl' ;clxXXo // ':oxo' c0WMMMMK; // :l: lNMWXxOWWo // '; :xdc' :XWd // , cXK; // ':, xXl // ;: ' o0c // ;c;,,,,' lx; // ''' cc // ,' import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/cryptography/MerkleProofUpgradeable.sol"; import "./base/SaleControlUpgradeable.sol"; import "./base/NFTExtensionUpgradeable.sol"; contract Allowlist is NFTExtensionUpgradeable, SaleControlUpgradeable { uint256 public price; bytes32 public allowlistRoot; string public title; mapping(address => uint256) public claimedByAddress; /// @custom:oz-upgrades-unsafe-allow constructor constructor() initializer {} function initialize( string memory _title, address _nft, bytes32 _allowlistRoot, uint256 _price ) public initializer { NFTExtensionUpgradeable.initialize(_nft); SaleControlUpgradeable.initialize(); title = _title; price = _price; allowlistRoot = _allowlistRoot; } function updatePrice(uint256 _price) public onlyOwner { price = _price; } function updateAllowlistRoot(bytes32 _allowlistRoot) public onlyOwner { allowlistRoot = _allowlistRoot; } function mint( uint256 amount, uint256 maxAllocatedAmount, bytes32[] memory proof ) external payable whenSaleStarted { require( isAllowlisted(allowlistRoot, msg.sender, maxAllocatedAmount, proof), "Not whitelisted" ); require( claimedByAddress[msg.sender] + amount <= maxAllocatedAmount, "Cannot claim more per address" ); require(msg.value >= amount * price, "Not enough ETH to mint"); claimedByAddress[msg.sender] += amount; nft.mintExternal{value: msg.value}(amount, msg.sender, bytes32(0)); } function computeLeaf( address receiver, uint256 maxAmount ) public pure returns (bytes32) { // leaf is [keccak256(address), maxAmount] // double hash to prevent length extension attack bytes memory leafData = abi.encode( keccak256(abi.encodePacked(receiver)), maxAmount ); return keccak256(bytes.concat(keccak256(leafData))); } function isAllowlisted( bytes32 root, address receiver, uint256 maxAmount, bytes32[] memory proof ) public pure returns (bool) { bytes32 leaf = computeLeaf(receiver, maxAmount); return MerkleProofUpgradeable.verify(proof, root, leaf); } }
// 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 { __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); } /** * @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 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 { __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()); } /** * @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.6.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Trees proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. * * WARNING: You should avoid using leaf values that are 64 bytes long prior to * hashing, or use a hash function other than keccak256 for hashing leaves. * This is because the concatenation of a sorted pair of internal nodes in * the merkle tree could be reinterpreted as a leaf value. */ library MerkleProofUpgradeable { /** * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree * defined by `root`. For this, a `proof` must be provided, containing * sibling hashes on the branch from the leaf to the root of the tree. Each * pair of leaves and each pair of pre-images are assumed to be sorted. */ function verify( bytes32[] memory proof, bytes32 root, bytes32 leaf ) internal pure returns (bool) { return processProof(proof, leaf) == root; } /** * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt * hash matches the root of the tree. When processing the proof, the pairs * of leafs & pre-images are assumed to be sorted. * * _Available since v4.4._ */ function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { bytes32 proofElement = proof[i]; if (computedHash <= proofElement) { // Hash(current computed hash + current element of the proof) computedHash = _efficientHash(computedHash, proofElement); } else { // Hash(current element of the proof + current computed hash) computedHash = _efficientHash(proofElement, computedHash); } } return computedHash; } function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) { assembly { mstore(0x00, a) mstore(0x20, b) value := keccak256(0x00, 0x40) } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol"; abstract contract SaleControlUpgradeable is OwnableUpgradeable { uint256 public constant __SALE_NEVER_STARTS = 2**256 - 1; uint256 public startTimestamp; function initialize() internal onlyInitializing { __Ownable_init(); startTimestamp = __SALE_NEVER_STARTS; } modifier whenSaleStarted() { require(saleStarted(), "Sale not started yet"); _; } function updateStartTimestamp(uint256 _startTimestamp) public onlyOwner { startTimestamp = _startTimestamp; } function startSale() public onlyOwner { startTimestamp = block.timestamp; } function stopSale() public onlyOwner { startTimestamp = __SALE_NEVER_STARTS; } function saleStarted() public view returns (bool) { return block.timestamp >= startTimestamp; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol"; import "../../../interfaces/INFTExtension.sol"; import "../../../interfaces/IERC721Community.sol"; contract NFTExtensionUpgradeable is INFTExtension, ERC165Upgradeable { IERC721Community public nft; function initialize(address _nft) internal onlyInitializing { __ERC165_init(); nft = IERC721Community(_nft); } function beforeMint() internal view { require( nft.isExtensionAdded(address(this)), "NFTExtension: this contract is not allowed to be used as an extension" ); } function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165Upgradeable) returns (bool) { return interfaceId == type(INFTExtension).interfaceId || super.supportsInterface(interfaceId); } }
// 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.6.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. Equivalent to `reinitializer(1)`. */ modifier initializer() { bool isTopLevelCall = _setInitializedVersion(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. * * `initializer` is equivalent to `reinitializer(1)`, so 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. * * 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. */ modifier reinitializer(uint8 version) { bool isTopLevelCall = _setInitializedVersion(version); if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _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. */ function _disableInitializers() internal virtual { _setInitializedVersion(type(uint8).max); } function _setInitializedVersion(uint8 version) private returns (bool) { // 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, and for the lowest level // of initializers, because in other contexts the contract may have been reentered. if (_initializing) { require( version == 1 && !AddressUpgradeable.isContract(address(this)), "Initializable: contract is already initialized" ); return false; } else { require(_initialized < version, "Initializable: contract is already initialized"); _initialized = version; return true; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.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 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/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165Upgradeable.sol"; import "../../proxy/utils/Initializable.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165Upgradeable is Initializable, IERC165Upgradeable { function __ERC165_init() internal onlyInitializing { } function __ERC165_init_unchained() internal onlyInitializing { } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165Upgradeable).interfaceId; } /** * @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 pragma solidity ^0.8.9; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; interface INFTExtension is IERC165 {} interface INFTURIExtension is INFTExtension { function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; /** @dev config includes values have setters and can be changed later */ struct MintConfig { uint256 publicPrice; uint256 maxTokensPerMint; uint256 maxTokensPerWallet; uint256 royaltyFee; address payoutReceiver; bool shouldLockPayoutReceiver; bool shouldStartSale; bool shouldUseJsonExtension; } interface IERC721Community { // ------ View functions ------ function saleStarted() external view returns (bool); function isExtensionAdded(address extension) external view returns (bool); /** Extra information stored for each tokenId. Optional, provided on mint */ function data(uint256 tokenId) external view returns (bytes32); // ------ Mint functions ------ /** Mint from NFTExtension contract. Optionally provide data parameter. */ function mintExternal( uint256 amount, address to, bytes32 data ) external payable; // ------ Admin functions ------ function addExtension(address extension) external; function revokeExtension(address extension) external; function withdraw() external; // ------ View functions ------ /** Recommended royalty for tokenId sale. */ function royaltyInfo(uint256 tokenId, uint256 salePrice) external view returns (address receiver, uint256 royaltyAmount); // ------ Admin functions ------ function setRoyaltyReceiver(address receiver) external; function setRoyaltyFee(uint256 fee) external; } interface IERC721CommunityImplementation { function initialize( string memory _name, string memory _symbol, uint256 _maxSupply, uint256 _nReserved, bool _startAtOne, string memory uri, MintConfig memory config ) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165Upgradeable { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); }
{ "optimizer": { "enabled": true, "runs": 10000 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"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":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"__SALE_NEVER_STARTS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"allowlistRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedByAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"maxAmount","type":"uint256"}],"name":"computeLeaf","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"string","name":"_title","type":"string"},{"internalType":"address","name":"_nft","type":"address"},{"internalType":"bytes32","name":"_allowlistRoot","type":"bytes32"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"maxAmount","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"isAllowlisted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"maxAllocatedAmount","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"nft","outputs":[{"internalType":"contract IERC721Community","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"saleStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"startSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stopSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"title","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_allowlistRoot","type":"bytes32"}],"name":"updateAllowlistRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"updatePrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_startTimestamp","type":"uint256"}],"name":"updateStartTimestamp","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b50600062000020600162000087565b9050801562000039576000805461ff0019166101001790555b801562000080576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50620001a8565b60008054610100900460ff161562000120578160ff166001148015620000c05750620000be306200019960201b62000d791760201c565b155b620001185760405162461bcd60e51b815260206004820152602e602482015260008051602062001a4983398151915260448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b506000919050565b60005460ff8084169116106200017f5760405162461bcd60e51b815260206004820152602e602482015260008051602062001a4983398151915260448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016200010f565b506000805460ff191660ff92909216919091179055600190565b6001600160a01b03163b151590565b61189180620001b86000396000f3fe60806040526004361061016a5760003560e01c8063902bb176116100cb578063b66a0e5d1161007f578063e6d37b8811610059578063e6d37b88146104ca578063e6fd48bc146104dd578063f2fde38b146104f357600080fd5b8063b66a0e5d14610480578063e36b0b3714610495578063e67151ae146104aa57600080fd5b80639f696274116100b05780639f69627414610416578063a035b1fe14610436578063adf8750c1461044c57600080fd5b8063902bb176146103e05780639c9c66691461040057600080fd5b80636864e66311610122578063715018a611610107578063715018a61461037e5780638d6cc56d146103955780638da5cb5b146103b557600080fd5b80636864e6631461026b5780636df050441461028b57600080fd5b806347ccca021161015357806347ccca02146101df5780634a79d50c146102315780635c474f9e1461025357600080fd5b806301ffc9a71461016f57806328592fc6146101a4575b600080fd5b34801561017b57600080fd5b5061018f61018a36600461135a565b610513565b60405190151581526020015b60405180910390f35b3480156101b057600080fd5b506101d16101bf3660046113c7565b609c6020526000908152604090205481565b60405190815260200161019b565b3480156101eb57600080fd5b5060335461020c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b34801561023d57600080fd5b5061024661058b565b60405161019b91906113e2565b34801561025f57600080fd5b5060985442101561018f565b34801561027757600080fd5b5061018f610286366004611553565b610619565b34801561029757600080fd5b506101d16102a63660046115b4565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084901b1660208201526000908190603401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120908301528101849052606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602080830191909120908401529250016040516020818303038152906040528051906020012091505092915050565b34801561038a57600080fd5b506103936106be565b005b3480156103a157600080fd5b506103936103b03660046115de565b610736565b3480156103c157600080fd5b5060665473ffffffffffffffffffffffffffffffffffffffff1661020c565b3480156103ec57600080fd5b506103936103fb3660046115f7565b6107a2565b34801561040c57600080fd5b506101d1609a5481565b34801561042257600080fd5b506103936104313660046115de565b61087c565b34801561044257600080fd5b506101d160995481565b34801561045857600080fd5b506101d17fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81565b34801561048c57600080fd5b506103936108e8565b3480156104a157600080fd5b50610393610955565b3480156104b657600080fd5b506103936104c53660046115de565b6109e2565b6103936104d83660046116cb565b610a4e565b3480156104e957600080fd5b506101d160985481565b3480156104ff57600080fd5b5061039361050e3660046113c7565b610c7d565b60007fffffffff000000000000000000000000000000000000000000000000000000008216158061058557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b609b80546105989061171b565b80601f01602080910402602001604051908101604052809291908181526020018280546105c49061171b565b80156106115780601f106105e657610100808354040283529160200191610611565b820191906000526020600020905b8154815290600101906020018083116105f457829003601f168201915b505050505081565b60408051606085901b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660208083019190915282516014818403018152603483018452805190820120605483015260748083018690528351808403909101815260948301845280519082012060b4808401919091528351808403909101815260d490920190925280519101206000906106b4838783610d95565b9695505050505050565b60665473ffffffffffffffffffffffffffffffffffffffff16331461072a5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b6107346000610dab565b565b60665473ffffffffffffffffffffffffffffffffffffffff16331461079d5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609955565b60006107ae6001610e22565b905080156107e357600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b6107ec84610f79565b6107f4611045565b845161080790609b9060208801906112c1565b506099829055609a839055801561087557600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b60665473ffffffffffffffffffffffffffffffffffffffff1633146108e35760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609a55565b60665473ffffffffffffffffffffffffffffffffffffffff16331461094f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b42609855565b60665473ffffffffffffffffffffffffffffffffffffffff1633146109bc5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff609855565b60665473ffffffffffffffffffffffffffffffffffffffff163314610a495760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609855565b609854421015610aa05760405162461bcd60e51b815260206004820152601460248201527f53616c65206e6f742073746172746564207965740000000000000000000000006044820152606401610721565b610aae609a54338484610619565b610afa5760405162461bcd60e51b815260206004820152600f60248201527f4e6f742077686974656c697374656400000000000000000000000000000000006044820152606401610721565b336000908152609c60205260409020548290610b1790859061179e565b1115610b655760405162461bcd60e51b815260206004820152601d60248201527f43616e6e6f7420636c61696d206d6f72652070657220616464726573730000006044820152606401610721565b609954610b7290846117b6565b341015610bc15760405162461bcd60e51b815260206004820152601660248201527f4e6f7420656e6f7567682045544820746f206d696e74000000000000000000006044820152606401610721565b336000908152609c602052604081208054859290610be090849061179e565b90915550506033546040517f4690521b000000000000000000000000000000000000000000000000000000008152600481018590523360248201526000604482015273ffffffffffffffffffffffffffffffffffffffff90911690634690521b9034906064016000604051808303818588803b158015610c5f57600080fd5b505af1158015610c73573d6000803e3d6000fd5b5050505050505050565b60665473ffffffffffffffffffffffffffffffffffffffff163314610ce45760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b73ffffffffffffffffffffffffffffffffffffffff8116610d6d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610721565b610d7681610dab565b50565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b600082610da285846110ca565b14949350505050565b6066805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008054610100900460ff1615610ebf578160ff166001148015610e455750303b155b610eb75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610721565b506000919050565b60005460ff808416911610610f3c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610721565b50600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055600190565b919050565b600054610100900460ff16610ff65760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b610ffe61113e565b603380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b600054610100900460ff166110c25760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b6109bc6111bb565b600081815b84518110156111365760008582815181106110ec576110ec6117f3565b602002602001015190508083116111125760008381526020829052604090209250611123565b600081815260208490526040902092505b508061112e81611822565b9150506110cf565b509392505050565b600054610100900460ff166107345760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b600054610100900460ff166112385760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b610734600054610100900460ff166112b85760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b61073433610dab565b8280546112cd9061171b565b90600052602060002090601f0160209004810192826112ef5760008555611335565b82601f1061130857805160ff1916838001178555611335565b82800160010185558215611335579182015b8281111561133557825182559160200191906001019061131a565b50611341929150611345565b5090565b5b808211156113415760008155600101611346565b60006020828403121561136c57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461139c57600080fd5b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610f7457600080fd5b6000602082840312156113d957600080fd5b61139c826113a3565b600060208083528351808285015260005b8181101561140f578581018301518582016040015282016113f3565b81811115611421576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156114cb576114cb611455565b604052919050565b600082601f8301126114e457600080fd5b8135602067ffffffffffffffff82111561150057611500611455565b8160051b61150f828201611484565b928352848101820192828101908785111561152957600080fd5b83870192505b848310156115485782358252918301919083019061152f565b979650505050505050565b6000806000806080858703121561156957600080fd5b84359350611579602086016113a3565b925060408501359150606085013567ffffffffffffffff81111561159c57600080fd5b6115a8878288016114d3565b91505092959194509250565b600080604083850312156115c757600080fd5b6115d0836113a3565b946020939093013593505050565b6000602082840312156115f057600080fd5b5035919050565b6000806000806080858703121561160d57600080fd5b843567ffffffffffffffff8082111561162557600080fd5b818701915087601f83011261163957600080fd5b813560208282111561164d5761164d611455565b61167d817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f85011601611484565b9250818352898183860101111561169357600080fd5b818185018285013760008183850101528297506116b1818a016113a3565b979a97995050505060408601359560600135949350505050565b6000806000606084860312156116e057600080fd5b8335925060208401359150604084013567ffffffffffffffff81111561170557600080fd5b611711868287016114d3565b9150509250925092565b600181811c9082168061172f57607f821691505b60208210811415611769577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156117b1576117b161176f565b500190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156117ee576117ee61176f565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156118545761185461176f565b506001019056fea26469706673582212204f29c1c4539d8e3f55cb9f781d6b78b3835d5ada9a0b4c51610a30d236bfab2b64736f6c63430008090033496e697469616c697a61626c653a20636f6e747261637420697320616c726561
Deployed Bytecode
0x60806040526004361061016a5760003560e01c8063902bb176116100cb578063b66a0e5d1161007f578063e6d37b8811610059578063e6d37b88146104ca578063e6fd48bc146104dd578063f2fde38b146104f357600080fd5b8063b66a0e5d14610480578063e36b0b3714610495578063e67151ae146104aa57600080fd5b80639f696274116100b05780639f69627414610416578063a035b1fe14610436578063adf8750c1461044c57600080fd5b8063902bb176146103e05780639c9c66691461040057600080fd5b80636864e66311610122578063715018a611610107578063715018a61461037e5780638d6cc56d146103955780638da5cb5b146103b557600080fd5b80636864e6631461026b5780636df050441461028b57600080fd5b806347ccca021161015357806347ccca02146101df5780634a79d50c146102315780635c474f9e1461025357600080fd5b806301ffc9a71461016f57806328592fc6146101a4575b600080fd5b34801561017b57600080fd5b5061018f61018a36600461135a565b610513565b60405190151581526020015b60405180910390f35b3480156101b057600080fd5b506101d16101bf3660046113c7565b609c6020526000908152604090205481565b60405190815260200161019b565b3480156101eb57600080fd5b5060335461020c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b34801561023d57600080fd5b5061024661058b565b60405161019b91906113e2565b34801561025f57600080fd5b5060985442101561018f565b34801561027757600080fd5b5061018f610286366004611553565b610619565b34801561029757600080fd5b506101d16102a63660046115b4565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084901b1660208201526000908190603401604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120908301528101849052606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602080830191909120908401529250016040516020818303038152906040528051906020012091505092915050565b34801561038a57600080fd5b506103936106be565b005b3480156103a157600080fd5b506103936103b03660046115de565b610736565b3480156103c157600080fd5b5060665473ffffffffffffffffffffffffffffffffffffffff1661020c565b3480156103ec57600080fd5b506103936103fb3660046115f7565b6107a2565b34801561040c57600080fd5b506101d1609a5481565b34801561042257600080fd5b506103936104313660046115de565b61087c565b34801561044257600080fd5b506101d160995481565b34801561045857600080fd5b506101d17fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81565b34801561048c57600080fd5b506103936108e8565b3480156104a157600080fd5b50610393610955565b3480156104b657600080fd5b506103936104c53660046115de565b6109e2565b6103936104d83660046116cb565b610a4e565b3480156104e957600080fd5b506101d160985481565b3480156104ff57600080fd5b5061039361050e3660046113c7565b610c7d565b60007fffffffff000000000000000000000000000000000000000000000000000000008216158061058557507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b609b80546105989061171b565b80601f01602080910402602001604051908101604052809291908181526020018280546105c49061171b565b80156106115780601f106105e657610100808354040283529160200191610611565b820191906000526020600020905b8154815290600101906020018083116105f457829003601f168201915b505050505081565b60408051606085901b7fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001660208083019190915282516014818403018152603483018452805190820120605483015260748083018690528351808403909101815260948301845280519082012060b4808401919091528351808403909101815260d490920190925280519101206000906106b4838783610d95565b9695505050505050565b60665473ffffffffffffffffffffffffffffffffffffffff16331461072a5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064015b60405180910390fd5b6107346000610dab565b565b60665473ffffffffffffffffffffffffffffffffffffffff16331461079d5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609955565b60006107ae6001610e22565b905080156107e357600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b6107ec84610f79565b6107f4611045565b845161080790609b9060208801906112c1565b506099829055609a839055801561087557600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b5050505050565b60665473ffffffffffffffffffffffffffffffffffffffff1633146108e35760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609a55565b60665473ffffffffffffffffffffffffffffffffffffffff16331461094f5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b42609855565b60665473ffffffffffffffffffffffffffffffffffffffff1633146109bc5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff609855565b60665473ffffffffffffffffffffffffffffffffffffffff163314610a495760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b609855565b609854421015610aa05760405162461bcd60e51b815260206004820152601460248201527f53616c65206e6f742073746172746564207965740000000000000000000000006044820152606401610721565b610aae609a54338484610619565b610afa5760405162461bcd60e51b815260206004820152600f60248201527f4e6f742077686974656c697374656400000000000000000000000000000000006044820152606401610721565b336000908152609c60205260409020548290610b1790859061179e565b1115610b655760405162461bcd60e51b815260206004820152601d60248201527f43616e6e6f7420636c61696d206d6f72652070657220616464726573730000006044820152606401610721565b609954610b7290846117b6565b341015610bc15760405162461bcd60e51b815260206004820152601660248201527f4e6f7420656e6f7567682045544820746f206d696e74000000000000000000006044820152606401610721565b336000908152609c602052604081208054859290610be090849061179e565b90915550506033546040517f4690521b000000000000000000000000000000000000000000000000000000008152600481018590523360248201526000604482015273ffffffffffffffffffffffffffffffffffffffff90911690634690521b9034906064016000604051808303818588803b158015610c5f57600080fd5b505af1158015610c73573d6000803e3d6000fd5b5050505050505050565b60665473ffffffffffffffffffffffffffffffffffffffff163314610ce45760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610721565b73ffffffffffffffffffffffffffffffffffffffff8116610d6d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610721565b610d7681610dab565b50565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b600082610da285846110ca565b14949350505050565b6066805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008054610100900460ff1615610ebf578160ff166001148015610e455750303b155b610eb75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610721565b506000919050565b60005460ff808416911610610f3c5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610721565b50600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055600190565b919050565b600054610100900460ff16610ff65760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b610ffe61113e565b603380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b600054610100900460ff166110c25760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b6109bc6111bb565b600081815b84518110156111365760008582815181106110ec576110ec6117f3565b602002602001015190508083116111125760008381526020829052604090209250611123565b600081815260208490526040902092505b508061112e81611822565b9150506110cf565b509392505050565b600054610100900460ff166107345760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b600054610100900460ff166112385760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b610734600054610100900460ff166112b85760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610721565b61073433610dab565b8280546112cd9061171b565b90600052602060002090601f0160209004810192826112ef5760008555611335565b82601f1061130857805160ff1916838001178555611335565b82800160010185558215611335579182015b8281111561133557825182559160200191906001019061131a565b50611341929150611345565b5090565b5b808211156113415760008155600101611346565b60006020828403121561136c57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461139c57600080fd5b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610f7457600080fd5b6000602082840312156113d957600080fd5b61139c826113a3565b600060208083528351808285015260005b8181101561140f578581018301518582016040015282016113f3565b81811115611421576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156114cb576114cb611455565b604052919050565b600082601f8301126114e457600080fd5b8135602067ffffffffffffffff82111561150057611500611455565b8160051b61150f828201611484565b928352848101820192828101908785111561152957600080fd5b83870192505b848310156115485782358252918301919083019061152f565b979650505050505050565b6000806000806080858703121561156957600080fd5b84359350611579602086016113a3565b925060408501359150606085013567ffffffffffffffff81111561159c57600080fd5b6115a8878288016114d3565b91505092959194509250565b600080604083850312156115c757600080fd5b6115d0836113a3565b946020939093013593505050565b6000602082840312156115f057600080fd5b5035919050565b6000806000806080858703121561160d57600080fd5b843567ffffffffffffffff8082111561162557600080fd5b818701915087601f83011261163957600080fd5b813560208282111561164d5761164d611455565b61167d817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f85011601611484565b9250818352898183860101111561169357600080fd5b818185018285013760008183850101528297506116b1818a016113a3565b979a97995050505060408601359560600135949350505050565b6000806000606084860312156116e057600080fd5b8335925060208401359150604084013567ffffffffffffffff81111561170557600080fd5b611711868287016114d3565b9150509250925092565b600181811c9082168061172f57607f821691505b60208210811415611769577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156117b1576117b161176f565b500190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156117ee576117ee61176f565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156118545761185461176f565b506001019056fea26469706673582212204f29c1c4539d8e3f55cb9f781d6b78b3835d5ada9a0b4c51610a30d236bfab2b64736f6c63430008090033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.