ERC-721
NFT
Overview
Max Total Supply
2,604 POE
Holders
977
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
1 POELoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
ProofOfEthereum
Compiler Version
v0.8.10+commit.fc410830
Optimization Enabled:
No with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity 0.8.10; import "ERC721A/contracts/extensions/ERC721AQueryable.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol"; contract ProofOfEthereum is ERC721AQueryable, Ownable, EIP712, ReentrancyGuard { using Strings for uint256; bytes32 public merkleRoot; mapping(address => bool) public whitelistClaimed; string public uriPrefix = ""; string public uriSuffix = ".json"; string public hiddenMetadataUri; uint256 public publicCost; uint256 public whitelistCost; uint256 public maxSupply; uint256 public maxMintAmountPerTxPublic; uint256 public maxMintAmountPerTxWhitelist; bool public paused = true; bool public whitelistMintEnabled = false; bool public revealed = false; address private treasuryAddress; address public signer; constructor( string memory _tokenName, string memory _tokenSymbol, uint256 _publicCost, uint256 _whitelistCost, uint256 _maxSupply, uint256 _maxMintAmountPerTxPublic, uint256 _maxMintAmountPerTxWhitelist, string memory _hiddenMetadataUri, address _treasuryAddress, address _signer ) EIP712("ProofOfEthereum", "1") ERC721A(_tokenName, _tokenSymbol) { setPublicCost(_publicCost); // 0.02604 setWhitelistCost(_whitelistCost); //0.03 maxSupply = _maxSupply; //2604 setMaxMintAmountPerTxPublic(_maxMintAmountPerTxPublic); // 4 setMaxMintAmountPerTxWhitelist(_maxMintAmountPerTxWhitelist); // 2 setHiddenMetadataUri(_hiddenMetadataUri); setTreasury(_treasuryAddress); setSigner(_signer); } modifier mintCompliancePublic(uint256 _mintAmount) { require( _mintAmount > 0 && _mintAmount <= maxMintAmountPerTxPublic, "Invalid mint amount!" ); require(totalSupply() + _mintAmount <= maxSupply, "Sold Out!"); _; } modifier mintComplianceWhitelist(uint256 _mintAmount) { require( _mintAmount > 0 && _mintAmount <= maxMintAmountPerTxWhitelist, "Invalid mint amount!" ); require(totalSupply() + _mintAmount <= maxSupply, "Sold out!"); _; } function whitelistMint(uint256 _mintAmount, bytes32[] calldata _merkleProof) public payable mintComplianceWhitelist(_mintAmount) { require( whitelistMintEnabled, "The whitelist sale has not started. Come check again later!" ); require( !whitelistClaimed[_msgSender()], "This address has already claimed their WL spot!" ); require( msg.value == whitelistCost * _mintAmount, "Insufficient funds!" ); bytes32 leaf = keccak256(abi.encodePacked(_msgSender())); require( MerkleProof.verify(_merkleProof, merkleRoot, leaf), "Invalid proof!" ); whitelistClaimed[_msgSender()] = true; _safeMint(_msgSender(), _mintAmount); (bool os, ) = payable(treasuryAddress).call{ value: address(this).balance }(""); require(os); } struct Voucher { address wallet; bytes signature; } function publicMint(Voucher calldata voucher, uint256 _mintAmount) public payable mintCompliancePublic(_mintAmount) { require(!paused, "The mint has been paused!"); require(msg.value == publicCost * _mintAmount, "Insufficient funds!"); _verifySignature(voucher); _safeMint(_msgSender(), _mintAmount); (bool os, ) = payable(treasuryAddress).call{ value: address(this).balance }(""); require(os); } function setSigner(address _signer) public onlyOwner { signer = _signer; } function _verifySignature(Voucher calldata voucher) internal view { bytes32 digest = _hashTypedDataV4( keccak256( abi.encode(keccak256("Approved(address wallet)"), _msgSender()) ) ); require( signer == ECDSA.recover(digest, voucher.signature), "Invalid signer" ); } function _startTokenId() internal view virtual override returns (uint256) { return 1; } function tokenURI(uint256 _tokenId) public view virtual override returns (string memory) { require( _exists(_tokenId), "ERC721Metadata: URI query for nonexistent token" ); if (revealed == false) { return hiddenMetadataUri; } string memory currentBaseURI = _baseURI(); return bytes(currentBaseURI).length > 0 ? string( abi.encodePacked( currentBaseURI, _tokenId.toString(), uriSuffix ) ) : ""; } function mintFromOwner(uint256 _mintAmount, address _receiver) external onlyOwner { require(totalSupply() + _mintAmount <= maxSupply, "Sold Out!"); _safeMint(_receiver, _mintAmount); } function setTreasury(address _treasury) public onlyOwner { treasuryAddress = _treasury; } function setPublicCost(uint256 _cost) public onlyOwner { publicCost = _cost; } function setWhitelistCost(uint256 _cost) public onlyOwner { whitelistCost = _cost; } function setMaxMintAmountPerTxPublic(uint256 _maxMintAmountPerTx) public onlyOwner { maxMintAmountPerTxPublic = _maxMintAmountPerTx; } function setMaxMintAmountPerTxWhitelist(uint256 _maxMintAmountPerTx) public onlyOwner { maxMintAmountPerTxWhitelist = _maxMintAmountPerTx; } function setHiddenMetadataUri(string memory _hiddenMetadataUri) public onlyOwner { hiddenMetadataUri = _hiddenMetadataUri; } function setUriPrefix(string memory _uriPrefix) public onlyOwner { uriPrefix = _uriPrefix; } function setUriSuffix(string memory _uriSuffix) public onlyOwner { uriSuffix = _uriSuffix; } function setPaused(bool _state) public onlyOwner { paused = _state; } function setMerkleRoot(bytes32 _merkleRoot) public onlyOwner { merkleRoot = _merkleRoot; } function setWhitelistMintEnabled(bool _state) public onlyOwner { whitelistMintEnabled = _state; } function setRevealed(bool _state) public onlyOwner { revealed = _state; } function withdraw() public onlyOwner nonReentrant { (bool os, ) = payable(treasuryAddress).call{ value: address(this).balance }(""); require(os); } function _baseURI() internal view virtual override returns (string memory) { return uriPrefix; } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721AQueryable.sol'; import '../ERC721A.sol'; /** * @title ERC721AQueryable. * * @dev ERC721A subclass with convenience query functions. */ abstract contract ERC721AQueryable is ERC721A, IERC721AQueryable { /** * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting. * * If the `tokenId` is out of bounds: * * - `addr = address(0)` * - `startTimestamp = 0` * - `burned = false` * - `extraData = 0` * * If the `tokenId` is burned: * * - `addr = <Address of owner before token was burned>` * - `startTimestamp = <Timestamp when token was burned>` * - `burned = true` * - `extraData = <Extra data when token was burned>` * * Otherwise: * * - `addr = <Address of owner>` * - `startTimestamp = <Timestamp of start of ownership>` * - `burned = false` * - `extraData = <Extra data at start of ownership>` */ function explicitOwnershipOf(uint256 tokenId) public view virtual override returns (TokenOwnership memory) { TokenOwnership memory ownership; if (tokenId < _startTokenId() || tokenId >= _nextTokenId()) { return ownership; } ownership = _ownershipAt(tokenId); if (ownership.burned) { return ownership; } return _ownershipOf(tokenId); } /** * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order. * See {ERC721AQueryable-explicitOwnershipOf} */ function explicitOwnershipsOf(uint256[] calldata tokenIds) external view virtual override returns (TokenOwnership[] memory) { unchecked { uint256 tokenIdsLength = tokenIds.length; TokenOwnership[] memory ownerships = new TokenOwnership[](tokenIdsLength); for (uint256 i; i != tokenIdsLength; ++i) { ownerships[i] = explicitOwnershipOf(tokenIds[i]); } return ownerships; } } /** * @dev Returns an array of token IDs owned by `owner`, * in the range [`start`, `stop`) * (i.e. `start <= tokenId < stop`). * * This function allows for tokens to be queried if the collection * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}. * * Requirements: * * - `start < stop` */ function tokensOfOwnerIn( address owner, uint256 start, uint256 stop ) external view virtual override returns (uint256[] memory) { unchecked { if (start >= stop) revert InvalidQueryRange(); uint256 tokenIdsIdx; uint256 stopLimit = _nextTokenId(); // Set `start = max(start, _startTokenId())`. if (start < _startTokenId()) { start = _startTokenId(); } // Set `stop = min(stop, stopLimit)`. if (stop > stopLimit) { stop = stopLimit; } uint256 tokenIdsMaxLength = balanceOf(owner); // Set `tokenIdsMaxLength = min(balanceOf(owner), stop - start)`, // to cater for cases where `balanceOf(owner)` is too big. if (start < stop) { uint256 rangeLength = stop - start; if (rangeLength < tokenIdsMaxLength) { tokenIdsMaxLength = rangeLength; } } else { tokenIdsMaxLength = 0; } uint256[] memory tokenIds = new uint256[](tokenIdsMaxLength); if (tokenIdsMaxLength == 0) { return tokenIds; } // We need to call `explicitOwnershipOf(start)`, // because the slot at `start` may not be initialized. TokenOwnership memory ownership = explicitOwnershipOf(start); address currOwnershipAddr; // If the starting slot exists (i.e. not burned), initialize `currOwnershipAddr`. // `ownership.address` will not be zero, as `start` is clamped to the valid token ID range. if (!ownership.burned) { currOwnershipAddr = ownership.addr; } for (uint256 i = start; i != stop && tokenIdsIdx != tokenIdsMaxLength; ++i) { ownership = _ownershipAt(i); if (ownership.burned) { continue; } if (ownership.addr != address(0)) { currOwnershipAddr = ownership.addr; } if (currOwnershipAddr == owner) { tokenIds[tokenIdsIdx++] = i; } } // Downsize the array to fit. assembly { mstore(tokenIds, tokenIdsIdx) } return tokenIds; } } /** * @dev Returns an array of token IDs owned by `owner`. * * This function scans the ownership mapping and is O(`totalSupply`) in complexity. * It is meant to be called off-chain. * * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into * multiple smaller scans if the collection is large enough to cause * an out-of-gas error (10K collections should be fine). */ function tokensOfOwner(address owner) external view virtual override returns (uint256[] memory) { unchecked { uint256 tokenIdsIdx; address currOwnershipAddr; uint256 tokenIdsLength = balanceOf(owner); uint256[] memory tokenIds = new uint256[](tokenIdsLength); TokenOwnership memory ownership; for (uint256 i = _startTokenId(); tokenIdsIdx != tokenIdsLength; ++i) { ownership = _ownershipAt(i); if (ownership.burned) { continue; } if (ownership.addr != address(0)) { currOwnershipAddr = ownership.addr; } if (currOwnershipAddr == owner) { tokenIds[tokenIdsIdx++] = i; } } return tokenIds; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @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); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) 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 making 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 // OpenZeppelin Contracts (last updated v4.7.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Tree proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. * * WARNING: You should avoid using leaf values that are 64 bytes long prior to * hashing, or use a hash function other than keccak256 for hashing leaves. * This is because the concatenation of a sorted pair of internal nodes in * the merkle tree could be reinterpreted as a leaf value. */ library 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) { return processProof(proof, leaf) == root; } /** * @dev Calldata version of {verify} * * _Available since v4.7._ */ function verifyCalldata( bytes32[] calldata proof, bytes32 root, bytes32 leaf ) internal pure returns (bool) { return processProofCalldata(proof, leaf) == root; } /** * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt * hash matches the root of the tree. When processing the proof, the pairs * of leafs & pre-images are assumed to be sorted. * * _Available since v4.4._ */ function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { computedHash = _hashPair(computedHash, proof[i]); } return computedHash; } /** * @dev Calldata version of {processProof} * * _Available since v4.7._ */ function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { computedHash = _hashPair(computedHash, proof[i]); } return computedHash; } /** * @dev Returns true if the `leaves` can be proved to be a part of a Merkle tree defined by * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}. * * _Available since v4.7._ */ function multiProofVerify( bytes32[] memory proof, bool[] memory proofFlags, bytes32 root, bytes32[] memory leaves ) internal pure returns (bool) { return processMultiProof(proof, proofFlags, leaves) == root; } /** * @dev Calldata version of {multiProofVerify} * * _Available since v4.7._ */ function multiProofVerifyCalldata( bytes32[] calldata proof, bool[] calldata proofFlags, bytes32 root, bytes32[] memory leaves ) internal pure returns (bool) { return processMultiProofCalldata(proof, proofFlags, leaves) == root; } /** * @dev Returns the root of a tree reconstructed from `leaves` and the sibling nodes in `proof`, * consuming from one or the other at each step according to the instructions given by * `proofFlags`. * * _Available since v4.7._ */ function processMultiProof( bytes32[] memory proof, bool[] memory proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of // the merkle tree. uint256 leavesLen = leaves.length; uint256 totalHashes = proofFlags.length; // Check proof validity. require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof"); // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop". bytes32[] memory hashes = new bytes32[](totalHashes); uint256 leafPos = 0; uint256 hashPos = 0; uint256 proofPos = 0; // At each step, we compute the next hash using two values: // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we // get the next hash. // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the // `proof` array. for (uint256 i = 0; i < totalHashes; i++) { bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]; bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++]; hashes[i] = _hashPair(a, b); } if (totalHashes > 0) { return hashes[totalHashes - 1]; } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } /** * @dev Calldata version of {processMultiProof} * * _Available since v4.7._ */ function processMultiProofCalldata( bytes32[] calldata proof, bool[] calldata proofFlags, bytes32[] memory leaves ) internal pure returns (bytes32 merkleRoot) { // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of // the merkle tree. uint256 leavesLen = leaves.length; uint256 totalHashes = proofFlags.length; // Check proof validity. require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof"); // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop". bytes32[] memory hashes = new bytes32[](totalHashes); uint256 leafPos = 0; uint256 hashPos = 0; uint256 proofPos = 0; // At each step, we compute the next hash using two values: // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we // get the next hash. // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the // `proof` array. for (uint256 i = 0; i < totalHashes; i++) { bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++]; bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++]; hashes[i] = _hashPair(a, b); } if (totalHashes > 0) { return hashes[totalHashes - 1]; } else if (leavesLen > 0) { return leaves[0]; } else { return proof[0]; } } function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) { return a < b ? _efficientHash(a, b) : _efficientHash(b, a); } function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) { /// @solidity memory-safe-assembly assembly { mstore(0x00, a) mstore(0x20, b) value := keccak256(0x00, 0x40) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/cryptography/draft-EIP712.sol) pragma solidity ^0.8.0; import "./ECDSA.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * _Available since v3.4._ */ abstract contract EIP712 { /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; uint256 private immutable _CACHED_CHAIN_ID; address private immutable _CACHED_THIS; bytes32 private immutable _HASHED_NAME; bytes32 private immutable _HASHED_VERSION; bytes32 private immutable _TYPE_HASH; /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ constructor(string memory name, string memory version) { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); bytes32 typeHash = keccak256( "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)" ); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; _CACHED_CHAIN_ID = block.chainid; _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion); _CACHED_THIS = address(this); _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) { return _CACHED_DOMAIN_SEPARATOR; } else { return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION); } } function _buildDomainSeparator( bytes32 typeHash, bytes32 nameHash, bytes32 versionHash ) private view returns (bytes32) { return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this))); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721A.sol'; /** * @dev Interface of ERC721 token receiver. */ interface ERC721A__IERC721Receiver { function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); } /** * @title ERC721A * * @dev Implementation of the [ERC721](https://eips.ethereum.org/EIPS/eip-721) * Non-Fungible Token Standard, including the Metadata extension. * Optimized for lower gas during batch mints. * * Token IDs are minted in sequential order (e.g. 0, 1, 2, 3, ...) * starting from `_startTokenId()`. * * Assumptions: * * - An owner cannot have more than 2**64 - 1 (max value of uint64) of supply. * - The maximum token ID cannot exceed 2**256 - 1 (max value of uint256). */ contract ERC721A is IERC721A { // Bypass for a `--via-ir` bug (https://github.com/chiru-labs/ERC721A/pull/364). struct TokenApprovalRef { address value; } // ============================================================= // CONSTANTS // ============================================================= // Mask of an entry in packed address data. uint256 private constant _BITMASK_ADDRESS_DATA_ENTRY = (1 << 64) - 1; // The bit position of `numberMinted` in packed address data. uint256 private constant _BITPOS_NUMBER_MINTED = 64; // The bit position of `numberBurned` in packed address data. uint256 private constant _BITPOS_NUMBER_BURNED = 128; // The bit position of `aux` in packed address data. uint256 private constant _BITPOS_AUX = 192; // Mask of all 256 bits in packed address data except the 64 bits for `aux`. uint256 private constant _BITMASK_AUX_COMPLEMENT = (1 << 192) - 1; // The bit position of `startTimestamp` in packed ownership. uint256 private constant _BITPOS_START_TIMESTAMP = 160; // The bit mask of the `burned` bit in packed ownership. uint256 private constant _BITMASK_BURNED = 1 << 224; // The bit position of the `nextInitialized` bit in packed ownership. uint256 private constant _BITPOS_NEXT_INITIALIZED = 225; // The bit mask of the `nextInitialized` bit in packed ownership. uint256 private constant _BITMASK_NEXT_INITIALIZED = 1 << 225; // The bit position of `extraData` in packed ownership. uint256 private constant _BITPOS_EXTRA_DATA = 232; // Mask of all 256 bits in a packed ownership except the 24 bits for `extraData`. uint256 private constant _BITMASK_EXTRA_DATA_COMPLEMENT = (1 << 232) - 1; // The mask of the lower 160 bits for addresses. uint256 private constant _BITMASK_ADDRESS = (1 << 160) - 1; // The maximum `quantity` that can be minted with {_mintERC2309}. // This limit is to prevent overflows on the address data entries. // For a limit of 5000, a total of 3.689e15 calls to {_mintERC2309} // is required to cause an overflow, which is unrealistic. uint256 private constant _MAX_MINT_ERC2309_QUANTITY_LIMIT = 5000; // The `Transfer` event signature is given by: // `keccak256(bytes("Transfer(address,address,uint256)"))`. bytes32 private constant _TRANSFER_EVENT_SIGNATURE = 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef; // ============================================================= // STORAGE // ============================================================= // The next token ID to be minted. uint256 private _currentIndex; // The number of tokens burned. uint256 private _burnCounter; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to ownership details // An empty struct value does not necessarily mean the token is unowned. // See {_packedOwnershipOf} implementation for details. // // Bits Layout: // - [0..159] `addr` // - [160..223] `startTimestamp` // - [224] `burned` // - [225] `nextInitialized` // - [232..255] `extraData` mapping(uint256 => uint256) private _packedOwnerships; // Mapping owner address to address data. // // Bits Layout: // - [0..63] `balance` // - [64..127] `numberMinted` // - [128..191] `numberBurned` // - [192..255] `aux` mapping(address => uint256) private _packedAddressData; // Mapping from token ID to approved address. mapping(uint256 => TokenApprovalRef) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; // ============================================================= // CONSTRUCTOR // ============================================================= constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; _currentIndex = _startTokenId(); } // ============================================================= // TOKEN COUNTING OPERATIONS // ============================================================= /** * @dev Returns the starting token ID. * To change the starting token ID, please override this function. */ function _startTokenId() internal view virtual returns (uint256) { return 0; } /** * @dev Returns the next token ID to be minted. */ function _nextTokenId() internal view virtual returns (uint256) { return _currentIndex; } /** * @dev Returns the total number of tokens in existence. * Burned tokens will reduce the count. * To get the total number of tokens minted, please see {_totalMinted}. */ function totalSupply() public view virtual override returns (uint256) { // Counter underflow is impossible as _burnCounter cannot be incremented // more than `_currentIndex - _startTokenId()` times. unchecked { return _currentIndex - _burnCounter - _startTokenId(); } } /** * @dev Returns the total amount of tokens minted in the contract. */ function _totalMinted() internal view virtual returns (uint256) { // Counter underflow is impossible as `_currentIndex` does not decrement, // and it is initialized to `_startTokenId()`. unchecked { return _currentIndex - _startTokenId(); } } /** * @dev Returns the total number of tokens burned. */ function _totalBurned() internal view virtual returns (uint256) { return _burnCounter; } // ============================================================= // ADDRESS DATA OPERATIONS // ============================================================= /** * @dev Returns the number of tokens in `owner`'s account. */ function balanceOf(address owner) public view virtual override returns (uint256) { if (owner == address(0)) revert BalanceQueryForZeroAddress(); return _packedAddressData[owner] & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens minted by `owner`. */ function _numberMinted(address owner) internal view returns (uint256) { return (_packedAddressData[owner] >> _BITPOS_NUMBER_MINTED) & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens burned by or on behalf of `owner`. */ function _numberBurned(address owner) internal view returns (uint256) { return (_packedAddressData[owner] >> _BITPOS_NUMBER_BURNED) & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the auxiliary data for `owner`. (e.g. number of whitelist mint slots used). */ function _getAux(address owner) internal view returns (uint64) { return uint64(_packedAddressData[owner] >> _BITPOS_AUX); } /** * Sets the auxiliary data for `owner`. (e.g. number of whitelist mint slots used). * If there are multiple variables, please pack them into a uint64. */ function _setAux(address owner, uint64 aux) internal virtual { uint256 packed = _packedAddressData[owner]; uint256 auxCasted; // Cast `aux` with assembly to avoid redundant masking. assembly { auxCasted := aux } packed = (packed & _BITMASK_AUX_COMPLEMENT) | (auxCasted << _BITPOS_AUX); _packedAddressData[owner] = packed; } // ============================================================= // IERC165 // ============================================================= /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified) * to learn more about how these ids are created. * * This function call must use less than 30000 gas. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { // The interface IDs are constants representing the first 4 bytes // of the XOR of all function selectors in the interface. // See: [ERC165](https://eips.ethereum.org/EIPS/eip-165) // (e.g. `bytes4(i.functionA.selector ^ i.functionB.selector ^ ...)`) return interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165. interfaceId == 0x80ac58cd || // ERC165 interface ID for ERC721. interfaceId == 0x5b5e139f; // ERC165 interface ID for ERC721Metadata. } // ============================================================= // IERC721Metadata // ============================================================= /** * @dev Returns the token collection name. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the token collection symbol. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { if (!_exists(tokenId)) revert URIQueryForNonexistentToken(); string memory baseURI = _baseURI(); return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, _toString(tokenId))) : ''; } /** * @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, it can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ''; } // ============================================================= // OWNERSHIPS OPERATIONS // ============================================================= /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { return address(uint160(_packedOwnershipOf(tokenId))); } /** * @dev Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around over time. */ function _ownershipOf(uint256 tokenId) internal view virtual returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnershipOf(tokenId)); } /** * @dev Returns the unpacked `TokenOwnership` struct at `index`. */ function _ownershipAt(uint256 index) internal view virtual returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnerships[index]); } /** * @dev Initializes the ownership slot minted at `index` for efficiency purposes. */ function _initializeOwnershipAt(uint256 index) internal virtual { if (_packedOwnerships[index] == 0) { _packedOwnerships[index] = _packedOwnershipOf(index); } } /** * Returns the packed ownership data of `tokenId`. */ function _packedOwnershipOf(uint256 tokenId) private view returns (uint256) { uint256 curr = tokenId; unchecked { if (_startTokenId() <= curr) if (curr < _currentIndex) { uint256 packed = _packedOwnerships[curr]; // If not burned. if (packed & _BITMASK_BURNED == 0) { // Invariant: // There will always be an initialized ownership slot // (i.e. `ownership.addr != address(0) && ownership.burned == false`) // before an unintialized ownership slot // (i.e. `ownership.addr == address(0) && ownership.burned == false`) // Hence, `curr` will not underflow. // // We can directly compare the packed value. // If the address is zero, packed will be zero. while (packed == 0) { packed = _packedOwnerships[--curr]; } return packed; } } } revert OwnerQueryForNonexistentToken(); } /** * @dev Returns the unpacked `TokenOwnership` struct from `packed`. */ function _unpackedOwnership(uint256 packed) private pure returns (TokenOwnership memory ownership) { ownership.addr = address(uint160(packed)); ownership.startTimestamp = uint64(packed >> _BITPOS_START_TIMESTAMP); ownership.burned = packed & _BITMASK_BURNED != 0; ownership.extraData = uint24(packed >> _BITPOS_EXTRA_DATA); } /** * @dev Packs ownership data into a single uint256. */ function _packOwnershipData(address owner, uint256 flags) private view returns (uint256 result) { assembly { // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean. owner := and(owner, _BITMASK_ADDRESS) // `owner | (block.timestamp << _BITPOS_START_TIMESTAMP) | flags`. result := or(owner, or(shl(_BITPOS_START_TIMESTAMP, timestamp()), flags)) } } /** * @dev Returns the `nextInitialized` flag set if `quantity` equals 1. */ function _nextInitializedFlag(uint256 quantity) private pure returns (uint256 result) { // For branchless setting of the `nextInitialized` flag. assembly { // `(quantity == 1) << _BITPOS_NEXT_INITIALIZED`. result := shl(_BITPOS_NEXT_INITIALIZED, eq(quantity, 1)) } } // ============================================================= // APPROVAL OPERATIONS // ============================================================= /** * @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) public payable virtual override { address owner = ownerOf(tokenId); if (_msgSenderERC721A() != owner) if (!isApprovedForAll(owner, _msgSenderERC721A())) { revert ApprovalCallerNotOwnerNorApproved(); } _tokenApprovals[tokenId].value = to; emit Approval(owner, to, tokenId); } /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return _tokenApprovals[tokenId].value; } /** * @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) public virtual override { _operatorApprovals[_msgSenderERC721A()][operator] = approved; emit ApprovalForAll(_msgSenderERC721A(), operator, approved); } /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @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. See {_mint}. */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _startTokenId() <= tokenId && tokenId < _currentIndex && // If within bounds, _packedOwnerships[tokenId] & _BITMASK_BURNED == 0; // and not burned. } /** * @dev Returns whether `msgSender` is equal to `approvedAddress` or `owner`. */ function _isSenderApprovedOrOwner( address approvedAddress, address owner, address msgSender ) private pure returns (bool result) { assembly { // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean. owner := and(owner, _BITMASK_ADDRESS) // Mask `msgSender` to the lower 160 bits, in case the upper bits somehow aren't clean. msgSender := and(msgSender, _BITMASK_ADDRESS) // `msgSender == owner || msgSender == approvedAddress`. result := or(eq(msgSender, owner), eq(msgSender, approvedAddress)) } } /** * @dev Returns the storage slot and value for the approved address of `tokenId`. */ function _getApprovedSlotAndAddress(uint256 tokenId) private view returns (uint256 approvedAddressSlot, address approvedAddress) { TokenApprovalRef storage tokenApproval = _tokenApprovals[tokenId]; // The following is equivalent to `approvedAddress = _tokenApprovals[tokenId].value`. assembly { approvedAddressSlot := tokenApproval.slot approvedAddress := sload(approvedAddressSlot) } } // ============================================================= // TRANSFER OPERATIONS // ============================================================= /** * @dev Transfers `tokenId` from `from` to `to`. * * 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 ) public payable virtual override { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); if (address(uint160(prevOwnershipPacked)) != from) revert TransferFromIncorrectOwner(); (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId); // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A())) if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved(); if (to == address(0)) revert TransferToZeroAddress(); _beforeTokenTransfers(from, to, tokenId, 1); // Clear approvals from the previous owner. assembly { if approvedAddress { // This is equivalent to `delete _tokenApprovals[tokenId]`. sstore(approvedAddressSlot, 0) } } // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256. unchecked { // We can directly increment and decrement the balances. --_packedAddressData[from]; // Updates: `balance -= 1`. ++_packedAddressData[to]; // Updates: `balance += 1`. // Updates: // - `address` to the next owner. // - `startTimestamp` to the timestamp of transfering. // - `burned` to `false`. // - `nextInitialized` to `true`. _packedOwnerships[tokenId] = _packOwnershipData( to, _BITMASK_NEXT_INITIALIZED | _nextExtraData(from, to, prevOwnershipPacked) ); // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (_packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != _currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. _packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, to, tokenId); _afterTokenTransfers(from, to, tokenId, 1); } /** * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public payable virtual override { safeTransferFrom(from, to, tokenId, ''); } /** * @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 memory _data ) public payable virtual override { transferFrom(from, to, tokenId); if (to.code.length != 0) if (!_checkContractOnERC721Received(from, to, tokenId, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } /** * @dev Hook that is called before a set of serially-ordered token IDs * are about to be transferred. This includes minting. * And also called before burning one token. * * `startTokenId` - the first token ID to be transferred. * `quantity` - the amount to be transferred. * * 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, `tokenId` will be burned by `from`. * - `from` and `to` are never both zero. */ function _beforeTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Hook that is called after a set of serially-ordered token IDs * have been transferred. This includes minting. * And also called after one token has been burned. * * `startTokenId` - the first token ID to be transferred. * `quantity` - the amount to be transferred. * * Calling conditions: * * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been * transferred to `to`. * - When `from` is zero, `tokenId` has been minted for `to`. * - When `to` is zero, `tokenId` has been burned by `from`. * - `from` and `to` are never both zero. */ function _afterTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target contract. * * `from` - Previous owner of the given token ID. * `to` - Target address that will receive the token. * `tokenId` - Token ID to be transferred. * `_data` - Optional data to send along with the call. * * Returns whether the call correctly returned the expected magic value. */ function _checkContractOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { try ERC721A__IERC721Receiver(to).onERC721Received(_msgSenderERC721A(), from, tokenId, _data) returns ( bytes4 retval ) { return retval == ERC721A__IERC721Receiver(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert TransferToNonERC721ReceiverImplementer(); } else { assembly { revert(add(32, reason), mload(reason)) } } } } // ============================================================= // MINT OPERATIONS // ============================================================= /** * @dev Mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {Transfer} event for each mint. */ function _mint(address to, uint256 quantity) internal virtual { uint256 startTokenId = _currentIndex; if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // `balance` and `numberMinted` have a maximum limit of 2**64. // `tokenId` has a maximum limit of 2**256. unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the `balance` and `numberMinted`. _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. _packedOwnerships[startTokenId] = _packOwnershipData( to, _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0) ); uint256 toMasked; uint256 end = startTokenId + quantity; // Use assembly to loop and emit the `Transfer` event for gas savings. // The duplicated `log4` removes an extra check and reduces stack juggling. // The assembly, together with the surrounding Solidity code, have been // delicately arranged to nudge the compiler into producing optimized opcodes. assembly { // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean. toMasked := and(to, _BITMASK_ADDRESS) // Emit the `Transfer` event. log4( 0, // Start of data (0, since no data). 0, // End of data (0, since no data). _TRANSFER_EVENT_SIGNATURE, // Signature. 0, // `address(0)`. toMasked, // `to`. startTokenId // `tokenId`. ) // The `iszero(eq(,))` check ensures that large values of `quantity` // that overflows uint256 will make the loop run out of gas. // The compiler will optimize the `iszero` away for performance. for { let tokenId := add(startTokenId, 1) } iszero(eq(tokenId, end)) { tokenId := add(tokenId, 1) } { // Emit the `Transfer` event. Similar to above. log4(0, 0, _TRANSFER_EVENT_SIGNATURE, 0, toMasked, tokenId) } } if (toMasked == 0) revert MintToZeroAddress(); _currentIndex = end; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Mints `quantity` tokens and transfers them to `to`. * * This function is intended for efficient minting only during contract creation. * * It emits only one {ConsecutiveTransfer} as defined in * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309), * instead of a sequence of {Transfer} event(s). * * Calling this function outside of contract creation WILL make your contract * non-compliant with the ERC721 standard. * For full ERC721 compliance, substituting ERC721 {Transfer} event(s) with the ERC2309 * {ConsecutiveTransfer} event is only permissible during contract creation. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {ConsecutiveTransfer} event. */ function _mintERC2309(address to, uint256 quantity) internal virtual { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); if (quantity > _MAX_MINT_ERC2309_QUANTITY_LIMIT) revert MintERC2309QuantityExceedsLimit(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are unrealistic due to the above check for `quantity` to be below the limit. unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the `balance` and `numberMinted`. _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. _packedOwnerships[startTokenId] = _packOwnershipData( to, _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0) ); emit ConsecutiveTransfer(startTokenId, startTokenId + quantity - 1, address(0), to); _currentIndex = startTokenId + quantity; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Safely mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - If `to` refers to a smart contract, it must implement * {IERC721Receiver-onERC721Received}, which is called for each safe transfer. * - `quantity` must be greater than 0. * * See {_mint}. * * Emits a {Transfer} event for each mint. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal virtual { _mint(to, quantity); unchecked { if (to.code.length != 0) { uint256 end = _currentIndex; uint256 index = end - quantity; do { if (!_checkContractOnERC721Received(address(0), to, index++, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } while (index < end); // Reentrancy protection. if (_currentIndex != end) revert(); } } } /** * @dev Equivalent to `_safeMint(to, quantity, '')`. */ function _safeMint(address to, uint256 quantity) internal virtual { _safeMint(to, quantity, ''); } // ============================================================= // BURN OPERATIONS // ============================================================= /** * @dev Equivalent to `_burn(tokenId, false)`. */ function _burn(uint256 tokenId) internal virtual { _burn(tokenId, false); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId, bool approvalCheck) internal virtual { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); address from = address(uint160(prevOwnershipPacked)); (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId); if (approvalCheck) { // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A())) if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved(); } _beforeTokenTransfers(from, address(0), tokenId, 1); // Clear approvals from the previous owner. assembly { if approvedAddress { // This is equivalent to `delete _tokenApprovals[tokenId]`. sstore(approvedAddressSlot, 0) } } // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256. unchecked { // Updates: // - `balance -= 1`. // - `numberBurned += 1`. // // We can directly decrement the balance, and increment the number burned. // This is equivalent to `packed -= 1; packed += 1 << _BITPOS_NUMBER_BURNED;`. _packedAddressData[from] += (1 << _BITPOS_NUMBER_BURNED) - 1; // Updates: // - `address` to the last owner. // - `startTimestamp` to the timestamp of burning. // - `burned` to `true`. // - `nextInitialized` to `true`. _packedOwnerships[tokenId] = _packOwnershipData( from, (_BITMASK_BURNED | _BITMASK_NEXT_INITIALIZED) | _nextExtraData(from, address(0), prevOwnershipPacked) ); // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (_packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != _currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. _packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, address(0), tokenId); _afterTokenTransfers(from, address(0), tokenId, 1); // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times. unchecked { _burnCounter++; } } // ============================================================= // EXTRA DATA OPERATIONS // ============================================================= /** * @dev Directly sets the extra data for the ownership data `index`. */ function _setExtraDataAt(uint256 index, uint24 extraData) internal virtual { uint256 packed = _packedOwnerships[index]; if (packed == 0) revert OwnershipNotInitializedForExtraData(); uint256 extraDataCasted; // Cast `extraData` with assembly to avoid redundant masking. assembly { extraDataCasted := extraData } packed = (packed & _BITMASK_EXTRA_DATA_COMPLEMENT) | (extraDataCasted << _BITPOS_EXTRA_DATA); _packedOwnerships[index] = packed; } /** * @dev Called during each token transfer to set the 24bit `extraData` field. * Intended to be overridden by the cosumer contract. * * `previousExtraData` - the value of `extraData` before transfer. * * 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, `tokenId` will be burned by `from`. * - `from` and `to` are never both zero. */ function _extraData( address from, address to, uint24 previousExtraData ) internal view virtual returns (uint24) {} /** * @dev Returns the next extra data for the packed ownership data. * The returned result is shifted into position. */ function _nextExtraData( address from, address to, uint256 prevOwnershipPacked ) private view returns (uint256) { uint24 extraData = uint24(prevOwnershipPacked >> _BITPOS_EXTRA_DATA); return uint256(_extraData(from, to, extraData)) << _BITPOS_EXTRA_DATA; } // ============================================================= // OTHER OPERATIONS // ============================================================= /** * @dev Returns the message sender (defaults to `msg.sender`). * * If you are writing GSN compatible contracts, you need to override this function. */ function _msgSenderERC721A() internal view virtual returns (address) { return msg.sender; } /** * @dev Converts a uint256 to its ASCII string decimal representation. */ function _toString(uint256 value) internal pure virtual returns (string memory str) { assembly { // The maximum value of a uint256 contains 78 digits (1 byte per digit), but // we allocate 0xa0 bytes to keep the free memory pointer 32-byte word aligned. // We will need 1 word for the trailing zeros padding, 1 word for the length, // and 3 words for a maximum of 78 digits. Total: 5 * 0x20 = 0xa0. let m := add(mload(0x40), 0xa0) // Update the free memory pointer to allocate. mstore(0x40, m) // Assign the `str` to the end. str := sub(m, 0x20) // Zeroize the slot after the string. mstore(str, 0) // Cache the end of the memory to calculate the length later. let end := str // We write the string from rightmost digit to leftmost digit. // The following is essentially a do-while loop that also handles the zero case. // prettier-ignore for { let temp := value } 1 {} { str := sub(str, 1) // Write the character to the pointer. // The ASCII index of the '0' character is 48. mstore8(str, add(48, mod(temp, 10))) // Keep dividing `temp` until zero. temp := div(temp, 10) // prettier-ignore if iszero(temp) { break } } let length := sub(end, str) // Move the pointer 32 bytes leftwards to make room for the length. str := sub(str, 0x20) // Store the length. mstore(str, length) } } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import '../IERC721A.sol'; /** * @dev Interface of ERC721AQueryable. */ interface IERC721AQueryable is IERC721A { /** * Invalid query range (`start` >= `stop`). */ error InvalidQueryRange(); /** * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting. * * If the `tokenId` is out of bounds: * * - `addr = address(0)` * - `startTimestamp = 0` * - `burned = false` * - `extraData = 0` * * If the `tokenId` is burned: * * - `addr = <Address of owner before token was burned>` * - `startTimestamp = <Timestamp when token was burned>` * - `burned = true` * - `extraData = <Extra data when token was burned>` * * Otherwise: * * - `addr = <Address of owner>` * - `startTimestamp = <Timestamp of start of ownership>` * - `burned = false` * - `extraData = <Extra data at start of ownership>` */ function explicitOwnershipOf(uint256 tokenId) external view returns (TokenOwnership memory); /** * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order. * See {ERC721AQueryable-explicitOwnershipOf} */ function explicitOwnershipsOf(uint256[] memory tokenIds) external view returns (TokenOwnership[] memory); /** * @dev Returns an array of token IDs owned by `owner`, * in the range [`start`, `stop`) * (i.e. `start <= tokenId < stop`). * * This function allows for tokens to be queried if the collection * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}. * * Requirements: * * - `start < stop` */ function tokensOfOwnerIn( address owner, uint256 start, uint256 stop ) external view returns (uint256[] memory); /** * @dev Returns an array of token IDs owned by `owner`. * * This function scans the ownership mapping and is O(`totalSupply`) in complexity. * It is meant to be called off-chain. * * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into * multiple smaller scans if the collection is large enough to cause * an out-of-gas error (10K collections should be fine). */ function tokensOfOwner(address owner) external view returns (uint256[] memory); }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; /** * @dev Interface of ERC721A. */ interface IERC721A { /** * The caller must own the token or be an approved operator. */ error ApprovalCallerNotOwnerNorApproved(); /** * The token does not exist. */ error ApprovalQueryForNonexistentToken(); /** * Cannot query the balance for the zero address. */ error BalanceQueryForZeroAddress(); /** * Cannot mint to the zero address. */ error MintToZeroAddress(); /** * The quantity of tokens minted must be more than zero. */ error MintZeroQuantity(); /** * The token does not exist. */ error OwnerQueryForNonexistentToken(); /** * The caller must own the token or be an approved operator. */ error TransferCallerNotOwnerNorApproved(); /** * The token must be owned by `from`. */ error TransferFromIncorrectOwner(); /** * Cannot safely transfer to a contract that does not implement the * ERC721Receiver interface. */ error TransferToNonERC721ReceiverImplementer(); /** * Cannot transfer to the zero address. */ error TransferToZeroAddress(); /** * The token does not exist. */ error URIQueryForNonexistentToken(); /** * The `quantity` minted with ERC2309 exceeds the safety limit. */ error MintERC2309QuantityExceedsLimit(); /** * The `extraData` cannot be set on an unintialized ownership slot. */ error OwnershipNotInitializedForExtraData(); // ============================================================= // STRUCTS // ============================================================= struct TokenOwnership { // The address of the owner. address addr; // Stores the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; // Arbitrary data similar to `startTimestamp` that can be set via {_extraData}. uint24 extraData; } // ============================================================= // TOKEN COUNTERS // ============================================================= /** * @dev Returns the total number of tokens in existence. * Burned tokens will reduce the count. * To get the total number of tokens minted, please see {_totalMinted}. */ function totalSupply() external view returns (uint256); // ============================================================= // IERC165 // ============================================================= /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified) * to learn more about how these ids are created. * * This function call must use less than 30000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); // ============================================================= // IERC721 // ============================================================= /** * @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, bytes calldata data ) external payable; /** * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external payable; /** * @dev Transfers `tokenId` 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 payable; /** * @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 payable; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} * for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll}. */ function isApprovedForAll(address owner, address operator) external view returns (bool); // ============================================================= // IERC721Metadata // ============================================================= /** * @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); // ============================================================= // IERC2309 // ============================================================= /** * @dev Emitted when tokens in `fromTokenId` to `toTokenId` * (inclusive) is transferred from `from` to `to`, as defined in the * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309) standard. * * See {_mintERC2309} for more details. */ event ConsecutiveTransfer(uint256 indexed fromTokenId, uint256 toTokenId, address indexed from, address indexed to); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.3) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; import "../Strings.sol"; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } else if (error == RecoverError.InvalidSignatureV) { revert("ECDSA: invalid signature 'v' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. /// @solidity memory-safe-assembly assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); uint8 v = uint8((uint256(vs) >> 255) + 27); return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } if (v != 27 && v != 28) { return (address(0), RecoverError.InvalidSignatureV); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { // 32 is the length in bytes of hash, // enforced by the type signature above return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); } /** * @dev Returns an Ethereum Signed Message, created from `s`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } }
{ "optimizer": { "enabled": false, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"_tokenName","type":"string"},{"internalType":"string","name":"_tokenSymbol","type":"string"},{"internalType":"uint256","name":"_publicCost","type":"uint256"},{"internalType":"uint256","name":"_whitelistCost","type":"uint256"},{"internalType":"uint256","name":"_maxSupply","type":"uint256"},{"internalType":"uint256","name":"_maxMintAmountPerTxPublic","type":"uint256"},{"internalType":"uint256","name":"_maxMintAmountPerTxWhitelist","type":"uint256"},{"internalType":"string","name":"_hiddenMetadataUri","type":"string"},{"internalType":"address","name":"_treasuryAddress","type":"address"},{"internalType":"address","name":"_signer","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"InvalidQueryRange","type":"error"},{"inputs":[],"name":"MintERC2309QuantityExceedsLimit","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"OwnershipNotInitializedForExtraData","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","type":"error"},{"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":"uint256","name":"fromTokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"toTokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"ConsecutiveTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"payable","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":"tokenId","type":"uint256"}],"name":"explicitOwnershipOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"explicitOwnershipsOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"hiddenMetadataUri","outputs":[{"internalType":"string","name":"","type":"string"}],"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":"maxMintAmountPerTxPublic","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxMintAmountPerTxWhitelist","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintAmount","type":"uint256"},{"internalType":"address","name":"_receiver","type":"address"}],"name":"mintFromOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"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":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicCost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes","name":"signature","type":"bytes"}],"internalType":"struct ProofOfEthereum.Voucher","name":"voucher","type":"tuple"},{"internalType":"uint256","name":"_mintAmount","type":"uint256"}],"name":"publicMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"revealed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","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":"payable","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":"payable","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":"_hiddenMetadataUri","type":"string"}],"name":"setHiddenMetadataUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxMintAmountPerTx","type":"uint256"}],"name":"setMaxMintAmountPerTxPublic","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxMintAmountPerTx","type":"uint256"}],"name":"setMaxMintAmountPerTxWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_state","type":"bool"}],"name":"setPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_cost","type":"uint256"}],"name":"setPublicCost","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_state","type":"bool"}],"name":"setRevealed","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_signer","type":"address"}],"name":"setSigner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_treasury","type":"address"}],"name":"setTreasury","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_uriPrefix","type":"string"}],"name":"setUriPrefix","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_uriSuffix","type":"string"}],"name":"setUriSuffix","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_cost","type":"uint256"}],"name":"setWhitelistCost","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_state","type":"bool"}],"name":"setWhitelistMintEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"signer","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","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":"uint256","name":"_tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"tokensOfOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"stop","type":"uint256"}],"name":"tokensOfOwnerIn","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","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":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"uriPrefix","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"uriSuffix","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistClaimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistCost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintAmount","type":"uint256"},{"internalType":"bytes32[]","name":"_merkleProof","type":"bytes32[]"}],"name":"whitelistMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"whitelistMintEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
61014060405260405180602001604052806000815250600c90805190602001906200002c92919062000629565b506040518060400160405280600581526020017f2e6a736f6e000000000000000000000000000000000000000000000000000000815250600d90805190602001906200007a92919062000629565b506001601460006101000a81548160ff0219169083151502179055506000601460016101000a81548160ff0219169083151502179055506000601460026101000a81548160ff021916908315150217905550348015620000d957600080fd5b50604051620061da380380620061da8339818101604052810190620000ff919062000916565b6040518060400160405280600f81526020017f50726f6f664f66457468657265756d00000000000000000000000000000000008152506040518060400160405280600181526020017f31000000000000000000000000000000000000000000000000000000000000008152508b8b81600290805190602001906200018592919062000629565b5080600390805190602001906200019e92919062000629565b50620001af6200031f60201b60201c565b6000819055505050620001d7620001cb6200032860201b60201c565b6200033060201b60201c565b60008280519060200120905060008280519060200120905060007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f90508260e081815250508161010081815250504660a0818152505062000240818484620003f660201b60201c565b608081815250503073ffffffffffffffffffffffffffffffffffffffff1660c08173ffffffffffffffffffffffffffffffffffffffff168152505080610120818152505050505050506001600981905550620002a2886200043260201b60201c565b620002b3876200044c60201b60201c565b85601181905550620002cb856200046660201b60201c565b620002dc846200048060201b60201c565b620002ed836200049a60201b60201c565b620002fe82620004c660201b60201c565b6200030f816200051a60201b60201c565b5050505050505050505062000beb565b60006001905090565b600033905090565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600083838346306040516020016200041395949392919062000aa6565b6040516020818303038152906040528051906020012090509392505050565b620004426200056e60201b60201c565b80600f8190555050565b6200045c6200056e60201b60201c565b8060108190555050565b620004766200056e60201b60201c565b8060128190555050565b620004906200056e60201b60201c565b8060138190555050565b620004aa6200056e60201b60201c565b80600e9080519060200190620004c292919062000629565b5050565b620004d66200056e60201b60201c565b80601460036101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6200052a6200056e60201b60201c565b80601560006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6200057e6200032860201b60201c565b73ffffffffffffffffffffffffffffffffffffffff16620005a4620005ff60201b60201c565b73ffffffffffffffffffffffffffffffffffffffff1614620005fd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401620005f49062000b64565b60405180910390fd5b565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b828054620006379062000bb5565b90600052602060002090601f0160209004810192826200065b5760008555620006a7565b82601f106200067657805160ff1916838001178555620006a7565b82800160010185558215620006a7579182015b82811115620006a657825182559160200191906001019062000689565b5b509050620006b69190620006ba565b5090565b5b80821115620006d5576000816000905550600101620006bb565b5090565b6000604051905090565b600080fd5b600080fd5b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6200074282620006f7565b810181811067ffffffffffffffff8211171562000764576200076362000708565b5b80604052505050565b600062000779620006d9565b905062000787828262000737565b919050565b600067ffffffffffffffff821115620007aa57620007a962000708565b5b620007b582620006f7565b9050602081019050919050565b60005b83811015620007e2578082015181840152602081019050620007c5565b83811115620007f2576000848401525b50505050565b60006200080f62000809846200078c565b6200076d565b9050828152602081018484840111156200082e576200082d620006f2565b5b6200083b848285620007c2565b509392505050565b600082601f8301126200085b576200085a620006ed565b5b81516200086d848260208601620007f8565b91505092915050565b6000819050919050565b6200088b8162000876565b81146200089757600080fd5b50565b600081519050620008ab8162000880565b92915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620008de82620008b1565b9050919050565b620008f081620008d1565b8114620008fc57600080fd5b50565b6000815190506200091081620008e5565b92915050565b6000806000806000806000806000806101408b8d0312156200093d576200093c620006e3565b5b60008b015167ffffffffffffffff8111156200095e576200095d620006e8565b5b6200096c8d828e0162000843565b9a505060208b015167ffffffffffffffff81111562000990576200098f620006e8565b5b6200099e8d828e0162000843565b9950506040620009b18d828e016200089a565b9850506060620009c48d828e016200089a565b9750506080620009d78d828e016200089a565b96505060a0620009ea8d828e016200089a565b95505060c0620009fd8d828e016200089a565b94505060e08b015167ffffffffffffffff81111562000a215762000a20620006e8565b5b62000a2f8d828e0162000843565b93505061010062000a438d828e01620008ff565b92505061012062000a578d828e01620008ff565b9150509295989b9194979a5092959850565b6000819050919050565b62000a7e8162000a69565b82525050565b62000a8f8162000876565b82525050565b62000aa081620008d1565b82525050565b600060a08201905062000abd600083018862000a73565b62000acc602083018762000a73565b62000adb604083018662000a73565b62000aea606083018562000a84565b62000af9608083018462000a95565b9695505050505050565b600082825260208201905092915050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b600062000b4c60208362000b03565b915062000b598262000b14565b602082019050919050565b6000602082019050818103600083015262000b7f8162000b3d565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168062000bce57607f821691505b6020821081141562000be55762000be462000b86565b5b50919050565b60805160a05160c05160e051610100516101205161559f62000c3b600039600061326d015260006132af0152600061328e015260006131c30152600061321901526000613242015261559f6000f3fe6080604052600436106102ff5760003560e01c80637722762211610190578063c23dc68f116100dc578063dab4a87611610095578063e7b99ec71161006f578063e7b99ec714610b2a578063e985e9c514610b55578063f0f4426014610b92578063f2fde38b14610bbb576102ff565b8063dab4a87614610a99578063db4bec4414610ac4578063e0a8085314610b01576102ff565b8063c23dc68f14610986578063c87b56dd146109c3578063d2cab05614610a00578063d49479eb14610a1c578063d4c9b92214610a45578063d5abeb0114610a6e576102ff565b80638da5cb5b11610149578063a22cb46511610123578063a22cb465146108ed578063a45ba8e714610916578063b767a09814610941578063b88d4fde1461096a576102ff565b80638da5cb5b1461085a57806395d89b411461088557806399a2557a146108b0576102ff565b8063772276221461075b5780637cb64759146107775780637ec4a659146107a0578063811d2437146107c95780638462151c146107f25780638693da201461082f576102ff565b806348a1c3a31161024f5780635c975abb116102085780636c19e783116101e25780636c19e783146106b35780636caede3d146106dc57806370a0823114610707578063715018a614610744576102ff565b80635c975abb1461062057806362b99ad41461064b5780636352211e14610676576102ff565b806348a1c3a3146105105780634a342320146105395780634fdd43cb14610564578063518302271461058d5780635503a0e8146105b85780635bbb2177146105e3576102ff565b806316c38b3c116102bc57806323b872dd1161029657806323b872dd146104965780632eb4a7ab146104b25780633ccfd60b146104dd57806342842e0e146104f4576102ff565b806316c38b3c1461041757806318160ddd14610440578063238ac9331461046b576102ff565b806301ffc9a71461030457806304c61a5f1461034157806306fdde031461036a578063081812fc14610395578063095ea7b3146103d257806316ba10e0146103ee575b600080fd5b34801561031057600080fd5b5061032b600480360381019061032691906139e7565b610be4565b6040516103389190613a2f565b60405180910390f35b34801561034d57600080fd5b5061036860048036038101906103639190613a80565b610c76565b005b34801561037657600080fd5b5061037f610c88565b60405161038c9190613b46565b60405180910390f35b3480156103a157600080fd5b506103bc60048036038101906103b79190613a80565b610d1a565b6040516103c99190613ba9565b60405180910390f35b6103ec60048036038101906103e79190613bf0565b610d99565b005b3480156103fa57600080fd5b5061041560048036038101906104109190613d65565b610edd565b005b34801561042357600080fd5b5061043e60048036038101906104399190613dda565b610eff565b005b34801561044c57600080fd5b50610455610f24565b6040516104629190613e16565b60405180910390f35b34801561047757600080fd5b50610480610f3b565b60405161048d9190613ba9565b60405180910390f35b6104b060048036038101906104ab9190613e31565b610f61565b005b3480156104be57600080fd5b506104c7611286565b6040516104d49190613e9d565b60405180910390f35b3480156104e957600080fd5b506104f261128c565b005b61050e60048036038101906105099190613e31565b611385565b005b34801561051c57600080fd5b5061053760048036038101906105329190613a80565b6113a5565b005b34801561054557600080fd5b5061054e6113b7565b60405161055b9190613e16565b60405180910390f35b34801561057057600080fd5b5061058b60048036038101906105869190613d65565b6113bd565b005b34801561059957600080fd5b506105a26113df565b6040516105af9190613a2f565b60405180910390f35b3480156105c457600080fd5b506105cd6113f2565b6040516105da9190613b46565b60405180910390f35b3480156105ef57600080fd5b5061060a60048036038101906106059190613f18565b611480565b60405161061791906140c8565b60405180910390f35b34801561062c57600080fd5b50610635611543565b6040516106429190613a2f565b60405180910390f35b34801561065757600080fd5b50610660611556565b60405161066d9190613b46565b60405180910390f35b34801561068257600080fd5b5061069d60048036038101906106989190613a80565b6115e4565b6040516106aa9190613ba9565b60405180910390f35b3480156106bf57600080fd5b506106da60048036038101906106d591906140ea565b6115f6565b005b3480156106e857600080fd5b506106f1611642565b6040516106fe9190613a2f565b60405180910390f35b34801561071357600080fd5b5061072e600480360381019061072991906140ea565b611655565b60405161073b9190613e16565b60405180910390f35b34801561075057600080fd5b5061075961170e565b005b6107756004803603810190610770919061413b565b611722565b005b34801561078357600080fd5b5061079e600480360381019061079991906141c3565b611922565b005b3480156107ac57600080fd5b506107c760048036038101906107c29190613d65565b611934565b005b3480156107d557600080fd5b506107f060048036038101906107eb9190613a80565b611956565b005b3480156107fe57600080fd5b50610819600480360381019061081491906140ea565b611968565b60405161082691906142ae565b60405180910390f35b34801561083b57600080fd5b50610844611ab2565b6040516108519190613e16565b60405180910390f35b34801561086657600080fd5b5061086f611ab8565b60405161087c9190613ba9565b60405180910390f35b34801561089157600080fd5b5061089a611ae2565b6040516108a79190613b46565b60405180910390f35b3480156108bc57600080fd5b506108d760048036038101906108d291906142d0565b611b74565b6040516108e491906142ae565b60405180910390f35b3480156108f957600080fd5b50610914600480360381019061090f9190614323565b611d88565b005b34801561092257600080fd5b5061092b611e93565b6040516109389190613b46565b60405180910390f35b34801561094d57600080fd5b5061096860048036038101906109639190613dda565b611f21565b005b610984600480360381019061097f9190614404565b611f46565b005b34801561099257600080fd5b506109ad60048036038101906109a89190613a80565b611fb9565b6040516109ba91906144dc565b60405180910390f35b3480156109cf57600080fd5b506109ea60048036038101906109e59190613a80565b612023565b6040516109f79190613b46565b60405180910390f35b610a1a6004803603810190610a15919061454d565b61217c565b005b348015610a2857600080fd5b50610a436004803603810190610a3e9190613a80565b612526565b005b348015610a5157600080fd5b50610a6c6004803603810190610a6791906145ad565b612538565b005b348015610a7a57600080fd5b50610a836125a5565b604051610a909190613e16565b60405180910390f35b348015610aa557600080fd5b50610aae6125ab565b604051610abb9190613e16565b60405180910390f35b348015610ad057600080fd5b50610aeb6004803603810190610ae691906140ea565b6125b1565b604051610af89190613a2f565b60405180910390f35b348015610b0d57600080fd5b50610b286004803603810190610b239190613dda565b6125d1565b005b348015610b3657600080fd5b50610b3f6125f6565b604051610b4c9190613e16565b60405180910390f35b348015610b6157600080fd5b50610b7c6004803603810190610b7791906145ed565b6125fc565b604051610b899190613a2f565b60405180910390f35b348015610b9e57600080fd5b50610bb96004803603810190610bb491906140ea565b612690565b005b348015610bc757600080fd5b50610be26004803603810190610bdd91906140ea565b6126dc565b005b60006301ffc9a760e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480610c3f57506380ac58cd60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80610c6f5750635b5e139f60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b9050919050565b610c7e612760565b8060138190555050565b606060028054610c979061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054610cc39061465c565b8015610d105780601f10610ce557610100808354040283529160200191610d10565b820191906000526020600020905b815481529060010190602001808311610cf357829003601f168201915b5050505050905090565b6000610d25826127de565b610d5b576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006600083815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6000610da4826115e4565b90508073ffffffffffffffffffffffffffffffffffffffff16610dc561283d565b73ffffffffffffffffffffffffffffffffffffffff1614610e2857610df181610dec61283d565b6125fc565b610e27576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b826006600084815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b610ee5612760565b80600d9080519060200190610efb929190613889565b5050565b610f07612760565b80601460006101000a81548160ff02191690831515021790555050565b6000610f2e612845565b6001546000540303905090565b601560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000610f6c8261284e565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610fd3576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080610fdf8461291c565b91509150610ff58187610ff061283d565b612943565b6110415761100a8661100561283d565b6125fc565b611040576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156110a8576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110b58686866001612987565b80156110c057600082555b600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001900391905081905550600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001019190508190555061118e8561116a88888761298d565b7c0200000000000000000000000000000000000000000000000000000000176129b5565b600460008681526020019081526020016000208190555060007c020000000000000000000000000000000000000000000000000000000084161415611216576000600185019050600060046000838152602001908152602001600020541415611214576000548114611213578360046000838152602001908152602001600020819055505b5b505b838573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a461127e86868660016129e0565b505050505050565b600a5481565b611294612760565b600260095414156112da576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016112d1906146da565b60405180910390fd5b60026009819055506000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff164760405161132a9061472b565b60006040518083038185875af1925050503d8060008114611367576040519150601f19603f3d011682016040523d82523d6000602084013e61136c565b606091505b505090508061137a57600080fd5b506001600981905550565b6113a083838360405180602001604052806000815250611f46565b505050565b6113ad612760565b8060128190555050565b60125481565b6113c5612760565b80600e90805190602001906113db929190613889565b5050565b601460029054906101000a900460ff1681565b600d80546113ff9061465c565b80601f016020809104026020016040519081016040528092919081815260200182805461142b9061465c565b80156114785780601f1061144d57610100808354040283529160200191611478565b820191906000526020600020905b81548152906001019060200180831161145b57829003601f168201915b505050505081565b6060600083839050905060008167ffffffffffffffff8111156114a6576114a5613c3a565b5b6040519080825280602002602001820160405280156114df57816020015b6114cc61390f565b8152602001906001900390816114c45790505b50905060005b8281146115375761150e86868381811061150257611501614740565b5b90506020020135611fb9565b82828151811061152157611520614740565b5b60200260200101819052508060010190506114e5565b50809250505092915050565b601460009054906101000a900460ff1681565b600c80546115639061465c565b80601f016020809104026020016040519081016040528092919081815260200182805461158f9061465c565b80156115dc5780601f106115b1576101008083540402835291602001916115dc565b820191906000526020600020905b8154815290600101906020018083116115bf57829003601f168201915b505050505081565b60006115ef8261284e565b9050919050565b6115fe612760565b80601560006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b601460019054906101000a900460ff1681565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156116bd576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054169050919050565b611716612760565b61172060006129e6565b565b8060008111801561173557506012548111155b611774576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161176b906147bb565b60405180910390fd5b60115481611780610f24565b61178a919061480a565b11156117cb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117c2906148ac565b60405180910390fd5b601460009054906101000a900460ff161561181b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161181290614918565b60405180910390fd5b81600f546118299190614938565b341461186a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611861906149de565b60405180910390fd5b61187383612aac565b61188461187e612bf7565b83612bff565b6000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16476040516118cc9061472b565b60006040518083038185875af1925050503d8060008114611909576040519150601f19603f3d011682016040523d82523d6000602084013e61190e565b606091505b505090508061191c57600080fd5b50505050565b61192a612760565b80600a8190555050565b61193c612760565b80600c9080519060200190611952929190613889565b5050565b61195e612760565b80600f8190555050565b6060600080600061197885611655565b905060008167ffffffffffffffff81111561199657611995613c3a565b5b6040519080825280602002602001820160405280156119c45781602001602082028036833780820191505090505b5090506119cf61390f565b60006119d9612845565b90505b838614611aa4576119ec81612c1d565b91508160400151156119fd57611a99565b600073ffffffffffffffffffffffffffffffffffffffff16826000015173ffffffffffffffffffffffffffffffffffffffff1614611a3d57816000015194505b8773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611a985780838780600101985081518110611a8b57611a8a614740565b5b6020026020010181815250505b5b8060010190506119dc565b508195505050505050919050565b600f5481565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060038054611af19061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054611b1d9061465c565b8015611b6a5780601f10611b3f57610100808354040283529160200191611b6a565b820191906000526020600020905b815481529060010190602001808311611b4d57829003601f168201915b5050505050905090565b6060818310611baf576040517f32c1995a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080611bba612c48565b9050611bc4612845565b851015611bd657611bd3612845565b94505b80841115611be2578093505b6000611bed87611655565b905084861015611c10576000868603905081811015611c0a578091505b50611c15565b600090505b60008167ffffffffffffffff811115611c3157611c30613c3a565b5b604051908082528060200260200182016040528015611c5f5781602001602082028036833780820191505090505b5090506000821415611c775780945050505050611d81565b6000611c8288611fb9565b905060008160400151611c9757816000015190505b60008990505b888114158015611cad5750848714155b15611d7357611cbb81612c1d565b9250826040015115611ccc57611d68565b600073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614611d0c57826000015191505b8a73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611d675780848880600101995081518110611d5a57611d59614740565b5b6020026020010181815250505b5b806001019050611c9d565b508583528296505050505050505b9392505050565b8060076000611d9561283d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16611e4261283d565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051611e879190613a2f565b60405180910390a35050565b600e8054611ea09061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054611ecc9061465c565b8015611f195780601f10611eee57610100808354040283529160200191611f19565b820191906000526020600020905b815481529060010190602001808311611efc57829003601f168201915b505050505081565b611f29612760565b80601460016101000a81548160ff02191690831515021790555050565b611f51848484610f61565b60008373ffffffffffffffffffffffffffffffffffffffff163b14611fb357611f7c84848484612c51565b611fb2576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50505050565b611fc161390f565b611fc961390f565b611fd1612845565b831080611fe55750611fe1612c48565b8310155b15611ff3578091505061201e565b611ffc83612c1d565b9050806040015115612011578091505061201e565b61201a83612da2565b9150505b919050565b606061202e826127de565b61206d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161206490614a70565b60405180910390fd5b60001515601460029054906101000a900460ff161515141561211b57600e80546120969061465c565b80601f01602080910402602001604051908101604052809291908181526020018280546120c29061465c565b801561210f5780601f106120e45761010080835404028352916020019161210f565b820191906000526020600020905b8154815290600101906020018083116120f257829003601f168201915b50505050509050612177565b6000612125612dc2565b905060008151116121455760405180602001604052806000815250612173565b8061214f84612e54565b600d60405160200161216393929190614b60565b6040516020818303038152906040525b9150505b919050565b8260008111801561218f57506013548111155b6121ce576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121c5906147bb565b60405180910390fd5b601154816121da610f24565b6121e4919061480a565b1115612225576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161221c90614bdd565b60405180910390fd5b601460019054906101000a900460ff16612274576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161226b90614c6f565b60405180910390fd5b600b6000612280612bf7565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615612308576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ff90614d01565b60405180910390fd5b836010546123169190614938565b3414612357576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161234e906149de565b60405180910390fd5b6000612361612bf7565b6040516020016123719190614d69565b6040516020818303038152906040528051906020012090506123d7848480806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600a5483612fb5565b612416576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161240d90614dd0565b60405180910390fd5b6001600b6000612424612bf7565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612486612480612bf7565b86612bff565b6000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16476040516124ce9061472b565b60006040518083038185875af1925050503d806000811461250b576040519150601f19603f3d011682016040523d82523d6000602084013e612510565b606091505b505090508061251e57600080fd5b505050505050565b61252e612760565b8060108190555050565b612540612760565b6011548261254c610f24565b612556919061480a565b1115612597576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161258e906148ac565b60405180910390fd5b6125a18183612bff565b5050565b60115481565b60135481565b600b6020528060005260406000206000915054906101000a900460ff1681565b6125d9612760565b80601460026101000a81548160ff02191690831515021790555050565b60105481565b6000600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b612698612760565b80601460036101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6126e4612760565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415612754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161274b90614e62565b60405180910390fd5b61275d816129e6565b50565b612768612bf7565b73ffffffffffffffffffffffffffffffffffffffff16612786611ab8565b73ffffffffffffffffffffffffffffffffffffffff16146127dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127d390614ece565b60405180910390fd5b565b6000816127e9612845565b111580156127f8575060005482105b8015612836575060007c0100000000000000000000000000000000000000000000000000000000600460008581526020019081526020016000205416145b9050919050565b600033905090565b60006001905090565b6000808290508061285d612845565b116128e5576000548110156128e45760006004600083815260200190815260200160002054905060007c0100000000000000000000000000000000000000000000000000000000821614156128e2575b60008114156128d85760046000836001900393508381526020019081526020016000205490506128ad565b8092505050612917565b505b5b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b919050565b60008060006006600085815260200190815260200160002090508092508254915050915091565b600073ffffffffffffffffffffffffffffffffffffffff8316925073ffffffffffffffffffffffffffffffffffffffff821691508382148383141790509392505050565b50505050565b60008060e883901c905060e86129a4868684612fcc565b62ffffff16901b9150509392505050565b600073ffffffffffffffffffffffffffffffffffffffff83169250814260a01b178317905092915050565b50505050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6000612b067fb793c547937a9a126a37f7d386b60ec9d3215c4cc65f40901d5268fdad7f9baf612ada612bf7565b604051602001612aeb929190614eee565b60405160208183030381529060405280519060200120612fd5565b9050612b6481838060200190612b1c9190614f26565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050612fef565b73ffffffffffffffffffffffffffffffffffffffff16601560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612bf3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bea90614fd5565b60405180910390fd5b5050565b600033905090565b612c19828260405180602001604052806000815250613016565b5050565b612c2561390f565b612c4160046000848152602001908152602001600020546130b3565b9050919050565b60008054905090565b60008373ffffffffffffffffffffffffffffffffffffffff1663150b7a02612c7761283d565b8786866040518563ffffffff1660e01b8152600401612c99949392919061504a565b6020604051808303816000875af1925050508015612cd557506040513d601f19601f82011682018060405250810190612cd291906150ab565b60015b612d4f573d8060008114612d05576040519150601f19603f3d011682016040523d82523d6000602084013e612d0a565b606091505b50600081511415612d47576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614915050949350505050565b612daa61390f565b612dbb612db68361284e565b6130b3565b9050919050565b6060600c8054612dd19061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054612dfd9061465c565b8015612e4a5780601f10612e1f57610100808354040283529160200191612e4a565b820191906000526020600020905b815481529060010190602001808311612e2d57829003601f168201915b5050505050905090565b60606000821415612e9c576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050612fb0565b600082905060005b60008214612ece578080612eb7906150d8565b915050600a82612ec79190615150565b9150612ea4565b60008167ffffffffffffffff811115612eea57612ee9613c3a565b5b6040519080825280601f01601f191660200182016040528015612f1c5781602001600182028036833780820191505090505b5090505b60008514612fa957600182612f359190615181565b9150600a85612f4491906151b5565b6030612f50919061480a565b60f81b818381518110612f6657612f65614740565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a85612fa29190615150565b9450612f20565b8093505050505b919050565b600082612fc28584613169565b1490509392505050565b60009392505050565b6000612fe8612fe26131bf565b836132d9565b9050919050565b6000806000612ffe858561330c565b9150915061300b8161335e565b819250505092915050565b6130208383613533565b60008373ffffffffffffffffffffffffffffffffffffffff163b146130ae57600080549050600083820390505b6130606000868380600101945086612c51565b613096576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81811061304d5781600054146130ab57600080fd5b50505b505050565b6130bb61390f565b81816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060a082901c816020019067ffffffffffffffff16908167ffffffffffffffff168152505060007c01000000000000000000000000000000000000000000000000000000008316141581604001901515908115158152505060e882901c816060019062ffffff16908162ffffff1681525050919050565b60008082905060005b84518110156131b45761319f8286838151811061319257613191614740565b5b60200260200101516136f0565b915080806131ac906150d8565b915050613172565b508091505092915050565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1614801561323b57507f000000000000000000000000000000000000000000000000000000000000000046145b15613268577f000000000000000000000000000000000000000000000000000000000000000090506132d6565b6132d37f00000000000000000000000000000000000000000000000000000000000000007f00000000000000000000000000000000000000000000000000000000000000007f000000000000000000000000000000000000000000000000000000000000000061371b565b90505b90565b600082826040516020016132ee929190615253565b60405160208183030381529060405280519060200120905092915050565b60008060418351141561334e5760008060006020860151925060408601519150606086015160001a905061334287828585613755565b94509450505050613357565b60006002915091505b9250929050565b600060048111156133725761337161528a565b5b8160048111156133855761338461528a565b5b141561339057613530565b600160048111156133a4576133a361528a565b5b8160048111156133b7576133b661528a565b5b14156133f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016133ef90615305565b60405180910390fd5b6002600481111561340c5761340b61528a565b5b81600481111561341f5761341e61528a565b5b1415613460576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161345790615371565b60405180910390fd5b600360048111156134745761347361528a565b5b8160048111156134875761348661528a565b5b14156134c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134bf90615403565b60405180910390fd5b6004808111156134db576134da61528a565b5b8160048111156134ee576134ed61528a565b5b141561352f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161352690615495565b60405180910390fd5b5b50565b6000805490506000821415613574576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6135816000848385612987565b600160406001901b178202600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055506135f8836135e9600086600061298d565b6135f285613862565b176129b5565b6004600083815260200190815260200160002081905550600080838301905073ffffffffffffffffffffffffffffffffffffffff85169150828260007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600183015b81811461369957808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a460018101905061365e565b5060008214156136d5576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008190555050506136eb60008483856129e0565b505050565b6000818310613708576137038284613872565b613713565b6137128383613872565b5b905092915050565b600083838346306040516020016137369594939291906154b5565b6040516020818303038152906040528051906020012090509392505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08360001c1115613790576000600391509150613859565b601b8560ff16141580156137a85750601c8560ff1614155b156137ba576000600491509150613859565b6000600187878787604051600081526020016040526040516137df9493929190615524565b6020604051602081039080840390855afa158015613801573d6000803e3d6000fd5b505050602060405103519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141561385057600060019250925050613859565b80600092509250505b94509492505050565b60006001821460e11b9050919050565b600082600052816020526040600020905092915050565b8280546138959061465c565b90600052602060002090601f0160209004810192826138b757600085556138fe565b82601f106138d057805160ff19168380011785556138fe565b828001600101855582156138fe579182015b828111156138fd5782518255916020019190600101906138e2565b5b50905061390b919061395e565b5090565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600067ffffffffffffffff168152602001600015158152602001600062ffffff1681525090565b5b8082111561397757600081600090555060010161395f565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6139c48161398f565b81146139cf57600080fd5b50565b6000813590506139e1816139bb565b92915050565b6000602082840312156139fd576139fc613985565b5b6000613a0b848285016139d2565b91505092915050565b60008115159050919050565b613a2981613a14565b82525050565b6000602082019050613a446000830184613a20565b92915050565b6000819050919050565b613a5d81613a4a565b8114613a6857600080fd5b50565b600081359050613a7a81613a54565b92915050565b600060208284031215613a9657613a95613985565b5b6000613aa484828501613a6b565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613ae7578082015181840152602081019050613acc565b83811115613af6576000848401525b50505050565b6000601f19601f8301169050919050565b6000613b1882613aad565b613b228185613ab8565b9350613b32818560208601613ac9565b613b3b81613afc565b840191505092915050565b60006020820190508181036000830152613b608184613b0d565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613b9382613b68565b9050919050565b613ba381613b88565b82525050565b6000602082019050613bbe6000830184613b9a565b92915050565b613bcd81613b88565b8114613bd857600080fd5b50565b600081359050613bea81613bc4565b92915050565b60008060408385031215613c0757613c06613985565b5b6000613c1585828601613bdb565b9250506020613c2685828601613a6b565b9150509250929050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b613c7282613afc565b810181811067ffffffffffffffff82111715613c9157613c90613c3a565b5b80604052505050565b6000613ca461397b565b9050613cb08282613c69565b919050565b600067ffffffffffffffff821115613cd057613ccf613c3a565b5b613cd982613afc565b9050602081019050919050565b82818337600083830152505050565b6000613d08613d0384613cb5565b613c9a565b905082815260208101848484011115613d2457613d23613c35565b5b613d2f848285613ce6565b509392505050565b600082601f830112613d4c57613d4b613c30565b5b8135613d5c848260208601613cf5565b91505092915050565b600060208284031215613d7b57613d7a613985565b5b600082013567ffffffffffffffff811115613d9957613d9861398a565b5b613da584828501613d37565b91505092915050565b613db781613a14565b8114613dc257600080fd5b50565b600081359050613dd481613dae565b92915050565b600060208284031215613df057613def613985565b5b6000613dfe84828501613dc5565b91505092915050565b613e1081613a4a565b82525050565b6000602082019050613e2b6000830184613e07565b92915050565b600080600060608486031215613e4a57613e49613985565b5b6000613e5886828701613bdb565b9350506020613e6986828701613bdb565b9250506040613e7a86828701613a6b565b9150509250925092565b6000819050919050565b613e9781613e84565b82525050565b6000602082019050613eb26000830184613e8e565b92915050565b600080fd5b600080fd5b60008083601f840112613ed857613ed7613c30565b5b8235905067ffffffffffffffff811115613ef557613ef4613eb8565b5b602083019150836020820283011115613f1157613f10613ebd565b5b9250929050565b60008060208385031215613f2f57613f2e613985565b5b600083013567ffffffffffffffff811115613f4d57613f4c61398a565b5b613f5985828601613ec2565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b613f9a81613b88565b82525050565b600067ffffffffffffffff82169050919050565b613fbd81613fa0565b82525050565b613fcc81613a14565b82525050565b600062ffffff82169050919050565b613fea81613fd2565b82525050565b6080820160008201516140066000850182613f91565b5060208201516140196020850182613fb4565b50604082015161402c6040850182613fc3565b50606082015161403f6060850182613fe1565b50505050565b60006140518383613ff0565b60808301905092915050565b6000602082019050919050565b600061407582613f65565b61407f8185613f70565b935061408a83613f81565b8060005b838110156140bb5781516140a28882614045565b97506140ad8361405d565b92505060018101905061408e565b5085935050505092915050565b600060208201905081810360008301526140e2818461406a565b905092915050565b600060208284031215614100576140ff613985565b5b600061410e84828501613bdb565b91505092915050565b600080fd5b60006040828403121561413257614131614117565b5b81905092915050565b6000806040838503121561415257614151613985565b5b600083013567ffffffffffffffff8111156141705761416f61398a565b5b61417c8582860161411c565b925050602061418d85828601613a6b565b9150509250929050565b6141a081613e84565b81146141ab57600080fd5b50565b6000813590506141bd81614197565b92915050565b6000602082840312156141d9576141d8613985565b5b60006141e7848285016141ae565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61422581613a4a565b82525050565b6000614237838361421c565b60208301905092915050565b6000602082019050919050565b600061425b826141f0565b61426581856141fb565b93506142708361420c565b8060005b838110156142a1578151614288888261422b565b975061429383614243565b925050600181019050614274565b5085935050505092915050565b600060208201905081810360008301526142c88184614250565b905092915050565b6000806000606084860312156142e9576142e8613985565b5b60006142f786828701613bdb565b935050602061430886828701613a6b565b925050604061431986828701613a6b565b9150509250925092565b6000806040838503121561433a57614339613985565b5b600061434885828601613bdb565b925050602061435985828601613dc5565b9150509250929050565b600067ffffffffffffffff82111561437e5761437d613c3a565b5b61438782613afc565b9050602081019050919050565b60006143a76143a284614363565b613c9a565b9050828152602081018484840111156143c3576143c2613c35565b5b6143ce848285613ce6565b509392505050565b600082601f8301126143eb576143ea613c30565b5b81356143fb848260208601614394565b91505092915050565b6000806000806080858703121561441e5761441d613985565b5b600061442c87828801613bdb565b945050602061443d87828801613bdb565b935050604061444e87828801613a6b565b925050606085013567ffffffffffffffff81111561446f5761446e61398a565b5b61447b878288016143d6565b91505092959194509250565b60808201600082015161449d6000850182613f91565b5060208201516144b06020850182613fb4565b5060408201516144c36040850182613fc3565b5060608201516144d66060850182613fe1565b50505050565b60006080820190506144f16000830184614487565b92915050565b60008083601f84011261450d5761450c613c30565b5b8235905067ffffffffffffffff81111561452a57614529613eb8565b5b60208301915083602082028301111561454657614545613ebd565b5b9250929050565b60008060006040848603121561456657614565613985565b5b600061457486828701613a6b565b935050602084013567ffffffffffffffff8111156145955761459461398a565b5b6145a1868287016144f7565b92509250509250925092565b600080604083850312156145c4576145c3613985565b5b60006145d285828601613a6b565b92505060206145e385828601613bdb565b9150509250929050565b6000806040838503121561460457614603613985565b5b600061461285828601613bdb565b925050602061462385828601613bdb565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061467457607f821691505b602082108114156146885761468761462d565b5b50919050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b60006146c4601f83613ab8565b91506146cf8261468e565b602082019050919050565b600060208201905081810360008301526146f3816146b7565b9050919050565b600081905092915050565b50565b60006147156000836146fa565b915061472082614705565b600082019050919050565b600061473682614708565b9150819050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f496e76616c6964206d696e7420616d6f756e7421000000000000000000000000600082015250565b60006147a5601483613ab8565b91506147b08261476f565b602082019050919050565b600060208201905081810360008301526147d481614798565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061481582613a4a565b915061482083613a4a565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115614855576148546147db565b5b828201905092915050565b7f536f6c64204f7574210000000000000000000000000000000000000000000000600082015250565b6000614896600983613ab8565b91506148a182614860565b602082019050919050565b600060208201905081810360008301526148c581614889565b9050919050565b7f546865206d696e7420686173206265656e207061757365642100000000000000600082015250565b6000614902601983613ab8565b915061490d826148cc565b602082019050919050565b60006020820190508181036000830152614931816148f5565b9050919050565b600061494382613a4a565b915061494e83613a4a565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614987576149866147db565b5b828202905092915050565b7f496e73756666696369656e742066756e64732100000000000000000000000000600082015250565b60006149c8601383613ab8565b91506149d382614992565b602082019050919050565b600060208201905081810360008301526149f7816149bb565b9050919050565b7f4552433732314d657461646174613a2055524920717565727920666f72206e6f60008201527f6e6578697374656e7420746f6b656e0000000000000000000000000000000000602082015250565b6000614a5a602f83613ab8565b9150614a65826149fe565b604082019050919050565b60006020820190508181036000830152614a8981614a4d565b9050919050565b600081905092915050565b6000614aa682613aad565b614ab08185614a90565b9350614ac0818560208601613ac9565b80840191505092915050565b60008190508160005260206000209050919050565b60008154614aee8161465c565b614af88186614a90565b94506001821660008114614b135760018114614b2457614b57565b60ff19831686528186019350614b57565b614b2d85614acc565b60005b83811015614b4f57815481890152600182019150602081019050614b30565b838801955050505b50505092915050565b6000614b6c8286614a9b565b9150614b788285614a9b565b9150614b848284614ae1565b9150819050949350505050565b7f536f6c64206f7574210000000000000000000000000000000000000000000000600082015250565b6000614bc7600983613ab8565b9150614bd282614b91565b602082019050919050565b60006020820190508181036000830152614bf681614bba565b9050919050565b7f5468652077686974656c6973742073616c6520686173206e6f7420737461727460008201527f65642e20436f6d6520636865636b20616761696e206c61746572210000000000602082015250565b6000614c59603b83613ab8565b9150614c6482614bfd565b604082019050919050565b60006020820190508181036000830152614c8881614c4c565b9050919050565b7f5468697320616464726573732068617320616c726561647920636c61696d656460008201527f20746865697220574c2073706f74210000000000000000000000000000000000602082015250565b6000614ceb602f83613ab8565b9150614cf682614c8f565b604082019050919050565b60006020820190508181036000830152614d1a81614cde565b9050919050565b60008160601b9050919050565b6000614d3982614d21565b9050919050565b6000614d4b82614d2e565b9050919050565b614d63614d5e82613b88565b614d40565b82525050565b6000614d758284614d52565b60148201915081905092915050565b7f496e76616c69642070726f6f6621000000000000000000000000000000000000600082015250565b6000614dba600e83613ab8565b9150614dc582614d84565b602082019050919050565b60006020820190508181036000830152614de981614dad565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614e4c602683613ab8565b9150614e5782614df0565b604082019050919050565b60006020820190508181036000830152614e7b81614e3f565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614eb8602083613ab8565b9150614ec382614e82565b602082019050919050565b60006020820190508181036000830152614ee781614eab565b9050919050565b6000604082019050614f036000830185613e8e565b614f106020830184613b9a565b9392505050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112614f4357614f42614f17565b5b80840192508235915067ffffffffffffffff821115614f6557614f64614f1c565b5b602083019250600182023603831315614f8157614f80614f21565b5b509250929050565b7f496e76616c6964207369676e6572000000000000000000000000000000000000600082015250565b6000614fbf600e83613ab8565b9150614fca82614f89565b602082019050919050565b60006020820190508181036000830152614fee81614fb2565b9050919050565b600081519050919050565b600082825260208201905092915050565b600061501c82614ff5565b6150268185615000565b9350615036818560208601613ac9565b61503f81613afc565b840191505092915050565b600060808201905061505f6000830187613b9a565b61506c6020830186613b9a565b6150796040830185613e07565b818103606083015261508b8184615011565b905095945050505050565b6000815190506150a5816139bb565b92915050565b6000602082840312156150c1576150c0613985565b5b60006150cf84828501615096565b91505092915050565b60006150e382613a4a565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415615116576151156147db565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061515b82613a4a565b915061516683613a4a565b92508261517657615175615121565b5b828204905092915050565b600061518c82613a4a565b915061519783613a4a565b9250828210156151aa576151a96147db565b5b828203905092915050565b60006151c082613a4a565b91506151cb83613a4a565b9250826151db576151da615121565b5b828206905092915050565b7f1901000000000000000000000000000000000000000000000000000000000000600082015250565b600061521c600283614a90565b9150615227826151e6565b600282019050919050565b6000819050919050565b61524d61524882613e84565b615232565b82525050565b600061525e8261520f565b915061526a828561523c565b60208201915061527a828461523c565b6020820191508190509392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f45434453413a20696e76616c6964207369676e61747572650000000000000000600082015250565b60006152ef601883613ab8565b91506152fa826152b9565b602082019050919050565b6000602082019050818103600083015261531e816152e2565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265206c656e67746800600082015250565b600061535b601f83613ab8565b915061536682615325565b602082019050919050565b6000602082019050818103600083015261538a8161534e565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202773272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b60006153ed602283613ab8565b91506153f882615391565b604082019050919050565b6000602082019050818103600083015261541c816153e0565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202776272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b600061547f602283613ab8565b915061548a82615423565b604082019050919050565b600060208201905081810360008301526154ae81615472565b9050919050565b600060a0820190506154ca6000830188613e8e565b6154d76020830187613e8e565b6154e46040830186613e8e565b6154f16060830185613e07565b6154fe6080830184613b9a565b9695505050505050565b600060ff82169050919050565b61551e81615508565b82525050565b60006080820190506155396000830187613e8e565b6155466020830186615515565b6155536040830185613e8e565b6155606060830184613e8e565b9594505050505056fea2646970667358221220cb2904d4d3fac3b931c1e184b7e41d078383e6a0656ab034ff0cc3610ed9ab1864736f6c634300080a003300000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000006a94d74f430000000000000000000000000000000000000000000000000000005c833df5f380000000000000000000000000000000000000000000000000000000000000000a2c0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000b73578ab7c6516bdd021f2b03b8407fe1cd03265000000000000000000000000f7bbff6839913758b769dab742a68ebcff49c393000000000000000000000000000000000000000000000000000000000000000f50726f6f664f66457468657265756d00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003504f4500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000042697066733a2f2f6261666b7265696766363663777933357a68686969717a72736e65797963656f70377078687a6d71346c3579376d7474723463616537726c697079000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106102ff5760003560e01c80637722762211610190578063c23dc68f116100dc578063dab4a87611610095578063e7b99ec71161006f578063e7b99ec714610b2a578063e985e9c514610b55578063f0f4426014610b92578063f2fde38b14610bbb576102ff565b8063dab4a87614610a99578063db4bec4414610ac4578063e0a8085314610b01576102ff565b8063c23dc68f14610986578063c87b56dd146109c3578063d2cab05614610a00578063d49479eb14610a1c578063d4c9b92214610a45578063d5abeb0114610a6e576102ff565b80638da5cb5b11610149578063a22cb46511610123578063a22cb465146108ed578063a45ba8e714610916578063b767a09814610941578063b88d4fde1461096a576102ff565b80638da5cb5b1461085a57806395d89b411461088557806399a2557a146108b0576102ff565b8063772276221461075b5780637cb64759146107775780637ec4a659146107a0578063811d2437146107c95780638462151c146107f25780638693da201461082f576102ff565b806348a1c3a31161024f5780635c975abb116102085780636c19e783116101e25780636c19e783146106b35780636caede3d146106dc57806370a0823114610707578063715018a614610744576102ff565b80635c975abb1461062057806362b99ad41461064b5780636352211e14610676576102ff565b806348a1c3a3146105105780634a342320146105395780634fdd43cb14610564578063518302271461058d5780635503a0e8146105b85780635bbb2177146105e3576102ff565b806316c38b3c116102bc57806323b872dd1161029657806323b872dd146104965780632eb4a7ab146104b25780633ccfd60b146104dd57806342842e0e146104f4576102ff565b806316c38b3c1461041757806318160ddd14610440578063238ac9331461046b576102ff565b806301ffc9a71461030457806304c61a5f1461034157806306fdde031461036a578063081812fc14610395578063095ea7b3146103d257806316ba10e0146103ee575b600080fd5b34801561031057600080fd5b5061032b600480360381019061032691906139e7565b610be4565b6040516103389190613a2f565b60405180910390f35b34801561034d57600080fd5b5061036860048036038101906103639190613a80565b610c76565b005b34801561037657600080fd5b5061037f610c88565b60405161038c9190613b46565b60405180910390f35b3480156103a157600080fd5b506103bc60048036038101906103b79190613a80565b610d1a565b6040516103c99190613ba9565b60405180910390f35b6103ec60048036038101906103e79190613bf0565b610d99565b005b3480156103fa57600080fd5b5061041560048036038101906104109190613d65565b610edd565b005b34801561042357600080fd5b5061043e60048036038101906104399190613dda565b610eff565b005b34801561044c57600080fd5b50610455610f24565b6040516104629190613e16565b60405180910390f35b34801561047757600080fd5b50610480610f3b565b60405161048d9190613ba9565b60405180910390f35b6104b060048036038101906104ab9190613e31565b610f61565b005b3480156104be57600080fd5b506104c7611286565b6040516104d49190613e9d565b60405180910390f35b3480156104e957600080fd5b506104f261128c565b005b61050e60048036038101906105099190613e31565b611385565b005b34801561051c57600080fd5b5061053760048036038101906105329190613a80565b6113a5565b005b34801561054557600080fd5b5061054e6113b7565b60405161055b9190613e16565b60405180910390f35b34801561057057600080fd5b5061058b60048036038101906105869190613d65565b6113bd565b005b34801561059957600080fd5b506105a26113df565b6040516105af9190613a2f565b60405180910390f35b3480156105c457600080fd5b506105cd6113f2565b6040516105da9190613b46565b60405180910390f35b3480156105ef57600080fd5b5061060a60048036038101906106059190613f18565b611480565b60405161061791906140c8565b60405180910390f35b34801561062c57600080fd5b50610635611543565b6040516106429190613a2f565b60405180910390f35b34801561065757600080fd5b50610660611556565b60405161066d9190613b46565b60405180910390f35b34801561068257600080fd5b5061069d60048036038101906106989190613a80565b6115e4565b6040516106aa9190613ba9565b60405180910390f35b3480156106bf57600080fd5b506106da60048036038101906106d591906140ea565b6115f6565b005b3480156106e857600080fd5b506106f1611642565b6040516106fe9190613a2f565b60405180910390f35b34801561071357600080fd5b5061072e600480360381019061072991906140ea565b611655565b60405161073b9190613e16565b60405180910390f35b34801561075057600080fd5b5061075961170e565b005b6107756004803603810190610770919061413b565b611722565b005b34801561078357600080fd5b5061079e600480360381019061079991906141c3565b611922565b005b3480156107ac57600080fd5b506107c760048036038101906107c29190613d65565b611934565b005b3480156107d557600080fd5b506107f060048036038101906107eb9190613a80565b611956565b005b3480156107fe57600080fd5b50610819600480360381019061081491906140ea565b611968565b60405161082691906142ae565b60405180910390f35b34801561083b57600080fd5b50610844611ab2565b6040516108519190613e16565b60405180910390f35b34801561086657600080fd5b5061086f611ab8565b60405161087c9190613ba9565b60405180910390f35b34801561089157600080fd5b5061089a611ae2565b6040516108a79190613b46565b60405180910390f35b3480156108bc57600080fd5b506108d760048036038101906108d291906142d0565b611b74565b6040516108e491906142ae565b60405180910390f35b3480156108f957600080fd5b50610914600480360381019061090f9190614323565b611d88565b005b34801561092257600080fd5b5061092b611e93565b6040516109389190613b46565b60405180910390f35b34801561094d57600080fd5b5061096860048036038101906109639190613dda565b611f21565b005b610984600480360381019061097f9190614404565b611f46565b005b34801561099257600080fd5b506109ad60048036038101906109a89190613a80565b611fb9565b6040516109ba91906144dc565b60405180910390f35b3480156109cf57600080fd5b506109ea60048036038101906109e59190613a80565b612023565b6040516109f79190613b46565b60405180910390f35b610a1a6004803603810190610a15919061454d565b61217c565b005b348015610a2857600080fd5b50610a436004803603810190610a3e9190613a80565b612526565b005b348015610a5157600080fd5b50610a6c6004803603810190610a6791906145ad565b612538565b005b348015610a7a57600080fd5b50610a836125a5565b604051610a909190613e16565b60405180910390f35b348015610aa557600080fd5b50610aae6125ab565b604051610abb9190613e16565b60405180910390f35b348015610ad057600080fd5b50610aeb6004803603810190610ae691906140ea565b6125b1565b604051610af89190613a2f565b60405180910390f35b348015610b0d57600080fd5b50610b286004803603810190610b239190613dda565b6125d1565b005b348015610b3657600080fd5b50610b3f6125f6565b604051610b4c9190613e16565b60405180910390f35b348015610b6157600080fd5b50610b7c6004803603810190610b7791906145ed565b6125fc565b604051610b899190613a2f565b60405180910390f35b348015610b9e57600080fd5b50610bb96004803603810190610bb491906140ea565b612690565b005b348015610bc757600080fd5b50610be26004803603810190610bdd91906140ea565b6126dc565b005b60006301ffc9a760e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480610c3f57506380ac58cd60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80610c6f5750635b5e139f60e01b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b9050919050565b610c7e612760565b8060138190555050565b606060028054610c979061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054610cc39061465c565b8015610d105780601f10610ce557610100808354040283529160200191610d10565b820191906000526020600020905b815481529060010190602001808311610cf357829003601f168201915b5050505050905090565b6000610d25826127de565b610d5b576040517fcf4700e400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006600083815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6000610da4826115e4565b90508073ffffffffffffffffffffffffffffffffffffffff16610dc561283d565b73ffffffffffffffffffffffffffffffffffffffff1614610e2857610df181610dec61283d565b6125fc565b610e27576040517fcfb3b94200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b826006600084815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b610ee5612760565b80600d9080519060200190610efb929190613889565b5050565b610f07612760565b80601460006101000a81548160ff02191690831515021790555050565b6000610f2e612845565b6001546000540303905090565b601560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000610f6c8261284e565b90508373ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610fd3576040517fa114810000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080610fdf8461291c565b91509150610ff58187610ff061283d565b612943565b6110415761100a8661100561283d565b6125fc565b611040576040517f59c896be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614156110a8576040517fea553b3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110b58686866001612987565b80156110c057600082555b600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001900391905081905550600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600081546001019190508190555061118e8561116a88888761298d565b7c0200000000000000000000000000000000000000000000000000000000176129b5565b600460008681526020019081526020016000208190555060007c020000000000000000000000000000000000000000000000000000000084161415611216576000600185019050600060046000838152602001908152602001600020541415611214576000548114611213578360046000838152602001908152602001600020819055505b5b505b838573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a461127e86868660016129e0565b505050505050565b600a5481565b611294612760565b600260095414156112da576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016112d1906146da565b60405180910390fd5b60026009819055506000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff164760405161132a9061472b565b60006040518083038185875af1925050503d8060008114611367576040519150601f19603f3d011682016040523d82523d6000602084013e61136c565b606091505b505090508061137a57600080fd5b506001600981905550565b6113a083838360405180602001604052806000815250611f46565b505050565b6113ad612760565b8060128190555050565b60125481565b6113c5612760565b80600e90805190602001906113db929190613889565b5050565b601460029054906101000a900460ff1681565b600d80546113ff9061465c565b80601f016020809104026020016040519081016040528092919081815260200182805461142b9061465c565b80156114785780601f1061144d57610100808354040283529160200191611478565b820191906000526020600020905b81548152906001019060200180831161145b57829003601f168201915b505050505081565b6060600083839050905060008167ffffffffffffffff8111156114a6576114a5613c3a565b5b6040519080825280602002602001820160405280156114df57816020015b6114cc61390f565b8152602001906001900390816114c45790505b50905060005b8281146115375761150e86868381811061150257611501614740565b5b90506020020135611fb9565b82828151811061152157611520614740565b5b60200260200101819052508060010190506114e5565b50809250505092915050565b601460009054906101000a900460ff1681565b600c80546115639061465c565b80601f016020809104026020016040519081016040528092919081815260200182805461158f9061465c565b80156115dc5780601f106115b1576101008083540402835291602001916115dc565b820191906000526020600020905b8154815290600101906020018083116115bf57829003601f168201915b505050505081565b60006115ef8261284e565b9050919050565b6115fe612760565b80601560006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b601460019054906101000a900460ff1681565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156116bd576040517f8f4eb60400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054169050919050565b611716612760565b61172060006129e6565b565b8060008111801561173557506012548111155b611774576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161176b906147bb565b60405180910390fd5b60115481611780610f24565b61178a919061480a565b11156117cb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117c2906148ac565b60405180910390fd5b601460009054906101000a900460ff161561181b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161181290614918565b60405180910390fd5b81600f546118299190614938565b341461186a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611861906149de565b60405180910390fd5b61187383612aac565b61188461187e612bf7565b83612bff565b6000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16476040516118cc9061472b565b60006040518083038185875af1925050503d8060008114611909576040519150601f19603f3d011682016040523d82523d6000602084013e61190e565b606091505b505090508061191c57600080fd5b50505050565b61192a612760565b80600a8190555050565b61193c612760565b80600c9080519060200190611952929190613889565b5050565b61195e612760565b80600f8190555050565b6060600080600061197885611655565b905060008167ffffffffffffffff81111561199657611995613c3a565b5b6040519080825280602002602001820160405280156119c45781602001602082028036833780820191505090505b5090506119cf61390f565b60006119d9612845565b90505b838614611aa4576119ec81612c1d565b91508160400151156119fd57611a99565b600073ffffffffffffffffffffffffffffffffffffffff16826000015173ffffffffffffffffffffffffffffffffffffffff1614611a3d57816000015194505b8773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415611a985780838780600101985081518110611a8b57611a8a614740565b5b6020026020010181815250505b5b8060010190506119dc565b508195505050505050919050565b600f5481565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060038054611af19061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054611b1d9061465c565b8015611b6a5780601f10611b3f57610100808354040283529160200191611b6a565b820191906000526020600020905b815481529060010190602001808311611b4d57829003601f168201915b5050505050905090565b6060818310611baf576040517f32c1995a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080611bba612c48565b9050611bc4612845565b851015611bd657611bd3612845565b94505b80841115611be2578093505b6000611bed87611655565b905084861015611c10576000868603905081811015611c0a578091505b50611c15565b600090505b60008167ffffffffffffffff811115611c3157611c30613c3a565b5b604051908082528060200260200182016040528015611c5f5781602001602082028036833780820191505090505b5090506000821415611c775780945050505050611d81565b6000611c8288611fb9565b905060008160400151611c9757816000015190505b60008990505b888114158015611cad5750848714155b15611d7357611cbb81612c1d565b9250826040015115611ccc57611d68565b600073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614611d0c57826000015191505b8a73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611d675780848880600101995081518110611d5a57611d59614740565b5b6020026020010181815250505b5b806001019050611c9d565b508583528296505050505050505b9392505050565b8060076000611d9561283d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16611e4261283d565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051611e879190613a2f565b60405180910390a35050565b600e8054611ea09061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054611ecc9061465c565b8015611f195780601f10611eee57610100808354040283529160200191611f19565b820191906000526020600020905b815481529060010190602001808311611efc57829003601f168201915b505050505081565b611f29612760565b80601460016101000a81548160ff02191690831515021790555050565b611f51848484610f61565b60008373ffffffffffffffffffffffffffffffffffffffff163b14611fb357611f7c84848484612c51565b611fb2576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5b50505050565b611fc161390f565b611fc961390f565b611fd1612845565b831080611fe55750611fe1612c48565b8310155b15611ff3578091505061201e565b611ffc83612c1d565b9050806040015115612011578091505061201e565b61201a83612da2565b9150505b919050565b606061202e826127de565b61206d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161206490614a70565b60405180910390fd5b60001515601460029054906101000a900460ff161515141561211b57600e80546120969061465c565b80601f01602080910402602001604051908101604052809291908181526020018280546120c29061465c565b801561210f5780601f106120e45761010080835404028352916020019161210f565b820191906000526020600020905b8154815290600101906020018083116120f257829003601f168201915b50505050509050612177565b6000612125612dc2565b905060008151116121455760405180602001604052806000815250612173565b8061214f84612e54565b600d60405160200161216393929190614b60565b6040516020818303038152906040525b9150505b919050565b8260008111801561218f57506013548111155b6121ce576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121c5906147bb565b60405180910390fd5b601154816121da610f24565b6121e4919061480a565b1115612225576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161221c90614bdd565b60405180910390fd5b601460019054906101000a900460ff16612274576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161226b90614c6f565b60405180910390fd5b600b6000612280612bf7565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1615612308576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ff90614d01565b60405180910390fd5b836010546123169190614938565b3414612357576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161234e906149de565b60405180910390fd5b6000612361612bf7565b6040516020016123719190614d69565b6040516020818303038152906040528051906020012090506123d7848480806020026020016040519081016040528093929190818152602001838360200280828437600081840152601f19601f82011690508083019250505050505050600a5483612fb5565b612416576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161240d90614dd0565b60405180910390fd5b6001600b6000612424612bf7565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550612486612480612bf7565b86612bff565b6000601460039054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16476040516124ce9061472b565b60006040518083038185875af1925050503d806000811461250b576040519150601f19603f3d011682016040523d82523d6000602084013e612510565b606091505b505090508061251e57600080fd5b505050505050565b61252e612760565b8060108190555050565b612540612760565b6011548261254c610f24565b612556919061480a565b1115612597576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161258e906148ac565b60405180910390fd5b6125a18183612bff565b5050565b60115481565b60135481565b600b6020528060005260406000206000915054906101000a900460ff1681565b6125d9612760565b80601460026101000a81548160ff02191690831515021790555050565b60105481565b6000600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b612698612760565b80601460036101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6126e4612760565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415612754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161274b90614e62565b60405180910390fd5b61275d816129e6565b50565b612768612bf7565b73ffffffffffffffffffffffffffffffffffffffff16612786611ab8565b73ffffffffffffffffffffffffffffffffffffffff16146127dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016127d390614ece565b60405180910390fd5b565b6000816127e9612845565b111580156127f8575060005482105b8015612836575060007c0100000000000000000000000000000000000000000000000000000000600460008581526020019081526020016000205416145b9050919050565b600033905090565b60006001905090565b6000808290508061285d612845565b116128e5576000548110156128e45760006004600083815260200190815260200160002054905060007c0100000000000000000000000000000000000000000000000000000000821614156128e2575b60008114156128d85760046000836001900393508381526020019081526020016000205490506128ad565b8092505050612917565b505b5b6040517fdf2d9b4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b919050565b60008060006006600085815260200190815260200160002090508092508254915050915091565b600073ffffffffffffffffffffffffffffffffffffffff8316925073ffffffffffffffffffffffffffffffffffffffff821691508382148383141790509392505050565b50505050565b60008060e883901c905060e86129a4868684612fcc565b62ffffff16901b9150509392505050565b600073ffffffffffffffffffffffffffffffffffffffff83169250814260a01b178317905092915050565b50505050565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6000612b067fb793c547937a9a126a37f7d386b60ec9d3215c4cc65f40901d5268fdad7f9baf612ada612bf7565b604051602001612aeb929190614eee565b60405160208183030381529060405280519060200120612fd5565b9050612b6481838060200190612b1c9190614f26565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050612fef565b73ffffffffffffffffffffffffffffffffffffffff16601560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612bf3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bea90614fd5565b60405180910390fd5b5050565b600033905090565b612c19828260405180602001604052806000815250613016565b5050565b612c2561390f565b612c4160046000848152602001908152602001600020546130b3565b9050919050565b60008054905090565b60008373ffffffffffffffffffffffffffffffffffffffff1663150b7a02612c7761283d565b8786866040518563ffffffff1660e01b8152600401612c99949392919061504a565b6020604051808303816000875af1925050508015612cd557506040513d601f19601f82011682018060405250810190612cd291906150ab565b60015b612d4f573d8060008114612d05576040519150601f19603f3d011682016040523d82523d6000602084013e612d0a565b606091505b50600081511415612d47576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614915050949350505050565b612daa61390f565b612dbb612db68361284e565b6130b3565b9050919050565b6060600c8054612dd19061465c565b80601f0160208091040260200160405190810160405280929190818152602001828054612dfd9061465c565b8015612e4a5780601f10612e1f57610100808354040283529160200191612e4a565b820191906000526020600020905b815481529060010190602001808311612e2d57829003601f168201915b5050505050905090565b60606000821415612e9c576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050612fb0565b600082905060005b60008214612ece578080612eb7906150d8565b915050600a82612ec79190615150565b9150612ea4565b60008167ffffffffffffffff811115612eea57612ee9613c3a565b5b6040519080825280601f01601f191660200182016040528015612f1c5781602001600182028036833780820191505090505b5090505b60008514612fa957600182612f359190615181565b9150600a85612f4491906151b5565b6030612f50919061480a565b60f81b818381518110612f6657612f65614740565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a85612fa29190615150565b9450612f20565b8093505050505b919050565b600082612fc28584613169565b1490509392505050565b60009392505050565b6000612fe8612fe26131bf565b836132d9565b9050919050565b6000806000612ffe858561330c565b9150915061300b8161335e565b819250505092915050565b6130208383613533565b60008373ffffffffffffffffffffffffffffffffffffffff163b146130ae57600080549050600083820390505b6130606000868380600101945086612c51565b613096576040517fd1a57ed600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81811061304d5781600054146130ab57600080fd5b50505b505050565b6130bb61390f565b81816000019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505060a082901c816020019067ffffffffffffffff16908167ffffffffffffffff168152505060007c01000000000000000000000000000000000000000000000000000000008316141581604001901515908115158152505060e882901c816060019062ffffff16908162ffffff1681525050919050565b60008082905060005b84518110156131b45761319f8286838151811061319257613191614740565b5b60200260200101516136f0565b915080806131ac906150d8565b915050613172565b508091505092915050565b60007f000000000000000000000000d3e3912cb7df9482d0e4eabdbafe843a35d9fee073ffffffffffffffffffffffffffffffffffffffff163073ffffffffffffffffffffffffffffffffffffffff1614801561323b57507f000000000000000000000000000000000000000000000000000000000000000146145b15613268577f30f79bdaf8472aaab2633f2396b2d614d3de1ef4e951302492e781d0dd49febc90506132d6565b6132d37f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f7f19196b8fcdabe15061fdaf38a7f684d256421541d0dc07c40f8a679b54ec65d87fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc661371b565b90505b90565b600082826040516020016132ee929190615253565b60405160208183030381529060405280519060200120905092915050565b60008060418351141561334e5760008060006020860151925060408601519150606086015160001a905061334287828585613755565b94509450505050613357565b60006002915091505b9250929050565b600060048111156133725761337161528a565b5b8160048111156133855761338461528a565b5b141561339057613530565b600160048111156133a4576133a361528a565b5b8160048111156133b7576133b661528a565b5b14156133f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016133ef90615305565b60405180910390fd5b6002600481111561340c5761340b61528a565b5b81600481111561341f5761341e61528a565b5b1415613460576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161345790615371565b60405180910390fd5b600360048111156134745761347361528a565b5b8160048111156134875761348661528a565b5b14156134c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016134bf90615403565b60405180910390fd5b6004808111156134db576134da61528a565b5b8160048111156134ee576134ed61528a565b5b141561352f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161352690615495565b60405180910390fd5b5b50565b6000805490506000821415613574576040517fb562e8dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6135816000848385612987565b600160406001901b178202600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055506135f8836135e9600086600061298d565b6135f285613862565b176129b5565b6004600083815260200190815260200160002081905550600080838301905073ffffffffffffffffffffffffffffffffffffffff85169150828260007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4600183015b81811461369957808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a460018101905061365e565b5060008214156136d5576040517f2e07630000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8060008190555050506136eb60008483856129e0565b505050565b6000818310613708576137038284613872565b613713565b6137128383613872565b5b905092915050565b600083838346306040516020016137369594939291906154b5565b6040516020818303038152906040528051906020012090509392505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08360001c1115613790576000600391509150613859565b601b8560ff16141580156137a85750601c8560ff1614155b156137ba576000600491509150613859565b6000600187878787604051600081526020016040526040516137df9493929190615524565b6020604051602081039080840390855afa158015613801573d6000803e3d6000fd5b505050602060405103519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141561385057600060019250925050613859565b80600092509250505b94509492505050565b60006001821460e11b9050919050565b600082600052816020526040600020905092915050565b8280546138959061465c565b90600052602060002090601f0160209004810192826138b757600085556138fe565b82601f106138d057805160ff19168380011785556138fe565b828001600101855582156138fe579182015b828111156138fd5782518255916020019190600101906138e2565b5b50905061390b919061395e565b5090565b6040518060800160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600067ffffffffffffffff168152602001600015158152602001600062ffffff1681525090565b5b8082111561397757600081600090555060010161395f565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6139c48161398f565b81146139cf57600080fd5b50565b6000813590506139e1816139bb565b92915050565b6000602082840312156139fd576139fc613985565b5b6000613a0b848285016139d2565b91505092915050565b60008115159050919050565b613a2981613a14565b82525050565b6000602082019050613a446000830184613a20565b92915050565b6000819050919050565b613a5d81613a4a565b8114613a6857600080fd5b50565b600081359050613a7a81613a54565b92915050565b600060208284031215613a9657613a95613985565b5b6000613aa484828501613a6b565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613ae7578082015181840152602081019050613acc565b83811115613af6576000848401525b50505050565b6000601f19601f8301169050919050565b6000613b1882613aad565b613b228185613ab8565b9350613b32818560208601613ac9565b613b3b81613afc565b840191505092915050565b60006020820190508181036000830152613b608184613b0d565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000613b9382613b68565b9050919050565b613ba381613b88565b82525050565b6000602082019050613bbe6000830184613b9a565b92915050565b613bcd81613b88565b8114613bd857600080fd5b50565b600081359050613bea81613bc4565b92915050565b60008060408385031215613c0757613c06613985565b5b6000613c1585828601613bdb565b9250506020613c2685828601613a6b565b9150509250929050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b613c7282613afc565b810181811067ffffffffffffffff82111715613c9157613c90613c3a565b5b80604052505050565b6000613ca461397b565b9050613cb08282613c69565b919050565b600067ffffffffffffffff821115613cd057613ccf613c3a565b5b613cd982613afc565b9050602081019050919050565b82818337600083830152505050565b6000613d08613d0384613cb5565b613c9a565b905082815260208101848484011115613d2457613d23613c35565b5b613d2f848285613ce6565b509392505050565b600082601f830112613d4c57613d4b613c30565b5b8135613d5c848260208601613cf5565b91505092915050565b600060208284031215613d7b57613d7a613985565b5b600082013567ffffffffffffffff811115613d9957613d9861398a565b5b613da584828501613d37565b91505092915050565b613db781613a14565b8114613dc257600080fd5b50565b600081359050613dd481613dae565b92915050565b600060208284031215613df057613def613985565b5b6000613dfe84828501613dc5565b91505092915050565b613e1081613a4a565b82525050565b6000602082019050613e2b6000830184613e07565b92915050565b600080600060608486031215613e4a57613e49613985565b5b6000613e5886828701613bdb565b9350506020613e6986828701613bdb565b9250506040613e7a86828701613a6b565b9150509250925092565b6000819050919050565b613e9781613e84565b82525050565b6000602082019050613eb26000830184613e8e565b92915050565b600080fd5b600080fd5b60008083601f840112613ed857613ed7613c30565b5b8235905067ffffffffffffffff811115613ef557613ef4613eb8565b5b602083019150836020820283011115613f1157613f10613ebd565b5b9250929050565b60008060208385031215613f2f57613f2e613985565b5b600083013567ffffffffffffffff811115613f4d57613f4c61398a565b5b613f5985828601613ec2565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b613f9a81613b88565b82525050565b600067ffffffffffffffff82169050919050565b613fbd81613fa0565b82525050565b613fcc81613a14565b82525050565b600062ffffff82169050919050565b613fea81613fd2565b82525050565b6080820160008201516140066000850182613f91565b5060208201516140196020850182613fb4565b50604082015161402c6040850182613fc3565b50606082015161403f6060850182613fe1565b50505050565b60006140518383613ff0565b60808301905092915050565b6000602082019050919050565b600061407582613f65565b61407f8185613f70565b935061408a83613f81565b8060005b838110156140bb5781516140a28882614045565b97506140ad8361405d565b92505060018101905061408e565b5085935050505092915050565b600060208201905081810360008301526140e2818461406a565b905092915050565b600060208284031215614100576140ff613985565b5b600061410e84828501613bdb565b91505092915050565b600080fd5b60006040828403121561413257614131614117565b5b81905092915050565b6000806040838503121561415257614151613985565b5b600083013567ffffffffffffffff8111156141705761416f61398a565b5b61417c8582860161411c565b925050602061418d85828601613a6b565b9150509250929050565b6141a081613e84565b81146141ab57600080fd5b50565b6000813590506141bd81614197565b92915050565b6000602082840312156141d9576141d8613985565b5b60006141e7848285016141ae565b91505092915050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b61422581613a4a565b82525050565b6000614237838361421c565b60208301905092915050565b6000602082019050919050565b600061425b826141f0565b61426581856141fb565b93506142708361420c565b8060005b838110156142a1578151614288888261422b565b975061429383614243565b925050600181019050614274565b5085935050505092915050565b600060208201905081810360008301526142c88184614250565b905092915050565b6000806000606084860312156142e9576142e8613985565b5b60006142f786828701613bdb565b935050602061430886828701613a6b565b925050604061431986828701613a6b565b9150509250925092565b6000806040838503121561433a57614339613985565b5b600061434885828601613bdb565b925050602061435985828601613dc5565b9150509250929050565b600067ffffffffffffffff82111561437e5761437d613c3a565b5b61438782613afc565b9050602081019050919050565b60006143a76143a284614363565b613c9a565b9050828152602081018484840111156143c3576143c2613c35565b5b6143ce848285613ce6565b509392505050565b600082601f8301126143eb576143ea613c30565b5b81356143fb848260208601614394565b91505092915050565b6000806000806080858703121561441e5761441d613985565b5b600061442c87828801613bdb565b945050602061443d87828801613bdb565b935050604061444e87828801613a6b565b925050606085013567ffffffffffffffff81111561446f5761446e61398a565b5b61447b878288016143d6565b91505092959194509250565b60808201600082015161449d6000850182613f91565b5060208201516144b06020850182613fb4565b5060408201516144c36040850182613fc3565b5060608201516144d66060850182613fe1565b50505050565b60006080820190506144f16000830184614487565b92915050565b60008083601f84011261450d5761450c613c30565b5b8235905067ffffffffffffffff81111561452a57614529613eb8565b5b60208301915083602082028301111561454657614545613ebd565b5b9250929050565b60008060006040848603121561456657614565613985565b5b600061457486828701613a6b565b935050602084013567ffffffffffffffff8111156145955761459461398a565b5b6145a1868287016144f7565b92509250509250925092565b600080604083850312156145c4576145c3613985565b5b60006145d285828601613a6b565b92505060206145e385828601613bdb565b9150509250929050565b6000806040838503121561460457614603613985565b5b600061461285828601613bdb565b925050602061462385828601613bdb565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061467457607f821691505b602082108114156146885761468761462d565b5b50919050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b60006146c4601f83613ab8565b91506146cf8261468e565b602082019050919050565b600060208201905081810360008301526146f3816146b7565b9050919050565b600081905092915050565b50565b60006147156000836146fa565b915061472082614705565b600082019050919050565b600061473682614708565b9150819050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f496e76616c6964206d696e7420616d6f756e7421000000000000000000000000600082015250565b60006147a5601483613ab8565b91506147b08261476f565b602082019050919050565b600060208201905081810360008301526147d481614798565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600061481582613a4a565b915061482083613a4a565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115614855576148546147db565b5b828201905092915050565b7f536f6c64204f7574210000000000000000000000000000000000000000000000600082015250565b6000614896600983613ab8565b91506148a182614860565b602082019050919050565b600060208201905081810360008301526148c581614889565b9050919050565b7f546865206d696e7420686173206265656e207061757365642100000000000000600082015250565b6000614902601983613ab8565b915061490d826148cc565b602082019050919050565b60006020820190508181036000830152614931816148f5565b9050919050565b600061494382613a4a565b915061494e83613a4a565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614987576149866147db565b5b828202905092915050565b7f496e73756666696369656e742066756e64732100000000000000000000000000600082015250565b60006149c8601383613ab8565b91506149d382614992565b602082019050919050565b600060208201905081810360008301526149f7816149bb565b9050919050565b7f4552433732314d657461646174613a2055524920717565727920666f72206e6f60008201527f6e6578697374656e7420746f6b656e0000000000000000000000000000000000602082015250565b6000614a5a602f83613ab8565b9150614a65826149fe565b604082019050919050565b60006020820190508181036000830152614a8981614a4d565b9050919050565b600081905092915050565b6000614aa682613aad565b614ab08185614a90565b9350614ac0818560208601613ac9565b80840191505092915050565b60008190508160005260206000209050919050565b60008154614aee8161465c565b614af88186614a90565b94506001821660008114614b135760018114614b2457614b57565b60ff19831686528186019350614b57565b614b2d85614acc565b60005b83811015614b4f57815481890152600182019150602081019050614b30565b838801955050505b50505092915050565b6000614b6c8286614a9b565b9150614b788285614a9b565b9150614b848284614ae1565b9150819050949350505050565b7f536f6c64206f7574210000000000000000000000000000000000000000000000600082015250565b6000614bc7600983613ab8565b9150614bd282614b91565b602082019050919050565b60006020820190508181036000830152614bf681614bba565b9050919050565b7f5468652077686974656c6973742073616c6520686173206e6f7420737461727460008201527f65642e20436f6d6520636865636b20616761696e206c61746572210000000000602082015250565b6000614c59603b83613ab8565b9150614c6482614bfd565b604082019050919050565b60006020820190508181036000830152614c8881614c4c565b9050919050565b7f5468697320616464726573732068617320616c726561647920636c61696d656460008201527f20746865697220574c2073706f74210000000000000000000000000000000000602082015250565b6000614ceb602f83613ab8565b9150614cf682614c8f565b604082019050919050565b60006020820190508181036000830152614d1a81614cde565b9050919050565b60008160601b9050919050565b6000614d3982614d21565b9050919050565b6000614d4b82614d2e565b9050919050565b614d63614d5e82613b88565b614d40565b82525050565b6000614d758284614d52565b60148201915081905092915050565b7f496e76616c69642070726f6f6621000000000000000000000000000000000000600082015250565b6000614dba600e83613ab8565b9150614dc582614d84565b602082019050919050565b60006020820190508181036000830152614de981614dad565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614e4c602683613ab8565b9150614e5782614df0565b604082019050919050565b60006020820190508181036000830152614e7b81614e3f565b9050919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614eb8602083613ab8565b9150614ec382614e82565b602082019050919050565b60006020820190508181036000830152614ee781614eab565b9050919050565b6000604082019050614f036000830185613e8e565b614f106020830184613b9a565b9392505050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112614f4357614f42614f17565b5b80840192508235915067ffffffffffffffff821115614f6557614f64614f1c565b5b602083019250600182023603831315614f8157614f80614f21565b5b509250929050565b7f496e76616c6964207369676e6572000000000000000000000000000000000000600082015250565b6000614fbf600e83613ab8565b9150614fca82614f89565b602082019050919050565b60006020820190508181036000830152614fee81614fb2565b9050919050565b600081519050919050565b600082825260208201905092915050565b600061501c82614ff5565b6150268185615000565b9350615036818560208601613ac9565b61503f81613afc565b840191505092915050565b600060808201905061505f6000830187613b9a565b61506c6020830186613b9a565b6150796040830185613e07565b818103606083015261508b8184615011565b905095945050505050565b6000815190506150a5816139bb565b92915050565b6000602082840312156150c1576150c0613985565b5b60006150cf84828501615096565b91505092915050565b60006150e382613a4a565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415615116576151156147db565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061515b82613a4a565b915061516683613a4a565b92508261517657615175615121565b5b828204905092915050565b600061518c82613a4a565b915061519783613a4a565b9250828210156151aa576151a96147db565b5b828203905092915050565b60006151c082613a4a565b91506151cb83613a4a565b9250826151db576151da615121565b5b828206905092915050565b7f1901000000000000000000000000000000000000000000000000000000000000600082015250565b600061521c600283614a90565b9150615227826151e6565b600282019050919050565b6000819050919050565b61524d61524882613e84565b615232565b82525050565b600061525e8261520f565b915061526a828561523c565b60208201915061527a828461523c565b6020820191508190509392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f45434453413a20696e76616c6964207369676e61747572650000000000000000600082015250565b60006152ef601883613ab8565b91506152fa826152b9565b602082019050919050565b6000602082019050818103600083015261531e816152e2565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265206c656e67746800600082015250565b600061535b601f83613ab8565b915061536682615325565b602082019050919050565b6000602082019050818103600083015261538a8161534e565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202773272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b60006153ed602283613ab8565b91506153f882615391565b604082019050919050565b6000602082019050818103600083015261541c816153e0565b9050919050565b7f45434453413a20696e76616c6964207369676e6174757265202776272076616c60008201527f7565000000000000000000000000000000000000000000000000000000000000602082015250565b600061547f602283613ab8565b915061548a82615423565b604082019050919050565b600060208201905081810360008301526154ae81615472565b9050919050565b600060a0820190506154ca6000830188613e8e565b6154d76020830187613e8e565b6154e46040830186613e8e565b6154f16060830185613e07565b6154fe6080830184613b9a565b9695505050505050565b600060ff82169050919050565b61551e81615508565b82525050565b60006080820190506155396000830187613e8e565b6155466020830186615515565b6155536040830185613e8e565b6155606060830184613e8e565b9594505050505056fea2646970667358221220cb2904d4d3fac3b931c1e184b7e41d078383e6a0656ab034ff0cc3610ed9ab1864736f6c634300080a0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000006a94d74f430000000000000000000000000000000000000000000000000000005c833df5f380000000000000000000000000000000000000000000000000000000000000000a2c0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000b73578ab7c6516bdd021f2b03b8407fe1cd03265000000000000000000000000f7bbff6839913758b769dab742a68ebcff49c393000000000000000000000000000000000000000000000000000000000000000f50726f6f664f66457468657265756d00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003504f4500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000042697066733a2f2f6261666b7265696766363663777933357a68686969717a72736e65797963656f70377078687a6d71346c3579376d7474723463616537726c697079000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _tokenName (string): ProofOfEthereum
Arg [1] : _tokenSymbol (string): POE
Arg [2] : _publicCost (uint256): 30000000000000000
Arg [3] : _whitelistCost (uint256): 26040000000000000
Arg [4] : _maxSupply (uint256): 2604
Arg [5] : _maxMintAmountPerTxPublic (uint256): 4
Arg [6] : _maxMintAmountPerTxWhitelist (uint256): 2
Arg [7] : _hiddenMetadataUri (string): ipfs://bafkreigf66cwy35zhhiiqzrsneyyceop7pxhzmq4l5y7mttr4cae7rlipy
Arg [8] : _treasuryAddress (address): 0xb73578ab7c6516BDd021f2b03b8407FE1Cd03265
Arg [9] : _signer (address): 0xf7BbfF6839913758b769DAB742a68EbcFF49C393
-----Encoded View---------------
18 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000180
Arg [2] : 000000000000000000000000000000000000000000000000006a94d74f430000
Arg [3] : 000000000000000000000000000000000000000000000000005c833df5f38000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000a2c
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [7] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [8] : 000000000000000000000000b73578ab7c6516bdd021f2b03b8407fe1cd03265
Arg [9] : 000000000000000000000000f7bbff6839913758b769dab742a68ebcff49c393
Arg [10] : 000000000000000000000000000000000000000000000000000000000000000f
Arg [11] : 50726f6f664f66457468657265756d0000000000000000000000000000000000
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [13] : 504f450000000000000000000000000000000000000000000000000000000000
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000042
Arg [15] : 697066733a2f2f6261666b7265696766363663777933357a68686969717a7273
Arg [16] : 6e65797963656f70377078687a6d71346c3579376d7474723463616537726c69
Arg [17] : 7079000000000000000000000000000000000000000000000000000000000000
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.