ERC-721
Overview
Max Total Supply
556 Lava
Holders
179
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
3 LavaLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
NFTSalesWhitelist
Compiler Version
v0.8.17+commit.8df45f5f
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity 0.8.17; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "./ERC721Min.sol"; contract NFTSalesWhitelist is Ownable, ERC721Min, ReentrancyGuard { using Strings for uint256; using SafeERC20 for IERC20; mapping(address => bool) proxyToApproved; // proxy allowance for interaction with future contract address public treasuryAddress; bool public useBaseUriOnly; string private _contractURI; string private _tokenBaseURI = ""; // SET TO THE METADATA URI mapping(uint256 => string) public TokenURIMap; // allows for assigning individual/unique metada per token uint16 public maxPerAddress; uint16 public maxPerMint; uint16 maxPerAddressForThree; uint16 maxMint; uint16 public maxMintForOne; uint16 maxMintForThree; uint16 maxMintForFive; bool public saleActive; uint256 public price; uint256 priceForThree; uint256 public priceForFive; address public paymentToken; uint256 public priceWithToken; uint256 public priceForThreeWithToken; bool public disableSalesWithETH; bool public disableSalesWithToken = true; // whitelist mapping(address => bool) public Whitelist; mapping(address => uint256) public WhitelistMints; bool whitelistEnabled = true; uint256 public whitelistMax = 3; struct FeeRecipient { address recipient; uint256 basisPoints; } mapping(uint256 => FeeRecipient) public FeeRecipients; uint256 feeRecipientCount; uint256 totalFeeBasisPoints; bool public transferDisabled; constructor( string memory name_, string memory symbol_, address treasury_ ) ERC721Min(name_, symbol_) { treasuryAddress = treasury_; } function totalSupply() external view returns (uint256) { return _owners.length; } // ** - CORE - ** // function buyOne() external payable { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithETH, "NO_ETH_SALES"); require(price == msg.value, "INCORRECT_ETH"); require(maxMintForOne > _owners.length, "EXCEED_MAX_SALE_SUPPLY"); require( maxPerAddress == 0 || balanceOf(_msgSender()) < maxPerAddress, "EXCEED_MAX_PER_USER" ); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()]++; } _mintMin(); } function buyThree() external payable { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithETH, "NO_ETH_SALES"); require(priceForThree == msg.value, "INCORRECT_ETH"); require(maxMintForThree > _owners.length, "EXCEED_MAX_SALE_SUPPLY"); require( maxPerAddress == 0 || balanceOf(_msgSender()) < maxPerAddressForThree, "EXCEED_MAX_PER_USER" ); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] + 4 < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()] += 3; } _mintMin(); _mintMin(); _mintMin(); } // uses priceForFive, not a multplier of price * 5 function buyFiveAtSetPrice() external payable { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithETH, "NO_ETH_SALES"); require(priceForFive == msg.value, "INCORRECT_ETH"); require(maxMintForFive > _owners.length, "EXCEED_MAX_SALE_SUPPLY"); require( maxPerAddress == 0 || balanceOf(_msgSender()) < maxPerAddressForThree, "EXCEED_MAX_PER_USER" ); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] + 4 < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()] += 5; } _mintMin(); _mintMin(); _mintMin(); _mintMin(); _mintMin(); } function buy(uint8 amount) external payable { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithETH, "NO_ETH_SALES"); require(price * amount == msg.value, "INCORRECT_ETH"); require(maxMint > _owners.length + amount, "EXCEED_MAX_SALE_SUPPLY"); require(amount < maxPerMint, "EXCEED_MAX_PER_MINT"); require( maxPerAddress == 0 || balanceOf(_msgSender()) + amount - 1 < maxPerAddress, "EXCEED_MAX_PER_USER" ); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] + amount - 1 < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()] += amount; } for (uint256 i = 0; i < amount; i++) { _mintMin(); } } function buyOneWithToken() external { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithToken, "NO_TOKEN_SALES"); IERC20(paymentToken).transferFrom( msg.sender, address(this), priceWithToken ); require(maxMintForOne > _owners.length, "EXCEED_MAX_SALE_SUPPLY"); require( maxPerAddress == 0 || balanceOf(_msgSender()) < maxPerAddress, "EXCEED_MAX_PER_USER" ); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()]++; } _mintMin(); } function buyThreeWithToken() external { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithToken, "NO_TOKEN_SALES"); IERC20(paymentToken).transferFrom( msg.sender, address(this), priceForThreeWithToken ); require(maxMintForThree > _owners.length, "EXCEED_MAX_SALE_SUPPLY"); require( maxPerAddress == 0 || balanceOf(_msgSender()) < maxPerAddressForThree, "EXCEED_MAX_PER_USER" ); _mintMin(); _mintMin(); _mintMin(); if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] + 4 < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()] += 5; } } function buyWithToken(uint16 amount) external { require(saleActive, "SALE_CLOSED"); require(!disableSalesWithToken, "NO_TOKEN_SALES"); IERC20(paymentToken).transferFrom( msg.sender, address(this), priceWithToken * amount ); require(maxMint > _owners.length + amount, "EXCEED_MAX_SALE_SUPPLY"); require(amount < maxPerMint, "EXCEED_MAX_PER_MINT"); require( maxPerAddress == 0 || balanceOf(_msgSender()) + amount - 1 < maxPerAddress, "EXCEED_MAX_PER_USER" ); for (uint256 i = 0; i < amount; i++) { _mintMin(); } if (whitelistEnabled) { require(Whitelist[_msgSender()], "NOT_ON_WHITELIST"); require( WhitelistMints[_msgSender()] + amount - 1 < whitelistMax, "MAX_WL_MINTED" ); WhitelistMints[_msgSender()] += amount; } } // ** - PROXY - ** // function mintOne(address receiver) external onlyProxy { _mintMin2(receiver); } function mintThree(address receiver) external onlyProxy { _mintMin2(receiver); _mintMin2(receiver); _mintMin2(receiver); } function mint(address receiver, uint16 amount) external onlyProxy { for (uint256 i = 0; i < amount; i++) { _mintMin2(receiver); } } // ** - ADMIN - ** // function addFeeRecipient(address recipient, uint256 basisPoints) external onlyOwner { feeRecipientCount++; FeeRecipients[feeRecipientCount].recipient = recipient; FeeRecipients[feeRecipientCount].basisPoints = basisPoints; totalFeeBasisPoints += basisPoints; } function editFeeRecipient( uint256 id, address recipient, uint256 basisPoints ) external onlyOwner { require(id <= feeRecipientCount, "INVALID_ID"); totalFeeBasisPoints = totalFeeBasisPoints - FeeRecipients[id].basisPoints + basisPoints; FeeRecipients[id].recipient = recipient; FeeRecipients[id].basisPoints = basisPoints; } function distributeETH() public { require(feeRecipientCount > 0, "RECIPIENTS_NOT_SET"); uint256 bal = address(this).balance; for (uint256 x = 1; x <= feeRecipientCount; x++) { uint256 amount = (bal * FeeRecipients[x].basisPoints) / totalFeeBasisPoints; amount = amount > address(this).balance ? address(this).balance : amount; (bool sent, ) = FeeRecipients[x].recipient.call{value: amount}(""); require(sent, "FAILED_SENDING_FUNDS"); } emit DistributeETH(_msgSender(), bal); } function distributeTokens() public { require(feeRecipientCount > 0, "RECIPIENTS_NOT_SET"); uint256 bal = IERC20(paymentToken).balanceOf(address(this)); for (uint256 x = 1; x <= feeRecipientCount; x++) { uint256 amount = (bal * FeeRecipients[x].basisPoints) / totalFeeBasisPoints; amount = amount > address(this).balance ? address(this).balance : amount; IERC20(paymentToken).transfer(FeeRecipients[x].recipient, amount); } emit DistributeTokens(_msgSender(), bal); } function setPriceForFive(uint256 value) external onlyOwner { priceForFive = value; } function withdrawETH() public { require( _msgSender() == owner() || _msgSender() == treasuryAddress || proxyToApproved[_msgSender()], "NOT_ALLOWED" ); require(treasuryAddress != address(0), "TREASURY_NOT_SET"); uint256 bal = address(this).balance; (bool sent, ) = treasuryAddress.call{value: bal}(""); require(sent, "FAILED_SENDING_FUNDS"); emit WithdrawETH(_msgSender(), bal); } function withdrawTokens(address _token) external nonReentrant { require( _msgSender() == owner() || _msgSender() == treasuryAddress || proxyToApproved[_msgSender()], "NOT_ALLOWED" ); require(treasuryAddress != address(0), "TREASURY_NOT_SET"); IERC20(_token).safeTransfer( treasuryAddress, IERC20(_token).balanceOf(address(this)) ); } function gift(address[] calldata receivers, uint256[] memory amounts) external onlyOwner { for (uint256 x = 0; x < receivers.length; x++) { for (uint256 i = 0; i < amounts[x]; i++) { _mintMin2(receivers[x]); } } } function setDisableSalesWithETH(bool value) external onlyOwner { disableSalesWithETH = value; } function setDisableSalesWithToken(bool value) external onlyOwner { disableSalesWithToken = value; } function updateConfig( uint16 _maxMint, uint16 _maxPerMint, uint256 _price, uint16 _maxPerAddress, bool _saleActive, string calldata _uri, address _paymentToken, uint256 _priceWithToken ) external onlyOwner { maxMint = _maxMint + 1; maxMintForOne = _maxMint; maxMintForThree = _maxMint - 2; maxMintForFive = _maxMint - 4; maxPerMint = _maxPerMint + 1; price = _price; priceForThree = _price * 3; maxPerAddress = _maxPerAddress > 0 ? _maxPerAddress : 0; maxPerAddressForThree = _maxPerAddress > 1 ? _maxPerAddress - 2 : 0; saleActive = _saleActive; _tokenBaseURI = _uri; paymentToken = _paymentToken; priceWithToken = _priceWithToken; priceForThreeWithToken = _priceWithToken * 3; } function updateToken(address _paymentToken, uint256 _priceWithToken) external onlyOwner { paymentToken = _paymentToken; priceWithToken = _priceWithToken; priceForThreeWithToken = _priceWithToken * 3; } /**** WHITELIST ****/ function whitelistAdd(address[] calldata addresses) external onlyOwner { for (uint256 x; x < addresses.length; x++) { Whitelist[addresses[x]] = true; } emit WhitelistAdd(_msgSender(), addresses); } function whitelistRemove(address[] calldata addresses) external onlyOwner { for (uint256 x; x < addresses.length; x++) { Whitelist[addresses[x]] = false; } emit WhitelistRemove(_msgSender(), addresses); } function setWhitelistMax(uint256 value) external onlyOwner { require(value > 0, "AMOUNT=0"); whitelistMax = value; } function setWhitelistSaleActive() external onlyOwner { whitelistEnabled = true; saleActive = true; } function setPublicSaleActive() external onlyOwner { whitelistEnabled = false; saleActive = true; } function toggleSaleActive() external onlyOwner { saleActive = !saleActive; } function setMaxPerMint(uint16 _maxPerMint) external onlyOwner { maxPerMint = _maxPerMint; } function setMaxMint(uint16 maxMint_) external onlyOwner { maxMint = maxMint_ + 1; maxMintForOne = maxMint_; maxMintForThree = maxMint_ - 2; maxMintForFive = maxMint_ - 4; } function setMaxPerAddress(uint16 _maxPerAddress) external onlyOwner { maxPerAddress = _maxPerAddress > 0 ? _maxPerAddress : 0; maxPerAddressForThree = _maxPerAddress > 1 ? _maxPerAddress - 2 : maxPerAddress; } function setPrice(uint256 _price) external onlyOwner { price = _price; priceForThree = _price * 3; } function flipProxyState(address proxyAddress) public onlyOwner { proxyToApproved[proxyAddress] = !proxyToApproved[proxyAddress]; } function isProxyToApproved(address proxyAddress) external view onlyOwner returns (bool) { return proxyToApproved[proxyAddress]; } // ** - SETTERS - ** // function setVaultAddress(address addr) external onlyOwner { treasuryAddress = addr; } function setContractURI(string calldata URI) external onlyOwner { _contractURI = URI; } function setBaseURI(string calldata URI) external onlyOwner { _tokenBaseURI = URI; } // ** - MISC - ** // function contractURI() public view returns (string memory) { return _contractURI; } function toggleUseBaseUri() external onlyOwner { useBaseUriOnly = !useBaseUriOnly; } function tokenURI(uint256 tokenId) external view virtual override returns (string memory) { require( _exists(tokenId), "ERC721Metadata: URI query for nonexistent token" ); if (bytes(TokenURIMap[tokenId]).length > 0) return TokenURIMap[tokenId]; if (useBaseUriOnly) return _tokenBaseURI; return bytes(_tokenBaseURI).length > 0 ? string(abi.encodePacked(_tokenBaseURI, tokenId.toString())) : ""; } function setTokenUri(uint256 tokenId, string calldata _uri) external onlyOwner { TokenURIMap[tokenId] = _uri; } function isOwnerOf(address account, uint256[] calldata _tokenIds) external view returns (bool) { for (uint256 i; i < _tokenIds.length; ++i) { if (_owners[_tokenIds[i]] != account) return false; } return true; } function setTransferDisabled(bool _transferDisabled) external onlyOwner { transferDisabled = _transferDisabled; } function batchSafeTransferFrom( address _from, address _to, uint256[] memory _tokenIds, bytes memory data_ ) public override { require( !transferDisabled || _msgSender() == owner() || proxyToApproved[_msgSender()], "TRANSFER_DISABLED" ); super.batchSafeTransferFrom(_from, _to, _tokenIds, data_); } function batchTransferFrom( address _from, address _to, uint256[] memory _tokenIds ) public override { require( !transferDisabled || _msgSender() == owner() || proxyToApproved[_msgSender()], "TRANSFER_DISABLED" ); super.batchTransferFrom(_from, _to, _tokenIds); } function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public override { require( !transferDisabled || _msgSender() == owner() || proxyToApproved[_msgSender()], "TRANSFER_DISABLED" ); super.safeTransferFrom(from, to, tokenId, _data); } function transferFrom( address from, address to, uint256 tokenId ) public override { require( !transferDisabled || _msgSender() == owner() || proxyToApproved[_msgSender()], "TRANSFER_DISABLED" ); super.transferFrom(from, to, tokenId); } modifier onlyProxy() { require(proxyToApproved[_msgSender()] == true, "onlyProxy"); _; } event DistributeETH(address indexed sender, uint256 indexed balance); event DistributeTokens(address indexed sender, uint256 indexed balance); event WithdrawETH(address indexed sender, uint256 indexed balance); event WhitelistAdd(address indexed user, address[] indexed addresses); event WhitelistRemove(address indexed user, address[] indexed addresses); }
// SPDX-License-Identifier: MIT pragma solidity 0.8.17; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/utils/Context.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; abstract contract ERC721Min is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Array of token owners. Array index is token Id address[] internal _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) external view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require( owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } function getOwnerCount() external view returns (uint256) { return _owners.length; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {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); } function batchTransferFrom(address _from, address _to, uint256[] memory _tokenIds) public virtual { for (uint256 i; i < _tokenIds.length; i++) { transferFrom(_from, _to, _tokenIds[i]); } } function batchSafeTransferFrom(address _from, address _to, uint256[] memory _tokenIds, bytes memory data_) public virtual { for (uint256 i; i < _tokenIds.length; i++) { safeTransferFrom(_from, _to, _tokenIds[i], data_); } } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer(address from, address to, uint256 tokenId, bytes memory _data) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return tokenId < _owners.length && _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints and transfers tokenId to `to`. * * Requirements: * * - 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) internal virtual { _safeMint(to, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint(address to, bytes memory _data) internal virtual { _mintMin2(to); require(_checkOnERC721Received(address(0), to, _owners.length - 1, _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: * * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mintMin2(address to) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); _owners.push(to); _balances[to]++; emit Transfer(address(0), to, _owners.length - 1); } function _mintMin() internal virtual { _owners.push(_msgSender()); _balances[_msgSender()]++; emit Transfer(address(0), _msgSender(), _owners.length - 1); } /** * @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); _owners[tokenId] = address(0); _balances[owner]--; 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]--; _balances[to]++; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(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()) return true; try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } assembly { revert(add(32, reason), mload(reason)) } } } /** * @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 {} function tokenOfOwnerByIndex(address account, uint256 index) public view returns (uint256) { uint256 foundCount; for (uint256 i; i < _owners.length; ++i) { if (_owners[i] == account) { if (foundCount == index) return i; foundCount++; } } require(foundCount > 0, "NONE_FOUND"); revert("OUT_OF_INDEX"); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol) pragma solidity ^0.8.0; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; import "../extensions/draft-IERC20Permit.sol"; import "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove( IERC20 token, address spender, uint256 value ) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance( IERC20 token, address spender, uint256 value ) internal { uint256 newAllowance = token.allowance(address(this), spender) + value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance( IERC20 token, address spender, uint256 value ) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); uint256 newAllowance = oldAllowance - value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } function safePermit( IERC20Permit token, address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) internal { uint256 nonceBefore = token.nonces(owner); token.permit(owner, spender, value, deadline, v, r, s); uint256 nonceAfter = token.nonces(owner); require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed"); } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `from` to `to` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. */ interface IERC20Permit { /** * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, * given ``owner``'s signed approval. * * IMPORTANT: The same issues {IERC20-approve} has related to transaction * ordering also apply here. * * Emits an {Approval} event. * * Requirements: * * - `spender` cannot be the zero address. * - `deadline` must be a timestamp in the future. * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` * over the EIP712-formatted function arguments. * - the signature must use ``owner``'s current nonce (see {nonces}). * * For more information on the signature format, see the * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP * section]. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; /** * @dev Returns the current nonce for `owner`. This value must be * included whenever a signature is generated for {permit}. * * Every successful call to {permit} increases ``owner``'s nonce by one. This * prevents a signature from being used multiple times. */ function nonces(address owner) external view returns (uint256); /** * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"address","name":"treasury_","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"uint256","name":"balance","type":"uint256"}],"name":"DistributeETH","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"uint256","name":"balance","type":"uint256"}],"name":"DistributeTokens","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"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"WhitelistAdd","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"WhitelistRemove","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"uint256","name":"balance","type":"uint256"}],"name":"WithdrawETH","type":"event"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"FeeRecipients","outputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"basisPoints","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"TokenURIMap","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"Whitelist","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"WhitelistMints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"basisPoints","type":"uint256"}],"name":"addFeeRecipient","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"},{"internalType":"bytes","name":"data_","type":"bytes"}],"name":"batchSafeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"}],"name":"batchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint8","name":"amount","type":"uint8"}],"name":"buy","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"buyFiveAtSetPrice","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"buyOne","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"buyOneWithToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"buyThree","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"buyThreeWithToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"amount","type":"uint16"}],"name":"buyWithToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"disableSalesWithETH","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"disableSalesWithToken","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"distributeETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"distributeTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"basisPoints","type":"uint256"}],"name":"editFeeRecipient","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"proxyAddress","type":"address"}],"name":"flipProxyState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getOwnerCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"receivers","type":"address[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"gift","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"}],"name":"isOwnerOf","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"proxyAddress","type":"address"}],"name":"isProxyToApproved","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxMintForOne","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPerAddress","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPerMint","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint16","name":"amount","type":"uint16"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"mintOne","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"mintThree","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paymentToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"priceForFive","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"priceForThreeWithToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"priceWithToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"saleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","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":"URI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"URI","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"value","type":"bool"}],"name":"setDisableSalesWithETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"value","type":"bool"}],"name":"setDisableSalesWithToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"maxMint_","type":"uint16"}],"name":"setMaxMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"_maxPerAddress","type":"uint16"}],"name":"setMaxPerAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"_maxPerMint","type":"uint16"}],"name":"setMaxPerMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"setPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"setPriceForFive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setPublicSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"_uri","type":"string"}],"name":"setTokenUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_transferDisabled","type":"bool"}],"name":"setTransferDisabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"setVaultAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"setWhitelistMax","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setWhitelistSaleActive","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":"toggleSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleUseBaseUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":[],"name":"transferDisabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"treasuryAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"_maxMint","type":"uint16"},{"internalType":"uint16","name":"_maxPerMint","type":"uint16"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"uint16","name":"_maxPerAddress","type":"uint16"},{"internalType":"bool","name":"_saleActive","type":"bool"},{"internalType":"string","name":"_uri","type":"string"},{"internalType":"address","name":"_paymentToken","type":"address"},{"internalType":"uint256","name":"_priceWithToken","type":"uint256"}],"name":"updateConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_paymentToken","type":"address"},{"internalType":"uint256","name":"_priceWithToken","type":"uint256"}],"name":"updateToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"useBaseUriOnly","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"whitelistAdd","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"whitelistMax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"whitelistRemove","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60a060405260006080908152600b906200001a9082620001bc565b506014805461ff0019166101001790556017805460ff1916600117905560036018553480156200004957600080fd5b506040516200521a3803806200521a8339810160408190526200006c9162000337565b82826200007933620000c7565b6001620000878382620001bc565b506002620000968282620001bc565b5050600160075550600980546001600160a01b0319166001600160a01b039290921691909117905550620003c49050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200014257607f821691505b6020821081036200016357634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620001b757600081815260208120601f850160051c81016020861015620001925750805b601f850160051c820191505b81811015620001b3578281556001016200019e565b5050505b505050565b81516001600160401b03811115620001d857620001d862000117565b620001f081620001e984546200012d565b8462000169565b602080601f8311600181146200022857600084156200020f5750858301515b600019600386901b1c1916600185901b178555620001b3565b600085815260208120601f198616915b82811015620002595788860151825594840194600190910190840162000238565b5085821015620002785787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b600082601f8301126200029a57600080fd5b81516001600160401b0380821115620002b757620002b762000117565b604051601f8301601f19908116603f01168101908282118183101715620002e257620002e262000117565b81604052838152602092508683858801011115620002ff57600080fd5b600091505b8382101562000323578582018301518183018401529082019062000304565b600093810190920192909252949350505050565b6000806000606084860312156200034d57600080fd5b83516001600160401b03808211156200036557600080fd5b620003738783880162000288565b945060208601519150808211156200038a57600080fd5b50620003998682870162000288565b604086015190935090506001600160a01b0381168114620003b957600080fd5b809150509250925092565b614e4680620003d46000396000f3fe6080604052600436106104895760003560e01c8063746a102c11610255578063b88d4fde11610144578063e985e9c5116100c1578063f3993d1111610085578063f3993d1114610da0578063f3c3991914610dc0578063f3f47f1214610de0578063f73c814b14610e00578063f980dc4514610e20578063fa695a9714610e4057600080fd5b8063e985e9c514610cf2578063eb73900b14610d3b578063ee84e8af14610d6b578063ef18374a14610697578063f2fde38b14610d8057600080fd5b8063c5f956af11610108578063c5f956af14610c68578063c87b56dd14610c88578063e086e5ec14610ca8578063e2b16c0f14610cbd578063e8a3d48514610cdd57600080fd5b8063b88d4fde14610bdd578063b8b9b54914610bfd578063bc629bf514610c12578063bf60dc2114610c28578063c2962bc714610c4857600080fd5b80639bb9e9dc116101d2578063a309a67211610196578063a309a67214610b47578063ad0be4bd14610b67578063ad27c07114610b87578063b08b27a614610ba8578063b4fafcae14610bc857600080fd5b80639bb9e9dc14610ac95780639cf9494314610ae95780639d733f8514610b09578063a035b1fe14610b11578063a22cb46514610b2757600080fd5b80638da5cb5b116102195780638da5cb5b14610a4157806391b7f5ed14610a5f578063938e3d7b14610a7f57806395d89b4114610a9f5780639ab1b48414610ab457600080fd5b8063746a102c146109a45780637705f9b5146109ba5780637c80d7fb146109da57806385535cc514610a07578063892dfdf614610a2757600080fd5b80633013ce291161037c5780635a4fee30116102f95780636902ad69116102bd5780636902ad69146109105780636909dc12146109255780636ab81008146109455780636b5e28961461096757806370a082311461096f578063715018a61461098f57600080fd5b80635a4fee30146108755780635fbcf0d3146108955780636352211e146108b4578063639814e0146108d457806368428a1b146108ef57600080fd5b80634d44660c116103405780634d44660c146107c15780634fab9869146107e1578063507e094f1461080157806355f804b31461083557806357f7789e1461085557600080fd5b80633013ce29146107375780633100a535146107575780633e11ab3f1461076c57806342842e0e1461078157806349df728c146107a157600080fd5b806312cfa1161161040a57806323b872dd116103ce57806323b872dd146106ac578063292beb54146106cc5780632bce9e7b146106e15780632f745c59146107015780632fafb6d21461072157600080fd5b806312cfa1161461064257806314107f3c1461064a57806315124db41461065d57806317c5bff91461067d57806318160ddd1461069757600080fd5b8063081812fc11610451578063081812fc1461058a578063095ea7b3146105c25780630a736c24146105e25780630be9396e146106025780630c82b9421461062257600080fd5b806301ffc9a71461048e578063037f489c146104c357806305dfd2c0146104e757806306fdde0314610509578063075365761461052b575b600080fd5b34801561049a57600080fd5b506104ae6104a93660046140a4565b610e60565b60405190151581526020015b60405180910390f35b3480156104cf57600080fd5b506104d960125481565b6040519081526020016104ba565b3480156104f357600080fd5b506105076105023660046140d8565b610eb2565b005b34801561051557600080fd5b5061051e610f5e565b6040516104ba919061415d565b34801561053757600080fd5b5061056b610546366004614170565b601960205260009081526040902080546001909101546001600160a01b039091169082565b604080516001600160a01b0390931683526020830191909152016104ba565b34801561059657600080fd5b506105aa6105a5366004614170565b610ff0565b6040516001600160a01b0390911681526020016104ba565b3480156105ce57600080fd5b506105076105dd366004614189565b611078565b3480156105ee57600080fd5b506105076105fd366004614170565b61118d565b34801561060e57600080fd5b5061050761061d366004614170565b61119a565b34801561062e57600080fd5b5061050761063d3660046141fe565b6111e2565b6105076112b5565b61050761065836600461423f565b611449565b34801561066957600080fd5b506105076106783660046142c3565b611683565b34801561068957600080fd5b506014546104ae9060ff1681565b3480156106a357600080fd5b506003546104d9565b3480156106b857600080fd5b506105076106c736600461436e565b611828565b3480156106d857600080fd5b50610507611885565b3480156106ed57600080fd5b506105076106fc366004614189565b6118ae565b34801561070d57600080fd5b506104d961071c366004614189565b6118e8565b34801561072d57600080fd5b506104d960135481565b34801561074357600080fd5b506011546105aa906001600160a01b031681565b34801561076357600080fd5b506105076119d2565b34801561077857600080fd5b506105076119fb565b34801561078d57600080fd5b5061050761079c36600461436e565b611a22565b3480156107ad57600080fd5b506105076107bc36600461439a565b611a3d565b3480156107cd57600080fd5b506104ae6107dc3660046143b5565b611bec565b3480156107ed57600080fd5b506105076107fc366004614407565b611c6e565b34801561080d57600080fd5b50600d546108229062010000900461ffff1681565b60405161ffff90911681526020016104ba565b34801561084157600080fd5b50610507610850366004614424565b611c89565b34801561086157600080fd5b50610507610870366004614459565b611c9e565b34801561088157600080fd5b506105076108903660046145c0565b611cc5565b3480156108a157600080fd5b506014546104ae90610100900460ff1681565b3480156108c057600080fd5b506105aa6108cf366004614170565b611d23565b3480156108e057600080fd5b50600d546108229061ffff1681565b3480156108fb57600080fd5b50600d546104ae90600160701b900460ff1681565b34801561091c57600080fd5b50610507611daf565b34801561093157600080fd5b5061051e610940366004614170565b611dd9565b34801561095157600080fd5b50600d5461082290600160401b900461ffff1681565b610507611e73565b34801561097b57600080fd5b506104d961098a36600461439a565b611fdc565b34801561099b57600080fd5b50610507612063565b3480156109b057600080fd5b506104d960105481565b3480156109c657600080fd5b506105076109d5366004614644565b612075565b3480156109e657600080fd5b506104d96109f536600461439a565b60166020526000908152604090205481565b348015610a1357600080fd5b50610507610a2236600461439a565b612100565b348015610a3357600080fd5b50601c546104ae9060ff1681565b348015610a4d57600080fd5b506000546001600160a01b03166105aa565b348015610a6b57600080fd5b50610507610a7a366004614170565b61212a565b348015610a8b57600080fd5b50610507610a9a366004614424565b612148565b348015610aab57600080fd5b5061051e61215d565b348015610ac057600080fd5b5061050761216c565b348015610ad557600080fd5b50610507610ae43660046146ac565b612339565b348015610af557600080fd5b50610507610b043660046141fe565b6125f4565b6105076126c7565b348015610b1d57600080fd5b506104d9600e5481565b348015610b3357600080fd5b50610507610b423660046146c7565b612851565b348015610b5357600080fd5b50610507610b623660046146ac565b612915565b348015610b7357600080fd5b50610507610b823660046146fe565b61293d565b348015610b9357600080fd5b506009546104ae90600160a01b900460ff1681565b348015610bb457600080fd5b50610507610bc33660046146ac565b61299b565b348015610bd457600080fd5b50610507612a0a565b348015610be957600080fd5b50610507610bf8366004614731565b612b09565b348015610c0957600080fd5b50610507612b67565b348015610c1e57600080fd5b506104d960185481565b348015610c3457600080fd5b50610507610c43366004614189565b612ce8565b348015610c5457600080fd5b50610507610c633660046146ac565b612d59565b348015610c7457600080fd5b506009546105aa906001600160a01b031681565b348015610c9457600080fd5b5061051e610ca3366004614170565b612dfa565b348015610cb457600080fd5b50610507612fa3565b348015610cc957600080fd5b50610507610cd8366004614407565b61313d565b348015610ce957600080fd5b5061051e61315f565b348015610cfe57600080fd5b506104ae610d0d36600461478c565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b348015610d4757600080fd5b506104ae610d5636600461439a565b60156020526000908152604090205460ff1681565b348015610d7757600080fd5b5061050761316e565b348015610d8c57600080fd5b50610507610d9b36600461439a565b613365565b348015610dac57600080fd5b50610507610dbb3660046147b6565b6133db565b348015610dcc57600080fd5b50610507610ddb366004614407565b613438565b348015610dec57600080fd5b50610507610dfb36600461439a565b613453565b348015610e0c57600080fd5b50610507610e1b36600461439a565b6134a2565b348015610e2c57600080fd5b506104ae610e3b36600461439a565b6134d3565b348015610e4c57600080fd5b50610507610e5b36600461439a565b613500565b60006001600160e01b031982166380ac58cd60e01b1480610e9157506001600160e01b03198216635b5e139f60e01b145b80610eac57506301ffc9a760e01b6001600160e01b03198316145b92915050565b610eba613534565b601a54831115610efe5760405162461bcd60e51b815260206004820152600a6024820152691253959053125117d25160b21b60448201526064015b60405180910390fd5b600083815260196020526040902060010154601b548291610f1e9161481f565b610f289190614832565b601b5560009283526019602052604090922080546001600160a01b0319166001600160a01b039290921691909117815560010155565b606060018054610f6d90614845565b80601f0160208091040260200160405190810160405280929190818152602001828054610f9990614845565b8015610fe65780601f10610fbb57610100808354040283529160200191610fe6565b820191906000526020600020905b815481529060010190602001808311610fc957829003601f168201915b5050505050905090565b6000610ffb8261358e565b61105c5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610ef5565b506000908152600560205260409020546001600160a01b031690565b600061108382611d23565b9050806001600160a01b0316836001600160a01b0316036110f05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610ef5565b336001600160a01b038216148061110c575061110c8133610d0d565b61117e5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610ef5565b61118883836135d8565b505050565b611195613534565b601055565b6111a2613534565b600081116111dd5760405162461bcd60e51b81526020600482015260086024820152670414d4f554e543d360c41b6044820152606401610ef5565b601855565b6111ea613534565b60005b8181101561125c5760006015600085858581811061120d5761120d61487f565b9050602002016020810190611222919061439a565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790558061125481614895565b9150506111ed565b50818160405161126d9291906148ae565b604051809103902061127c3390565b6001600160a01b03167fd6ac91164e2cf7bb91d1929d1af0a25052d12a7033448af7c3866223f9e4d53060405160405180910390a35050565b600d54600160701b900460ff166112de5760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156113015760405162461bcd60e51b8152600401610ef590614913565b34600f54146113225760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160501b900461ffff16116113505760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff1615806113785750600d54640100000000900461ffff1661137633611fdc565b105b6113945760405162461bcd60e51b8152600401610ef590614990565b60175460ff161561142f573360009081526015602052604090205460ff166113ce5760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546113ec906004614832565b106114095760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805460039290611429908490614832565b90915550505b611437613646565b61143f613646565b611447613646565b565b600d54600160701b900460ff166114725760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156114955760405162461bcd60e51b8152600401610ef590614913565b348160ff16600e546114a79190614a0e565b146114c45760405162461bcd60e51b8152600401610ef590614939565b6003546114d59060ff831690614832565b600d54600160301b900461ffff16116115005760405162461bcd60e51b8152600401610ef590614960565b600d5462010000900461ffff1660ff8216106115545760405162461bcd60e51b8152602060048201526013602482015272115610d1515117d3505617d4115497d3525395606a1b6044820152606401610ef5565b600d5461ffff16158061158e5750600d5461ffff16600160ff831661157833611fdc565b6115829190614832565b61158c919061481f565b105b6115aa5760405162461bcd60e51b8152600401610ef590614990565b60175460ff1615611657573360009081526015602052604090205460ff166115e45760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546001906116089060ff851690614832565b611612919061481f565b1061162f5760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805460ff84169290611651908490614832565b90915550505b60005b8160ff1681101561167f5761166d613646565b8061167781614895565b91505061165a565b5050565b61168b613534565b611696896001614a25565b600d805469ffffffff0000000000001916600160301b61ffff9384160261ffff60401b191617600160401b928c16929092029190911790556116d960028a614a47565b600d805461ffff92909216600160501b0261ffff60501b1990921691909117905561170560048a614a47565b600d805461ffff92909216600160601b0261ffff60601b19909216919091179055611731886001614a25565b600d805461ffff92909216620100000263ffff000019909216919091179055600e879055611760876003614a0e565b600f5561ffff8616611773576000611775565b855b600d805461ffff191661ffff9283161790556001908716116117985760006117a3565b6117a3600287614a47565b600d80546eff0000000000000000ffff00000000191664010000000061ffff939093169290920260ff60701b191691909117600160701b87151502179055600b6117ee848683614ab0565b50601180546001600160a01b0319166001600160a01b038416179055601281905561181a816003614a0e565b601355505050505050505050565b601c5460ff16158061184457506000546001600160a01b031633145b8061185e57503360009081526008602052604090205460ff165b61187a5760405162461bcd60e51b8152600401610ef590614b6f565b6111888383836136e3565b61188d613534565b6009805460ff60a01b198116600160a01b9182900460ff1615909102179055565b6118b6613534565b601180546001600160a01b0319166001600160a01b03841617905560128190556118e1816003614a0e565b6013555050565b60008060005b60035481101561195d57846001600160a01b0316600382815481106119155761191561487f565b6000918252602090912001546001600160a01b03160361194d5783820361193f579150610eac9050565b8161194981614895565b9250505b61195681614895565b90506118ee565b506000811161199b5760405162461bcd60e51b815260206004820152600a6024820152691393d39157d193d5539160b21b6044820152606401610ef5565b60405162461bcd60e51b815260206004820152600c60248201526b09eaaa8be9e8cbe929c888ab60a31b6044820152606401610ef5565b6119da613534565b600d805460ff60701b198116600160701b9182900460ff1615909102179055565b611a03613534565b6017805460ff19169055600d805460ff60701b1916600160701b179055565b61118883838360405180602001604052806000815250612b09565b600260075403611a8f5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610ef5565b60026007556000546001600160a01b0316331480611ac057506009546001600160a01b0316336001600160a01b0316145b80611ada57503360009081526008602052604090205460ff165b611b145760405162461bcd60e51b815260206004820152600b60248201526a1393d517d0531313d5d15160aa1b6044820152606401610ef5565b6009546001600160a01b0316611b5f5760405162461bcd60e51b815260206004820152601060248201526f1514915054d5549657d393d517d4d15560821b6044820152606401610ef5565b6009546040516370a0823160e01b8152306004820152611be4916001600160a01b0390811691908416906370a0823190602401602060405180830381865afa158015611baf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bd39190614b9a565b6001600160a01b0384169190613714565b506001600755565b6000805b82811015611c6157846001600160a01b03166003858584818110611c1657611c1661487f565b9050602002013581548110611c2d57611c2d61487f565b6000918252602090912001546001600160a01b031614611c51576000915050611c67565b611c5a81614895565b9050611bf0565b50600190505b9392505050565b611c76613534565b6014805460ff1916911515919091179055565b611c91613534565b600b611188828483614ab0565b611ca6613534565b6000838152600c60205260409020611cbf828483614ab0565b50505050565b601c5460ff161580611ce157506000546001600160a01b031633145b80611cfb57503360009081526008602052604090205460ff165b611d175760405162461bcd60e51b8152600401610ef590614b6f565b611cbf84848484613766565b60008060038381548110611d3957611d3961487f565b6000918252602090912001546001600160a01b0316905080610eac5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610ef5565b611db7613534565b6017805460ff19166001179055600d805460ff60701b1916600160701b179055565b600c6020526000908152604090208054611df290614845565b80601f0160208091040260200160405190810160405280929190818152602001828054611e1e90614845565b8015611e6b5780601f10611e4057610100808354040283529160200191611e6b565b820191906000526020600020905b815481529060010190602001808311611e4e57829003601f168201915b505050505081565b600d54600160701b900460ff16611e9c5760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff1615611ebf5760405162461bcd60e51b8152600401610ef590614913565b34600e5414611ee05760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160401b900461ffff1611611f0e5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff161580611f2e5750600d5461ffff16611f2c33611fdc565b105b611f4a5760405162461bcd60e51b8152600401610ef590614990565b60175460ff161561143f573360009081526015602052604090205460ff16611f845760405162461bcd60e51b8152600401610ef5906149bd565b6018543360009081526016602052604090205410611fb45760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805491611fcf83614895565b9190505550611447613646565b60006001600160a01b0382166120475760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610ef5565b506001600160a01b031660009081526004602052604090205490565b61206b613534565b61144760006137b0565b61207d613534565b60005b82811015611cbf5760005b82828151811061209d5761209d61487f565b60200260200101518110156120ed576120db8585848181106120c1576120c161487f565b90506020020160208101906120d6919061439a565b613800565b806120e581614895565b91505061208b565b50806120f881614895565b915050612080565b612108613534565b600980546001600160a01b0319166001600160a01b0392909216919091179055565b612132613534565b600e819055612142816003614a0e565b600f5550565b612150613534565b600a611188828483614ab0565b606060028054610f6d90614845565b6000601a54116121b35760405162461bcd60e51b8152602060048201526012602482015271149150d2541251539514d7d393d517d4d15560721b6044820152606401610ef5565b6011546040516370a0823160e01b81523060048201526000916001600160a01b0316906370a0823190602401602060405180830381865afa1580156121fc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122209190614b9a565b905060015b601a54811161230857601b546000828152601960205260408120600101549091906122509085614a0e565b61225a9190614bc9565b9050478111612269578061226b565b475b6011546000848152601960205260409081902054905163a9059cbb60e01b81526001600160a01b03918216600482015260248101849052929350169063a9059cbb906044016020604051808303816000875af11580156122cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122f39190614bdd565b5050808061230090614895565b915050612225565b50604051819033907f66902764973bf4d35892cf2fde75fcd39ea2cc28a2d6f61e51e45493ee10afe190600090a350565b600d54600160701b900460ff166123625760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff161561238a5760405162461bcd60e51b8152600401610ef590614bfa565b6011546012546001600160a01b03909116906323b872dd90339030906123b59061ffff871690614a0e565b6040516001600160e01b031960e086901b1681526001600160a01b03938416600482015292909116602483015260448201526064016020604051808303816000875af1158015612409573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061242d9190614bdd565b506003546124409061ffff831690614832565b600d54600160301b900461ffff161161246b5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff620100009091048116908216106124c05760405162461bcd60e51b8152602060048201526013602482015272115610d1515117d3505617d4115497d3525395606a1b6044820152606401610ef5565b600d5461ffff1615806124fc5750600d5461ffff9081169060019083166124e633611fdc565b6124f09190614832565b6124fa919061481f565b105b6125185760405162461bcd60e51b8152600401610ef590614990565b60005b8161ffff168110156125415761252f613646565b8061253981614895565b91505061251b565b5060175460ff16156125f1573360009081526015602052604090205460ff1661257c5760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546001906125a19061ffff851690614832565b6125ab919061481f565b106125c85760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805461ffff841692906125eb908490614832565b90915550505b50565b6125fc613534565b60005b8181101561266e5760016015600085858581811061261f5761261f61487f565b9050602002016020810190612634919061439a565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790558061266681614895565b9150506125ff565b50818160405161267f9291906148ae565b604051809103902061268e3390565b6001600160a01b03167fcd843f7737d79a305493e6db876a1be0a17a416451f2a700901efbe0b8be5fab60405160405180910390a35050565b600d54600160701b900460ff166126f05760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156127135760405162461bcd60e51b8152600401610ef590614913565b34601054146127345760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160601b900461ffff16116127625760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff16158061278a5750600d54640100000000900461ffff1661278833611fdc565b105b6127a65760405162461bcd60e51b8152600401610ef590614990565b60175460ff1615612841573360009081526015602052604090205460ff166127e05760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546127fe906004614832565b1061281b5760405162461bcd60e51b8152600401610ef5906149e7565b33600090815260166020526040812080546005929061283b908490614832565b90915550505b612849613646565b61142f613646565b336001600160a01b038316036128a95760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610ef5565b3360008181526006602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61291d613534565b600d805461ffff909216620100000263ffff000019909216919091179055565b3360009081526008602052604090205460ff1615156001146129715760405162461bcd60e51b8152600401610ef590614c22565b60005b8161ffff168110156111885761298983613800565b8061299381614895565b915050612974565b6129a3613534565b60008161ffff16116129b65760006129b8565b805b600d805461ffff191661ffff9283161790556001908216116129e057600d5461ffff166129eb565b6129eb600282614a47565b600d60046101000a81548161ffff021916908361ffff16021790555050565b600d54600160701b900460ff16612a335760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff1615612a5b5760405162461bcd60e51b8152600401610ef590614bfa565b6011546012546040516323b872dd60e01b815233600482015230602482015260448101919091526001600160a01b03909116906323b872dd906064016020604051808303816000875af1158015612ab6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ada9190614bdd565b50600354600d54600160401b900461ffff1611611f0e5760405162461bcd60e51b8152600401610ef590614960565b601c5460ff161580612b2557506000546001600160a01b031633145b80612b3f57503360009081526008602052604090205460ff165b612b5b5760405162461bcd60e51b8152600401610ef590614b6f565b611cbf84848484613906565b6000601a5411612bae5760405162461bcd60e51b8152602060048201526012602482015271149150d2541251539514d7d393d517d4d15560721b6044820152606401610ef5565b4760015b601a548111612cb757601b54600082815260196020526040812060010154909190612bdd9085614a0e565b612be79190614bc9565b9050478111612bf65780612bf8565b475b60008381526019602052604080822054905192935090916001600160a01b039091169083908381818185875af1925050503d8060008114612c55576040519150601f19603f3d011682016040523d82523d6000602084013e612c5a565b606091505b5050905080612ca25760405162461bcd60e51b81526020600482015260146024820152734641494c45445f53454e44494e475f46554e445360601b6044820152606401610ef5565b50508080612caf90614895565b915050612bb2565b50604051819033907f0d20f677b24c0f42423a7e690ab1d066e4ae75145c497a68b1f34bd34944d12290600090a350565b612cf0613534565b601a8054906000612d0083614895565b9091555050601a805460009081526019602052604080822080546001600160a01b0319166001600160a01b03871617905591548152908120600101829055601b8054839290612d50908490614832565b90915550505050565b612d61613534565b612d6c816001614a25565b600d805469ffffffff0000000000001916600160301b61ffff9384160261ffff60401b191617600160401b92841692909202919091179055612daf600282614a47565b600d805461ffff92909216600160501b0261ffff60501b19909216919091179055612ddb600482614a47565b600d600c6101000a81548161ffff021916908361ffff16021790555050565b6060612e058261358e565b612e695760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610ef5565b6000828152600c602052604081208054612e8290614845565b90501115612f28576000828152600c602052604090208054612ea390614845565b80601f0160208091040260200160405190810160405280929190818152602001828054612ecf90614845565b8015612f1c5780601f10612ef157610100808354040283529160200191612f1c565b820191906000526020600020905b815481529060010190602001808311612eff57829003601f168201915b50505050509050919050565b600954600160a01b900460ff1615612f4757600b8054612ea390614845565b6000600b8054612f5690614845565b905011612f725760405180602001604052806000815250610eac565b600b612f7d83613938565b604051602001612f8e929190614c45565b60405160208183030381529060405292915050565b6000546001600160a01b0316331480612fcf57506009546001600160a01b0316336001600160a01b0316145b80612fe957503360009081526008602052604090205460ff165b6130235760405162461bcd60e51b815260206004820152600b60248201526a1393d517d0531313d5d15160aa1b6044820152606401610ef5565b6009546001600160a01b031661306e5760405162461bcd60e51b815260206004820152601060248201526f1514915054d5549657d393d517d4d15560821b6044820152606401610ef5565b60095460405147916000916001600160a01b039091169083908381818185875af1925050503d80600081146130bf576040519150601f19603f3d011682016040523d82523d6000602084013e6130c4565b606091505b505090508061310c5760405162461bcd60e51b81526020600482015260146024820152734641494c45445f53454e44494e475f46554e445360601b6044820152606401610ef5565b604051829033907f566e45b1c8057e725bf62796a7f1d37ae294393cab069725a09daddd1af98b7990600090a35050565b613145613534565b601480549115156101000261ff0019909216919091179055565b6060600a8054610f6d90614845565b600d54600160701b900460ff166131975760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff16156131bf5760405162461bcd60e51b8152600401610ef590614bfa565b6011546013546040516323b872dd60e01b815233600482015230602482015260448101919091526001600160a01b03909116906323b872dd906064016020604051808303816000875af115801561321a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061323e9190614bdd565b50600354600d54600160501b900461ffff161161326d5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff1615806132955750600d54640100000000900461ffff1661329333611fdc565b105b6132b15760405162461bcd60e51b8152600401610ef590614990565b6132b9613646565b6132c1613646565b6132c9613646565b60175460ff1615611447573360009081526015602052604090205460ff166133035760405162461bcd60e51b8152600401610ef5906149bd565b60185433600090815260166020526040902054613321906004614832565b1061333e5760405162461bcd60e51b8152600401610ef5906149e7565b33600090815260166020526040812080546005929061335e908490614832565b9091555050565b61336d613534565b6001600160a01b0381166133d25760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ef5565b6125f1816137b0565b601c5460ff1615806133f757506000546001600160a01b031633145b8061341157503360009081526008602052604090205460ff165b61342d5760405162461bcd60e51b8152600401610ef590614b6f565b611188838383613a40565b613440613534565b601c805460ff1916911515919091179055565b3360009081526008602052604090205460ff1615156001146134875760405162461bcd60e51b8152600401610ef590614c22565b61349081613800565b61349981613800565b6125f181613800565b6134aa613534565b6001600160a01b03166000908152600860205260409020805460ff19811660ff90911615179055565b60006134dd613534565b506001600160a01b03811660009081526008602052604090205460ff165b919050565b3360009081526008602052604090205460ff1615156001146134995760405162461bcd60e51b8152600401610ef590614c22565b6000546001600160a01b031633146114475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ef5565b60035460009082108015610eac575060006001600160a01b0316600383815481106135bb576135bb61487f565b6000918252602090912001546001600160a01b0316141592915050565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061360d82611d23565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60038054600181019091557fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b0180546001600160a01b0319163390811790915560009081526004602052604081208054916136a083614895565b90915550506003546136b49060019061481f565b60405133906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4565b6136ed3382613a82565b6137095760405162461bcd60e51b8152600401610ef590614ccc565b611188838383613b68565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052611188908490613d10565b60005b82518110156137a95761379785858584815181106137895761378961487f565b602002602001015185612b09565b806137a181614895565b915050613769565b5050505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b0381166138565760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610ef5565b60038054600181019091557fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b0180546001600160a01b0319166001600160a01b03831690811790915560009081526004602052604081208054916138b983614895565b90915550506003546138cd9060019061481f565b6040516001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a450565b6139103383613a82565b61392c5760405162461bcd60e51b8152600401610ef590614ccc565b611cbf84848484613de2565b60608160000361395f5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613989578061397381614895565b91506139829050600a83614bc9565b9150613963565b6000816001600160401b038111156139a3576139a3614497565b6040519080825280601f01601f1916602001820160405280156139cd576020820181803683370190505b5090505b8415613a38576139e260018361481f565b91506139ef600a86614d1d565b6139fa906030614832565b60f81b818381518110613a0f57613a0f61487f565b60200101906001600160f81b031916908160001a905350613a31600a86614bc9565b94506139d1565b949350505050565b60005b8151811015611cbf57613a708484848481518110613a6357613a6361487f565b6020026020010151611828565b80613a7a81614895565b915050613a43565b6000613a8d8261358e565b613aee5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610ef5565b6000613af983611d23565b9050806001600160a01b0316846001600160a01b03161480613b345750836001600160a01b0316613b2984610ff0565b6001600160a01b0316145b80613a3857506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff16613a38565b826001600160a01b0316613b7b82611d23565b6001600160a01b031614613be35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610ef5565b6001600160a01b038216613c455760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610ef5565b613c506000826135d8565b6001600160a01b0383166000908152600460205260408120805491613c7483614d31565b90915550506001600160a01b0382166000908152600460205260408120805491613c9d83614895565b91905055508160038281548110613cb657613cb661487f565b6000918252602082200180546001600160a01b0319166001600160a01b03938416179055604051839285811692908716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a4505050565b6000613d65826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316613e159092919063ffffffff16565b8051909150156111885780806020019051810190613d839190614bdd565b6111885760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610ef5565b613ded848484613b68565b613df984848484613e24565b611cbf5760405162461bcd60e51b8152600401610ef590614d48565b6060613a388484600085613f24565b60006001600160a01b0384163b613e3d57506001613a38565b604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613e6f903390899088908890600401614d9a565b6020604051808303816000875af1925050508015613eaa575060408051601f3d908101601f19168201909252613ea791810190614dd7565b60015b613f07573d808015613ed8576040519150601f19603f3d011682016040523d82523d6000602084013e613edd565b606091505b508051600003613eff5760405162461bcd60e51b8152600401610ef590614d48565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b606082471015613f855760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610ef5565b6001600160a01b0385163b613fdc5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610ef5565b600080866001600160a01b03168587604051613ff89190614df4565b60006040518083038185875af1925050503d8060008114614035576040519150601f19603f3d011682016040523d82523d6000602084013e61403a565b606091505b509150915061404a828286614055565b979650505050505050565b60608315614064575081611c67565b8251156140745782518084602001fd5b8160405162461bcd60e51b8152600401610ef5919061415d565b6001600160e01b0319811681146125f157600080fd5b6000602082840312156140b657600080fd5b8135611c678161408e565b80356001600160a01b03811681146134fb57600080fd5b6000806000606084860312156140ed57600080fd5b833592506140fd602085016140c1565b9150604084013590509250925092565b60005b83811015614128578181015183820152602001614110565b50506000910152565b6000815180845261414981602086016020860161410d565b601f01601f19169290920160200192915050565b602081526000611c676020830184614131565b60006020828403121561418257600080fd5b5035919050565b6000806040838503121561419c57600080fd5b6141a5836140c1565b946020939093013593505050565b60008083601f8401126141c557600080fd5b5081356001600160401b038111156141dc57600080fd5b6020830191508360208260051b85010111156141f757600080fd5b9250929050565b6000806020838503121561421157600080fd5b82356001600160401b0381111561422757600080fd5b614233858286016141b3565b90969095509350505050565b60006020828403121561425157600080fd5b813560ff81168114611c6757600080fd5b803561ffff811681146134fb57600080fd5b80151581146125f157600080fd5b60008083601f84011261429457600080fd5b5081356001600160401b038111156142ab57600080fd5b6020830191508360208285010111156141f757600080fd5b60008060008060008060008060006101008a8c0312156142e257600080fd5b6142eb8a614262565b98506142f960208b01614262565b975060408a0135965061430e60608b01614262565b955060808a013561431e81614274565b945060a08a01356001600160401b0381111561433957600080fd5b6143458c828d01614282565b9095509350614358905060c08b016140c1565b915060e08a013590509295985092959850929598565b60008060006060848603121561438357600080fd5b61438c846140c1565b92506140fd602085016140c1565b6000602082840312156143ac57600080fd5b611c67826140c1565b6000806000604084860312156143ca57600080fd5b6143d3846140c1565b925060208401356001600160401b038111156143ee57600080fd5b6143fa868287016141b3565b9497909650939450505050565b60006020828403121561441957600080fd5b8135611c6781614274565b6000806020838503121561443757600080fd5b82356001600160401b0381111561444d57600080fd5b61423385828601614282565b60008060006040848603121561446e57600080fd5b8335925060208401356001600160401b0381111561448b57600080fd5b6143fa86828701614282565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156144d5576144d5614497565b604052919050565b600082601f8301126144ee57600080fd5b813560206001600160401b0382111561450957614509614497565b8160051b6145188282016144ad565b928352848101820192828101908785111561453257600080fd5b83870192505b8483101561404a57823582529183019190830190614538565b600082601f83011261456257600080fd5b81356001600160401b0381111561457b5761457b614497565b61458e601f8201601f19166020016144ad565b8181528460208386010111156145a357600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080608085870312156145d657600080fd5b6145df856140c1565b93506145ed602086016140c1565b925060408501356001600160401b038082111561460957600080fd5b614615888389016144dd565b9350606087013591508082111561462b57600080fd5b5061463887828801614551565b91505092959194509250565b60008060006040848603121561465957600080fd5b83356001600160401b038082111561467057600080fd5b61467c878388016141b3565b9095509350602086013591508082111561469557600080fd5b506146a2868287016144dd565b9150509250925092565b6000602082840312156146be57600080fd5b611c6782614262565b600080604083850312156146da57600080fd5b6146e3836140c1565b915060208301356146f381614274565b809150509250929050565b6000806040838503121561471157600080fd5b61471a836140c1565b915061472860208401614262565b90509250929050565b6000806000806080858703121561474757600080fd5b614750856140c1565b935061475e602086016140c1565b92506040850135915060608501356001600160401b0381111561478057600080fd5b61463887828801614551565b6000806040838503121561479f57600080fd5b6147a8836140c1565b9150614728602084016140c1565b6000806000606084860312156147cb57600080fd5b6147d4846140c1565b92506147e2602085016140c1565b915060408401356001600160401b038111156147fd57600080fd5b6146a2868287016144dd565b634e487b7160e01b600052601160045260246000fd5b81810381811115610eac57610eac614809565b80820180821115610eac57610eac614809565b600181811c9082168061485957607f821691505b60208210810361487957634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052603260045260246000fd5b6000600182016148a7576148a7614809565b5060010190565b60008184825b858110156148e3576001600160a01b036148cd836140c1565b16835260209283019291909101906001016148b4565b509095945050505050565b6020808252600b908201526a14d0531157d0d313d4d15160aa1b604082015260600190565b6020808252600c908201526b4e4f5f4554485f53414c455360a01b604082015260600190565b6020808252600d908201526c0929c869ea4a48a86a8be8aa89609b1b604082015260600190565b6020808252601690820152754558434545445f4d41585f53414c455f535550504c5960501b604082015260600190565b60208082526013908201527222ac21a2a2a22fa6a0ac2fa822a92faaa9a2a960691b604082015260600190565b60208082526010908201526f1393d517d3d397d5d2125511531254d560821b604082015260600190565b6020808252600d908201526c13505617d5d317d35253951151609a1b604082015260600190565b8082028115828204841417610eac57610eac614809565b61ffff818116838216019080821115614a4057614a40614809565b5092915050565b61ffff828116828216039080821115614a4057614a40614809565b601f82111561118857600081815260208120601f850160051c81016020861015614a895750805b601f850160051c820191505b81811015614aa857828155600101614a95565b505050505050565b6001600160401b03831115614ac757614ac7614497565b614adb83614ad58354614845565b83614a62565b6000601f841160018114614b0f5760008515614af75750838201355b600019600387901b1c1916600186901b1783556137a9565b600083815260209020601f19861690835b82811015614b405786850135825560209485019460019092019101614b20565b5086821015614b5d5760001960f88860031b161c19848701351681555b505060018560011b0183555050505050565b6020808252601190820152701514905394d1915497d11254d050931151607a1b604082015260600190565b600060208284031215614bac57600080fd5b5051919050565b634e487b7160e01b600052601260045260246000fd5b600082614bd857614bd8614bb3565b500490565b600060208284031215614bef57600080fd5b8151611c6781614274565b6020808252600e908201526d4e4f5f544f4b454e5f53414c455360901b604082015260600190565b6020808252600990820152686f6e6c7950726f787960b81b604082015260600190565b6000808454614c5381614845565b60018281168015614c6b5760018114614c8057614caf565b60ff1984168752821515830287019450614caf565b8860005260208060002060005b85811015614ca65781548a820152908401908201614c8d565b50505082870194505b505050508351614cc381836020880161410d565b01949350505050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600082614d2c57614d2c614bb3565b500690565b600081614d4057614d40614809565b506000190190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090614dcd90830184614131565b9695505050505050565b600060208284031215614de957600080fd5b8151611c678161408e565b60008251614e0681846020870161410d565b919091019291505056fea2646970667358221220fa9aed0ab05e12e1bf309439e242ea17e2d801d7984444d7e557e054a7969be664736f6c63430008110033000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000001f3eac5ba1247db5b31d6f6478eb234eaa75e14a000000000000000000000000000000000000000000000000000000000000000a4c6176612048656164730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044c61766100000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106104895760003560e01c8063746a102c11610255578063b88d4fde11610144578063e985e9c5116100c1578063f3993d1111610085578063f3993d1114610da0578063f3c3991914610dc0578063f3f47f1214610de0578063f73c814b14610e00578063f980dc4514610e20578063fa695a9714610e4057600080fd5b8063e985e9c514610cf2578063eb73900b14610d3b578063ee84e8af14610d6b578063ef18374a14610697578063f2fde38b14610d8057600080fd5b8063c5f956af11610108578063c5f956af14610c68578063c87b56dd14610c88578063e086e5ec14610ca8578063e2b16c0f14610cbd578063e8a3d48514610cdd57600080fd5b8063b88d4fde14610bdd578063b8b9b54914610bfd578063bc629bf514610c12578063bf60dc2114610c28578063c2962bc714610c4857600080fd5b80639bb9e9dc116101d2578063a309a67211610196578063a309a67214610b47578063ad0be4bd14610b67578063ad27c07114610b87578063b08b27a614610ba8578063b4fafcae14610bc857600080fd5b80639bb9e9dc14610ac95780639cf9494314610ae95780639d733f8514610b09578063a035b1fe14610b11578063a22cb46514610b2757600080fd5b80638da5cb5b116102195780638da5cb5b14610a4157806391b7f5ed14610a5f578063938e3d7b14610a7f57806395d89b4114610a9f5780639ab1b48414610ab457600080fd5b8063746a102c146109a45780637705f9b5146109ba5780637c80d7fb146109da57806385535cc514610a07578063892dfdf614610a2757600080fd5b80633013ce291161037c5780635a4fee30116102f95780636902ad69116102bd5780636902ad69146109105780636909dc12146109255780636ab81008146109455780636b5e28961461096757806370a082311461096f578063715018a61461098f57600080fd5b80635a4fee30146108755780635fbcf0d3146108955780636352211e146108b4578063639814e0146108d457806368428a1b146108ef57600080fd5b80634d44660c116103405780634d44660c146107c15780634fab9869146107e1578063507e094f1461080157806355f804b31461083557806357f7789e1461085557600080fd5b80633013ce29146107375780633100a535146107575780633e11ab3f1461076c57806342842e0e1461078157806349df728c146107a157600080fd5b806312cfa1161161040a57806323b872dd116103ce57806323b872dd146106ac578063292beb54146106cc5780632bce9e7b146106e15780632f745c59146107015780632fafb6d21461072157600080fd5b806312cfa1161461064257806314107f3c1461064a57806315124db41461065d57806317c5bff91461067d57806318160ddd1461069757600080fd5b8063081812fc11610451578063081812fc1461058a578063095ea7b3146105c25780630a736c24146105e25780630be9396e146106025780630c82b9421461062257600080fd5b806301ffc9a71461048e578063037f489c146104c357806305dfd2c0146104e757806306fdde0314610509578063075365761461052b575b600080fd5b34801561049a57600080fd5b506104ae6104a93660046140a4565b610e60565b60405190151581526020015b60405180910390f35b3480156104cf57600080fd5b506104d960125481565b6040519081526020016104ba565b3480156104f357600080fd5b506105076105023660046140d8565b610eb2565b005b34801561051557600080fd5b5061051e610f5e565b6040516104ba919061415d565b34801561053757600080fd5b5061056b610546366004614170565b601960205260009081526040902080546001909101546001600160a01b039091169082565b604080516001600160a01b0390931683526020830191909152016104ba565b34801561059657600080fd5b506105aa6105a5366004614170565b610ff0565b6040516001600160a01b0390911681526020016104ba565b3480156105ce57600080fd5b506105076105dd366004614189565b611078565b3480156105ee57600080fd5b506105076105fd366004614170565b61118d565b34801561060e57600080fd5b5061050761061d366004614170565b61119a565b34801561062e57600080fd5b5061050761063d3660046141fe565b6111e2565b6105076112b5565b61050761065836600461423f565b611449565b34801561066957600080fd5b506105076106783660046142c3565b611683565b34801561068957600080fd5b506014546104ae9060ff1681565b3480156106a357600080fd5b506003546104d9565b3480156106b857600080fd5b506105076106c736600461436e565b611828565b3480156106d857600080fd5b50610507611885565b3480156106ed57600080fd5b506105076106fc366004614189565b6118ae565b34801561070d57600080fd5b506104d961071c366004614189565b6118e8565b34801561072d57600080fd5b506104d960135481565b34801561074357600080fd5b506011546105aa906001600160a01b031681565b34801561076357600080fd5b506105076119d2565b34801561077857600080fd5b506105076119fb565b34801561078d57600080fd5b5061050761079c36600461436e565b611a22565b3480156107ad57600080fd5b506105076107bc36600461439a565b611a3d565b3480156107cd57600080fd5b506104ae6107dc3660046143b5565b611bec565b3480156107ed57600080fd5b506105076107fc366004614407565b611c6e565b34801561080d57600080fd5b50600d546108229062010000900461ffff1681565b60405161ffff90911681526020016104ba565b34801561084157600080fd5b50610507610850366004614424565b611c89565b34801561086157600080fd5b50610507610870366004614459565b611c9e565b34801561088157600080fd5b506105076108903660046145c0565b611cc5565b3480156108a157600080fd5b506014546104ae90610100900460ff1681565b3480156108c057600080fd5b506105aa6108cf366004614170565b611d23565b3480156108e057600080fd5b50600d546108229061ffff1681565b3480156108fb57600080fd5b50600d546104ae90600160701b900460ff1681565b34801561091c57600080fd5b50610507611daf565b34801561093157600080fd5b5061051e610940366004614170565b611dd9565b34801561095157600080fd5b50600d5461082290600160401b900461ffff1681565b610507611e73565b34801561097b57600080fd5b506104d961098a36600461439a565b611fdc565b34801561099b57600080fd5b50610507612063565b3480156109b057600080fd5b506104d960105481565b3480156109c657600080fd5b506105076109d5366004614644565b612075565b3480156109e657600080fd5b506104d96109f536600461439a565b60166020526000908152604090205481565b348015610a1357600080fd5b50610507610a2236600461439a565b612100565b348015610a3357600080fd5b50601c546104ae9060ff1681565b348015610a4d57600080fd5b506000546001600160a01b03166105aa565b348015610a6b57600080fd5b50610507610a7a366004614170565b61212a565b348015610a8b57600080fd5b50610507610a9a366004614424565b612148565b348015610aab57600080fd5b5061051e61215d565b348015610ac057600080fd5b5061050761216c565b348015610ad557600080fd5b50610507610ae43660046146ac565b612339565b348015610af557600080fd5b50610507610b043660046141fe565b6125f4565b6105076126c7565b348015610b1d57600080fd5b506104d9600e5481565b348015610b3357600080fd5b50610507610b423660046146c7565b612851565b348015610b5357600080fd5b50610507610b623660046146ac565b612915565b348015610b7357600080fd5b50610507610b823660046146fe565b61293d565b348015610b9357600080fd5b506009546104ae90600160a01b900460ff1681565b348015610bb457600080fd5b50610507610bc33660046146ac565b61299b565b348015610bd457600080fd5b50610507612a0a565b348015610be957600080fd5b50610507610bf8366004614731565b612b09565b348015610c0957600080fd5b50610507612b67565b348015610c1e57600080fd5b506104d960185481565b348015610c3457600080fd5b50610507610c43366004614189565b612ce8565b348015610c5457600080fd5b50610507610c633660046146ac565b612d59565b348015610c7457600080fd5b506009546105aa906001600160a01b031681565b348015610c9457600080fd5b5061051e610ca3366004614170565b612dfa565b348015610cb457600080fd5b50610507612fa3565b348015610cc957600080fd5b50610507610cd8366004614407565b61313d565b348015610ce957600080fd5b5061051e61315f565b348015610cfe57600080fd5b506104ae610d0d36600461478c565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b348015610d4757600080fd5b506104ae610d5636600461439a565b60156020526000908152604090205460ff1681565b348015610d7757600080fd5b5061050761316e565b348015610d8c57600080fd5b50610507610d9b36600461439a565b613365565b348015610dac57600080fd5b50610507610dbb3660046147b6565b6133db565b348015610dcc57600080fd5b50610507610ddb366004614407565b613438565b348015610dec57600080fd5b50610507610dfb36600461439a565b613453565b348015610e0c57600080fd5b50610507610e1b36600461439a565b6134a2565b348015610e2c57600080fd5b506104ae610e3b36600461439a565b6134d3565b348015610e4c57600080fd5b50610507610e5b36600461439a565b613500565b60006001600160e01b031982166380ac58cd60e01b1480610e9157506001600160e01b03198216635b5e139f60e01b145b80610eac57506301ffc9a760e01b6001600160e01b03198316145b92915050565b610eba613534565b601a54831115610efe5760405162461bcd60e51b815260206004820152600a6024820152691253959053125117d25160b21b60448201526064015b60405180910390fd5b600083815260196020526040902060010154601b548291610f1e9161481f565b610f289190614832565b601b5560009283526019602052604090922080546001600160a01b0319166001600160a01b039290921691909117815560010155565b606060018054610f6d90614845565b80601f0160208091040260200160405190810160405280929190818152602001828054610f9990614845565b8015610fe65780601f10610fbb57610100808354040283529160200191610fe6565b820191906000526020600020905b815481529060010190602001808311610fc957829003601f168201915b5050505050905090565b6000610ffb8261358e565b61105c5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610ef5565b506000908152600560205260409020546001600160a01b031690565b600061108382611d23565b9050806001600160a01b0316836001600160a01b0316036110f05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610ef5565b336001600160a01b038216148061110c575061110c8133610d0d565b61117e5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610ef5565b61118883836135d8565b505050565b611195613534565b601055565b6111a2613534565b600081116111dd5760405162461bcd60e51b81526020600482015260086024820152670414d4f554e543d360c41b6044820152606401610ef5565b601855565b6111ea613534565b60005b8181101561125c5760006015600085858581811061120d5761120d61487f565b9050602002016020810190611222919061439a565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790558061125481614895565b9150506111ed565b50818160405161126d9291906148ae565b604051809103902061127c3390565b6001600160a01b03167fd6ac91164e2cf7bb91d1929d1af0a25052d12a7033448af7c3866223f9e4d53060405160405180910390a35050565b600d54600160701b900460ff166112de5760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156113015760405162461bcd60e51b8152600401610ef590614913565b34600f54146113225760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160501b900461ffff16116113505760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff1615806113785750600d54640100000000900461ffff1661137633611fdc565b105b6113945760405162461bcd60e51b8152600401610ef590614990565b60175460ff161561142f573360009081526015602052604090205460ff166113ce5760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546113ec906004614832565b106114095760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805460039290611429908490614832565b90915550505b611437613646565b61143f613646565b611447613646565b565b600d54600160701b900460ff166114725760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156114955760405162461bcd60e51b8152600401610ef590614913565b348160ff16600e546114a79190614a0e565b146114c45760405162461bcd60e51b8152600401610ef590614939565b6003546114d59060ff831690614832565b600d54600160301b900461ffff16116115005760405162461bcd60e51b8152600401610ef590614960565b600d5462010000900461ffff1660ff8216106115545760405162461bcd60e51b8152602060048201526013602482015272115610d1515117d3505617d4115497d3525395606a1b6044820152606401610ef5565b600d5461ffff16158061158e5750600d5461ffff16600160ff831661157833611fdc565b6115829190614832565b61158c919061481f565b105b6115aa5760405162461bcd60e51b8152600401610ef590614990565b60175460ff1615611657573360009081526015602052604090205460ff166115e45760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546001906116089060ff851690614832565b611612919061481f565b1061162f5760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805460ff84169290611651908490614832565b90915550505b60005b8160ff1681101561167f5761166d613646565b8061167781614895565b91505061165a565b5050565b61168b613534565b611696896001614a25565b600d805469ffffffff0000000000001916600160301b61ffff9384160261ffff60401b191617600160401b928c16929092029190911790556116d960028a614a47565b600d805461ffff92909216600160501b0261ffff60501b1990921691909117905561170560048a614a47565b600d805461ffff92909216600160601b0261ffff60601b19909216919091179055611731886001614a25565b600d805461ffff92909216620100000263ffff000019909216919091179055600e879055611760876003614a0e565b600f5561ffff8616611773576000611775565b855b600d805461ffff191661ffff9283161790556001908716116117985760006117a3565b6117a3600287614a47565b600d80546eff0000000000000000ffff00000000191664010000000061ffff939093169290920260ff60701b191691909117600160701b87151502179055600b6117ee848683614ab0565b50601180546001600160a01b0319166001600160a01b038416179055601281905561181a816003614a0e565b601355505050505050505050565b601c5460ff16158061184457506000546001600160a01b031633145b8061185e57503360009081526008602052604090205460ff165b61187a5760405162461bcd60e51b8152600401610ef590614b6f565b6111888383836136e3565b61188d613534565b6009805460ff60a01b198116600160a01b9182900460ff1615909102179055565b6118b6613534565b601180546001600160a01b0319166001600160a01b03841617905560128190556118e1816003614a0e565b6013555050565b60008060005b60035481101561195d57846001600160a01b0316600382815481106119155761191561487f565b6000918252602090912001546001600160a01b03160361194d5783820361193f579150610eac9050565b8161194981614895565b9250505b61195681614895565b90506118ee565b506000811161199b5760405162461bcd60e51b815260206004820152600a6024820152691393d39157d193d5539160b21b6044820152606401610ef5565b60405162461bcd60e51b815260206004820152600c60248201526b09eaaa8be9e8cbe929c888ab60a31b6044820152606401610ef5565b6119da613534565b600d805460ff60701b198116600160701b9182900460ff1615909102179055565b611a03613534565b6017805460ff19169055600d805460ff60701b1916600160701b179055565b61118883838360405180602001604052806000815250612b09565b600260075403611a8f5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610ef5565b60026007556000546001600160a01b0316331480611ac057506009546001600160a01b0316336001600160a01b0316145b80611ada57503360009081526008602052604090205460ff165b611b145760405162461bcd60e51b815260206004820152600b60248201526a1393d517d0531313d5d15160aa1b6044820152606401610ef5565b6009546001600160a01b0316611b5f5760405162461bcd60e51b815260206004820152601060248201526f1514915054d5549657d393d517d4d15560821b6044820152606401610ef5565b6009546040516370a0823160e01b8152306004820152611be4916001600160a01b0390811691908416906370a0823190602401602060405180830381865afa158015611baf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bd39190614b9a565b6001600160a01b0384169190613714565b506001600755565b6000805b82811015611c6157846001600160a01b03166003858584818110611c1657611c1661487f565b9050602002013581548110611c2d57611c2d61487f565b6000918252602090912001546001600160a01b031614611c51576000915050611c67565b611c5a81614895565b9050611bf0565b50600190505b9392505050565b611c76613534565b6014805460ff1916911515919091179055565b611c91613534565b600b611188828483614ab0565b611ca6613534565b6000838152600c60205260409020611cbf828483614ab0565b50505050565b601c5460ff161580611ce157506000546001600160a01b031633145b80611cfb57503360009081526008602052604090205460ff165b611d175760405162461bcd60e51b8152600401610ef590614b6f565b611cbf84848484613766565b60008060038381548110611d3957611d3961487f565b6000918252602090912001546001600160a01b0316905080610eac5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610ef5565b611db7613534565b6017805460ff19166001179055600d805460ff60701b1916600160701b179055565b600c6020526000908152604090208054611df290614845565b80601f0160208091040260200160405190810160405280929190818152602001828054611e1e90614845565b8015611e6b5780601f10611e4057610100808354040283529160200191611e6b565b820191906000526020600020905b815481529060010190602001808311611e4e57829003601f168201915b505050505081565b600d54600160701b900460ff16611e9c5760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff1615611ebf5760405162461bcd60e51b8152600401610ef590614913565b34600e5414611ee05760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160401b900461ffff1611611f0e5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff161580611f2e5750600d5461ffff16611f2c33611fdc565b105b611f4a5760405162461bcd60e51b8152600401610ef590614990565b60175460ff161561143f573360009081526015602052604090205460ff16611f845760405162461bcd60e51b8152600401610ef5906149bd565b6018543360009081526016602052604090205410611fb45760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805491611fcf83614895565b9190505550611447613646565b60006001600160a01b0382166120475760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610ef5565b506001600160a01b031660009081526004602052604090205490565b61206b613534565b61144760006137b0565b61207d613534565b60005b82811015611cbf5760005b82828151811061209d5761209d61487f565b60200260200101518110156120ed576120db8585848181106120c1576120c161487f565b90506020020160208101906120d6919061439a565b613800565b806120e581614895565b91505061208b565b50806120f881614895565b915050612080565b612108613534565b600980546001600160a01b0319166001600160a01b0392909216919091179055565b612132613534565b600e819055612142816003614a0e565b600f5550565b612150613534565b600a611188828483614ab0565b606060028054610f6d90614845565b6000601a54116121b35760405162461bcd60e51b8152602060048201526012602482015271149150d2541251539514d7d393d517d4d15560721b6044820152606401610ef5565b6011546040516370a0823160e01b81523060048201526000916001600160a01b0316906370a0823190602401602060405180830381865afa1580156121fc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122209190614b9a565b905060015b601a54811161230857601b546000828152601960205260408120600101549091906122509085614a0e565b61225a9190614bc9565b9050478111612269578061226b565b475b6011546000848152601960205260409081902054905163a9059cbb60e01b81526001600160a01b03918216600482015260248101849052929350169063a9059cbb906044016020604051808303816000875af11580156122cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122f39190614bdd565b5050808061230090614895565b915050612225565b50604051819033907f66902764973bf4d35892cf2fde75fcd39ea2cc28a2d6f61e51e45493ee10afe190600090a350565b600d54600160701b900460ff166123625760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff161561238a5760405162461bcd60e51b8152600401610ef590614bfa565b6011546012546001600160a01b03909116906323b872dd90339030906123b59061ffff871690614a0e565b6040516001600160e01b031960e086901b1681526001600160a01b03938416600482015292909116602483015260448201526064016020604051808303816000875af1158015612409573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061242d9190614bdd565b506003546124409061ffff831690614832565b600d54600160301b900461ffff161161246b5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff620100009091048116908216106124c05760405162461bcd60e51b8152602060048201526013602482015272115610d1515117d3505617d4115497d3525395606a1b6044820152606401610ef5565b600d5461ffff1615806124fc5750600d5461ffff9081169060019083166124e633611fdc565b6124f09190614832565b6124fa919061481f565b105b6125185760405162461bcd60e51b8152600401610ef590614990565b60005b8161ffff168110156125415761252f613646565b8061253981614895565b91505061251b565b5060175460ff16156125f1573360009081526015602052604090205460ff1661257c5760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546001906125a19061ffff851690614832565b6125ab919061481f565b106125c85760405162461bcd60e51b8152600401610ef5906149e7565b336000908152601660205260408120805461ffff841692906125eb908490614832565b90915550505b50565b6125fc613534565b60005b8181101561266e5760016015600085858581811061261f5761261f61487f565b9050602002016020810190612634919061439a565b6001600160a01b031681526020810191909152604001600020805460ff19169115159190911790558061266681614895565b9150506125ff565b50818160405161267f9291906148ae565b604051809103902061268e3390565b6001600160a01b03167fcd843f7737d79a305493e6db876a1be0a17a416451f2a700901efbe0b8be5fab60405160405180910390a35050565b600d54600160701b900460ff166126f05760405162461bcd60e51b8152600401610ef5906148ee565b60145460ff16156127135760405162461bcd60e51b8152600401610ef590614913565b34601054146127345760405162461bcd60e51b8152600401610ef590614939565b600354600d54600160601b900461ffff16116127625760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff16158061278a5750600d54640100000000900461ffff1661278833611fdc565b105b6127a65760405162461bcd60e51b8152600401610ef590614990565b60175460ff1615612841573360009081526015602052604090205460ff166127e05760405162461bcd60e51b8152600401610ef5906149bd565b601854336000908152601660205260409020546127fe906004614832565b1061281b5760405162461bcd60e51b8152600401610ef5906149e7565b33600090815260166020526040812080546005929061283b908490614832565b90915550505b612849613646565b61142f613646565b336001600160a01b038316036128a95760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610ef5565b3360008181526006602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b61291d613534565b600d805461ffff909216620100000263ffff000019909216919091179055565b3360009081526008602052604090205460ff1615156001146129715760405162461bcd60e51b8152600401610ef590614c22565b60005b8161ffff168110156111885761298983613800565b8061299381614895565b915050612974565b6129a3613534565b60008161ffff16116129b65760006129b8565b805b600d805461ffff191661ffff9283161790556001908216116129e057600d5461ffff166129eb565b6129eb600282614a47565b600d60046101000a81548161ffff021916908361ffff16021790555050565b600d54600160701b900460ff16612a335760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff1615612a5b5760405162461bcd60e51b8152600401610ef590614bfa565b6011546012546040516323b872dd60e01b815233600482015230602482015260448101919091526001600160a01b03909116906323b872dd906064016020604051808303816000875af1158015612ab6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ada9190614bdd565b50600354600d54600160401b900461ffff1611611f0e5760405162461bcd60e51b8152600401610ef590614960565b601c5460ff161580612b2557506000546001600160a01b031633145b80612b3f57503360009081526008602052604090205460ff165b612b5b5760405162461bcd60e51b8152600401610ef590614b6f565b611cbf84848484613906565b6000601a5411612bae5760405162461bcd60e51b8152602060048201526012602482015271149150d2541251539514d7d393d517d4d15560721b6044820152606401610ef5565b4760015b601a548111612cb757601b54600082815260196020526040812060010154909190612bdd9085614a0e565b612be79190614bc9565b9050478111612bf65780612bf8565b475b60008381526019602052604080822054905192935090916001600160a01b039091169083908381818185875af1925050503d8060008114612c55576040519150601f19603f3d011682016040523d82523d6000602084013e612c5a565b606091505b5050905080612ca25760405162461bcd60e51b81526020600482015260146024820152734641494c45445f53454e44494e475f46554e445360601b6044820152606401610ef5565b50508080612caf90614895565b915050612bb2565b50604051819033907f0d20f677b24c0f42423a7e690ab1d066e4ae75145c497a68b1f34bd34944d12290600090a350565b612cf0613534565b601a8054906000612d0083614895565b9091555050601a805460009081526019602052604080822080546001600160a01b0319166001600160a01b03871617905591548152908120600101829055601b8054839290612d50908490614832565b90915550505050565b612d61613534565b612d6c816001614a25565b600d805469ffffffff0000000000001916600160301b61ffff9384160261ffff60401b191617600160401b92841692909202919091179055612daf600282614a47565b600d805461ffff92909216600160501b0261ffff60501b19909216919091179055612ddb600482614a47565b600d600c6101000a81548161ffff021916908361ffff16021790555050565b6060612e058261358e565b612e695760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610ef5565b6000828152600c602052604081208054612e8290614845565b90501115612f28576000828152600c602052604090208054612ea390614845565b80601f0160208091040260200160405190810160405280929190818152602001828054612ecf90614845565b8015612f1c5780601f10612ef157610100808354040283529160200191612f1c565b820191906000526020600020905b815481529060010190602001808311612eff57829003601f168201915b50505050509050919050565b600954600160a01b900460ff1615612f4757600b8054612ea390614845565b6000600b8054612f5690614845565b905011612f725760405180602001604052806000815250610eac565b600b612f7d83613938565b604051602001612f8e929190614c45565b60405160208183030381529060405292915050565b6000546001600160a01b0316331480612fcf57506009546001600160a01b0316336001600160a01b0316145b80612fe957503360009081526008602052604090205460ff165b6130235760405162461bcd60e51b815260206004820152600b60248201526a1393d517d0531313d5d15160aa1b6044820152606401610ef5565b6009546001600160a01b031661306e5760405162461bcd60e51b815260206004820152601060248201526f1514915054d5549657d393d517d4d15560821b6044820152606401610ef5565b60095460405147916000916001600160a01b039091169083908381818185875af1925050503d80600081146130bf576040519150601f19603f3d011682016040523d82523d6000602084013e6130c4565b606091505b505090508061310c5760405162461bcd60e51b81526020600482015260146024820152734641494c45445f53454e44494e475f46554e445360601b6044820152606401610ef5565b604051829033907f566e45b1c8057e725bf62796a7f1d37ae294393cab069725a09daddd1af98b7990600090a35050565b613145613534565b601480549115156101000261ff0019909216919091179055565b6060600a8054610f6d90614845565b600d54600160701b900460ff166131975760405162461bcd60e51b8152600401610ef5906148ee565b601454610100900460ff16156131bf5760405162461bcd60e51b8152600401610ef590614bfa565b6011546013546040516323b872dd60e01b815233600482015230602482015260448101919091526001600160a01b03909116906323b872dd906064016020604051808303816000875af115801561321a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061323e9190614bdd565b50600354600d54600160501b900461ffff161161326d5760405162461bcd60e51b8152600401610ef590614960565b600d5461ffff1615806132955750600d54640100000000900461ffff1661329333611fdc565b105b6132b15760405162461bcd60e51b8152600401610ef590614990565b6132b9613646565b6132c1613646565b6132c9613646565b60175460ff1615611447573360009081526015602052604090205460ff166133035760405162461bcd60e51b8152600401610ef5906149bd565b60185433600090815260166020526040902054613321906004614832565b1061333e5760405162461bcd60e51b8152600401610ef5906149e7565b33600090815260166020526040812080546005929061335e908490614832565b9091555050565b61336d613534565b6001600160a01b0381166133d25760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ef5565b6125f1816137b0565b601c5460ff1615806133f757506000546001600160a01b031633145b8061341157503360009081526008602052604090205460ff165b61342d5760405162461bcd60e51b8152600401610ef590614b6f565b611188838383613a40565b613440613534565b601c805460ff1916911515919091179055565b3360009081526008602052604090205460ff1615156001146134875760405162461bcd60e51b8152600401610ef590614c22565b61349081613800565b61349981613800565b6125f181613800565b6134aa613534565b6001600160a01b03166000908152600860205260409020805460ff19811660ff90911615179055565b60006134dd613534565b506001600160a01b03811660009081526008602052604090205460ff165b919050565b3360009081526008602052604090205460ff1615156001146134995760405162461bcd60e51b8152600401610ef590614c22565b6000546001600160a01b031633146114475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ef5565b60035460009082108015610eac575060006001600160a01b0316600383815481106135bb576135bb61487f565b6000918252602090912001546001600160a01b0316141592915050565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061360d82611d23565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60038054600181019091557fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b0180546001600160a01b0319163390811790915560009081526004602052604081208054916136a083614895565b90915550506003546136b49060019061481f565b60405133906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4565b6136ed3382613a82565b6137095760405162461bcd60e51b8152600401610ef590614ccc565b611188838383613b68565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052611188908490613d10565b60005b82518110156137a95761379785858584815181106137895761378961487f565b602002602001015185612b09565b806137a181614895565b915050613769565b5050505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6001600160a01b0381166138565760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610ef5565b60038054600181019091557fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b0180546001600160a01b0319166001600160a01b03831690811790915560009081526004602052604081208054916138b983614895565b90915550506003546138cd9060019061481f565b6040516001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a450565b6139103383613a82565b61392c5760405162461bcd60e51b8152600401610ef590614ccc565b611cbf84848484613de2565b60608160000361395f5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613989578061397381614895565b91506139829050600a83614bc9565b9150613963565b6000816001600160401b038111156139a3576139a3614497565b6040519080825280601f01601f1916602001820160405280156139cd576020820181803683370190505b5090505b8415613a38576139e260018361481f565b91506139ef600a86614d1d565b6139fa906030614832565b60f81b818381518110613a0f57613a0f61487f565b60200101906001600160f81b031916908160001a905350613a31600a86614bc9565b94506139d1565b949350505050565b60005b8151811015611cbf57613a708484848481518110613a6357613a6361487f565b6020026020010151611828565b80613a7a81614895565b915050613a43565b6000613a8d8261358e565b613aee5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610ef5565b6000613af983611d23565b9050806001600160a01b0316846001600160a01b03161480613b345750836001600160a01b0316613b2984610ff0565b6001600160a01b0316145b80613a3857506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff16613a38565b826001600160a01b0316613b7b82611d23565b6001600160a01b031614613be35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610ef5565b6001600160a01b038216613c455760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610ef5565b613c506000826135d8565b6001600160a01b0383166000908152600460205260408120805491613c7483614d31565b90915550506001600160a01b0382166000908152600460205260408120805491613c9d83614895565b91905055508160038281548110613cb657613cb661487f565b6000918252602082200180546001600160a01b0319166001600160a01b03938416179055604051839285811692908716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a4505050565b6000613d65826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316613e159092919063ffffffff16565b8051909150156111885780806020019051810190613d839190614bdd565b6111885760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610ef5565b613ded848484613b68565b613df984848484613e24565b611cbf5760405162461bcd60e51b8152600401610ef590614d48565b6060613a388484600085613f24565b60006001600160a01b0384163b613e3d57506001613a38565b604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613e6f903390899088908890600401614d9a565b6020604051808303816000875af1925050508015613eaa575060408051601f3d908101601f19168201909252613ea791810190614dd7565b60015b613f07573d808015613ed8576040519150601f19603f3d011682016040523d82523d6000602084013e613edd565b606091505b508051600003613eff5760405162461bcd60e51b8152600401610ef590614d48565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b606082471015613f855760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610ef5565b6001600160a01b0385163b613fdc5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610ef5565b600080866001600160a01b03168587604051613ff89190614df4565b60006040518083038185875af1925050503d8060008114614035576040519150601f19603f3d011682016040523d82523d6000602084013e61403a565b606091505b509150915061404a828286614055565b979650505050505050565b60608315614064575081611c67565b8251156140745782518084602001fd5b8160405162461bcd60e51b8152600401610ef5919061415d565b6001600160e01b0319811681146125f157600080fd5b6000602082840312156140b657600080fd5b8135611c678161408e565b80356001600160a01b03811681146134fb57600080fd5b6000806000606084860312156140ed57600080fd5b833592506140fd602085016140c1565b9150604084013590509250925092565b60005b83811015614128578181015183820152602001614110565b50506000910152565b6000815180845261414981602086016020860161410d565b601f01601f19169290920160200192915050565b602081526000611c676020830184614131565b60006020828403121561418257600080fd5b5035919050565b6000806040838503121561419c57600080fd5b6141a5836140c1565b946020939093013593505050565b60008083601f8401126141c557600080fd5b5081356001600160401b038111156141dc57600080fd5b6020830191508360208260051b85010111156141f757600080fd5b9250929050565b6000806020838503121561421157600080fd5b82356001600160401b0381111561422757600080fd5b614233858286016141b3565b90969095509350505050565b60006020828403121561425157600080fd5b813560ff81168114611c6757600080fd5b803561ffff811681146134fb57600080fd5b80151581146125f157600080fd5b60008083601f84011261429457600080fd5b5081356001600160401b038111156142ab57600080fd5b6020830191508360208285010111156141f757600080fd5b60008060008060008060008060006101008a8c0312156142e257600080fd5b6142eb8a614262565b98506142f960208b01614262565b975060408a0135965061430e60608b01614262565b955060808a013561431e81614274565b945060a08a01356001600160401b0381111561433957600080fd5b6143458c828d01614282565b9095509350614358905060c08b016140c1565b915060e08a013590509295985092959850929598565b60008060006060848603121561438357600080fd5b61438c846140c1565b92506140fd602085016140c1565b6000602082840312156143ac57600080fd5b611c67826140c1565b6000806000604084860312156143ca57600080fd5b6143d3846140c1565b925060208401356001600160401b038111156143ee57600080fd5b6143fa868287016141b3565b9497909650939450505050565b60006020828403121561441957600080fd5b8135611c6781614274565b6000806020838503121561443757600080fd5b82356001600160401b0381111561444d57600080fd5b61423385828601614282565b60008060006040848603121561446e57600080fd5b8335925060208401356001600160401b0381111561448b57600080fd5b6143fa86828701614282565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b03811182821017156144d5576144d5614497565b604052919050565b600082601f8301126144ee57600080fd5b813560206001600160401b0382111561450957614509614497565b8160051b6145188282016144ad565b928352848101820192828101908785111561453257600080fd5b83870192505b8483101561404a57823582529183019190830190614538565b600082601f83011261456257600080fd5b81356001600160401b0381111561457b5761457b614497565b61458e601f8201601f19166020016144ad565b8181528460208386010111156145a357600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080608085870312156145d657600080fd5b6145df856140c1565b93506145ed602086016140c1565b925060408501356001600160401b038082111561460957600080fd5b614615888389016144dd565b9350606087013591508082111561462b57600080fd5b5061463887828801614551565b91505092959194509250565b60008060006040848603121561465957600080fd5b83356001600160401b038082111561467057600080fd5b61467c878388016141b3565b9095509350602086013591508082111561469557600080fd5b506146a2868287016144dd565b9150509250925092565b6000602082840312156146be57600080fd5b611c6782614262565b600080604083850312156146da57600080fd5b6146e3836140c1565b915060208301356146f381614274565b809150509250929050565b6000806040838503121561471157600080fd5b61471a836140c1565b915061472860208401614262565b90509250929050565b6000806000806080858703121561474757600080fd5b614750856140c1565b935061475e602086016140c1565b92506040850135915060608501356001600160401b0381111561478057600080fd5b61463887828801614551565b6000806040838503121561479f57600080fd5b6147a8836140c1565b9150614728602084016140c1565b6000806000606084860312156147cb57600080fd5b6147d4846140c1565b92506147e2602085016140c1565b915060408401356001600160401b038111156147fd57600080fd5b6146a2868287016144dd565b634e487b7160e01b600052601160045260246000fd5b81810381811115610eac57610eac614809565b80820180821115610eac57610eac614809565b600181811c9082168061485957607f821691505b60208210810361487957634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052603260045260246000fd5b6000600182016148a7576148a7614809565b5060010190565b60008184825b858110156148e3576001600160a01b036148cd836140c1565b16835260209283019291909101906001016148b4565b509095945050505050565b6020808252600b908201526a14d0531157d0d313d4d15160aa1b604082015260600190565b6020808252600c908201526b4e4f5f4554485f53414c455360a01b604082015260600190565b6020808252600d908201526c0929c869ea4a48a86a8be8aa89609b1b604082015260600190565b6020808252601690820152754558434545445f4d41585f53414c455f535550504c5960501b604082015260600190565b60208082526013908201527222ac21a2a2a22fa6a0ac2fa822a92faaa9a2a960691b604082015260600190565b60208082526010908201526f1393d517d3d397d5d2125511531254d560821b604082015260600190565b6020808252600d908201526c13505617d5d317d35253951151609a1b604082015260600190565b8082028115828204841417610eac57610eac614809565b61ffff818116838216019080821115614a4057614a40614809565b5092915050565b61ffff828116828216039080821115614a4057614a40614809565b601f82111561118857600081815260208120601f850160051c81016020861015614a895750805b601f850160051c820191505b81811015614aa857828155600101614a95565b505050505050565b6001600160401b03831115614ac757614ac7614497565b614adb83614ad58354614845565b83614a62565b6000601f841160018114614b0f5760008515614af75750838201355b600019600387901b1c1916600186901b1783556137a9565b600083815260209020601f19861690835b82811015614b405786850135825560209485019460019092019101614b20565b5086821015614b5d5760001960f88860031b161c19848701351681555b505060018560011b0183555050505050565b6020808252601190820152701514905394d1915497d11254d050931151607a1b604082015260600190565b600060208284031215614bac57600080fd5b5051919050565b634e487b7160e01b600052601260045260246000fd5b600082614bd857614bd8614bb3565b500490565b600060208284031215614bef57600080fd5b8151611c6781614274565b6020808252600e908201526d4e4f5f544f4b454e5f53414c455360901b604082015260600190565b6020808252600990820152686f6e6c7950726f787960b81b604082015260600190565b6000808454614c5381614845565b60018281168015614c6b5760018114614c8057614caf565b60ff1984168752821515830287019450614caf565b8860005260208060002060005b85811015614ca65781548a820152908401908201614c8d565b50505082870194505b505050508351614cc381836020880161410d565b01949350505050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600082614d2c57614d2c614bb3565b500690565b600081614d4057614d40614809565b506000190190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090614dcd90830184614131565b9695505050505050565b600060208284031215614de957600080fd5b8151611c678161408e565b60008251614e0681846020870161410d565b919091019291505056fea2646970667358221220fa9aed0ab05e12e1bf309439e242ea17e2d801d7984444d7e557e054a7969be664736f6c63430008110033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000001f3eac5ba1247db5b31d6f6478eb234eaa75e14a000000000000000000000000000000000000000000000000000000000000000a4c6176612048656164730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044c61766100000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : name_ (string): Lava Heads
Arg [1] : symbol_ (string): Lava
Arg [2] : treasury_ (address): 0x1F3eAC5Ba1247DB5B31D6F6478EB234EAA75e14A
-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [2] : 0000000000000000000000001f3eac5ba1247db5b31d6f6478eb234eaa75e14a
Arg [3] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [4] : 4c61766120486561647300000000000000000000000000000000000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [6] : 4c61766100000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.