Address Details
contract
0xA5f2FBA47bDF1fD03c7FB75f89FE7C7a8Bb39dD4
- Contract Name
- StarNFT
- Creator
- 0x7d6740–c9cfce at 0xf4878d–99f519
- Balance
- 0 CELO ( )
- Locked CELO Balance
- 0.00 CELO
- Voting CELO Balance
- 0.00 CELO
- Pending Unlocked Gold
- 0.00 CELO
- Tokens
-
Fetching tokens...
- Transactions
- Fetching transactions...
- Transfers
- Fetching transfers...
- Gas Used
- Fetching gas used...
- Last Balance Update
- 8609836
This contract has been verified via Sourcify.
View contract in Sourcify repository
- Contract name:
- StarNFT
- Optimization enabled
- true
- Compiler version
- v0.8.10+commit.fc410830
- Optimization runs
- 200
- EVM Version
- london
- Verified at
- 2022-08-19T05:11:45.501701Z
contracts/StarNFT.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/StringsUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; import "@openzeppelin/contracts-upgradeable/utils/CountersUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/token/ERC721/IERC721Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/token/ERC721/IERC721ReceiverUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/token/ERC721/extensions/IERC721MetadataUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/token/ERC721/extensions/IERC721EnumerableUpgradeable.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract StarNFT is Initializable, ContextUpgradeable, OwnableUpgradeable, ERC165Upgradeable, IERC721Upgradeable, IERC721MetadataUpgradeable, IERC721EnumerableUpgradeable { using AddressUpgradeable for address; using StringsUpgradeable for uint256; // auto increasement tokenids using CountersUpgradeable for CountersUpgradeable.Counter; CountersUpgradeable.Counter private tokenIds; // Token name string private _name; // Token symbol string private _symbol; // Token base uri string baseURI; // logic contract address logic; // Token struct struct Token { address owner; uint256 cateId; uint256 lastBlock; } // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex; // Array with all token ids, used for enumeration uint256[] private _allTokens; // Mapping from token id to position in the allTokens array mapping(uint256 => uint256) private _allTokensIndex; // Mapping from token ID to owner address mapping (uint256 => Token) public tokenInfo; // Mapping owner address to token count mapping (address => uint256) private _balances; // Mapping from token ID to approved address mapping (uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping (address => mapping (address => bool)) private _operatorApprovals; // Mapping from cate to token uri mapping (uint256 => string) public cateUri; function initialize(string memory name_, string memory symbol_) public initializer { __ERC721_init(name_, symbol_); } /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ function __ERC721_init(string memory name_, string memory symbol_) internal initializer { __Context_init_unchained(); __Ownable_init_unchained(); __ERC165_init_unchained(); __ERC721_init_unchained(name_, symbol_); } function __ERC721_init_unchained(string memory name_, string memory symbol_) internal initializer { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165Upgradeable, IERC165Upgradeable) returns (bool) { return interfaceId == type(IERC721Upgradeable).interfaceId || interfaceId == type(IERC721MetadataUpgradeable).interfaceId || super.supportsInterface(interfaceId); } function a(address owner) external view returns (uint256) { for (uint256 i = 0 ; i < _balances[owner]; i ++) { return _ownedTokens[owner][i]; } } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = tokenInfo[tokenId].owner; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, cateUri[tokenInfo[tokenId].cateId])) : ''; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return baseURI; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require(_msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom(address from, address to, uint256 tokenId) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory _data) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; } /** * @dev See {IERC721Enumerable-tokenByIndex}. */ function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; } function mint(address owner, uint256 _cateId) public onlyLogic returns (uint256) { tokenIds.increment(); uint256 _tokenId = tokenIds.current(); _safeMint(owner, _tokenId); tokenInfo[_tokenId].cateId = _cateId; tokenInfo[_tokenId].lastBlock = block.number; return _tokenId; } function massVerifyOwner(address owner, uint256[] memory _tokenIds) view public returns (bool) { for (uint256 i = 0 ; i < _tokenIds.length; i ++) { if (ownerOf(_tokenIds[i]) != owner) return false; } return true; } function massBurn(uint256[] memory _tokenIds) public onlyLogic { for (uint256 i = 0 ; i < _tokenIds.length; i ++) { _burn(_tokenIds[i]); } } function setCateURI(uint256 _cateId, string memory _cateUri) public virtual onlyLogic { require(bytes(_cateUri).length > 0, "uri is empty"); cateUri[_cateId] = _cateUri; } function setLogic(address _logic) public virtual onlyOwner { require(address(0) != _logic); logic = _logic; } function setBaseURI(string memory _newBaseURI) public virtual onlyOwner { baseURI = _newBaseURI; } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer(address from, address to, uint256 tokenId, bytes memory _data) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */ function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; } /** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */ function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); } /** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes). * This has O(1) time complexity, but alters the order of the _ownedTokens array. * @param from address representing the previous owner of the given token ID * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address */ function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = balanceOf(from) - 1; uint256 tokenIndex = _ownedTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary if (tokenIndex != lastTokenIndex) { uint256 lastTokenId = _ownedTokens[from][lastTokenIndex]; _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index } // This also deletes the contents at the last position of the array delete _ownedTokensIndex[tokenId]; delete _ownedTokens[from][lastTokenIndex]; } /** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */ function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding // an 'if' statement (like in _removeTokenFromOwnerEnumeration) uint256 lastTokenId = _allTokens[lastTokenIndex]; _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index // This also deletes the contents at the last position of the array delete _allTokensIndex[tokenId]; _allTokens.pop(); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return tokenInfo[tokenId].owner != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint(address to, uint256 tokenId, bytes memory _data) internal virtual { _mint(to, tokenId); require(_checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; tokenInfo[tokenId].owner = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete tokenInfo[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer(address from, address to, uint256 tokenId) internal virtual { require(ownerOf(tokenId) == from, "ERC721: transfer of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; tokenInfo[tokenId].owner = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data) private returns (bool) { if (to.isContract()) { try IERC721ReceiverUpgradeable(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721ReceiverUpgradeable(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { // solhint-disable-next-line no-inline-assembly assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } modifier onlyLogic() { require(logic == _msgSender(), "ERC721: not allowed to access"); _; } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer(address from, address to, uint256 tokenId) internal virtual { if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnumeration(from, tokenId); } if (to == address(0)) { _removeTokenFromAllTokensEnumeration(tokenId); } else if (to != from) { _addTokenToOwnerEnumeration(to, tokenId); } } uint256[44] private __gap; }
/_openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/ContextUpgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract OwnableUpgradeable is Initializable, ContextUpgradeable { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ function __Ownable_init() internal initializer { __Context_init_unchained(); __Ownable_init_unchained(); } function __Ownable_init_unchained() internal initializer { _transferOwnership(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } uint256[49] private __gap; }
/_openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (proxy/utils/Initializable.sol) pragma solidity ^0.8.0; /** * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed * behind a proxy. Since a proxied contract can't have a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. * * [CAUTION] * ==== * Avoid leaving a contract uninitialized. * * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation * contract, which may impact the proxy. To initialize the implementation contract, you can either invoke the * initializer manually, or you can include a constructor to automatically mark it as initialized when it is deployed: * * [.hljs-theme-light.nopadding] * ``` * /// @custom:oz-upgrades-unsafe-allow constructor * constructor() initializer {} * ``` * ==== */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. */ bool private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Modifier to protect an initializer function from being invoked twice. */ modifier initializer() { require(_initializing || !_initialized, "Initializable: contract is already initialized"); bool isTopLevelCall = !_initializing; if (isTopLevelCall) { _initializing = true; _initialized = true; } _; if (isTopLevelCall) { _initializing = false; } } }
/_openzeppelin/contracts-upgradeable/token/ERC721/IERC721ReceiverUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721ReceiverUpgradeable { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
/_openzeppelin/contracts-upgradeable/token/ERC721/IERC721Upgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165Upgradeable.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721Upgradeable is IERC165Upgradeable { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
/_openzeppelin/contracts-upgradeable/token/ERC721/extensions/IERC721EnumerableUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (token/ERC721/extensions/IERC721Enumerable.sol) pragma solidity ^0.8.0; import "../IERC721Upgradeable.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721EnumerableUpgradeable is IERC721Upgradeable { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
/_openzeppelin/contracts-upgradeable/token/ERC721/extensions/IERC721MetadataUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721Upgradeable.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721MetadataUpgradeable is IERC721Upgradeable { /** * @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); }
/_openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/Address.sol) pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library AddressUpgradeable { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
/_openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/Context.sol) pragma solidity ^0.8.0; import "../proxy/utils/Initializable.sol"; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract ContextUpgradeable is Initializable { function __Context_init() internal initializer { __Context_init_unchained(); } function __Context_init_unchained() internal initializer { } function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } uint256[50] private __gap; }
/_openzeppelin/contracts-upgradeable/utils/CountersUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/Counters.sol) pragma solidity ^0.8.0; /** * @title Counters * @author Matt Condon (@shrugs) * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number * of elements in a mapping, issuing ERC721 ids, or counting request ids. * * Include with `using Counters for Counters.Counter;` */ library CountersUpgradeable { struct Counter { // This variable should never be directly accessed by users of the library: interactions must be restricted to // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add // this feature: see https://github.com/ethereum/solidity/issues/4637 uint256 _value; // default: 0 } function current(Counter storage counter) internal view returns (uint256) { return counter._value; } function increment(Counter storage counter) internal { unchecked { counter._value += 1; } } function decrement(Counter storage counter) internal { uint256 value = counter._value; require(value > 0, "Counter: decrement overflow"); unchecked { counter._value = value - 1; } } function reset(Counter storage counter) internal { counter._value = 0; } }
/_openzeppelin/contracts-upgradeable/utils/StringsUpgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library StringsUpgradeable { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
/_openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165Upgradeable.sol"; import "../../proxy/utils/Initializable.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165Upgradeable is Initializable, IERC165Upgradeable { function __ERC165_init() internal initializer { __ERC165_init_unchained(); } function __ERC165_init_unchained() internal initializer { } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165Upgradeable).interfaceId; } uint256[50] private __gap; }
/_openzeppelin/contracts-upgradeable/utils/introspection/IERC165Upgradeable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.0 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165Upgradeable { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
Contract ABI
[{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"approved","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"event","name":"ApprovalForAll","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"bool","name":"approved","internalType":"bool","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"a","inputs":[{"type":"address","name":"owner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"approve","inputs":[{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"owner","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"cateUri","inputs":[{"type":"uint256","name":"","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"getApproved","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"initialize","inputs":[{"type":"string","name":"name_","internalType":"string"},{"type":"string","name":"symbol_","internalType":"string"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isApprovedForAll","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"operator","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"massBurn","inputs":[{"type":"uint256[]","name":"_tokenIds","internalType":"uint256[]"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"massVerifyOwner","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"uint256[]","name":"_tokenIds","internalType":"uint256[]"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"mint","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"uint256","name":"_cateId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"ownerOf","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"bytes","name":"_data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setApprovalForAll","inputs":[{"type":"address","name":"operator","internalType":"address"},{"type":"bool","name":"approved","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setBaseURI","inputs":[{"type":"string","name":"_newBaseURI","internalType":"string"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setCateURI","inputs":[{"type":"uint256","name":"_cateId","internalType":"uint256"},{"type":"string","name":"_cateUri","internalType":"string"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setLogic","inputs":[{"type":"address","name":"_logic","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"supportsInterface","inputs":[{"type":"bytes4","name":"interfaceId","internalType":"bytes4"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenByIndex","inputs":[{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"uint256","name":"cateId","internalType":"uint256"},{"type":"uint256","name":"lastBlock","internalType":"uint256"}],"name":"tokenInfo","inputs":[{"type":"uint256","name":"","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenOfOwnerByIndex","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"tokenURI","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]}]
Contract Creation Code
0x608060405234801561001057600080fd5b506123f5806100206000396000f3fe608060405234801561001057600080fd5b50600436106101cf5760003560e01c806370a0823111610104578063b1d73026116100a2578063cc33c87511610071578063cc33c875146103c7578063cd846f1114610425578063e985e9c514610438578063f2fde38b1461047457600080fd5b8063b1d730261461037b578063b88d4fde1461038e578063c68d81e0146103a1578063c87b56dd146103b457600080fd5b80638da5cb5b116100de5780638da5cb5b1461033c57806395d89b411461034d578063a22cb46514610355578063adc84d2e1461036857600080fd5b806370a082311461030e578063715018a614610321578063718570001461032957600080fd5b806340c10f19116101715780634f69b8621161014b5780634f69b862146102c25780634f6ccce7146102d557806355f804b3146102e85780636352211e146102fb57600080fd5b806340c10f191461028957806342842e0e1461029c5780634cd88b76146102af57600080fd5b8063095ea7b3116101ad578063095ea7b31461023c57806318160ddd1461025157806323b872dd146102635780632f745c591461027657600080fd5b806301ffc9a7146101d457806306fdde03146101fc578063081812fc14610211575b600080fd5b6101e76101e2366004611be5565b610487565b60405190151581526020015b60405180910390f35b6102046104d9565b6040516101f39190611c56565b61022461021f366004611c69565b61056b565b6040516001600160a01b0390911681526020016101f3565b61024f61024a366004611c9e565b610605565b005b609e545b6040519081526020016101f3565b61024f610271366004611cc8565b61071b565b610255610284366004611c9e565b61074c565b610255610297366004611c9e565b6107e2565b61024f6102aa366004611cc8565b610858565b61024f6102bd366004611dc3565b610873565b6101e76102d0366004611ea7565b6108ea565b6102556102e3366004611c69565b610957565b61024f6102f6366004611eeb565b6109ea565b610224610309366004611c69565b610a2b565b61025561031c366004611f20565b610aa2565b61024f610b29565b61024f610337366004611f20565b610b5f565b6033546001600160a01b0316610224565b610204610bbe565b61024f610363366004611f3b565b610bcd565b61024f610376366004611f77565b610c92565b61024f610389366004611fb4565b610d1b565b61024f61039c366004611fe9565b610d85565b6102556103af366004611f20565b610dbd565b6102046103c2366004611c69565b610e0f565b6104006103d5366004611c69565b60a0602052600090815260409020805460018201546002909201546001600160a01b03909116919083565b604080516001600160a01b0390941684526020840192909252908201526060016101f3565b610204610433366004611c69565b610efe565b6101e7610446366004612065565b6001600160a01b03918216600090815260a36020908152604080832093909416825291909152205460ff1690565b61024f610482366004611f20565b610f98565b60006001600160e01b031982166380ac58cd60e01b14806104b857506001600160e01b03198216635b5e139f60e01b145b806104d357506301ffc9a760e01b6001600160e01b03198316145b92915050565b6060609880546104e890612098565b80601f016020809104026020016040519081016040528092919081815260200182805461051490612098565b80156105615780601f1061053657610100808354040283529160200191610561565b820191906000526020600020905b81548152906001019060200180831161054457829003601f168201915b5050505050905090565b600081815260a060205260408120546001600160a01b03166105e95760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b50600090815260a260205260409020546001600160a01b031690565b600061061082610a2b565b9050806001600160a01b0316836001600160a01b0316141561067e5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084016105e0565b336001600160a01b038216148061069a575061069a8133610446565b61070c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c000000000000000060648201526084016105e0565b6107168383611033565b505050565b61072533826110a1565b6107415760405162461bcd60e51b81526004016105e0906120cd565b610716838383611198565b600061075783610aa2565b82106107b95760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b60648201526084016105e0565b506001600160a01b03919091166000908152609c60209081526040808320938352929052205490565b609b546000906001600160a01b0316331461080f5760405162461bcd60e51b81526004016105e09061211e565b61081d609780546001019055565b600061082860975490565b90506108348482611343565b600081815260a0602052604090206001810184905543600290910155905092915050565b61071683838360405180602001604052806000815250610d85565b600054610100900460ff168061088c575060005460ff16155b6108a85760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156108ca576000805461ffff19166101011790555b6108d4838361135d565b8015610716576000805461ff0019169055505050565b6000805b825181101561094d57836001600160a01b0316610923848381518110610916576109166121a3565b6020026020010151610a2b565b6001600160a01b03161461093b5760009150506104d3565b80610945816121cf565b9150506108ee565b5060019392505050565b6000610962609e5490565b82106109c55760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b60648201526084016105e0565b609e82815481106109d8576109d86121a3565b90600052602060002001549050919050565b6033546001600160a01b03163314610a145760405162461bcd60e51b81526004016105e0906121ea565b8051610a2790609a906020840190611b36565b5050565b600081815260a060205260408120546001600160a01b0316806104d35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b60648201526084016105e0565b60006001600160a01b038216610b0d5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b60648201526084016105e0565b506001600160a01b0316600090815260a1602052604090205490565b6033546001600160a01b03163314610b535760405162461bcd60e51b81526004016105e0906121ea565b610b5d60006113d6565b565b6033546001600160a01b03163314610b895760405162461bcd60e51b81526004016105e0906121ea565b6001600160a01b038116610b9c57600080fd5b609b80546001600160a01b0319166001600160a01b0392909216919091179055565b6060609980546104e890612098565b6001600160a01b038216331415610c265760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016105e0565b33600081815260a3602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b609b546001600160a01b03163314610cbc5760405162461bcd60e51b81526004016105e09061211e565b6000815111610cfc5760405162461bcd60e51b815260206004820152600c60248201526b75726920697320656d70747960a01b60448201526064016105e0565b600082815260a460209081526040909120825161071692840190611b36565b609b546001600160a01b03163314610d455760405162461bcd60e51b81526004016105e09061211e565b60005b8151811015610a2757610d73828281518110610d6657610d666121a3565b6020026020010151611428565b80610d7d816121cf565b915050610d48565b610d8f33836110a1565b610dab5760405162461bcd60e51b81526004016105e0906120cd565b610db7848484846114dc565b50505050565b6001600160a01b038116600090815260a16020526040812054819015610e09576001600160a01b039092166000908152609c602090815260408083209483529390529190912054919050565b50919050565b600081815260a060205260409020546060906001600160a01b0316610e8e5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b60648201526084016105e0565b6000609a8054610e9d90612098565b905011610eb957604051806020016040528060008152506104d3565b600082815260a06020908152604080832060010154835260a48252918290209151610ee992609a929091016122b9565b60405160208183030381529060405292915050565b60a46020526000908152604090208054610f1790612098565b80601f0160208091040260200160405190810160405280929190818152602001828054610f4390612098565b8015610f905780601f10610f6557610100808354040283529160200191610f90565b820191906000526020600020905b815481529060010190602001808311610f7357829003601f168201915b505050505081565b6033546001600160a01b03163314610fc25760405162461bcd60e51b81526004016105e0906121ea565b6001600160a01b0381166110275760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016105e0565b611030816113d6565b50565b600081815260a26020526040902080546001600160a01b0319166001600160a01b038416908117909155819061106882610a2b565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600081815260a060205260408120546001600160a01b031661111a5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084016105e0565b600061112583610a2b565b9050806001600160a01b0316846001600160a01b031614806111605750836001600160a01b03166111558461056b565b6001600160a01b0316145b8061119057506001600160a01b03808216600090815260a3602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166111ab82610a2b565b6001600160a01b0316146112135760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b60648201526084016105e0565b6001600160a01b0382166112755760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016105e0565b61128083838361150f565b61128b600082611033565b6001600160a01b038316600090815260a1602052604081208054600192906112b49084906122ce565b90915550506001600160a01b038216600090815260a1602052604081208054600192906112e29084906122e5565b9091555050600081815260a0602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b610a278282604051806020016040528060008152506115c7565b600054610100900460ff1680611376575060005460ff16155b6113925760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156113b4576000805461ffff19166101011790555b6113bc6115fa565b6113c4611665565b6113cc6115fa565b6108d483836116c5565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600061143382610a2b565b90506114418160008461150f565b61144c600083611033565b6001600160a01b038116600090815260a1602052604081208054600192906114759084906122ce565b9091555050600082815260a0602052604080822080546001600160a01b031916815560018101839055600201829055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6114e7848484611198565b6114f38484848461175a565b610db75760405162461bcd60e51b81526004016105e0906122fd565b6001600160a01b03831661156a5761156581609e80546000838152609f60205260408120829055600182018355919091527fcfe2a20ff701a1f3e14f63bd70d6c6bc6fba8172ec6d5a505cdab3927c0a9de60155565b61158d565b816001600160a01b0316836001600160a01b03161461158d5761158d8382611858565b6001600160a01b0382166115a457610716816118f5565b826001600160a01b0316826001600160a01b0316146107165761071682826119a4565b6115d183836119e8565b6115de600084848461175a565b6107165760405162461bcd60e51b81526004016105e0906122fd565b600054610100900460ff1680611613575060005460ff16155b61162f5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff16158015611651576000805461ffff19166101011790555b8015611030576000805461ff001916905550565b600054610100900460ff168061167e575060005460ff16155b61169a5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156116bc576000805461ffff19166101011790555b611651336113d6565b600054610100900460ff16806116de575060005460ff16155b6116fa5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff1615801561171c576000805461ffff19166101011790555b825161172f906098906020860190611b36565b508151611743906099906020850190611b36565b508015610716576000805461ff0019169055505050565b60006001600160a01b0384163b1561184d57604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061179e90339089908890889060040161234f565b6020604051808303816000875af19250505080156117d9575060408051601f3d908101601f191682019092526117d69181019061238c565b60015b611833573d808015611807576040519150601f19603f3d011682016040523d82523d6000602084013e61180c565b606091505b50805161182b5760405162461bcd60e51b81526004016105e0906122fd565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611190565b506001949350505050565b6000600161186584610aa2565b61186f91906122ce565b6000838152609d60205260409020549091508082146118c2576001600160a01b0384166000908152609c602090815260408083208584528252808320548484528184208190558352609d90915290208190555b506000918252609d602090815260408084208490556001600160a01b039094168352609c81528383209183525290812055565b609e54600090611907906001906122ce565b6000838152609f6020526040812054609e805493945090928490811061192f5761192f6121a3565b9060005260206000200154905080609e8381548110611950576119506121a3565b6000918252602080832090910192909255828152609f9091526040808220849055858252812055609e805480611988576119886123a9565b6001900381819060005260206000200160009055905550505050565b60006119af83610aa2565b6001600160a01b039093166000908152609c602090815260408083208684528252808320859055938252609d9052919091209190915550565b6001600160a01b038216611a3e5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016105e0565b600081815260a060205260409020546001600160a01b031615611aa35760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016105e0565b611aaf6000838361150f565b6001600160a01b038216600090815260a160205260408120805460019290611ad89084906122e5565b9091555050600081815260a0602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054611b4290612098565b90600052602060002090601f016020900481019282611b645760008555611baa565b82601f10611b7d57805160ff1916838001178555611baa565b82800160010185558215611baa579182015b82811115611baa578251825591602001919060010190611b8f565b50611bb6929150611bba565b5090565b5b80821115611bb65760008155600101611bbb565b6001600160e01b03198116811461103057600080fd5b600060208284031215611bf757600080fd5b8135611c0281611bcf565b9392505050565b6000815180845260005b81811015611c2f57602081850181015186830182015201611c13565b81811115611c41576000602083870101525b50601f01601f19169290920160200192915050565b602081526000611c026020830184611c09565b600060208284031215611c7b57600080fd5b5035919050565b80356001600160a01b0381168114611c9957600080fd5b919050565b60008060408385031215611cb157600080fd5b611cba83611c82565b946020939093013593505050565b600080600060608486031215611cdd57600080fd5b611ce684611c82565b9250611cf460208501611c82565b9150604084013590509250925092565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715611d4357611d43611d04565b604052919050565b600067ffffffffffffffff831115611d6557611d65611d04565b611d78601f8401601f1916602001611d1a565b9050828152838383011115611d8c57600080fd5b828260208301376000602084830101529392505050565b600082601f830112611db457600080fd5b611c0283833560208501611d4b565b60008060408385031215611dd657600080fd5b823567ffffffffffffffff80821115611dee57600080fd5b611dfa86838701611da3565b93506020850135915080821115611e1057600080fd5b50611e1d85828601611da3565b9150509250929050565b600082601f830112611e3857600080fd5b8135602067ffffffffffffffff821115611e5457611e54611d04565b8160051b611e63828201611d1a565b9283528481018201928281019087851115611e7d57600080fd5b83870192505b84831015611e9c57823582529183019190830190611e83565b979650505050505050565b60008060408385031215611eba57600080fd5b611ec383611c82565b9150602083013567ffffffffffffffff811115611edf57600080fd5b611e1d85828601611e27565b600060208284031215611efd57600080fd5b813567ffffffffffffffff811115611f1457600080fd5b61119084828501611da3565b600060208284031215611f3257600080fd5b611c0282611c82565b60008060408385031215611f4e57600080fd5b611f5783611c82565b915060208301358015158114611f6c57600080fd5b809150509250929050565b60008060408385031215611f8a57600080fd5b82359150602083013567ffffffffffffffff811115611fa857600080fd5b611e1d85828601611da3565b600060208284031215611fc657600080fd5b813567ffffffffffffffff811115611fdd57600080fd5b61119084828501611e27565b60008060008060808587031215611fff57600080fd5b61200885611c82565b935061201660208601611c82565b925060408501359150606085013567ffffffffffffffff81111561203957600080fd5b8501601f8101871361204a57600080fd5b61205987823560208401611d4b565b91505092959194509250565b6000806040838503121561207857600080fd5b61208183611c82565b915061208f60208401611c82565b90509250929050565b600181811c908216806120ac57607f821691505b60208210811415610e0957634e487b7160e01b600052602260045260246000fd5b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252601d908201527f4552433732313a206e6f7420616c6c6f77656420746f20616363657373000000604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006000198214156121e3576121e36121b9565b5060010190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b8054600090600181811c908083168061223957607f831692505b602080841082141561225b57634e487b7160e01b600052602260045260246000fd5b81801561226f5760018114612280576122ad565b60ff198616895284890196506122ad565b60008881526020902060005b868110156122a55781548b82015290850190830161228c565b505084890196505b50505050505092915050565b60006111906122c8838661221f565b8461221f565b6000828210156122e0576122e06121b9565b500390565b600082198211156122f8576122f86121b9565b500190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061238290830184611c09565b9695505050505050565b60006020828403121561239e57600080fd5b8151611c0281611bcf565b634e487b7160e01b600052603160045260246000fdfea264697066735822122006a8aea773918e7694a8d954e76d094a0c147a153ef95811b6739500fc0e282764736f6c634300080a0033
Deployed ByteCode
0x608060405234801561001057600080fd5b50600436106101cf5760003560e01c806370a0823111610104578063b1d73026116100a2578063cc33c87511610071578063cc33c875146103c7578063cd846f1114610425578063e985e9c514610438578063f2fde38b1461047457600080fd5b8063b1d730261461037b578063b88d4fde1461038e578063c68d81e0146103a1578063c87b56dd146103b457600080fd5b80638da5cb5b116100de5780638da5cb5b1461033c57806395d89b411461034d578063a22cb46514610355578063adc84d2e1461036857600080fd5b806370a082311461030e578063715018a614610321578063718570001461032957600080fd5b806340c10f19116101715780634f69b8621161014b5780634f69b862146102c25780634f6ccce7146102d557806355f804b3146102e85780636352211e146102fb57600080fd5b806340c10f191461028957806342842e0e1461029c5780634cd88b76146102af57600080fd5b8063095ea7b3116101ad578063095ea7b31461023c57806318160ddd1461025157806323b872dd146102635780632f745c591461027657600080fd5b806301ffc9a7146101d457806306fdde03146101fc578063081812fc14610211575b600080fd5b6101e76101e2366004611be5565b610487565b60405190151581526020015b60405180910390f35b6102046104d9565b6040516101f39190611c56565b61022461021f366004611c69565b61056b565b6040516001600160a01b0390911681526020016101f3565b61024f61024a366004611c9e565b610605565b005b609e545b6040519081526020016101f3565b61024f610271366004611cc8565b61071b565b610255610284366004611c9e565b61074c565b610255610297366004611c9e565b6107e2565b61024f6102aa366004611cc8565b610858565b61024f6102bd366004611dc3565b610873565b6101e76102d0366004611ea7565b6108ea565b6102556102e3366004611c69565b610957565b61024f6102f6366004611eeb565b6109ea565b610224610309366004611c69565b610a2b565b61025561031c366004611f20565b610aa2565b61024f610b29565b61024f610337366004611f20565b610b5f565b6033546001600160a01b0316610224565b610204610bbe565b61024f610363366004611f3b565b610bcd565b61024f610376366004611f77565b610c92565b61024f610389366004611fb4565b610d1b565b61024f61039c366004611fe9565b610d85565b6102556103af366004611f20565b610dbd565b6102046103c2366004611c69565b610e0f565b6104006103d5366004611c69565b60a0602052600090815260409020805460018201546002909201546001600160a01b03909116919083565b604080516001600160a01b0390941684526020840192909252908201526060016101f3565b610204610433366004611c69565b610efe565b6101e7610446366004612065565b6001600160a01b03918216600090815260a36020908152604080832093909416825291909152205460ff1690565b61024f610482366004611f20565b610f98565b60006001600160e01b031982166380ac58cd60e01b14806104b857506001600160e01b03198216635b5e139f60e01b145b806104d357506301ffc9a760e01b6001600160e01b03198316145b92915050565b6060609880546104e890612098565b80601f016020809104026020016040519081016040528092919081815260200182805461051490612098565b80156105615780601f1061053657610100808354040283529160200191610561565b820191906000526020600020905b81548152906001019060200180831161054457829003601f168201915b5050505050905090565b600081815260a060205260408120546001600160a01b03166105e95760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b50600090815260a260205260409020546001600160a01b031690565b600061061082610a2b565b9050806001600160a01b0316836001600160a01b0316141561067e5760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084016105e0565b336001600160a01b038216148061069a575061069a8133610446565b61070c5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c000000000000000060648201526084016105e0565b6107168383611033565b505050565b61072533826110a1565b6107415760405162461bcd60e51b81526004016105e0906120cd565b610716838383611198565b600061075783610aa2565b82106107b95760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b60648201526084016105e0565b506001600160a01b03919091166000908152609c60209081526040808320938352929052205490565b609b546000906001600160a01b0316331461080f5760405162461bcd60e51b81526004016105e09061211e565b61081d609780546001019055565b600061082860975490565b90506108348482611343565b600081815260a0602052604090206001810184905543600290910155905092915050565b61071683838360405180602001604052806000815250610d85565b600054610100900460ff168061088c575060005460ff16155b6108a85760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156108ca576000805461ffff19166101011790555b6108d4838361135d565b8015610716576000805461ff0019169055505050565b6000805b825181101561094d57836001600160a01b0316610923848381518110610916576109166121a3565b6020026020010151610a2b565b6001600160a01b03161461093b5760009150506104d3565b80610945816121cf565b9150506108ee565b5060019392505050565b6000610962609e5490565b82106109c55760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b60648201526084016105e0565b609e82815481106109d8576109d86121a3565b90600052602060002001549050919050565b6033546001600160a01b03163314610a145760405162461bcd60e51b81526004016105e0906121ea565b8051610a2790609a906020840190611b36565b5050565b600081815260a060205260408120546001600160a01b0316806104d35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b60648201526084016105e0565b60006001600160a01b038216610b0d5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b60648201526084016105e0565b506001600160a01b0316600090815260a1602052604090205490565b6033546001600160a01b03163314610b535760405162461bcd60e51b81526004016105e0906121ea565b610b5d60006113d6565b565b6033546001600160a01b03163314610b895760405162461bcd60e51b81526004016105e0906121ea565b6001600160a01b038116610b9c57600080fd5b609b80546001600160a01b0319166001600160a01b0392909216919091179055565b6060609980546104e890612098565b6001600160a01b038216331415610c265760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016105e0565b33600081815260a3602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b609b546001600160a01b03163314610cbc5760405162461bcd60e51b81526004016105e09061211e565b6000815111610cfc5760405162461bcd60e51b815260206004820152600c60248201526b75726920697320656d70747960a01b60448201526064016105e0565b600082815260a460209081526040909120825161071692840190611b36565b609b546001600160a01b03163314610d455760405162461bcd60e51b81526004016105e09061211e565b60005b8151811015610a2757610d73828281518110610d6657610d666121a3565b6020026020010151611428565b80610d7d816121cf565b915050610d48565b610d8f33836110a1565b610dab5760405162461bcd60e51b81526004016105e0906120cd565b610db7848484846114dc565b50505050565b6001600160a01b038116600090815260a16020526040812054819015610e09576001600160a01b039092166000908152609c602090815260408083209483529390529190912054919050565b50919050565b600081815260a060205260409020546060906001600160a01b0316610e8e5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b60648201526084016105e0565b6000609a8054610e9d90612098565b905011610eb957604051806020016040528060008152506104d3565b600082815260a06020908152604080832060010154835260a48252918290209151610ee992609a929091016122b9565b60405160208183030381529060405292915050565b60a46020526000908152604090208054610f1790612098565b80601f0160208091040260200160405190810160405280929190818152602001828054610f4390612098565b8015610f905780601f10610f6557610100808354040283529160200191610f90565b820191906000526020600020905b815481529060010190602001808311610f7357829003601f168201915b505050505081565b6033546001600160a01b03163314610fc25760405162461bcd60e51b81526004016105e0906121ea565b6001600160a01b0381166110275760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016105e0565b611030816113d6565b50565b600081815260a26020526040902080546001600160a01b0319166001600160a01b038416908117909155819061106882610a2b565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600081815260a060205260408120546001600160a01b031661111a5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084016105e0565b600061112583610a2b565b9050806001600160a01b0316846001600160a01b031614806111605750836001600160a01b03166111558461056b565b6001600160a01b0316145b8061119057506001600160a01b03808216600090815260a3602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b03166111ab82610a2b565b6001600160a01b0316146112135760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b60648201526084016105e0565b6001600160a01b0382166112755760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016105e0565b61128083838361150f565b61128b600082611033565b6001600160a01b038316600090815260a1602052604081208054600192906112b49084906122ce565b90915550506001600160a01b038216600090815260a1602052604081208054600192906112e29084906122e5565b9091555050600081815260a0602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b610a278282604051806020016040528060008152506115c7565b600054610100900460ff1680611376575060005460ff16155b6113925760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156113b4576000805461ffff19166101011790555b6113bc6115fa565b6113c4611665565b6113cc6115fa565b6108d483836116c5565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600061143382610a2b565b90506114418160008461150f565b61144c600083611033565b6001600160a01b038116600090815260a1602052604081208054600192906114759084906122ce565b9091555050600082815260a0602052604080822080546001600160a01b031916815560018101839055600201829055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6114e7848484611198565b6114f38484848461175a565b610db75760405162461bcd60e51b81526004016105e0906122fd565b6001600160a01b03831661156a5761156581609e80546000838152609f60205260408120829055600182018355919091527fcfe2a20ff701a1f3e14f63bd70d6c6bc6fba8172ec6d5a505cdab3927c0a9de60155565b61158d565b816001600160a01b0316836001600160a01b03161461158d5761158d8382611858565b6001600160a01b0382166115a457610716816118f5565b826001600160a01b0316826001600160a01b0316146107165761071682826119a4565b6115d183836119e8565b6115de600084848461175a565b6107165760405162461bcd60e51b81526004016105e0906122fd565b600054610100900460ff1680611613575060005460ff16155b61162f5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff16158015611651576000805461ffff19166101011790555b8015611030576000805461ff001916905550565b600054610100900460ff168061167e575060005460ff16155b61169a5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff161580156116bc576000805461ffff19166101011790555b611651336113d6565b600054610100900460ff16806116de575060005460ff16155b6116fa5760405162461bcd60e51b81526004016105e090612155565b600054610100900460ff1615801561171c576000805461ffff19166101011790555b825161172f906098906020860190611b36565b508151611743906099906020850190611b36565b508015610716576000805461ff0019169055505050565b60006001600160a01b0384163b1561184d57604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061179e90339089908890889060040161234f565b6020604051808303816000875af19250505080156117d9575060408051601f3d908101601f191682019092526117d69181019061238c565b60015b611833573d808015611807576040519150601f19603f3d011682016040523d82523d6000602084013e61180c565b606091505b50805161182b5760405162461bcd60e51b81526004016105e0906122fd565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611190565b506001949350505050565b6000600161186584610aa2565b61186f91906122ce565b6000838152609d60205260409020549091508082146118c2576001600160a01b0384166000908152609c602090815260408083208584528252808320548484528184208190558352609d90915290208190555b506000918252609d602090815260408084208490556001600160a01b039094168352609c81528383209183525290812055565b609e54600090611907906001906122ce565b6000838152609f6020526040812054609e805493945090928490811061192f5761192f6121a3565b9060005260206000200154905080609e8381548110611950576119506121a3565b6000918252602080832090910192909255828152609f9091526040808220849055858252812055609e805480611988576119886123a9565b6001900381819060005260206000200160009055905550505050565b60006119af83610aa2565b6001600160a01b039093166000908152609c602090815260408083208684528252808320859055938252609d9052919091209190915550565b6001600160a01b038216611a3e5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016105e0565b600081815260a060205260409020546001600160a01b031615611aa35760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016105e0565b611aaf6000838361150f565b6001600160a01b038216600090815260a160205260408120805460019290611ad89084906122e5565b9091555050600081815260a0602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b828054611b4290612098565b90600052602060002090601f016020900481019282611b645760008555611baa565b82601f10611b7d57805160ff1916838001178555611baa565b82800160010185558215611baa579182015b82811115611baa578251825591602001919060010190611b8f565b50611bb6929150611bba565b5090565b5b80821115611bb65760008155600101611bbb565b6001600160e01b03198116811461103057600080fd5b600060208284031215611bf757600080fd5b8135611c0281611bcf565b9392505050565b6000815180845260005b81811015611c2f57602081850181015186830182015201611c13565b81811115611c41576000602083870101525b50601f01601f19169290920160200192915050565b602081526000611c026020830184611c09565b600060208284031215611c7b57600080fd5b5035919050565b80356001600160a01b0381168114611c9957600080fd5b919050565b60008060408385031215611cb157600080fd5b611cba83611c82565b946020939093013593505050565b600080600060608486031215611cdd57600080fd5b611ce684611c82565b9250611cf460208501611c82565b9150604084013590509250925092565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715611d4357611d43611d04565b604052919050565b600067ffffffffffffffff831115611d6557611d65611d04565b611d78601f8401601f1916602001611d1a565b9050828152838383011115611d8c57600080fd5b828260208301376000602084830101529392505050565b600082601f830112611db457600080fd5b611c0283833560208501611d4b565b60008060408385031215611dd657600080fd5b823567ffffffffffffffff80821115611dee57600080fd5b611dfa86838701611da3565b93506020850135915080821115611e1057600080fd5b50611e1d85828601611da3565b9150509250929050565b600082601f830112611e3857600080fd5b8135602067ffffffffffffffff821115611e5457611e54611d04565b8160051b611e63828201611d1a565b9283528481018201928281019087851115611e7d57600080fd5b83870192505b84831015611e9c57823582529183019190830190611e83565b979650505050505050565b60008060408385031215611eba57600080fd5b611ec383611c82565b9150602083013567ffffffffffffffff811115611edf57600080fd5b611e1d85828601611e27565b600060208284031215611efd57600080fd5b813567ffffffffffffffff811115611f1457600080fd5b61119084828501611da3565b600060208284031215611f3257600080fd5b611c0282611c82565b60008060408385031215611f4e57600080fd5b611f5783611c82565b915060208301358015158114611f6c57600080fd5b809150509250929050565b60008060408385031215611f8a57600080fd5b82359150602083013567ffffffffffffffff811115611fa857600080fd5b611e1d85828601611da3565b600060208284031215611fc657600080fd5b813567ffffffffffffffff811115611fdd57600080fd5b61119084828501611e27565b60008060008060808587031215611fff57600080fd5b61200885611c82565b935061201660208601611c82565b925060408501359150606085013567ffffffffffffffff81111561203957600080fd5b8501601f8101871361204a57600080fd5b61205987823560208401611d4b565b91505092959194509250565b6000806040838503121561207857600080fd5b61208183611c82565b915061208f60208401611c82565b90509250929050565b600181811c908216806120ac57607f821691505b60208210811415610e0957634e487b7160e01b600052602260045260246000fd5b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252601d908201527f4552433732313a206e6f7420616c6c6f77656420746f20616363657373000000604082015260600190565b6020808252602e908201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160408201526d191e481a5b9a5d1a585b1a5e995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006000198214156121e3576121e36121b9565b5060010190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b8054600090600181811c908083168061223957607f831692505b602080841082141561225b57634e487b7160e01b600052602260045260246000fd5b81801561226f5760018114612280576122ad565b60ff198616895284890196506122ad565b60008881526020902060005b868110156122a55781548b82015290850190830161228c565b505084890196505b50505050505092915050565b60006111906122c8838661221f565b8461221f565b6000828210156122e0576122e06121b9565b500390565b600082198211156122f8576122f86121b9565b500190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061238290830184611c09565b9695505050505050565b60006020828403121561239e57600080fd5b8151611c0281611bcf565b634e487b7160e01b600052603160045260246000fdfea264697066735822122006a8aea773918e7694a8d954e76d094a0c147a153ef95811b6739500fc0e282764736f6c634300080a0033