Overview
TokenID
671
Total Transfers
-
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Source Code Verified (Exact Match)
Contract Name:
LimitedCollection
Compiler Version
v0.8.24+commit.e11b9ed9
Optimization Enabled:
Yes with 1000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.24; import "./data/MintTicket.sol"; import "./signature/MintTicketSignatureVerification.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol"; import "@openzeppelin/contracts/token/common/ERC2981.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract LimitedCollection is ERC2981, ERC721URIStorage, Ownable, MintTicketSigantureVerification { struct TokenURIDefinition { uint256 tokenId; string tokenURI; } error MintNotAllowed(); error InvalidTicket(); error CannotMintZeroTokens(); error InsufficientValue(); error TooHighValue(); error NoMoreTokens(); error AmountExceeded(); error ContractEmpty(); error WithdrawalFailed(); uint256 public mintPrice; uint256 public totalSupply; uint256 public maxSupply; uint256 public maxPerWallet; bool public isMintEnabled; string internal baseTokenURI; address public ticketSigner; address payable public withdrawWallet; mapping(address => uint256) public walletMints; constructor( string memory _name, string memory _symbol, uint256 _mintPrice, uint256 _maxSupply, uint256 _maxPerWallet, address _withdrawWallet, address _royaltyReceiver, uint96 _feeNumerator, // 100 percents is 10 000 value in feeNumenator address _ticketSigner ) ERC721(_name, _symbol) Ownable(msg.sender) { mintPrice = _mintPrice; totalSupply = 0; maxSupply = _maxSupply; maxPerWallet = _maxPerWallet; isMintEnabled = false; withdrawWallet = payable(_withdrawWallet); ticketSigner = _ticketSigner; _setDefaultRoyalty(_royaltyReceiver, _feeNumerator); } function mint(MintTicket memory _ticket, bytes memory _signature, uint256 _quantity) public payable { address sender = _msgSender(); if(!isMintEnabled) revert MintNotAllowed(); if(address(this) != _ticket.nft) revert InvalidTicket(); if(sender != _ticket.minter) revert InvalidTicket(); if(!verify(_ticket, _signature, ticketSigner)) revert InvalidTicket(); if(_quantity == 0) revert CannotMintZeroTokens(); if(totalSupply + _quantity > maxSupply) revert NoMoreTokens(); if(walletMints[sender] + _quantity > maxPerWallet) revert AmountExceeded(); if(msg.value < mintPrice * _quantity) revert InsufficientValue(); if(msg.value > mintPrice * _quantity) revert TooHighValue(); for (uint i = 0; i < _quantity; ++i) { walletMints[sender]++; uint256 newTokenId = totalSupply++; _safeMint(sender, newTokenId); } } function setIsMintEnabled(bool _isMintEnabled) public onlyOwner { isMintEnabled = _isMintEnabled; } function setDefaultRoyalty(address _reciever, uint96 _centiPercents) public onlyOwner { _setDefaultRoyalty(_reciever, _centiPercents); } function setMaxSupply(uint256 _newMaxSupply) public onlyOwner { if(_newMaxSupply < totalSupply) revert InsufficientValue(); maxSupply = _newMaxSupply; } function setMintPrice(uint256 _newMintPrice) public onlyOwner { mintPrice = _newMintPrice; } function setMaxPerWallet(uint256 _newMaxPerWallet) public onlyOwner { maxPerWallet = _newMaxPerWallet; } function setBaseTokenURI(string calldata _baseTokenURI) public onlyOwner { baseTokenURI = _baseTokenURI; } function setMultipleTokenURIs(TokenURIDefinition [] calldata _definitions) public onlyOwner { for (uint256 index = 0; index < _definitions.length; index++) { TokenURIDefinition calldata definition = _definitions[index]; _setTokenURI(definition.tokenId, definition.tokenURI); } } function setTokenURI(TokenURIDefinition calldata _definition) public onlyOwner { _setTokenURI(_definition.tokenId, _definition.tokenURI); } function withdraw() public onlyOwner { if (address(this).balance == 0) revert ContractEmpty(); (bool success, ) = withdrawWallet.call { value: address(this).balance }(""); if (!success) revert WithdrawalFailed(); } function _baseURI() internal view virtual override returns (string memory) { return baseTokenURI; } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { return ERC721URIStorage.tokenURI(tokenId); } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC2981, ERC721URIStorage) returns (bool) { return ERC2981.supportsInterface(interfaceId) || ERC721URIStorage.supportsInterface(interfaceId); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol) pragma solidity ^0.8.20; import {Context} from "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * The initial owner is set to the address provided by the deployer. This can * later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; /** * @dev The caller account is not authorized to perform an operation. */ error OwnableUnauthorizedAccount(address account); /** * @dev The owner is not a valid owner account. (eg. `address(0)`) */ error OwnableInvalidOwner(address owner); event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the address provided by the deployer as the initial owner. */ constructor(address initialOwner) { if (initialOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(initialOwner); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { if (owner() != _msgSender()) { revert OwnableUnauthorizedAccount(_msgSender()); } } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { if (newOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC6093.sol) pragma solidity ^0.8.20; /** * @dev Standard ERC20 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC20 tokens. */ interface IERC20Errors { /** * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. * @param balance Current balance for the interacting account. * @param needed Minimum amount required to perform a transfer. */ error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC20InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC20InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers. * @param spender Address that may be allowed to operate on tokens without being their owner. * @param allowance Amount of tokens a `spender` is allowed to operate with. * @param needed Minimum amount required to perform a transfer. */ error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC20InvalidApprover(address approver); /** * @dev Indicates a failure with the `spender` to be approved. Used in approvals. * @param spender Address that may be allowed to operate on tokens without being their owner. */ error ERC20InvalidSpender(address spender); } /** * @dev Standard ERC721 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC721 tokens. */ interface IERC721Errors { /** * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in EIP-20. * Used in balance queries. * @param owner Address of the current owner of a token. */ error ERC721InvalidOwner(address owner); /** * @dev Indicates a `tokenId` whose `owner` is the zero address. * @param tokenId Identifier number of a token. */ error ERC721NonexistentToken(uint256 tokenId); /** * @dev Indicates an error related to the ownership over a particular token. Used in transfers. * @param sender Address whose tokens are being transferred. * @param tokenId Identifier number of a token. * @param owner Address of the current owner of a token. */ error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC721InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC721InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `operator`’s approval. Used in transfers. * @param operator Address that may be allowed to operate on tokens without being their owner. * @param tokenId Identifier number of a token. */ error ERC721InsufficientApproval(address operator, uint256 tokenId); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC721InvalidApprover(address approver); /** * @dev Indicates a failure with the `operator` to be approved. Used in approvals. * @param operator Address that may be allowed to operate on tokens without being their owner. */ error ERC721InvalidOperator(address operator); } /** * @dev Standard ERC1155 Errors * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC1155 tokens. */ interface IERC1155Errors { /** * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. * @param balance Current balance for the interacting account. * @param needed Minimum amount required to perform a transfer. * @param tokenId Identifier number of a token. */ error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId); /** * @dev Indicates a failure with the token `sender`. Used in transfers. * @param sender Address whose tokens are being transferred. */ error ERC1155InvalidSender(address sender); /** * @dev Indicates a failure with the token `receiver`. Used in transfers. * @param receiver Address to which tokens are being transferred. */ error ERC1155InvalidReceiver(address receiver); /** * @dev Indicates a failure with the `operator`’s approval. Used in transfers. * @param operator Address that may be allowed to operate on tokens without being their owner. * @param owner Address of the current owner of a token. */ error ERC1155MissingApprovalForAll(address operator, address owner); /** * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. * @param approver Address initiating an approval operation. */ error ERC1155InvalidApprover(address approver); /** * @dev Indicates a failure with the `operator` to be approved. Used in approvals. * @param operator Address that may be allowed to operate on tokens without being their owner. */ error ERC1155InvalidOperator(address operator); /** * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation. * Used in batch transfers. * @param idsLength Length of the array of token identifiers * @param valuesLength Length of the array of token amounts */ error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC165.sol) pragma solidity ^0.8.20; import {IERC165} from "../utils/introspection/IERC165.sol";
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.20; import {IERC165} from "../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. */ 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC4906.sol) pragma solidity ^0.8.20; import {IERC165} from "./IERC165.sol"; import {IERC721} from "./IERC721.sol"; /// @title EIP-721 Metadata Update Extension interface IERC4906 is IERC165, IERC721 { /// @dev This event emits when the metadata of a token is changed. /// So that the third-party platforms such as NFT market could /// timely update the images and related attributes of the NFT. event MetadataUpdate(uint256 _tokenId); /// @dev This event emits when the metadata of a range of tokens is changed. /// So that the third-party platforms such as NFT market could /// timely update the images and related attributes of the NFTs. event BatchMetadataUpdate(uint256 _fromTokenId, uint256 _toTokenId); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC5267.sol) pragma solidity ^0.8.20; interface IERC5267 { /** * @dev MAY be emitted to signal that the domain could have changed. */ event EIP712DomainChanged(); /** * @dev returns the fields and values that describe the domain separator used by this contract for EIP-712 * signature. */ function eip712Domain() external view returns ( bytes1 fields, string memory name, string memory version, uint256 chainId, address verifyingContract, bytes32 salt, uint256[] memory extensions ); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC721.sol) pragma solidity ^0.8.20; import {IERC721} from "../token/ERC721/IERC721.sol";
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/common/ERC2981.sol) pragma solidity ^0.8.20; import {IERC2981} from "../../interfaces/IERC2981.sol"; import {IERC165, ERC165} from "../../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. */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 tokenId => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev The default royalty set is invalid (eg. (numerator / denominator) >= 1). */ error ERC2981InvalidDefaultRoyalty(uint256 numerator, uint256 denominator); /** * @dev The default royalty receiver is invalid. */ error ERC2981InvalidDefaultRoyaltyReceiver(address receiver); /** * @dev The royalty set for an specific `tokenId` is invalid (eg. (numerator / denominator) >= 1). */ error ERC2981InvalidTokenRoyalty(uint256 tokenId, uint256 numerator, uint256 denominator); /** * @dev The royalty receiver for `tokenId` is invalid. */ error ERC2981InvalidTokenRoyaltyReceiver(uint256 tokenId, address receiver); /** * @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 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 { uint256 denominator = _feeDenominator(); if (feeNumerator > denominator) { // Royalty fee will exceed the sale price revert ERC2981InvalidDefaultRoyalty(feeNumerator, denominator); } if (receiver == address(0)) { revert ERC2981InvalidDefaultRoyaltyReceiver(address(0)); } _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: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty(uint256 tokenId, address receiver, uint96 feeNumerator) internal virtual { uint256 denominator = _feeDenominator(); if (feeNumerator > denominator) { // Royalty fee will exceed the sale price revert ERC2981InvalidTokenRoyalty(tokenId, feeNumerator, denominator); } if (receiver == address(0)) { revert ERC2981InvalidTokenRoyaltyReceiver(tokenId, address(0)); } _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 v5.0.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.20; import {IERC721} from "./IERC721.sol"; import {IERC721Receiver} from "./IERC721Receiver.sol"; import {IERC721Metadata} from "./extensions/IERC721Metadata.sol"; import {Context} from "../../utils/Context.sol"; import {Strings} from "../../utils/Strings.sol"; import {IERC165, ERC165} from "../../utils/introspection/ERC165.sol"; import {IERC721Errors} from "../../interfaces/draft-IERC6093.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}. */ abstract contract ERC721 is Context, ERC165, IERC721, IERC721Metadata, IERC721Errors { using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; mapping(uint256 tokenId => address) private _owners; mapping(address owner => uint256) private _balances; mapping(uint256 tokenId => address) private _tokenApprovals; mapping(address owner => mapping(address operator => 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 returns (uint256) { if (owner == address(0)) { revert ERC721InvalidOwner(address(0)); } return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual returns (address) { return _requireOwned(tokenId); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual returns (string memory) { _requireOwned(tokenId); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string.concat(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 { _approve(to, tokenId, _msgSender()); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual returns (address) { _requireOwned(tokenId); return _getApproved(tokenId); } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom(address from, address to, uint256 tokenId) public virtual { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } // Setting an "auth" arguments enables the `_isAuthorized` check which verifies that the token exists // (from != 0). Therefore, it is not needed to verify that the return value is not 0 here. address previousOwner = _update(to, tokenId, _msgSender()); if (previousOwner != from) { revert ERC721IncorrectOwner(from, tokenId, previousOwner); } } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId) public { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory data) public virtual { transferFrom(from, to, tokenId); _checkOnERC721Received(from, to, tokenId, data); } /** * @dev Returns the owner of the `tokenId`. Does NOT revert if token doesn't exist * * IMPORTANT: Any overrides to this function that add ownership of tokens not tracked by the * core ERC721 logic MUST be matched with the use of {_increaseBalance} to keep balances * consistent with ownership. The invariant to preserve is that for any address `a` the value returned by * `balanceOf(a)` must be equal to the number of tokens such that `_ownerOf(tokenId)` is `a`. */ function _ownerOf(uint256 tokenId) internal view virtual returns (address) { return _owners[tokenId]; } /** * @dev Returns the approved address for `tokenId`. Returns 0 if `tokenId` is not minted. */ function _getApproved(uint256 tokenId) internal view virtual returns (address) { return _tokenApprovals[tokenId]; } /** * @dev Returns whether `spender` is allowed to manage `owner`'s tokens, or `tokenId` in * particular (ignoring whether it is owned by `owner`). * * WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this * assumption. */ function _isAuthorized(address owner, address spender, uint256 tokenId) internal view virtual returns (bool) { return spender != address(0) && (owner == spender || isApprovedForAll(owner, spender) || _getApproved(tokenId) == spender); } /** * @dev Checks if `spender` can operate on `tokenId`, assuming the provided `owner` is the actual owner. * Reverts if `spender` does not have approval from the provided `owner` for the given token or for all its assets * the `spender` for the specific `tokenId`. * * WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this * assumption. */ function _checkAuthorized(address owner, address spender, uint256 tokenId) internal view virtual { if (!_isAuthorized(owner, spender, tokenId)) { if (owner == address(0)) { revert ERC721NonexistentToken(tokenId); } else { revert ERC721InsufficientApproval(spender, tokenId); } } } /** * @dev Unsafe write access to the balances, used by extensions that "mint" tokens using an {ownerOf} override. * * NOTE: the value is limited to type(uint128).max. This protect against _balance overflow. It is unrealistic that * a uint256 would ever overflow from increments when these increments are bounded to uint128 values. * * WARNING: Increasing an account's balance using this function tends to be paired with an override of the * {_ownerOf} function to resolve the ownership of the corresponding tokens so that balances and ownership * remain consistent with one another. */ function _increaseBalance(address account, uint128 value) internal virtual { unchecked { _balances[account] += value; } } /** * @dev Transfers `tokenId` from its current owner to `to`, or alternatively mints (or burns) if the current owner * (or `to`) is the zero address. Returns the owner of the `tokenId` before the update. * * The `auth` argument is optional. If the value passed is non 0, then this function will check that * `auth` is either the owner of the token, or approved to operate on the token (by the owner). * * Emits a {Transfer} event. * * NOTE: If overriding this function in a way that tracks balances, see also {_increaseBalance}. */ function _update(address to, uint256 tokenId, address auth) internal virtual returns (address) { address from = _ownerOf(tokenId); // Perform (optional) operator check if (auth != address(0)) { _checkAuthorized(from, auth, tokenId); } // Execute the update if (from != address(0)) { // Clear approval. No need to re-authorize or emit the Approval event _approve(address(0), tokenId, address(0), false); unchecked { _balances[from] -= 1; } } if (to != address(0)) { unchecked { _balances[to] += 1; } } _owners[tokenId] = to; emit Transfer(from, to, tokenId); return from; } /** * @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 { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } address previousOwner = _update(to, tokenId, address(0)); if (previousOwner != address(0)) { revert ERC721InvalidSender(address(0)); } } /** * @dev Mints `tokenId`, transfers it to `to` and checks for `to` acceptance. * * 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 { _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); _checkOnERC721Received(address(0), to, tokenId, data); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * This is an internal function that does not check if the sender is authorized to operate on the token. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal { address previousOwner = _update(address(0), tokenId, address(0)); if (previousOwner == address(0)) { revert ERC721NonexistentToken(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 { if (to == address(0)) { revert ERC721InvalidReceiver(address(0)); } address previousOwner = _update(to, tokenId, address(0)); if (previousOwner == address(0)) { revert ERC721NonexistentToken(tokenId); } else if (previousOwner != from) { revert ERC721IncorrectOwner(from, tokenId, previousOwner); } } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking that contract recipients * are aware of the ERC721 standard 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 like {safeTransferFrom} in the sense that it invokes * {IERC721Receiver-onERC721Received} on the receiver, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `tokenId` token must exist and be owned by `from`. * - `to` cannot be the zero address. * - `from` cannot be the zero address. * - 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) internal { _safeTransfer(from, to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeTransfer-address-address-uint256-}[`_safeTransfer`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeTransfer(address from, address to, uint256 tokenId, bytes memory data) internal virtual { _transfer(from, to, tokenId); _checkOnERC721Received(from, to, tokenId, data); } /** * @dev Approve `to` to operate on `tokenId` * * The `auth` argument is optional. If the value passed is non 0, then this function will check that `auth` is * either the owner of the token, or approved to operate on all tokens held by this owner. * * Emits an {Approval} event. * * Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument. */ function _approve(address to, uint256 tokenId, address auth) internal { _approve(to, tokenId, auth, true); } /** * @dev Variant of `_approve` with an optional flag to enable or disable the {Approval} event. The event is not * emitted in the context of transfers. */ function _approve(address to, uint256 tokenId, address auth, bool emitEvent) internal virtual { // Avoid reading the owner unless necessary if (emitEvent || auth != address(0)) { address owner = _requireOwned(tokenId); // We do not use _isAuthorized because single-token approvals should not be able to call approve if (auth != address(0) && owner != auth && !isApprovedForAll(owner, auth)) { revert ERC721InvalidApprover(auth); } if (emitEvent) { emit Approval(owner, to, tokenId); } } _tokenApprovals[tokenId] = to; } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Requirements: * - operator can't be the address zero. * * Emits an {ApprovalForAll} event. */ function _setApprovalForAll(address owner, address operator, bool approved) internal virtual { if (operator == address(0)) { revert ERC721InvalidOperator(operator); } _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Reverts if the `tokenId` doesn't have a current owner (it hasn't been minted, or it has been burned). * Returns the owner. * * Overrides to ownership logic should be done to {_ownerOf}. */ function _requireOwned(uint256 tokenId) internal view returns (address) { address owner = _ownerOf(tokenId); if (owner == address(0)) { revert ERC721NonexistentToken(tokenId); } return owner; } /** * @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target address. This will revert if the * recipient doesn't accept the token transfer. 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 */ function _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory data) private { if (to.code.length > 0) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) { if (retval != IERC721Receiver.onERC721Received.selector) { revert ERC721InvalidReceiver(to); } } catch (bytes memory reason) { if (reason.length == 0) { revert ERC721InvalidReceiver(to); } else { /// @solidity memory-safe-assembly assembly { revert(add(32, reason), mload(reason)) } } } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/extensions/ERC721URIStorage.sol) pragma solidity ^0.8.20; import {ERC721} from "../ERC721.sol"; import {Strings} from "../../../utils/Strings.sol"; import {IERC4906} from "../../../interfaces/IERC4906.sol"; import {IERC165} from "../../../interfaces/IERC165.sol"; /** * @dev ERC721 token with storage based token URI management. */ abstract contract ERC721URIStorage is IERC4906, ERC721 { using Strings for uint256; // Interface ID as defined in ERC-4906. This does not correspond to a traditional interface ID as ERC-4906 only // defines events and does not include any external function. bytes4 private constant ERC4906_INTERFACE_ID = bytes4(0x49064906); // Optional mapping for token URIs mapping(uint256 tokenId => string) private _tokenURIs; /** * @dev See {IERC165-supportsInterface} */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721, IERC165) returns (bool) { return interfaceId == ERC4906_INTERFACE_ID || super.supportsInterface(interfaceId); } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { _requireOwned(tokenId); string memory _tokenURI = _tokenURIs[tokenId]; string memory base = _baseURI(); // If there is no base URI, return the token URI. if (bytes(base).length == 0) { return _tokenURI; } // If both are set, concatenate the baseURI and tokenURI (via string.concat). if (bytes(_tokenURI).length > 0) { return string.concat(base, _tokenURI); } return super.tokenURI(tokenId); } /** * @dev Sets `_tokenURI` as the tokenURI of `tokenId`. * * Emits {MetadataUpdate}. */ function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual { _tokenURIs[tokenId] = _tokenURI; emit MetadataUpdate(tokenId); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.20; import {IERC721} from "../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 (last updated v5.0.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.20; import {IERC165} from "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon * a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or * {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon * a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom(address from, address to, uint256 tokenId) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721 * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must * understand this adds an external call which potentially creates a reentrancy vulnerability. * * 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 address zero. * * 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 v5.0.0) (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.20; /** * @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 (last updated v5.0.1) (utils/Context.sol) pragma solidity ^0.8.20; /** * @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; } function _contextSuffixLength() internal view virtual returns (uint256) { return 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.20; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS } /** * @dev The signature derives the `address(0)`. */ error ECDSAInvalidSignature(); /** * @dev The signature has an invalid length. */ error ECDSAInvalidSignatureLength(uint256 length); /** * @dev The signature has an S value that is in the upper half order. */ error ECDSAInvalidSignatureS(bytes32 s); /** * @dev Returns the address that signed a hashed message (`hash`) with `signature` or an error. This will not * return address(0) without also returning an error description. Errors are documented using an enum (error type) * and a bytes32 providing additional information about the error. * * If no error is returned, then the address can be used for verification purposes. * * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError, bytes32) { if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. /// @solidity memory-safe-assembly assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else { return (address(0), RecoverError.InvalidSignatureLength, bytes32(signature.length)); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, signature); _throwError(error, errorArg); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] */ function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError, bytes32) { unchecked { bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); // We do not check for an overflow here since the shift operation results in 0 or 1. uint8 v = uint8((uint256(vs) >> 255) + 27); return tryRecover(hash, v, r, s); } } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. */ function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) { (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, r, vs); _throwError(error, errorArg); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError, bytes32) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS, s); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature, bytes32(0)); } return (signer, RecoverError.NoError, bytes32(0)); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) { (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, v, r, s); _throwError(error, errorArg); return recovered; } /** * @dev Optionally reverts with the corresponding custom error according to the `error` argument provided. */ function _throwError(RecoverError error, bytes32 errorArg) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert ECDSAInvalidSignature(); } else if (error == RecoverError.InvalidSignatureLength) { revert ECDSAInvalidSignatureLength(uint256(errorArg)); } else if (error == RecoverError.InvalidSignatureS) { revert ECDSAInvalidSignatureS(errorArg); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/EIP712.sol) pragma solidity ^0.8.20; import {MessageHashUtils} from "./MessageHashUtils.sol"; import {ShortStrings, ShortString} from "../ShortStrings.sol"; import {IERC5267} from "../../interfaces/IERC5267.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding scheme specified in the EIP requires a domain separator and a hash of the typed structured data, whose * encoding is very generic and therefore its implementation in Solidity is not feasible, thus this contract * does not implement the encoding itself. Protocols need to implement the type-specific encoding they need in order to * produce the hash of their typed data using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain * separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the * separator from the immutable values, which is cheaper than accessing a cached version in cold storage. * * @custom:oz-upgrades-unsafe-allow state-variable-immutable */ abstract contract EIP712 is IERC5267 { using ShortStrings for *; bytes32 private constant TYPE_HASH = keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _cachedDomainSeparator; uint256 private immutable _cachedChainId; address private immutable _cachedThis; bytes32 private immutable _hashedName; bytes32 private immutable _hashedVersion; ShortString private immutable _name; ShortString private immutable _version; string private _nameFallback; string private _versionFallback; /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ constructor(string memory name, string memory version) { _name = name.toShortStringWithFallback(_nameFallback); _version = version.toShortStringWithFallback(_versionFallback); _hashedName = keccak256(bytes(name)); _hashedVersion = keccak256(bytes(version)); _cachedChainId = block.chainid; _cachedDomainSeparator = _buildDomainSeparator(); _cachedThis = address(this); } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _cachedThis && block.chainid == _cachedChainId) { return _cachedDomainSeparator; } else { return _buildDomainSeparator(); } } function _buildDomainSeparator() private view returns (bytes32) { return keccak256(abi.encode(TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this))); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return MessageHashUtils.toTypedDataHash(_domainSeparatorV4(), structHash); } /** * @dev See {IERC-5267}. */ function eip712Domain() public view virtual returns ( bytes1 fields, string memory name, string memory version, uint256 chainId, address verifyingContract, bytes32 salt, uint256[] memory extensions ) { return ( hex"0f", // 01111 _EIP712Name(), _EIP712Version(), block.chainid, address(this), bytes32(0), new uint256[](0) ); } /** * @dev The name parameter for the EIP712 domain. * * NOTE: By default this function reads _name which is an immutable value. * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). */ // solhint-disable-next-line func-name-mixedcase function _EIP712Name() internal view returns (string memory) { return _name.toStringWithFallback(_nameFallback); } /** * @dev The version parameter for the EIP712 domain. * * NOTE: By default this function reads _version which is an immutable value. * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). */ // solhint-disable-next-line func-name-mixedcase function _EIP712Version() internal view returns (string memory) { return _version.toStringWithFallback(_versionFallback); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/MessageHashUtils.sol) pragma solidity ^0.8.20; import {Strings} from "../Strings.sol"; /** * @dev Signature message hash utilities for producing digests to be consumed by {ECDSA} recovery or signing. * * The library provides methods for generating a hash of a message that conforms to the * https://eips.ethereum.org/EIPS/eip-191[EIP 191] and https://eips.ethereum.org/EIPS/eip-712[EIP 712] * specifications. */ library MessageHashUtils { /** * @dev Returns the keccak256 digest of an EIP-191 signed data with version * `0x45` (`personal_sign` messages). * * The digest is calculated by prefixing a bytes32 `messageHash` with * `"\x19Ethereum Signed Message:\n32"` and hashing the result. It corresponds with the * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. * * NOTE: The `messageHash` parameter is intended to be the result of hashing a raw message with * keccak256, although any bytes32 value can be safely used because the final digest will * be re-hashed. * * See {ECDSA-recover}. */ function toEthSignedMessageHash(bytes32 messageHash) internal pure returns (bytes32 digest) { /// @solidity memory-safe-assembly assembly { mstore(0x00, "\x19Ethereum Signed Message:\n32") // 32 is the bytes-length of messageHash mstore(0x1c, messageHash) // 0x1c (28) is the length of the prefix digest := keccak256(0x00, 0x3c) // 0x3c is the length of the prefix (0x1c) + messageHash (0x20) } } /** * @dev Returns the keccak256 digest of an EIP-191 signed data with version * `0x45` (`personal_sign` messages). * * The digest is calculated by prefixing an arbitrary `message` with * `"\x19Ethereum Signed Message:\n" + len(message)` and hashing the result. It corresponds with the * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. * * See {ECDSA-recover}. */ function toEthSignedMessageHash(bytes memory message) internal pure returns (bytes32) { return keccak256(bytes.concat("\x19Ethereum Signed Message:\n", bytes(Strings.toString(message.length)), message)); } /** * @dev Returns the keccak256 digest of an EIP-191 signed data with version * `0x00` (data with intended validator). * * The digest is calculated by prefixing an arbitrary `data` with `"\x19\x00"` and the intended * `validator` address. Then hashing the result. * * See {ECDSA-recover}. */ function toDataWithIntendedValidatorHash(address validator, bytes memory data) internal pure returns (bytes32) { return keccak256(abi.encodePacked(hex"19_00", validator, data)); } /** * @dev Returns the keccak256 digest of an EIP-712 typed data (EIP-191 version `0x01`). * * The digest is calculated from a `domainSeparator` and a `structHash`, by prefixing them with * `\x19\x01` and hashing the result. It corresponds to the hash signed by the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] JSON-RPC method as part of EIP-712. * * See {ECDSA-recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 digest) { /// @solidity memory-safe-assembly assembly { let ptr := mload(0x40) mstore(ptr, hex"19_01") mstore(add(ptr, 0x02), domainSeparator) mstore(add(ptr, 0x22), structHash) digest := keccak256(ptr, 0x42) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.sol) pragma solidity ^0.8.20; import {IERC165} from "./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); * } * ``` */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/math/Math.sol) pragma solidity ^0.8.20; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { /** * @dev Muldiv operation overflow. */ error MathOverflowedMulDiv(); enum Rounding { Floor, // Toward negative infinity Ceil, // Toward positive infinity Trunc, // Toward zero Expand // Away from zero } /** * @dev Returns the addition of two unsigned integers, with an overflow flag. */ 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. */ 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. */ 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. */ 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. */ 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 largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return a > b ? a : b; } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return a < b ? a : b; } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow. return (a & b) + (a ^ b) / 2; } /** * @dev Returns the ceiling of the division of two numbers. * * This differs from standard division with `/` in that it rounds towards infinity instead * of rounding towards zero. */ function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { if (b == 0) { // Guarantee the same behavior as in a regular Solidity division. return a / b; } // (a + b - 1) / b can overflow on addition, so we distribute. return a == 0 ? 0 : (a - 1) / b + 1; } /** * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or * denominator == 0. * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) with further edits by * Uniswap Labs also under MIT license. */ function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) { unchecked { // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256 // variables such that product = prod1 * 2^256 + prod0. uint256 prod0 = x * y; // Least significant 256 bits of the product uint256 prod1; // Most significant 256 bits of the product assembly { let mm := mulmod(x, y, not(0)) prod1 := sub(sub(mm, prod0), lt(mm, prod0)) } // Handle non-overflow cases, 256 by 256 division. if (prod1 == 0) { // Solidity will revert if denominator == 0, unlike the div opcode on its own. // The surrounding unchecked block does not change this fact. // See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic. return prod0 / denominator; } // Make sure the result is less than 2^256. Also prevents denominator == 0. if (denominator <= prod1) { revert MathOverflowedMulDiv(); } /////////////////////////////////////////////// // 512 by 256 division. /////////////////////////////////////////////// // Make division exact by subtracting the remainder from [prod1 prod0]. uint256 remainder; assembly { // Compute remainder using mulmod. remainder := mulmod(x, y, denominator) // Subtract 256 bit number from 512 bit number. prod1 := sub(prod1, gt(remainder, prod0)) prod0 := sub(prod0, remainder) } // Factor powers of two out of denominator and compute largest power of two divisor of denominator. // Always >= 1. See https://cs.stackexchange.com/q/138556/92363. uint256 twos = denominator & (0 - denominator); assembly { // Divide denominator by twos. denominator := div(denominator, twos) // Divide [prod1 prod0] by twos. prod0 := div(prod0, twos) // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one. twos := add(div(sub(0, twos), twos), 1) } // Shift in bits from prod1 into prod0. prod0 |= prod1 * twos; // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for // four bits. That is, denominator * inv = 1 mod 2^4. uint256 inverse = (3 * denominator) ^ 2; // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also // works in modular arithmetic, doubling the correct bits in each step. inverse *= 2 - denominator * inverse; // inverse mod 2^8 inverse *= 2 - denominator * inverse; // inverse mod 2^16 inverse *= 2 - denominator * inverse; // inverse mod 2^32 inverse *= 2 - denominator * inverse; // inverse mod 2^64 inverse *= 2 - denominator * inverse; // inverse mod 2^128 inverse *= 2 - denominator * inverse; // inverse mod 2^256 // Because the division is now exact we can divide by multiplying with the modular inverse of denominator. // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1 // is no longer required. result = prod0 * inverse; return result; } } /** * @notice Calculates x * y / denominator with full precision, following the selected rounding direction. */ function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) { uint256 result = mulDiv(x, y, denominator); if (unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0) { result += 1; } return result; } /** * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded * towards zero. * * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11). */ function sqrt(uint256 a) internal pure returns (uint256) { if (a == 0) { return 0; } // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target. // // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`. // // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)` // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))` // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)` // // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit. uint256 result = 1 << (log2(a) >> 1); // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128, // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision // into the expected uint128 result. unchecked { result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; return min(result, a / result); } } /** * @notice Calculates sqrt(a), following the selected rounding direction. */ function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = sqrt(a); return result + (unsignedRoundsUp(rounding) && result * result < a ? 1 : 0); } } /** * @dev Return the log in base 2 of a positive value rounded towards zero. * Returns 0 if given 0. */ function log2(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >> 128 > 0) { value >>= 128; result += 128; } if (value >> 64 > 0) { value >>= 64; result += 64; } if (value >> 32 > 0) { value >>= 32; result += 32; } if (value >> 16 > 0) { value >>= 16; result += 16; } if (value >> 8 > 0) { value >>= 8; result += 8; } if (value >> 4 > 0) { value >>= 4; result += 4; } if (value >> 2 > 0) { value >>= 2; result += 2; } if (value >> 1 > 0) { result += 1; } } return result; } /** * @dev Return the log in base 2, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log2(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log2(value); return result + (unsignedRoundsUp(rounding) && 1 << result < value ? 1 : 0); } } /** * @dev Return the log in base 10 of a positive value rounded towards zero. * Returns 0 if given 0. */ function log10(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >= 10 ** 64) { value /= 10 ** 64; result += 64; } if (value >= 10 ** 32) { value /= 10 ** 32; result += 32; } if (value >= 10 ** 16) { value /= 10 ** 16; result += 16; } if (value >= 10 ** 8) { value /= 10 ** 8; result += 8; } if (value >= 10 ** 4) { value /= 10 ** 4; result += 4; } if (value >= 10 ** 2) { value /= 10 ** 2; result += 2; } if (value >= 10 ** 1) { result += 1; } } return result; } /** * @dev Return the log in base 10, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log10(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log10(value); return result + (unsignedRoundsUp(rounding) && 10 ** result < value ? 1 : 0); } } /** * @dev Return the log in base 256 of a positive value rounded towards zero. * Returns 0 if given 0. * * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string. */ function log256(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >> 128 > 0) { value >>= 128; result += 16; } if (value >> 64 > 0) { value >>= 64; result += 8; } if (value >> 32 > 0) { value >>= 32; result += 4; } if (value >> 16 > 0) { value >>= 16; result += 2; } if (value >> 8 > 0) { result += 1; } } return result; } /** * @dev Return the log in base 256, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log256(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log256(value); return result + (unsignedRoundsUp(rounding) && 1 << (result << 3) < value ? 1 : 0); } } /** * @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers. */ function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) { return uint8(rounding) % 2 == 1; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/math/SignedMath.sol) pragma solidity ^0.8.20; /** * @dev Standard signed math utilities missing in the Solidity language. */ library SignedMath { /** * @dev Returns the largest of two signed numbers. */ function max(int256 a, int256 b) internal pure returns (int256) { return a > b ? a : b; } /** * @dev Returns the smallest of two signed numbers. */ function min(int256 a, int256 b) internal pure returns (int256) { return a < b ? a : b; } /** * @dev Returns the average of two signed numbers without overflow. * The result is rounded towards zero. */ function average(int256 a, int256 b) internal pure returns (int256) { // Formula from the book "Hacker's Delight" int256 x = (a & b) + ((a ^ b) >> 1); return x + (int256(uint256(x) >> 255) & (a ^ b)); } /** * @dev Returns the absolute unsigned value of a signed value. */ function abs(int256 n) internal pure returns (uint256) { unchecked { // must be unchecked in order to support `n = type(int256).min` return uint256(n >= 0 ? n : -n); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/ShortStrings.sol) pragma solidity ^0.8.20; import {StorageSlot} from "./StorageSlot.sol"; // | string | 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA | // | length | 0x BB | type ShortString is bytes32; /** * @dev This library provides functions to convert short memory strings * into a `ShortString` type that can be used as an immutable variable. * * Strings of arbitrary length can be optimized using this library if * they are short enough (up to 31 bytes) by packing them with their * length (1 byte) in a single EVM word (32 bytes). Additionally, a * fallback mechanism can be used for every other case. * * Usage example: * * ```solidity * contract Named { * using ShortStrings for *; * * ShortString private immutable _name; * string private _nameFallback; * * constructor(string memory contractName) { * _name = contractName.toShortStringWithFallback(_nameFallback); * } * * function name() external view returns (string memory) { * return _name.toStringWithFallback(_nameFallback); * } * } * ``` */ library ShortStrings { // Used as an identifier for strings longer than 31 bytes. bytes32 private constant FALLBACK_SENTINEL = 0x00000000000000000000000000000000000000000000000000000000000000FF; error StringTooLong(string str); error InvalidShortString(); /** * @dev Encode a string of at most 31 chars into a `ShortString`. * * This will trigger a `StringTooLong` error is the input string is too long. */ function toShortString(string memory str) internal pure returns (ShortString) { bytes memory bstr = bytes(str); if (bstr.length > 31) { revert StringTooLong(str); } return ShortString.wrap(bytes32(uint256(bytes32(bstr)) | bstr.length)); } /** * @dev Decode a `ShortString` back to a "normal" string. */ function toString(ShortString sstr) internal pure returns (string memory) { uint256 len = byteLength(sstr); // using `new string(len)` would work locally but is not memory safe. string memory str = new string(32); /// @solidity memory-safe-assembly assembly { mstore(str, len) mstore(add(str, 0x20), sstr) } return str; } /** * @dev Return the length of a `ShortString`. */ function byteLength(ShortString sstr) internal pure returns (uint256) { uint256 result = uint256(ShortString.unwrap(sstr)) & 0xFF; if (result > 31) { revert InvalidShortString(); } return result; } /** * @dev Encode a string into a `ShortString`, or write it to storage if it is too long. */ function toShortStringWithFallback(string memory value, string storage store) internal returns (ShortString) { if (bytes(value).length < 32) { return toShortString(value); } else { StorageSlot.getStringSlot(store).value = value; return ShortString.wrap(FALLBACK_SENTINEL); } } /** * @dev Decode a string that was encoded to `ShortString` or written to storage using {setWithFallback}. */ function toStringWithFallback(ShortString value, string storage store) internal pure returns (string memory) { if (ShortString.unwrap(value) != FALLBACK_SENTINEL) { return toString(value); } else { return store; } } /** * @dev Return the length of a string that was encoded to `ShortString` or written to storage using * {setWithFallback}. * * WARNING: This will return the "byte length" of the string. This may not reflect the actual length in terms of * actual characters as the UTF-8 encoding of a single character can span over multiple bytes. */ function byteLengthWithFallback(ShortString value, string storage store) internal view returns (uint256) { if (ShortString.unwrap(value) != FALLBACK_SENTINEL) { return byteLength(value); } else { return bytes(store).length; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/StorageSlot.sol) // This file was procedurally generated from scripts/generate/templates/StorageSlot.js. pragma solidity ^0.8.20; /** * @dev Library for reading and writing primitive types to specific storage slots. * * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. * This library helps with reading and writing to such slots without the need for inline assembly. * * The functions in this library return Slot structs that contain a `value` member that can be used to read or write. * * Example usage to set ERC1967 implementation slot: * ```solidity * contract ERC1967 { * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; * * function _getImplementation() internal view returns (address) { * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; * } * * function _setImplementation(address newImplementation) internal { * require(newImplementation.code.length > 0); * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; * } * } * ``` */ library StorageSlot { struct AddressSlot { address value; } struct BooleanSlot { bool value; } struct Bytes32Slot { bytes32 value; } struct Uint256Slot { uint256 value; } struct StringSlot { string value; } struct BytesSlot { bytes value; } /** * @dev Returns an `AddressSlot` with member `value` located at `slot`. */ function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `BooleanSlot` with member `value` located at `slot`. */ function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `Bytes32Slot` with member `value` located at `slot`. */ function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `Uint256Slot` with member `value` located at `slot`. */ function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `StringSlot` with member `value` located at `slot`. */ function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `StringSlot` representation of the string storage pointer `store`. */ function getStringSlot(string storage store) internal pure returns (StringSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := store.slot } } /** * @dev Returns an `BytesSlot` with member `value` located at `slot`. */ function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`. */ function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := store.slot } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/Strings.sol) pragma solidity ^0.8.20; import {Math} from "./math/Math.sol"; import {SignedMath} from "./math/SignedMath.sol"; /** * @dev String operations. */ library Strings { bytes16 private constant HEX_DIGITS = "0123456789abcdef"; uint8 private constant ADDRESS_LENGTH = 20; /** * @dev The `value` string doesn't fit in the specified `length`. */ error StringsInsufficientHexLength(uint256 value, uint256 length); /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { unchecked { uint256 length = Math.log10(value) + 1; string memory buffer = new string(length); uint256 ptr; /// @solidity memory-safe-assembly assembly { ptr := add(buffer, add(32, length)) } while (true) { ptr--; /// @solidity memory-safe-assembly assembly { mstore8(ptr, byte(mod(value, 10), HEX_DIGITS)) } value /= 10; if (value == 0) break; } return buffer; } } /** * @dev Converts a `int256` to its ASCII `string` decimal representation. */ function toStringSigned(int256 value) internal pure returns (string memory) { return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value))); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { unchecked { return toHexString(value, Math.log256(value) + 1); } } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { uint256 localValue = value; 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_DIGITS[localValue & 0xf]; localValue >>= 4; } if (localValue != 0) { revert StringsInsufficientHexLength(value, length); } return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal * representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), ADDRESS_LENGTH); } /** * @dev Returns true if the two strings are equal. */ function equal(string memory a, string memory b) internal pure returns (bool) { return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b)); } }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.24; struct MintTicket { address nft; address minter; uint256 deadline; }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.24; import "../data/MintTicket.sol"; import "@openzeppelin/contracts/utils/cryptography/EIP712.sol"; import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; contract MintTicketSigantureVerification is EIP712 { using ECDSA for bytes32; bytes32 public constant MINT_TICKET_TYPEHASH = keccak256("MintTicket(address nft,address minter,uint256 deadline)"); constructor() EIP712("ElympicsMintTicket", "1") {} function verify( MintTicket memory ticket, bytes memory signature, address signer ) public view returns (bool) { bool signerMatches = recoverSignerOfMintTicket(ticket, signature) == signer; bool isDeadlineValid = ticket.deadline >= block.timestamp; return signerMatches && isDeadlineValid; } function recoverSignerOfMintTicket( MintTicket memory ticket, bytes memory signature ) public view returns (address) { return _hashTypedDataV4(keccak256(encode(ticket))).recover(signature); } function encode( MintTicket memory _ticket ) public pure returns (bytes memory) { return abi.encode( MINT_TICKET_TYPEHASH, _ticket.nft, _ticket.minter, _ticket.deadline ); } }
{ "viaIR": true, "optimizer": { "enabled": true, "runs": 1000 }, "evmVersion": "paris", "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"},{"internalType":"uint256","name":"_mintPrice","type":"uint256"},{"internalType":"uint256","name":"_maxSupply","type":"uint256"},{"internalType":"uint256","name":"_maxPerWallet","type":"uint256"},{"internalType":"address","name":"_withdrawWallet","type":"address"},{"internalType":"address","name":"_royaltyReceiver","type":"address"},{"internalType":"uint96","name":"_feeNumerator","type":"uint96"},{"internalType":"address","name":"_ticketSigner","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AmountExceeded","type":"error"},{"inputs":[],"name":"CannotMintZeroTokens","type":"error"},{"inputs":[],"name":"ContractEmpty","type":"error"},{"inputs":[],"name":"ECDSAInvalidSignature","type":"error"},{"inputs":[{"internalType":"uint256","name":"length","type":"uint256"}],"name":"ECDSAInvalidSignatureLength","type":"error"},{"inputs":[{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"ECDSAInvalidSignatureS","type":"error"},{"inputs":[{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidDefaultRoyalty","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidDefaultRoyaltyReceiver","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidTokenRoyalty","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidTokenRoyaltyReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721IncorrectOwner","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721InsufficientApproval","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC721InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"ERC721InvalidOperator","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721InvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC721InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC721InvalidSender","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721NonexistentToken","type":"error"},{"inputs":[],"name":"InsufficientValue","type":"error"},{"inputs":[],"name":"InvalidShortString","type":"error"},{"inputs":[],"name":"InvalidTicket","type":"error"},{"inputs":[],"name":"MintNotAllowed","type":"error"},{"inputs":[],"name":"NoMoreTokens","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"inputs":[{"internalType":"string","name":"str","type":"string"}],"name":"StringTooLong","type":"error"},{"inputs":[],"name":"TooHighValue","type":"error"},{"inputs":[],"name":"WithdrawalFailed","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_fromTokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_toTokenId","type":"uint256"}],"name":"BatchMetadataUpdate","type":"event"},{"anonymous":false,"inputs":[],"name":"EIP712DomainChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"MetadataUpdate","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"MINT_TICKET_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"eip712Domain","outputs":[{"internalType":"bytes1","name":"fields","type":"bytes1"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"version","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"address","name":"verifyingContract","type":"address"},{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"uint256[]","name":"extensions","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"nft","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"internalType":"struct MintTicket","name":"_ticket","type":"tuple"}],"name":"encode","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isMintEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"nft","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"internalType":"struct MintTicket","name":"_ticket","type":"tuple"},{"internalType":"bytes","name":"_signature","type":"bytes"},{"internalType":"uint256","name":"_quantity","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":[{"components":[{"internalType":"address","name":"nft","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"internalType":"struct MintTicket","name":"ticket","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"recoverSignerOfMintTicket","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"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":"string","name":"_baseTokenURI","type":"string"}],"name":"setBaseTokenURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_reciever","type":"address"},{"internalType":"uint96","name":"_centiPercents","type":"uint96"}],"name":"setDefaultRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isMintEnabled","type":"bool"}],"name":"setIsMintEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxPerWallet","type":"uint256"}],"name":"setMaxPerWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxSupply","type":"uint256"}],"name":"setMaxSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMintPrice","type":"uint256"}],"name":"setMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"tokenURI","type":"string"}],"internalType":"struct LimitedCollection.TokenURIDefinition[]","name":"_definitions","type":"tuple[]"}],"name":"setMultipleTokenURIs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"tokenURI","type":"string"}],"internalType":"struct LimitedCollection.TokenURIDefinition","name":"_definition","type":"tuple"}],"name":"setTokenURI","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":[],"name":"ticketSigner","outputs":[{"internalType":"address","name":"","type":"address"}],"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":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"nft","type":"address"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"internalType":"struct MintTicket","name":"ticket","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"address","name":"signer","type":"address"}],"name":"verify","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"walletMints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawWallet","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
61016080604052346200066c576200322080380380916200002182856200068d565b83398101610120828203126200066c5781516001600160401b0381116200066c578162000050918401620006d6565b602083015190916001600160401b0382116200066c5762000073918401620006d6565b90604083015160608401519260808501516200009260a0870162000731565b90620000a160c0880162000731565b60e0880151979096906001600160601b03891689036200066c57610100620000ca910162000731565b9360405190620000da8262000671565b6012825271115b1e5b5c1a58dcd35a5b9d151a58dad95d60721b602083015260405197620001088962000671565b60018952603160f81b60208a01528051906001600160401b038211620003dd5760025490600182811c9216801562000661575b6020831014620005555781601f84931162000600575b50602090601f8311600114620005825760009262000576575b50508160011b916000199060031b1c1916176002555b8051906001600160401b038211620003dd5760035490600182811c921680156200056b575b6020831014620005555781601f849311620004e3575b50602090601f8311600114620004545760009262000448575b50508160011b916000199060031b1c1916176003555b33156200042f5760098054336001600160a01b0319821681179092556001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a36200023f8162000746565b610120526200024e87620008ee565b6101405260208151910120958660e052602081519101209485610100524660a0526040519560208701977f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f8952604088015260608701524660808701523060a087015260a0865260c086019686881060018060401b03891117620003dd576040889052865190206080523060c052600c556000600d55600e55600f556010805460ff19169055601380546001600160a01b039283166001600160a01b03199182161790915560128054939092169216919091179055612710906001600160601b03851682106200040c575050506001600160a01b0316908115620003f357604080519081016001600160401b03811182821017620003dd57604052828152602060018060601b03831691015260018060a01b03199060a01b16176000556040516127ba908162000a468239608051816124f8015260a051816125c4015260c051816124c9015260e051816125470152610100518161256d015261012051816107210152610140518161074b0152f35b634e487b7160e01b600052604160045260246000fd5b604051635b6cc80560e11b815260006004820152602490fd5b636f483d0960e01b83526001600160601b03851660c482015260e4015260449150fd5b604051631e4fbdf760e01b815260006004820152602490fd5b015190503880620001d4565b6003600090815293507fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b91905b601f1984168510620004c7576001945083601f19811610620004ad575b505050811b01600355620001ea565b015160001960f88460031b161c191690553880806200049e565b8181015183556020948501946001909301929091019062000481565b60036000529091507fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b601f840160051c8101602085106200054d575b90849392915b601f830160051c820181106200053d575050620001bb565b6000815585945060010162000525565b50806200051f565b634e487b7160e01b600052602260045260246000fd5b91607f1691620001a5565b0151905038806200016a565b6002600090815293506000805160206200320083398151915291905b601f1984168510620005e4576001945083601f19811610620005ca575b505050811b0160025562000180565b015160001960f88460031b161c19169055388080620005bb565b818101518355602094850194600190930192909101906200059e565b600260005290915060008051602062003200833981519152601f840160051c81016020851062000659575b90849392915b601f830160051c820181106200064957505062000151565b6000815585945060010162000631565b50806200062b565b91607f16916200013b565b600080fd5b604081019081106001600160401b03821117620003dd57604052565b601f909101601f19168101906001600160401b03821190821017620003dd57604052565b60005b838110620006c55750506000910152565b8181015183820152602001620006b4565b81601f820112156200066c5780516001600160401b038111620003dd57604051926200070d601f8301601f1916602001856200068d565b818452602082840101116200066c576200072e9160208085019101620006b1565b90565b51906001600160a01b03821682036200066c57565b805160209081811015620007c45750601f8251116200078257808251920151908083106200077357501790565b82600019910360031b1b161790565b604490620007b69260405193849263305a27a960e01b845280600485015282519283918260248701528686019101620006b1565b601f01601f19168101030190fd5b906001600160401b038211620003dd57600a54926001938481811c91168015620008e3575b838210146200055557601f8111620008a9575b5081601f84116001146200083d575092829391839260009462000831575b50501b916000199060031b1c191617600a5560ff90565b0151925038806200081a565b919083601f198116600a60005284600020946000905b888383106200088e575050501062000874575b505050811b01600a5560ff90565b015160001960f88460031b161c1916905538808062000866565b85870151885590960195948501948793509081019062000853565b600a60005284601f84600020920160051c820191601f860160051c015b828110620008d6575050620007fc565b60008155018590620008c6565b90607f1690620007e9565b8051602090818110156200091b5750601f8251116200078257808251920151908083106200077357501790565b906001600160401b038211620003dd57600b54926001938481811c9116801562000a3a575b838210146200055557601f811162000a00575b5081601f841160011462000994575092829391839260009462000988575b50501b916000199060031b1c191617600b5560ff90565b01519250388062000971565b919083601f198116600b60005284600020946000905b88838310620009e55750505010620009cb575b505050811b01600b5560ff90565b015160001960f88460031b161c19169055388080620009bd565b858701518855909601959485019487935090810190620009aa565b600b60005284601f84600020920160051c820191601f860160051c015b82811062000a2d57505062000953565b6000815501859062000a1d565b90607f16906200094056fe608060408181526004908136101561001657600080fd5b600092833560e01c90816301ffc9a7146115465750806304634d8d1461146b57806306fdde03146113b8578063081812fc1461137d578063095ea7b31461128557806318160ddd1461126657806323b872dd1461124e5780632a55205a1461119257806330176e1314610ffd578063346de50a14610fd95780633ccfd60b14610f4857806342842e0e14610f19578063453c231014610efa5780634de8bcfb14610ec357806351b2065314610e1c5780635bad0b9714610db45780636352211e14610d8c5780636817c76c14610d6d5780636f8b44b014610d3157806370a0823114610cc3578063715018a614610c685780637ccd717414610854578063825e282e1461081957806384b0196e1461070557806385d178f4146106dd5780638da5cb5b146106b557806395d89b41146105cb578063a167288e146105a3578063a22cb465146104ee578063b1b709cc146104c6578063b88d4fde14610468578063c87b56dd14610430578063d5abeb0114610411578063e268e4d3146103ef578063e79106d514610392578063e985e9c514610344578063f0293fd31461030d578063f2fde38b1461026b578063f4a0a528146102455763fa693330146101dc57600080fd5b3461023957600319906020368301126102415782359267ffffffffffffffff841161023d5783019183360301126102395761022f610228602461023694610221611cd9565b0183611b84565b3691611810565b9035611d58565b80f35b8280fd5b8480fd5b8380fd5b50503461026757602036600319011261026757610260611cd9565b35600c5580f35b5080fd5b5090346102395760203660031901126102395761028661167a565b9061028f611cd9565b6001600160a01b038092169283156102de575050600954826001600160a01b0319821617600955167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08380a380f35b908460249251917f1e4fbdf7000000000000000000000000000000000000000000000000000000008352820152fd5b83823461026757602036600319011261026757806020926001600160a01b0361033461167a565b1681526014845220549051908152f35b83823461026757806003193601126102675760ff8160209361036461167a565b61036c611695565b6001600160a01b0391821683526007875283832091168252855220549151911615158152f35b509034610239576080366003190112610239576103ae36611798565b926064359067ffffffffffffffff82116103ec57506020936103de6001600160a01b03936103e493369101611847565b90611c77565b915191168152f35b80fd5b5050346102675760203660031901126102675761040a611cd9565b35600f5580f35b838234610267578160031936011261026757602090600e549051908152f35b5082346103ec5760203660031901126103ec57506104516104649235612031565b90519182916020835260208301906116ce565b0390f35b5050346102675760803660031901126102675761048361167a565b61048b611695565b6044359060643567ffffffffffffffff81116104c257610236946104b191369101611847565b926104bd838383611953565b611ed6565b8580fd5b8382346102675781600319360112610267576020906001600160a01b03601254169051908152f35b503461023957806003193601126102395761050761167a565b906024359182151580930361023d576001600160a01b03169283156105755750338452600760205280842083855260205280842060ff1981541660ff8416179055519081527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a380f35b8360249251917f5b08ba18000000000000000000000000000000000000000000000000000000008352820152fd5b83823461026757606036600319011261026757610464906104516105c636611798565b611c03565b5082346103ec57806003193601126103ec5781519182826003546105ee81611865565b908184526020956001918760018216918260001461068e575050600114610632575b5050506104649291610623910385611776565b519282849384528301906116ce565b9190869350600383527fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b5b8284106106765750505082010181610623610464610610565b8054848a01860152889550879490930192810161065d565b60ff19168782015293151560051b8601909301935084925061062391506104649050610610565b8382346102675781600319360112610267576020906001600160a01b03600954169051908152f35b8382346102675781600319360112610267576020906001600160a01b03601354169051908152f35b838234610267578160031936011261026757906107bd916107457f00000000000000000000000000000000000000000000000000000000000000006122e6565b9161076f7f00000000000000000000000000000000000000000000000000000000000000006123ff565b6107ca83519361077e8561175a565b83855260209281519788977f0f00000000000000000000000000000000000000000000000000000000000000895260e060208a015260e08901906116ce565b91878303908801526116ce565b904660608601523060808601528260a086015284820360c0860152602080855193848152019401925b82811061080257505050500390f35b8351855286955093810193928101926001016107f3565b838234610267578160031936011261026757602090517f6c5a0b3f63d911db0f0f9b3483a2731957b4774d4b3d5d910d24111180f40d9e8152f35b509060a03660031901126102395761086b36611798565b9060643567ffffffffffffffff811161023d5761088b9036908301611847565b6084359260ff6010541615610c40576001600160a01b0391828251163003610c3157826020830151163303610c3157906108ca91836012541691611bb7565b15610c22578215610bfa576108e183600d54611be7565b600e5410610bd25733855260146020526108fe8385872054611be7565b600f5410610baa57600c546109138482611b2b565b3410610b9b578361092391611b2b565b3411610b7357845b838110610936578580f35b338652601460205284862061094b8154611bf4565b9055600d5461095981611bf4565b600d5585516109678161175a565b8781523315610b5d5781885284602052838789205416828115159182610b24575b33610b0d575b818b5287602052898b20336001600160a01b031982541617905533907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8c80a4610ade57333b6109e3575b505060010161092b565b6020610a209188999796985180938192630a85bd0160e11b96878452338d8501528b602485015260448401526080606484015260848301906116ce565b038189335af1869181610a95575b50610a63578787610a3d611b54565b8051929083610a5c578151633250574960e11b81523381850152602490fd5b8390602001fd5b94969593946001600160e01b03191603610a7f576001386109d9565b8451633250574960e11b81523381850152602490fd5b9091506020813d602011610ad6575b81610ab160209383611776565b81010312610ad257516001600160e01b031981168103610ad2579038610a2e565b8680fd5b3d9150610aa4565b602485898951917f73c6ac6e000000000000000000000000000000000000000000000000000000008352820152fd5b338b526005602052898b206001815401905561098e565b610b4582600052600660205260406000206001600160a01b03198154169055565b808b526005602052898b208054600019019055610988565b60248589895191633250574960e11b8352820152fd5b5082517f38991c03000000000000000000000000000000000000000000000000000000008152fd5b82855163044044a560e21b8152fd5b5082517f6e048253000000000000000000000000000000000000000000000000000000008152fd5b5082517f2be469fa000000000000000000000000000000000000000000000000000000008152fd5b5082517f4d3f50c7000000000000000000000000000000000000000000000000000000008152fd5b5082516319a1b6d960e21b8152fd5b8386516319a1b6d960e21b8152fd5b8285517f344fa43b000000000000000000000000000000000000000000000000000000008152fd5b83346103ec57806003193601126103ec57610c81611cd9565b806001600160a01b036009546001600160a01b03198116600955167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b5082346103ec5760203660031901126103ec576001600160a01b03610ce661167a565b16928315610d035750806020938392526005845220549051908152f35b9060249251917f89c62b64000000000000000000000000000000000000000000000000000000008352820152fd5b50903461023957602036600319011261023957803591610d4f611cd9565b600d548310610d60575050600e5580f35b5163044044a560e21b8152fd5b838234610267578160031936011261026757602090600c549051908152f35b5082346103ec5760203660031901126103ec57506001600160a01b036103e460209335611d1d565b5090346102395760a036600319011261023957610dd036611798565b906064359067ffffffffffffffff821161023d57610df091369101611847565b90608435936001600160a01b03851685036103ec575092610e1391602094611bb7565b90519015158152f35b50503461026757602036600319011261026757803567ffffffffffffffff91828211610241573660238301121561024157810135918211610239576024916005913660248360051b8301011161023d57610e77929192611cd9565b368190036062190191855b848110610e8d578680f35b8581831b840101359084821215610ebf57610eb9600192850161022f61022860448b8401930183611b84565b01610e82565b8780fd5b505034610267576020366003190112610267573580151580910361026757610ee9611cd9565b60ff80196010541691161760105580f35b838234610267578160031936011261026757602090600f549051908152f35b8382346102675761023690610f2d366116f3565b91925192610f3a8461175a565b8584526104bd838383611953565b5034610239578260031936011261023957610f61611cd9565b4715610fb357828080806001600160a01b036013541647905af1610f83611b54565b5015610f8d578280f35b517f27fcd9d1000000000000000000000000000000000000000000000000000000008152fd5b517f7da4b333000000000000000000000000000000000000000000000000000000008152fd5b83823461026757816003193601126102675760209060ff6010541690519015158152f35b8284346103ec57602091602060031936011261026757803567ffffffffffffffff91828211610241573660238301121561024157810135918211610239576024366024848401011161024157611051611cd9565b61105c601154611865565b601f8111611133575b508394601f84116001146110ac57505082938291611098949261109e575b50508160011b916000199060031b1c19161790565b60115580f35b602492500101358480611083565b7f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c689291601f1985169186915b83831061111757505050948360019596106110fa575b505050811b0160115580f35b0160240135600019600384901b60f8161c191690558380806110ee565b908060018a978483969c890101358155019601980191906110d8565b7f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c68601f850160051c81019160208610611188575b601f0160051c01905b81811061117d5750611065565b858155600101611170565b9091508190611167565b50903461023957816003193601126102395735825260016020528082208151906111bb82611728565b54926001600160a01b03918285169485825260a01c60208201529315611227575b50610464906127106112026bffffffffffffffffffffffff602087015116602435611b2b565b04935116915192839283602090939291936001600160a01b0360408201951681520152565b61046491935082519061123982611728565b54848116825260a01c602082015292906111dc565b83346103ec57610236611260366116f3565b91611953565b838234610267578160031936011261026757602090600d549051908152f35b503461023957806003193601126102395761129e61167a565b91602435906112ac82611d1d565b903315158061136a575b80611342575b611312575081906001600160a01b03809516948591167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258780a4835260066020528220906001600160a01b031982541617905580f35b6024908451907fa9fbf51f0000000000000000000000000000000000000000000000000000000082523390820152fd5b506001600160a01b0382168652600760205283862033875260205260ff8487205416156112bc565b50336001600160a01b03831614156112b6565b50903461023957602036600319011261023957816020936001600160a01b0392356113a781611d1d565b508152600685522054169051908152f35b5082346103ec57806003193601126103ec5781519182826002546113db81611865565b908184526020956001918760018216918260001461068e57505060011461140f575050506104649291610623910385611776565b9190869350600283527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace5b8284106114535750505082010181610623610464610610565b8054848a01860152889550879490930192810161143a565b503461023957806003193601126102395761148461167a565b90602435916bffffffffffffffffffffffff83168084036104c2576114a7611cd9565b612710908181116115115750506001600160a01b03169283156114e35750906114d96001600160a01b03199251611728565b60a01b1617815580f35b8460249251917fb6d9900a000000000000000000000000000000000000000000000000000000008352820152fd5b85925060449351927f6f483d090000000000000000000000000000000000000000000000000000000084528301526024820152fd5b8490843461023957602036600319011261023957356001600160e01b0319811680910361023957602092507f2a55205a0000000000000000000000000000000000000000000000000000000081148015611651575b809181156115ac575b505015158152f35b7f4906490600000000000000000000000000000000000000000000000000000000811492509082156115e2575b505083806115a4565b7f80ac58cd0000000000000000000000000000000000000000000000000000000082149250908215611627575b50811561161f575b5083806115d9565b905083611617565b7f5b5e139f000000000000000000000000000000000000000000000000000000001491508461160f565b507f01ffc9a700000000000000000000000000000000000000000000000000000000811461159b565b600435906001600160a01b038216820361169057565b600080fd5b602435906001600160a01b038216820361169057565b60005b8381106116be5750506000910152565b81810151838201526020016116ae565b906020916116e7815180928185528580860191016116ab565b601f01601f1916010190565b6060906003190112611690576001600160a01b0390600435828116810361169057916024359081168103611690579060443590565b6040810190811067ffffffffffffffff82111761174457604052565b634e487b7160e01b600052604160045260246000fd5b6020810190811067ffffffffffffffff82111761174457604052565b90601f8019910116810190811067ffffffffffffffff82111761174457604052565b606090600319011261169057604051906060820182811067ffffffffffffffff82111761174457604052816001600160a01b03600435818116810361169057825260243590811681036116905760208201526040604435910152565b67ffffffffffffffff811161174457601f01601f191660200190565b92919261181c826117f4565b9161182a6040519384611776565b829481845281830111611690578281602093846000960137010152565b9080601f830112156116905781602061186293359101611810565b90565b90600182811c92168015611895575b602083101461187f57565b634e487b7160e01b600052602260045260246000fd5b91607f1691611874565b601154600092916118af82611865565b8082529160209060019081811690811561192e57506001146118d2575b50505050565b9293945060116000527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c68926000935b85851061191b5750505060209250010190388080806118cc565b8054858501840152938201938101611901565b92505050602093945060ff929192191683830152151560051b010190388080806118cc565b90916001600160a01b03809316928315611b1357600092828452826020956004875260409684888820541696879133151580611a61575b509060047fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9284611a29575b858352600581528b83206001815401905586835252898120846001600160a01b031982541617905580a416928383036119ef5750505050565b6064945051927f64283d7b000000000000000000000000000000000000000000000000000000008452600484015260248301526044820152fd5b611a4a87600052600660205260406000206001600160a01b03198154169055565b848352600581528b832080546000190190556119b6565b91939450915080611ad2575b15611a7d5785929187913861198a565b878688611a9a576024915190637e27328960e01b82526004820152fd5b90517f177e802f0000000000000000000000000000000000000000000000000000000081523360048201526024810191909152604490fd5b503387148015611af7575b80611a6d5750858252600681523385898420541614611a6d565b5086825260078152878220338352815260ff8883205416611add565b6024604051633250574960e11b815260006004820152fd5b81810292918115918404141715611b3e57565b634e487b7160e01b600052601160045260246000fd5b3d15611b7f573d90611b65826117f4565b91611b736040519384611776565b82523d6000602084013e565b606090565b903590601e1981360301821215611690570180359067ffffffffffffffff82116116905760200191813603831361169057565b91611bc460409284611c77565b906001600160a01b0380911691161491015181611bdf575090565b905042111590565b91908201809211611b3e57565b6000198114611b3e5760010190565b6001600160a01b03906040828251169260208301511691015190604051927f6c5a0b3f63d911db0f0f9b3483a2731957b4774d4b3d5d910d24111180f40d9e60208501526040840152606083015260808201526080815260a0810181811067ffffffffffffffff8211176117445760405290565b611862916042611c89611cd093611c03565b60208151910120611c986124bf565b90604051917f1901000000000000000000000000000000000000000000000000000000000000835260028301526022820152206125ea565b90929192612626565b6001600160a01b03600954163303611ced57565b60246040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152fd5b8060005260046020526001600160a01b0360406000205416908115611d40575090565b60249060405190637e27328960e01b82526004820152fd5b91909160009080825260209160088352604081209085519567ffffffffffffffff8711611ec257611d898354611865565b601f8111611e7f575b508491601f8811600114611dfb5796611de49281927ff8e1a15aba9398e019f0b49df1a4fde98ee17ae345cb5f6b5e2c27f5033e8ce7989992611df05750508160011b916000199060031b1c19161790565b90555b604051908152a1565b015190503880611083565b9190601f198816848452868420935b818110611e6857509160019391897ff8e1a15aba9398e019f0b49df1a4fde98ee17ae345cb5f6b5e2c27f5033e8ce7999a9410611e4f575b505050811b019055611de7565b015160001960f88460031b161c19169055388080611e42565b929387600181928786015181550195019301611e0a565b838352858320601f890160051c810191878a10611eb8575b601f0160051c01905b818110611ead5750611d92565b838155600101611ea0565b9091508190611e97565b602482634e487b7160e01b81526041600452fd5b9190803b611ee45750505050565b611f276001600160a01b0380921694604051938493630a85bd0160e11b9687865233600487015216602485015260448401526080606484015260848301906116ce565b03906020816000938185885af190829082611fa5575b5050611f745782611f4c611b54565b8051919082611f6d5760248260405190633250574960e11b82526004820152fd5b9050602001fd5b6001600160e01b03191603611f8d5750388080806118cc565b60249060405190633250574960e11b82526004820152fd5b909192506020813d602011611fe6575b81611fc260209383611776565b810103126102675751906001600160e01b0319821682036103ec5750903880611f3d565b3d9150611fb5565b602061202f91939293604051948161200f87935180928680870191016116ab565b8201612023825180938680850191016116ab565b01038085520183611776565b565b61203a81611d1d565b506000818152602060088152604091828120835182918181549361205d85611865565b92838352600195886001821691826000146122c6575050600114612288575b5061208992500382611776565b845161209f816120988161189f565b0382611776565b80511561227e57815161226e5750506120b785611d1d565b508351946120cf866120c88161189f565b0387611776565b855115612259578092819481927a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000908181101561224c575b50506d04ee2d6d415b85acef81000000008087101561223f575b50662386f26fc1000080871015612230575b506305f5e10080871015612221575b5061271080871015612212575b506064861015612200575b9060219291600a809710156121f6575b908291600186979695940161218561217c826117f4565b9a519a8b611776565b808a52612194601f19916117f4565b019036908a013750860101905b6121b3575b5050505061186291611fee565b600019019083907f30313233343536373839616263646566000000000000000000000000000000008282061a8353049182156121f1579190826121a1565b6121a6565b9160010191612165565b60649095049460029290920191612155565b6004919396049501913861214a565b6008919396049501913861213d565b6010919396049501913861212e565b819396049501913861211c565b0495508692503880612102565b505092505051906122698261175a565b815290565b9350935050506118629250611fee565b5094505050505090565b915050845281858086208587915b8583106122ad57505061208993508201013861207c565b8091929450548385880101520191018690858593612296565b60ff19168582015261208995151560051b850101925038915061207c9050565b60ff811461233c5760ff811690601f8211612312576040519161230883611728565b8252602082015290565b60046040517fb3512b0c000000000000000000000000000000000000000000000000000000008152fd5b50604051600a5481600061234f83611865565b808352926020906001908181169081156123db575060011461237a575b505061186292500382611776565b915092600a6000527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8936000925b8284106123c35750611862945050508101602001388061236c565b855487850183015294850194869450928101926123a8565b9150506020925061186294915060ff191682840152151560051b820101388061236c565b60ff81146124215760ff811690601f8211612312576040519161230883611728565b50604051600b5481600061243483611865565b808352926020906001908181169081156123db575060011461245e57505061186292500382611776565b915092600b6000527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9936000925b8284106124a75750611862945050508101602001388061236c565b8554878501830152948501948694509281019261248c565b6001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163014806125c1575b1561251a577f000000000000000000000000000000000000000000000000000000000000000090565b60405160208101907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f82527f000000000000000000000000000000000000000000000000000000000000000060408201527f000000000000000000000000000000000000000000000000000000000000000060608201524660808201523060a082015260a0815260c0810181811067ffffffffffffffff8211176117445760405251902090565b507f000000000000000000000000000000000000000000000000000000000000000046146124f1565b815191906041830361261b5761261492506020820151906060604084015193015160001a906126f4565b9192909190565b505060009160029190565b60048110156126de5780612638575050565b6001810361266a5760046040517ff645eedf000000000000000000000000000000000000000000000000000000008152fd5b600281036126a357602482604051907ffce698f70000000000000000000000000000000000000000000000000000000082526004820152fd5b6003146126ad5750565b602490604051907fd78bce0c0000000000000000000000000000000000000000000000000000000082526004820152fd5b634e487b7160e01b600052602160045260246000fd5b91907f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0841161277857926020929160ff608095604051948552168484015260408301526060820152600092839182805260015afa1561276c5780516001600160a01b0381161561276357918190565b50809160019190565b604051903d90823e3d90fd5b5050506000916003919056fea26469706673582212206ab6c517ee08b1b9c3f8c77f599bc0edbeee1fd1beb127d3ffba40bc0b8b5b3264736f6c63430008180033405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000214e8348c4f000000000000000000000000000000000000000000000000000000000000000002260000000000000000000000000000000000000000000000000000000000000001000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a00000000000000000000000000000000000000000000000000000000000003e8000000000000000000000000c755778a6b9bdb14f1d78b1b5041a3465d0264c60000000000000000000000000000000000000000000000000000000000000013456c796d7069637320416c70686120506173730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034541500000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608060408181526004908136101561001657600080fd5b600092833560e01c90816301ffc9a7146115465750806304634d8d1461146b57806306fdde03146113b8578063081812fc1461137d578063095ea7b31461128557806318160ddd1461126657806323b872dd1461124e5780632a55205a1461119257806330176e1314610ffd578063346de50a14610fd95780633ccfd60b14610f4857806342842e0e14610f19578063453c231014610efa5780634de8bcfb14610ec357806351b2065314610e1c5780635bad0b9714610db45780636352211e14610d8c5780636817c76c14610d6d5780636f8b44b014610d3157806370a0823114610cc3578063715018a614610c685780637ccd717414610854578063825e282e1461081957806384b0196e1461070557806385d178f4146106dd5780638da5cb5b146106b557806395d89b41146105cb578063a167288e146105a3578063a22cb465146104ee578063b1b709cc146104c6578063b88d4fde14610468578063c87b56dd14610430578063d5abeb0114610411578063e268e4d3146103ef578063e79106d514610392578063e985e9c514610344578063f0293fd31461030d578063f2fde38b1461026b578063f4a0a528146102455763fa693330146101dc57600080fd5b3461023957600319906020368301126102415782359267ffffffffffffffff841161023d5783019183360301126102395761022f610228602461023694610221611cd9565b0183611b84565b3691611810565b9035611d58565b80f35b8280fd5b8480fd5b8380fd5b50503461026757602036600319011261026757610260611cd9565b35600c5580f35b5080fd5b5090346102395760203660031901126102395761028661167a565b9061028f611cd9565b6001600160a01b038092169283156102de575050600954826001600160a01b0319821617600955167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08380a380f35b908460249251917f1e4fbdf7000000000000000000000000000000000000000000000000000000008352820152fd5b83823461026757602036600319011261026757806020926001600160a01b0361033461167a565b1681526014845220549051908152f35b83823461026757806003193601126102675760ff8160209361036461167a565b61036c611695565b6001600160a01b0391821683526007875283832091168252855220549151911615158152f35b509034610239576080366003190112610239576103ae36611798565b926064359067ffffffffffffffff82116103ec57506020936103de6001600160a01b03936103e493369101611847565b90611c77565b915191168152f35b80fd5b5050346102675760203660031901126102675761040a611cd9565b35600f5580f35b838234610267578160031936011261026757602090600e549051908152f35b5082346103ec5760203660031901126103ec57506104516104649235612031565b90519182916020835260208301906116ce565b0390f35b5050346102675760803660031901126102675761048361167a565b61048b611695565b6044359060643567ffffffffffffffff81116104c257610236946104b191369101611847565b926104bd838383611953565b611ed6565b8580fd5b8382346102675781600319360112610267576020906001600160a01b03601254169051908152f35b503461023957806003193601126102395761050761167a565b906024359182151580930361023d576001600160a01b03169283156105755750338452600760205280842083855260205280842060ff1981541660ff8416179055519081527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a380f35b8360249251917f5b08ba18000000000000000000000000000000000000000000000000000000008352820152fd5b83823461026757606036600319011261026757610464906104516105c636611798565b611c03565b5082346103ec57806003193601126103ec5781519182826003546105ee81611865565b908184526020956001918760018216918260001461068e575050600114610632575b5050506104649291610623910385611776565b519282849384528301906116ce565b9190869350600383527fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b5b8284106106765750505082010181610623610464610610565b8054848a01860152889550879490930192810161065d565b60ff19168782015293151560051b8601909301935084925061062391506104649050610610565b8382346102675781600319360112610267576020906001600160a01b03600954169051908152f35b8382346102675781600319360112610267576020906001600160a01b03601354169051908152f35b838234610267578160031936011261026757906107bd916107457f456c796d706963734d696e745469636b657400000000000000000000000000126122e6565b9161076f7f31000000000000000000000000000000000000000000000000000000000000016123ff565b6107ca83519361077e8561175a565b83855260209281519788977f0f00000000000000000000000000000000000000000000000000000000000000895260e060208a015260e08901906116ce565b91878303908801526116ce565b904660608601523060808601528260a086015284820360c0860152602080855193848152019401925b82811061080257505050500390f35b8351855286955093810193928101926001016107f3565b838234610267578160031936011261026757602090517f6c5a0b3f63d911db0f0f9b3483a2731957b4774d4b3d5d910d24111180f40d9e8152f35b509060a03660031901126102395761086b36611798565b9060643567ffffffffffffffff811161023d5761088b9036908301611847565b6084359260ff6010541615610c40576001600160a01b0391828251163003610c3157826020830151163303610c3157906108ca91836012541691611bb7565b15610c22578215610bfa576108e183600d54611be7565b600e5410610bd25733855260146020526108fe8385872054611be7565b600f5410610baa57600c546109138482611b2b565b3410610b9b578361092391611b2b565b3411610b7357845b838110610936578580f35b338652601460205284862061094b8154611bf4565b9055600d5461095981611bf4565b600d5585516109678161175a565b8781523315610b5d5781885284602052838789205416828115159182610b24575b33610b0d575b818b5287602052898b20336001600160a01b031982541617905533907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8c80a4610ade57333b6109e3575b505060010161092b565b6020610a209188999796985180938192630a85bd0160e11b96878452338d8501528b602485015260448401526080606484015260848301906116ce565b038189335af1869181610a95575b50610a63578787610a3d611b54565b8051929083610a5c578151633250574960e11b81523381850152602490fd5b8390602001fd5b94969593946001600160e01b03191603610a7f576001386109d9565b8451633250574960e11b81523381850152602490fd5b9091506020813d602011610ad6575b81610ab160209383611776565b81010312610ad257516001600160e01b031981168103610ad2579038610a2e565b8680fd5b3d9150610aa4565b602485898951917f73c6ac6e000000000000000000000000000000000000000000000000000000008352820152fd5b338b526005602052898b206001815401905561098e565b610b4582600052600660205260406000206001600160a01b03198154169055565b808b526005602052898b208054600019019055610988565b60248589895191633250574960e11b8352820152fd5b5082517f38991c03000000000000000000000000000000000000000000000000000000008152fd5b82855163044044a560e21b8152fd5b5082517f6e048253000000000000000000000000000000000000000000000000000000008152fd5b5082517f2be469fa000000000000000000000000000000000000000000000000000000008152fd5b5082517f4d3f50c7000000000000000000000000000000000000000000000000000000008152fd5b5082516319a1b6d960e21b8152fd5b8386516319a1b6d960e21b8152fd5b8285517f344fa43b000000000000000000000000000000000000000000000000000000008152fd5b83346103ec57806003193601126103ec57610c81611cd9565b806001600160a01b036009546001600160a01b03198116600955167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b5082346103ec5760203660031901126103ec576001600160a01b03610ce661167a565b16928315610d035750806020938392526005845220549051908152f35b9060249251917f89c62b64000000000000000000000000000000000000000000000000000000008352820152fd5b50903461023957602036600319011261023957803591610d4f611cd9565b600d548310610d60575050600e5580f35b5163044044a560e21b8152fd5b838234610267578160031936011261026757602090600c549051908152f35b5082346103ec5760203660031901126103ec57506001600160a01b036103e460209335611d1d565b5090346102395760a036600319011261023957610dd036611798565b906064359067ffffffffffffffff821161023d57610df091369101611847565b90608435936001600160a01b03851685036103ec575092610e1391602094611bb7565b90519015158152f35b50503461026757602036600319011261026757803567ffffffffffffffff91828211610241573660238301121561024157810135918211610239576024916005913660248360051b8301011161023d57610e77929192611cd9565b368190036062190191855b848110610e8d578680f35b8581831b840101359084821215610ebf57610eb9600192850161022f61022860448b8401930183611b84565b01610e82565b8780fd5b505034610267576020366003190112610267573580151580910361026757610ee9611cd9565b60ff80196010541691161760105580f35b838234610267578160031936011261026757602090600f549051908152f35b8382346102675761023690610f2d366116f3565b91925192610f3a8461175a565b8584526104bd838383611953565b5034610239578260031936011261023957610f61611cd9565b4715610fb357828080806001600160a01b036013541647905af1610f83611b54565b5015610f8d578280f35b517f27fcd9d1000000000000000000000000000000000000000000000000000000008152fd5b517f7da4b333000000000000000000000000000000000000000000000000000000008152fd5b83823461026757816003193601126102675760209060ff6010541690519015158152f35b8284346103ec57602091602060031936011261026757803567ffffffffffffffff91828211610241573660238301121561024157810135918211610239576024366024848401011161024157611051611cd9565b61105c601154611865565b601f8111611133575b508394601f84116001146110ac57505082938291611098949261109e575b50508160011b916000199060031b1c19161790565b60115580f35b602492500101358480611083565b7f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c689291601f1985169186915b83831061111757505050948360019596106110fa575b505050811b0160115580f35b0160240135600019600384901b60f8161c191690558380806110ee565b908060018a978483969c890101358155019601980191906110d8565b7f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c68601f850160051c81019160208610611188575b601f0160051c01905b81811061117d5750611065565b858155600101611170565b9091508190611167565b50903461023957816003193601126102395735825260016020528082208151906111bb82611728565b54926001600160a01b03918285169485825260a01c60208201529315611227575b50610464906127106112026bffffffffffffffffffffffff602087015116602435611b2b565b04935116915192839283602090939291936001600160a01b0360408201951681520152565b61046491935082519061123982611728565b54848116825260a01c602082015292906111dc565b83346103ec57610236611260366116f3565b91611953565b838234610267578160031936011261026757602090600d549051908152f35b503461023957806003193601126102395761129e61167a565b91602435906112ac82611d1d565b903315158061136a575b80611342575b611312575081906001600160a01b03809516948591167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258780a4835260066020528220906001600160a01b031982541617905580f35b6024908451907fa9fbf51f0000000000000000000000000000000000000000000000000000000082523390820152fd5b506001600160a01b0382168652600760205283862033875260205260ff8487205416156112bc565b50336001600160a01b03831614156112b6565b50903461023957602036600319011261023957816020936001600160a01b0392356113a781611d1d565b508152600685522054169051908152f35b5082346103ec57806003193601126103ec5781519182826002546113db81611865565b908184526020956001918760018216918260001461068e57505060011461140f575050506104649291610623910385611776565b9190869350600283527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace5b8284106114535750505082010181610623610464610610565b8054848a01860152889550879490930192810161143a565b503461023957806003193601126102395761148461167a565b90602435916bffffffffffffffffffffffff83168084036104c2576114a7611cd9565b612710908181116115115750506001600160a01b03169283156114e35750906114d96001600160a01b03199251611728565b60a01b1617815580f35b8460249251917fb6d9900a000000000000000000000000000000000000000000000000000000008352820152fd5b85925060449351927f6f483d090000000000000000000000000000000000000000000000000000000084528301526024820152fd5b8490843461023957602036600319011261023957356001600160e01b0319811680910361023957602092507f2a55205a0000000000000000000000000000000000000000000000000000000081148015611651575b809181156115ac575b505015158152f35b7f4906490600000000000000000000000000000000000000000000000000000000811492509082156115e2575b505083806115a4565b7f80ac58cd0000000000000000000000000000000000000000000000000000000082149250908215611627575b50811561161f575b5083806115d9565b905083611617565b7f5b5e139f000000000000000000000000000000000000000000000000000000001491508461160f565b507f01ffc9a700000000000000000000000000000000000000000000000000000000811461159b565b600435906001600160a01b038216820361169057565b600080fd5b602435906001600160a01b038216820361169057565b60005b8381106116be5750506000910152565b81810151838201526020016116ae565b906020916116e7815180928185528580860191016116ab565b601f01601f1916010190565b6060906003190112611690576001600160a01b0390600435828116810361169057916024359081168103611690579060443590565b6040810190811067ffffffffffffffff82111761174457604052565b634e487b7160e01b600052604160045260246000fd5b6020810190811067ffffffffffffffff82111761174457604052565b90601f8019910116810190811067ffffffffffffffff82111761174457604052565b606090600319011261169057604051906060820182811067ffffffffffffffff82111761174457604052816001600160a01b03600435818116810361169057825260243590811681036116905760208201526040604435910152565b67ffffffffffffffff811161174457601f01601f191660200190565b92919261181c826117f4565b9161182a6040519384611776565b829481845281830111611690578281602093846000960137010152565b9080601f830112156116905781602061186293359101611810565b90565b90600182811c92168015611895575b602083101461187f57565b634e487b7160e01b600052602260045260246000fd5b91607f1691611874565b601154600092916118af82611865565b8082529160209060019081811690811561192e57506001146118d2575b50505050565b9293945060116000527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c68926000935b85851061191b5750505060209250010190388080806118cc565b8054858501840152938201938101611901565b92505050602093945060ff929192191683830152151560051b010190388080806118cc565b90916001600160a01b03809316928315611b1357600092828452826020956004875260409684888820541696879133151580611a61575b509060047fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9284611a29575b858352600581528b83206001815401905586835252898120846001600160a01b031982541617905580a416928383036119ef5750505050565b6064945051927f64283d7b000000000000000000000000000000000000000000000000000000008452600484015260248301526044820152fd5b611a4a87600052600660205260406000206001600160a01b03198154169055565b848352600581528b832080546000190190556119b6565b91939450915080611ad2575b15611a7d5785929187913861198a565b878688611a9a576024915190637e27328960e01b82526004820152fd5b90517f177e802f0000000000000000000000000000000000000000000000000000000081523360048201526024810191909152604490fd5b503387148015611af7575b80611a6d5750858252600681523385898420541614611a6d565b5086825260078152878220338352815260ff8883205416611add565b6024604051633250574960e11b815260006004820152fd5b81810292918115918404141715611b3e57565b634e487b7160e01b600052601160045260246000fd5b3d15611b7f573d90611b65826117f4565b91611b736040519384611776565b82523d6000602084013e565b606090565b903590601e1981360301821215611690570180359067ffffffffffffffff82116116905760200191813603831361169057565b91611bc460409284611c77565b906001600160a01b0380911691161491015181611bdf575090565b905042111590565b91908201809211611b3e57565b6000198114611b3e5760010190565b6001600160a01b03906040828251169260208301511691015190604051927f6c5a0b3f63d911db0f0f9b3483a2731957b4774d4b3d5d910d24111180f40d9e60208501526040840152606083015260808201526080815260a0810181811067ffffffffffffffff8211176117445760405290565b611862916042611c89611cd093611c03565b60208151910120611c986124bf565b90604051917f1901000000000000000000000000000000000000000000000000000000000000835260028301526022820152206125ea565b90929192612626565b6001600160a01b03600954163303611ced57565b60246040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152fd5b8060005260046020526001600160a01b0360406000205416908115611d40575090565b60249060405190637e27328960e01b82526004820152fd5b91909160009080825260209160088352604081209085519567ffffffffffffffff8711611ec257611d898354611865565b601f8111611e7f575b508491601f8811600114611dfb5796611de49281927ff8e1a15aba9398e019f0b49df1a4fde98ee17ae345cb5f6b5e2c27f5033e8ce7989992611df05750508160011b916000199060031b1c19161790565b90555b604051908152a1565b015190503880611083565b9190601f198816848452868420935b818110611e6857509160019391897ff8e1a15aba9398e019f0b49df1a4fde98ee17ae345cb5f6b5e2c27f5033e8ce7999a9410611e4f575b505050811b019055611de7565b015160001960f88460031b161c19169055388080611e42565b929387600181928786015181550195019301611e0a565b838352858320601f890160051c810191878a10611eb8575b601f0160051c01905b818110611ead5750611d92565b838155600101611ea0565b9091508190611e97565b602482634e487b7160e01b81526041600452fd5b9190803b611ee45750505050565b611f276001600160a01b0380921694604051938493630a85bd0160e11b9687865233600487015216602485015260448401526080606484015260848301906116ce565b03906020816000938185885af190829082611fa5575b5050611f745782611f4c611b54565b8051919082611f6d5760248260405190633250574960e11b82526004820152fd5b9050602001fd5b6001600160e01b03191603611f8d5750388080806118cc565b60249060405190633250574960e11b82526004820152fd5b909192506020813d602011611fe6575b81611fc260209383611776565b810103126102675751906001600160e01b0319821682036103ec5750903880611f3d565b3d9150611fb5565b602061202f91939293604051948161200f87935180928680870191016116ab565b8201612023825180938680850191016116ab565b01038085520183611776565b565b61203a81611d1d565b506000818152602060088152604091828120835182918181549361205d85611865565b92838352600195886001821691826000146122c6575050600114612288575b5061208992500382611776565b845161209f816120988161189f565b0382611776565b80511561227e57815161226e5750506120b785611d1d565b508351946120cf866120c88161189f565b0387611776565b855115612259578092819481927a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000908181101561224c575b50506d04ee2d6d415b85acef81000000008087101561223f575b50662386f26fc1000080871015612230575b506305f5e10080871015612221575b5061271080871015612212575b506064861015612200575b9060219291600a809710156121f6575b908291600186979695940161218561217c826117f4565b9a519a8b611776565b808a52612194601f19916117f4565b019036908a013750860101905b6121b3575b5050505061186291611fee565b600019019083907f30313233343536373839616263646566000000000000000000000000000000008282061a8353049182156121f1579190826121a1565b6121a6565b9160010191612165565b60649095049460029290920191612155565b6004919396049501913861214a565b6008919396049501913861213d565b6010919396049501913861212e565b819396049501913861211c565b0495508692503880612102565b505092505051906122698261175a565b815290565b9350935050506118629250611fee565b5094505050505090565b915050845281858086208587915b8583106122ad57505061208993508201013861207c565b8091929450548385880101520191018690858593612296565b60ff19168582015261208995151560051b850101925038915061207c9050565b60ff811461233c5760ff811690601f8211612312576040519161230883611728565b8252602082015290565b60046040517fb3512b0c000000000000000000000000000000000000000000000000000000008152fd5b50604051600a5481600061234f83611865565b808352926020906001908181169081156123db575060011461237a575b505061186292500382611776565b915092600a6000527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a8936000925b8284106123c35750611862945050508101602001388061236c565b855487850183015294850194869450928101926123a8565b9150506020925061186294915060ff191682840152151560051b820101388061236c565b60ff81146124215760ff811690601f8211612312576040519161230883611728565b50604051600b5481600061243483611865565b808352926020906001908181169081156123db575060011461245e57505061186292500382611776565b915092600b6000527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9936000925b8284106124a75750611862945050508101602001388061236c565b8554878501830152948501948694509281019261248c565b6001600160a01b037f000000000000000000000000bcf2fb914965e65ec0c065757f24ae6c89117b46163014806125c1575b1561251a577ff88d74caa9958a9a676cfd359a514200c56b53d5c6ae842a64815578e9dcaebe90565b60405160208101907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f82527f04c67bcbeb9d06789b446d6119c944791a997094fc1e5f7d547e6557542bdfa460408201527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc660608201524660808201523060a082015260a0815260c0810181811067ffffffffffffffff8211176117445760405251902090565b507f000000000000000000000000000000000000000000000000000000000000000146146124f1565b815191906041830361261b5761261492506020820151906060604084015193015160001a906126f4565b9192909190565b505060009160029190565b60048110156126de5780612638575050565b6001810361266a5760046040517ff645eedf000000000000000000000000000000000000000000000000000000008152fd5b600281036126a357602482604051907ffce698f70000000000000000000000000000000000000000000000000000000082526004820152fd5b6003146126ad5750565b602490604051907fd78bce0c0000000000000000000000000000000000000000000000000000000082526004820152fd5b634e487b7160e01b600052602160045260246000fd5b91907f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0841161277857926020929160ff608095604051948552168484015260408301526060820152600092839182805260015afa1561276c5780516001600160a01b0381161561276357918190565b50809160019190565b604051903d90823e3d90fd5b5050506000916003919056fea26469706673582212206ab6c517ee08b1b9c3f8c77f599bc0edbeee1fd1beb127d3ffba40bc0b8b5b3264736f6c63430008180033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000001600000000000000000000000000000000000000000000000000214e8348c4f000000000000000000000000000000000000000000000000000000000000000002260000000000000000000000000000000000000000000000000000000000000001000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a00000000000000000000000000000000000000000000000000000000000003e8000000000000000000000000c755778a6b9bdb14f1d78b1b5041a3465d0264c60000000000000000000000000000000000000000000000000000000000000013456c796d7069637320416c70686120506173730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034541500000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _name (string): Elympics Alpha Pass
Arg [1] : _symbol (string): EAP
Arg [2] : _mintPrice (uint256): 150000000000000000
Arg [3] : _maxSupply (uint256): 550
Arg [4] : _maxPerWallet (uint256): 1
Arg [5] : _withdrawWallet (address): 0xe0ccaCc6D5F69B680F195b6c69A4c8F8C522E83A
Arg [6] : _royaltyReceiver (address): 0xe0ccaCc6D5F69B680F195b6c69A4c8F8C522E83A
Arg [7] : _feeNumerator (uint96): 1000
Arg [8] : _ticketSigner (address): 0xC755778a6B9bdB14f1d78B1B5041A3465d0264c6
-----Encoded View---------------
13 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000160
Arg [2] : 0000000000000000000000000000000000000000000000000214e8348c4f0000
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000226
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [5] : 000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a
Arg [6] : 000000000000000000000000e0ccacc6d5f69b680f195b6c69a4c8f8c522e83a
Arg [7] : 00000000000000000000000000000000000000000000000000000000000003e8
Arg [8] : 000000000000000000000000c755778a6b9bdb14f1d78b1b5041a3465d0264c6
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000013
Arg [10] : 456c796d7069637320416c706861205061737300000000000000000000000000
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [12] : 4541500000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
[ 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.