Feature Tip: Add private address tag to any address under My Name Tag !
ERC-721
Overview
Max Total Supply
0 MAXZE
Holders
141
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
1 MAXZELoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
TheGreatestMuhammadAliXZeblocksMintPass
Compiler Version
v0.8.18+commit.87f61d96
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/[email protected]/token/ERC721/ERC721.sol"; import "@openzeppelin/[email protected]/token/ERC721/extensions/ERC721Burnable.sol"; import "@openzeppelin/[email protected]/access/AccessControl.sol"; import "@openzeppelin/[email protected]/utils/Counters.sol"; import "@openzeppelin/[email protected]/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/[email protected]/utils/structs/EnumerableSet.sol"; import "@openzeppelin/[email protected]/security/ReentrancyGuard.sol"; import "@openzeppelin/[email protected]/utils/Address.sol"; import "@openzeppelin/[email protected]/token/ERC20/IERC20.sol"; contract TheGreatestMuhammadAliXZeblocksMintPass is ERC721, ERC721Burnable, AccessControl, ReentrancyGuard { using Counters for Counters.Counter; using EnumerableSet for EnumerableSet.AddressSet; using Address for address payable; uint256 public MAX_SUPPLY = 2000; uint256 public MAX_MINT_PER_TX = 10; mapping(address => uint256) public claimedTokens; bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE"); Counters.Counter private _tokenIdCounter; bytes32 public merkleRootPhase1; bytes32 public merkleRootPhase2; uint256 public AmountPhase1Cap = 1000; uint256 public AmountPhase2Cap = 1000; uint256 public Phase1Minted; uint256 public Phase2Minted; mapping(address => uint256) public whitelistedQuantitiesPhase1; mapping(address => uint256) public whitelistedQuantitiesPhase2; mapping(address => bool) public usersClaimedPhase1Before; mapping(address => bool) public usersClaimedPhase2Before; EnumerableSet.AddressSet private claimedPhase1; EnumerableSet.AddressSet private claimedPhase2; bool public phase1Enabled; bool public phase2Enabled; bool public openMintingEnabled; string private _currentBaseURI = "https://fleek.muhammadalinft.io/7d0c8100-40cb-45ac-b78d-7f9e3775762f-bucket/ali/data.json"; uint256 public claimPrice; uint256 public openMintPrice; uint256 public claimPriceToken; uint256 public openMintPriceToken; address payable public PaymentAddress; IERC20 public paymentToken; constructor() ERC721("The Greatest: Muhammad Ali x Zeblocks Mint Pass", "MAXZE"){ _setupRole(DEFAULT_ADMIN_ROLE, msg.sender); _setupRole(MINTER_ROLE, msg.sender); phase1Enabled = false; phase2Enabled = false; openMintingEnabled = false; claimPrice = 0.2 ether; openMintPrice = 0.2 ether; claimPriceToken = 9000000 ether; openMintPriceToken = 9000000 ether; PaymentAddress = payable(msg.sender); } function _baseURI() internal view override returns (string memory) { return _currentBaseURI; } function totalMinted() public view returns (uint256) { return _tokenIdCounter.current(); } function setBaseURI(string memory newBaseURI) external onlyRole(DEFAULT_ADMIN_ROLE) { _currentBaseURI = newBaseURI; } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? baseURI : ""; } function setMaxSupply(uint256 supply) external onlyRole(DEFAULT_ADMIN_ROLE) { MAX_SUPPLY=supply; } function setMaxMintPerTx(uint256 maxTx) external onlyRole(DEFAULT_ADMIN_ROLE) { MAX_MINT_PER_TX=maxTx; } function setMerkleRoots(bytes32 _merkleRootPhase1, bytes32 _merkleRootPhase2) external onlyRole(DEFAULT_ADMIN_ROLE) { merkleRootPhase1 = _merkleRootPhase1; merkleRootPhase2 = _merkleRootPhase2; } function setMerkleRootPhase1(bytes32 _merkleRootPhase1) external onlyRole(DEFAULT_ADMIN_ROLE) { merkleRootPhase1 = _merkleRootPhase1; } function setMerkleRootPhase2( bytes32 _merkleRootPhase2) external onlyRole(DEFAULT_ADMIN_ROLE) { merkleRootPhase2 = _merkleRootPhase2; } function togglePhase(uint8 phase, bool enabled) external onlyRole(DEFAULT_ADMIN_ROLE) { if (phase == 1) { phase1Enabled = enabled; } else if (phase == 2) { phase2Enabled = enabled; } else { revert("Invalid phase"); } } function toggleOpenMinting(bool enabled) external onlyRole(DEFAULT_ADMIN_ROLE) { openMintingEnabled = enabled; } function setClaimPrice(uint256 _claimPrice) external onlyRole(DEFAULT_ADMIN_ROLE) { claimPrice = _claimPrice; } function setPaymentTokenAddress(address tokenAddress) external onlyRole(DEFAULT_ADMIN_ROLE) { paymentToken = IERC20(tokenAddress); } function setTokenPrices(uint256 _claimPriceToken, uint256 _openMintPriceToken) external onlyRole(DEFAULT_ADMIN_ROLE) { claimPriceToken = _claimPriceToken; openMintPriceToken = _openMintPriceToken; } function setOpenMintPrice(uint256 _openMintPrice) external onlyRole(DEFAULT_ADMIN_ROLE) { openMintPrice = _openMintPrice; } function setPaymentAddress(address payable _paymentAddress) external onlyRole(DEFAULT_ADMIN_ROLE) { PaymentAddress = _paymentAddress; } function setAmountPhase1(uint256 amount) external onlyRole(DEFAULT_ADMIN_ROLE) { AmountPhase1Cap = amount; } function setAmountPhase2(uint256 amount) external onlyRole(DEFAULT_ADMIN_ROLE) { AmountPhase2Cap = amount; } function setWhitelistedQuantityPhase1(address user, uint256 quantity) external onlyRole(DEFAULT_ADMIN_ROLE) { whitelistedQuantitiesPhase1[user] = quantity; } function setWhitelistedQuantityPhase2(address user, uint256 quantity) external onlyRole(DEFAULT_ADMIN_ROLE) { whitelistedQuantitiesPhase2[user] = quantity; } function claim(uint256 numTokens, uint256 allowance1, uint256 allowance2, bytes32[] calldata merkleProofPhase1, bytes32[] calldata merkleProofPhase2, bool payWithToken) external payable nonReentrant { require(phase1Enabled || phase2Enabled, "Both claim phases are disabled"); require(numTokens > 0 && numTokens <= MAX_MINT_PER_TX, "Invalid number of tokens to mint"); uint256 totalPayment; if (payWithToken) { totalPayment = claimPriceToken * numTokens; require(paymentToken.balanceOf(msg.sender) >= totalPayment, "Insufficient token payment"); paymentToken.transferFrom(msg.sender, PaymentAddress, totalPayment); } else { totalPayment = claimPrice * numTokens; require(msg.value >= totalPayment, "Insufficient ETH payment"); PaymentAddress.sendValue(msg.value); } uint256 allowedTotal = 0; if (phase1Enabled) { if (!claimedPhase1.contains(msg.sender) && merkleProofPhase1.length > 0) { bool validPhase1Proof = MerkleProof.verify(merkleProofPhase1, merkleRootPhase1, keccak256(bytes.concat(keccak256(abi.encode(msg.sender, allowance1))))); require(validPhase1Proof, "Invalid proof or quantity for phase 1"); claimedPhase1.add(msg.sender); whitelistedQuantitiesPhase1[msg.sender] += allowance1; allowedTotal += allowance1; usersClaimedPhase1Before[msg.sender]=true; } else { allowedTotal += whitelistedQuantitiesPhase1[msg.sender]; } } if (phase2Enabled) { if (!claimedPhase2.contains(msg.sender) && merkleProofPhase2.length > 0) { bool validPhase2Proof = MerkleProof.verify(merkleProofPhase2, merkleRootPhase2, keccak256(bytes.concat(keccak256(abi.encode(msg.sender, allowance2))))); require(validPhase2Proof, "Invalid proof or quantity for phase 2"); claimedPhase2.add(msg.sender); whitelistedQuantitiesPhase2[msg.sender] += allowance2; allowedTotal += allowance2; usersClaimedPhase2Before[msg.sender]=true; } else { allowedTotal += whitelistedQuantitiesPhase2[msg.sender]; } } require(numTokens <= allowedTotal, "Claim limit exceeded"); for (uint256 i = 0; i < numTokens; i++) { if (phase1Enabled) { if (whitelistedQuantitiesPhase1[msg.sender] > 0) { require(_tokenIdCounter.current() < MAX_SUPPLY, "Max Supply Limit"); require(Phase1Minted < AmountPhase1Cap, "Max Supply Limit"); Phase1Minted++; uint256 tokenId = _tokenIdCounter.current(); _tokenIdCounter.increment(); _safeMint(msg.sender, tokenId); whitelistedQuantitiesPhase1[msg.sender]--; continue; } } if (phase2Enabled) { if (whitelistedQuantitiesPhase2[msg.sender] > 0) { require(_tokenIdCounter.current() < MAX_SUPPLY, "Max Supply Limit"); require(Phase2Minted < AmountPhase2Cap, "Max Supply Limit"); Phase2Minted++; uint256 tokenId = _tokenIdCounter.current(); _tokenIdCounter.increment(); _safeMint(msg.sender, tokenId); whitelistedQuantitiesPhase2[msg.sender]--; continue; } } } } function openMint(uint256 numTokens, bool payWithToken) external payable nonReentrant { require(openMintingEnabled, "Open minting is not enabled"); uint256 totalPayment; if (payWithToken) { totalPayment = openMintPriceToken * numTokens; require(paymentToken.balanceOf(msg.sender) >= totalPayment, "Insufficient token payment"); paymentToken.transferFrom(msg.sender, PaymentAddress, totalPayment); } else { totalPayment = openMintPrice * numTokens; require(msg.value >= totalPayment, "Insufficient ETH payment"); PaymentAddress.sendValue(msg.value); } require(_tokenIdCounter.current() + numTokens <= MAX_SUPPLY, "Mint limit exceeded"); require(numTokens > 0 && numTokens <= MAX_MINT_PER_TX, "Invalid number of tokens to mint"); for (uint256 i = 0; i < numTokens; i++) { uint256 tokenId = _tokenIdCounter.current(); _tokenIdCounter.increment(); _safeMint(msg.sender, tokenId); } } function supportsInterface(bytes4 interfaceId) public view override(ERC721, AccessControl) returns (bool) { return super.supportsInterface(interfaceId); } function burn(uint256 tokenId) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: burn caller is not owner nor approved"); _burn(tokenId); } function batchBurn(uint256[] memory tokenIds) public virtual { for (uint256 i = 0; i < tokenIds.length; i++) { burn(tokenIds[i]); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // 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 Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(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 pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and make it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ``` * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. */ library EnumerableSet { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastvalue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastvalue; // Update the index for the moved value set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { return _values(set._inner); } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values on the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT 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. */ library MerkleProof { /** * @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) { 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 = keccak256(abi.encodePacked(computedHash, proofElement)); } else { // Hash(current element of the proof + current computed hash) computedHash = keccak256(abi.encodePacked(proofElement, computedHash)); } } // Check if the computed hash (root) is equal to the provided root return computedHash == root; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title Counters * @author Matt Condon (@shrugs) * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number * of elements in a mapping, issuing ERC721 ids, or counting request ids. * * Include with `using Counters for Counters.Counter;` */ library Counters { struct Counter { // This variable should never be directly accessed by users of the library: interactions must be restricted to // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add // this feature: see https://github.com/ethereum/solidity/issues/4637 uint256 _value; // default: 0 } function current(Counter storage counter) internal view returns (uint256) { return counter._value; } function increment(Counter storage counter) internal { unchecked { counter._value += 1; } } function decrement(Counter storage counter) internal { uint256 value = counter._value; require(value > 0, "Counter: decrement overflow"); unchecked { counter._value = value - 1; } } function reset(Counter storage counter) internal { counter._value = 0; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role, _msgSender()); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } function _grantRole(bytes32 role, address account) private { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } function _revokeRole(bytes32 role, address account) private { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC721.sol"; import "../../../utils/Context.sol"; /** * @title ERC721 Burnable Token * @dev ERC721 Token that can be irreversibly burned (destroyed). */ abstract contract ERC721Burnable is Context, ERC721 { /** * @dev Burns `tokenId`. See {ERC721-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721Burnable: caller is not owner nor approved"); _burn(tokenId); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @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. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165.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 ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT 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`, 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 be 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 Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @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 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); /** * @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; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT 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); }
{ "optimizer": { "enabled": true, "runs": 200 }, "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":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"AmountPhase1Cap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"AmountPhase2Cap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_MINT_PER_TX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PaymentAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"Phase1Minted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"Phase2Minted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"batchBurn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"numTokens","type":"uint256"},{"internalType":"uint256","name":"allowance1","type":"uint256"},{"internalType":"uint256","name":"allowance2","type":"uint256"},{"internalType":"bytes32[]","name":"merkleProofPhase1","type":"bytes32[]"},{"internalType":"bytes32[]","name":"merkleProofPhase2","type":"bytes32[]"},{"internalType":"bool","name":"payWithToken","type":"bool"}],"name":"claim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"claimPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimPriceToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimedTokens","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRootPhase1","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRootPhase2","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"numTokens","type":"uint256"},{"internalType":"bool","name":"payWithToken","type":"bool"}],"name":"openMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"openMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"openMintPriceToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"openMintingEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paymentToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"phase1Enabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"phase2Enabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"setAmountPhase1","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"setAmountPhase2","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newBaseURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimPrice","type":"uint256"}],"name":"setClaimPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"maxTx","type":"uint256"}],"name":"setMaxMintPerTx","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"supply","type":"uint256"}],"name":"setMaxSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRootPhase1","type":"bytes32"}],"name":"setMerkleRootPhase1","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRootPhase2","type":"bytes32"}],"name":"setMerkleRootPhase2","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRootPhase1","type":"bytes32"},{"internalType":"bytes32","name":"_merkleRootPhase2","type":"bytes32"}],"name":"setMerkleRoots","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_openMintPrice","type":"uint256"}],"name":"setOpenMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_paymentAddress","type":"address"}],"name":"setPaymentAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"setPaymentTokenAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_claimPriceToken","type":"uint256"},{"internalType":"uint256","name":"_openMintPriceToken","type":"uint256"}],"name":"setTokenPrices","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"setWhitelistedQuantityPhase1","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"setWhitelistedQuantityPhase2","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":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"enabled","type":"bool"}],"name":"toggleOpenMinting","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint8","name":"phase","type":"uint8"},{"internalType":"bool","name":"enabled","type":"bool"}],"name":"togglePhase","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"usersClaimedPhase1Before","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"usersClaimedPhase2Before","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistedQuantitiesPhase1","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistedQuantitiesPhase2","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
6107d0600855600a6009556103e8600e819055600f5561010060405260596080818152906200398460a039601b906200003990826200027e565b503480156200004757600080fd5b506040518060600160405280602f815260200162003955602f91396040805180820190915260058152644d41585a4560d81b602082015260006200008c83826200027e565b5060016200009b82826200027e565b5050600160075550620000b060003362000125565b620000dc7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a63362000125565b601a805462ffffff191690556702c68af0bb140000601c819055601d556a0771d2fa45345aa9000000601e819055601f55602080546001600160a01b031916331790556200034a565b62000131828262000135565b5050565b60008281526006602090815260408083206001600160a01b038516845290915290205460ff16620001315760008281526006602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620001953390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200020457607f821691505b6020821081036200022557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200027957600081815260208120601f850160051c81016020861015620002545750805b601f850160051c820191505b81811015620002755782815560010162000260565b5050505b505050565b81516001600160401b038111156200029a576200029a620001d9565b620002b281620002ab8454620001ef565b846200022b565b602080601f831160018114620002ea5760008415620002d15750858301515b600019600386901b1c1916600185901b17855562000275565b600085815260208120601f198616915b828110156200031b57888601518255948401946001909101908401620002fa565b50858210156200033a5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6135fb806200035a6000396000f3fe6080604052600436106103c35760003560e01c806364f52a1f116101f2578063c0ce2f2e1161010d578063e4daa916116100a0578063f4f6d2d51161006f578063f4f6d2d514610b6b578063f7f2f7f514610b81578063f812d23014610ba1578063fc202d4014610bc157600080fd5b8063e4daa91614610ad6578063e985e9c514610aec578063ef24b09914610b35578063f3f119f114610b5557600080fd5b8063d547741f116100dc578063d547741f14610a57578063dc8e92ea14610a77578063dcb98f7e14610a97578063dfab41f114610ab757600080fd5b8063c0ce2f2e146109da578063c87b56dd146109f0578063d10fa83514610a10578063d539139314610a2357600080fd5b80639a48eb5111610185578063a58d990a11610154578063a58d990a14610957578063a960c65f14610977578063b88d4fde146109a4578063b9749b61146109c457600080fd5b80639a48eb51146108ed578063a217fddf1461090d578063a22cb46514610922578063a2309ff81461094257600080fd5b80638ecad721116101c15780638ecad7211461088257806391d148541461089857806395d89b41146108b857806396db3e89146108cd57600080fd5b806364f52a1f146107fc5780636f8b44b01461081257806370a08231146108325780638304dac61461085257600080fd5b80633013ce29116102e257806355f5f066116102755780635e1e1004116102445780635e1e10041461077c578063616cdb1e1461079c5780636352211e146107bc57806364768654146107dc57600080fd5b806355f5f0661461070657806355f804b3146107265780635832d5b6146107465780635b2093ef1461076657600080fd5b806342842e0e116102b157806342842e0e1461068657806342966c68146106a657806345158979146106c657806351f468c0146106e657600080fd5b80633013ce291461060357806332cb6b0c1461062357806336568abe1461063957806336e5a22a1461065957600080fd5b8063156d5e0d1161035a578063191b16a011610329578063191b16a01461057357806323b872dd14610593578063248a9ca3146105b35780632f2ff15d146105e357600080fd5b8063156d5e0d146104ea57806315d655c9146105005780631691e36f1461051657806316d821e81461054357600080fd5b8063081812fc11610396578063081812fc1461044e5780630821aaa414610486578063095ea7b3146104a65780630d7028c0146104c657600080fd5b806301ffc9a7146103c85780630614c8a1146103fd57806306fdde0314610412578063079386b514610434575b600080fd5b3480156103d457600080fd5b506103e86103e3366004612cbe565b610be1565b60405190151581526020015b60405180910390f35b61041061040b366004612d35565b610bf2565b005b34801561041e57600080fd5b506104276113cf565b6040516103f49190612e25565b34801561044057600080fd5b50601a546103e89060ff1681565b34801561045a57600080fd5b5061046e610469366004612e38565b611461565b6040516001600160a01b0390911681526020016103f4565b34801561049257600080fd5b506104106104a1366004612e66565b6114f6565b3480156104b257600080fd5b506104106104c1366004612e66565b61151f565b3480156104d257600080fd5b506104dc601f5481565b6040519081526020016103f4565b3480156104f657600080fd5b506104dc60105481565b34801561050c57600080fd5b506104dc601c5481565b34801561052257600080fd5b506104dc610531366004612e92565b60126020526000908152604090205481565b34801561054f57600080fd5b506103e861055e366004612e92565b60146020526000908152604090205460ff1681565b34801561057f57600080fd5b5061041061058e366004612eaf565b611634565b34801561059f57600080fd5b506104106105ae366004612ed1565b61164c565b3480156105bf57600080fd5b506104dc6105ce366004612e38565b60009081526006602052604090206001015490565b3480156105ef57600080fd5b506104106105fe366004612f12565b61167e565b34801561060f57600080fd5b5060215461046e906001600160a01b031681565b34801561062f57600080fd5b506104dc60085481565b34801561064557600080fd5b50610410610654366004612f12565b6116a4565b34801561066557600080fd5b506104dc610674366004612e92565b60136020526000908152604090205481565b34801561069257600080fd5b506104106106a1366004612ed1565b611722565b3480156106b257600080fd5b506104106106c1366004612e38565b61173d565b3480156106d257600080fd5b506104106106e1366004612e38565b6117b4565b3480156106f257600080fd5b50610410610701366004612e38565b6117c6565b34801561071257600080fd5b50610410610721366004612e38565b6117d8565b34801561073257600080fd5b50610410610741366004612fe1565b6117ea565b34801561075257600080fd5b5060205461046e906001600160a01b031681565b34801561077257600080fd5b506104dc600f5481565b34801561078857600080fd5b50610410610797366004612e92565b611802565b3480156107a857600080fd5b506104106107b7366004612e38565b611831565b3480156107c857600080fd5b5061046e6107d7366004612e38565b611843565b3480156107e857600080fd5b506104106107f7366004612e38565b6118ba565b34801561080857600080fd5b506104dc600c5481565b34801561081e57600080fd5b5061041061082d366004612e38565b6118cc565b34801561083e57600080fd5b506104dc61084d366004612e92565b6118de565b34801561085e57600080fd5b506103e861086d366004612e92565b60156020526000908152604090205460ff1681565b34801561088e57600080fd5b506104dc60095481565b3480156108a457600080fd5b506103e86108b3366004612f12565b611965565b3480156108c457600080fd5b50610427611990565b3480156108d957600080fd5b506104106108e8366004612e38565b61199f565b3480156108f957600080fd5b50610410610908366004612eaf565b6119b1565b34801561091957600080fd5b506104dc600081565b34801561092e57600080fd5b5061041061093d36600461302a565b6119c9565b34801561094e57600080fd5b506104dc611a8d565b34801561096357600080fd5b50610410610972366004613058565b611a9d565b34801561098357600080fd5b506104dc610992366004612e92565b600a6020526000908152604090205481565b3480156109b057600080fd5b506104106109bf36600461307c565b611b26565b3480156109d057600080fd5b506104dc600e5481565b3480156109e657600080fd5b506104dc601e5481565b3480156109fc57600080fd5b50610427610a0b366004612e38565b611b5e565b610410610a1e3660046130fc565b611c09565b348015610a2f57600080fd5b506104dc7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b348015610a6357600080fd5b50610410610a72366004612f12565b611f8a565b348015610a8357600080fd5b50610410610a92366004613121565b611fb0565b348015610aa357600080fd5b50610410610ab2366004612e92565b611ff0565b348015610ac357600080fd5b50601a546103e890610100900460ff1681565b348015610ae257600080fd5b506104dc601d5481565b348015610af857600080fd5b506103e8610b073660046131c7565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b348015610b4157600080fd5b50610410610b50366004612e38565b61201f565b348015610b6157600080fd5b506104dc600d5481565b348015610b7757600080fd5b506104dc60115481565b348015610b8d57600080fd5b50610410610b9c3660046131f5565b612031565b348015610bad57600080fd5b50601a546103e89062010000900460ff1681565b348015610bcd57600080fd5b50610410610bdc366004612e66565b61205a565b6000610bec82612083565b92915050565b600260075403610c495760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b6002600755601a5460ff1680610c665750601a54610100900460ff165b610cb25760405162461bcd60e51b815260206004820152601e60248201527f426f746820636c61696d20706861736573206172652064697361626c656400006044820152606401610c40565b600088118015610cc457506009548811155b610d105760405162461bcd60e51b815260206004820181905260248201527f496e76616c6964206e756d626572206f6620746f6b656e7320746f206d696e746044820152606401610c40565b60008115610e6a5788601e54610d269190613228565b6021546040516370a0823160e01b815233600482015291925082916001600160a01b03909116906370a0823190602401602060405180830381865afa158015610d73573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d97919061323f565b1015610de55760405162461bcd60e51b815260206004820152601a60248201527f496e73756666696369656e7420746f6b656e207061796d656e740000000000006044820152606401610c40565b6021546020546040516323b872dd60e01b81523360048201526001600160a01b039182166024820152604481018490529116906323b872dd906064016020604051808303816000875af1158015610e40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e649190613258565b50610edb565b88601c54610e789190613228565b905080341015610ec55760405162461bcd60e51b8152602060048201526018602482015277125b9cdd59999a58da595b9d08115512081c185e5b595b9d60421b6044820152606401610c40565b602054610edb906001600160a01b0316346120a8565b601a5460009060ff161561107957610ef46016336121c1565b158015610f0057508515155b1561105c576000610fa188888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600c54604051909250610f69915033908f906020016001600160a01b03929092168252602082015260400190565b60408051601f1981840301815282825280516020918201209083015201604051602081830303815290604052805190602001206121e6565b905080610ffe5760405162461bcd60e51b815260206004820152602560248201527f496e76616c69642070726f6f66206f72207175616e7469747920666f72207068604482015264617365203160d81b6064820152608401610c40565b611009601633612295565b5033600090815260126020526040812080548c9290611029908490613275565b9091555061103990508a83613275565b336000908152601460205260409020805460ff1916600117905591506110799050565b336000908152601260205260409020546110769082613275565b90505b601a54610100900460ff16156111d3576110946018336121c1565b1580156110a057508315155b156111b65760006110fb86868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600d54604080513360208201529081018f90529092506060019050610f69565b9050806111585760405162461bcd60e51b815260206004820152602560248201527f496e76616c69642070726f6f66206f72207175616e7469747920666f7220706860448201526430b9b2901960d91b6064820152608401610c40565b611163601833612295565b5033600090815260136020526040812080548b9290611183908490613275565b9091555061119390508983613275565b336000908152601560205260409020805460ff1916600117905591506111d39050565b336000908152601360205260409020546111d09082613275565b90505b808a111561121a5760405162461bcd60e51b815260206004820152601460248201527310db185a5b481b1a5b5a5d08195e18d95959195960621b6044820152606401610c40565b60005b8a8110156113bd57601a5460ff16156112eb5733600090815260126020526040902054156112eb57600854600b54106112685760405162461bcd60e51b8152600401610c4090613288565b600e546010541061128b5760405162461bcd60e51b8152600401610c4090613288565b6010805490600061129b836132b2565b919050555060006112ab600b5490565b90506112bb600b80546001019055565b6112c533826122aa565b3360009081526012602052604081208054916112e0836132cb565b9190505550506113ab565b601a54610100900460ff16156113ab5733600090815260136020526040902054156113ab57600854600b54106113335760405162461bcd60e51b8152600401610c4090613288565b600f54601154106113565760405162461bcd60e51b8152600401610c4090613288565b60118054906000611366836132b2565b91905055506000611376600b5490565b9050611386600b80546001019055565b61139033826122aa565b3360009081526013602052604081208054916112e0836132cb565b806113b5816132b2565b91505061121d565b50506001600755505050505050505050565b6060600080546113de906132e2565b80601f016020809104026020016040519081016040528092919081815260200182805461140a906132e2565b80156114575780601f1061142c57610100808354040283529160200191611457565b820191906000526020600020905b81548152906001019060200180831161143a57829003601f168201915b5050505050905090565b6000818152600260205260408120546001600160a01b03166114da5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c40565b506000908152600460205260409020546001600160a01b031690565b600061150281336122c4565b506001600160a01b03909116600090815260136020526040902055565b600061152a82611843565b9050806001600160a01b0316836001600160a01b0316036115975760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610c40565b336001600160a01b03821614806115b357506115b38133610b07565b6116255760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610c40565b61162f8383612328565b505050565b600061164081336122c4565b50601e91909155601f55565b611657335b82612396565b6116735760405162461bcd60e51b8152600401610c409061331c565b61162f83838361248d565b60008281526006602052604090206001015461169a81336122c4565b61162f838361262d565b6001600160a01b03811633146117145760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610c40565b61171e82826126b3565b5050565b61162f83838360405180602001604052806000815250611b26565b61174633611651565b6117a85760405162461bcd60e51b815260206004820152602d60248201527f4552433732313a206275726e2063616c6c6572206973206e6f74206f776e657260448201526c081b9bdc88185c1c1c9bdd9959609a1b6064820152608401610c40565b6117b18161271a565b50565b60006117c081336122c4565b50601d55565b60006117d281336122c4565b50601c55565b60006117e481336122c4565b50600c55565b60006117f681336122c4565b601b61162f83826133bb565b600061180e81336122c4565b50602080546001600160a01b0319166001600160a01b0392909216919091179055565b600061183d81336122c4565b50600955565b6000818152600260205260408120546001600160a01b031680610bec5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610c40565b60006118c681336122c4565b50600e55565b60006118d881336122c4565b50600855565b60006001600160a01b0382166119495760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610c40565b506001600160a01b031660009081526003602052604090205490565b60009182526006602090815260408084206001600160a01b0393909316845291905290205460ff1690565b6060600180546113de906132e2565b60006119ab81336122c4565b50600d55565b60006119bd81336122c4565b50600c91909155600d55565b336001600160a01b03831603611a215760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c40565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6000611a98600b5490565b905090565b6000611aa981336122c4565b8260ff16600103611ac957601a805483151560ff19909116179055505050565b8260ff16600203611aee57601a80548315156101000261ff0019909116179055505050565b60405162461bcd60e51b815260206004820152600d60248201526c496e76616c696420706861736560981b6044820152606401610c40565b611b303383612396565b611b4c5760405162461bcd60e51b8152600401610c409061331c565b611b58848484846127b5565b50505050565b6000818152600260205260409020546060906001600160a01b0316611bdd5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610c40565b6000611be76127e8565b90506000815111610bec57604051806020016040528060008152509392505050565b600260075403611c5b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610c40565b6002600755601a5462010000900460ff16611cb85760405162461bcd60e51b815260206004820152601b60248201527f4f70656e206d696e74696e67206973206e6f7420656e61626c656400000000006044820152606401610c40565b60008115611e125782601f54611cce9190613228565b6021546040516370a0823160e01b815233600482015291925082916001600160a01b03909116906370a0823190602401602060405180830381865afa158015611d1b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d3f919061323f565b1015611d8d5760405162461bcd60e51b815260206004820152601a60248201527f496e73756666696369656e7420746f6b656e207061796d656e740000000000006044820152606401610c40565b6021546020546040516323b872dd60e01b81523360048201526001600160a01b039182166024820152604481018490529116906323b872dd906064016020604051808303816000875af1158015611de8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e0c9190613258565b50611e83565b82601d54611e209190613228565b905080341015611e6d5760405162461bcd60e51b8152602060048201526018602482015277125b9cdd59999a58da595b9d08115512081c185e5b595b9d60421b6044820152606401610c40565b602054611e83906001600160a01b0316346120a8565b60085483611e90600b5490565b611e9a9190613275565b1115611ede5760405162461bcd60e51b8152602060048201526013602482015272135a5b9d081b1a5b5a5d08195e18d959591959606a1b6044820152606401610c40565b600083118015611ef057506009548311155b611f3c5760405162461bcd60e51b815260206004820181905260248201527f496e76616c6964206e756d626572206f6620746f6b656e7320746f206d696e746044820152606401610c40565b60005b83811015611f7f576000611f52600b5490565b9050611f62600b80546001019055565b611f6c33826122aa565b5080611f77816132b2565b915050611f3f565b505060016007555050565b600082815260066020526040902060010154611fa681336122c4565b61162f83836126b3565b60005b815181101561171e57611fde828281518110611fd157611fd161347b565b602002602001015161173d565b80611fe8816132b2565b915050611fb3565b6000611ffc81336122c4565b50602180546001600160a01b0319166001600160a01b0392909216919091179055565b600061202b81336122c4565b50600f55565b600061203d81336122c4565b50601a8054911515620100000262ff000019909216919091179055565b600061206681336122c4565b506001600160a01b03909116600090815260126020526040902055565b60006001600160e01b03198216637965db0b60e01b1480610bec5750610bec826127f7565b804710156120f85760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610c40565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612145576040519150601f19603f3d011682016040523d82523d6000602084013e61214a565b606091505b505090508061162f5760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610c40565b6001600160a01b038116600090815260018301602052604081205415155b9392505050565b600081815b855181101561228a5760008682815181106122085761220861347b565b6020026020010151905080831161224a576040805160208101859052908101829052606001604051602081830303815290604052805190602001209250612277565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b5080612282816132b2565b9150506121eb565b509092149392505050565b60006121df836001600160a01b038416612847565b61171e828260405180602001604052806000815250612896565b6122ce8282611965565b61171e576122e6816001600160a01b031660146128c9565b6122f18360206128c9565b604051602001612302929190613491565b60408051601f198184030181529082905262461bcd60e51b8252610c4091600401612e25565b600081815260046020526040902080546001600160a01b0319166001600160a01b038416908117909155819061235d82611843565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b031661240f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c40565b600061241a83611843565b9050806001600160a01b0316846001600160a01b031614806124555750836001600160a01b031661244a84611461565b6001600160a01b0316145b8061248557506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166124a082611843565b6001600160a01b0316146125085760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610c40565b6001600160a01b03821661256a5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c40565b612575600082612328565b6001600160a01b038316600090815260036020526040812080546001929061259e908490613506565b90915550506001600160a01b03821660009081526003602052604081208054600192906125cc908490613275565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6126378282611965565b61171e5760008281526006602090815260408083206001600160a01b03851684529091529020805460ff1916600117905561266f3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6126bd8282611965565b1561171e5760008281526006602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b600061272582611843565b9050612732600083612328565b6001600160a01b038116600090815260036020526040812080546001929061275b908490613506565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6127c084848461248d565b6127cc84848484612a65565b611b585760405162461bcd60e51b8152600401610c4090613519565b6060601b80546113de906132e2565b60006001600160e01b031982166380ac58cd60e01b148061282857506001600160e01b03198216635b5e139f60e01b145b80610bec57506301ffc9a760e01b6001600160e01b0319831614610bec565b600081815260018301602052604081205461288e57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610bec565b506000610bec565b6128a08383612b66565b6128ad6000848484612a65565b61162f5760405162461bcd60e51b8152600401610c4090613519565b606060006128d8836002613228565b6128e3906002613275565b67ffffffffffffffff8111156128fb576128fb612f42565b6040519080825280601f01601f191660200182016040528015612925576020820181803683370190505b509050600360fc1b816000815181106129405761294061347b565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061296f5761296f61347b565b60200101906001600160f81b031916908160001a9053506000612993846002613228565b61299e906001613275565b90505b6001811115612a16576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106129d2576129d261347b565b1a60f81b8282815181106129e8576129e861347b565b60200101906001600160f81b031916908160001a90535060049490941c93612a0f816132cb565b90506129a1565b5083156121df5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610c40565b60006001600160a01b0384163b15612b5b57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612aa990339089908890889060040161356b565b6020604051808303816000875af1925050508015612ae4575060408051601f3d908101601f19168201909252612ae1918101906135a8565b60015b612b41573d808015612b12576040519150601f19603f3d011682016040523d82523d6000602084013e612b17565b606091505b508051600003612b395760405162461bcd60e51b8152600401610c4090613519565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612485565b506001949350505050565b6001600160a01b038216612bbc5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c40565b6000818152600260205260409020546001600160a01b031615612c215760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c40565b6001600160a01b0382166000908152600360205260408120805460019290612c4a908490613275565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b0319811681146117b157600080fd5b600060208284031215612cd057600080fd5b81356121df81612ca8565b60008083601f840112612ced57600080fd5b50813567ffffffffffffffff811115612d0557600080fd5b6020830191508360208260051b8501011115612d2057600080fd5b9250929050565b80151581146117b157600080fd5b60008060008060008060008060c0898b031215612d5157600080fd5b883597506020890135965060408901359550606089013567ffffffffffffffff80821115612d7e57600080fd5b612d8a8c838d01612cdb565b909750955060808b0135915080821115612da357600080fd5b50612db08b828c01612cdb565b90945092505060a0890135612dc481612d27565b809150509295985092959890939650565b60005b83811015612df0578181015183820152602001612dd8565b50506000910152565b60008151808452612e11816020860160208601612dd5565b601f01601f19169290920160200192915050565b6020815260006121df6020830184612df9565b600060208284031215612e4a57600080fd5b5035919050565b6001600160a01b03811681146117b157600080fd5b60008060408385031215612e7957600080fd5b8235612e8481612e51565b946020939093013593505050565b600060208284031215612ea457600080fd5b81356121df81612e51565b60008060408385031215612ec257600080fd5b50508035926020909101359150565b600080600060608486031215612ee657600080fd5b8335612ef181612e51565b92506020840135612f0181612e51565b929592945050506040919091013590565b60008060408385031215612f2557600080fd5b823591506020830135612f3781612e51565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715612f8157612f81612f42565b604052919050565b600067ffffffffffffffff831115612fa357612fa3612f42565b612fb6601f8401601f1916602001612f58565b9050828152838383011115612fca57600080fd5b828260208301376000602084830101529392505050565b600060208284031215612ff357600080fd5b813567ffffffffffffffff81111561300a57600080fd5b8201601f8101841361301b57600080fd5b61248584823560208401612f89565b6000806040838503121561303d57600080fd5b823561304881612e51565b91506020830135612f3781612d27565b6000806040838503121561306b57600080fd5b823560ff8116811461304857600080fd5b6000806000806080858703121561309257600080fd5b843561309d81612e51565b935060208501356130ad81612e51565b925060408501359150606085013567ffffffffffffffff8111156130d057600080fd5b8501601f810187136130e157600080fd5b6130f087823560208401612f89565b91505092959194509250565b6000806040838503121561310f57600080fd5b823591506020830135612f3781612d27565b6000602080838503121561313457600080fd5b823567ffffffffffffffff8082111561314c57600080fd5b818501915085601f83011261316057600080fd5b81358181111561317257613172612f42565b8060051b9150613183848301612f58565b818152918301840191848101908884111561319d57600080fd5b938501935b838510156131bb578435825293850193908501906131a2565b98975050505050505050565b600080604083850312156131da57600080fd5b82356131e581612e51565b91506020830135612f3781612e51565b60006020828403121561320757600080fd5b81356121df81612d27565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417610bec57610bec613212565b60006020828403121561325157600080fd5b5051919050565b60006020828403121561326a57600080fd5b81516121df81612d27565b80820180821115610bec57610bec613212565b60208082526010908201526f13585e0814dd5c1c1b1e48131a5b5a5d60821b604082015260600190565b6000600182016132c4576132c4613212565b5060010190565b6000816132da576132da613212565b506000190190565b600181811c908216806132f657607f821691505b60208210810361331657634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b601f82111561162f57600081815260208120601f850160051c810160208610156133945750805b601f850160051c820191505b818110156133b3578281556001016133a0565b505050505050565b815167ffffffffffffffff8111156133d5576133d5612f42565b6133e9816133e384546132e2565b8461336d565b602080601f83116001811461341e57600084156134065750858301515b600019600386901b1c1916600185901b1785556133b3565b600085815260208120601f198616915b8281101561344d5788860151825594840194600190910190840161342e565b508582101561346b5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052603260045260246000fd5b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516134c9816017850160208801612dd5565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516134fa816028840160208801612dd5565b01602801949350505050565b81810381811115610bec57610bec613212565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061359e90830184612df9565b9695505050505050565b6000602082840312156135ba57600080fd5b81516121df81612ca856fea2646970667358221220ea794224c216472e3d3334eca60cb724cf1ba26006a45e9b30ad4a88c8c2476564736f6c634300081200335468652047726561746573743a204d7568616d6d616420416c692078205a65626c6f636b73204d696e74205061737368747470733a2f2f666c65656b2e6d7568616d6d6164616c696e66742e696f2f37643063383130302d343063622d343561632d623738642d3766396533373735373632662d6275636b65742f616c692f646174612e6a736f6e
Deployed Bytecode
0x6080604052600436106103c35760003560e01c806364f52a1f116101f2578063c0ce2f2e1161010d578063e4daa916116100a0578063f4f6d2d51161006f578063f4f6d2d514610b6b578063f7f2f7f514610b81578063f812d23014610ba1578063fc202d4014610bc157600080fd5b8063e4daa91614610ad6578063e985e9c514610aec578063ef24b09914610b35578063f3f119f114610b5557600080fd5b8063d547741f116100dc578063d547741f14610a57578063dc8e92ea14610a77578063dcb98f7e14610a97578063dfab41f114610ab757600080fd5b8063c0ce2f2e146109da578063c87b56dd146109f0578063d10fa83514610a10578063d539139314610a2357600080fd5b80639a48eb5111610185578063a58d990a11610154578063a58d990a14610957578063a960c65f14610977578063b88d4fde146109a4578063b9749b61146109c457600080fd5b80639a48eb51146108ed578063a217fddf1461090d578063a22cb46514610922578063a2309ff81461094257600080fd5b80638ecad721116101c15780638ecad7211461088257806391d148541461089857806395d89b41146108b857806396db3e89146108cd57600080fd5b806364f52a1f146107fc5780636f8b44b01461081257806370a08231146108325780638304dac61461085257600080fd5b80633013ce29116102e257806355f5f066116102755780635e1e1004116102445780635e1e10041461077c578063616cdb1e1461079c5780636352211e146107bc57806364768654146107dc57600080fd5b806355f5f0661461070657806355f804b3146107265780635832d5b6146107465780635b2093ef1461076657600080fd5b806342842e0e116102b157806342842e0e1461068657806342966c68146106a657806345158979146106c657806351f468c0146106e657600080fd5b80633013ce291461060357806332cb6b0c1461062357806336568abe1461063957806336e5a22a1461065957600080fd5b8063156d5e0d1161035a578063191b16a011610329578063191b16a01461057357806323b872dd14610593578063248a9ca3146105b35780632f2ff15d146105e357600080fd5b8063156d5e0d146104ea57806315d655c9146105005780631691e36f1461051657806316d821e81461054357600080fd5b8063081812fc11610396578063081812fc1461044e5780630821aaa414610486578063095ea7b3146104a65780630d7028c0146104c657600080fd5b806301ffc9a7146103c85780630614c8a1146103fd57806306fdde0314610412578063079386b514610434575b600080fd5b3480156103d457600080fd5b506103e86103e3366004612cbe565b610be1565b60405190151581526020015b60405180910390f35b61041061040b366004612d35565b610bf2565b005b34801561041e57600080fd5b506104276113cf565b6040516103f49190612e25565b34801561044057600080fd5b50601a546103e89060ff1681565b34801561045a57600080fd5b5061046e610469366004612e38565b611461565b6040516001600160a01b0390911681526020016103f4565b34801561049257600080fd5b506104106104a1366004612e66565b6114f6565b3480156104b257600080fd5b506104106104c1366004612e66565b61151f565b3480156104d257600080fd5b506104dc601f5481565b6040519081526020016103f4565b3480156104f657600080fd5b506104dc60105481565b34801561050c57600080fd5b506104dc601c5481565b34801561052257600080fd5b506104dc610531366004612e92565b60126020526000908152604090205481565b34801561054f57600080fd5b506103e861055e366004612e92565b60146020526000908152604090205460ff1681565b34801561057f57600080fd5b5061041061058e366004612eaf565b611634565b34801561059f57600080fd5b506104106105ae366004612ed1565b61164c565b3480156105bf57600080fd5b506104dc6105ce366004612e38565b60009081526006602052604090206001015490565b3480156105ef57600080fd5b506104106105fe366004612f12565b61167e565b34801561060f57600080fd5b5060215461046e906001600160a01b031681565b34801561062f57600080fd5b506104dc60085481565b34801561064557600080fd5b50610410610654366004612f12565b6116a4565b34801561066557600080fd5b506104dc610674366004612e92565b60136020526000908152604090205481565b34801561069257600080fd5b506104106106a1366004612ed1565b611722565b3480156106b257600080fd5b506104106106c1366004612e38565b61173d565b3480156106d257600080fd5b506104106106e1366004612e38565b6117b4565b3480156106f257600080fd5b50610410610701366004612e38565b6117c6565b34801561071257600080fd5b50610410610721366004612e38565b6117d8565b34801561073257600080fd5b50610410610741366004612fe1565b6117ea565b34801561075257600080fd5b5060205461046e906001600160a01b031681565b34801561077257600080fd5b506104dc600f5481565b34801561078857600080fd5b50610410610797366004612e92565b611802565b3480156107a857600080fd5b506104106107b7366004612e38565b611831565b3480156107c857600080fd5b5061046e6107d7366004612e38565b611843565b3480156107e857600080fd5b506104106107f7366004612e38565b6118ba565b34801561080857600080fd5b506104dc600c5481565b34801561081e57600080fd5b5061041061082d366004612e38565b6118cc565b34801561083e57600080fd5b506104dc61084d366004612e92565b6118de565b34801561085e57600080fd5b506103e861086d366004612e92565b60156020526000908152604090205460ff1681565b34801561088e57600080fd5b506104dc60095481565b3480156108a457600080fd5b506103e86108b3366004612f12565b611965565b3480156108c457600080fd5b50610427611990565b3480156108d957600080fd5b506104106108e8366004612e38565b61199f565b3480156108f957600080fd5b50610410610908366004612eaf565b6119b1565b34801561091957600080fd5b506104dc600081565b34801561092e57600080fd5b5061041061093d36600461302a565b6119c9565b34801561094e57600080fd5b506104dc611a8d565b34801561096357600080fd5b50610410610972366004613058565b611a9d565b34801561098357600080fd5b506104dc610992366004612e92565b600a6020526000908152604090205481565b3480156109b057600080fd5b506104106109bf36600461307c565b611b26565b3480156109d057600080fd5b506104dc600e5481565b3480156109e657600080fd5b506104dc601e5481565b3480156109fc57600080fd5b50610427610a0b366004612e38565b611b5e565b610410610a1e3660046130fc565b611c09565b348015610a2f57600080fd5b506104dc7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b348015610a6357600080fd5b50610410610a72366004612f12565b611f8a565b348015610a8357600080fd5b50610410610a92366004613121565b611fb0565b348015610aa357600080fd5b50610410610ab2366004612e92565b611ff0565b348015610ac357600080fd5b50601a546103e890610100900460ff1681565b348015610ae257600080fd5b506104dc601d5481565b348015610af857600080fd5b506103e8610b073660046131c7565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b348015610b4157600080fd5b50610410610b50366004612e38565b61201f565b348015610b6157600080fd5b506104dc600d5481565b348015610b7757600080fd5b506104dc60115481565b348015610b8d57600080fd5b50610410610b9c3660046131f5565b612031565b348015610bad57600080fd5b50601a546103e89062010000900460ff1681565b348015610bcd57600080fd5b50610410610bdc366004612e66565b61205a565b6000610bec82612083565b92915050565b600260075403610c495760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b6002600755601a5460ff1680610c665750601a54610100900460ff165b610cb25760405162461bcd60e51b815260206004820152601e60248201527f426f746820636c61696d20706861736573206172652064697361626c656400006044820152606401610c40565b600088118015610cc457506009548811155b610d105760405162461bcd60e51b815260206004820181905260248201527f496e76616c6964206e756d626572206f6620746f6b656e7320746f206d696e746044820152606401610c40565b60008115610e6a5788601e54610d269190613228565b6021546040516370a0823160e01b815233600482015291925082916001600160a01b03909116906370a0823190602401602060405180830381865afa158015610d73573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d97919061323f565b1015610de55760405162461bcd60e51b815260206004820152601a60248201527f496e73756666696369656e7420746f6b656e207061796d656e740000000000006044820152606401610c40565b6021546020546040516323b872dd60e01b81523360048201526001600160a01b039182166024820152604481018490529116906323b872dd906064016020604051808303816000875af1158015610e40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e649190613258565b50610edb565b88601c54610e789190613228565b905080341015610ec55760405162461bcd60e51b8152602060048201526018602482015277125b9cdd59999a58da595b9d08115512081c185e5b595b9d60421b6044820152606401610c40565b602054610edb906001600160a01b0316346120a8565b601a5460009060ff161561107957610ef46016336121c1565b158015610f0057508515155b1561105c576000610fa188888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600c54604051909250610f69915033908f906020016001600160a01b03929092168252602082015260400190565b60408051601f1981840301815282825280516020918201209083015201604051602081830303815290604052805190602001206121e6565b905080610ffe5760405162461bcd60e51b815260206004820152602560248201527f496e76616c69642070726f6f66206f72207175616e7469747920666f72207068604482015264617365203160d81b6064820152608401610c40565b611009601633612295565b5033600090815260126020526040812080548c9290611029908490613275565b9091555061103990508a83613275565b336000908152601460205260409020805460ff1916600117905591506110799050565b336000908152601260205260409020546110769082613275565b90505b601a54610100900460ff16156111d3576110946018336121c1565b1580156110a057508315155b156111b65760006110fb86868080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600d54604080513360208201529081018f90529092506060019050610f69565b9050806111585760405162461bcd60e51b815260206004820152602560248201527f496e76616c69642070726f6f66206f72207175616e7469747920666f7220706860448201526430b9b2901960d91b6064820152608401610c40565b611163601833612295565b5033600090815260136020526040812080548b9290611183908490613275565b9091555061119390508983613275565b336000908152601560205260409020805460ff1916600117905591506111d39050565b336000908152601360205260409020546111d09082613275565b90505b808a111561121a5760405162461bcd60e51b815260206004820152601460248201527310db185a5b481b1a5b5a5d08195e18d95959195960621b6044820152606401610c40565b60005b8a8110156113bd57601a5460ff16156112eb5733600090815260126020526040902054156112eb57600854600b54106112685760405162461bcd60e51b8152600401610c4090613288565b600e546010541061128b5760405162461bcd60e51b8152600401610c4090613288565b6010805490600061129b836132b2565b919050555060006112ab600b5490565b90506112bb600b80546001019055565b6112c533826122aa565b3360009081526012602052604081208054916112e0836132cb565b9190505550506113ab565b601a54610100900460ff16156113ab5733600090815260136020526040902054156113ab57600854600b54106113335760405162461bcd60e51b8152600401610c4090613288565b600f54601154106113565760405162461bcd60e51b8152600401610c4090613288565b60118054906000611366836132b2565b91905055506000611376600b5490565b9050611386600b80546001019055565b61139033826122aa565b3360009081526013602052604081208054916112e0836132cb565b806113b5816132b2565b91505061121d565b50506001600755505050505050505050565b6060600080546113de906132e2565b80601f016020809104026020016040519081016040528092919081815260200182805461140a906132e2565b80156114575780601f1061142c57610100808354040283529160200191611457565b820191906000526020600020905b81548152906001019060200180831161143a57829003601f168201915b5050505050905090565b6000818152600260205260408120546001600160a01b03166114da5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c40565b506000908152600460205260409020546001600160a01b031690565b600061150281336122c4565b506001600160a01b03909116600090815260136020526040902055565b600061152a82611843565b9050806001600160a01b0316836001600160a01b0316036115975760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610c40565b336001600160a01b03821614806115b357506115b38133610b07565b6116255760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610c40565b61162f8383612328565b505050565b600061164081336122c4565b50601e91909155601f55565b611657335b82612396565b6116735760405162461bcd60e51b8152600401610c409061331c565b61162f83838361248d565b60008281526006602052604090206001015461169a81336122c4565b61162f838361262d565b6001600160a01b03811633146117145760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610c40565b61171e82826126b3565b5050565b61162f83838360405180602001604052806000815250611b26565b61174633611651565b6117a85760405162461bcd60e51b815260206004820152602d60248201527f4552433732313a206275726e2063616c6c6572206973206e6f74206f776e657260448201526c081b9bdc88185c1c1c9bdd9959609a1b6064820152608401610c40565b6117b18161271a565b50565b60006117c081336122c4565b50601d55565b60006117d281336122c4565b50601c55565b60006117e481336122c4565b50600c55565b60006117f681336122c4565b601b61162f83826133bb565b600061180e81336122c4565b50602080546001600160a01b0319166001600160a01b0392909216919091179055565b600061183d81336122c4565b50600955565b6000818152600260205260408120546001600160a01b031680610bec5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610c40565b60006118c681336122c4565b50600e55565b60006118d881336122c4565b50600855565b60006001600160a01b0382166119495760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610c40565b506001600160a01b031660009081526003602052604090205490565b60009182526006602090815260408084206001600160a01b0393909316845291905290205460ff1690565b6060600180546113de906132e2565b60006119ab81336122c4565b50600d55565b60006119bd81336122c4565b50600c91909155600d55565b336001600160a01b03831603611a215760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c40565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6000611a98600b5490565b905090565b6000611aa981336122c4565b8260ff16600103611ac957601a805483151560ff19909116179055505050565b8260ff16600203611aee57601a80548315156101000261ff0019909116179055505050565b60405162461bcd60e51b815260206004820152600d60248201526c496e76616c696420706861736560981b6044820152606401610c40565b611b303383612396565b611b4c5760405162461bcd60e51b8152600401610c409061331c565b611b58848484846127b5565b50505050565b6000818152600260205260409020546060906001600160a01b0316611bdd5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610c40565b6000611be76127e8565b90506000815111610bec57604051806020016040528060008152509392505050565b600260075403611c5b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610c40565b6002600755601a5462010000900460ff16611cb85760405162461bcd60e51b815260206004820152601b60248201527f4f70656e206d696e74696e67206973206e6f7420656e61626c656400000000006044820152606401610c40565b60008115611e125782601f54611cce9190613228565b6021546040516370a0823160e01b815233600482015291925082916001600160a01b03909116906370a0823190602401602060405180830381865afa158015611d1b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d3f919061323f565b1015611d8d5760405162461bcd60e51b815260206004820152601a60248201527f496e73756666696369656e7420746f6b656e207061796d656e740000000000006044820152606401610c40565b6021546020546040516323b872dd60e01b81523360048201526001600160a01b039182166024820152604481018490529116906323b872dd906064016020604051808303816000875af1158015611de8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e0c9190613258565b50611e83565b82601d54611e209190613228565b905080341015611e6d5760405162461bcd60e51b8152602060048201526018602482015277125b9cdd59999a58da595b9d08115512081c185e5b595b9d60421b6044820152606401610c40565b602054611e83906001600160a01b0316346120a8565b60085483611e90600b5490565b611e9a9190613275565b1115611ede5760405162461bcd60e51b8152602060048201526013602482015272135a5b9d081b1a5b5a5d08195e18d959591959606a1b6044820152606401610c40565b600083118015611ef057506009548311155b611f3c5760405162461bcd60e51b815260206004820181905260248201527f496e76616c6964206e756d626572206f6620746f6b656e7320746f206d696e746044820152606401610c40565b60005b83811015611f7f576000611f52600b5490565b9050611f62600b80546001019055565b611f6c33826122aa565b5080611f77816132b2565b915050611f3f565b505060016007555050565b600082815260066020526040902060010154611fa681336122c4565b61162f83836126b3565b60005b815181101561171e57611fde828281518110611fd157611fd161347b565b602002602001015161173d565b80611fe8816132b2565b915050611fb3565b6000611ffc81336122c4565b50602180546001600160a01b0319166001600160a01b0392909216919091179055565b600061202b81336122c4565b50600f55565b600061203d81336122c4565b50601a8054911515620100000262ff000019909216919091179055565b600061206681336122c4565b506001600160a01b03909116600090815260126020526040902055565b60006001600160e01b03198216637965db0b60e01b1480610bec5750610bec826127f7565b804710156120f85760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610c40565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612145576040519150601f19603f3d011682016040523d82523d6000602084013e61214a565b606091505b505090508061162f5760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610c40565b6001600160a01b038116600090815260018301602052604081205415155b9392505050565b600081815b855181101561228a5760008682815181106122085761220861347b565b6020026020010151905080831161224a576040805160208101859052908101829052606001604051602081830303815290604052805190602001209250612277565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b5080612282816132b2565b9150506121eb565b509092149392505050565b60006121df836001600160a01b038416612847565b61171e828260405180602001604052806000815250612896565b6122ce8282611965565b61171e576122e6816001600160a01b031660146128c9565b6122f18360206128c9565b604051602001612302929190613491565b60408051601f198184030181529082905262461bcd60e51b8252610c4091600401612e25565b600081815260046020526040902080546001600160a01b0319166001600160a01b038416908117909155819061235d82611843565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b031661240f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c40565b600061241a83611843565b9050806001600160a01b0316846001600160a01b031614806124555750836001600160a01b031661244a84611461565b6001600160a01b0316145b8061248557506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166124a082611843565b6001600160a01b0316146125085760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610c40565b6001600160a01b03821661256a5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c40565b612575600082612328565b6001600160a01b038316600090815260036020526040812080546001929061259e908490613506565b90915550506001600160a01b03821660009081526003602052604081208054600192906125cc908490613275565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6126378282611965565b61171e5760008281526006602090815260408083206001600160a01b03851684529091529020805460ff1916600117905561266f3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6126bd8282611965565b1561171e5760008281526006602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b600061272582611843565b9050612732600083612328565b6001600160a01b038116600090815260036020526040812080546001929061275b908490613506565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6127c084848461248d565b6127cc84848484612a65565b611b585760405162461bcd60e51b8152600401610c4090613519565b6060601b80546113de906132e2565b60006001600160e01b031982166380ac58cd60e01b148061282857506001600160e01b03198216635b5e139f60e01b145b80610bec57506301ffc9a760e01b6001600160e01b0319831614610bec565b600081815260018301602052604081205461288e57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610bec565b506000610bec565b6128a08383612b66565b6128ad6000848484612a65565b61162f5760405162461bcd60e51b8152600401610c4090613519565b606060006128d8836002613228565b6128e3906002613275565b67ffffffffffffffff8111156128fb576128fb612f42565b6040519080825280601f01601f191660200182016040528015612925576020820181803683370190505b509050600360fc1b816000815181106129405761294061347b565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061296f5761296f61347b565b60200101906001600160f81b031916908160001a9053506000612993846002613228565b61299e906001613275565b90505b6001811115612a16576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106129d2576129d261347b565b1a60f81b8282815181106129e8576129e861347b565b60200101906001600160f81b031916908160001a90535060049490941c93612a0f816132cb565b90506129a1565b5083156121df5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610c40565b60006001600160a01b0384163b15612b5b57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612aa990339089908890889060040161356b565b6020604051808303816000875af1925050508015612ae4575060408051601f3d908101601f19168201909252612ae1918101906135a8565b60015b612b41573d808015612b12576040519150601f19603f3d011682016040523d82523d6000602084013e612b17565b606091505b508051600003612b395760405162461bcd60e51b8152600401610c4090613519565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612485565b506001949350505050565b6001600160a01b038216612bbc5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c40565b6000818152600260205260409020546001600160a01b031615612c215760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c40565b6001600160a01b0382166000908152600360205260408120805460019290612c4a908490613275565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b0319811681146117b157600080fd5b600060208284031215612cd057600080fd5b81356121df81612ca8565b60008083601f840112612ced57600080fd5b50813567ffffffffffffffff811115612d0557600080fd5b6020830191508360208260051b8501011115612d2057600080fd5b9250929050565b80151581146117b157600080fd5b60008060008060008060008060c0898b031215612d5157600080fd5b883597506020890135965060408901359550606089013567ffffffffffffffff80821115612d7e57600080fd5b612d8a8c838d01612cdb565b909750955060808b0135915080821115612da357600080fd5b50612db08b828c01612cdb565b90945092505060a0890135612dc481612d27565b809150509295985092959890939650565b60005b83811015612df0578181015183820152602001612dd8565b50506000910152565b60008151808452612e11816020860160208601612dd5565b601f01601f19169290920160200192915050565b6020815260006121df6020830184612df9565b600060208284031215612e4a57600080fd5b5035919050565b6001600160a01b03811681146117b157600080fd5b60008060408385031215612e7957600080fd5b8235612e8481612e51565b946020939093013593505050565b600060208284031215612ea457600080fd5b81356121df81612e51565b60008060408385031215612ec257600080fd5b50508035926020909101359150565b600080600060608486031215612ee657600080fd5b8335612ef181612e51565b92506020840135612f0181612e51565b929592945050506040919091013590565b60008060408385031215612f2557600080fd5b823591506020830135612f3781612e51565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715612f8157612f81612f42565b604052919050565b600067ffffffffffffffff831115612fa357612fa3612f42565b612fb6601f8401601f1916602001612f58565b9050828152838383011115612fca57600080fd5b828260208301376000602084830101529392505050565b600060208284031215612ff357600080fd5b813567ffffffffffffffff81111561300a57600080fd5b8201601f8101841361301b57600080fd5b61248584823560208401612f89565b6000806040838503121561303d57600080fd5b823561304881612e51565b91506020830135612f3781612d27565b6000806040838503121561306b57600080fd5b823560ff8116811461304857600080fd5b6000806000806080858703121561309257600080fd5b843561309d81612e51565b935060208501356130ad81612e51565b925060408501359150606085013567ffffffffffffffff8111156130d057600080fd5b8501601f810187136130e157600080fd5b6130f087823560208401612f89565b91505092959194509250565b6000806040838503121561310f57600080fd5b823591506020830135612f3781612d27565b6000602080838503121561313457600080fd5b823567ffffffffffffffff8082111561314c57600080fd5b818501915085601f83011261316057600080fd5b81358181111561317257613172612f42565b8060051b9150613183848301612f58565b818152918301840191848101908884111561319d57600080fd5b938501935b838510156131bb578435825293850193908501906131a2565b98975050505050505050565b600080604083850312156131da57600080fd5b82356131e581612e51565b91506020830135612f3781612e51565b60006020828403121561320757600080fd5b81356121df81612d27565b634e487b7160e01b600052601160045260246000fd5b8082028115828204841417610bec57610bec613212565b60006020828403121561325157600080fd5b5051919050565b60006020828403121561326a57600080fd5b81516121df81612d27565b80820180821115610bec57610bec613212565b60208082526010908201526f13585e0814dd5c1c1b1e48131a5b5a5d60821b604082015260600190565b6000600182016132c4576132c4613212565b5060010190565b6000816132da576132da613212565b506000190190565b600181811c908216806132f657607f821691505b60208210810361331657634e487b7160e01b600052602260045260246000fd5b50919050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b601f82111561162f57600081815260208120601f850160051c810160208610156133945750805b601f850160051c820191505b818110156133b3578281556001016133a0565b505050505050565b815167ffffffffffffffff8111156133d5576133d5612f42565b6133e9816133e384546132e2565b8461336d565b602080601f83116001811461341e57600084156134065750858301515b600019600386901b1c1916600185901b1785556133b3565b600085815260208120601f198616915b8281101561344d5788860151825594840194600190910190840161342e565b508582101561346b5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052603260045260246000fd5b7f416363657373436f6e74726f6c3a206163636f756e74200000000000000000008152600083516134c9816017850160208801612dd5565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516134fa816028840160208801612dd5565b01602801949350505050565b81810381811115610bec57610bec613212565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061359e90830184612df9565b9695505050505050565b6000602082840312156135ba57600080fd5b81516121df81612ca856fea2646970667358221220ea794224c216472e3d3334eca60cb724cf1ba26006a45e9b30ad4a88c8c2476564736f6c63430008120033
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.