ERC-721
Overview
Max Total Supply
746 SMPLFRKS
Holders
310
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
1 SMPLFRKSLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
NFTCollectionContract
Compiler Version
v0.8.2+commit.661d1103
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./NFTCollection.sol"; contract NFTCollectionContract is NFTCollection { constructor( DeploymentConfig memory deploymentConfig, RuntimeConfig memory runtimeConfig ) { _preventInitialization = false; initialize(deploymentConfig, runtimeConfig); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/proxy/utils/Initializable.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "./ERC2981.sol"; import "./Base64.sol"; contract NFTCollection is ERC721, ERC2981, AccessControl, Initializable { using Address for address payable; using Strings for uint256; /// Fixed at deployment time struct DeploymentConfig { // Name of the NFT contract. string name; // Symbol of the NFT contract. string symbol; // The contract owner address. If you wish to own the contract, then set it as your wallet address. // This is also the wallet that can manage the contract on NFT marketplaces. Use `transferOwnership()` // to update the contract owner. address owner; // The fee address of JustMint.org address providerAddress; // The maximum number of tokens that can be minted in this collection. uint256 maxSupply; // The number of free token mints reserved for the contract owner uint256 reservedSupply; // The maximum number of tokens the user can mint per transaction. uint256 tokensPerMint; // Treasury address is the address where minting fees can be withdrawn to. // Use `withdrawFees()` to transfer the entire contract balance to the treasury address. address payable treasuryAddress; } /// Updatable by admins and owner struct RuntimeConfig { // Metadata base URI for tokens, NFTs minted in this contract will have metadata URI of `baseURI` + `tokenID`. // Set this to reveal token metadata. string baseURI; // If true, the base URI of the NFTs minted in the specified contract can be updated after minting (token URIs // are not frozen on the contract level). This is useful for revealing NFTs after the drop. If false, all the // NFTs minted in this contract are frozen by default which means token URIs are non-updatable. bool metadataUpdatable; // Starting timestamp for public minting. uint256 publicMintStart; // Starting timestamp for whitelisted/presale minting. uint256 presaleMintStart; // Pre-reveal token URI for placholder metadata. This will be returned for all token IDs until a `baseURI` // has been set. string prerevealTokenURI; // Root of the Merkle tree of whitelisted addresses. This is used to check if a wallet has been whitelisted // for presale minting. bytes32 presaleMerkleRoot; // Secondary market royalties in basis points (100 bps = 1%) uint256 royaltiesBps; // Address for royalties address royaltiesAddress; // Minting price per token. uint256 mintPrice; } struct ContractInfo { uint256 version; DeploymentConfig deploymentConfig; RuntimeConfig runtimeConfig; } event OwnershipTransferred( address indexed previousOwner, address indexed newOwner ); /************* * Constants * *************/ /// Contract version, semver-style uint X_YY_ZZ uint256 public constant VERSION = 1_02_00; /// Admin role bytes32 public constant ADMIN_ROLE = keccak256("ADMIN_ROLE"); // Basis for calculating royalties. // This has to be 10k for royaltiesBps to be in basis points. uint16 constant ROYALTIES_BASIS = 10000; /******************** * Public variables * ********************/ /// The number of currently minted tokens /// @dev Managed by the contract uint256 public totalSupply; /*************************** * Contract initialization * ***************************/ constructor() ERC721("", "") { _preventInitialization = true; } /// Contract initializer function initialize( DeploymentConfig memory deploymentConfig, RuntimeConfig memory runtimeConfig ) public initializer { require(!_preventInitialization, "Cannot be initialized"); _validateDeploymentConfig(deploymentConfig); _grantRole(ADMIN_ROLE, msg.sender); _grantRole(ADMIN_ROLE, deploymentConfig.owner); _grantRole(DEFAULT_ADMIN_ROLE, deploymentConfig.owner); _deploymentConfig = deploymentConfig; _runtimeConfig = runtimeConfig; } /**************** * User actions * ****************/ function creditCardMint(address to, uint256 amount) external payable paymentProvided(amount) { /// CrossMint currently only for public sales require(mintingActive(), "Minting has not started yet"); require(msg.sender == 0xdAb1a1854214684acE522439684a145E62505233, "This function is reserved for credit-card payments." ); _mintTokens(to, amount); } /// Mint tokens1 function mint(uint256 amount) external payable paymentProvided(amount) { require(mintingActive(), "Minting has not started yet"); _mintTokens(msg.sender, amount); } /// Mint tokens if the wallet has been whitelisted function presaleMint(uint256 amount, bytes32[] calldata proof) external payable paymentProvided(amount) { require(presaleActive(), "Presale has not started yet"); require( isWhitelisted(msg.sender, proof), "Not whitelisted for presale" ); _presaleMinted[msg.sender] = true; _mintTokens(msg.sender, amount); } /****************** * View functions * ******************/ /// Check if public minting is active function mintingActive() public view returns (bool) { return block.timestamp > _runtimeConfig.publicMintStart; } /// Check if presale minting is active function presaleActive() public view returns (bool) { return block.timestamp > _runtimeConfig.presaleMintStart; } /// Get the number of tokens still available for minting function availableSupply() public view returns (uint256) { return _deploymentConfig.maxSupply - totalSupply - _deploymentConfig.reservedSupply; } /// Check if the wallet is whitelisted for the presale function isWhitelisted(address wallet, bytes32[] calldata proof) public view returns (bool) { require(!_presaleMinted[wallet], "Already minted"); bytes32 leaf = keccak256(abi.encodePacked(wallet)); return MerkleProof.verify(proof, _runtimeConfig.presaleMerkleRoot, leaf); } /// Contract owner address /// @dev Required for easy integration with OpenSea function owner() public view returns (address) { return _deploymentConfig.owner; } /******************* * Access controls * *******************/ /// Transfer contract ownership function transferOwnership(address newOwner) external onlyRole(DEFAULT_ADMIN_ROLE) { require(newOwner != _deploymentConfig.owner, "Already the owner"); _revokeRole(ADMIN_ROLE, _deploymentConfig.owner); _revokeRole(DEFAULT_ADMIN_ROLE, _deploymentConfig.owner); address previousOwner = _deploymentConfig.owner; _deploymentConfig.owner = newOwner; _grantRole(ADMIN_ROLE, _deploymentConfig.owner); _grantRole(DEFAULT_ADMIN_ROLE, _deploymentConfig.owner); emit OwnershipTransferred(previousOwner, newOwner); } /// Transfer contract ownership function transferAdminRights(address to) external onlyRole(ADMIN_ROLE) { require(!hasRole(ADMIN_ROLE, to), "Already an admin"); require(msg.sender != _deploymentConfig.owner, "Use transferOwnership"); _revokeRole(ADMIN_ROLE, msg.sender); _grantRole(ADMIN_ROLE, to); } /***************** * Admin actions * *****************/ /// Mint a token from the reserve function reserveMint(address to, uint256 amount) external onlyRole(ADMIN_ROLE) { require( amount <= _deploymentConfig.reservedSupply, "Not enough reserved" ); _deploymentConfig.reservedSupply -= amount; _mintTokensFromReserve(to, amount); } /// Get full contract information /// @dev Convenience helper function getInfo() external view returns (ContractInfo memory info) { info.version = VERSION; info.deploymentConfig = _deploymentConfig; info.runtimeConfig = _runtimeConfig; } /// Update contract configuration /// @dev Callable by admin roles only function updateConfig(RuntimeConfig calldata newConfig) external onlyRole(ADMIN_ROLE) { _validateRuntimeConfig(newConfig); _runtimeConfig = newConfig; } /// Withdraw minting fees to the treasury address /// @dev Callable by admin roles only function withdrawFees() external onlyRole(ADMIN_ROLE) { _deploymentConfig.treasuryAddress.sendValue(address(this).balance); } /************* * Internals * *************/ RuntimeConfig internal _runtimeConfig; DeploymentConfig internal _deploymentConfig; bool internal _preventInitialization; mapping(address => bool) internal _presaleMinted; function _sendProviderFee() internal { if(msg.value != 0){ // 2.5% of the transaction value uint256 splitValue = SafeMath.mul(SafeMath.div(msg.value, 1000), 25); payable(_deploymentConfig.providerAddress).transfer(splitValue); } } /// @dev Internal function for performing token mints function _mintTokens(address to, uint256 amount) internal { require(amount <= _deploymentConfig.tokensPerMint, "Amount too large"); require(amount <= availableSupply(), "Not enough tokens left"); // Update totalSupply only once with the total minted amount totalSupply += amount; // Send fee to provider _sendProviderFee(); // Mint the required amount of tokens, // starting with the highest token ID for (uint256 i = 1; i <= amount; i++) { _safeMint(to, totalSupply - i); } } /// @dev Internal function for performing token mints from reserve (no tokensPerMint limit) function _mintTokensFromReserve(address to, uint256 amount) internal { require(amount <= availableSupply(), "Not enough tokens left"); // Update totalSupply only once with the total minted amount totalSupply += amount; // Mint the required amount of tokens, // starting with the highest token ID for (uint256 i = 1; i <= amount; i++) { _safeMint(to, totalSupply - i); } } /// Validate deployment config function _validateDeploymentConfig(DeploymentConfig memory config) internal pure { require(config.maxSupply > 0, "Maximum supply must be non-zero"); require(config.tokensPerMint > 0, "Tokens per mint must be non-zero"); require( config.treasuryAddress != address(0), "Treasury address cannot be the null address" ); require(config.owner != address(0), "Contract must have an owner"); require( config.reservedSupply <= config.maxSupply, "Reserve must be less than maximum supply" ); } /// Validate a runtime configuration change function _validateRuntimeConfig(RuntimeConfig calldata config) internal view { // Can't set royalties to more than 100% require(config.royaltiesBps <= ROYALTIES_BASIS, "Royalties too high"); // If metadata is updatable, we don't have any other limitations if (_runtimeConfig.metadataUpdatable) return; // If it isn't, has we can't allow the flag to change anymore require( _runtimeConfig.metadataUpdatable == config.metadataUpdatable, "Cannot unfreeze metadata" ); // We also can't allow base URI to change require( keccak256(abi.encodePacked(_runtimeConfig.baseURI)) == keccak256(abi.encodePacked(config.baseURI)), "Metadata is frozen" ); } /// @dev See {IERC165-supportsInterface}. function supportsInterface(bytes4 interfaceId) public view override(ERC721, AccessControl, ERC2981) returns (bool) { return ERC721.supportsInterface(interfaceId) || AccessControl.supportsInterface(interfaceId) || ERC2981.supportsInterface(interfaceId); } /// Get the token metadata URI function tokenURI(uint256 tokenId) public view override returns (string memory) { require(_exists(tokenId), "Token does not exist"); return bytes(_runtimeConfig.baseURI).length > 0 ? string( abi.encodePacked(_runtimeConfig.baseURI, tokenId.toString()) ) : _runtimeConfig.prerevealTokenURI; } /// @dev Need name() to support setting it in the initializer instead of constructor function name() public view override returns (string memory) { return _deploymentConfig.name; } /// @dev Need symbol() to support setting it in the initializer instead of constructor function symbol() public view override returns (string memory) { return _deploymentConfig.symbol; } /// @dev ERC2981 token royalty info function royaltyInfo(uint256, uint256 salePrice) external override view returns (address receiver, uint256 royaltyAmount) { receiver = _runtimeConfig.royaltiesAddress; royaltyAmount = (_runtimeConfig.royaltiesBps * salePrice) / ROYALTIES_BASIS; } /// @dev OpenSea contract metadata function contractURI() external view returns (string memory) { string memory json = Base64.encode( bytes( string( abi.encodePacked( // solium-disable-next-line quotes '{"seller_fee_basis_points": ', // solhint-disable-line quotes _runtimeConfig.royaltiesBps.toString(), // solium-disable-next-line quotes ', "fee_recipient": "', // solhint-disable-line quotes uint256(uint160(_runtimeConfig.royaltiesAddress)) .toHexString(20), // solium-disable-next-line quotes '"}' // solhint-disable-line quotes ) ) ) ); string memory output = string( abi.encodePacked("data:application/json;base64,", json) ); return output; } /// Check if enough payment was provided to mint `amount` number of tokens modifier paymentProvided(uint256 amount) { require( msg.value >= amount * _runtimeConfig.mintPrice, "Payment too small" ); _; } /*********************** * Convenience getters * ***********************/ function maxSupply() public view returns (uint256) { return _deploymentConfig.maxSupply; } function reservedSupply() public view returns (uint256) { return _deploymentConfig.reservedSupply; } function mintPrice() public view returns (uint256) { return _runtimeConfig.mintPrice; } function tokensPerMint() public view returns (uint256) { return _deploymentConfig.tokensPerMint; } function treasuryAddress() public view returns (address) { return _deploymentConfig.treasuryAddress; } function publicMintStart() public view returns (uint256) { return _runtimeConfig.publicMintStart; } function presaleMintStart() public view returns (uint256) { return _runtimeConfig.presaleMintStart; } function presaleMerkleRoot() public view returns (bytes32) { return _runtimeConfig.presaleMerkleRoot; } function baseURI() public view returns (string memory) { return _runtimeConfig.baseURI; } function metadataUpdatable() public view returns (bool) { return _runtimeConfig.metadataUpdatable; } function prerevealTokenURI() public view returns (string memory) { return _runtimeConfig.prerevealTokenURI; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol) pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the subtraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); _afterTokenTransfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); _afterTokenTransfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); _afterTokenTransfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC721: approve to caller"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (access/AccessControl.sol) pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view virtual override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `_msgSender()` is missing `role`. * Overriding this function changes the behavior of the {onlyRole} modifier. * * Format of the revert message is described in {_checkRole}. * * _Available since v4.6._ */ function _checkRole(bytes32 role) internal view virtual { _checkRole(role, _msgSender()); } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view virtual { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view virtual override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been revoked `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== * * NOTE: This function is deprecated in favor of {_grantRole}. */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } /** * @dev Grants `role` to `account`. * * Internal function without access restriction. */ function _grantRole(bytes32 role, address account) internal virtual { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } /** * @dev Revokes `role` from `account`. * * Internal function without access restriction. */ function _revokeRole(bytes32 role, address account) internal virtual { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (proxy/utils/Initializable.sol) pragma solidity ^0.8.2; import "../../utils/Address.sol"; /** * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in * case an upgrade adds a module that needs to be initialized. * * For example: * * [.hljs-theme-light.nopadding] * ``` * contract MyToken is ERC20Upgradeable { * function initialize() initializer public { * __ERC20_init("MyToken", "MTK"); * } * } * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable { * function initializeV2() reinitializer(2) public { * __ERC20Permit_init("MyToken"); * } * } * ``` * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. * * [CAUTION] * ==== * Avoid leaving a contract uninitialized. * * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed: * * [.hljs-theme-light.nopadding] * ``` * /// @custom:oz-upgrades-unsafe-allow constructor * constructor() { * _disableInitializers(); * } * ``` * ==== */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. * @custom:oz-retyped-from bool */ uint8 private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Triggered when the contract has been initialized or reinitialized. */ event Initialized(uint8 version); /** * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope, * `onlyInitializing` functions can be used to initialize parent contracts. Equivalent to `reinitializer(1)`. */ modifier initializer() { bool isTopLevelCall = _setInitializedVersion(1); if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _initializing = false; emit Initialized(1); } } /** * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be * used to initialize parent contracts. * * `initializer` is equivalent to `reinitializer(1)`, so a reinitializer may be used after the original * initialization step. This is essential to configure modules that are added through upgrades and that require * initialization. * * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in * a contract, executing them in the right order is up to the developer or operator. */ modifier reinitializer(uint8 version) { bool isTopLevelCall = _setInitializedVersion(version); if (isTopLevelCall) { _initializing = true; } _; if (isTopLevelCall) { _initializing = false; emit Initialized(version); } } /** * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the * {initializer} and {reinitializer} modifiers, directly or indirectly. */ modifier onlyInitializing() { require(_initializing, "Initializable: contract is not initializing"); _; } /** * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call. * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized * to any version. It is recommended to use this to lock implementation contracts that are designed to be called * through proxies. */ function _disableInitializers() internal virtual { _setInitializedVersion(type(uint8).max); } function _setInitializedVersion(uint8 version) private returns (bool) { // If the contract is initializing we ignore whether _initialized is set in order to support multiple // inheritance patterns, but we only do this in the context of a constructor, and for the lowest level // of initializers, because in other contexts the contract may have been reentered. if (_initializing) { require( version == 1 && !Address.isContract(address(this)), "Initializable: contract is already initialized" ); return false; } else { require(_initialized < version, "Initializable: contract is already initialized"); _initialized = version; return true; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Trees proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. * * WARNING: You should avoid using leaf values that are 64 bytes long prior to * hashing, or use a hash function other than keccak256 for hashing leaves. * This is because the concatenation of a sorted pair of internal nodes in * the merkle tree could be reinterpreted as a leaf value. */ library 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 Returns the rebuilt hash obtained by traversing a Merkle tree up * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt * hash matches the root of the tree. When processing the proof, the pairs * of leafs & pre-images are assumed to be sorted. * * _Available since v4.4._ */ function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { bytes32 proofElement = proof[i]; if (computedHash <= proofElement) { // Hash(current computed hash + current element of the proof) computedHash = _efficientHash(computedHash, proofElement); } else { // Hash(current element of the proof + current computed hash) computedHash = _efficientHash(proofElement, computedHash); } } return computedHash; } function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) { assembly { mstore(0x00, a) mstore(0x20, b) value := keccak256(0x00, 0x40) } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import {IERC2981} from "@openzeppelin/contracts/token/common/ERC2981.sol"; abstract contract ERC2981 is IERC165, IERC2981 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC2981).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /// @title Base64 /// @notice Provides a function for encoding some bytes in base64 /// @author Brecht Devos <[email protected]> library Base64 { bytes internal constant TABLE = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; /// @notice Encodes some bytes to the base64 representation function encode(bytes memory data) internal pure returns (string memory) { uint256 len = data.length; if (len == 0) return ""; // multiply by 4/3 rounded up uint256 encodedLen = 4 * ((len + 2) / 3); // Add some extra buffer at the end bytes memory result = new bytes(encodedLen + 32); bytes memory table = TABLE; // solium-disable-next-line security/no-inline-assembly assembly { let tablePtr := add(table, 1) let resultPtr := add(result, 32) for { let i := 0 } lt(i, len) { } { i := add(i, 3) let input := and(mload(add(data, i)), 0xffffff) let out := mload(add(tablePtr, and(shr(18, input), 0x3F))) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(shr(12, input), 0x3F))), 0xFF) ) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(shr(6, input), 0x3F))), 0xFF) ) out := shl(8, out) out := add( out, and(mload(add(tablePtr, and(input, 0x3F))), 0xFF) ) out := shl(224, out) mstore(resultPtr, out) resultPtr := add(resultPtr, 4) } switch mod(len, 3) case 1 { mstore(sub(resultPtr, 2), shl(240, 0x3d3d)) } case 2 { mstore(sub(resultPtr, 1), shl(248, 0x3d)) } mstore(result, encodedLen) } return string(result); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // 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 v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol) pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/common/ERC2981.sol) pragma solidity ^0.8.0; import "../../interfaces/IERC2981.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information. * * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first. * * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the * fee is specified in basis points by default. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. * * _Available since v4.5._ */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @inheritdoc IERC2981 */ function royaltyInfo(uint256 _tokenId, uint256 _salePrice) public view virtual override returns (address, uint256) { RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId]; if (royalty.receiver == address(0)) { royalty = _defaultRoyaltyInfo; } uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator(); return (royalty.receiver, royaltyAmount); } /** * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an * override. */ function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } /** * @dev Sets the royalty information that all ids in this contract will default to. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: invalid receiver"); _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Removes default royalty information. */ function _deleteDefaultRoyalty() internal virtual { delete _defaultRoyaltyInfo; } /** * @dev Sets the royalty information for a specific token id, overriding the global default. * * Requirements: * * - `tokenId` must be already minted. * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: Invalid parameters"); _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Resets royalty information for the token id back to the global default. */ function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.0; import "../utils/introspection/IERC165.sol"; /** * @dev Interface for the NFT Royalty Standard. * * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal * support for royalty payments across all NFT marketplaces and ecosystem participants. * * _Available since v4.5._ */ interface IERC2981 is IERC165 { /** * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of * exchange. The royalty amount is denominated and should be paid in that same unit of exchange. */ function royaltyInfo(uint256 tokenId, uint256 salePrice) external view returns (address receiver, uint256 royaltyAmount); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"providerAddress","type":"address"},{"internalType":"uint256","name":"maxSupply","type":"uint256"},{"internalType":"uint256","name":"reservedSupply","type":"uint256"},{"internalType":"uint256","name":"tokensPerMint","type":"uint256"},{"internalType":"address payable","name":"treasuryAddress","type":"address"}],"internalType":"struct NFTCollection.DeploymentConfig","name":"deploymentConfig","type":"tuple"},{"components":[{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"bool","name":"metadataUpdatable","type":"bool"},{"internalType":"uint256","name":"publicMintStart","type":"uint256"},{"internalType":"uint256","name":"presaleMintStart","type":"uint256"},{"internalType":"string","name":"prerevealTokenURI","type":"string"},{"internalType":"bytes32","name":"presaleMerkleRoot","type":"bytes32"},{"internalType":"uint256","name":"royaltiesBps","type":"uint256"},{"internalType":"address","name":"royaltiesAddress","type":"address"},{"internalType":"uint256","name":"mintPrice","type":"uint256"}],"internalType":"struct NFTCollection.RuntimeConfig","name":"runtimeConfig","type":"tuple"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VERSION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"availableSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"creditCardMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getInfo","outputs":[{"components":[{"internalType":"uint256","name":"version","type":"uint256"},{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"providerAddress","type":"address"},{"internalType":"uint256","name":"maxSupply","type":"uint256"},{"internalType":"uint256","name":"reservedSupply","type":"uint256"},{"internalType":"uint256","name":"tokensPerMint","type":"uint256"},{"internalType":"address payable","name":"treasuryAddress","type":"address"}],"internalType":"struct NFTCollection.DeploymentConfig","name":"deploymentConfig","type":"tuple"},{"components":[{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"bool","name":"metadataUpdatable","type":"bool"},{"internalType":"uint256","name":"publicMintStart","type":"uint256"},{"internalType":"uint256","name":"presaleMintStart","type":"uint256"},{"internalType":"string","name":"prerevealTokenURI","type":"string"},{"internalType":"bytes32","name":"presaleMerkleRoot","type":"bytes32"},{"internalType":"uint256","name":"royaltiesBps","type":"uint256"},{"internalType":"address","name":"royaltiesAddress","type":"address"},{"internalType":"uint256","name":"mintPrice","type":"uint256"}],"internalType":"struct NFTCollection.RuntimeConfig","name":"runtimeConfig","type":"tuple"}],"internalType":"struct NFTCollection.ContractInfo","name":"info","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"providerAddress","type":"address"},{"internalType":"uint256","name":"maxSupply","type":"uint256"},{"internalType":"uint256","name":"reservedSupply","type":"uint256"},{"internalType":"uint256","name":"tokensPerMint","type":"uint256"},{"internalType":"address payable","name":"treasuryAddress","type":"address"}],"internalType":"struct NFTCollection.DeploymentConfig","name":"deploymentConfig","type":"tuple"},{"components":[{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"bool","name":"metadataUpdatable","type":"bool"},{"internalType":"uint256","name":"publicMintStart","type":"uint256"},{"internalType":"uint256","name":"presaleMintStart","type":"uint256"},{"internalType":"string","name":"prerevealTokenURI","type":"string"},{"internalType":"bytes32","name":"presaleMerkleRoot","type":"bytes32"},{"internalType":"uint256","name":"royaltiesBps","type":"uint256"},{"internalType":"address","name":"royaltiesAddress","type":"address"},{"internalType":"uint256","name":"mintPrice","type":"uint256"}],"internalType":"struct NFTCollection.RuntimeConfig","name":"runtimeConfig","type":"tuple"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","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":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"isWhitelisted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"metadataUpdatable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mintingActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","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":"prerevealTokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"presaleMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"presaleMintStart","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMintStart","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"reserveMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"reservedSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"royaltyAmount","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":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tokensPerMint","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":"to","type":"address"}],"name":"transferAdminRights","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"treasuryAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"string","name":"baseURI","type":"string"},{"internalType":"bool","name":"metadataUpdatable","type":"bool"},{"internalType":"uint256","name":"publicMintStart","type":"uint256"},{"internalType":"uint256","name":"presaleMintStart","type":"uint256"},{"internalType":"string","name":"prerevealTokenURI","type":"string"},{"internalType":"bytes32","name":"presaleMerkleRoot","type":"bytes32"},{"internalType":"uint256","name":"royaltiesBps","type":"uint256"},{"internalType":"address","name":"royaltiesAddress","type":"address"},{"internalType":"uint256","name":"mintPrice","type":"uint256"}],"internalType":"struct NFTCollection.RuntimeConfig","name":"newConfig","type":"tuple"}],"name":"updateConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawFees","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b5060405162004ba638038062004ba68339810160408190526200003491620008fb565b6040805160208082018084526000808452845192830190945283825282519293919262000063929190620006c5565b50805162000079906001906020840190620006c5565b5050601a805460ff1990811660011716905550620000988282620000a0565b505062000a9c565b6000620000ae60016200031c565b90508015620000c7576007805461ff0019166101001790555b601a5460ff1615620001205760405162461bcd60e51b815260206004820152601560248201527f43616e6e6f7420626520696e697469616c697a6564000000000000000000000060448201526064015b60405180910390fd5b6200012b836200042b565b6200014660008051602062004b868339815191523362000611565b6200016b60008051602062004b8683398151915284604001516200061160201b60201c565b60408301516200017e9060009062000611565b8251805184916012916200019a918391602090910190620006c5565b506020828101518051620001b59260018501920190620006c5565b5060408201516002820180546001600160a01b03199081166001600160a01b0393841617909155606084015160038401805483169184169190911790556080840151600484015560a0840151600584015560c0840151600684015560e09093015160079092018054909316911617905581518051839160099162000241918391602090910190620006c5565b5060208281015160018301805460ff1916911515919091179055604083015160028301556060830151600383015560808301518051620002889260048501920190620006c5565b5060a0820151600582015560c0820151600682015560e08201516007820180546001600160a01b0319166001600160a01b0390921691909117905561010090910151600890910155801562000317576007805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b505050565b600754600090610100900460ff1615620003b4578160ff1660011480156200035757506200035530620006b660201b62001bef1760201c565b155b620003ab5760405162461bcd60e51b815260206004820152602e602482015260008051602062004b6683398151915260448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840162000117565b50600062000426565b60075460ff808416911610620004135760405162461bcd60e51b815260206004820152602e602482015260008051602062004b6683398151915260448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840162000117565b506007805460ff191660ff831617905560015b919050565b6000816080015111620004815760405162461bcd60e51b815260206004820152601f60248201527f4d6178696d756d20737570706c79206d757374206265206e6f6e2d7a65726f00604482015260640162000117565b60008160c0015111620004d75760405162461bcd60e51b815260206004820181905260248201527f546f6b656e7320706572206d696e74206d757374206265206e6f6e2d7a65726f604482015260640162000117565b60e08101516001600160a01b0316620005475760405162461bcd60e51b815260206004820152602b60248201527f547265617375727920616464726573732063616e6e6f7420626520746865206e60448201526a756c6c206164647265737360a81b606482015260840162000117565b60408101516001600160a01b0316620005a35760405162461bcd60e51b815260206004820152601b60248201527f436f6e7472616374206d757374206861766520616e206f776e65720000000000604482015260640162000117565b80608001518160a0015111156200060e5760405162461bcd60e51b815260206004820152602860248201527f52657365727665206d757374206265206c657373207468616e206d6178696d756044820152676d20737570706c7960c01b606482015260840162000117565b50565b60008281526006602090815260408083206001600160a01b038516845290915290205460ff16620006b25760008281526006602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620006713390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45b5050565b6001600160a01b03163b151590565b828054620006d39062000a49565b90600052602060002090601f016020900481019282620006f7576000855562000742565b82601f106200071257805160ff191683800117855562000742565b8280016001018555821562000742579182015b828111156200074257825182559160200191906001019062000725565b506200075092915062000754565b5090565b5b8082111562000750576000815560010162000755565b80516001600160a01b03811681146200042657600080fd5b805180151581146200042657600080fd5b600082601f830112620007a5578081fd5b81516001600160401b03811115620007c157620007c162000a86565b6020620007d7601f8301601f1916820162000a16565b8281528582848701011115620007eb578384fd5b835b838110156200080a578581018301518282018401528201620007ed565b838111156200081b57848385840101525b5095945050505050565b600061012080838503121562000839578182fd5b620008448162000a16565b835190925090506001600160401b03808211156200086157600080fd5b6200086f8583860162000794565b83526200087f6020850162000783565b602084015260408401516040840152606084015160608401526080840151915080821115620008ad57600080fd5b50620008bc8482850162000794565b60808301525060a082015160a082015260c082015160c0820152620008e460e083016200076b565b60e082015261010080830151818301525092915050565b600080604083850312156200090e578182fd5b82516001600160401b038082111562000925578384fd5b81850191506101008083880312156200093c578485fd5b620009478162000a16565b905082518281111562000958578586fd5b620009668882860162000794565b8252506020830151828111156200097b578586fd5b620009898882860162000794565b6020830152506200099d604084016200076b565b6040820152620009b0606084016200076b565b60608201526080830151608082015260a083015160a082015260c083015160c0820152620009e160e084016200076b565b60e08201526020860151909450915080821115620009fd578283fd5b5062000a0c8582860162000825565b9150509250929050565b604051601f8201601f191681016001600160401b038111828210171562000a415762000a4162000a86565b604052919050565b60028104600182168062000a5e57607f821691505b6020821081141562000a8057634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052604160045260246000fd5b6140ba8062000aac6000396000f3fe6080604052600436106102c95760003560e01c806370a0823111610175578063b5106add116100dc578063d5abeb0111610095578063e985e9c51161006f578063e985e9c51461081e578063f2fde38b14610867578063f4ad0f9714610887578063ffa1ad741461089c576102c9565b8063d5abeb01146107e1578063e3e1e8ef146107f6578063e8a3d48514610809576102c9565b8063b5106add14610723578063b88d4fde14610743578063bfbbb0ad14610763578063c5f956af14610783578063c87b56dd146107a1578063d547741f146107c1576102c9565b806391d148541161012e57806391d148541461068657806395d89b41146106a6578063a0712d68146106bb578063a217fddf146106ce578063a22cb465146106e3578063b0ea180214610703576102c9565b806370a08231146105e957806375b238fc146106095780637ecc2b561461062b57806385e3aac6146106405780638cfec4c0146106535780638da5cb5b14610668576102c9565b806331f9c919116102345780634e6f9dd6116101ed5780635a9b0b89116101c75780635a9b0b891461057d5780636352211e1461059f5780636817c76c146105bf5780636c0360eb146105d4576102c9565b80634e6f9dd61461052e57806353135ca0146105465780635a23dd991461055d576102c9565b806331f9c9191461049857806336568abe146104af57806342842e0e146104cf57806344d19d2b146104ef5780634653124b14610504578063476343ee14610519576102c9565b806318160ddd1161028657806318160ddd146103be57806322212e2b146103d457806323b872dd146103e9578063248a9ca3146104095780632a55205a146104395780632f2ff15d14610478576102c9565b806301ffc9a7146102ce57806306fdde03146103035780630726d086146103255780630807b9e214610347578063081812fc14610366578063095ea7b31461039e575b600080fd5b3480156102da57600080fd5b506102ee6102e9366004613574565b6108b2565b60405190151581526020015b60405180910390f35b34801561030f57600080fd5b506103186108ef565b6040516102fa9190613a33565b34801561033157600080fd5b506103456103403660046136b2565b610984565b005b34801561035357600080fd5b506018545b6040519081526020016102fa565b34801561037257600080fd5b50610386610381366004613538565b6109b8565b6040516001600160a01b0390911681526020016102fa565b3480156103aa57600080fd5b506103456103b93660046134f1565b610a52565b3480156103ca57600080fd5b5061035860085481565b3480156103e057600080fd5b50600e54610358565b3480156103f557600080fd5b506103456104043660046133b6565b610b68565b34801561041557600080fd5b50610358610424366004613538565b60009081526006602052604090206001015490565b34801561044557600080fd5b5061045961045436600461371a565b610b99565b604080516001600160a01b0390931683526020830191909152016102fa565b34801561048457600080fd5b50610345610493366004613550565b610bd0565b3480156104a457600080fd5b50600b5442116102ee565b3480156104bb57600080fd5b506103456104ca366004613550565b610bf5565b3480156104db57600080fd5b506103456104ea3660046133b6565b610c73565b3480156104fb57600080fd5b50601754610358565b34801561051057600080fd5b50600c54610358565b34801561052557600080fd5b50610345610c8e565b34801561053a57600080fd5b50600a5460ff166102ee565b34801561055257600080fd5b50600c5442116102ee565b34801561056957600080fd5b506102ee610578366004613472565b610cbf565b34801561058957600080fd5b50610592610d9d565b6040516102fa9190613b62565b3480156105ab57600080fd5b506103866105ba366004613538565b6110cb565b3480156105cb57600080fd5b50601154610358565b3480156105e057600080fd5b50610318611142565b3480156105f557600080fd5b50610358610604366004613362565b611154565b34801561061557600080fd5b5061035860008051602061406583398151915281565b34801561063757600080fd5b506103586111db565b61034561064e3660046134f1565b611200565b34801561065f57600080fd5b50600b54610358565b34801561067457600080fd5b506014546001600160a01b0316610386565b34801561069257600080fd5b506102ee6106a1366004613550565b611308565b3480156106b257600080fd5b50610318611333565b6103456106c9366004613538565b611345565b3480156106da57600080fd5b50610358600081565b3480156106ef57600080fd5b506103456106fe3660046134c4565b6113ce565b34801561070f57600080fd5b5061034561071e3660046134f1565b6113d9565b34801561072f57600080fd5b5061034561073e366004613362565b61145e565b34801561074f57600080fd5b5061034561075e3660046133f6565b611551565b34801561076f57600080fd5b5061034561077e3660046135ac565b611583565b34801561078f57600080fd5b506019546001600160a01b0316610386565b3480156107ad57600080fd5b506103186107bc366004613538565b6117d4565b3480156107cd57600080fd5b506103456107dc366004613550565b61190d565b3480156107ed57600080fd5b50601654610358565b6103456108043660046136ea565b611932565b34801561081557600080fd5b50610318611a2c565b34801561082a57600080fd5b506102ee61083936600461337e565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b34801561087357600080fd5b50610345610882366004613362565b611aa9565b34801561089357600080fd5b50610318611bdd565b3480156108a857600080fd5b506103586127d881565b60006108bd82611bfe565b806108cc57506108cc82611c4e565b806108e7575063152a902d60e11b6001600160e01b03198316145b90505b919050565b60606012600001805461090190613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461092d90613e5f565b801561097a5780601f1061094f5761010080835404028352916020019161097a565b820191906000526020600020905b81548152906001019060200180831161095d57829003601f168201915b5050505050905090565b60008051602061406583398151915261099c81611c83565b6109a582611c8d565b8160096109b28282613f25565b50505050565b6000818152600260205260408120546001600160a01b0316610a365760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6000610a5d826110cb565b9050806001600160a01b0316836001600160a01b03161415610acb5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610a2d565b336001600160a01b0382161480610ae75750610ae78133610839565b610b595760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610a2d565b610b638383611dea565b505050565b610b723382611e58565b610b8e5760405162461bcd60e51b8152600401610a2d90613b11565b610b63838383611f4f565b601054600f546001600160a01b039091169060009061271090610bbd908590613cd4565b610bc79190613cc0565b90509250929050565b600082815260066020526040902060010154610beb81611c83565b610b6383836120eb565b6001600160a01b0381163314610c655760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610a2d565b610c6f8282612171565b5050565b610b6383838360405180602001604052806000815250611551565b600080516020614065833981519152610ca681611c83565b601954610cbc906001600160a01b0316476121d8565b50565b6001600160a01b0383166000908152601b602052604081205460ff1615610d195760405162461bcd60e51b815260206004820152600e60248201526d105b1c9958591e481b5a5b9d195960921b6044820152606401610a2d565b6040516bffffffffffffffffffffffff19606086901b166020820152600090603401604051602081830303815290604052805190602001209050610d9484848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600e5491508490506122f1565b95945050505050565b610da5613052565b6127d881526040805161010081019091526012805482908290610dc790613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610df390613e5f565b8015610e405780601f10610e1557610100808354040283529160200191610e40565b820191906000526020600020905b815481529060010190602001808311610e2357829003601f168201915b50505050508152602001600182018054610e5990613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610e8590613e5f565b8015610ed25780601f10610ea757610100808354040283529160200191610ed2565b820191906000526020600020905b815481529060010190602001808311610eb557829003601f168201915b505050918352505060028201546001600160a01b03908116602080840191909152600384015482166040808501919091526004850154606085015260058501546080850152600685015460a085015260079094015490911660c090920191909152830191909152805161012081019091526009805482908290610f5490613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610f8090613e5f565b8015610fcd5780601f10610fa257610100808354040283529160200191610fcd565b820191906000526020600020905b815481529060010190602001808311610fb057829003601f168201915b5050509183525050600182015460ff1615156020820152600282015460408201526003820154606082015260048201805460809092019161100d90613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461103990613e5f565b80156110865780601f1061105b57610100808354040283529160200191611086565b820191906000526020600020905b81548152906001019060200180831161106957829003601f168201915b505050918352505060058201546020820152600682015460408083019190915260078301546001600160a01b0316606083015260089092015460809091015282015290565b6000818152600260205260408120546001600160a01b0316806108e75760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610a2d565b60606009600001805461090190613e5f565b60006001600160a01b0382166111bf5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610a2d565b506001600160a01b031660009081526003602052604090205490565b601754600854601654600092916111f191613cf3565b6111fb9190613cf3565b905090565b601154819061120f9082613cd4565b34101561122e5760405162461bcd60e51b8152600401610a2d90613a98565b600b54421161127f5760405162461bcd60e51b815260206004820152601b60248201527f4d696e74696e6720686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b73dab1a1854214684ace522439684a145e6250523333146112fe5760405162461bcd60e51b815260206004820152603360248201527f546869732066756e6374696f6e20697320726573657276656420666f7220637260448201527232b234ba16b1b0b932103830bcb6b2b73a399760691b6064820152608401610a2d565b610b638383612307565b60009182526006602090815260408084206001600160a01b0393909316845291905290205460ff1690565b60606012600101805461090190613e5f565b60115481906113549082613cd4565b3410156113735760405162461bcd60e51b8152600401610a2d90613a98565b600b5442116113c45760405162461bcd60e51b815260206004820152601b60248201527f4d696e74696e6720686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b610c6f3383612307565b610c6f3383836123ef565b6000805160206140658339815191526113f181611c83565b6017548211156114395760405162461bcd60e51b8152602060048201526013602482015272139bdd08195b9bdd59da081c995cd95c9d9959606a1b6044820152606401610a2d565b816012600501600082825461144e9190613cf3565b90915550610b63905083836124be565b60008051602061406583398151915261147681611c83565b61148e60008051602061406583398151915283611308565b156114ce5760405162461bcd60e51b815260206004820152601060248201526f20b63932b0b23c9030b71030b236b4b760811b6044820152606401610a2d565b6014546001600160a01b03163314156115215760405162461bcd60e51b81526020600482015260156024820152740557365207472616e736665724f776e65727368697605c1b6044820152606401610a2d565b61153960008051602061406583398151915233612171565b610c6f600080516020614065833981519152836120eb565b61155b3383611e58565b6115775760405162461bcd60e51b8152600401610a2d90613b11565b6109b284848484612554565b600061158f6001612587565b905080156115a7576007805461ff0019166101001790555b601a5460ff16156115f25760405162461bcd60e51b815260206004820152601560248201527410d85b9b9bdd081899481a5b9a5d1a585b1a5e9959605a1b6044820152606401610a2d565b6115fb8361260e565b611613600080516020614065833981519152336120eb565b61162f60008051602061406583398151915284604001516120eb565b6116406000801b84604001516120eb565b82518051849160129161165a91839160209091019061312e565b506020828101518051611673926001850192019061312e565b5060408201516002820180546001600160a01b03199081166001600160a01b0393841617909155606084015160038401805483169184169190911790556080840151600484015560a0840151600584015560c0840151600684015560e0909301516007909201805490931691161790558151805183916009916116fd91839160209091019061312e565b5060208281015160018301805460ff1916911515919091179055604083015160028301556060830151600383015560808301518051611742926004850192019061312e565b5060a0820151600582015560c0820151600682015560e08201516007820180546001600160a01b0319166001600160a01b03909216919091179055610100909101516008909101558015610b63576007805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a1505050565b6000818152600260205260409020546060906001600160a01b03166118325760405162461bcd60e51b8152602060048201526014602482015273151bdad95b88191bd95cc81b9bdd08195e1a5cdd60621b6044820152606401610a2d565b60006009600001805461184490613e5f565b9050116118db57600d805461185890613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461188490613e5f565b80156118d15780601f106118a6576101008083540402835291602001916118d1565b820191906000526020600020905b8154815290600101906020018083116118b457829003601f168201915b50505050506108e7565b60096118e6836127e7565b6040516020016118f7929190613890565b6040516020818303038152906040529050919050565b60008281526006602052604090206001015461192881611c83565b610b638383612171565b60115483906119419082613cd4565b3410156119605760405162461bcd60e51b8152600401610a2d90613a98565b600c5442116119b15760405162461bcd60e51b815260206004820152601b60248201527f50726573616c6520686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b6119bc338484610cbf565b611a085760405162461bcd60e51b815260206004820152601b60248201527f4e6f742077686974656c697374656420666f722070726573616c6500000000006044820152606401610a2d565b336000818152601b60205260409020805460ff191660011790556109b29085612307565b60606000611a7d611a416009600601546127e7565b601054611a58906001600160a01b03166014612901565b604051602001611a699291906138b5565b604051602081830303815290604052612ae9565b9050600081604051602001611a92919061393c565b60408051601f198184030181529190529250505090565b6000611ab481611c83565b6014546001600160a01b0383811691161415611b065760405162461bcd60e51b815260206004820152601160248201527020b63932b0b23c903a34329037bbb732b960791b6044820152606401610a2d565b601454611b2b90600080516020614065833981519152906001600160a01b0316612171565b601454611b43906000906001600160a01b0316612171565b601480546001600160a01b038481166001600160a01b03198316179283905590811691611b809160008051602061406583398151915291166120eb565b601454611b98906000906001600160a01b03166120eb565b826001600160a01b0316816001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3505050565b60606009600401805461090190613e5f565b6001600160a01b03163b151590565b60006001600160e01b031982166380ac58cd60e01b1480611c2f57506001600160e01b03198216635b5e139f60e01b145b806108e757506301ffc9a760e01b6001600160e01b03198316146108e7565b60006001600160e01b03198216637965db0b60e01b14806108e7575063152a902d60e11b6001600160e01b03198316146108e7565b610cbc8133612c5c565b61271060c08201351115611cd85760405162461bcd60e51b81526020600482015260126024820152710a4def2c2d8e8d2cae640e8dede40d0d2ced60731b6044820152606401610a2d565b600a5460ff1615611ce857610cbc565b611cf8604082016020830161351c565b600a5460ff16151590151514611d505760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420756e667265657a65206d6574616461746100000000000000006044820152606401610a2d565b611d5a8180613c34565b604051602001611d6b929190613874565b60408051601f1981840301815290829052805160209182012091611d929160099101613884565b6040516020818303038152906040528051906020012014610cbc5760405162461bcd60e51b815260206004820152601260248201527126b2ba30b230ba309034b990333937bd32b760711b6044820152606401610a2d565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611e1f826110cb565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b0316611ed15760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610a2d565b6000611edc836110cb565b9050806001600160a01b0316846001600160a01b03161480611f2357506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b80611f475750836001600160a01b0316611f3c846109b8565b6001600160a01b0316145b949350505050565b826001600160a01b0316611f62826110cb565b6001600160a01b031614611fc65760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610a2d565b6001600160a01b0382166120285760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610a2d565b612033600082611dea565b6001600160a01b038316600090815260036020526040812080546001929061205c908490613cf3565b90915550506001600160a01b038216600090815260036020526040812080546001929061208a908490613ca8565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4610b63565b6120f58282611308565b610c6f5760008281526006602090815260408083206001600160a01b03851684529091529020805460ff1916600117905561212d3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b61217b8282611308565b15610c6f5760008281526006602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b804710156122285760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610a2d565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612275576040519150601f19603f3d011682016040523d82523d6000602084013e61227a565b606091505b5050905080610b635760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610a2d565b6000826122fe8584612cc0565b14949350505050565b60185481111561234c5760405162461bcd60e51b815260206004820152601060248201526f416d6f756e7420746f6f206c6172676560801b6044820152606401610a2d565b6123546111db565b81111561239c5760405162461bcd60e51b8152602060048201526016602482015275139bdd08195b9bdd59da081d1bdad95b9cc81b19599d60521b6044820152606401610a2d565b80600860008282546123ae9190613ca8565b909155506123bc9050612d42565b60015b818111610b63576123dd83826008546123d89190613cf3565b612d9d565b806123e781613e9a565b9150506123bf565b816001600160a01b0316836001600160a01b031614156124515760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610a2d565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6124c66111db565b81111561250e5760405162461bcd60e51b8152602060048201526016602482015275139bdd08195b9bdd59da081d1bdad95b9cc81b19599d60521b6044820152606401610a2d565b80600860008282546125209190613ca8565b90915550600190505b818111610b635761254283826008546123d89190613cf3565b8061254c81613e9a565b915050612529565b61255f848484611f4f565b61256b84848484612db7565b6109b25760405162461bcd60e51b8152600401610a2d90613a46565b600754600090610100900460ff16156125d0578160ff1660011480156125ac5750303b155b6125c85760405162461bcd60e51b8152600401610a2d90613ac3565b5060006108ea565b60075460ff8084169116106125f75760405162461bcd60e51b8152600401610a2d90613ac3565b506007805460ff191660ff831617905560016108ea565b60008160800151116126625760405162461bcd60e51b815260206004820152601f60248201527f4d6178696d756d20737570706c79206d757374206265206e6f6e2d7a65726f006044820152606401610a2d565b60008160c00151116126b65760405162461bcd60e51b815260206004820181905260248201527f546f6b656e7320706572206d696e74206d757374206265206e6f6e2d7a65726f6044820152606401610a2d565b60e08101516001600160a01b03166127245760405162461bcd60e51b815260206004820152602b60248201527f547265617375727920616464726573732063616e6e6f7420626520746865206e60448201526a756c6c206164647265737360a81b6064820152608401610a2d565b60408101516001600160a01b031661277e5760405162461bcd60e51b815260206004820152601b60248201527f436f6e7472616374206d757374206861766520616e206f776e657200000000006044820152606401610a2d565b80608001518160a001511115610cbc5760405162461bcd60e51b815260206004820152602860248201527f52657365727665206d757374206265206c657373207468616e206d6178696d756044820152676d20737570706c7960c01b6064820152608401610a2d565b60608161280c57506040805180820190915260018152600360fc1b60208201526108ea565b8160005b8115612836578061282081613e9a565b915061282f9050600a83613cc0565b9150612810565b6000816001600160401b0381111561285e57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612888576020820181803683370190505b5090505b8415611f475761289d600183613cf3565b91506128aa600a86613eb5565b6128b5906030613ca8565b60f81b8183815181106128d857634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053506128fa600a86613cc0565b945061288c565b60606000612910836002613cd4565b61291b906002613ca8565b6001600160401b0381111561294057634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561296a576020820181803683370190505b509050600360fc1b8160008151811061299357634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106129d057634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060006129f4846002613cd4565b6129ff906001613ca8565b90505b6001811115612a93576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110612a4157634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110612a6557634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060049490941c93612a8c81613e48565b9050612a02565b508315612ae25760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610a2d565b9392505050565b805160609080612b095750506040805160208101909152600081526108ea565b60006003612b18836002613ca8565b612b229190613cc0565b612b2d906004613cd4565b90506000612b3c826020613ca8565b6001600160401b03811115612b6157634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612b8b576020820181803683370190505b5090506000604051806060016040528060408152602001614025604091399050600181016020830160005b86811015612c17576003818a01810151603f601282901c8116860151600c83901c8216870151600684901c831688015192909316870151600891821b60ff94851601821b92841692909201901b91160160e01b835260049092019101612bb6565b506003860660018114612c315760028114612c4257612c4e565b613d3d60f01b600119830152612c4e565b603d60f81b6000198301525b505050918152949350505050565b612c668282611308565b610c6f57612c7e816001600160a01b03166014612901565b612c89836020612901565b604051602001612c9a929190613981565b60408051601f198184030181529082905262461bcd60e51b8252610a2d91600401613a33565b600081815b8451811015612d3a576000858281518110612cf057634e487b7160e01b600052603260045260246000fd5b60200260200101519050808311612d165760008381526020829052604090209250612d27565b600081815260208490526040902092505b5080612d3281613e9a565b915050612cc5565b509392505050565b3415612d9b576000612d60612d59346103e8612ec4565b6019612ed0565b6015546040519192506001600160a01b03169082156108fc029083906000818181858888f19350505050158015610c6f573d6000803e3d6000fd5b565b610c6f828260405180602001604052806000815250612edc565b60006001600160a01b0384163b15612eb957604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612dfb9033908990889088906004016139f6565b602060405180830381600087803b158015612e1557600080fd5b505af1925050508015612e45575060408051601f3d908101601f19168201909252612e4291810190613590565b60015b612e9f573d808015612e73576040519150601f19603f3d011682016040523d82523d6000602084013e612e78565b606091505b508051612e975760405162461bcd60e51b8152600401610a2d90613a46565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611f47565b506001949350505050565b6000612ae28284613cc0565b6000612ae28284613cd4565b612ee68383612f0f565b612ef36000848484612db7565b610b635760405162461bcd60e51b8152600401610a2d90613a46565b6001600160a01b038216612f655760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610a2d565b6000818152600260205260409020546001600160a01b031615612fca5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610a2d565b6001600160a01b0382166000908152600360205260408120805460019290612ff3908490613ca8565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4610c6f565b6040518060600160405280600081526020016130c7604051806101000160405280606081526020016060815260200160006001600160a01b0316815260200160006001600160a01b0316815260200160008152602001600081526020016000815260200160006001600160a01b031681525090565b815260200161312960405180610120016040528060608152602001600015158152602001600081526020016000815260200160608152602001600080191681526020016000815260200160006001600160a01b03168152602001600081525090565b905290565b82805461313a90613e5f565b90600052602060002090601f01602090048101928261315c57600085556131a2565b82601f1061317557805160ff19168380011785556131a2565b828001600101855582156131a2579182015b828111156131a2578251825591602001919060010190613187565b506131ae9291506131b2565b5090565b5b808211156131ae57600081556001016131b3565b60006001600160401b038311156131e0576131e0613ef5565b6131f3601f8401601f1916602001613c78565b905082815283838301111561320757600080fd5b828260208301376000602084830101529392505050565b80356108ea81613feb565b60008083601f84011261323a578182fd5b5081356001600160401b03811115613250578182fd5b602083019150836020808302850101111561326a57600080fd5b9250929050565b80356108ea81614000565b600082601f83011261328c578081fd5b612ae2838335602085016131c7565b60006101208083850312156132ae578182fd5b6132b781613c78565b91505081356001600160401b03808211156132d157600080fd5b6132dd8583860161327c565b83526132eb60208501613271565b60208401526040840135604084015260608401356060840152608084013591508082111561331857600080fd5b506133258482850161327c565b60808301525060a082013560a082015260c082013560c082015261334b60e0830161321e565b60e082015261010080830135818301525092915050565b600060208284031215613373578081fd5b8135612ae281613feb565b60008060408385031215613390578081fd5b823561339b81613feb565b915060208301356133ab81613feb565b809150509250929050565b6000806000606084860312156133ca578081fd5b83356133d581613feb565b925060208401356133e581613feb565b929592945050506040919091013590565b6000806000806080858703121561340b578081fd5b843561341681613feb565b9350602085013561342681613feb565b92506040850135915060608501356001600160401b03811115613447578182fd5b8501601f81018713613457578182fd5b613466878235602084016131c7565b91505092959194509250565b600080600060408486031215613486578283fd5b833561349181613feb565b925060208401356001600160401b038111156134ab578283fd5b6134b786828701613229565b9497909650939450505050565b600080604083850312156134d6578182fd5b82356134e181613feb565b915060208301356133ab81614000565b60008060408385031215613503578081fd5b823561350e81613feb565b946020939093013593505050565b60006020828403121561352d578081fd5b8135612ae281614000565b600060208284031215613549578081fd5b5035919050565b60008060408385031215613562578182fd5b8235915060208301356133ab81613feb565b600060208284031215613585578081fd5b8135612ae28161400e565b6000602082840312156135a1578081fd5b8151612ae28161400e565b600080604083850312156135be578182fd5b82356001600160401b03808211156135d4578384fd5b81850191506101008083880312156135ea578485fd5b6135f381613c78565b9050823582811115613603578586fd5b61360f8882860161327c565b825250602083013582811115613623578586fd5b61362f8882860161327c565b6020830152506136416040840161321e565b60408201526136526060840161321e565b60608201526080830135608082015260a083013560a082015260c083013560c082015261368160e0840161321e565b60e08201529350602085013591508082111561369b578283fd5b506136a88582860161329b565b9150509250929050565b6000602082840312156136c3578081fd5b81356001600160401b038111156136d8578182fd5b82016101208185031215612ae2578182fd5b6000806000604084860312156136fe578081fd5b8335925060208401356001600160401b038111156134ab578182fd5b6000806040838503121561372c578182fd5b50508035926020909101359150565b60008151808452613753816020860160208601613e1c565b601f01601f19169290920160200192915050565b6000815461377481613e5f565b6001828116801561378c576001811461379d576137cc565b60ff198416875282870194506137cc565b8560005260208060002060005b858110156137c35781548a8201529084019082016137aa565b50505082870194505b5050505092915050565b600061012082518185526137ec8286018261373b565b9150506020830151613802602086018215159052565b5060408301516040850152606083015160608501526080830151848203608086015261382e828261373b565b91505060a083015160a085015260c083015160c085015260e083015161385f60e08601826001600160a01b03169052565b50610100928301519390920192909252919050565b6000828483379101908152919050565b6000612ae28284613767565b600061389c8285613767565b83516138ac818360208801613e1c565b01949350505050565b60007f7b2273656c6c65725f6665655f62617369735f706f696e7473223a2000000000825283516138ed81601c850160208801613e1c565b731610113332b2afb932b1b4b834b2b73a111d101160611b601c918401918201528351613921816030840160208801613e1c565b61227d60f01b60309290910191820152603201949350505050565b60007f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008252825161397481601d850160208701613e1c565b91909101601d0192915050565b60007f416363657373436f6e74726f6c3a206163636f756e7420000000000000000000825283516139b9816017850160208801613e1c565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516139ea816028840160208801613e1c565b01602801949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090613a299083018461373b565b9695505050505050565b600060208252612ae2602083018461373b565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526011908201527014185e5b595b9d081d1bdbc81cdb585b1b607a1b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600060208252825160208301526020830151606060408401528051610100806080860152613b9461018086018361373b565b91506020830151607f198684030160a0870152613bb1838261373b565b60408501516001600160a01b031660c088015260608501519093509050613be360e08701826001600160a01b03169052565b5060808301519085015260a082015161012085015260c082015161014085015260e0909101516001600160a01b03166101608401526040840151838203601f1901606085015290610d9481836137d6565b6000808335601e19843603018112613c4a578283fd5b8301803591506001600160401b03821115613c63578283fd5b60200191503681900382131561326a57600080fd5b604051601f8201601f191681016001600160401b0381118282101715613ca057613ca0613ef5565b604052919050565b60008219821115613cbb57613cbb613ec9565b500190565b600082613ccf57613ccf613edf565b500490565b6000816000190483118215151615613cee57613cee613ec9565b500290565b600082821015613d0557613d05613ec9565b500390565b5b81811015610c6f5760008155600101613d0b565b6001600160401b03831115613d3657613d36613ef5565b613d408154613e5f565b600080601f8611601f841181811715613d5f5760008681526020902092505b8015613d8e576020601f89010483016020891015613d7a5750825b613d8c6020601f880104850182613d0a565b505b508060018114613dc057600094508715613da9578387013594505b6002880260001960088a021c198616178655613e12565b601f198816945082845b86811015613dea5788860135825560209586019560019092019101613dca565b5088861015613e0757878501356000196008601f8c16021c191681555b506001600289020186555b5050505050505050565b60005b83811015613e37578181015183820152602001613e1f565b838111156109b25750506000910152565b600081613e5757613e57613ec9565b506000190190565b600281046001821680613e7357607f821691505b60208210811415613e9457634e487b7160e01b600052602260045260246000fd5b50919050565b6000600019821415613eae57613eae613ec9565b5060010190565b600082613ec457613ec4613edf565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b600081356108e781613feb565b600081356108e781614000565b613f2f8283613c34565b613f3a818385613d1f565b5050613f64613f4b60208401613f18565b6001830160ff1981541660ff8315151681178255505050565b6040820135600282015560608201356003820155613f856080830183613c34565b613f93818360048601613d1f565b505060a0820135600582015560c08201356006820155613fdc613fb860e08401613f0b565b6007830180546001600160a01b0319166001600160a01b0392909216919091179055565b61010082013560088201555050565b6001600160a01b0381168114610cbc57600080fd5b8015158114610cbc57600080fd5b6001600160e01b031981168114610cbc57600080fdfe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775a26469706673582212207b41652e445fa0392886a6af5567f7cc1bfd9c96328127ede2b17f188c06979a64736f6c63430008020033496e697469616c697a61626c653a20636f6e747261637420697320616c726561a49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001c000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000c00a9ba526583c49a08416cee0c7ffc54c2154f4000000000000000000000000c048b5757bee085712ce5aecac987c471d9f0f9200000000000000000000000000000000000000000000000000000000000020d000000000000000000000000000000000000000000000000000000000000001f4000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba0000000000000000000000000000000000000000000000000000000000000008534d504c46524b530000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008534d504c46524b530000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000636ffb4000000000000000000000000000000000000000000000000000000000634b03300000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002ee000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba00000000000000000000000000000000000000000000000000354a6ba7a1800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035697066733a2f2f516d544a56584a68614d635844557958796a36435a557161437a4331674a69637a4b396d4e5051585451505978770000000000000000000000
Deployed Bytecode
0x6080604052600436106102c95760003560e01c806370a0823111610175578063b5106add116100dc578063d5abeb0111610095578063e985e9c51161006f578063e985e9c51461081e578063f2fde38b14610867578063f4ad0f9714610887578063ffa1ad741461089c576102c9565b8063d5abeb01146107e1578063e3e1e8ef146107f6578063e8a3d48514610809576102c9565b8063b5106add14610723578063b88d4fde14610743578063bfbbb0ad14610763578063c5f956af14610783578063c87b56dd146107a1578063d547741f146107c1576102c9565b806391d148541161012e57806391d148541461068657806395d89b41146106a6578063a0712d68146106bb578063a217fddf146106ce578063a22cb465146106e3578063b0ea180214610703576102c9565b806370a08231146105e957806375b238fc146106095780637ecc2b561461062b57806385e3aac6146106405780638cfec4c0146106535780638da5cb5b14610668576102c9565b806331f9c919116102345780634e6f9dd6116101ed5780635a9b0b89116101c75780635a9b0b891461057d5780636352211e1461059f5780636817c76c146105bf5780636c0360eb146105d4576102c9565b80634e6f9dd61461052e57806353135ca0146105465780635a23dd991461055d576102c9565b806331f9c9191461049857806336568abe146104af57806342842e0e146104cf57806344d19d2b146104ef5780634653124b14610504578063476343ee14610519576102c9565b806318160ddd1161028657806318160ddd146103be57806322212e2b146103d457806323b872dd146103e9578063248a9ca3146104095780632a55205a146104395780632f2ff15d14610478576102c9565b806301ffc9a7146102ce57806306fdde03146103035780630726d086146103255780630807b9e214610347578063081812fc14610366578063095ea7b31461039e575b600080fd5b3480156102da57600080fd5b506102ee6102e9366004613574565b6108b2565b60405190151581526020015b60405180910390f35b34801561030f57600080fd5b506103186108ef565b6040516102fa9190613a33565b34801561033157600080fd5b506103456103403660046136b2565b610984565b005b34801561035357600080fd5b506018545b6040519081526020016102fa565b34801561037257600080fd5b50610386610381366004613538565b6109b8565b6040516001600160a01b0390911681526020016102fa565b3480156103aa57600080fd5b506103456103b93660046134f1565b610a52565b3480156103ca57600080fd5b5061035860085481565b3480156103e057600080fd5b50600e54610358565b3480156103f557600080fd5b506103456104043660046133b6565b610b68565b34801561041557600080fd5b50610358610424366004613538565b60009081526006602052604090206001015490565b34801561044557600080fd5b5061045961045436600461371a565b610b99565b604080516001600160a01b0390931683526020830191909152016102fa565b34801561048457600080fd5b50610345610493366004613550565b610bd0565b3480156104a457600080fd5b50600b5442116102ee565b3480156104bb57600080fd5b506103456104ca366004613550565b610bf5565b3480156104db57600080fd5b506103456104ea3660046133b6565b610c73565b3480156104fb57600080fd5b50601754610358565b34801561051057600080fd5b50600c54610358565b34801561052557600080fd5b50610345610c8e565b34801561053a57600080fd5b50600a5460ff166102ee565b34801561055257600080fd5b50600c5442116102ee565b34801561056957600080fd5b506102ee610578366004613472565b610cbf565b34801561058957600080fd5b50610592610d9d565b6040516102fa9190613b62565b3480156105ab57600080fd5b506103866105ba366004613538565b6110cb565b3480156105cb57600080fd5b50601154610358565b3480156105e057600080fd5b50610318611142565b3480156105f557600080fd5b50610358610604366004613362565b611154565b34801561061557600080fd5b5061035860008051602061406583398151915281565b34801561063757600080fd5b506103586111db565b61034561064e3660046134f1565b611200565b34801561065f57600080fd5b50600b54610358565b34801561067457600080fd5b506014546001600160a01b0316610386565b34801561069257600080fd5b506102ee6106a1366004613550565b611308565b3480156106b257600080fd5b50610318611333565b6103456106c9366004613538565b611345565b3480156106da57600080fd5b50610358600081565b3480156106ef57600080fd5b506103456106fe3660046134c4565b6113ce565b34801561070f57600080fd5b5061034561071e3660046134f1565b6113d9565b34801561072f57600080fd5b5061034561073e366004613362565b61145e565b34801561074f57600080fd5b5061034561075e3660046133f6565b611551565b34801561076f57600080fd5b5061034561077e3660046135ac565b611583565b34801561078f57600080fd5b506019546001600160a01b0316610386565b3480156107ad57600080fd5b506103186107bc366004613538565b6117d4565b3480156107cd57600080fd5b506103456107dc366004613550565b61190d565b3480156107ed57600080fd5b50601654610358565b6103456108043660046136ea565b611932565b34801561081557600080fd5b50610318611a2c565b34801561082a57600080fd5b506102ee61083936600461337e565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b34801561087357600080fd5b50610345610882366004613362565b611aa9565b34801561089357600080fd5b50610318611bdd565b3480156108a857600080fd5b506103586127d881565b60006108bd82611bfe565b806108cc57506108cc82611c4e565b806108e7575063152a902d60e11b6001600160e01b03198316145b90505b919050565b60606012600001805461090190613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461092d90613e5f565b801561097a5780601f1061094f5761010080835404028352916020019161097a565b820191906000526020600020905b81548152906001019060200180831161095d57829003601f168201915b5050505050905090565b60008051602061406583398151915261099c81611c83565b6109a582611c8d565b8160096109b28282613f25565b50505050565b6000818152600260205260408120546001600160a01b0316610a365760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6000610a5d826110cb565b9050806001600160a01b0316836001600160a01b03161415610acb5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610a2d565b336001600160a01b0382161480610ae75750610ae78133610839565b610b595760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610a2d565b610b638383611dea565b505050565b610b723382611e58565b610b8e5760405162461bcd60e51b8152600401610a2d90613b11565b610b63838383611f4f565b601054600f546001600160a01b039091169060009061271090610bbd908590613cd4565b610bc79190613cc0565b90509250929050565b600082815260066020526040902060010154610beb81611c83565b610b6383836120eb565b6001600160a01b0381163314610c655760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610a2d565b610c6f8282612171565b5050565b610b6383838360405180602001604052806000815250611551565b600080516020614065833981519152610ca681611c83565b601954610cbc906001600160a01b0316476121d8565b50565b6001600160a01b0383166000908152601b602052604081205460ff1615610d195760405162461bcd60e51b815260206004820152600e60248201526d105b1c9958591e481b5a5b9d195960921b6044820152606401610a2d565b6040516bffffffffffffffffffffffff19606086901b166020820152600090603401604051602081830303815290604052805190602001209050610d9484848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050600e5491508490506122f1565b95945050505050565b610da5613052565b6127d881526040805161010081019091526012805482908290610dc790613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610df390613e5f565b8015610e405780601f10610e1557610100808354040283529160200191610e40565b820191906000526020600020905b815481529060010190602001808311610e2357829003601f168201915b50505050508152602001600182018054610e5990613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610e8590613e5f565b8015610ed25780601f10610ea757610100808354040283529160200191610ed2565b820191906000526020600020905b815481529060010190602001808311610eb557829003601f168201915b505050918352505060028201546001600160a01b03908116602080840191909152600384015482166040808501919091526004850154606085015260058501546080850152600685015460a085015260079094015490911660c090920191909152830191909152805161012081019091526009805482908290610f5490613e5f565b80601f0160208091040260200160405190810160405280929190818152602001828054610f8090613e5f565b8015610fcd5780601f10610fa257610100808354040283529160200191610fcd565b820191906000526020600020905b815481529060010190602001808311610fb057829003601f168201915b5050509183525050600182015460ff1615156020820152600282015460408201526003820154606082015260048201805460809092019161100d90613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461103990613e5f565b80156110865780601f1061105b57610100808354040283529160200191611086565b820191906000526020600020905b81548152906001019060200180831161106957829003601f168201915b505050918352505060058201546020820152600682015460408083019190915260078301546001600160a01b0316606083015260089092015460809091015282015290565b6000818152600260205260408120546001600160a01b0316806108e75760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610a2d565b60606009600001805461090190613e5f565b60006001600160a01b0382166111bf5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610a2d565b506001600160a01b031660009081526003602052604090205490565b601754600854601654600092916111f191613cf3565b6111fb9190613cf3565b905090565b601154819061120f9082613cd4565b34101561122e5760405162461bcd60e51b8152600401610a2d90613a98565b600b54421161127f5760405162461bcd60e51b815260206004820152601b60248201527f4d696e74696e6720686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b73dab1a1854214684ace522439684a145e6250523333146112fe5760405162461bcd60e51b815260206004820152603360248201527f546869732066756e6374696f6e20697320726573657276656420666f7220637260448201527232b234ba16b1b0b932103830bcb6b2b73a399760691b6064820152608401610a2d565b610b638383612307565b60009182526006602090815260408084206001600160a01b0393909316845291905290205460ff1690565b60606012600101805461090190613e5f565b60115481906113549082613cd4565b3410156113735760405162461bcd60e51b8152600401610a2d90613a98565b600b5442116113c45760405162461bcd60e51b815260206004820152601b60248201527f4d696e74696e6720686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b610c6f3383612307565b610c6f3383836123ef565b6000805160206140658339815191526113f181611c83565b6017548211156114395760405162461bcd60e51b8152602060048201526013602482015272139bdd08195b9bdd59da081c995cd95c9d9959606a1b6044820152606401610a2d565b816012600501600082825461144e9190613cf3565b90915550610b63905083836124be565b60008051602061406583398151915261147681611c83565b61148e60008051602061406583398151915283611308565b156114ce5760405162461bcd60e51b815260206004820152601060248201526f20b63932b0b23c9030b71030b236b4b760811b6044820152606401610a2d565b6014546001600160a01b03163314156115215760405162461bcd60e51b81526020600482015260156024820152740557365207472616e736665724f776e65727368697605c1b6044820152606401610a2d565b61153960008051602061406583398151915233612171565b610c6f600080516020614065833981519152836120eb565b61155b3383611e58565b6115775760405162461bcd60e51b8152600401610a2d90613b11565b6109b284848484612554565b600061158f6001612587565b905080156115a7576007805461ff0019166101001790555b601a5460ff16156115f25760405162461bcd60e51b815260206004820152601560248201527410d85b9b9bdd081899481a5b9a5d1a585b1a5e9959605a1b6044820152606401610a2d565b6115fb8361260e565b611613600080516020614065833981519152336120eb565b61162f60008051602061406583398151915284604001516120eb565b6116406000801b84604001516120eb565b82518051849160129161165a91839160209091019061312e565b506020828101518051611673926001850192019061312e565b5060408201516002820180546001600160a01b03199081166001600160a01b0393841617909155606084015160038401805483169184169190911790556080840151600484015560a0840151600584015560c0840151600684015560e0909301516007909201805490931691161790558151805183916009916116fd91839160209091019061312e565b5060208281015160018301805460ff1916911515919091179055604083015160028301556060830151600383015560808301518051611742926004850192019061312e565b5060a0820151600582015560c0820151600682015560e08201516007820180546001600160a01b0319166001600160a01b03909216919091179055610100909101516008909101558015610b63576007805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a1505050565b6000818152600260205260409020546060906001600160a01b03166118325760405162461bcd60e51b8152602060048201526014602482015273151bdad95b88191bd95cc81b9bdd08195e1a5cdd60621b6044820152606401610a2d565b60006009600001805461184490613e5f565b9050116118db57600d805461185890613e5f565b80601f016020809104026020016040519081016040528092919081815260200182805461188490613e5f565b80156118d15780601f106118a6576101008083540402835291602001916118d1565b820191906000526020600020905b8154815290600101906020018083116118b457829003601f168201915b50505050506108e7565b60096118e6836127e7565b6040516020016118f7929190613890565b6040516020818303038152906040529050919050565b60008281526006602052604090206001015461192881611c83565b610b638383612171565b60115483906119419082613cd4565b3410156119605760405162461bcd60e51b8152600401610a2d90613a98565b600c5442116119b15760405162461bcd60e51b815260206004820152601b60248201527f50726573616c6520686173206e6f7420737461727465642079657400000000006044820152606401610a2d565b6119bc338484610cbf565b611a085760405162461bcd60e51b815260206004820152601b60248201527f4e6f742077686974656c697374656420666f722070726573616c6500000000006044820152606401610a2d565b336000818152601b60205260409020805460ff191660011790556109b29085612307565b60606000611a7d611a416009600601546127e7565b601054611a58906001600160a01b03166014612901565b604051602001611a699291906138b5565b604051602081830303815290604052612ae9565b9050600081604051602001611a92919061393c565b60408051601f198184030181529190529250505090565b6000611ab481611c83565b6014546001600160a01b0383811691161415611b065760405162461bcd60e51b815260206004820152601160248201527020b63932b0b23c903a34329037bbb732b960791b6044820152606401610a2d565b601454611b2b90600080516020614065833981519152906001600160a01b0316612171565b601454611b43906000906001600160a01b0316612171565b601480546001600160a01b038481166001600160a01b03198316179283905590811691611b809160008051602061406583398151915291166120eb565b601454611b98906000906001600160a01b03166120eb565b826001600160a01b0316816001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3505050565b60606009600401805461090190613e5f565b6001600160a01b03163b151590565b60006001600160e01b031982166380ac58cd60e01b1480611c2f57506001600160e01b03198216635b5e139f60e01b145b806108e757506301ffc9a760e01b6001600160e01b03198316146108e7565b60006001600160e01b03198216637965db0b60e01b14806108e7575063152a902d60e11b6001600160e01b03198316146108e7565b610cbc8133612c5c565b61271060c08201351115611cd85760405162461bcd60e51b81526020600482015260126024820152710a4def2c2d8e8d2cae640e8dede40d0d2ced60731b6044820152606401610a2d565b600a5460ff1615611ce857610cbc565b611cf8604082016020830161351c565b600a5460ff16151590151514611d505760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420756e667265657a65206d6574616461746100000000000000006044820152606401610a2d565b611d5a8180613c34565b604051602001611d6b929190613874565b60408051601f1981840301815290829052805160209182012091611d929160099101613884565b6040516020818303038152906040528051906020012014610cbc5760405162461bcd60e51b815260206004820152601260248201527126b2ba30b230ba309034b990333937bd32b760711b6044820152606401610a2d565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611e1f826110cb565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b0316611ed15760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610a2d565b6000611edc836110cb565b9050806001600160a01b0316846001600160a01b03161480611f2357506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b80611f475750836001600160a01b0316611f3c846109b8565b6001600160a01b0316145b949350505050565b826001600160a01b0316611f62826110cb565b6001600160a01b031614611fc65760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610a2d565b6001600160a01b0382166120285760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610a2d565b612033600082611dea565b6001600160a01b038316600090815260036020526040812080546001929061205c908490613cf3565b90915550506001600160a01b038216600090815260036020526040812080546001929061208a908490613ca8565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4610b63565b6120f58282611308565b610c6f5760008281526006602090815260408083206001600160a01b03851684529091529020805460ff1916600117905561212d3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b61217b8282611308565b15610c6f5760008281526006602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b804710156122285760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e63650000006044820152606401610a2d565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612275576040519150601f19603f3d011682016040523d82523d6000602084013e61227a565b606091505b5050905080610b635760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610a2d565b6000826122fe8584612cc0565b14949350505050565b60185481111561234c5760405162461bcd60e51b815260206004820152601060248201526f416d6f756e7420746f6f206c6172676560801b6044820152606401610a2d565b6123546111db565b81111561239c5760405162461bcd60e51b8152602060048201526016602482015275139bdd08195b9bdd59da081d1bdad95b9cc81b19599d60521b6044820152606401610a2d565b80600860008282546123ae9190613ca8565b909155506123bc9050612d42565b60015b818111610b63576123dd83826008546123d89190613cf3565b612d9d565b806123e781613e9a565b9150506123bf565b816001600160a01b0316836001600160a01b031614156124515760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610a2d565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6124c66111db565b81111561250e5760405162461bcd60e51b8152602060048201526016602482015275139bdd08195b9bdd59da081d1bdad95b9cc81b19599d60521b6044820152606401610a2d565b80600860008282546125209190613ca8565b90915550600190505b818111610b635761254283826008546123d89190613cf3565b8061254c81613e9a565b915050612529565b61255f848484611f4f565b61256b84848484612db7565b6109b25760405162461bcd60e51b8152600401610a2d90613a46565b600754600090610100900460ff16156125d0578160ff1660011480156125ac5750303b155b6125c85760405162461bcd60e51b8152600401610a2d90613ac3565b5060006108ea565b60075460ff8084169116106125f75760405162461bcd60e51b8152600401610a2d90613ac3565b506007805460ff191660ff831617905560016108ea565b60008160800151116126625760405162461bcd60e51b815260206004820152601f60248201527f4d6178696d756d20737570706c79206d757374206265206e6f6e2d7a65726f006044820152606401610a2d565b60008160c00151116126b65760405162461bcd60e51b815260206004820181905260248201527f546f6b656e7320706572206d696e74206d757374206265206e6f6e2d7a65726f6044820152606401610a2d565b60e08101516001600160a01b03166127245760405162461bcd60e51b815260206004820152602b60248201527f547265617375727920616464726573732063616e6e6f7420626520746865206e60448201526a756c6c206164647265737360a81b6064820152608401610a2d565b60408101516001600160a01b031661277e5760405162461bcd60e51b815260206004820152601b60248201527f436f6e7472616374206d757374206861766520616e206f776e657200000000006044820152606401610a2d565b80608001518160a001511115610cbc5760405162461bcd60e51b815260206004820152602860248201527f52657365727665206d757374206265206c657373207468616e206d6178696d756044820152676d20737570706c7960c01b6064820152608401610a2d565b60608161280c57506040805180820190915260018152600360fc1b60208201526108ea565b8160005b8115612836578061282081613e9a565b915061282f9050600a83613cc0565b9150612810565b6000816001600160401b0381111561285e57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612888576020820181803683370190505b5090505b8415611f475761289d600183613cf3565b91506128aa600a86613eb5565b6128b5906030613ca8565b60f81b8183815181106128d857634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053506128fa600a86613cc0565b945061288c565b60606000612910836002613cd4565b61291b906002613ca8565b6001600160401b0381111561294057634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f19166020018201604052801561296a576020820181803683370190505b509050600360fc1b8160008151811061299357634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350600f60fb1b816001815181106129d057634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060006129f4846002613cd4565b6129ff906001613ca8565b90505b6001811115612a93576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110612a4157634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110612a6557634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060049490941c93612a8c81613e48565b9050612a02565b508315612ae25760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610a2d565b9392505050565b805160609080612b095750506040805160208101909152600081526108ea565b60006003612b18836002613ca8565b612b229190613cc0565b612b2d906004613cd4565b90506000612b3c826020613ca8565b6001600160401b03811115612b6157634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612b8b576020820181803683370190505b5090506000604051806060016040528060408152602001614025604091399050600181016020830160005b86811015612c17576003818a01810151603f601282901c8116860151600c83901c8216870151600684901c831688015192909316870151600891821b60ff94851601821b92841692909201901b91160160e01b835260049092019101612bb6565b506003860660018114612c315760028114612c4257612c4e565b613d3d60f01b600119830152612c4e565b603d60f81b6000198301525b505050918152949350505050565b612c668282611308565b610c6f57612c7e816001600160a01b03166014612901565b612c89836020612901565b604051602001612c9a929190613981565b60408051601f198184030181529082905262461bcd60e51b8252610a2d91600401613a33565b600081815b8451811015612d3a576000858281518110612cf057634e487b7160e01b600052603260045260246000fd5b60200260200101519050808311612d165760008381526020829052604090209250612d27565b600081815260208490526040902092505b5080612d3281613e9a565b915050612cc5565b509392505050565b3415612d9b576000612d60612d59346103e8612ec4565b6019612ed0565b6015546040519192506001600160a01b03169082156108fc029083906000818181858888f19350505050158015610c6f573d6000803e3d6000fd5b565b610c6f828260405180602001604052806000815250612edc565b60006001600160a01b0384163b15612eb957604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612dfb9033908990889088906004016139f6565b602060405180830381600087803b158015612e1557600080fd5b505af1925050508015612e45575060408051601f3d908101601f19168201909252612e4291810190613590565b60015b612e9f573d808015612e73576040519150601f19603f3d011682016040523d82523d6000602084013e612e78565b606091505b508051612e975760405162461bcd60e51b8152600401610a2d90613a46565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611f47565b506001949350505050565b6000612ae28284613cc0565b6000612ae28284613cd4565b612ee68383612f0f565b612ef36000848484612db7565b610b635760405162461bcd60e51b8152600401610a2d90613a46565b6001600160a01b038216612f655760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610a2d565b6000818152600260205260409020546001600160a01b031615612fca5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610a2d565b6001600160a01b0382166000908152600360205260408120805460019290612ff3908490613ca8565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4610c6f565b6040518060600160405280600081526020016130c7604051806101000160405280606081526020016060815260200160006001600160a01b0316815260200160006001600160a01b0316815260200160008152602001600081526020016000815260200160006001600160a01b031681525090565b815260200161312960405180610120016040528060608152602001600015158152602001600081526020016000815260200160608152602001600080191681526020016000815260200160006001600160a01b03168152602001600081525090565b905290565b82805461313a90613e5f565b90600052602060002090601f01602090048101928261315c57600085556131a2565b82601f1061317557805160ff19168380011785556131a2565b828001600101855582156131a2579182015b828111156131a2578251825591602001919060010190613187565b506131ae9291506131b2565b5090565b5b808211156131ae57600081556001016131b3565b60006001600160401b038311156131e0576131e0613ef5565b6131f3601f8401601f1916602001613c78565b905082815283838301111561320757600080fd5b828260208301376000602084830101529392505050565b80356108ea81613feb565b60008083601f84011261323a578182fd5b5081356001600160401b03811115613250578182fd5b602083019150836020808302850101111561326a57600080fd5b9250929050565b80356108ea81614000565b600082601f83011261328c578081fd5b612ae2838335602085016131c7565b60006101208083850312156132ae578182fd5b6132b781613c78565b91505081356001600160401b03808211156132d157600080fd5b6132dd8583860161327c565b83526132eb60208501613271565b60208401526040840135604084015260608401356060840152608084013591508082111561331857600080fd5b506133258482850161327c565b60808301525060a082013560a082015260c082013560c082015261334b60e0830161321e565b60e082015261010080830135818301525092915050565b600060208284031215613373578081fd5b8135612ae281613feb565b60008060408385031215613390578081fd5b823561339b81613feb565b915060208301356133ab81613feb565b809150509250929050565b6000806000606084860312156133ca578081fd5b83356133d581613feb565b925060208401356133e581613feb565b929592945050506040919091013590565b6000806000806080858703121561340b578081fd5b843561341681613feb565b9350602085013561342681613feb565b92506040850135915060608501356001600160401b03811115613447578182fd5b8501601f81018713613457578182fd5b613466878235602084016131c7565b91505092959194509250565b600080600060408486031215613486578283fd5b833561349181613feb565b925060208401356001600160401b038111156134ab578283fd5b6134b786828701613229565b9497909650939450505050565b600080604083850312156134d6578182fd5b82356134e181613feb565b915060208301356133ab81614000565b60008060408385031215613503578081fd5b823561350e81613feb565b946020939093013593505050565b60006020828403121561352d578081fd5b8135612ae281614000565b600060208284031215613549578081fd5b5035919050565b60008060408385031215613562578182fd5b8235915060208301356133ab81613feb565b600060208284031215613585578081fd5b8135612ae28161400e565b6000602082840312156135a1578081fd5b8151612ae28161400e565b600080604083850312156135be578182fd5b82356001600160401b03808211156135d4578384fd5b81850191506101008083880312156135ea578485fd5b6135f381613c78565b9050823582811115613603578586fd5b61360f8882860161327c565b825250602083013582811115613623578586fd5b61362f8882860161327c565b6020830152506136416040840161321e565b60408201526136526060840161321e565b60608201526080830135608082015260a083013560a082015260c083013560c082015261368160e0840161321e565b60e08201529350602085013591508082111561369b578283fd5b506136a88582860161329b565b9150509250929050565b6000602082840312156136c3578081fd5b81356001600160401b038111156136d8578182fd5b82016101208185031215612ae2578182fd5b6000806000604084860312156136fe578081fd5b8335925060208401356001600160401b038111156134ab578182fd5b6000806040838503121561372c578182fd5b50508035926020909101359150565b60008151808452613753816020860160208601613e1c565b601f01601f19169290920160200192915050565b6000815461377481613e5f565b6001828116801561378c576001811461379d576137cc565b60ff198416875282870194506137cc565b8560005260208060002060005b858110156137c35781548a8201529084019082016137aa565b50505082870194505b5050505092915050565b600061012082518185526137ec8286018261373b565b9150506020830151613802602086018215159052565b5060408301516040850152606083015160608501526080830151848203608086015261382e828261373b565b91505060a083015160a085015260c083015160c085015260e083015161385f60e08601826001600160a01b03169052565b50610100928301519390920192909252919050565b6000828483379101908152919050565b6000612ae28284613767565b600061389c8285613767565b83516138ac818360208801613e1c565b01949350505050565b60007f7b2273656c6c65725f6665655f62617369735f706f696e7473223a2000000000825283516138ed81601c850160208801613e1c565b731610113332b2afb932b1b4b834b2b73a111d101160611b601c918401918201528351613921816030840160208801613e1c565b61227d60f01b60309290910191820152603201949350505050565b60007f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008252825161397481601d850160208701613e1c565b91909101601d0192915050565b60007f416363657373436f6e74726f6c3a206163636f756e7420000000000000000000825283516139b9816017850160208801613e1c565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516139ea816028840160208801613e1c565b01602801949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090613a299083018461373b565b9695505050505050565b600060208252612ae2602083018461373b565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526011908201527014185e5b595b9d081d1bdbc81cdb585b1b607a1b604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600060208252825160208301526020830151606060408401528051610100806080860152613b9461018086018361373b565b91506020830151607f198684030160a0870152613bb1838261373b565b60408501516001600160a01b031660c088015260608501519093509050613be360e08701826001600160a01b03169052565b5060808301519085015260a082015161012085015260c082015161014085015260e0909101516001600160a01b03166101608401526040840151838203601f1901606085015290610d9481836137d6565b6000808335601e19843603018112613c4a578283fd5b8301803591506001600160401b03821115613c63578283fd5b60200191503681900382131561326a57600080fd5b604051601f8201601f191681016001600160401b0381118282101715613ca057613ca0613ef5565b604052919050565b60008219821115613cbb57613cbb613ec9565b500190565b600082613ccf57613ccf613edf565b500490565b6000816000190483118215151615613cee57613cee613ec9565b500290565b600082821015613d0557613d05613ec9565b500390565b5b81811015610c6f5760008155600101613d0b565b6001600160401b03831115613d3657613d36613ef5565b613d408154613e5f565b600080601f8611601f841181811715613d5f5760008681526020902092505b8015613d8e576020601f89010483016020891015613d7a5750825b613d8c6020601f880104850182613d0a565b505b508060018114613dc057600094508715613da9578387013594505b6002880260001960088a021c198616178655613e12565b601f198816945082845b86811015613dea5788860135825560209586019560019092019101613dca565b5088861015613e0757878501356000196008601f8c16021c191681555b506001600289020186555b5050505050505050565b60005b83811015613e37578181015183820152602001613e1f565b838111156109b25750506000910152565b600081613e5757613e57613ec9565b506000190190565b600281046001821680613e7357607f821691505b60208210811415613e9457634e487b7160e01b600052602260045260246000fd5b50919050565b6000600019821415613eae57613eae613ec9565b5060010190565b600082613ec457613ec4613edf565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b600081356108e781613feb565b600081356108e781614000565b613f2f8283613c34565b613f3a818385613d1f565b5050613f64613f4b60208401613f18565b6001830160ff1981541660ff8315151681178255505050565b6040820135600282015560608201356003820155613f856080830183613c34565b613f93818360048601613d1f565b505060a0820135600582015560c08201356006820155613fdc613fb860e08401613f0b565b6007830180546001600160a01b0319166001600160a01b0392909216919091179055565b61010082013560088201555050565b6001600160a01b0381168114610cbc57600080fd5b8015158114610cbc57600080fd5b6001600160e01b031981168114610cbc57600080fdfe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775a26469706673582212207b41652e445fa0392886a6af5567f7cc1bfd9c96328127ede2b17f188c06979a64736f6c63430008020033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001c000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000c00a9ba526583c49a08416cee0c7ffc54c2154f4000000000000000000000000c048b5757bee085712ce5aecac987c471d9f0f9200000000000000000000000000000000000000000000000000000000000020d000000000000000000000000000000000000000000000000000000000000001f4000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba0000000000000000000000000000000000000000000000000000000000000008534d504c46524b530000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008534d504c46524b530000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000636ffb4000000000000000000000000000000000000000000000000000000000634b03300000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002ee000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba00000000000000000000000000000000000000000000000000354a6ba7a1800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035697066733a2f2f516d544a56584a68614d635844557958796a36435a557161437a4331674a69637a4b396d4e5051585451505978770000000000000000000000
-----Decoded View---------------
Arg [0] : deploymentConfig (tuple): System.Collections.Generic.List`1[Nethereum.ABI.FunctionEncoding.ParameterOutput]
Arg [1] : runtimeConfig (tuple): System.Collections.Generic.List`1[Nethereum.ABI.FunctionEncoding.ParameterOutput]
-----Encoded View---------------
27 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [1] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000100
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [4] : 000000000000000000000000c00a9ba526583c49a08416cee0c7ffc54c2154f4
Arg [5] : 000000000000000000000000c048b5757bee085712ce5aecac987c471d9f0f92
Arg [6] : 00000000000000000000000000000000000000000000000000000000000020d0
Arg [7] : 00000000000000000000000000000000000000000000000000000000000001f4
Arg [8] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [9] : 000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [11] : 534d504c46524b53000000000000000000000000000000000000000000000000
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [13] : 534d504c46524b53000000000000000000000000000000000000000000000000
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [15] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [16] : 00000000000000000000000000000000000000000000000000000000636ffb40
Arg [17] : 00000000000000000000000000000000000000000000000000000000634b0330
Arg [18] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [19] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [20] : 00000000000000000000000000000000000000000000000000000000000002ee
Arg [21] : 000000000000000000000000015ed5123cbc184d232ad67fcd51fc7b0a4fe9ba
Arg [22] : 00000000000000000000000000000000000000000000000000354a6ba7a18000
Arg [23] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [24] : 0000000000000000000000000000000000000000000000000000000000000035
Arg [25] : 697066733a2f2f516d544a56584a68614d635844557958796a36435a55716143
Arg [26] : 7a4331674a69637a4b396d4e5051585451505978770000000000000000000000
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.