Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 113 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Deploy Wrapped N... | 16439012 | 731 days ago | IN | 0 ETH | 0.03191032 | ||||
Deploy Wrapped N... | 16438990 | 731 days ago | IN | 0 ETH | 0.03403768 | ||||
Deploy Wrapped N... | 16438981 | 731 days ago | IN | 0 ETH | 0.03403768 | ||||
Deploy Wrapped N... | 16438655 | 731 days ago | IN | 0 ETH | 0.03191032 | ||||
Deploy Wrapped N... | 15483494 | 866 days ago | IN | 0 ETH | 0.0087214 | ||||
Deploy Wrapped N... | 15459040 | 870 days ago | IN | 0 ETH | 0.02405968 | ||||
Deploy Wrapped N... | 15413240 | 877 days ago | IN | 0 ETH | 0.00957309 | ||||
Deploy Wrapped N... | 15408553 | 878 days ago | IN | 0 ETH | 0.00893489 | ||||
Deploy Wrapped N... | 15267958 | 900 days ago | IN | 0 ETH | 0.00942087 | ||||
Deploy Wrapped N... | 15267900 | 900 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15267825 | 900 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15267733 | 900 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15267633 | 900 days ago | IN | 0 ETH | 0.00850942 | ||||
Deploy Wrapped N... | 15267566 | 900 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15267549 | 900 days ago | IN | 0 ETH | 0.00951611 | ||||
Deploy Wrapped N... | 15267519 | 900 days ago | IN | 0 ETH | 0.01084951 | ||||
Deploy Wrapped N... | 15267358 | 900 days ago | IN | 0 ETH | 0.01035279 | ||||
Deploy Wrapped N... | 15267246 | 900 days ago | IN | 0 ETH | 0.01063677 | ||||
Deploy Wrapped N... | 15266420 | 900 days ago | IN | 0 ETH | 0.00893489 | ||||
Deploy Wrapped N... | 15262599 | 901 days ago | IN | 0 ETH | 0.00957309 | ||||
Deploy Wrapped N... | 15262216 | 901 days ago | IN | 0 ETH | 0.00957309 | ||||
Deploy Wrapped N... | 15261399 | 901 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15255088 | 902 days ago | IN | 0 ETH | 0.0087221 | ||||
Deploy Wrapped N... | 15248574 | 903 days ago | IN | 0 ETH | 0.00872215 | ||||
Deploy Wrapped N... | 15248399 | 903 days ago | IN | 0 ETH | 0.00872215 |
Latest 25 internal transactions (View All)
Advanced mode:
Loading...
Loading
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Name:
WrappedNFTFactory
Compiler Version
v0.8.10+commit.fc410830
Contract Source Code (Solidity Multiple files format)
// SPDX-License-Identifier: MIT // StarBlock DAO Contracts pragma solidity ^0.8.0; import "./Ownable.sol"; import "./ReentrancyGuard.sol"; import "./ERC2981.sol"; import "./ERC721Enumerable.sol"; import "./wnft_interfaces.sol"; import "./ArrayUtils.sol"; abstract contract BaseWrappedNFT is Ownable, ReentrancyGuard, ERC721, ERC2981, IBaseWrappedNFT { using ArrayUtils for uint256[]; string public constant NAME_PREFIX = "Wrapped "; string public constant SYMBOL_PREFIX = "W"; IWrappedNFTFactory public immutable factory;// can not changed IERC721Metadata public immutable nft; address public delegator; //who can help user to deposit and withdraw NFT, need user to approve //only user self and delegator can deposit or withdraw for user. modifier userSelfOrDelegator(address _forUser) { require(msg.sender == delegator || (_forUser == address(0) || _forUser == msg.sender), "BaseWrappedNFT: not allowed!"); _; } constructor( IERC721Metadata _nft ) ERC721("", "") { nft = _nft; factory = IWrappedNFTFactory(msg.sender); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 _interfaceId) public view virtual override(IERC165, ERC721, ERC2981) returns (bool) { return _interfaceId == type(IBaseWrappedNFT).interfaceId || _interfaceId == type(IERC721Receiver).interfaceId || _interfaceId == type(IERC2981Mutable).interfaceId || ERC721.supportsInterface(_interfaceId) || ERC2981.supportsInterface(_interfaceId); } function setDelegator(address _delegator) external onlyOwner nonReentrant { //allow delegator to be zero delegator = _delegator; emit DelegatorChanged(_delegator); } function _requireTokenIds(uint256[] memory _tokenIds) internal pure { require(_tokenIds.length > 0, "BaseWrappedNFT: tokenIds can not be empty!"); require(!_tokenIds.hasDuplicate(), "BaseWrappedNFT: tokenIds can not contain duplicate ones!"); } function deposit(address _forUser, uint256[] memory _tokenIds) external nonReentrant userSelfOrDelegator(_forUser) { _requireTokenIds(_tokenIds); if(_forUser == address(0)){ _forUser = msg.sender; } uint256 tokenId; for(uint256 i = 0; i < _tokenIds.length; i ++){ tokenId = _tokenIds[i]; require(nft.ownerOf(tokenId) == _forUser, "BaseWrappedNFT: can not deposit nft not owned!"); nft.safeTransferFrom(_forUser, address(this), tokenId); if(_exists(tokenId)){ require(ownerOf(tokenId) == address(this), "BaseWrappedNFT: tokenId owner error!"); _transfer(address(this), _forUser, tokenId); }else{ _safeMint(_forUser, tokenId); } } emit Deposit(_forUser, _tokenIds); } function withdraw(address _forUser, uint256[] memory _wnftTokenIds) external nonReentrant userSelfOrDelegator(_forUser) { _requireTokenIds(_wnftTokenIds); if(_forUser == address(0)){ _forUser = msg.sender; } uint256 wnftTokenId; for(uint256 i = 0; i < _wnftTokenIds.length; i ++){ wnftTokenId = _wnftTokenIds[i]; require(ownerOf(wnftTokenId) == _forUser, "BaseWrappedNFT: can not withdraw nft not owned!"); safeTransferFrom(_forUser, address(this), wnftTokenId); nft.safeTransferFrom(address(this), _forUser, wnftTokenId); } emit Withdraw(_forUser, _wnftTokenIds); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override(IERC721Metadata, ERC721) returns (string memory) { return string(abi.encodePacked(NAME_PREFIX, nft.name())); } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override(IERC721Metadata, ERC721) returns (string memory) { return string(abi.encodePacked(SYMBOL_PREFIX, nft.symbol())); } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 _tokenId) public view virtual override(IERC721Metadata, ERC721) returns (string memory) { require(ERC721._exists(_tokenId), "BaseWrappedNFT: URI query for nonexistent token"); return nft.tokenURI(_tokenId); } function exists(uint256 _tokenId) external view returns (bool) { return _exists(_tokenId); } /** * @dev See {IERC721Receiver-onERC721Received}. * * Always returns `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received ( address, address, uint256, bytes calldata ) public virtual override returns (bytes4) { return this.onERC721Received.selector; } function setDefaultRoyalty(address _receiver, uint96 _feeNumerator) external onlyOwner nonReentrant { _setDefaultRoyalty(_receiver, _feeNumerator); } function deleteDefaultRoyalty() external onlyOwner nonReentrant { _deleteDefaultRoyalty(); } function isEnumerable() external view virtual returns (bool) { return false; } } contract WrappedNFT is IWrappedNFT, BaseWrappedNFT { //add total supply for etherscan uint256 private _totalSupply; constructor( IERC721Metadata _nft ) BaseWrappedNFT(_nft) { } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 _interfaceId) public view virtual override(IERC165, BaseWrappedNFT) returns (bool) { return _interfaceId == type(IWrappedNFT).interfaceId || BaseWrappedNFT.supportsInterface(_interfaceId); } /** * @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` cannot be the zero address. * - `to` cannot be the zero address. * * 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 override { ERC721._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _totalSupply ++; } else if (to == address(0)) { _totalSupply --; } } function totalSupply() public view virtual override returns (uint256){ return _totalSupply; } } contract WrappedNFTEnumerable is IWrappedNFTEnumerable, WrappedNFT, ERC721Enumerable { constructor( IERC721Metadata _nft ) WrappedNFT(_nft) { } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 _interfaceId) public view virtual override(IERC165, WrappedNFT, ERC721Enumerable) returns (bool) { return _interfaceId == type(IWrappedNFTEnumerable).interfaceId || WrappedNFT.supportsInterface(_interfaceId) || ERC721Enumerable.supportsInterface(_interfaceId); } /** * @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` cannot be the zero address. * - `to` cannot be the zero address. * * 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 override(WrappedNFT, ERC721Enumerable) { ERC721Enumerable._beforeTokenTransfer(from, to, tokenId); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override(IERC721Metadata, ERC721) returns (string memory) { return BaseWrappedNFT.name(); } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override(IERC721Metadata, ERC721) returns (string memory) { return BaseWrappedNFT.symbol(); } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 _tokenId) public view virtual override(IERC721Metadata, ERC721) returns (string memory) { return BaseWrappedNFT.tokenURI(_tokenId); } function totalSupply() public view override(IWrappedNFTEnumerable, ERC721Enumerable, WrappedNFT) returns (uint256){ return ERC721Enumerable.totalSupply(); } function isEnumerable() external view virtual override returns (bool) { return true; } } //support deploy 2 WNFTs: ERC721 and ERC721Enumerable implementation. contract WrappedNFTFactory is IWrappedNFTFactory, Ownable, ReentrancyGuard { address public wnftDelegator; //used to set the delegator in WrappedNFT. mapping(IERC721Metadata => IWrappedNFT) public wnfts; //all the deployed WrappedNFTs. uint256 public wnftsNumber; function deployWrappedNFT(IERC721Metadata _nft, bool _isEnumerable) external onlyOwner nonReentrant returns (IWrappedNFT _wnft) { require(address(_nft) != address(0), "WrappedNFTFactory: _nft can not be zero!"); require(address(wnfts[_nft]) == address(0), "WrappedNFTFactory: wnft has been deployed!"); if(_isEnumerable){ _wnft = new WrappedNFTEnumerable(_nft); }else{ _wnft = new WrappedNFT(_nft); } if(wnftDelegator != address(0)){ _wnft.setDelegator(wnftDelegator); } Ownable(address(_wnft)).transferOwnership(owner()); wnfts[_nft] = _wnft; wnftsNumber ++; emit WrappedNFTDeployed(_nft, _wnft, _isEnumerable); } //allow wnftDelegator to be zero function setWNFTDelegator(address _wnftDelegator) external onlyOwner nonReentrant { wnftDelegator = _wnftDelegator; emit WNFTDelegatorChanged(_wnftDelegator); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT // StarBlock DAO Contracts pragma solidity ^0.8.0; library ArrayUtils { function hasDuplicate(uint256[] memory self) external pure returns(bool) { uint256 ivalue; uint256 jvalue; for(uint256 i = 0; i < self.length - 1; i ++){ ivalue = self[i]; for(uint256 j = i + 1; j < self.length; j ++){ jvalue = self[j]; if(ivalue == jvalue){ return true; } } } return false; } }
// 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 (last updated v4.6.0) (token/common/ERC2981.sol) pragma solidity ^0.8.0; import "./IERC2981.sol"; import "./ERC165.sol"; /** * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information. * * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first. * * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the * fee is specified in basis points by default. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. * * _Available since v4.5._ */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @inheritdoc IERC2981 */ function royaltyInfo(uint256 _tokenId, uint256 _salePrice) public view virtual override returns (address, uint256) { RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId]; if (royalty.receiver == address(0)) { royalty = _defaultRoyaltyInfo; } uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator(); return (royalty.receiver, royaltyAmount); } /** * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an * override. */ function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } /** * @dev Sets the royalty information that all ids in this contract will default to. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: invalid receiver"); _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Removes default royalty information. */ function _deleteDefaultRoyalty() internal virtual { delete _defaultRoyaltyInfo; } /** * @dev Sets the royalty information for a specific token id, overriding the global default. * * Requirements: * * - `tokenId` must be already minted. * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: Invalid parameters"); _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Resets royalty information for the token id back to the global default. */ function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/ERC721.sol) pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./IERC721Metadata.sol"; import "./Address.sol"; import "./Context.sol"; import "./Strings.sol"; import "./ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); _afterTokenTransfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); _afterTokenTransfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); _afterTokenTransfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC721: approve to caller"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721Enumerable.sol) pragma solidity ^0.8.0; import "./ERC721.sol"; import "./IERC721Enumerable.sol"; /** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */ abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex; // Array with all token ids, used for enumeration uint256[] private _allTokens; // Mapping from token id to position in the allTokens array mapping(uint256 => uint256) private _allTokensIndex; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; } /** * @dev See {IERC721Enumerable-tokenByIndex}. */ function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; } /** * @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` cannot be the zero address. * - `to` cannot be the zero address. * * 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 override { super._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnumeration(from, tokenId); } if (to == address(0)) { _removeTokenFromAllTokensEnumeration(tokenId); } else if (to != from) { _addTokenToOwnerEnumeration(to, tokenId); } } /** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */ function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = ERC721.balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; } /** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */ function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); } /** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes). * This has O(1) time complexity, but alters the order of the _ownedTokens array. * @param from address representing the previous owner of the given token ID * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address */ function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = ERC721.balanceOf(from) - 1; uint256 tokenIndex = _ownedTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary if (tokenIndex != lastTokenIndex) { uint256 lastTokenId = _ownedTokens[from][lastTokenIndex]; _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index } // This also deletes the contents at the last position of the array delete _ownedTokensIndex[tokenId]; delete _ownedTokens[from][lastTokenIndex]; } /** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */ function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding // an 'if' statement (like in _removeTokenFromOwnerEnumeration) uint256 lastTokenId = _allTokens[lastTokenIndex]; _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index // This also deletes the contents at the last position of the array delete _allTokensIndex[tokenId]; _allTokens.pop(); } }
// 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/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 (last updated v4.6.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Interface for the NFT Royalty Standard. * * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal * support for royalty payments across all NFT marketplaces and ecosystem participants. * * _Available since v4.5._ */ interface IERC2981 is IERC165 { /** * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of * exchange. The royalty amount is denominated and should be paid in that same unit of exchange. */ function royaltyInfo(uint256 tokenId, uint256 salePrice) external view returns (address receiver, uint256 royaltyAmount); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol) pragma solidity ^0.8.0; import "./IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
// 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/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "./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 Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// 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 v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT // StarBlock DAO Contracts pragma solidity ^0.8.0; import "./IERC2981.sol"; import "./IERC721Receiver.sol"; import "./IERC721Metadata.sol"; import "./IERC721Enumerable.sol"; interface IERC2981Mutable is IERC165, IERC2981 { function setDefaultRoyalty(address _receiver, uint96 _feeNumerator) external; function deleteDefaultRoyalty() external; } interface IBaseWrappedNFT is IERC165, IERC2981Mutable, IERC721Receiver, IERC721, IERC721Metadata { event DelegatorChanged(address _delegator); event Deposit(address _forUser, uint256[] _tokenIds); event Withdraw(address _forUser, uint256[] _wnftTokenIds); function nft() external view returns (IERC721Metadata); function factory() external view returns (IWrappedNFTFactory); function deposit(address _forUser, uint256[] memory _tokenIds) external; function withdraw(address _forUser, uint256[] memory _wnftTokenIds) external; function exists(uint256 _tokenId) external view returns (bool); function delegator() external view returns (address); function setDelegator(address _delegator) external; function isEnumerable() external view returns (bool); } interface IWrappedNFT is IBaseWrappedNFT { function totalSupply() external view returns (uint256); } interface IWrappedNFTEnumerable is IWrappedNFT, IERC721Enumerable { function totalSupply() external view override(IWrappedNFT, IERC721Enumerable) returns (uint256); } interface IWrappedNFTFactory { event WrappedNFTDeployed(IERC721Metadata _nft, IWrappedNFT _wnft, bool _isEnumerable); event WNFTDelegatorChanged(address _wnftDelegator); function wnftDelegator() external view returns (address); function deployWrappedNFT(IERC721Metadata _nft, bool _isEnumerable) external returns (IWrappedNFT); function wnfts(IERC721Metadata _nft) external view returns (IWrappedNFT); function wnftsNumber() external view returns (uint); }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"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":false,"internalType":"address","name":"_wnftDelegator","type":"address"}],"name":"WNFTDelegatorChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"contract IERC721Metadata","name":"_nft","type":"address"},{"indexed":false,"internalType":"contract IWrappedNFT","name":"_wnft","type":"address"},{"indexed":false,"internalType":"bool","name":"_isEnumerable","type":"bool"}],"name":"WrappedNFTDeployed","type":"event"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"_nft","type":"address"},{"internalType":"bool","name":"_isEnumerable","type":"bool"}],"name":"deployWrappedNFT","outputs":[{"internalType":"contract IWrappedNFT","name":"_wnft","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_wnftDelegator","type":"address"}],"name":"setWNFTDelegator","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"wnftDelegator","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC721Metadata","name":"","type":"address"}],"name":"wnfts","outputs":[{"internalType":"contract IWrappedNFT","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wnftsNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b5061001a33610023565b60018055610073565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b615d6f806100826000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c8063b442103d1161005b578063b442103d146100ef578063cd5d0df714610118578063cee0af431461012b578063f2fde38b1461013e57600080fd5b8063685106461461008d578063715018a6146100bd5780638388c4bd146100c75780638da5cb5b146100de575b600080fd5b6002546100a0906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100c5610151565b005b6100d060045481565b6040519081526020016100b4565b6000546001600160a01b03166100a0565b6100a06100fd3660046106f1565b6003602052600090815260409020546001600160a01b031681565b6100a0610126366004610715565b610190565b6100c56101393660046106f1565b6104fb565b6100c561014c3660046106f1565b6105d5565b6000546001600160a01b031633146101845760405162461bcd60e51b815260040161017b90610753565b60405180910390fd5b61018e6000610670565b565b600080546001600160a01b031633146101bb5760405162461bcd60e51b815260040161017b90610753565b6002600154141561020e5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640161017b565b60026001556001600160a01b03831661027a5760405162461bcd60e51b815260206004820152602860248201527f577261707065644e4654466163746f72793a205f6e66742063616e206e6f74206044820152676265207a65726f2160c01b606482015260840161017b565b6001600160a01b0383811660009081526003602052604090205416156102f55760405162461bcd60e51b815260206004820152602a60248201527f577261707065644e4654466163746f72793a20776e667420686173206265656e604482015269206465706c6f7965642160b01b606482015260840161017b565b811561033c5782604051610308906106c0565b6001600160a01b039091168152602001604051809103906000f080158015610334573d6000803e3d6000fd5b509050610379565b82604051610349906106ce565b6001600160a01b039091168152602001604051809103906000f080158015610375573d6000803e3d6000fd5b5090505b6002546001600160a01b0316156103ea576002546040516383cd9cc360e01b81526001600160a01b039182166004820152908216906383cd9cc390602401600060405180830381600087803b1580156103d157600080fd5b505af11580156103e5573d6000803e3d6000fd5b505050505b806001600160a01b031663f2fde38b61040b6000546001600160a01b031690565b6040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602401600060405180830381600087803b15801561044c57600080fd5b505af1158015610460573d6000803e3d6000fd5b505050506001600160a01b03838116600090815260036020526040812080546001600160a01b0319169284169290921790915560048054916104a183610788565b9091555050604080516001600160a01b038581168252831660208201528315158183015290517f1fb80a710cecae17f8ba11b6c37c173720084f38100d8e6ae4414df52cb167cc9181900360600190a16001805592915050565b6000546001600160a01b031633146105255760405162461bcd60e51b815260040161017b90610753565b600260015414156105785760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640161017b565b6002600181905580546001600160a01b0319166001600160a01b0383169081179091556040519081527fa2419509bda0c1bac16d68698ef4ebdacd7301a3d4b6018650eccc2ffcc9992b9060200160405180910390a15060018055565b6000546001600160a01b031633146105ff5760405162461bcd60e51b815260040161017b90610753565b6001600160a01b0381166106645760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161017b565b61066d81610670565b50565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b612d0380620007b283390190565b61288580620034b583390190565b6001600160a01b038116811461066d57600080fd5b60006020828403121561070357600080fd5b813561070e816106dc565b9392505050565b6000806040838503121561072857600080fd5b8235610733816106dc565b91506020830135801515811461074857600080fd5b809150509250929050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60006000198214156107aa57634e487b7160e01b600052601160045260246000fd5b506001019056fe60c06040523480156200001157600080fd5b5060405162002d0338038062002d038339810160408190526200003491620001b4565b80806040518060200160405280600081525060405180602001604052806000815250620000706200006a620000ba60201b60201c565b620000be565b600180558151620000899060029060208501906200010e565b5080516200009f9060039060208401906200010e565b5050506001600160a01b031660a05250503360805262000223565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b8280546200011c90620001e6565b90600052602060002090601f0160209004810192826200014057600085556200018b565b82601f106200015b57805160ff19168380011785556200018b565b828001600101855582156200018b579182015b828111156200018b5782518255916020019190600101906200016e565b50620001999291506200019d565b5090565b5b808211156200019957600081556001016200019e565b600060208284031215620001c757600080fd5b81516001600160a01b0381168114620001df57600080fd5b9392505050565b600181811c90821680620001fb57607f821691505b602082108114156200021d57634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a051612a90620002736000396000818161034e01528181610c9101528181610eff0152818161102501528181611405015281816119870152611b84015260006104970152612a906000f3fe608060405234801561001057600080fd5b50600436106101fb5760003560e01c806370a082311161011a578063a40f15ea116100ad578063c45a01551161007c578063c45a015514610492578063c87b56dd146104b9578063ce9b7930146104cc578063e985e9c5146104df578063f2fde38b1461051b57600080fd5b8063a40f15ea1461045d578063a71604e814610464578063aa1b103f14610477578063b88d4fde1461047f57600080fd5b806383cd9cc3116100e957806383cd9cc31461041e5780638da5cb5b1461043157806395d89b4114610442578063a22cb4651461044a57600080fd5b806370a08231146103c9578063715018a6146103dc5780637f7c4746146103e45780638293744b1461040b57600080fd5b80632a55205a116101925780634f558e79116101615780634f558e79146103705780634f6ccce714610383578063631c2bb8146103965780636352211e146103b657600080fd5b80632a55205a146102f15780632f745c591461032357806342842e0e1461033657806347ccca021461034957600080fd5b8063095ea7b3116101ce578063095ea7b31461027d578063150b7a021461029057806318160ddd146102c857806323b872dd146102de57600080fd5b806301ffc9a71461020057806304634d8d1461022857806306fdde031461023d578063081812fc14610252575b600080fd5b61021361020e366004612203565b61052e565b60405190151581526020015b60405180910390f35b61023b61023636600461223c565b610568565b005b6102456105d5565b60405161021f91906122d9565b6102656102603660046122ec565b6105e4565b6040516001600160a01b03909116815260200161021f565b61023b61028b366004612305565b61066c565b6102af61029e366004612331565b630a85bd0160e11b95945050505050565b6040516001600160e01b0319909116815260200161021f565b6102d0610782565b60405190815260200161021f565b61023b6102ec3660046123d0565b61078d565b6103046102ff366004612411565b6107be565b604080516001600160a01b03909316835260208301919091520161021f565b6102d0610331366004612305565b61086a565b61023b6103443660046123d0565b610900565b6102657f000000000000000000000000000000000000000000000000000000000000000081565b61021361037e3660046122ec565b61091b565b6102d06103913660046122ec565b610926565b610245604051806040016040528060018152602001605760f81b81525081565b6102656103c43660046122ec565b6109b9565b6102d06103d7366004612433565b610a30565b61023b610ab7565b6102456040518060400160405280600881526020016702bb930b83832b2160c51b81525081565b61023b610419366004612497565b610aed565b61023b61042c366004612433565b610d44565b6000546001600160a01b0316610265565b610245610dee565b61023b610458366004612560565b610df8565b6001610213565b61023b610472366004612497565b610e07565b61023b611159565b61023b61048d3660046125b6565b6111bb565b6102657f000000000000000000000000000000000000000000000000000000000000000081565b6102456104c73660046122ec565b6111f3565b600a54610265906001600160a01b031681565b6102136104ed366004612665565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b61023b610529366004612433565b6111fe565b60006001600160e01b031982166318160ddd60e01b1480610553575061055382611299565b806105625750610562826112be565b92915050565b6000546001600160a01b0316331461059b5760405162461bcd60e51b815260040161059290612693565b60405180910390fd5b600260015414156105be5760405162461bcd60e51b8152600401610592906126c8565b60026001556105cd82826112e3565b505060018055565b60606105df6113e0565b905090565b60006105ef826114ae565b6106505760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610592565b506000908152600660205260409020546001600160a01b031690565b6000610677826109b9565b9050806001600160a01b0316836001600160a01b031614156106e55760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610592565b336001600160a01b0382161480610701575061070181336104ed565b6107735760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610592565b61077d83836114cb565b505050565b60006105df600e5490565b6107973382611539565b6107b35760405162461bcd60e51b8152600401610592906126ff565b61077d838383611623565b60008281526009602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b03169282019290925282916108335750604080518082019091526008546001600160a01b0381168252600160a01b90046001600160601b031660208201525b602081015160009061271090610852906001600160601b031687612766565b61085c9190612785565b915196919550909350505050565b600061087583610a30565b82106108d75760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610592565b506001600160a01b03919091166000908152600c60209081526040808320938352929052205490565b61077d838383604051806020016040528060008152506111bb565b6000610562826114ae565b6000610931600e5490565b82106109945760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610592565b600e82815481106109a7576109a76127a7565b90600052602060002001549050919050565b6000818152600460205260408120546001600160a01b0316806105625760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610592565b60006001600160a01b038216610a9b5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610592565b506001600160a01b031660009081526005602052604090205490565b6000546001600160a01b03163314610ae15760405162461bcd60e51b815260040161059290612693565b610aeb60006117ca565b565b60026001541415610b105760405162461bcd60e51b8152600401610592906126c8565b6002600155600a5482906001600160a01b0316331480610b4957506001600160a01b0381161580610b4957506001600160a01b03811633145b610b955760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610592565b610b9e8261181a565b6001600160a01b038316610bb0573392505b6000805b8351811015610d0057838181518110610bcf57610bcf6127a7565b60200260200101519150846001600160a01b0316610bec836109b9565b6001600160a01b031614610c5a5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2063616e206e6f7420776974686472617760448201526e206e6674206e6f74206f776e65642160881b6064820152608401610592565b610c65853084610900565b604051632142170760e11b81523060048201526001600160a01b038681166024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b158015610cd557600080fd5b505af1158015610ce9573d6000803e3d6000fd5b505050508080610cf8906127bd565b915050610bb4565b507f67e9df8b3c7743c9f1b625ba4f2b4e601206dbd46ed5c33c85a1242e4d23a2d18484604051610d329291906127d8565b60405180910390a15050600180555050565b6000546001600160a01b03163314610d6e5760405162461bcd60e51b815260040161059290612693565b60026001541415610d915760405162461bcd60e51b8152600401610592906126c8565b6002600155600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f2b9e73b1b859ae78d60ebbdbf4300a27c63cb000bf7621af19d93940d89a09959060200160405180910390a15060018055565b60606105df611969565b610e033383836119e3565b5050565b60026001541415610e2a5760405162461bcd60e51b8152600401610592906126c8565b6002600155600a5482906001600160a01b0316331480610e6357506001600160a01b0381161580610e6357506001600160a01b03811633145b610eaf5760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610592565b610eb88261181a565b6001600160a01b038316610eca573392505b6000805b835181101561112757838181518110610ee957610ee96127a7565b60200260200101519150846001600160a01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316636352211e846040518263ffffffff1660e01b8152600401610f4b91815260200190565b602060405180830381865afa158015610f68573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f8c919061282e565b6001600160a01b031614610ff95760405162461bcd60e51b815260206004820152602e60248201527f42617365577261707065644e46543a2063616e206e6f74206465706f7369742060448201526d6e6674206e6f74206f776e65642160901b6064820152608401610592565b604051632142170760e11b81526001600160a01b038681166004830152306024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b15801561106957600080fd5b505af115801561107d573d6000803e3d6000fd5b5050505061108a826114ae565b1561110b5730611099836109b9565b6001600160a01b0316146110fb5760405162461bcd60e51b8152602060048201526024808201527f42617365577261707065644e46543a20746f6b656e4964206f776e6572206572604482015263726f722160e01b6064820152608401610592565b611106308684611623565b611115565b6111158583611ab2565b8061111f816127bd565b915050610ece565b507fff409334d2645d660e7cfa41a637aa21f45a79ecb9660a6931aa923bf75577c78484604051610d329291906127d8565b6000546001600160a01b031633146111835760405162461bcd60e51b815260040161059290612693565b600260015414156111a65760405162461bcd60e51b8152600401610592906126c8565b60026001556111b56000600855565b60018055565b6111c53383611539565b6111e15760405162461bcd60e51b8152600401610592906126ff565b6111ed84848484611acc565b50505050565b606061056282611aff565b6000546001600160a01b031633146112285760405162461bcd60e51b815260040161059290612693565b6001600160a01b03811661128d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610592565b611296816117ca565b50565b60006001600160e01b031982166318160ddd60e01b1480610562575061056282611bfb565b60006001600160e01b0319821663780e9d6360e01b1480610562575061056282611299565b6127106001600160601b03821611156113515760405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608401610592565b6001600160a01b0382166113a75760405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606401610592565b604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600855565b60606040518060400160405280600881526020016702bb930b83832b2160c51b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166306fdde036040518163ffffffff1660e01b8152600401600060405180830381865afa158015611461573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052611489919081019061284b565b60405160200161149a9291906128c2565b604051602081830303815290604052905090565b6000908152600460205260409020546001600160a01b0316151590565b600081815260066020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611500826109b9565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000611544826114ae565b6115a55760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610592565b60006115b0836109b9565b9050806001600160a01b0316846001600160a01b031614806115f757506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b8061161b5750836001600160a01b0316611610846105e4565b6001600160a01b0316145b949350505050565b826001600160a01b0316611636826109b9565b6001600160a01b03161461169a5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610592565b6001600160a01b0382166116fc5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610592565b611707838383611c64565b6117126000826114cb565b6001600160a01b038316600090815260056020526040812080546001929061173b9084906128f1565b90915550506001600160a01b0382166000908152600560205260408120805460019290611769908490612908565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600081511161187e5760405162461bcd60e51b815260206004820152602a60248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201526920626520656d7074792160b01b6064820152608401610592565b604051637cf7d2f560e01b8152738767cb8790faec827536fde6176036b234892ecc90637cf7d2f5906118b5908490600401612920565b602060405180830381865af41580156118d2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118f69190612964565b156112965760405162461bcd60e51b815260206004820152603860248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201527f20636f6e7461696e206475706c6963617465206f6e65732100000000000000006064820152608401610592565b6060604051806040016040528060018152602001605760f81b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015611461573d6000803e3d6000fd5b816001600160a01b0316836001600160a01b03161415611a455760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610592565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b610e03828260405180602001604052806000815250611c6f565b611ad7848484611623565b611ae384848484611ca2565b6111ed5760405162461bcd60e51b815260040161059290612981565b6060611b0a826114ae565b611b6e5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610592565b60405163c87b56dd60e01b8152600481018390527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063c87b56dd90602401600060405180830381865afa158015611bd3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610562919081019061284b565b60006001600160e01b031982166207f16560e21b1480611c2b57506001600160e01b03198216630a85bd0160e11b145b80611c4657506001600160e01b0319821663573c2ed960e11b145b80611c555750611c5582611da0565b80610562575061056282611df0565b61077d838383611e15565b611c798383611ed8565b611c866000848484611ca2565b61077d5760405162461bcd60e51b815260040161059290612981565b60006001600160a01b0384163b15611d9557604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ce69033908990889088906004016129d3565b6020604051808303816000875af1925050508015611d21575060408051601f3d908101601f19168201909252611d1e91810190612a10565b60015b611d7b573d808015611d4f576040519150601f19603f3d011682016040523d82523d6000602084013e611d54565b606091505b508051611d735760405162461bcd60e51b815260040161059290612981565b805181602001fd5b6001600160e01b031916630a85bd0160e11b14905061161b565b506001949350505050565b60006001600160e01b031982166380ac58cd60e01b1480611dd157506001600160e01b03198216635b5e139f60e01b145b8061056257506301ffc9a760e01b6001600160e01b0319831614610562565b60006001600160e01b0319821663152a902d60e11b1480610562575061056282611da0565b611e20838383612017565b6001600160a01b038316611e7b57611e7681600e80546000838152600f60205260408120829055600182018355919091527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd0155565b611e9e565b816001600160a01b0316836001600160a01b031614611e9e57611e9e838261205d565b6001600160a01b038216611eb55761077d816120fa565b826001600160a01b0316826001600160a01b03161461077d5761077d82826121a9565b6001600160a01b038216611f2e5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610592565b611f37816114ae565b15611f845760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610592565b611f9060008383611c64565b6001600160a01b0382166000908152600560205260408120805460019290611fb9908490612908565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160a01b03831661203f57600b8054906000612035836127bd565b9190505550505050565b6001600160a01b03821661077d57600b805490600061203583612a2d565b6000600161206a84610a30565b61207491906128f1565b6000838152600d60205260409020549091508082146120c7576001600160a01b0384166000908152600c602090815260408083208584528252808320548484528184208190558352600d90915290208190555b506000918252600d602090815260408084208490556001600160a01b039094168352600c81528383209183525290812055565b600e5460009061210c906001906128f1565b6000838152600f6020526040812054600e8054939450909284908110612134576121346127a7565b9060005260206000200154905080600e8381548110612155576121556127a7565b6000918252602080832090910192909255828152600f9091526040808220849055858252812055600e80548061218d5761218d612a44565b6001900381819060005260206000200160009055905550505050565b60006121b483610a30565b6001600160a01b039093166000908152600c602090815260408083208684528252808320859055938252600d9052919091209190915550565b6001600160e01b03198116811461129657600080fd5b60006020828403121561221557600080fd5b8135612220816121ed565b9392505050565b6001600160a01b038116811461129657600080fd5b6000806040838503121561224f57600080fd5b823561225a81612227565b915060208301356001600160601b038116811461227657600080fd5b809150509250929050565b60005b8381101561229c578181015183820152602001612284565b838111156111ed5750506000910152565b600081518084526122c5816020860160208601612281565b601f01601f19169290920160200192915050565b60208152600061222060208301846122ad565b6000602082840312156122fe57600080fd5b5035919050565b6000806040838503121561231857600080fd5b823561232381612227565b946020939093013593505050565b60008060008060006080868803121561234957600080fd5b853561235481612227565b9450602086013561236481612227565b935060408601359250606086013567ffffffffffffffff8082111561238857600080fd5b818801915088601f83011261239c57600080fd5b8135818111156123ab57600080fd5b8960208285010111156123bd57600080fd5b9699959850939650602001949392505050565b6000806000606084860312156123e557600080fd5b83356123f081612227565b9250602084013561240081612227565b929592945050506040919091013590565b6000806040838503121561242457600080fd5b50508035926020909101359150565b60006020828403121561244557600080fd5b813561222081612227565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561248f5761248f612450565b604052919050565b600080604083850312156124aa57600080fd5b82356124b581612227565b915060208381013567ffffffffffffffff808211156124d357600080fd5b818601915086601f8301126124e757600080fd5b8135818111156124f9576124f9612450565b8060051b915061250a848301612466565b818152918301840191848101908984111561252457600080fd5b938501935b8385101561254257843582529385019390850190612529565b8096505050505050509250929050565b801515811461129657600080fd5b6000806040838503121561257357600080fd5b823561257e81612227565b9150602083013561227681612552565b600067ffffffffffffffff8211156125a8576125a8612450565b50601f01601f191660200190565b600080600080608085870312156125cc57600080fd5b84356125d781612227565b935060208501356125e781612227565b925060408501359150606085013567ffffffffffffffff81111561260a57600080fd5b8501601f8101871361261b57600080fd5b803561262e6126298261258e565b612466565b81815288602083850101111561264357600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561267857600080fd5b823561268381612227565b9150602083013561227681612227565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b600081600019048311821515161561278057612780612750565b500290565b6000826127a257634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b60006000198214156127d1576127d1612750565b5060010190565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b8181101561282157845183529383019391830191600101612805565b5090979650505050505050565b60006020828403121561284057600080fd5b815161222081612227565b60006020828403121561285d57600080fd5b815167ffffffffffffffff81111561287457600080fd5b8201601f8101841361288557600080fd5b80516128936126298261258e565b8181528560208385010111156128a857600080fd5b6128b9826020830160208601612281565b95945050505050565b600083516128d4818460208801612281565b8351908301906128e8818360208801612281565b01949350505050565b60008282101561290357612903612750565b500390565b6000821982111561291b5761291b612750565b500190565b6020808252825182820181905260009190848201906040850190845b818110156129585783518352928401929184019160010161293c565b50909695505050505050565b60006020828403121561297657600080fd5b815161222081612552565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612a06908301846122ad565b9695505050505050565b600060208284031215612a2257600080fd5b8151612220816121ed565b600081612a3c57612a3c612750565b506000190190565b634e487b7160e01b600052603160045260246000fdfea2646970667358221220e0256d8400f125a68e5839778d6ea40d33c3a91cd3ba21d37c8a159f856386a364736f6c634300080a003360c06040523480156200001157600080fd5b50604051620028853803806200288583398101604081905262000034916200019b565b60408051602080820183526000808352835191820190935291825282916200005c33620000a5565b60018055815162000075906002906020850190620000f5565b5080516200008b906003906020840190620000f5565b5050506001600160a01b031660a05250336080526200020a565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b8280546200010390620001cd565b90600052602060002090601f01602090048101928262000127576000855562000172565b82601f106200014257805160ff191683800117855562000172565b8280016001018555821562000172579182015b828111156200017257825182559160200191906001019062000155565b506200018092915062000184565b5090565b5b8082111562000180576000815560010162000185565b600060208284031215620001ae57600080fd5b81516001600160a01b0381168114620001c657600080fd5b9392505050565b600181811c90821680620001e257607f821691505b602082108114156200020457634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a05161262b6200025a60003960008181610321015281816105ab01528181610bcd01528181610d4801528181610eab01528181610fd1015261122401526000610457015261262b6000f3fe608060405234801561001057600080fd5b50600436106101e55760003560e01c8063715018a61161010f578063a71604e8116100a2578063c87b56dd11610071578063c87b56dd14610479578063ce9b79301461048c578063e985e9c51461049f578063f2fde38b146104db57600080fd5b8063a71604e814610424578063aa1b103f14610437578063b88d4fde1461043f578063c45a01551461045257600080fd5b80638da5cb5b116100de5780638da5cb5b146103f157806395d89b4114610402578063a22cb4651461040a578063a40f15ea1461041d57600080fd5b8063715018a61461039c5780637f7c4746146103a45780638293744b146103cb57806383cd9cc3146103de57600080fd5b806323b872dd116101875780634f558e79116101565780634f558e7914610343578063631c2bb8146103565780636352211e1461037657806370a082311461038957600080fd5b806323b872dd146102c45780632a55205a146102d757806342842e0e1461030957806347ccca021461031c57600080fd5b8063081812fc116101c3578063081812fc1461023c578063095ea7b314610267578063150b7a021461027a57806318160ddd146102b257600080fd5b806301ffc9a7146101ea57806304634d8d1461021257806306fdde0314610227575b600080fd5b6101fd6101f8366004611db4565b6104ee565b60405190151581526020015b60405180910390f35b610225610220366004611ded565b610519565b005b61022f610586565b6040516102099190611e8a565b61024f61024a366004611e9d565b610654565b6040516001600160a01b039091168152602001610209565b610225610275366004611eb6565b6106dc565b610299610288366004611ee2565b630a85bd0160e11b95945050505050565b6040516001600160e01b03199091168152602001610209565b600b545b604051908152602001610209565b6102256102d2366004611f81565b6107f2565b6102ea6102e5366004611fc2565b610823565b604080516001600160a01b039093168352602083019190915201610209565b610225610317366004611f81565b6108cf565b61024f7f000000000000000000000000000000000000000000000000000000000000000081565b6101fd610351366004611e9d565b6108ea565b61022f604051806040016040528060018152602001605760f81b81525081565b61024f610384366004611e9d565b6108f5565b6102b6610397366004611fe4565b61096c565b6102256109f3565b61022f6040518060400160405280600881526020016702bb930b83832b2160c51b81525081565b6102256103d9366004612048565b610a29565b6102256103ec366004611fe4565b610c80565b6000546001600160a01b031661024f565b61022f610d2a565b610225610418366004612111565b610da4565b60006101fd565b610225610432366004612048565b610db3565b610225611105565b61022561044d366004612167565b611167565b61024f7f000000000000000000000000000000000000000000000000000000000000000081565b61022f610487366004611e9d565b61119f565b600a5461024f906001600160a01b031681565b6101fd6104ad366004612216565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b6102256104e9366004611fe4565b61129b565b60006001600160e01b031982166318160ddd60e01b1480610513575061051382611336565b92915050565b6000546001600160a01b0316331461054c5760405162461bcd60e51b815260040161054390612244565b60405180910390fd5b6002600154141561056f5760405162461bcd60e51b815260040161054390612279565b600260015561057e828261139f565b505060018055565b60606040518060400160405280600881526020016702bb930b83832b2160c51b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166306fdde036040518163ffffffff1660e01b8152600401600060405180830381865afa158015610607573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261062f91908101906122b0565b604051602001610640929190612327565b604051602081830303815290604052905090565b600061065f8261149c565b6106c05760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610543565b506000908152600660205260409020546001600160a01b031690565b60006106e7826108f5565b9050806001600160a01b0316836001600160a01b031614156107555760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610543565b336001600160a01b0382161480610771575061077181336104ad565b6107e35760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610543565b6107ed83836114b9565b505050565b6107fc3382611527565b6108185760405162461bcd60e51b815260040161054390612356565b6107ed838383611611565b60008281526009602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b03169282019290925282916108985750604080518082019091526008546001600160a01b0381168252600160a01b90046001600160601b031660208201525b6020810151600090612710906108b7906001600160601b0316876123bd565b6108c191906123dc565b915196919550909350505050565b6107ed83838360405180602001604052806000815250611167565b60006105138261149c565b6000818152600460205260408120546001600160a01b0316806105135760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610543565b60006001600160a01b0382166109d75760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610543565b506001600160a01b031660009081526005602052604090205490565b6000546001600160a01b03163314610a1d5760405162461bcd60e51b815260040161054390612244565b610a2760006117b8565b565b60026001541415610a4c5760405162461bcd60e51b815260040161054390612279565b6002600155600a5482906001600160a01b0316331480610a8557506001600160a01b0381161580610a8557506001600160a01b03811633145b610ad15760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610543565b610ada82611808565b6001600160a01b038316610aec573392505b6000805b8351811015610c3c57838181518110610b0b57610b0b6123fe565b60200260200101519150846001600160a01b0316610b28836108f5565b6001600160a01b031614610b965760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2063616e206e6f7420776974686472617760448201526e206e6674206e6f74206f776e65642160881b6064820152608401610543565b610ba18530846108cf565b604051632142170760e11b81523060048201526001600160a01b038681166024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b158015610c1157600080fd5b505af1158015610c25573d6000803e3d6000fd5b505050508080610c3490612414565b915050610af0565b507f67e9df8b3c7743c9f1b625ba4f2b4e601206dbd46ed5c33c85a1242e4d23a2d18484604051610c6e92919061242f565b60405180910390a15050600180555050565b6000546001600160a01b03163314610caa5760405162461bcd60e51b815260040161054390612244565b60026001541415610ccd5760405162461bcd60e51b815260040161054390612279565b6002600155600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f2b9e73b1b859ae78d60ebbdbf4300a27c63cb000bf7621af19d93940d89a09959060200160405180910390a15060018055565b6060604051806040016040528060018152602001605760f81b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610607573d6000803e3d6000fd5b610daf338383611957565b5050565b60026001541415610dd65760405162461bcd60e51b815260040161054390612279565b6002600155600a5482906001600160a01b0316331480610e0f57506001600160a01b0381161580610e0f57506001600160a01b03811633145b610e5b5760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610543565b610e6482611808565b6001600160a01b038316610e76573392505b6000805b83518110156110d357838181518110610e9557610e956123fe565b60200260200101519150846001600160a01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316636352211e846040518263ffffffff1660e01b8152600401610ef791815260200190565b602060405180830381865afa158015610f14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f389190612485565b6001600160a01b031614610fa55760405162461bcd60e51b815260206004820152602e60248201527f42617365577261707065644e46543a2063616e206e6f74206465706f7369742060448201526d6e6674206e6f74206f776e65642160901b6064820152608401610543565b604051632142170760e11b81526001600160a01b038681166004830152306024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b15801561101557600080fd5b505af1158015611029573d6000803e3d6000fd5b505050506110368261149c565b156110b75730611045836108f5565b6001600160a01b0316146110a75760405162461bcd60e51b8152602060048201526024808201527f42617365577261707065644e46543a20746f6b656e4964206f776e6572206572604482015263726f722160e01b6064820152608401610543565b6110b2308684611611565b6110c1565b6110c18583611a26565b806110cb81612414565b915050610e7a565b507fff409334d2645d660e7cfa41a637aa21f45a79ecb9660a6931aa923bf75577c78484604051610c6e92919061242f565b6000546001600160a01b0316331461112f5760405162461bcd60e51b815260040161054390612244565b600260015414156111525760405162461bcd60e51b815260040161054390612279565b60026001556111616000600855565b60018055565b6111713383611527565b61118d5760405162461bcd60e51b815260040161054390612356565b61119984848484611a40565b50505050565b60606111aa8261149c565b61120e5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610543565b60405163c87b56dd60e01b8152600481018390527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063c87b56dd90602401600060405180830381865afa158015611273573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261051391908101906122b0565b6000546001600160a01b031633146112c55760405162461bcd60e51b815260040161054390612244565b6001600160a01b03811661132a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610543565b611333816117b8565b50565b60006001600160e01b031982166207f16560e21b148061136657506001600160e01b03198216630a85bd0160e11b145b8061138157506001600160e01b0319821663573c2ed960e11b145b80611390575061139082611a73565b80610513575061051382611ac3565b6127106001600160601b038216111561140d5760405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608401610543565b6001600160a01b0382166114635760405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606401610543565b604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600855565b6000908152600460205260409020546001600160a01b0316151590565b600081815260066020526040902080546001600160a01b0319166001600160a01b03841690811790915581906114ee826108f5565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60006115328261149c565b6115935760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610543565b600061159e836108f5565b9050806001600160a01b0316846001600160a01b031614806115e557506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b806116095750836001600160a01b03166115fe84610654565b6001600160a01b0316145b949350505050565b826001600160a01b0316611624826108f5565b6001600160a01b0316146116885760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610543565b6001600160a01b0382166116ea5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610543565b6116f5838383611ae8565b6117006000826114b9565b6001600160a01b03831660009081526005602052604081208054600192906117299084906124a2565b90915550506001600160a01b03821660009081526005602052604081208054600192906117579084906124b9565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600081511161186c5760405162461bcd60e51b815260206004820152602a60248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201526920626520656d7074792160b01b6064820152608401610543565b604051637cf7d2f560e01b8152738767cb8790faec827536fde6176036b234892ecc90637cf7d2f5906118a39084906004016124d1565b602060405180830381865af41580156118c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118e49190612515565b156113335760405162461bcd60e51b815260206004820152603860248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201527f20636f6e7461696e206475706c6963617465206f6e65732100000000000000006064820152608401610543565b816001600160a01b0316836001600160a01b031614156119b95760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610543565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b610daf828260405180602001604052806000815250611b2e565b611a4b848484611611565b611a5784848484611b61565b6111995760405162461bcd60e51b815260040161054390612532565b60006001600160e01b031982166380ac58cd60e01b1480611aa457506001600160e01b03198216635b5e139f60e01b145b8061051357506301ffc9a760e01b6001600160e01b0319831614610513565b60006001600160e01b0319821663152a902d60e11b1480610513575061051382611a73565b6001600160a01b038316611b1057600b8054906000611b0683612414565b9190505550505050565b6001600160a01b0382166107ed57600b8054906000611b0683612584565b611b388383611c5f565b611b456000848484611b61565b6107ed5760405162461bcd60e51b815260040161054390612532565b60006001600160a01b0384163b15611c5457604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ba590339089908890889060040161259b565b6020604051808303816000875af1925050508015611be0575060408051601f3d908101601f19168201909252611bdd918101906125d8565b60015b611c3a573d808015611c0e576040519150601f19603f3d011682016040523d82523d6000602084013e611c13565b606091505b508051611c325760405162461bcd60e51b815260040161054390612532565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611609565b506001949350505050565b6001600160a01b038216611cb55760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610543565b611cbe8161149c565b15611d0b5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610543565b611d1760008383611ae8565b6001600160a01b0382166000908152600560205260408120805460019290611d409084906124b9565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b03198116811461133357600080fd5b600060208284031215611dc657600080fd5b8135611dd181611d9e565b9392505050565b6001600160a01b038116811461133357600080fd5b60008060408385031215611e0057600080fd5b8235611e0b81611dd8565b915060208301356001600160601b0381168114611e2757600080fd5b809150509250929050565b60005b83811015611e4d578181015183820152602001611e35565b838111156111995750506000910152565b60008151808452611e76816020860160208601611e32565b601f01601f19169290920160200192915050565b602081526000611dd16020830184611e5e565b600060208284031215611eaf57600080fd5b5035919050565b60008060408385031215611ec957600080fd5b8235611ed481611dd8565b946020939093013593505050565b600080600080600060808688031215611efa57600080fd5b8535611f0581611dd8565b94506020860135611f1581611dd8565b935060408601359250606086013567ffffffffffffffff80821115611f3957600080fd5b818801915088601f830112611f4d57600080fd5b813581811115611f5c57600080fd5b896020828501011115611f6e57600080fd5b9699959850939650602001949392505050565b600080600060608486031215611f9657600080fd5b8335611fa181611dd8565b92506020840135611fb181611dd8565b929592945050506040919091013590565b60008060408385031215611fd557600080fd5b50508035926020909101359150565b600060208284031215611ff657600080fd5b8135611dd181611dd8565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561204057612040612001565b604052919050565b6000806040838503121561205b57600080fd5b823561206681611dd8565b915060208381013567ffffffffffffffff8082111561208457600080fd5b818601915086601f83011261209857600080fd5b8135818111156120aa576120aa612001565b8060051b91506120bb848301612017565b81815291830184019184810190898411156120d557600080fd5b938501935b838510156120f3578435825293850193908501906120da565b8096505050505050509250929050565b801515811461133357600080fd5b6000806040838503121561212457600080fd5b823561212f81611dd8565b91506020830135611e2781612103565b600067ffffffffffffffff82111561215957612159612001565b50601f01601f191660200190565b6000806000806080858703121561217d57600080fd5b843561218881611dd8565b9350602085013561219881611dd8565b925060408501359150606085013567ffffffffffffffff8111156121bb57600080fd5b8501601f810187136121cc57600080fd5b80356121df6121da8261213f565b612017565b8181528860208385010111156121f457600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561222957600080fd5b823561223481611dd8565b91506020830135611e2781611dd8565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b6000602082840312156122c257600080fd5b815167ffffffffffffffff8111156122d957600080fd5b8201601f810184136122ea57600080fd5b80516122f86121da8261213f565b81815285602083850101111561230d57600080fd5b61231e826020830160208601611e32565b95945050505050565b60008351612339818460208801611e32565b83519083019061234d818360208801611e32565b01949350505050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b60008160001904831182151516156123d7576123d76123a7565b500290565b6000826123f957634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b6000600019821415612428576124286123a7565b5060010190565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b818110156124785784518352938301939183019160010161245c565b5090979650505050505050565b60006020828403121561249757600080fd5b8151611dd181611dd8565b6000828210156124b4576124b46123a7565b500390565b600082198211156124cc576124cc6123a7565b500190565b6020808252825182820181905260009190848201906040850190845b81811015612509578351835292840192918401916001016124ed565b50909695505050505050565b60006020828403121561252757600080fd5b8151611dd181612103565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b600081612593576125936123a7565b506000190190565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906125ce90830184611e5e565b9695505050505050565b6000602082840312156125ea57600080fd5b8151611dd181611d9e56fea2646970667358221220392c61325e34c86b1061063f7d19cedefa2b57c1ac7f6fbae89a288e616485f764736f6c634300080a0033a2646970667358221220469987aaea2a77e2dc9e7a1bf82ea117f48026f8d4eb90214e28074c4a4384d664736f6c634300080a0033
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100885760003560e01c8063b442103d1161005b578063b442103d146100ef578063cd5d0df714610118578063cee0af431461012b578063f2fde38b1461013e57600080fd5b8063685106461461008d578063715018a6146100bd5780638388c4bd146100c75780638da5cb5b146100de575b600080fd5b6002546100a0906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b6100c5610151565b005b6100d060045481565b6040519081526020016100b4565b6000546001600160a01b03166100a0565b6100a06100fd3660046106f1565b6003602052600090815260409020546001600160a01b031681565b6100a0610126366004610715565b610190565b6100c56101393660046106f1565b6104fb565b6100c561014c3660046106f1565b6105d5565b6000546001600160a01b031633146101845760405162461bcd60e51b815260040161017b90610753565b60405180910390fd5b61018e6000610670565b565b600080546001600160a01b031633146101bb5760405162461bcd60e51b815260040161017b90610753565b6002600154141561020e5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640161017b565b60026001556001600160a01b03831661027a5760405162461bcd60e51b815260206004820152602860248201527f577261707065644e4654466163746f72793a205f6e66742063616e206e6f74206044820152676265207a65726f2160c01b606482015260840161017b565b6001600160a01b0383811660009081526003602052604090205416156102f55760405162461bcd60e51b815260206004820152602a60248201527f577261707065644e4654466163746f72793a20776e667420686173206265656e604482015269206465706c6f7965642160b01b606482015260840161017b565b811561033c5782604051610308906106c0565b6001600160a01b039091168152602001604051809103906000f080158015610334573d6000803e3d6000fd5b509050610379565b82604051610349906106ce565b6001600160a01b039091168152602001604051809103906000f080158015610375573d6000803e3d6000fd5b5090505b6002546001600160a01b0316156103ea576002546040516383cd9cc360e01b81526001600160a01b039182166004820152908216906383cd9cc390602401600060405180830381600087803b1580156103d157600080fd5b505af11580156103e5573d6000803e3d6000fd5b505050505b806001600160a01b031663f2fde38b61040b6000546001600160a01b031690565b6040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602401600060405180830381600087803b15801561044c57600080fd5b505af1158015610460573d6000803e3d6000fd5b505050506001600160a01b03838116600090815260036020526040812080546001600160a01b0319169284169290921790915560048054916104a183610788565b9091555050604080516001600160a01b038581168252831660208201528315158183015290517f1fb80a710cecae17f8ba11b6c37c173720084f38100d8e6ae4414df52cb167cc9181900360600190a16001805592915050565b6000546001600160a01b031633146105255760405162461bcd60e51b815260040161017b90610753565b600260015414156105785760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015260640161017b565b6002600181905580546001600160a01b0319166001600160a01b0383169081179091556040519081527fa2419509bda0c1bac16d68698ef4ebdacd7301a3d4b6018650eccc2ffcc9992b9060200160405180910390a15060018055565b6000546001600160a01b031633146105ff5760405162461bcd60e51b815260040161017b90610753565b6001600160a01b0381166106645760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161017b565b61066d81610670565b50565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b612d0380620007b283390190565b61288580620034b583390190565b6001600160a01b038116811461066d57600080fd5b60006020828403121561070357600080fd5b813561070e816106dc565b9392505050565b6000806040838503121561072857600080fd5b8235610733816106dc565b91506020830135801515811461074857600080fd5b809150509250929050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60006000198214156107aa57634e487b7160e01b600052601160045260246000fd5b506001019056fe60c06040523480156200001157600080fd5b5060405162002d0338038062002d038339810160408190526200003491620001b4565b80806040518060200160405280600081525060405180602001604052806000815250620000706200006a620000ba60201b60201c565b620000be565b600180558151620000899060029060208501906200010e565b5080516200009f9060039060208401906200010e565b5050506001600160a01b031660a05250503360805262000223565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b8280546200011c90620001e6565b90600052602060002090601f0160209004810192826200014057600085556200018b565b82601f106200015b57805160ff19168380011785556200018b565b828001600101855582156200018b579182015b828111156200018b5782518255916020019190600101906200016e565b50620001999291506200019d565b5090565b5b808211156200019957600081556001016200019e565b600060208284031215620001c757600080fd5b81516001600160a01b0381168114620001df57600080fd5b9392505050565b600181811c90821680620001fb57607f821691505b602082108114156200021d57634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a051612a90620002736000396000818161034e01528181610c9101528181610eff0152818161102501528181611405015281816119870152611b84015260006104970152612a906000f3fe608060405234801561001057600080fd5b50600436106101fb5760003560e01c806370a082311161011a578063a40f15ea116100ad578063c45a01551161007c578063c45a015514610492578063c87b56dd146104b9578063ce9b7930146104cc578063e985e9c5146104df578063f2fde38b1461051b57600080fd5b8063a40f15ea1461045d578063a71604e814610464578063aa1b103f14610477578063b88d4fde1461047f57600080fd5b806383cd9cc3116100e957806383cd9cc31461041e5780638da5cb5b1461043157806395d89b4114610442578063a22cb4651461044a57600080fd5b806370a08231146103c9578063715018a6146103dc5780637f7c4746146103e45780638293744b1461040b57600080fd5b80632a55205a116101925780634f558e79116101615780634f558e79146103705780634f6ccce714610383578063631c2bb8146103965780636352211e146103b657600080fd5b80632a55205a146102f15780632f745c591461032357806342842e0e1461033657806347ccca021461034957600080fd5b8063095ea7b3116101ce578063095ea7b31461027d578063150b7a021461029057806318160ddd146102c857806323b872dd146102de57600080fd5b806301ffc9a71461020057806304634d8d1461022857806306fdde031461023d578063081812fc14610252575b600080fd5b61021361020e366004612203565b61052e565b60405190151581526020015b60405180910390f35b61023b61023636600461223c565b610568565b005b6102456105d5565b60405161021f91906122d9565b6102656102603660046122ec565b6105e4565b6040516001600160a01b03909116815260200161021f565b61023b61028b366004612305565b61066c565b6102af61029e366004612331565b630a85bd0160e11b95945050505050565b6040516001600160e01b0319909116815260200161021f565b6102d0610782565b60405190815260200161021f565b61023b6102ec3660046123d0565b61078d565b6103046102ff366004612411565b6107be565b604080516001600160a01b03909316835260208301919091520161021f565b6102d0610331366004612305565b61086a565b61023b6103443660046123d0565b610900565b6102657f000000000000000000000000000000000000000000000000000000000000000081565b61021361037e3660046122ec565b61091b565b6102d06103913660046122ec565b610926565b610245604051806040016040528060018152602001605760f81b81525081565b6102656103c43660046122ec565b6109b9565b6102d06103d7366004612433565b610a30565b61023b610ab7565b6102456040518060400160405280600881526020016702bb930b83832b2160c51b81525081565b61023b610419366004612497565b610aed565b61023b61042c366004612433565b610d44565b6000546001600160a01b0316610265565b610245610dee565b61023b610458366004612560565b610df8565b6001610213565b61023b610472366004612497565b610e07565b61023b611159565b61023b61048d3660046125b6565b6111bb565b6102657f000000000000000000000000000000000000000000000000000000000000000081565b6102456104c73660046122ec565b6111f3565b600a54610265906001600160a01b031681565b6102136104ed366004612665565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b61023b610529366004612433565b6111fe565b60006001600160e01b031982166318160ddd60e01b1480610553575061055382611299565b806105625750610562826112be565b92915050565b6000546001600160a01b0316331461059b5760405162461bcd60e51b815260040161059290612693565b60405180910390fd5b600260015414156105be5760405162461bcd60e51b8152600401610592906126c8565b60026001556105cd82826112e3565b505060018055565b60606105df6113e0565b905090565b60006105ef826114ae565b6106505760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610592565b506000908152600660205260409020546001600160a01b031690565b6000610677826109b9565b9050806001600160a01b0316836001600160a01b031614156106e55760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610592565b336001600160a01b0382161480610701575061070181336104ed565b6107735760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610592565b61077d83836114cb565b505050565b60006105df600e5490565b6107973382611539565b6107b35760405162461bcd60e51b8152600401610592906126ff565b61077d838383611623565b60008281526009602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b03169282019290925282916108335750604080518082019091526008546001600160a01b0381168252600160a01b90046001600160601b031660208201525b602081015160009061271090610852906001600160601b031687612766565b61085c9190612785565b915196919550909350505050565b600061087583610a30565b82106108d75760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610592565b506001600160a01b03919091166000908152600c60209081526040808320938352929052205490565b61077d838383604051806020016040528060008152506111bb565b6000610562826114ae565b6000610931600e5490565b82106109945760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610592565b600e82815481106109a7576109a76127a7565b90600052602060002001549050919050565b6000818152600460205260408120546001600160a01b0316806105625760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610592565b60006001600160a01b038216610a9b5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610592565b506001600160a01b031660009081526005602052604090205490565b6000546001600160a01b03163314610ae15760405162461bcd60e51b815260040161059290612693565b610aeb60006117ca565b565b60026001541415610b105760405162461bcd60e51b8152600401610592906126c8565b6002600155600a5482906001600160a01b0316331480610b4957506001600160a01b0381161580610b4957506001600160a01b03811633145b610b955760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610592565b610b9e8261181a565b6001600160a01b038316610bb0573392505b6000805b8351811015610d0057838181518110610bcf57610bcf6127a7565b60200260200101519150846001600160a01b0316610bec836109b9565b6001600160a01b031614610c5a5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2063616e206e6f7420776974686472617760448201526e206e6674206e6f74206f776e65642160881b6064820152608401610592565b610c65853084610900565b604051632142170760e11b81523060048201526001600160a01b038681166024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b158015610cd557600080fd5b505af1158015610ce9573d6000803e3d6000fd5b505050508080610cf8906127bd565b915050610bb4565b507f67e9df8b3c7743c9f1b625ba4f2b4e601206dbd46ed5c33c85a1242e4d23a2d18484604051610d329291906127d8565b60405180910390a15050600180555050565b6000546001600160a01b03163314610d6e5760405162461bcd60e51b815260040161059290612693565b60026001541415610d915760405162461bcd60e51b8152600401610592906126c8565b6002600155600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f2b9e73b1b859ae78d60ebbdbf4300a27c63cb000bf7621af19d93940d89a09959060200160405180910390a15060018055565b60606105df611969565b610e033383836119e3565b5050565b60026001541415610e2a5760405162461bcd60e51b8152600401610592906126c8565b6002600155600a5482906001600160a01b0316331480610e6357506001600160a01b0381161580610e6357506001600160a01b03811633145b610eaf5760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610592565b610eb88261181a565b6001600160a01b038316610eca573392505b6000805b835181101561112757838181518110610ee957610ee96127a7565b60200260200101519150846001600160a01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316636352211e846040518263ffffffff1660e01b8152600401610f4b91815260200190565b602060405180830381865afa158015610f68573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f8c919061282e565b6001600160a01b031614610ff95760405162461bcd60e51b815260206004820152602e60248201527f42617365577261707065644e46543a2063616e206e6f74206465706f7369742060448201526d6e6674206e6f74206f776e65642160901b6064820152608401610592565b604051632142170760e11b81526001600160a01b038681166004830152306024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b15801561106957600080fd5b505af115801561107d573d6000803e3d6000fd5b5050505061108a826114ae565b1561110b5730611099836109b9565b6001600160a01b0316146110fb5760405162461bcd60e51b8152602060048201526024808201527f42617365577261707065644e46543a20746f6b656e4964206f776e6572206572604482015263726f722160e01b6064820152608401610592565b611106308684611623565b611115565b6111158583611ab2565b8061111f816127bd565b915050610ece565b507fff409334d2645d660e7cfa41a637aa21f45a79ecb9660a6931aa923bf75577c78484604051610d329291906127d8565b6000546001600160a01b031633146111835760405162461bcd60e51b815260040161059290612693565b600260015414156111a65760405162461bcd60e51b8152600401610592906126c8565b60026001556111b56000600855565b60018055565b6111c53383611539565b6111e15760405162461bcd60e51b8152600401610592906126ff565b6111ed84848484611acc565b50505050565b606061056282611aff565b6000546001600160a01b031633146112285760405162461bcd60e51b815260040161059290612693565b6001600160a01b03811661128d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610592565b611296816117ca565b50565b60006001600160e01b031982166318160ddd60e01b1480610562575061056282611bfb565b60006001600160e01b0319821663780e9d6360e01b1480610562575061056282611299565b6127106001600160601b03821611156113515760405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608401610592565b6001600160a01b0382166113a75760405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606401610592565b604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600855565b60606040518060400160405280600881526020016702bb930b83832b2160c51b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166306fdde036040518163ffffffff1660e01b8152600401600060405180830381865afa158015611461573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052611489919081019061284b565b60405160200161149a9291906128c2565b604051602081830303815290604052905090565b6000908152600460205260409020546001600160a01b0316151590565b600081815260066020526040902080546001600160a01b0319166001600160a01b0384169081179091558190611500826109b9565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000611544826114ae565b6115a55760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610592565b60006115b0836109b9565b9050806001600160a01b0316846001600160a01b031614806115f757506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b8061161b5750836001600160a01b0316611610846105e4565b6001600160a01b0316145b949350505050565b826001600160a01b0316611636826109b9565b6001600160a01b03161461169a5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610592565b6001600160a01b0382166116fc5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610592565b611707838383611c64565b6117126000826114cb565b6001600160a01b038316600090815260056020526040812080546001929061173b9084906128f1565b90915550506001600160a01b0382166000908152600560205260408120805460019290611769908490612908565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600081511161187e5760405162461bcd60e51b815260206004820152602a60248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201526920626520656d7074792160b01b6064820152608401610592565b604051637cf7d2f560e01b8152738767cb8790faec827536fde6176036b234892ecc90637cf7d2f5906118b5908490600401612920565b602060405180830381865af41580156118d2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118f69190612964565b156112965760405162461bcd60e51b815260206004820152603860248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201527f20636f6e7461696e206475706c6963617465206f6e65732100000000000000006064820152608401610592565b6060604051806040016040528060018152602001605760f81b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015611461573d6000803e3d6000fd5b816001600160a01b0316836001600160a01b03161415611a455760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610592565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b610e03828260405180602001604052806000815250611c6f565b611ad7848484611623565b611ae384848484611ca2565b6111ed5760405162461bcd60e51b815260040161059290612981565b6060611b0a826114ae565b611b6e5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610592565b60405163c87b56dd60e01b8152600481018390527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063c87b56dd90602401600060405180830381865afa158015611bd3573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610562919081019061284b565b60006001600160e01b031982166207f16560e21b1480611c2b57506001600160e01b03198216630a85bd0160e11b145b80611c4657506001600160e01b0319821663573c2ed960e11b145b80611c555750611c5582611da0565b80610562575061056282611df0565b61077d838383611e15565b611c798383611ed8565b611c866000848484611ca2565b61077d5760405162461bcd60e51b815260040161059290612981565b60006001600160a01b0384163b15611d9557604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ce69033908990889088906004016129d3565b6020604051808303816000875af1925050508015611d21575060408051601f3d908101601f19168201909252611d1e91810190612a10565b60015b611d7b573d808015611d4f576040519150601f19603f3d011682016040523d82523d6000602084013e611d54565b606091505b508051611d735760405162461bcd60e51b815260040161059290612981565b805181602001fd5b6001600160e01b031916630a85bd0160e11b14905061161b565b506001949350505050565b60006001600160e01b031982166380ac58cd60e01b1480611dd157506001600160e01b03198216635b5e139f60e01b145b8061056257506301ffc9a760e01b6001600160e01b0319831614610562565b60006001600160e01b0319821663152a902d60e11b1480610562575061056282611da0565b611e20838383612017565b6001600160a01b038316611e7b57611e7681600e80546000838152600f60205260408120829055600182018355919091527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd0155565b611e9e565b816001600160a01b0316836001600160a01b031614611e9e57611e9e838261205d565b6001600160a01b038216611eb55761077d816120fa565b826001600160a01b0316826001600160a01b03161461077d5761077d82826121a9565b6001600160a01b038216611f2e5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610592565b611f37816114ae565b15611f845760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610592565b611f9060008383611c64565b6001600160a01b0382166000908152600560205260408120805460019290611fb9908490612908565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160a01b03831661203f57600b8054906000612035836127bd565b9190505550505050565b6001600160a01b03821661077d57600b805490600061203583612a2d565b6000600161206a84610a30565b61207491906128f1565b6000838152600d60205260409020549091508082146120c7576001600160a01b0384166000908152600c602090815260408083208584528252808320548484528184208190558352600d90915290208190555b506000918252600d602090815260408084208490556001600160a01b039094168352600c81528383209183525290812055565b600e5460009061210c906001906128f1565b6000838152600f6020526040812054600e8054939450909284908110612134576121346127a7565b9060005260206000200154905080600e8381548110612155576121556127a7565b6000918252602080832090910192909255828152600f9091526040808220849055858252812055600e80548061218d5761218d612a44565b6001900381819060005260206000200160009055905550505050565b60006121b483610a30565b6001600160a01b039093166000908152600c602090815260408083208684528252808320859055938252600d9052919091209190915550565b6001600160e01b03198116811461129657600080fd5b60006020828403121561221557600080fd5b8135612220816121ed565b9392505050565b6001600160a01b038116811461129657600080fd5b6000806040838503121561224f57600080fd5b823561225a81612227565b915060208301356001600160601b038116811461227657600080fd5b809150509250929050565b60005b8381101561229c578181015183820152602001612284565b838111156111ed5750506000910152565b600081518084526122c5816020860160208601612281565b601f01601f19169290920160200192915050565b60208152600061222060208301846122ad565b6000602082840312156122fe57600080fd5b5035919050565b6000806040838503121561231857600080fd5b823561232381612227565b946020939093013593505050565b60008060008060006080868803121561234957600080fd5b853561235481612227565b9450602086013561236481612227565b935060408601359250606086013567ffffffffffffffff8082111561238857600080fd5b818801915088601f83011261239c57600080fd5b8135818111156123ab57600080fd5b8960208285010111156123bd57600080fd5b9699959850939650602001949392505050565b6000806000606084860312156123e557600080fd5b83356123f081612227565b9250602084013561240081612227565b929592945050506040919091013590565b6000806040838503121561242457600080fd5b50508035926020909101359150565b60006020828403121561244557600080fd5b813561222081612227565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561248f5761248f612450565b604052919050565b600080604083850312156124aa57600080fd5b82356124b581612227565b915060208381013567ffffffffffffffff808211156124d357600080fd5b818601915086601f8301126124e757600080fd5b8135818111156124f9576124f9612450565b8060051b915061250a848301612466565b818152918301840191848101908984111561252457600080fd5b938501935b8385101561254257843582529385019390850190612529565b8096505050505050509250929050565b801515811461129657600080fd5b6000806040838503121561257357600080fd5b823561257e81612227565b9150602083013561227681612552565b600067ffffffffffffffff8211156125a8576125a8612450565b50601f01601f191660200190565b600080600080608085870312156125cc57600080fd5b84356125d781612227565b935060208501356125e781612227565b925060408501359150606085013567ffffffffffffffff81111561260a57600080fd5b8501601f8101871361261b57600080fd5b803561262e6126298261258e565b612466565b81815288602083850101111561264357600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561267857600080fd5b823561268381612227565b9150602083013561227681612227565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b600081600019048311821515161561278057612780612750565b500290565b6000826127a257634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b60006000198214156127d1576127d1612750565b5060010190565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b8181101561282157845183529383019391830191600101612805565b5090979650505050505050565b60006020828403121561284057600080fd5b815161222081612227565b60006020828403121561285d57600080fd5b815167ffffffffffffffff81111561287457600080fd5b8201601f8101841361288557600080fd5b80516128936126298261258e565b8181528560208385010111156128a857600080fd5b6128b9826020830160208601612281565b95945050505050565b600083516128d4818460208801612281565b8351908301906128e8818360208801612281565b01949350505050565b60008282101561290357612903612750565b500390565b6000821982111561291b5761291b612750565b500190565b6020808252825182820181905260009190848201906040850190845b818110156129585783518352928401929184019160010161293c565b50909695505050505050565b60006020828403121561297657600080fd5b815161222081612552565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612a06908301846122ad565b9695505050505050565b600060208284031215612a2257600080fd5b8151612220816121ed565b600081612a3c57612a3c612750565b506000190190565b634e487b7160e01b600052603160045260246000fdfea2646970667358221220e0256d8400f125a68e5839778d6ea40d33c3a91cd3ba21d37c8a159f856386a364736f6c634300080a003360c06040523480156200001157600080fd5b50604051620028853803806200288583398101604081905262000034916200019b565b60408051602080820183526000808352835191820190935291825282916200005c33620000a5565b60018055815162000075906002906020850190620000f5565b5080516200008b906003906020840190620000f5565b5050506001600160a01b031660a05250336080526200020a565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b8280546200010390620001cd565b90600052602060002090601f01602090048101928262000127576000855562000172565b82601f106200014257805160ff191683800117855562000172565b8280016001018555821562000172579182015b828111156200017257825182559160200191906001019062000155565b506200018092915062000184565b5090565b5b8082111562000180576000815560010162000185565b600060208284031215620001ae57600080fd5b81516001600160a01b0381168114620001c657600080fd5b9392505050565b600181811c90821680620001e257607f821691505b602082108114156200020457634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a05161262b6200025a60003960008181610321015281816105ab01528181610bcd01528181610d4801528181610eab01528181610fd1015261122401526000610457015261262b6000f3fe608060405234801561001057600080fd5b50600436106101e55760003560e01c8063715018a61161010f578063a71604e8116100a2578063c87b56dd11610071578063c87b56dd14610479578063ce9b79301461048c578063e985e9c51461049f578063f2fde38b146104db57600080fd5b8063a71604e814610424578063aa1b103f14610437578063b88d4fde1461043f578063c45a01551461045257600080fd5b80638da5cb5b116100de5780638da5cb5b146103f157806395d89b4114610402578063a22cb4651461040a578063a40f15ea1461041d57600080fd5b8063715018a61461039c5780637f7c4746146103a45780638293744b146103cb57806383cd9cc3146103de57600080fd5b806323b872dd116101875780634f558e79116101565780634f558e7914610343578063631c2bb8146103565780636352211e1461037657806370a082311461038957600080fd5b806323b872dd146102c45780632a55205a146102d757806342842e0e1461030957806347ccca021461031c57600080fd5b8063081812fc116101c3578063081812fc1461023c578063095ea7b314610267578063150b7a021461027a57806318160ddd146102b257600080fd5b806301ffc9a7146101ea57806304634d8d1461021257806306fdde0314610227575b600080fd5b6101fd6101f8366004611db4565b6104ee565b60405190151581526020015b60405180910390f35b610225610220366004611ded565b610519565b005b61022f610586565b6040516102099190611e8a565b61024f61024a366004611e9d565b610654565b6040516001600160a01b039091168152602001610209565b610225610275366004611eb6565b6106dc565b610299610288366004611ee2565b630a85bd0160e11b95945050505050565b6040516001600160e01b03199091168152602001610209565b600b545b604051908152602001610209565b6102256102d2366004611f81565b6107f2565b6102ea6102e5366004611fc2565b610823565b604080516001600160a01b039093168352602083019190915201610209565b610225610317366004611f81565b6108cf565b61024f7f000000000000000000000000000000000000000000000000000000000000000081565b6101fd610351366004611e9d565b6108ea565b61022f604051806040016040528060018152602001605760f81b81525081565b61024f610384366004611e9d565b6108f5565b6102b6610397366004611fe4565b61096c565b6102256109f3565b61022f6040518060400160405280600881526020016702bb930b83832b2160c51b81525081565b6102256103d9366004612048565b610a29565b6102256103ec366004611fe4565b610c80565b6000546001600160a01b031661024f565b61022f610d2a565b610225610418366004612111565b610da4565b60006101fd565b610225610432366004612048565b610db3565b610225611105565b61022561044d366004612167565b611167565b61024f7f000000000000000000000000000000000000000000000000000000000000000081565b61022f610487366004611e9d565b61119f565b600a5461024f906001600160a01b031681565b6101fd6104ad366004612216565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b6102256104e9366004611fe4565b61129b565b60006001600160e01b031982166318160ddd60e01b1480610513575061051382611336565b92915050565b6000546001600160a01b0316331461054c5760405162461bcd60e51b815260040161054390612244565b60405180910390fd5b6002600154141561056f5760405162461bcd60e51b815260040161054390612279565b600260015561057e828261139f565b505060018055565b60606040518060400160405280600881526020016702bb930b83832b2160c51b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166306fdde036040518163ffffffff1660e01b8152600401600060405180830381865afa158015610607573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261062f91908101906122b0565b604051602001610640929190612327565b604051602081830303815290604052905090565b600061065f8261149c565b6106c05760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610543565b506000908152600660205260409020546001600160a01b031690565b60006106e7826108f5565b9050806001600160a01b0316836001600160a01b031614156107555760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610543565b336001600160a01b0382161480610771575061077181336104ad565b6107e35760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610543565b6107ed83836114b9565b505050565b6107fc3382611527565b6108185760405162461bcd60e51b815260040161054390612356565b6107ed838383611611565b60008281526009602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b03169282019290925282916108985750604080518082019091526008546001600160a01b0381168252600160a01b90046001600160601b031660208201525b6020810151600090612710906108b7906001600160601b0316876123bd565b6108c191906123dc565b915196919550909350505050565b6107ed83838360405180602001604052806000815250611167565b60006105138261149c565b6000818152600460205260408120546001600160a01b0316806105135760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610543565b60006001600160a01b0382166109d75760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610543565b506001600160a01b031660009081526005602052604090205490565b6000546001600160a01b03163314610a1d5760405162461bcd60e51b815260040161054390612244565b610a2760006117b8565b565b60026001541415610a4c5760405162461bcd60e51b815260040161054390612279565b6002600155600a5482906001600160a01b0316331480610a8557506001600160a01b0381161580610a8557506001600160a01b03811633145b610ad15760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610543565b610ada82611808565b6001600160a01b038316610aec573392505b6000805b8351811015610c3c57838181518110610b0b57610b0b6123fe565b60200260200101519150846001600160a01b0316610b28836108f5565b6001600160a01b031614610b965760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2063616e206e6f7420776974686472617760448201526e206e6674206e6f74206f776e65642160881b6064820152608401610543565b610ba18530846108cf565b604051632142170760e11b81523060048201526001600160a01b038681166024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b158015610c1157600080fd5b505af1158015610c25573d6000803e3d6000fd5b505050508080610c3490612414565b915050610af0565b507f67e9df8b3c7743c9f1b625ba4f2b4e601206dbd46ed5c33c85a1242e4d23a2d18484604051610c6e92919061242f565b60405180910390a15050600180555050565b6000546001600160a01b03163314610caa5760405162461bcd60e51b815260040161054390612244565b60026001541415610ccd5760405162461bcd60e51b815260040161054390612279565b6002600155600a80546001600160a01b0319166001600160a01b0383169081179091556040519081527f2b9e73b1b859ae78d60ebbdbf4300a27c63cb000bf7621af19d93940d89a09959060200160405180910390a15060018055565b6060604051806040016040528060018152602001605760f81b8152507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166395d89b416040518163ffffffff1660e01b8152600401600060405180830381865afa158015610607573d6000803e3d6000fd5b610daf338383611957565b5050565b60026001541415610dd65760405162461bcd60e51b815260040161054390612279565b6002600155600a5482906001600160a01b0316331480610e0f57506001600160a01b0381161580610e0f57506001600160a01b03811633145b610e5b5760405162461bcd60e51b815260206004820152601c60248201527f42617365577261707065644e46543a206e6f7420616c6c6f77656421000000006044820152606401610543565b610e6482611808565b6001600160a01b038316610e76573392505b6000805b83518110156110d357838181518110610e9557610e956123fe565b60200260200101519150846001600160a01b03167f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316636352211e846040518263ffffffff1660e01b8152600401610ef791815260200190565b602060405180830381865afa158015610f14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f389190612485565b6001600160a01b031614610fa55760405162461bcd60e51b815260206004820152602e60248201527f42617365577261707065644e46543a2063616e206e6f74206465706f7369742060448201526d6e6674206e6f74206f776e65642160901b6064820152608401610543565b604051632142170760e11b81526001600160a01b038681166004830152306024830152604482018490527f000000000000000000000000000000000000000000000000000000000000000016906342842e0e90606401600060405180830381600087803b15801561101557600080fd5b505af1158015611029573d6000803e3d6000fd5b505050506110368261149c565b156110b75730611045836108f5565b6001600160a01b0316146110a75760405162461bcd60e51b8152602060048201526024808201527f42617365577261707065644e46543a20746f6b656e4964206f776e6572206572604482015263726f722160e01b6064820152608401610543565b6110b2308684611611565b6110c1565b6110c18583611a26565b806110cb81612414565b915050610e7a565b507fff409334d2645d660e7cfa41a637aa21f45a79ecb9660a6931aa923bf75577c78484604051610c6e92919061242f565b6000546001600160a01b0316331461112f5760405162461bcd60e51b815260040161054390612244565b600260015414156111525760405162461bcd60e51b815260040161054390612279565b60026001556111616000600855565b60018055565b6111713383611527565b61118d5760405162461bcd60e51b815260040161054390612356565b61119984848484611a40565b50505050565b60606111aa8261149c565b61120e5760405162461bcd60e51b815260206004820152602f60248201527f42617365577261707065644e46543a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610543565b60405163c87b56dd60e01b8152600481018390527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063c87b56dd90602401600060405180830381865afa158015611273573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261051391908101906122b0565b6000546001600160a01b031633146112c55760405162461bcd60e51b815260040161054390612244565b6001600160a01b03811661132a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610543565b611333816117b8565b50565b60006001600160e01b031982166207f16560e21b148061136657506001600160e01b03198216630a85bd0160e11b145b8061138157506001600160e01b0319821663573c2ed960e11b145b80611390575061139082611a73565b80610513575061051382611ac3565b6127106001600160601b038216111561140d5760405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608401610543565b6001600160a01b0382166114635760405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606401610543565b604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600855565b6000908152600460205260409020546001600160a01b0316151590565b600081815260066020526040902080546001600160a01b0319166001600160a01b03841690811790915581906114ee826108f5565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60006115328261149c565b6115935760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610543565b600061159e836108f5565b9050806001600160a01b0316846001600160a01b031614806115e557506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b806116095750836001600160a01b03166115fe84610654565b6001600160a01b0316145b949350505050565b826001600160a01b0316611624826108f5565b6001600160a01b0316146116885760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610543565b6001600160a01b0382166116ea5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610543565b6116f5838383611ae8565b6117006000826114b9565b6001600160a01b03831660009081526005602052604081208054600192906117299084906124a2565b90915550506001600160a01b03821660009081526005602052604081208054600192906117579084906124b9565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600081511161186c5760405162461bcd60e51b815260206004820152602a60248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201526920626520656d7074792160b01b6064820152608401610543565b604051637cf7d2f560e01b8152738767cb8790faec827536fde6176036b234892ecc90637cf7d2f5906118a39084906004016124d1565b602060405180830381865af41580156118c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118e49190612515565b156113335760405162461bcd60e51b815260206004820152603860248201527f42617365577261707065644e46543a20746f6b656e4964732063616e206e6f7460448201527f20636f6e7461696e206475706c6963617465206f6e65732100000000000000006064820152608401610543565b816001600160a01b0316836001600160a01b031614156119b95760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610543565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b610daf828260405180602001604052806000815250611b2e565b611a4b848484611611565b611a5784848484611b61565b6111995760405162461bcd60e51b815260040161054390612532565b60006001600160e01b031982166380ac58cd60e01b1480611aa457506001600160e01b03198216635b5e139f60e01b145b8061051357506301ffc9a760e01b6001600160e01b0319831614610513565b60006001600160e01b0319821663152a902d60e11b1480610513575061051382611a73565b6001600160a01b038316611b1057600b8054906000611b0683612414565b9190505550505050565b6001600160a01b0382166107ed57600b8054906000611b0683612584565b611b388383611c5f565b611b456000848484611b61565b6107ed5760405162461bcd60e51b815260040161054390612532565b60006001600160a01b0384163b15611c5457604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ba590339089908890889060040161259b565b6020604051808303816000875af1925050508015611be0575060408051601f3d908101601f19168201909252611bdd918101906125d8565b60015b611c3a573d808015611c0e576040519150601f19603f3d011682016040523d82523d6000602084013e611c13565b606091505b508051611c325760405162461bcd60e51b815260040161054390612532565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611609565b506001949350505050565b6001600160a01b038216611cb55760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610543565b611cbe8161149c565b15611d0b5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610543565b611d1760008383611ae8565b6001600160a01b0382166000908152600560205260408120805460019290611d409084906124b9565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b03198116811461133357600080fd5b600060208284031215611dc657600080fd5b8135611dd181611d9e565b9392505050565b6001600160a01b038116811461133357600080fd5b60008060408385031215611e0057600080fd5b8235611e0b81611dd8565b915060208301356001600160601b0381168114611e2757600080fd5b809150509250929050565b60005b83811015611e4d578181015183820152602001611e35565b838111156111995750506000910152565b60008151808452611e76816020860160208601611e32565b601f01601f19169290920160200192915050565b602081526000611dd16020830184611e5e565b600060208284031215611eaf57600080fd5b5035919050565b60008060408385031215611ec957600080fd5b8235611ed481611dd8565b946020939093013593505050565b600080600080600060808688031215611efa57600080fd5b8535611f0581611dd8565b94506020860135611f1581611dd8565b935060408601359250606086013567ffffffffffffffff80821115611f3957600080fd5b818801915088601f830112611f4d57600080fd5b813581811115611f5c57600080fd5b896020828501011115611f6e57600080fd5b9699959850939650602001949392505050565b600080600060608486031215611f9657600080fd5b8335611fa181611dd8565b92506020840135611fb181611dd8565b929592945050506040919091013590565b60008060408385031215611fd557600080fd5b50508035926020909101359150565b600060208284031215611ff657600080fd5b8135611dd181611dd8565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561204057612040612001565b604052919050565b6000806040838503121561205b57600080fd5b823561206681611dd8565b915060208381013567ffffffffffffffff8082111561208457600080fd5b818601915086601f83011261209857600080fd5b8135818111156120aa576120aa612001565b8060051b91506120bb848301612017565b81815291830184019184810190898411156120d557600080fd5b938501935b838510156120f3578435825293850193908501906120da565b8096505050505050509250929050565b801515811461133357600080fd5b6000806040838503121561212457600080fd5b823561212f81611dd8565b91506020830135611e2781612103565b600067ffffffffffffffff82111561215957612159612001565b50601f01601f191660200190565b6000806000806080858703121561217d57600080fd5b843561218881611dd8565b9350602085013561219881611dd8565b925060408501359150606085013567ffffffffffffffff8111156121bb57600080fd5b8501601f810187136121cc57600080fd5b80356121df6121da8261213f565b612017565b8181528860208385010111156121f457600080fd5b8160208401602083013760006020838301015280935050505092959194509250565b6000806040838503121561222957600080fd5b823561223481611dd8565b91506020830135611e2781611dd8565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b6000602082840312156122c257600080fd5b815167ffffffffffffffff8111156122d957600080fd5b8201601f810184136122ea57600080fd5b80516122f86121da8261213f565b81815285602083850101111561230d57600080fd5b61231e826020830160208601611e32565b95945050505050565b60008351612339818460208801611e32565b83519083019061234d818360208801611e32565b01949350505050565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b60008160001904831182151516156123d7576123d76123a7565b500290565b6000826123f957634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b6000600019821415612428576124286123a7565b5060010190565b6001600160a01b038316815260406020808301829052835191830182905260009184820191906060850190845b818110156124785784518352938301939183019160010161245c565b5090979650505050505050565b60006020828403121561249757600080fd5b8151611dd181611dd8565b6000828210156124b4576124b46123a7565b500390565b600082198211156124cc576124cc6123a7565b500190565b6020808252825182820181905260009190848201906040850190845b81811015612509578351835292840192918401916001016124ed565b50909695505050505050565b60006020828403121561252757600080fd5b8151611dd181612103565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b600081612593576125936123a7565b506000190190565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906125ce90830184611e5e565b9695505050505050565b6000602082840312156125ea57600080fd5b8151611dd181611d9e56fea2646970667358221220392c61325e34c86b1061063f7d19cedefa2b57c1ac7f6fbae89a288e616485f764736f6c634300080a0033a2646970667358221220469987aaea2a77e2dc9e7a1bf82ea117f48026f8d4eb90214e28074c4a4384d664736f6c634300080a0033
Deployed Bytecode Sourcemap
9184:1253:17:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9265:28;;;;;-1:-1:-1;;;;;9265:28:17;;;;;;-1:-1:-1;;;;;178:32:19;;;160:51;;148:2;133:18;9265:28:17;;;;;;;;1661:101:14;;;:::i;:::-;;9433:26:17;;;;;;;;;368:25:19;;;356:2;341:18;9433:26:17;222:177:19;1029:85:14;1075:7;1101:6;-1:-1:-1;;;;;1101:6:14;1029:85;;9343:52:17;;;;;;:::i;:::-;;;;;;;;;;;;-1:-1:-1;;;;;9343:52:17;;;9466:742;;;;;;:::i;:::-;;:::i;10255:180::-;;;;;;:::i;:::-;;:::i;1911:198:14:-;;;;;;:::i;:::-;;:::i;1661:101::-;1075:7;1101:6;-1:-1:-1;;;;;1101:6:14;719:10:2;1241:23:14;1233:68;;;;-1:-1:-1;;;1233:68:14;;;;;;;:::i;:::-;;;;;;;;;1725:30:::1;1752:1;1725:18;:30::i;:::-;1661:101::o:0;9466:742:17:-;9575:17;1101:6:14;;-1:-1:-1;;;;;1101:6:14;719:10:2;1241:23:14;1233:68;;;;-1:-1:-1;;;1233:68:14;;;;;;;:::i;:::-;1744:1:15::1;2325:7;;:19;;2317:63;;;::::0;-1:-1:-1;;;2317:63:15;;2372:2:19;2317:63:15::1;::::0;::::1;2354:21:19::0;2411:2;2391:18;;;2384:30;2450:33;2430:18;;;2423:61;2501:18;;2317:63:15::1;2170:355:19::0;2317:63:15::1;1744:1;2455:7;:18:::0;-1:-1:-1;;;;;9612:27:17;::::2;9604:80;;;::::0;-1:-1:-1;;;9604:80:17;;2732:2:19;9604:80:17::2;::::0;::::2;2714:21:19::0;2771:2;2751:18;;;2744:30;2810:34;2790:18;;;2783:62;-1:-1:-1;;;2861:18:19;;;2854:38;2909:19;;9604:80:17::2;2530:404:19::0;9604:80:17::2;-1:-1:-1::0;;;;;9710:11:17;;::::2;9734:1;9710:11:::0;;;:5:::2;:11;::::0;;;;;::::2;9702:34:::0;9694:89:::2;;;::::0;-1:-1:-1;;;9694:89:17;;3141:2:19;9694:89:17::2;::::0;::::2;3123:21:19::0;3180:2;3160:18;;;3153:30;3219:34;3199:18;;;3192:62;-1:-1:-1;;;3270:18:19;;;3263:40;3320:19;;9694:89:17::2;2939:406:19::0;9694:89:17::2;9796:13;9793:137;;;9857:4;9832:30;;;;;:::i;:::-;-1:-1:-1::0;;;;;178:32:19;;;160:51;;148:2;133:18;9832:30:17::2;;;;;;;;;;;;;;;;::::0;::::2;;;;;;9824:38;;9793:137;;;9914:4;9899:20;;;;;:::i;:::-;-1:-1:-1::0;;;;;178:32:19;;;160:51;;148:2;133:18;9899:20:17::2;;;;;;;;;;;;;;;;::::0;::::2;;;;;;9891:28;;9793:137;9942:13;::::0;-1:-1:-1;;;;;9942:13:17::2;:27:::0;9939:89:::2;;10003:13;::::0;9984:33:::2;::::0;-1:-1:-1;;;9984:33:17;;-1:-1:-1;;;;;10003:13:17;;::::2;9984:33;::::0;::::2;160:51:19::0;9984:18:17;;::::2;::::0;::::2;::::0;133::19;;9984:33:17::2;;;;;;;;;;;;;;;;;::::0;::::2;;;;;;;;;;;;::::0;::::2;;;;;;;;;9939:89;10053:5;-1:-1:-1::0;;;;;10037:41:17::2;;10079:7;1075::14::0;1101:6;-1:-1:-1;;;;;1101:6:14;;1029:85;10079:7:17::2;10037:50;::::0;-1:-1:-1;;;;;;10037:50:17::2;::::0;;;;;;-1:-1:-1;;;;;178:32:19;;;10037:50:17::2;::::0;::::2;160:51:19::0;133:18;;10037:50:17::2;;;;;;;;;;;;;;;;;::::0;::::2;;;;;;;;;;;;::::0;::::2;;;;;-1:-1:-1::0;;;;;;;;;10097:11:17;;::::2;;::::0;;;:5:::2;:11;::::0;;;;:19;;-1:-1:-1;;;;;;10097:19:17::2;::::0;;::::2;::::0;;;::::2;::::0;;;10126:11:::2;:14:::0;;;::::2;::::0;::::2;:::i;:::-;::::0;;;-1:-1:-1;;10155:46:17::2;::::0;;-1:-1:-1;;;;;4115:15:19;;;4097:34;;4167:15;;4162:2;4147:18;;4140:43;4226:14;;4219:22;4199:18;;;4192:50;10155:46:17;;::::2;::::0;;;;4047:2:19;10155:46:17;;::::2;1701:1:15::1;2628:22:::0;;9466:742:17;;-1:-1:-1;;9466:742:17:o;10255:180::-;1075:7:14;1101:6;-1:-1:-1;;;;;1101:6:14;719:10:2;1241:23:14;1233:68;;;;-1:-1:-1;;;1233:68:14;;;;;;;:::i;:::-;1744:1:15::1;2325:7;;:19;;2317:63;;;::::0;-1:-1:-1;;;2317:63:15;;2372:2:19;2317:63:15::1;::::0;::::1;2354:21:19::0;2411:2;2391:18;;;2384:30;2450:33;2430:18;;;2423:61;2501:18;;2317:63:15::1;2170:355:19::0;2317:63:15::1;1744:1;2455:7;:18:::0;;;10347:30:17;;-1:-1:-1;;;;;;10347:30:17::2;-1:-1:-1::0;;;;;10347:30:17;::::2;::::0;;::::2;::::0;;;10392:36:::2;::::0;160:51:19;;;10392:36:17::2;::::0;148:2:19;133:18;10392:36:17::2;;;;;;;-1:-1:-1::0;1701:1:15::1;2628:22:::0;;10255:180:17:o;1911:198:14:-;1075:7;1101:6;-1:-1:-1;;;;;1101:6:14;719:10:2;1241:23:14;1233:68;;;;-1:-1:-1;;;1233:68:14;;;;;;;:::i;:::-;-1:-1:-1;;;;;1999:22:14;::::1;1991:73;;;::::0;-1:-1:-1;;;1991:73:14;;4455:2:19;1991:73:14::1;::::0;::::1;4437:21:19::0;4494:2;4474:18;;;4467:30;4533:34;4513:18;;;4506:62;-1:-1:-1;;;4584:18:19;;;4577:36;4630:19;;1991:73:14::1;4253:402:19::0;1991:73:14::1;2074:28;2093:8;2074:18;:28::i;:::-;1911:198:::0;:::o;2263:187::-;2336:16;2355:6;;-1:-1:-1;;;;;2371:17:14;;;-1:-1:-1;;;;;;2371:17:14;;;;;;2403:40;;2355:6;;;;;;;2403:40;;2336:16;2403:40;2326:124;2263:187;:::o;-1:-1:-1:-;;;;;;;;:::o;:::-;;;;;;;;:::o;404:148:19:-;-1:-1:-1;;;;;496:31:19;;486:42;;476:70;;542:1;539;532:12;557:288;640:6;693:2;681:9;672:7;668:23;664:32;661:52;;;709:1;706;699:12;661:52;748:9;735:23;767:48;809:5;767:48;:::i;:::-;834:5;557:288;-1:-1:-1;;;557:288:19:o;1078:457::-;1167:6;1175;1228:2;1216:9;1207:7;1203:23;1199:32;1196:52;;;1244:1;1241;1234:12;1196:52;1283:9;1270:23;1302:48;1344:5;1302:48;:::i;:::-;1369:5;-1:-1:-1;1426:2:19;1411:18;;1398:32;1468:15;;1461:23;1449:36;;1439:64;;1499:1;1496;1489:12;1439:64;1522:7;1512:17;;;1078:457;;;;;:::o;1809:356::-;2011:2;1993:21;;;2030:18;;;2023:30;2089:34;2084:2;2069:18;;2062:62;2156:2;2141:18;;1809:356::o;3582:232::-;3621:3;-1:-1:-1;;3642:17:19;;3639:140;;;3701:10;3696:3;3692:20;3689:1;3682:31;3736:4;3733:1;3726:15;3764:4;3761:1;3754:15;3639:140;-1:-1:-1;3806:1:19;3795:13;;3582:232::o
Swarm Source
ipfs://469987aaea2a77e2dc9e7a1bf82ea117f48026f8d4eb90214e28074c4a4384d6
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.