Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 1 from a total of 1 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
Value | ||||
---|---|---|---|---|---|---|---|---|---|
0x60806040 | 14049182 | 901 days ago | IN | Create: MossLandNFT | 0 ETH | 0.62964096 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
MossLandNFT
Compiler Version
v0.8.8+commit.dddeac2f
Optimization Enabled:
Yes with 200000 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: MIT pragma solidity ^0.8.8; import "./LandNFT_Authorization.sol"; contract MossLandNFT is LandNFT_Authorization { enum ProjectType { GOVERNANCE, PROPERTY } struct Project { uint256 id; uint256 totalHectares; uint256 totalSupply; uint256 inflationCooldownPeriod; uint256 nextInflationAt; ProjectType projectType; bool created; } uint256 public constant HECTARE_TOKEN_INFLATION_RATE_FACTOR = 10000; string public name; string public symbol; string public description; address public owner; // for opensea uint256[] public tokenIds; // list of token ids - order is not important mapping(uint256 => Project) public projects; mapping (uint256 => string) private _tokenURIs; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); event ProjectAdded(address sender, Project project); event TokenInflation(uint256 tokenId, uint256 ratio, address sender); function initialize( string calldata __uri, string calldata _name, string calldata _symbol, string calldata _description, address _owner ) public initializer { __ERC1155_init(__uri); __EIP712_init("LandNFT", "1"); _setupRole(MINTER_ROLE, _msgSender()); _setupRole(BURNER_ROLE, _msgSender()); _setupRole(OPERATOR_ROLE, _msgSender()); _setupRole(ADMIN_ROLE, _msgSender()); _setupRole(DEFAULT_ADMIN_ROLE, _msgSender()); name = _name; symbol = _symbol; description = _description; owner = _owner; emit OwnershipTransferred(address(0), msg.sender); } /************************************** ROLE-RESTRICTED WRITE FUNCTIONS ***************************************/ function addProject( uint256 id, string calldata cid, uint256 hectares, uint256 cooldown, ProjectType projectType ) external onlyMinter { require(hectares > 0, "LandNFT: invalid hectares"); require(cooldown > 0, "LandNFT: invalid cooldown period"); require(bytes(cid).length > 0, "LandNFT: empty cid"); require(!projects[id].created, "LandNFT: project already added"); tokenIds.push(id); projects[id] = Project({ id: id, totalHectares: hectares, totalSupply: hectares, inflationCooldownPeriod: cooldown, nextInflationAt: block.timestamp + cooldown, created: true, projectType: projectType }); _mint(msg.sender, id, hectares, new bytes(0)); _setTokenURI(id, cid); emit ProjectAdded(msg.sender, projects[id]); } function inflate( uint256 projectId, uint256 increase ) public onlyMinter { Project storage project = projects[projectId]; require(project.created, "LandNFT: project not registered"); require(increase != 0, "LandNFT: increase ratio cannot be zero"); require(block.timestamp > project.nextInflationAt, "LandNFT: project is in cooldown period"); uint256 additionalAmount = project.totalSupply * increase/ HECTARE_TOKEN_INFLATION_RATE_FACTOR; project.totalSupply += additionalAmount; project.nextInflationAt += project.nextInflationAt + project.inflationCooldownPeriod; _mint(msg.sender, projectId, additionalAmount, new bytes(0)); emit TokenInflation(projectId, additionalAmount, msg.sender); } function burn( address account, uint256 id, uint256 value ) public override onlyBurner { _burn(account, id, value); projects[id].totalSupply -= value; } function burnBatch( address account, uint256[] calldata ids, uint256[] calldata values ) public override onlyBurner { _burnBatch(account, ids, values); for (uint256 i = 0; i < ids.length; i++) { projects[ids[i]].totalSupply -= values[i]; } } function updateTokenURI( uint256 id, string memory cid ) external onlyAdmin { require(projects[id].created, "LandNFT: token not registered"); _setTokenURI(id, cid); } /** * @dev Internal function to set the token cid for a given token. * @param tokenId uint256 ID of the token to set its URI * @param cid string ipfs cid to assign */ function _setTokenURI(uint256 tokenId, string memory cid) internal { _tokenURIs[tokenId] = string(abi.encodePacked(_uri, cid)); emit URI(_tokenURIs[tokenId], tokenId); } /** * @dev Updates owner * @param _newOwner new owner's address */ function setOwner(address _newOwner) external onlyAdmin { require(_newOwner != address(0), "LandNFT: invalid owner address"); emit OwnershipTransferred(owner, _newOwner); owner = _newOwner; } /************************************** READ FUNCTIONS ***************************************/ function isRegistered( uint256 id ) external view returns (bool) { return projects[id].created; } function getRegisteredTokens() external view returns (uint256[] memory) { return tokenIds; } function hectaresBalanceOf(address account, uint256 id) public view returns (uint256 balance, uint256 totalSupply, uint256 totalHectares) { balance = super.balanceOf(account, id); totalSupply = projects[id].totalSupply; totalHectares = projects[id].totalHectares; } function balancesOf( address wallet ) external view returns (uint256[] memory tokens, uint256[] memory balances) { tokens = tokenIds; balances = new uint256[](tokens.length); for (uint256 i = 0; i < tokens.length; ++i) { balances[i] = balanceOf(wallet, tokens[i]); } } function uri(uint256 _id) public view override returns (string memory) { return _tokenURI(_id); } /** * @dev Returns an URI for a given token ID. If tokenId is 0, returns _uri * @param tokenId uint256 ID of the token to query */ function _tokenURI(uint256 tokenId) internal view returns (string memory) { if (tokenId == 0) return _uri; return _tokenURIs[tokenId]; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.8; import "@openzeppelin/contracts-upgradeable/utils/cryptography/draft-EIP712Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/cryptography/ECDSAUpgradeable.sol"; import "./LandNFT_Roles.sol"; /** * @dev Adaptation of OpenZeppelin's ERC20Permit */ contract LandNFT_Authorization is LandNFT_Roles, EIP712Upgradeable { mapping(address => mapping(bytes32 => bool)) internal _authorizationStates; event AuthorizationUsed(address indexed authorizer, bytes32 indexed nonce); // solhint-disable-next-line var-name-mixedcase bytes32 private constant _AUTHORIZATION_TYPEHASH = keccak256("Authorization(address owner,address operator,bool approved,bytes32 nonce,uint256 deadline)"); /** * @dev See {IERC20Permit-permit}. */ function authorize( address owner, address operator, bool approved, bytes32 nonce, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) public onlyOperator { // solhint-disable-next-line not-rely-on-time require(block.timestamp <= deadline, "LandNFT_Authorization: expired deadline"); require( !_authorizationStates[owner][nonce], "LandNFT_Authorization: authorization is used" ); bytes32 structHash = keccak256( abi.encode( _AUTHORIZATION_TYPEHASH, owner, operator, approved, nonce, deadline ) ); bytes32 hash = _hashTypedDataV4(structHash); address signer = ECDSAUpgradeable.recover(hash, v, r, s); require(signer == owner, "LandNFT_Authorization: invalid signature"); _authorizationStates[owner][nonce] = true; _setApprovalForAll(owner, operator, approved); emit AuthorizationUsed(owner, nonce); } function _setApprovalForAll(address owner, address operator, bool approved) internal { require(owner != operator, "ERC1155: setting approval status for self"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } function authorizationState(address authorizer, bytes32 nonce) external view returns (bool) { return _authorizationStates[authorizer][nonce]; } /** * @dev See {IERC20Permit-DOMAIN_SEPARATOR}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32) { return _domainSeparatorV4(); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ECDSAUpgradeable.sol"; import "../../proxy/utils/Initializable.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * _Available since v3.4._ */ abstract contract EIP712Upgradeable is Initializable { /* solhint-disable var-name-mixedcase */ bytes32 private _HASHED_NAME; bytes32 private _HASHED_VERSION; bytes32 private constant _TYPE_HASH = keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ function __EIP712_init(string memory name, string memory version) internal initializer { __EIP712_init_unchained(name, version); } function __EIP712_init_unchained(string memory name, string memory version) internal initializer { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { return _buildDomainSeparator(_TYPE_HASH, _EIP712NameHash(), _EIP712VersionHash()); } function _buildDomainSeparator( bytes32 typeHash, bytes32 nameHash, bytes32 versionHash ) private view returns (bytes32) { return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this))); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return ECDSAUpgradeable.toTypedDataHash(_domainSeparatorV4(), structHash); } /** * @dev The hash of the name parameter for the EIP712 domain. * * NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs * are a concern. */ function _EIP712NameHash() internal virtual view returns (bytes32) { return _HASHED_NAME; } /** * @dev The hash of the version parameter for the EIP712 domain. * * NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs * are a concern. */ function _EIP712VersionHash() internal virtual view returns (bytes32) { return _HASHED_VERSION; } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSAUpgradeable { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } else if (error == RecoverError.InvalidSignatureV) { revert("ECDSA: invalid signature 'v' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { // Check the signature length // - case 65: r,s,v signature (standard) // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._ if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else if (signature.length == 64) { bytes32 r; bytes32 vs; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. assembly { r := mload(add(signature, 0x20)) vs := mload(add(signature, 0x40)) } return tryRecover(hash, r, vs); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s; uint8 v; assembly { s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff) v := add(shr(255, vs), 27) } return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } if (v != 27 && v != 28) { return (address(0), RecoverError.InvalidSignatureV); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { // 32 is the length in bytes of hash, // enforced by the type signature above return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } }
//SPDX-License-Identifier: none pragma solidity ^0.8.8; import "@openzeppelin/contracts-upgradeable/access/AccessControlEnumerableUpgradeable.sol"; import "./ERC1155/extensions/ERC1155BurnableUpgradeable.sol"; import "./ERC1155/extensions/ERC1155PausableUpgradeable.sol"; import "./ERC1155/ERC1155Upgradeable.sol"; contract LandNFT_Roles is ERC1155Upgradeable, AccessControlEnumerableUpgradeable, ERC1155BurnableUpgradeable, ERC1155PausableUpgradeable { bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE"); bytes32 public constant BURNER_ROLE = keccak256("BURNER_ROLE"); bytes32 public constant OPERATOR_ROLE = keccak256("OPERATOR_ROLE"); bytes32 public constant ADMIN_ROLE = keccak256("ADMIN_ROLE"); modifier onlyMinter() { require(hasRole(MINTER_ROLE, _msgSender()), "LandNFT: caller is not a MINTER"); _; } modifier onlyOperator() { require(hasRole(OPERATOR_ROLE, _msgSender()), "LandNFT: caller is not an OPERATOR"); _; } modifier onlyBurner() { require(hasRole(BURNER_ROLE, _msgSender()), "LandNFT: caller is not a BURNER"); _; } modifier onlyAdmin() { require(hasRole(ADMIN_ROLE, _msgSender()), "LandNFT: caller is not an ADMIN"); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(AccessControlEnumerableUpgradeable, ERC1155Upgradeable) returns (bool) { return super.supportsInterface(interfaceId); } function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override(ERC1155Upgradeable, ERC1155PausableUpgradeable) { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed * behind a proxy. Since a proxied contract can't have a constructor, it's common to move constructor logic to an * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect. * * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}. * * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity. */ abstract contract Initializable { /** * @dev Indicates that the contract has been initialized. */ bool private _initialized; /** * @dev Indicates that the contract is in the process of being initialized. */ bool private _initializing; /** * @dev Modifier to protect an initializer function from being invoked twice. */ modifier initializer() { require(_initializing || !_initialized, "Initializable: contract is already initialized"); bool isTopLevelCall = !_initializing; if (isTopLevelCall) { _initializing = true; _initialized = true; } _; if (isTopLevelCall) { _initializing = false; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IAccessControlEnumerableUpgradeable.sol"; import "./AccessControlUpgradeable.sol"; import "../utils/structs/EnumerableSetUpgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Extension of {AccessControl} that allows enumerating the members of each role. */ abstract contract AccessControlEnumerableUpgradeable is Initializable, IAccessControlEnumerableUpgradeable, AccessControlUpgradeable { function __AccessControlEnumerable_init() internal initializer { __Context_init_unchained(); __ERC165_init_unchained(); __AccessControl_init_unchained(); __AccessControlEnumerable_init_unchained(); } function __AccessControlEnumerable_init_unchained() internal initializer { } using EnumerableSetUpgradeable for EnumerableSetUpgradeable.AddressSet; mapping(bytes32 => EnumerableSetUpgradeable.AddressSet) private _roleMembers; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControlEnumerableUpgradeable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns one of the accounts that have `role`. `index` must be a * value between 0 and {getRoleMemberCount}, non-inclusive. * * Role bearers are not sorted in any particular way, and their ordering may * change at any point. * * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure * you perform all queries on the same block. See the following * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post] * for more information. */ function getRoleMember(bytes32 role, uint256 index) public view override returns (address) { return _roleMembers[role].at(index); } /** * @dev Returns the number of accounts that have `role`. Can be used * together with {getRoleMember} to enumerate all bearers of a role. */ function getRoleMemberCount(bytes32 role) public view override returns (uint256) { return _roleMembers[role].length(); } /** * @dev Overload {grantRole} to track enumerable memberships */ function grantRole(bytes32 role, address account) public virtual override(AccessControlUpgradeable, IAccessControlUpgradeable) { super.grantRole(role, account); _roleMembers[role].add(account); } /** * @dev Overload {revokeRole} to track enumerable memberships */ function revokeRole(bytes32 role, address account) public virtual override(AccessControlUpgradeable, IAccessControlUpgradeable) { super.revokeRole(role, account); _roleMembers[role].remove(account); } /** * @dev Overload {renounceRole} to track enumerable memberships */ function renounceRole(bytes32 role, address account) public virtual override(AccessControlUpgradeable, IAccessControlUpgradeable) { super.renounceRole(role, account); _roleMembers[role].remove(account); } /** * @dev Overload {_setupRole} to track enumerable memberships */ function _setupRole(bytes32 role, address account) internal virtual override { super._setupRole(role, account); _roleMembers[role].add(account); } uint256[49] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC1155Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; /** * @dev Extension of {ERC1155} that allows token holders to destroy both their * own tokens and those that they have been approved to use. * * _Available since v3.1._ */ abstract contract ERC1155BurnableUpgradeable is Initializable, ERC1155Upgradeable { function __ERC1155Burnable_init() internal initializer { __Context_init_unchained(); __ERC165_init_unchained(); __ERC1155Burnable_init_unchained(); } function __ERC1155Burnable_init_unchained() internal initializer { } function burn(address account, uint256 id, uint256 value) public virtual { require( account == _msgSender() || isApprovedForAll(account, _msgSender()), "ERC1155: caller is not owner nor approved" ); _burn(account, id, value); } function burnBatch(address account, uint256[] memory ids, uint256[] memory values) public virtual { require( account == _msgSender() || isApprovedForAll(account, _msgSender()), "ERC1155: caller is not owner nor approved" ); _burnBatch(account, ids, values); } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC1155Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/security/PausableUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; /** * @dev ERC1155 token with pausable token transfers, minting and burning. * * Useful for scenarios such as preventing trades until the end of an evaluation * period, or having an emergency switch for freezing all token transfers in the * event of a large bug. * * _Available since v3.1._ */ abstract contract ERC1155PausableUpgradeable is Initializable, ERC1155Upgradeable, PausableUpgradeable { function __ERC1155Pausable_init() internal initializer { __Context_init_unchained(); __ERC165_init_unchained(); __Pausable_init_unchained(); __ERC1155Pausable_init_unchained(); } function __ERC1155Pausable_init_unchained() internal initializer { } /** * @dev See {ERC1155-_beforeTokenTransfer}. * * Requirements: * * - the contract must not be paused. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); require(!paused(), "ERC1155Pausable: token transfer while paused"); } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC1155Upgradeable.sol"; import "./IERC1155ReceiverUpgradeable.sol"; import "./extensions/IERC1155MetadataURIUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol"; import "@openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; /** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */ contract ERC1155Upgradeable is Initializable, ContextUpgradeable, ERC165Upgradeable, IERC1155Upgradeable, IERC1155MetadataURIUpgradeable { using AddressUpgradeable for address; // Mapping from token ID to account balances mapping (uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping (address => mapping(address => bool)) internal _operatorApprovals; // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json string internal _uri; /** * @dev See {_setURI}. */ function __ERC1155_init(string memory uri_) internal initializer { __Context_init_unchained(); __ERC165_init_unchained(); __ERC1155_init_unchained(uri_); } function __ERC1155_init_unchained(string memory uri_) internal initializer { _setURI(uri_); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165Upgradeable, IERC165Upgradeable) returns (bool) { return interfaceId == type(IERC1155Upgradeable).interfaceId || interfaceId == type(IERC1155MetadataURIUpgradeable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the same URI for *all* token types. It relies * on the token type ID substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * Clients calling this function must replace the `\{id\}` substring with the * actual token type ID. */ function uri(uint256) public view virtual override returns (string memory) { return _uri; } /** * @dev See {IERC1155-balanceOf}. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) public view virtual override returns (uint256) { require(account != address(0), "ERC1155: balance query for the zero address"); return _balances[id][account]; } /** * @dev See {IERC1155-balanceOfBatch}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch( address[] memory accounts, uint256[] memory ids ) public view virtual override returns (uint256[] memory) { require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch"); uint256[] memory batchBalances = new uint256[](accounts.length); for (uint256 i = 0; i < accounts.length; ++i) { batchBalances[i] = balanceOf(accounts[i], ids[i]); } return batchBalances; } /** * @dev See {IERC1155-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(_msgSender() != operator, "ERC1155: setting approval status for self"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC1155-isApprovedForAll}. */ function isApprovedForAll(address account, address operator) public view virtual override returns (bool) { return _operatorApprovals[account][operator]; } /** * @dev See {IERC1155-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) public virtual override { require(to != address(0), "ERC1155: transfer to the zero address"); require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not owner nor approved" ); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, _asSingletonArray(id), _asSingletonArray(amount), data); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); _balances[id][from] = fromBalance - amount; _balances[id][to] += amount; emit TransferSingle(operator, from, to, id, amount); _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data); } /** * @dev See {IERC1155-safeBatchTransferFrom}. */ function safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) public virtual override { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zero address"); require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: transfer caller is not owner nor approved" ); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); _balances[id][from] = fromBalance - amount; _balances[id][to] += amount; } emit TransferBatch(operator, from, to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data); } /** * @dev Sets a new URI for all token types, by relying on the token type ID * substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * By this mechanism, any occurrence of the `\{id\}` substring in either the * URI or any of the amounts in the JSON file at said URI will be replaced by * clients with the token type ID. * * For example, the `https://token-cdn-domain/\{id\}.json` URI would be * interpreted by clients as * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json` * for token type ID 0x4cce0. * * See {uri}. * * Because these URIs cannot be meaningfully represented by the {URI} event, * this function emits no events. */ function _setURI(string memory newuri) internal virtual { _uri = newuri; } /** * @dev Creates `amount` tokens of token type `id`, and assigns them to `account`. * * Emits a {TransferSingle} event. * * Requirements: * * - `account` cannot be the zero address. * - If `account` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint(address account, uint256 id, uint256 amount, bytes memory data) internal virtual { require(account != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), account, _asSingletonArray(id), _asSingletonArray(amount), data); _balances[id][account] += amount; emit TransferSingle(operator, address(0), account, id, amount); _doSafeTransferAcceptanceCheck(operator, address(0), account, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _mintBatch(address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); for (uint i = 0; i < ids.length; i++) { _balances[ids[i]][to] += amounts[i]; } emit TransferBatch(operator, address(0), to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data); } /** * @dev Destroys `amount` tokens of token type `id` from `account` * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens of token type `id`. */ function _burn(address account, uint256 id, uint256 amount) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), _asSingletonArray(id), _asSingletonArray(amount), ""); uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); _balances[id][account] = accountBalance - amount; emit TransferSingle(operator, account, address(0), id, amount); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Requirements: * * - `ids` and `amounts` must have the same length. */ function _burnBatch(address account, uint256[] memory ids, uint256[] memory amounts) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), ids, amounts, ""); for (uint i = 0; i < ids.length; i++) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); _balances[id][account] = accountBalance - amount; } emit TransferBatch(operator, account, address(0), ids, amounts); } /** * @dev Hook that is called before any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` and `amount` pair): * * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens * of token type `id` will be transferred to `to`. * - When `from` is zero, `amount` tokens of token type `id` will be minted * for `to`. * - when `to` is zero, `amount` of ``from``'s tokens of token type `id` * will be burned. * - `from` and `to` are never both zero. * - `ids` and `amounts` have the same, non-zero length. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { } function _doSafeTransferAcceptanceCheck( address operator, address from, address to, uint256 id, uint256 amount, bytes memory data ) private { if (to.isContract()) { try IERC1155ReceiverUpgradeable(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) { if (response != IERC1155ReceiverUpgradeable(to).onERC1155Received.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _doSafeBatchTransferAcceptanceCheck( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) private { if (to.isContract()) { try IERC1155ReceiverUpgradeable(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns (bytes4 response) { if (response != IERC1155ReceiverUpgradeable(to).onERC1155BatchReceived.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) { uint256[] memory array = new uint256[](1); array[0] = element; return array; } uint256[47] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IAccessControlUpgradeable.sol"; /** * @dev External interface of AccessControlEnumerable declared to support ERC165 detection. */ interface IAccessControlEnumerableUpgradeable is IAccessControlUpgradeable { /** * @dev Returns one of the accounts that have `role`. `index` must be a * value between 0 and {getRoleMemberCount}, non-inclusive. * * Role bearers are not sorted in any particular way, and their ordering may * change at any point. * * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure * you perform all queries on the same block. See the following * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post] * for more information. */ function getRoleMember(bytes32 role, uint256 index) external view returns (address); /** * @dev Returns the number of accounts that have `role`. Can be used * together with {getRoleMember} to enumerate all bearers of a role. */ function getRoleMemberCount(bytes32 role) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IAccessControlUpgradeable.sol"; import "../utils/ContextUpgradeable.sol"; import "../utils/StringsUpgradeable.sol"; import "../utils/introspection/ERC165Upgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControlUpgradeable is Initializable, ContextUpgradeable, IAccessControlUpgradeable, ERC165Upgradeable { function __AccessControl_init() internal initializer { __Context_init_unchained(); __ERC165_init_unchained(); __AccessControl_init_unchained(); } function __AccessControl_init_unchained() internal initializer { } struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role, _msgSender()); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControlUpgradeable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", StringsUpgradeable.toHexString(uint160(account), 20), " is missing role ", StringsUpgradeable.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } function _grantRole(bytes32 role, address account) private { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } function _revokeRole(bytes32 role, address account) private { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } uint256[49] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Library for managing * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive * types. * * Sets have the following properties: * * - Elements are added, removed, and checked for existence in constant time * (O(1)). * - Elements are enumerated in O(n). No guarantees are made on the ordering. * * ``` * contract Example { * // Add the library methods * using EnumerableSet for EnumerableSet.AddressSet; * * // Declare a set state variable * EnumerableSet.AddressSet private mySet; * } * ``` * * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`) * and `uint256` (`UintSet`) are supported. */ library EnumerableSetUpgradeable { // To implement this library for multiple types with as little code // repetition as possible, we write it in terms of a generic Set type with // bytes32 values. // The Set implementation uses private functions, and user-facing // implementations (such as AddressSet) are just wrappers around the // underlying Set. // This means that we can only create new EnumerableSets for types that fit // in bytes32. struct Set { // Storage of set values bytes32[] _values; // Position of the value in the `values` array, plus 1 because index 0 // means a value is not in the set. mapping(bytes32 => uint256) _indexes; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function _add(Set storage set, bytes32 value) private returns (bool) { if (!_contains(set, value)) { set._values.push(value); // The value is stored at length-1, but we add 1 to all indexes // and use 0 as a sentinel value set._indexes[value] = set._values.length; return true; } else { return false; } } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function _remove(Set storage set, bytes32 value) private returns (bool) { // We read and store the value's index to prevent multiple reads from the same storage slot uint256 valueIndex = set._indexes[value]; if (valueIndex != 0) { // Equivalent to contains(set, value) // To delete an element from the _values array in O(1), we swap the element to delete with the last one in // the array, and then remove the last element (sometimes called as 'swap and pop'). // This modifies the order of the array, as noted in {at}. uint256 toDeleteIndex = valueIndex - 1; uint256 lastIndex = set._values.length - 1; if (lastIndex != toDeleteIndex) { bytes32 lastvalue = set._values[lastIndex]; // Move the last value to the index where the value to delete is set._values[toDeleteIndex] = lastvalue; // Update the index for the moved value set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored set._values.pop(); // Delete the index for the deleted slot delete set._indexes[value]; return true; } else { return false; } } /** * @dev Returns true if the value is in the set. O(1). */ function _contains(Set storage set, bytes32 value) private view returns (bool) { return set._indexes[value] != 0; } /** * @dev Returns the number of values on the set. O(1). */ function _length(Set storage set) private view returns (uint256) { return set._values.length; } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function _at(Set storage set, uint256 index) private view returns (bytes32) { return set._values[index]; } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function _values(Set storage set) private view returns (bytes32[] memory) { return set._values; } // Bytes32Set struct Bytes32Set { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _add(set._inner, value); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) { return _remove(set._inner, value); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) { return _contains(set._inner, value); } /** * @dev Returns the number of values in the set. O(1). */ function length(Bytes32Set storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) { return _at(set._inner, index); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(Bytes32Set storage set) internal view returns (bytes32[] memory) { return _values(set._inner); } // AddressSet struct AddressSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(AddressSet storage set, address value) internal returns (bool) { return _add(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(AddressSet storage set, address value) internal returns (bool) { return _remove(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(AddressSet storage set, address value) internal view returns (bool) { return _contains(set._inner, bytes32(uint256(uint160(value)))); } /** * @dev Returns the number of values in the set. O(1). */ function length(AddressSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(AddressSet storage set, uint256 index) internal view returns (address) { return address(uint160(uint256(_at(set._inner, index)))); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(AddressSet storage set) internal view returns (address[] memory) { bytes32[] memory store = _values(set._inner); address[] memory result; assembly { result := store } return result; } // UintSet struct UintSet { Set _inner; } /** * @dev Add a value to a set. O(1). * * Returns true if the value was added to the set, that is if it was not * already present. */ function add(UintSet storage set, uint256 value) internal returns (bool) { return _add(set._inner, bytes32(value)); } /** * @dev Removes a value from a set. O(1). * * Returns true if the value was removed from the set, that is if it was * present. */ function remove(UintSet storage set, uint256 value) internal returns (bool) { return _remove(set._inner, bytes32(value)); } /** * @dev Returns true if the value is in the set. O(1). */ function contains(UintSet storage set, uint256 value) internal view returns (bool) { return _contains(set._inner, bytes32(value)); } /** * @dev Returns the number of values on the set. O(1). */ function length(UintSet storage set) internal view returns (uint256) { return _length(set._inner); } /** * @dev Returns the value stored at position `index` in the set. O(1). * * Note that there are no guarantees on the ordering of values inside the * array, and it may change when more values are added or removed. * * Requirements: * * - `index` must be strictly less than {length}. */ function at(UintSet storage set, uint256 index) internal view returns (uint256) { return uint256(_at(set._inner, index)); } /** * @dev Return the entire set in an array * * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that * this function has an unbounded cost, and using it as part of a state-changing function may render the function * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. */ function values(UintSet storage set) internal view returns (uint256[] memory) { bytes32[] memory store = _values(set._inner); uint256[] memory result; assembly { result := store } return result; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControlUpgradeable { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../proxy/utils/Initializable.sol"; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract ContextUpgradeable is Initializable { function __Context_init() internal initializer { __Context_init_unchained(); } function __Context_init_unchained() internal initializer { } function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev String operations. */ library StringsUpgradeable { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165Upgradeable.sol"; import "../../proxy/utils/Initializable.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165Upgradeable is Initializable, IERC165Upgradeable { function __ERC165_init() internal initializer { __ERC165_init_unchained(); } function __ERC165_init_unchained() internal initializer { } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165Upgradeable).interfaceId; } uint256[50] private __gap; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165Upgradeable { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts-upgradeable/utils/introspection/IERC165Upgradeable.sol"; /** * @dev Required interface of an ERC1155 compliant contract, as defined in the * https://eips.ethereum.org/EIPS/eip-1155[EIP]. * * _Available since v3.1._ */ interface IERC1155Upgradeable is IERC165Upgradeable { /** * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`. */ event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value); /** * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all * transfers. */ event TransferBatch(address indexed operator, address indexed from, address indexed to, uint256[] ids, uint256[] values); /** * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to * `approved`. */ event ApprovalForAll(address indexed account, address indexed operator, bool approved); /** * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI. * * If an {URI} event was emitted for `id`, the standard * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value * returned by {IERC1155MetadataURI-uri}. */ event URI(string value, uint256 indexed id); /** * @dev Returns the amount of tokens of token type `id` owned by `account`. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) external view returns (uint256); /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids) external view returns (uint256[] memory); /** * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`, * * Emits an {ApprovalForAll} event. * * Requirements: * * - `operator` cannot be the caller. */ function setApprovalForAll(address operator, bool approved) external; /** * @dev Returns true if `operator` is approved to transfer ``account``'s tokens. * * See {setApprovalForAll}. */ function isApprovedForAll(address account, address operator) external view returns (bool); /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If the caller is not `from`, it must be have been approved to spend ``from``'s tokens via {setApprovalForAll}. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function safeTransferFrom(address from, address to, uint256 id, uint256 amount, bytes calldata data) external; /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function safeBatchTransferFrom(address from, address to, uint256[] calldata ids, uint256[] calldata amounts, bytes calldata data) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "@openzeppelin/contracts-upgradeable/utils/introspection/IERC165Upgradeable.sol"; /** * @dev _Available since v3.1._ */ interface IERC1155ReceiverUpgradeable is IERC165Upgradeable { /** @dev Handles the receipt of a single ERC1155 token type. This function is called at the end of a `safeTransferFrom` after the balance has been updated. To accept the transfer, this must return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` (i.e. 0xf23a6e61, or its own function selector). @param operator The address which initiated the transfer (i.e. msg.sender) @param from The address which previously owned the token @param id The ID of the token being transferred @param value The amount of tokens being transferred @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed */ function onERC1155Received( address operator, address from, uint256 id, uint256 value, bytes calldata data ) external returns(bytes4); /** @dev Handles the receipt of a multiple ERC1155 token types. This function is called at the end of a `safeBatchTransferFrom` after the balances have been updated. To accept the transfer(s), this must return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` (i.e. 0xbc197c81, or its own function selector). @param operator The address which initiated the batch transfer (i.e. msg.sender) @param from The address which previously owned the token @param ids An array containing ids of each token being transferred (order and length must match values array) @param values An array containing amounts of each token being transferred (order and length must match ids array) @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed */ function onERC1155BatchReceived( address operator, address from, uint256[] calldata ids, uint256[] calldata values, bytes calldata data ) external returns(bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC1155Upgradeable.sol"; /** * @dev Interface of the optional ERC1155MetadataExtension interface, as defined * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP]. * * _Available since v3.1._ */ interface IERC1155MetadataURIUpgradeable is IERC1155Upgradeable { /** * @dev Returns the URI for token type `id`. * * If the `\{id\}` substring is present in the URI, it must be replaced by * clients with the actual token type ID. */ function uri(uint256 id) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library AddressUpgradeable { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/ContextUpgradeable.sol"; import "../proxy/utils/Initializable.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract PausableUpgradeable is Initializable, ContextUpgradeable { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ function __Pausable_init() internal initializer { __Context_init_unchained(); __Pausable_init_unchained(); } function __Pausable_init_unchained() internal initializer { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } uint256[49] private __gap; }
{ "optimizer": { "enabled": true, "runs": 200000, "details": { "yul": false } }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"authorizer","type":"address"},{"indexed":true,"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"AuthorizationUsed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"components":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"totalHectares","type":"uint256"},{"internalType":"uint256","name":"totalSupply","type":"uint256"},{"internalType":"uint256","name":"inflationCooldownPeriod","type":"uint256"},{"internalType":"uint256","name":"nextInflationAt","type":"uint256"},{"internalType":"enum MossLandNFT.ProjectType","name":"projectType","type":"uint8"},{"internalType":"bool","name":"created","type":"bool"}],"indexed":false,"internalType":"struct MossLandNFT.Project","name":"project","type":"tuple"}],"name":"ProjectAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"ratio","type":"uint256"},{"indexed":false,"internalType":"address","name":"sender","type":"address"}],"name":"TokenInflation","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BURNER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"HECTARE_TOKEN_INFLATION_RATE_FACTOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OPERATOR_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"string","name":"cid","type":"string"},{"internalType":"uint256","name":"hectares","type":"uint256"},{"internalType":"uint256","name":"cooldown","type":"uint256"},{"internalType":"enum MossLandNFT.ProjectType","name":"projectType","type":"uint8"}],"name":"addProject","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"authorizer","type":"address"},{"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"authorizationState","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"},{"internalType":"bytes32","name":"nonce","type":"bytes32"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"authorize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"}],"name":"balancesOf","outputs":[{"internalType":"uint256[]","name":"tokens","type":"uint256[]"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"burnBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"description","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getRegisteredTokens","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"hectaresBalanceOf","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"},{"internalType":"uint256","name":"totalSupply","type":"uint256"},{"internalType":"uint256","name":"totalHectares","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"projectId","type":"uint256"},{"internalType":"uint256","name":"increase","type":"uint256"}],"name":"inflate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"__uri","type":"string"},{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"},{"internalType":"string","name":"_description","type":"string"},{"internalType":"address","name":"_owner","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"isRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"projects","outputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"totalHectares","type":"uint256"},{"internalType":"uint256","name":"totalSupply","type":"uint256"},{"internalType":"uint256","name":"inflationCooldownPeriod","type":"uint256"},{"internalType":"uint256","name":"nextInflationAt","type":"uint256"},{"internalType":"enum MossLandNFT.ProjectType","name":"projectType","type":"uint8"},{"internalType":"bool","name":"created","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newOwner","type":"address"}],"name":"setOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tokenIds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"string","name":"cid","type":"string"}],"name":"updateTokenURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b50615e9480620000216000396000f3fe608060405234801561001057600080fd5b50600436106102dd5760003560e01c80636b20c45411610186578063bc706774116100e3578063d58778d611610097578063f242432a11610071578063f242432a1461073d578063f5298aca14610750578063f5b541a61461076357600080fd5b8063d58778d61461069a578063e94a0102146106ad578063e985e9c5146106f457600080fd5b8063d2f33110116100c8578063d2f331101461063e578063d539139314610660578063d547741f1461068757600080fd5b8063bc70677414610618578063ca15c8731461062b57600080fd5b806391d148541161013a578063979518921161011f57806397951892146105ea578063a217fddf146105fd578063a22cb4651461060557600080fd5b806391d148541461059c57806395d89b41146105e257600080fd5b806375b238fc1161016b57806375b238fc146105345780638da5cb5b1461055b5780639010d07c1461058957600080fd5b80636b20c454146105195780637284e4161461052c57600080fd5b80632a9383421161023f57806336568abe116101f35780635add6537116101cd5780635add6537146104e35780635c975abb146104ec5780636392a51f146104f857600080fd5b806336568abe146104915780634e1273f4146104a4578063579a6988146104b757600080fd5b80632eb2c2d6116102245780632eb2c2d6146104635780632f2ff15d146104765780633644e5151461048957600080fd5b80632a9383421461043d5780632e6400241461045057600080fd5b806313af40351161029657806318e97fd11161027b57806318e97fd1146103e0578063248a9ca3146103f3578063282c51f31461041657600080fd5b806313af4035146103b657806314cbd993146103cb57600080fd5b806306fdde03116102c757806306fdde031461032b5780630e89341c14610340578063107046bd1461035357600080fd5b8062fdd58e146102e257806301ffc9a71461030b575b600080fd5b6102f56102f0366004613d35565b61078a565b6040516103029190613d7a565b60405180910390f35b61031e610319366004613dbb565b61081a565b6040516103029190613de4565b610333610825565b6040516103029190613e72565b61033361034e366004613e83565b6108b4565b6103a3610361366004613e83565b6101cb60205260009081526040902080546001820154600283015460038401546004850154600590950154939492939192909160ff8082169161010090041687565b6040516103029796959493929190613f06565b6103c96103c4366004613f6e565b6108bf565b005b6103d36109fc565b6040516103029190613fec565b6103c96103ee366004614140565b610a55565b6102f5610401366004613e83565b60009081526065602052604090206001015490565b6102f57f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84881565b6103c961044b36600461418e565b610b14565b6103c961045e366004614202565b610d1b565b6103c9610471366004614399565b610fe2565b6103c9610484366004614462565b6112fc565b6102f5611323565b6103c961049f366004614462565b611332565b6103d36104b236600461450a565b611354565b61031e6104c5366004613e83565b60009081526101cb6020526040902060050154610100900460ff1690565b6102f561271081565b61012d5460ff1661031e565b61050b610506366004613f6e565b611456565b604051610302929190614572565b6103c96105273660046145e2565b611548565b610333611690565b6102f57fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177581565b6101c95461057c9073ffffffffffffffffffffffffffffffffffffffff1681565b604051610302919061467b565b61057c61059736600461418e565b61169e565b61031e6105aa366004614462565b600091825260656020908152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b6103336116bd565b6103c96105f83660046146a1565b6116cb565b6102f5600081565b6103c961061336600461474a565b611a0d565b6103c9610626366004614791565b611af7565b6102f5610639366004613e83565b611d89565b61065161064c366004613d35565b611da0565b60405161030293929190614844565b6102f57f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6103c9610695366004614462565b611dd5565b6102f56106a8366004613e83565b611ddf565b61031e6106bb366004613d35565b73ffffffffffffffffffffffffffffffffffffffff9190911660009081526101c560209081526040808320938352929052205460ff1690565b61031e61070236600461486c565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260986020908152604080832093909416825291909152205460ff1690565b6103c961074b36600461488e565b611e01565b6103c961075e3660046148e8565b612027565b6102f57f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b92981565b600073ffffffffffffffffffffffffffffffffffffffff83166107e2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614995565b60405180910390fd5b50600081815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff861684529091529020545b92915050565b6000610814826120be565b6101c68054610833906149d4565b80601f016020809104026020016040519081016040528092919081815260200182805461085f906149d4565b80156108ac5780601f10610881576101008083540402835291602001916108ac565b820191906000526020600020905b81548152906001019060200180831161088f57829003601f168201915b505050505081565b606061081482612114565b6108e97fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775336105aa565b61091f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a38565b73ffffffffffffffffffffffffffffffffffffffff811661096c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a7c565b6101c95460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36101c980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60606101ca805480602002602001604051908101604052809291908181526020018280548015610a4b57602002820191906000526020600020905b815481526020019060010190808311610a37575b5050505050905090565b610a7f7fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775336105aa565b610ab5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a38565b60008281526101cb6020526040902060050154610100900460ff16610b06576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ac0565b610b1082826121c7565b5050565b610b3e7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6336105aa565b610b74576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b04565b60008281526101cb602052604090206005810154610100900460ff16610bc6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b48565b81610bfd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614bb2565b80600401544211610c3a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614c1c565b6000612710838360020154610c4f9190614c5b565b610c599190614cc7565b905080826002016000828254610c6f9190614cdb565b909155505060038201546004830154610c889190614cdb565b826004016000828254610c9b9190614cdb565b90915550610cda905033858360005b6040519080825280601f01601f191660200182016040528015610cd4576020820181803683370190505b5061227a565b7fadf79fc7a670e099524b7ec65630a87db4c692ea399a4cc07d5b3c0fff3e3086848233604051610d0d93929190614cf3565b60405180910390a150505050565b600054610100900460ff1680610d34575060005460ff16155b610d6a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff16158015610da957600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b610de88a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506123b392505050565b610e5c6040518060400160405280600781526020017f4c616e644e4654000000000000000000000000000000000000000000000000008152506040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525061248c565b610e867f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633612557565b610eb07f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84833612557565b610eda7f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b92933612557565b610f047fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533612557565b610f0f600033612557565b610f1c6101c68989613bbc565b50610f2a6101c78787613bbc565b50610f386101c88585613bbc565b506101c980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff841617905560405133906000907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a38015610fd657600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b50505050505050505050565b815183511461101d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ddf565b73ffffffffffffffffffffffffffffffffffffffff841661106a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614e49565b73ffffffffffffffffffffffffffffffffffffffff851633148061109357506110938533610702565b6110c9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614eb3565b336110d8818787878787612561565b60005b84518110156112675760008582815181106110f8576110f8614ec3565b60200260200101519050600085838151811061111657611116614ec3565b602090810291909101810151600084815260978352604080822073ffffffffffffffffffffffffffffffffffffffff8e16835290935291909120549091508181101561118e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614f4c565b6111988282614f5c565b6097600085815260200190815260200160002060008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816097600085815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825461124c9190614cdb565b925050819055505050508061126090614f73565b90506110db565b508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb87876040516112de929190614572565b60405180910390a46112f481878787878761256f565b505050505050565b611306828261275d565b600082815260c96020526040902061131e9082612783565b505050565b600061132d6127a5565b905090565b61133c82826127de565b600082815260c96020526040902061131e9082612837565b60608151835114611391576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615006565b6000835167ffffffffffffffff8111156113ad576113ad613ffd565b6040519080825280602002602001820160405280156113d6578160200160208202803683370190505b50905060005b845181101561144e576114218582815181106113fa576113fa614ec3565b602002602001015185838151811061141457611414614ec3565b602002602001015161078a565b82828151811061143357611433614ec3565b602090810291909101015261144781614f73565b90506113dc565b509392505050565b6060806101ca8054806020026020016040519081016040528092919081815260200182805480156114a657602002820191906000526020600020905b815481526020019060010190808311611492575b50505050509150815167ffffffffffffffff8111156114c7576114c7613ffd565b6040519080825280602002602001820160405280156114f0578160200160208202803683370190505b50905060005b8251811015611542576115158484838151811061141457611414614ec3565b82828151811061152757611527614ec3565b602090810291909101015261153b81614f73565b90506114f6565b50915091565b6115727f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a848336105aa565b6115a8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061504a565b611616858585808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080890282810182019093528882529093508892508791829185019084908082843760009201919091525061285992505050565b60005b838110156112f45782828281811061163357611633614ec3565b905060200201356101cb600087878581811061165157611651614ec3565b90506020020135815260200190815260200160002060020160008282546116789190614f5c565b9091555081905061168881614f73565b915050611619565b6101c88054610833906149d4565b600082815260c9602052604081206116b69083612a93565b9392505050565b6101c78054610833906149d4565b6116f57f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6336105aa565b61172b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b04565b60008311611765576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061508e565b6000821161179f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906150d0565b836117d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615114565b60008681526101cb6020526040902060050154610100900460ff1615611828576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615158565b6101ca80546001810182556000919091527f0faeda9012b7f59bd2a84ac2a33ead5fc9f720c38d8bbf90db1ac3c1518386eb018690556040805160e08101825287815260208101859052908101849052606081018390526080810161188d8442614cdb565b81526020018260018111156118a4576118a4613ea4565b81526001602091820181905260008981526101cb83526040908190208451815592840151838301558301516002830155606083015160038301556080830151600483015560a0830151600583018054919290917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690838181111561192b5761192b613ea4565b021790555060c0919091015160059091018054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905561197c3387856000610caa565b6119bc8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506121c792505050565b60008681526101cb60205260409081902090517fca8ddcb55f768e292deb4557a3c1f262532d0c7d84e281b47b74614957059c58916119fd91339190615251565b60405180910390a1505050505050565b3373ffffffffffffffffffffffffffffffffffffffff83161415611a5d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906152c7565b33600081815260986020908152604080832073ffffffffffffffffffffffffffffffffffffffff871680855292529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001685151517905590519091907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190611aeb908590613de4565b60405180910390a35050565b611b217f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929336105aa565b611b57576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615331565b83421115611b91576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061539b565b73ffffffffffffffffffffffffffffffffffffffff881660009081526101c56020908152604080832088845290915290205460ff1615611bfd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615405565b60007f91aaffcde7eb6e14c35a5d629a51978795daafb7f3caeeaad4d913ed8d322c568989898989604051602001611c3a96959493929190615415565b6040516020818303038152906040528051906020012090506000611c5d82612a9f565b90506000611c6d82878787612ab2565b90508a73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614611cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906154c9565b73ffffffffffffffffffffffffffffffffffffffff8b1660009081526101c5602090815260408083208b8452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055611d398b8b8b612adc565b604051889073ffffffffffffffffffffffffffffffffffffffff8d16907f98de503528ee59b575ef0c0a2576a82497bfc029a5685b209e9ec333479b10a590600090a35050505050505050505050565b600081815260c96020526040812061081490612bde565b6000806000611daf858561078a565b60009485526101cb60205260409094206002810154600190910154949690955092505050565b61133c8282612be8565b6101ca8181548110611df057600080fd5b600091825260209091200154905081565b73ffffffffffffffffffffffffffffffffffffffff8416611e4e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614e49565b73ffffffffffffffffffffffffffffffffffffffff8516331480611e775750611e778533610702565b611ead576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615533565b33611ecc818787611ebd88612c0e565b611ec688612c0e565b87612561565b600084815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8a16845290915290205483811015611f36576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614f4c565b611f408482614f5c565b600086815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8c81168552925280832093909355881681529081208054869290611f8b908490614cdb565b925050819055508573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628888604051612008929190615543565b60405180910390a461201e828888888888612c59565b50505050505050565b6120517f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a848336105aa565b612087576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061504a565b612092838383612dbf565b60008281526101cb6020526040812060020180548392906120b4908490614f5c565b9091555050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f5a05180f000000000000000000000000000000000000000000000000000000001480610814575061081482612f2c565b6060816121ad5760998054612128906149d4565b80601f0160208091040260200160405190810160405280929190818152602001828054612154906149d4565b80156121a15780601f10612176576101008083540402835291602001916121a1565b820191906000526020600020905b81548152906001019060200180831161218457829003601f168201915b50505050509050919050565b60008281526101cc602052604090208054612128906149d4565b6099816040516020016121db92919061560c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815260008481526101cc6020908152919020825161222a93919290910190613c5e565b50817f6bb7ff708619ba0610cba295a58592e0451dee2622938c8755667688daf3529b6101cc600085815260200190815260200160002060405161226e91906156b6565b60405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff84166122c7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615721565b336122d881600087611ebd88612c0e565b600084815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8916845290915281208054859290612317908490614cdb565b925050819055508473ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628787604051612395929190615543565b60405180910390a46123ac81600087878787612c59565b5050505050565b600054610100900460ff16806123cc575060005460ff16155b612402576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561244157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b612449612fce565b612451612fce565b61245a8261308e565b8015610b1057600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555050565b600054610100900460ff16806124a5575060005460ff16155b6124db576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561251a57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b6125248383613125565b801561131e57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055505050565b6113068282613205565b6112f486868686868661320f565b73ffffffffffffffffffffffffffffffffffffffff84163b156112f4576040517fbc197c8100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063bc197c81906125e69089908990889088908890600401615731565b602060405180830381600087803b15801561260057600080fd5b505af192505050801561264e575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261264b91810190615791565b60015b6126e25761265a6157b2565b806308c379a014156126ae575061266f6157cd565b8061267a57506126b0565b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99190613e72565b505b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906158ae565b7fffffffff0000000000000000000000000000000000000000000000000000000081167fbc197c81000000000000000000000000000000000000000000000000000000001461201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615918565b600082815260656020526040902060010154612779813361324d565b61131e838361331f565b60006116b68373ffffffffffffffffffffffffffffffffffffffff8416613413565b600061132d7f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6127d56101915490565b61019254613462565b73ffffffffffffffffffffffffffffffffffffffff8116331461282d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615982565b610b10828261349c565b60006116b68373ffffffffffffffffffffffffffffffffffffffff8416613557565b73ffffffffffffffffffffffffffffffffffffffff83166128a6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906159ec565b80518251146128e1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ddf565b600033905061290481856000868660405180602001604052806000815250612561565b60005b8351811015612a0d57600084828151811061292457612924614ec3565b60200260200101519050600084838151811061294257612942614ec3565b602090810291909101810151600084815260978352604080822073ffffffffffffffffffffffffffffffffffffffff8c1683529093529190912054909150818110156129ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615a56565b6129c48282614f5c565b600093845260976020908152604080862073ffffffffffffffffffffffffffffffffffffffff8c1687529091529093209290925550819050612a0581614f73565b915050612907565b50600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051612a85929190614572565b60405180910390a450505050565b60006116b6838361364a565b6000610814612aac6127a5565b83613674565b6000806000612ac3878787876136a7565b91509150612ad0816137b2565b5090505b949350505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612b42576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906152c7565b73ffffffffffffffffffffffffffffffffffffffff8381166000818152609860209081526040808320948716808452949091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016851515179055517f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190612bd1908590613de4565b60405180910390a3505050565b6000610814825490565b600082815260656020526040902060010154612c04813361324d565b61131e838361349c565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110612c4857612c48614ec3565b602090810291909101015292915050565b73ffffffffffffffffffffffffffffffffffffffff84163b156112f4576040517ff23a6e6100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063f23a6e6190612cd09089908990889088908890600401615a66565b602060405180830381600087803b158015612cea57600080fd5b505af1925050508015612d38575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252612d3591810190615791565b60015b612d445761265a6157b2565b7fffffffff0000000000000000000000000000000000000000000000000000000081167ff23a6e61000000000000000000000000000000000000000000000000000000001461201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615918565b73ffffffffffffffffffffffffffffffffffffffff8316612e0c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906159ec565b33612e3b81856000612e1d87612c0e565b612e2687612c0e565b60405180602001604052806000815250612561565b600083815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8816845290915290205482811015612ea5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615a56565b612eaf8382614f5c565b600085815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff808b16808652919093528184209490945551919291908516907fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6290612f1d9089908990615543565b60405180910390a45050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fd9b67a26000000000000000000000000000000000000000000000000000000001480612fbf57507fffffffff0000000000000000000000000000000000000000000000000000000082167f0e89341c00000000000000000000000000000000000000000000000000000000145b806108145750610814826138ff565b600054610100900460ff1680612fe7575060005460ff16155b61301d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561305c57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b801561308b57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b50565b600054610100900460ff16806130a7575060005460ff16155b6130dd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561311c57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b61245a82613996565b600054610100900460ff168061313e575060005460ff16155b613174576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff161580156131b357600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b82516020808501919091208351918401919091206101919190915561019255801561131e57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055505050565b610b10828261331f565b61012d5460ff16156112f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615b07565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610b10576132a58173ffffffffffffffffffffffffffffffffffffffff1660146139a9565b6132b08360206139a9565b6040516020016132c1929190615b17565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f08c379a00000000000000000000000000000000000000000000000000000000082526107d991600401613e72565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610b1057600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556133b53390565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b600081815260018301602052604081205461345a57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610814565b506000610814565b6000838383463060405160200161347d959493929190615b77565b6040516020818303038152906040528051906020012090509392505050565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff1615610b1057600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000818152600183016020526040812054801561364057600061357b600183614f5c565b855490915060009061358f90600190614f5c565b90508181146135f45760008660000182815481106135af576135af614ec3565b90600052602060002001549050808760000184815481106135d2576135d2614ec3565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061360557613605615bc3565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610814565b6000915050610814565b600082600001828154811061366157613661614ec3565b9060005260206000200154905092915050565b60008282604051602001613689929190615bf8565b60405160208183030381529060405280519060200120905092915050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156136de57506000905060036137a9565b8460ff16601b141580156136f657508460ff16601c14155b1561370757506000905060046137a9565b60006001878787876040516000815260200160405260405161372c9493929190615c4d565b6020604051602081039080840390855afa15801561374e573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166137a2576000600192509250506137a9565b9150600090505b94509492505050565b60008160048111156137c6576137c6613ea4565b14156137cf5750565b60018160048111156137e3576137e3613ea4565b141561381b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615cbf565b600281600481111561382f5761382f613ea4565b1415613867576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615d03565b600381600481111561387b5761387b613ea4565b14156138b3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615d6d565b60048160048111156138c7576138c7613ea4565b141561308b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615dd7565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b00000000000000000000000000000000000000000000000000000000148061081457507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610814565b8051610b10906099906020840190613c5e565b606060006139b8836002614c5b565b6139c3906002614cdb565b67ffffffffffffffff8111156139db576139db613ffd565b6040519080825280601f01601f191660200182016040528015613a05576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110613a3c57613a3c614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110613a9f57613a9f614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506000613adb846002614c5b565b613ae6906001614cdb565b90505b6001811115613b83577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110613b2757613b27614ec3565b1a60f81b828281518110613b3d57613b3d614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060049490941c93613b7c81615de7565b9050613ae9565b5083156116b6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615e4e565b828054613bc8906149d4565b90600052602060002090601f016020900481019282613bea5760008555613c4e565b82601f10613c21578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00823516178555613c4e565b82800160010185558215613c4e579182015b82811115613c4e578235825591602001919060010190613c33565b50613c5a929150613cd2565b5090565b828054613c6a906149d4565b90600052602060002090601f016020900481019282613c8c5760008555613c4e565b82601f10613ca557805160ff1916838001178555613c4e565b82800160010185558215613c4e579182015b82811115613c4e578251825591602001919060010190613cb7565b5b80821115613c5a5760008155600101613cd3565b600073ffffffffffffffffffffffffffffffffffffffff8216610814565b613d0e81613ce7565b811461308b57600080fd5b803561081481613d05565b80613d0e565b803561081481613d24565b60008060408385031215613d4b57613d4b600080fd5b6000613d578585613d19565b9250506020613d6885828601613d2a565b9150509250929050565b805b82525050565b602081016108148284613d72565b7fffffffff000000000000000000000000000000000000000000000000000000008116613d0e565b803561081481613d88565b600060208284031215613dd057613dd0600080fd5b6000612ad48484613db0565b801515613d74565b602081016108148284613ddc565b60005b83811015613e0d578181015183820152602001613df5565b83811115613e1c576000848401525b50505050565b6000613e2c825190565b808452602084019350613e43818560208601613df2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920192915050565b602080825281016116b68184613e22565b600060208284031215613e9857613e98600080fd5b6000612ad48484613d2a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6002811061308b5761308b613ea4565b80613eed81613ed3565b919050565b600061081482613ee3565b613d7481613ef2565b60e08101613f14828a613d72565b613f216020830189613d72565b613f2e6040830188613d72565b613f3b6060830187613d72565b613f486080830186613d72565b613f5560a0830185613efd565b613f6260c0830184613ddc565b98975050505050505050565b600060208284031215613f8357613f83600080fd5b6000612ad48484613d19565b6000613f9b8383613d72565b505060200190565b6000613fad825190565b80845260209384019383018060005b83811015613fe1578151613fd08882613f8f565b975060208301925050600101613fbc565b509495945050505050565b602080825281016116b68184613fa3565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116810181811067ffffffffffffffff8211171561407057614070613ffd565b6040525050565b600061408260405190565b9050613eed828261402c565b600067ffffffffffffffff8211156140a8576140a8613ffd565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011660200192915050565b82818337506000910152565b60006140f66140f18461408e565b614077565b90508281526020810184848401111561411157614111600080fd5b61144e8482856140d7565b600082601f83011261413057614130600080fd5b8135612ad48482602086016140e3565b6000806040838503121561415657614156600080fd5b60006141628585613d2a565b925050602083013567ffffffffffffffff81111561418257614182600080fd5b613d688582860161411c565b600080604083850312156141a4576141a4600080fd5b6000613d578585613d2a565b60008083601f8401126141c5576141c5600080fd5b50813567ffffffffffffffff8111156141e0576141e0600080fd5b6020830191508360018202830111156141fb576141fb600080fd5b9250929050565b600080600080600080600080600060a08a8c03121561422357614223600080fd5b893567ffffffffffffffff81111561423d5761423d600080fd5b6142498c828d016141b0565b995099505060208a013567ffffffffffffffff81111561426b5761426b600080fd5b6142778c828d016141b0565b975097505060408a013567ffffffffffffffff81111561429957614299600080fd5b6142a58c828d016141b0565b955095505060608a013567ffffffffffffffff8111156142c7576142c7600080fd5b6142d38c828d016141b0565b935093505060806142e68c828d01613d19565b9150509295985092959850929598565b600067ffffffffffffffff82111561431057614310613ffd565b5060209081020190565b60006143286140f1846142f6565b8381529050602080820190840283018581111561434757614347600080fd5b835b8181101561436b578061435c8882613d2a565b84525060209283019201614349565b5050509392505050565b600082601f83011261438957614389600080fd5b8135612ad484826020860161431a565b600080600080600060a086880312156143b4576143b4600080fd5b60006143c08888613d19565b95505060206143d188828901613d19565b945050604086013567ffffffffffffffff8111156143f1576143f1600080fd5b6143fd88828901614375565b935050606086013567ffffffffffffffff81111561441d5761441d600080fd5b61442988828901614375565b925050608086013567ffffffffffffffff81111561444957614449600080fd5b6144558882890161411c565b9150509295509295909350565b6000806040838503121561447857614478600080fd5b60006144848585613d2a565b9250506020613d6885828601613d19565b60006144a36140f1846142f6565b838152905060208082019084028301858111156144c2576144c2600080fd5b835b8181101561436b57806144d78882613d19565b845250602092830192016144c4565b600082601f8301126144fa576144fa600080fd5b8135612ad4848260208601614495565b6000806040838503121561452057614520600080fd5b823567ffffffffffffffff81111561453a5761453a600080fd5b614546858286016144e6565b925050602083013567ffffffffffffffff81111561456657614566600080fd5b613d6885828601614375565b604080825281016145838185613fa3565b90508181036020830152612ad48184613fa3565b60008083601f8401126145ac576145ac600080fd5b50813567ffffffffffffffff8111156145c7576145c7600080fd5b6020830191508360208202830111156141fb576141fb600080fd5b6000806000806000606086880312156145fd576145fd600080fd5b60006146098888613d19565b955050602086013567ffffffffffffffff81111561462957614629600080fd5b61463588828901614597565b9450945050604086013567ffffffffffffffff81111561465757614657600080fd5b61466388828901614597565b92509250509295509295909350565b613d7481613ce7565b602081016108148284614672565b6002811061308b57600080fd5b803561081481614689565b60008060008060008060a087890312156146bd576146bd600080fd5b60006146c98989613d2a565b965050602087013567ffffffffffffffff8111156146e9576146e9600080fd5b6146f589828a016141b0565b9550955050604061470889828a01613d2a565b935050606061471989828a01613d2a565b925050608061472a89828a01614696565b9150509295509295509295565b801515613d0e565b803561081481614737565b6000806040838503121561476057614760600080fd5b600061476c8585613d19565b9250506020613d688582860161473f565b60ff8116613d0e565b80356108148161477d565b600080600080600080600080610100898b0312156147b1576147b1600080fd5b60006147bd8b8b613d19565b98505060206147ce8b828c01613d19565b97505060406147df8b828c0161473f565b96505060606147f08b828c01613d2a565b95505060806148018b828c01613d2a565b94505060a06148128b828c01614786565b93505060c06148238b828c01613d2a565b92505060e06148348b828c01613d2a565b9150509295985092959890939650565b606081016148528286613d72565b61485f6020830185613d72565b612ad46040830184613d72565b6000806040838503121561488257614882600080fd5b60006144848585613d19565b600080600080600060a086880312156148a9576148a9600080fd5b60006148b58888613d19565b95505060206148c688828901613d19565b94505060406148d788828901613d2a565b935050606061442988828901613d2a565b60008060006060848603121561490057614900600080fd5b600061490c8686613d19565b935050602061491d86828701613d2a565b925050604061492e86828701613d2a565b9150509250925092565b602b81526000602082017f455243313135353a2062616c616e636520717565727920666f7220746865207a81527f65726f2061646472657373000000000000000000000000000000000000000000602082015291505b5060400190565b6020808252810161081481614938565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6002810460018216806149e857607f821691505b602082108114156149fb576149fb6149a5565b50919050565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f7420616e2041444d494e00815291505b5060200190565b6020808252810161081481614a01565b601e81526000602082017f4c616e644e46543a20696e76616c6964206f776e65722061646472657373000081529150614a31565b6020808252810161081481614a48565b601d81526000602082017f4c616e644e46543a20746f6b656e206e6f74207265676973746572656400000081529150614a31565b6020808252810161081481614a8c565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f742061204d494e5445520081529150614a31565b6020808252810161081481614ad0565b601f81526000602082017f4c616e644e46543a2070726f6a656374206e6f7420726567697374657265640081529150614a31565b6020808252810161081481614b14565b602681526000602082017f4c616e644e46543a20696e63726561736520726174696f2063616e6e6f74206281527f65207a65726f00000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614b58565b602681526000602082017f4c616e644e46543a2070726f6a65637420697320696e20636f6f6c646f776e2081527f706572696f6400000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614bc2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614c9357614c93614c2c565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082614cd657614cd6614c98565b500490565b60008219821115614cee57614cee614c2c565b500190565b60608101614d018286613d72565b614d0e6020830185613d72565b612ad46040830184614672565b602e81526000602082017f496e697469616c697a61626c653a20636f6e747261637420697320616c72656181527f647920696e697469616c697a65640000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614d1b565b602881526000602082017f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682081527f6d69736d617463680000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614d85565b602581526000602082017f455243313135353a207472616e7366657220746f20746865207a65726f20616481527f64726573730000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614def565b603281526000602082017f455243313135353a207472616e736665722063616c6c6572206973206e6f742081527f6f776e6572206e6f7220617070726f76656400000000000000000000000000006020820152915061498e565b6020808252810161081481614e59565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602a81526000602082017f455243313135353a20696e73756666696369656e742062616c616e636520666f81527f72207472616e73666572000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614ef2565b600082821015614f6e57614f6e614c2c565b500390565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614fa557614fa5614c2c565b5060010190565b602981526000602082017f455243313135353a206163636f756e747320616e6420696473206c656e67746881527f206d69736d6174636800000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614fac565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f742061204255524e45520081529150614a31565b6020808252810161081481615016565b601981526000602082017f4c616e644e46543a20696e76616c69642068656374617265730000000000000081529150614a31565b602080825281016108148161505a565b60208082527f4c616e644e46543a20696e76616c696420636f6f6c646f776e20706572696f6491019081526000614a31565b602080825281016108148161509e565b601281526000602082017f4c616e644e46543a20656d70747920636964000000000000000000000000000081529150614a31565b60208082528101610814816150e0565b601e81526000602082017f4c616e644e46543a2070726f6a65637420616c7265616479206164646564000081529150614a31565b6020808252810161081481615124565b600081610814565b90565b6000610814825b60ff1690565b600061081461517a8360081c90565b805460e083019061519f81615168565b6151a98582613d72565b505060018201546151b981615168565b6151c66020860182613d72565b505060028201546151d681615168565b6151e36040860182613d72565b505060038201546151f381615168565b6152006060860182613d72565b5050600482015461521081615168565b61521d6080860182613d72565b5050600582015461522d81615173565b61523a60a0860182613efd565b5061524481615180565b6123ac60c0860182613ddc565b61010081016152608285614672565b6116b6602083018461518f565b602981526000602082017f455243313135353a2073657474696e6720617070726f76616c2073746174757381527f20666f722073656c6600000000000000000000000000000000000000000000006020820152915061498e565b602080825281016108148161526d565b602281526000602082017f4c616e644e46543a2063616c6c6572206973206e6f7420616e204f504552415481527f4f520000000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816152d7565b602781526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a2065787069726564206481527f6561646c696e65000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615341565b602c81526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a20617574686f72697a6181527f74696f6e206973207573656400000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816153ab565b60c081016154238289613d72565b6154306020830188614672565b61543d6040830187614672565b61544a6060830186613ddc565b6154576080830185613d72565b61546460a0830184613d72565b979650505050505050565b602881526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a20696e76616c6964207381527f69676e61747572650000000000000000000000000000000000000000000000006020820152915061498e565b602080825281016108148161546f565b602981526000602082017f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7281527f20617070726f76656400000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816154d9565b604081016155518285613d72565b6116b66020830184613d72565b6000815461556b816149d4565b60018216801561558257600181146155b1576155e1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008316865281860193506155e1565b60008581526020902060005b838110156155d9578154888201526001909101906020016155bd565b838801955050505b50505092915050565b60006155f4825190565b615602818560208601613df2565b9290920192915050565b6000615618828561555e565b9150612ad482846155ea565b60008154615631816149d4565b8085526020850194506001821680156156515760018114615681576155e1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00831686526020860193506155e1565b60008581526020902060005b838110156156a95781548882015260019091019060200161568d565b9096019695505050505050565b602080825281016116b68184615624565b602181526000602082017f455243313135353a206d696e7420746f20746865207a65726f2061646472657381527f73000000000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816156c7565b60a0810161573f8288614672565b61574c6020830187614672565b818103604083015261575e8186613fa3565b905081810360608301526157728185613fa3565b905081810360808301526154648184613e22565b805161081481613d88565b6000602082840312156157a6576157a6600080fd5b6000612ad48484615786565b600060033d11156151705760046000803e5060005160e01c90565b600060443d10156157db5790565b60405160043d036004823e80513d602482011167ffffffffffffffff8211171561580457505090565b808201805167ffffffffffffffff811115615820575050505090565b80602083010160043d03850181111561583b57505050505090565b61584a8260200185018661402c565b5090949350505050565b603481526000602082017f455243313135353a207472616e7366657220746f206e6f6e204552433131353581527f526563656976657220696d706c656d656e7465720000000000000000000000006020820152915061498e565b6020808252810161081481615854565b602881526000602082017f455243313135353a204552433131353552656365697665722072656a6563746581527f6420746f6b656e730000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816158be565b602f81526000602082017f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636581527f20726f6c657320666f722073656c6600000000000000000000000000000000006020820152915061498e565b6020808252810161081481615928565b602381526000602082017f455243313135353a206275726e2066726f6d20746865207a65726f206164647281527f65737300000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615992565b602481526000602082017f455243313135353a206275726e20616d6f756e7420657863656564732062616c81527f616e6365000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816159fc565b60a08101615a748288614672565b615a816020830187614672565b615a8e6040830186613d72565b615a9b6060830185613d72565b81810360808301526154648184613e22565b602c81526000602082017f455243313135355061757361626c653a20746f6b656e207472616e736665722081527f7768696c652070617573656400000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615aad565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526017016000615b4982856155ea565b7f206973206d697373696e6720726f6c65200000000000000000000000000000008152915060118201615618565b60a08101615b858288613d72565b615b926020830187613d72565b615b9f6040830186613d72565b615bac6060830185613d72565b615bb96080830184614672565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b80613d74565b7f190100000000000000000000000000000000000000000000000000000000000081526002016000615c2a8285615bf2565b602082019150615c3a8284615bf2565b5060200192915050565b60ff8116613d74565b60808101615c5b8287613d72565b615c686020830186615c44565b615c756040830185613d72565b615c826060830184613d72565b95945050505050565b601881526000602082017f45434453413a20696e76616c6964207369676e6174757265000000000000000081529150614a31565b6020808252810161081481615c8b565b601f81526000602082017f45434453413a20696e76616c6964207369676e6174757265206c656e6774680081529150614a31565b6020808252810161081481615ccf565b602281526000602082017f45434453413a20696e76616c6964207369676e6174757265202773272076616c81527f75650000000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615d13565b602281526000602082017f45434453413a20696e76616c6964207369676e6174757265202776272076616c81527f75650000000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615d7d565b600081615df657615df6614c2c565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b60208082527f537472696e67733a20686578206c656e67746820696e73756666696369656e7491019081526000614a31565b6020808252810161081481615e1c56fea26469706673582212209796236358e267a034314230f5b469a258e54c0f31a3fdec2501a7478fbf92f764736f6c63430008080033
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102dd5760003560e01c80636b20c45411610186578063bc706774116100e3578063d58778d611610097578063f242432a11610071578063f242432a1461073d578063f5298aca14610750578063f5b541a61461076357600080fd5b8063d58778d61461069a578063e94a0102146106ad578063e985e9c5146106f457600080fd5b8063d2f33110116100c8578063d2f331101461063e578063d539139314610660578063d547741f1461068757600080fd5b8063bc70677414610618578063ca15c8731461062b57600080fd5b806391d148541161013a578063979518921161011f57806397951892146105ea578063a217fddf146105fd578063a22cb4651461060557600080fd5b806391d148541461059c57806395d89b41146105e257600080fd5b806375b238fc1161016b57806375b238fc146105345780638da5cb5b1461055b5780639010d07c1461058957600080fd5b80636b20c454146105195780637284e4161461052c57600080fd5b80632a9383421161023f57806336568abe116101f35780635add6537116101cd5780635add6537146104e35780635c975abb146104ec5780636392a51f146104f857600080fd5b806336568abe146104915780634e1273f4146104a4578063579a6988146104b757600080fd5b80632eb2c2d6116102245780632eb2c2d6146104635780632f2ff15d146104765780633644e5151461048957600080fd5b80632a9383421461043d5780632e6400241461045057600080fd5b806313af40351161029657806318e97fd11161027b57806318e97fd1146103e0578063248a9ca3146103f3578063282c51f31461041657600080fd5b806313af4035146103b657806314cbd993146103cb57600080fd5b806306fdde03116102c757806306fdde031461032b5780630e89341c14610340578063107046bd1461035357600080fd5b8062fdd58e146102e257806301ffc9a71461030b575b600080fd5b6102f56102f0366004613d35565b61078a565b6040516103029190613d7a565b60405180910390f35b61031e610319366004613dbb565b61081a565b6040516103029190613de4565b610333610825565b6040516103029190613e72565b61033361034e366004613e83565b6108b4565b6103a3610361366004613e83565b6101cb60205260009081526040902080546001820154600283015460038401546004850154600590950154939492939192909160ff8082169161010090041687565b6040516103029796959493929190613f06565b6103c96103c4366004613f6e565b6108bf565b005b6103d36109fc565b6040516103029190613fec565b6103c96103ee366004614140565b610a55565b6102f5610401366004613e83565b60009081526065602052604090206001015490565b6102f57f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84881565b6103c961044b36600461418e565b610b14565b6103c961045e366004614202565b610d1b565b6103c9610471366004614399565b610fe2565b6103c9610484366004614462565b6112fc565b6102f5611323565b6103c961049f366004614462565b611332565b6103d36104b236600461450a565b611354565b61031e6104c5366004613e83565b60009081526101cb6020526040902060050154610100900460ff1690565b6102f561271081565b61012d5460ff1661031e565b61050b610506366004613f6e565b611456565b604051610302929190614572565b6103c96105273660046145e2565b611548565b610333611690565b6102f57fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177581565b6101c95461057c9073ffffffffffffffffffffffffffffffffffffffff1681565b604051610302919061467b565b61057c61059736600461418e565b61169e565b61031e6105aa366004614462565b600091825260656020908152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b6103336116bd565b6103c96105f83660046146a1565b6116cb565b6102f5600081565b6103c961061336600461474a565b611a0d565b6103c9610626366004614791565b611af7565b6102f5610639366004613e83565b611d89565b61065161064c366004613d35565b611da0565b60405161030293929190614844565b6102f57f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b6103c9610695366004614462565b611dd5565b6102f56106a8366004613e83565b611ddf565b61031e6106bb366004613d35565b73ffffffffffffffffffffffffffffffffffffffff9190911660009081526101c560209081526040808320938352929052205460ff1690565b61031e61070236600461486c565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260986020908152604080832093909416825291909152205460ff1690565b6103c961074b36600461488e565b611e01565b6103c961075e3660046148e8565b612027565b6102f57f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b92981565b600073ffffffffffffffffffffffffffffffffffffffff83166107e2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614995565b60405180910390fd5b50600081815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff861684529091529020545b92915050565b6000610814826120be565b6101c68054610833906149d4565b80601f016020809104026020016040519081016040528092919081815260200182805461085f906149d4565b80156108ac5780601f10610881576101008083540402835291602001916108ac565b820191906000526020600020905b81548152906001019060200180831161088f57829003601f168201915b505050505081565b606061081482612114565b6108e97fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775336105aa565b61091f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a38565b73ffffffffffffffffffffffffffffffffffffffff811661096c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a7c565b6101c95460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36101c980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60606101ca805480602002602001604051908101604052809291908181526020018280548015610a4b57602002820191906000526020600020905b815481526020019060010190808311610a37575b5050505050905090565b610a7f7fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c21775336105aa565b610ab5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614a38565b60008281526101cb6020526040902060050154610100900460ff16610b06576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ac0565b610b1082826121c7565b5050565b610b3e7f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6336105aa565b610b74576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b04565b60008281526101cb602052604090206005810154610100900460ff16610bc6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b48565b81610bfd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614bb2565b80600401544211610c3a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614c1c565b6000612710838360020154610c4f9190614c5b565b610c599190614cc7565b905080826002016000828254610c6f9190614cdb565b909155505060038201546004830154610c889190614cdb565b826004016000828254610c9b9190614cdb565b90915550610cda905033858360005b6040519080825280601f01601f191660200182016040528015610cd4576020820181803683370190505b5061227a565b7fadf79fc7a670e099524b7ec65630a87db4c692ea399a4cc07d5b3c0fff3e3086848233604051610d0d93929190614cf3565b60405180910390a150505050565b600054610100900460ff1680610d34575060005460ff16155b610d6a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff16158015610da957600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b610de88a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506123b392505050565b610e5c6040518060400160405280600781526020017f4c616e644e4654000000000000000000000000000000000000000000000000008152506040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525061248c565b610e867f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a633612557565b610eb07f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a84833612557565b610eda7f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b92933612557565b610f047fa49807205ce4d355092ef5a8a18f56e8913cf4a201fbe287825b095693c2177533612557565b610f0f600033612557565b610f1c6101c68989613bbc565b50610f2a6101c78787613bbc565b50610f386101c88585613bbc565b506101c980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff841617905560405133906000907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a38015610fd657600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b50505050505050505050565b815183511461101d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ddf565b73ffffffffffffffffffffffffffffffffffffffff841661106a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614e49565b73ffffffffffffffffffffffffffffffffffffffff851633148061109357506110938533610702565b6110c9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614eb3565b336110d8818787878787612561565b60005b84518110156112675760008582815181106110f8576110f8614ec3565b60200260200101519050600085838151811061111657611116614ec3565b602090810291909101810151600084815260978352604080822073ffffffffffffffffffffffffffffffffffffffff8e16835290935291909120549091508181101561118e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614f4c565b6111988282614f5c565b6097600085815260200190815260200160002060008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816097600085815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825461124c9190614cdb565b925050819055505050508061126090614f73565b90506110db565b508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb87876040516112de929190614572565b60405180910390a46112f481878787878761256f565b505050505050565b611306828261275d565b600082815260c96020526040902061131e9082612783565b505050565b600061132d6127a5565b905090565b61133c82826127de565b600082815260c96020526040902061131e9082612837565b60608151835114611391576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615006565b6000835167ffffffffffffffff8111156113ad576113ad613ffd565b6040519080825280602002602001820160405280156113d6578160200160208202803683370190505b50905060005b845181101561144e576114218582815181106113fa576113fa614ec3565b602002602001015185838151811061141457611414614ec3565b602002602001015161078a565b82828151811061143357611433614ec3565b602090810291909101015261144781614f73565b90506113dc565b509392505050565b6060806101ca8054806020026020016040519081016040528092919081815260200182805480156114a657602002820191906000526020600020905b815481526020019060010190808311611492575b50505050509150815167ffffffffffffffff8111156114c7576114c7613ffd565b6040519080825280602002602001820160405280156114f0578160200160208202803683370190505b50905060005b8251811015611542576115158484838151811061141457611414614ec3565b82828151811061152757611527614ec3565b602090810291909101015261153b81614f73565b90506114f6565b50915091565b6115727f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a848336105aa565b6115a8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061504a565b611616858585808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080890282810182019093528882529093508892508791829185019084908082843760009201919091525061285992505050565b60005b838110156112f45782828281811061163357611633614ec3565b905060200201356101cb600087878581811061165157611651614ec3565b90506020020135815260200190815260200160002060020160008282546116789190614f5c565b9091555081905061168881614f73565b915050611619565b6101c88054610833906149d4565b600082815260c9602052604081206116b69083612a93565b9392505050565b6101c78054610833906149d4565b6116f57f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6336105aa565b61172b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614b04565b60008311611765576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061508e565b6000821161179f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906150d0565b836117d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615114565b60008681526101cb6020526040902060050154610100900460ff1615611828576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615158565b6101ca80546001810182556000919091527f0faeda9012b7f59bd2a84ac2a33ead5fc9f720c38d8bbf90db1ac3c1518386eb018690556040805160e08101825287815260208101859052908101849052606081018390526080810161188d8442614cdb565b81526020018260018111156118a4576118a4613ea4565b81526001602091820181905260008981526101cb83526040908190208451815592840151838301558301516002830155606083015160038301556080830151600483015560a0830151600583018054919290917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690838181111561192b5761192b613ea4565b021790555060c0919091015160059091018054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905561197c3387856000610caa565b6119bc8686868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506121c792505050565b60008681526101cb60205260409081902090517fca8ddcb55f768e292deb4557a3c1f262532d0c7d84e281b47b74614957059c58916119fd91339190615251565b60405180910390a1505050505050565b3373ffffffffffffffffffffffffffffffffffffffff83161415611a5d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906152c7565b33600081815260986020908152604080832073ffffffffffffffffffffffffffffffffffffffff871680855292529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001685151517905590519091907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190611aeb908590613de4565b60405180910390a35050565b611b217f97667070c54ef182b0f5858b034beac1b6f3089aa2d3188bb1e8929f4fa9b929336105aa565b611b57576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615331565b83421115611b91576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061539b565b73ffffffffffffffffffffffffffffffffffffffff881660009081526101c56020908152604080832088845290915290205460ff1615611bfd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615405565b60007f91aaffcde7eb6e14c35a5d629a51978795daafb7f3caeeaad4d913ed8d322c568989898989604051602001611c3a96959493929190615415565b6040516020818303038152906040528051906020012090506000611c5d82612a9f565b90506000611c6d82878787612ab2565b90508a73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614611cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906154c9565b73ffffffffffffffffffffffffffffffffffffffff8b1660009081526101c5602090815260408083208b8452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055611d398b8b8b612adc565b604051889073ffffffffffffffffffffffffffffffffffffffff8d16907f98de503528ee59b575ef0c0a2576a82497bfc029a5685b209e9ec333479b10a590600090a35050505050505050505050565b600081815260c96020526040812061081490612bde565b6000806000611daf858561078a565b60009485526101cb60205260409094206002810154600190910154949690955092505050565b61133c8282612be8565b6101ca8181548110611df057600080fd5b600091825260209091200154905081565b73ffffffffffffffffffffffffffffffffffffffff8416611e4e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614e49565b73ffffffffffffffffffffffffffffffffffffffff8516331480611e775750611e778533610702565b611ead576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615533565b33611ecc818787611ebd88612c0e565b611ec688612c0e565b87612561565b600084815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8a16845290915290205483811015611f36576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614f4c565b611f408482614f5c565b600086815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8c81168552925280832093909355881681529081208054869290611f8b908490614cdb565b925050819055508573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628888604051612008929190615543565b60405180910390a461201e828888888888612c59565b50505050505050565b6120517f3c11d16cbaffd01df69ce1c404f6340ee057498f5f00246190ea54220576a848336105aa565b612087576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99061504a565b612092838383612dbf565b60008281526101cb6020526040812060020180548392906120b4908490614f5c565b9091555050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f5a05180f000000000000000000000000000000000000000000000000000000001480610814575061081482612f2c565b6060816121ad5760998054612128906149d4565b80601f0160208091040260200160405190810160405280929190818152602001828054612154906149d4565b80156121a15780601f10612176576101008083540402835291602001916121a1565b820191906000526020600020905b81548152906001019060200180831161218457829003601f168201915b50505050509050919050565b60008281526101cc602052604090208054612128906149d4565b6099816040516020016121db92919061560c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815260008481526101cc6020908152919020825161222a93919290910190613c5e565b50817f6bb7ff708619ba0610cba295a58592e0451dee2622938c8755667688daf3529b6101cc600085815260200190815260200160002060405161226e91906156b6565b60405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff84166122c7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615721565b336122d881600087611ebd88612c0e565b600084815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8916845290915281208054859290612317908490614cdb565b925050819055508473ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628787604051612395929190615543565b60405180910390a46123ac81600087878787612c59565b5050505050565b600054610100900460ff16806123cc575060005460ff16155b612402576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561244157600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b612449612fce565b612451612fce565b61245a8261308e565b8015610b1057600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555050565b600054610100900460ff16806124a5575060005460ff16155b6124db576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561251a57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b6125248383613125565b801561131e57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055505050565b6113068282613205565b6112f486868686868661320f565b73ffffffffffffffffffffffffffffffffffffffff84163b156112f4576040517fbc197c8100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063bc197c81906125e69089908990889088908890600401615731565b602060405180830381600087803b15801561260057600080fd5b505af192505050801561264e575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261264b91810190615791565b60015b6126e25761265a6157b2565b806308c379a014156126ae575061266f6157cd565b8061267a57506126b0565b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d99190613e72565b505b6040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906158ae565b7fffffffff0000000000000000000000000000000000000000000000000000000081167fbc197c81000000000000000000000000000000000000000000000000000000001461201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615918565b600082815260656020526040902060010154612779813361324d565b61131e838361331f565b60006116b68373ffffffffffffffffffffffffffffffffffffffff8416613413565b600061132d7f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6127d56101915490565b61019254613462565b73ffffffffffffffffffffffffffffffffffffffff8116331461282d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615982565b610b10828261349c565b60006116b68373ffffffffffffffffffffffffffffffffffffffff8416613557565b73ffffffffffffffffffffffffffffffffffffffff83166128a6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906159ec565b80518251146128e1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614ddf565b600033905061290481856000868660405180602001604052806000815250612561565b60005b8351811015612a0d57600084828151811061292457612924614ec3565b60200260200101519050600084838151811061294257612942614ec3565b602090810291909101810151600084815260978352604080822073ffffffffffffffffffffffffffffffffffffffff8c1683529093529190912054909150818110156129ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615a56565b6129c48282614f5c565b600093845260976020908152604080862073ffffffffffffffffffffffffffffffffffffffff8c1687529091529093209290925550819050612a0581614f73565b915050612907565b50600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051612a85929190614572565b60405180910390a450505050565b60006116b6838361364a565b6000610814612aac6127a5565b83613674565b6000806000612ac3878787876136a7565b91509150612ad0816137b2565b5090505b949350505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612b42576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906152c7565b73ffffffffffffffffffffffffffffffffffffffff8381166000818152609860209081526040808320948716808452949091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016851515179055517f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3190612bd1908590613de4565b60405180910390a3505050565b6000610814825490565b600082815260656020526040902060010154612c04813361324d565b61131e838361349c565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110612c4857612c48614ec3565b602090810291909101015292915050565b73ffffffffffffffffffffffffffffffffffffffff84163b156112f4576040517ff23a6e6100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063f23a6e6190612cd09089908990889088908890600401615a66565b602060405180830381600087803b158015612cea57600080fd5b505af1925050508015612d38575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252612d3591810190615791565b60015b612d445761265a6157b2565b7fffffffff0000000000000000000000000000000000000000000000000000000081167ff23a6e61000000000000000000000000000000000000000000000000000000001461201e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615918565b73ffffffffffffffffffffffffffffffffffffffff8316612e0c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d9906159ec565b33612e3b81856000612e1d87612c0e565b612e2687612c0e565b60405180602001604052806000815250612561565b600083815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff8816845290915290205482811015612ea5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615a56565b612eaf8382614f5c565b600085815260976020908152604080832073ffffffffffffffffffffffffffffffffffffffff808b16808652919093528184209490945551919291908516907fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6290612f1d9089908990615543565b60405180910390a45050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fd9b67a26000000000000000000000000000000000000000000000000000000001480612fbf57507fffffffff0000000000000000000000000000000000000000000000000000000082167f0e89341c00000000000000000000000000000000000000000000000000000000145b806108145750610814826138ff565b600054610100900460ff1680612fe7575060005460ff16155b61301d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561305c57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b801561308b57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b50565b600054610100900460ff16806130a7575060005460ff16155b6130dd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff1615801561311c57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b61245a82613996565b600054610100900460ff168061313e575060005460ff16155b613174576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990614d75565b600054610100900460ff161580156131b357600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b82516020808501919091208351918401919091206101919190915561019255801561131e57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055505050565b610b10828261331f565b61012d5460ff16156112f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615b07565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610b10576132a58173ffffffffffffffffffffffffffffffffffffffff1660146139a9565b6132b08360206139a9565b6040516020016132c1929190615b17565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f08c379a00000000000000000000000000000000000000000000000000000000082526107d991600401613e72565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16610b1057600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556133b53390565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b600081815260018301602052604081205461345a57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610814565b506000610814565b6000838383463060405160200161347d959493929190615b77565b6040516020818303038152906040528051906020012090509392505050565b600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff1615610b1057600082815260656020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000818152600183016020526040812054801561364057600061357b600183614f5c565b855490915060009061358f90600190614f5c565b90508181146135f45760008660000182815481106135af576135af614ec3565b90600052602060002001549050808760000184815481106135d2576135d2614ec3565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061360557613605615bc3565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610814565b6000915050610814565b600082600001828154811061366157613661614ec3565b9060005260206000200154905092915050565b60008282604051602001613689929190615bf8565b60405160208183030381529060405280519060200120905092915050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08311156136de57506000905060036137a9565b8460ff16601b141580156136f657508460ff16601c14155b1561370757506000905060046137a9565b60006001878787876040516000815260200160405260405161372c9493929190615c4d565b6020604051602081039080840390855afa15801561374e573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166137a2576000600192509250506137a9565b9150600090505b94509492505050565b60008160048111156137c6576137c6613ea4565b14156137cf5750565b60018160048111156137e3576137e3613ea4565b141561381b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615cbf565b600281600481111561382f5761382f613ea4565b1415613867576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615d03565b600381600481111561387b5761387b613ea4565b14156138b3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615d6d565b60048160048111156138c7576138c7613ea4565b141561308b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615dd7565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b00000000000000000000000000000000000000000000000000000000148061081457507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610814565b8051610b10906099906020840190613c5e565b606060006139b8836002614c5b565b6139c3906002614cdb565b67ffffffffffffffff8111156139db576139db613ffd565b6040519080825280601f01601f191660200182016040528015613a05576020820181803683370190505b5090507f300000000000000000000000000000000000000000000000000000000000000081600081518110613a3c57613a3c614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110613a9f57613a9f614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506000613adb846002614c5b565b613ae6906001614cdb565b90505b6001811115613b83577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110613b2757613b27614ec3565b1a60f81b828281518110613b3d57613b3d614ec3565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060049490941c93613b7c81615de7565b9050613ae9565b5083156116b6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107d990615e4e565b828054613bc8906149d4565b90600052602060002090601f016020900481019282613bea5760008555613c4e565b82601f10613c21578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00823516178555613c4e565b82800160010185558215613c4e579182015b82811115613c4e578235825591602001919060010190613c33565b50613c5a929150613cd2565b5090565b828054613c6a906149d4565b90600052602060002090601f016020900481019282613c8c5760008555613c4e565b82601f10613ca557805160ff1916838001178555613c4e565b82800160010185558215613c4e579182015b82811115613c4e578251825591602001919060010190613cb7565b5b80821115613c5a5760008155600101613cd3565b600073ffffffffffffffffffffffffffffffffffffffff8216610814565b613d0e81613ce7565b811461308b57600080fd5b803561081481613d05565b80613d0e565b803561081481613d24565b60008060408385031215613d4b57613d4b600080fd5b6000613d578585613d19565b9250506020613d6885828601613d2a565b9150509250929050565b805b82525050565b602081016108148284613d72565b7fffffffff000000000000000000000000000000000000000000000000000000008116613d0e565b803561081481613d88565b600060208284031215613dd057613dd0600080fd5b6000612ad48484613db0565b801515613d74565b602081016108148284613ddc565b60005b83811015613e0d578181015183820152602001613df5565b83811115613e1c576000848401525b50505050565b6000613e2c825190565b808452602084019350613e43818560208601613df2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920192915050565b602080825281016116b68184613e22565b600060208284031215613e9857613e98600080fd5b6000612ad48484613d2a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6002811061308b5761308b613ea4565b80613eed81613ed3565b919050565b600061081482613ee3565b613d7481613ef2565b60e08101613f14828a613d72565b613f216020830189613d72565b613f2e6040830188613d72565b613f3b6060830187613d72565b613f486080830186613d72565b613f5560a0830185613efd565b613f6260c0830184613ddc565b98975050505050505050565b600060208284031215613f8357613f83600080fd5b6000612ad48484613d19565b6000613f9b8383613d72565b505060200190565b6000613fad825190565b80845260209384019383018060005b83811015613fe1578151613fd08882613f8f565b975060208301925050600101613fbc565b509495945050505050565b602080825281016116b68184613fa3565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116810181811067ffffffffffffffff8211171561407057614070613ffd565b6040525050565b600061408260405190565b9050613eed828261402c565b600067ffffffffffffffff8211156140a8576140a8613ffd565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011660200192915050565b82818337506000910152565b60006140f66140f18461408e565b614077565b90508281526020810184848401111561411157614111600080fd5b61144e8482856140d7565b600082601f83011261413057614130600080fd5b8135612ad48482602086016140e3565b6000806040838503121561415657614156600080fd5b60006141628585613d2a565b925050602083013567ffffffffffffffff81111561418257614182600080fd5b613d688582860161411c565b600080604083850312156141a4576141a4600080fd5b6000613d578585613d2a565b60008083601f8401126141c5576141c5600080fd5b50813567ffffffffffffffff8111156141e0576141e0600080fd5b6020830191508360018202830111156141fb576141fb600080fd5b9250929050565b600080600080600080600080600060a08a8c03121561422357614223600080fd5b893567ffffffffffffffff81111561423d5761423d600080fd5b6142498c828d016141b0565b995099505060208a013567ffffffffffffffff81111561426b5761426b600080fd5b6142778c828d016141b0565b975097505060408a013567ffffffffffffffff81111561429957614299600080fd5b6142a58c828d016141b0565b955095505060608a013567ffffffffffffffff8111156142c7576142c7600080fd5b6142d38c828d016141b0565b935093505060806142e68c828d01613d19565b9150509295985092959850929598565b600067ffffffffffffffff82111561431057614310613ffd565b5060209081020190565b60006143286140f1846142f6565b8381529050602080820190840283018581111561434757614347600080fd5b835b8181101561436b578061435c8882613d2a565b84525060209283019201614349565b5050509392505050565b600082601f83011261438957614389600080fd5b8135612ad484826020860161431a565b600080600080600060a086880312156143b4576143b4600080fd5b60006143c08888613d19565b95505060206143d188828901613d19565b945050604086013567ffffffffffffffff8111156143f1576143f1600080fd5b6143fd88828901614375565b935050606086013567ffffffffffffffff81111561441d5761441d600080fd5b61442988828901614375565b925050608086013567ffffffffffffffff81111561444957614449600080fd5b6144558882890161411c565b9150509295509295909350565b6000806040838503121561447857614478600080fd5b60006144848585613d2a565b9250506020613d6885828601613d19565b60006144a36140f1846142f6565b838152905060208082019084028301858111156144c2576144c2600080fd5b835b8181101561436b57806144d78882613d19565b845250602092830192016144c4565b600082601f8301126144fa576144fa600080fd5b8135612ad4848260208601614495565b6000806040838503121561452057614520600080fd5b823567ffffffffffffffff81111561453a5761453a600080fd5b614546858286016144e6565b925050602083013567ffffffffffffffff81111561456657614566600080fd5b613d6885828601614375565b604080825281016145838185613fa3565b90508181036020830152612ad48184613fa3565b60008083601f8401126145ac576145ac600080fd5b50813567ffffffffffffffff8111156145c7576145c7600080fd5b6020830191508360208202830111156141fb576141fb600080fd5b6000806000806000606086880312156145fd576145fd600080fd5b60006146098888613d19565b955050602086013567ffffffffffffffff81111561462957614629600080fd5b61463588828901614597565b9450945050604086013567ffffffffffffffff81111561465757614657600080fd5b61466388828901614597565b92509250509295509295909350565b613d7481613ce7565b602081016108148284614672565b6002811061308b57600080fd5b803561081481614689565b60008060008060008060a087890312156146bd576146bd600080fd5b60006146c98989613d2a565b965050602087013567ffffffffffffffff8111156146e9576146e9600080fd5b6146f589828a016141b0565b9550955050604061470889828a01613d2a565b935050606061471989828a01613d2a565b925050608061472a89828a01614696565b9150509295509295509295565b801515613d0e565b803561081481614737565b6000806040838503121561476057614760600080fd5b600061476c8585613d19565b9250506020613d688582860161473f565b60ff8116613d0e565b80356108148161477d565b600080600080600080600080610100898b0312156147b1576147b1600080fd5b60006147bd8b8b613d19565b98505060206147ce8b828c01613d19565b97505060406147df8b828c0161473f565b96505060606147f08b828c01613d2a565b95505060806148018b828c01613d2a565b94505060a06148128b828c01614786565b93505060c06148238b828c01613d2a565b92505060e06148348b828c01613d2a565b9150509295985092959890939650565b606081016148528286613d72565b61485f6020830185613d72565b612ad46040830184613d72565b6000806040838503121561488257614882600080fd5b60006144848585613d19565b600080600080600060a086880312156148a9576148a9600080fd5b60006148b58888613d19565b95505060206148c688828901613d19565b94505060406148d788828901613d2a565b935050606061442988828901613d2a565b60008060006060848603121561490057614900600080fd5b600061490c8686613d19565b935050602061491d86828701613d2a565b925050604061492e86828701613d2a565b9150509250925092565b602b81526000602082017f455243313135353a2062616c616e636520717565727920666f7220746865207a81527f65726f2061646472657373000000000000000000000000000000000000000000602082015291505b5060400190565b6020808252810161081481614938565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6002810460018216806149e857607f821691505b602082108114156149fb576149fb6149a5565b50919050565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f7420616e2041444d494e00815291505b5060200190565b6020808252810161081481614a01565b601e81526000602082017f4c616e644e46543a20696e76616c6964206f776e65722061646472657373000081529150614a31565b6020808252810161081481614a48565b601d81526000602082017f4c616e644e46543a20746f6b656e206e6f74207265676973746572656400000081529150614a31565b6020808252810161081481614a8c565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f742061204d494e5445520081529150614a31565b6020808252810161081481614ad0565b601f81526000602082017f4c616e644e46543a2070726f6a656374206e6f7420726567697374657265640081529150614a31565b6020808252810161081481614b14565b602681526000602082017f4c616e644e46543a20696e63726561736520726174696f2063616e6e6f74206281527f65207a65726f00000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614b58565b602681526000602082017f4c616e644e46543a2070726f6a65637420697320696e20636f6f6c646f776e2081527f706572696f6400000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614bc2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614c9357614c93614c2c565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082614cd657614cd6614c98565b500490565b60008219821115614cee57614cee614c2c565b500190565b60608101614d018286613d72565b614d0e6020830185613d72565b612ad46040830184614672565b602e81526000602082017f496e697469616c697a61626c653a20636f6e747261637420697320616c72656181527f647920696e697469616c697a65640000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614d1b565b602881526000602082017f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682081527f6d69736d617463680000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614d85565b602581526000602082017f455243313135353a207472616e7366657220746f20746865207a65726f20616481527f64726573730000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614def565b603281526000602082017f455243313135353a207472616e736665722063616c6c6572206973206e6f742081527f6f776e6572206e6f7220617070726f76656400000000000000000000000000006020820152915061498e565b6020808252810161081481614e59565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602a81526000602082017f455243313135353a20696e73756666696369656e742062616c616e636520666f81527f72207472616e73666572000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614ef2565b600082821015614f6e57614f6e614c2c565b500390565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614fa557614fa5614c2c565b5060010190565b602981526000602082017f455243313135353a206163636f756e747320616e6420696473206c656e67746881527f206d69736d6174636800000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481614fac565b601f81526000602082017f4c616e644e46543a2063616c6c6572206973206e6f742061204255524e45520081529150614a31565b6020808252810161081481615016565b601981526000602082017f4c616e644e46543a20696e76616c69642068656374617265730000000000000081529150614a31565b602080825281016108148161505a565b60208082527f4c616e644e46543a20696e76616c696420636f6f6c646f776e20706572696f6491019081526000614a31565b602080825281016108148161509e565b601281526000602082017f4c616e644e46543a20656d70747920636964000000000000000000000000000081529150614a31565b60208082528101610814816150e0565b601e81526000602082017f4c616e644e46543a2070726f6a65637420616c7265616479206164646564000081529150614a31565b6020808252810161081481615124565b600081610814565b90565b6000610814825b60ff1690565b600061081461517a8360081c90565b805460e083019061519f81615168565b6151a98582613d72565b505060018201546151b981615168565b6151c66020860182613d72565b505060028201546151d681615168565b6151e36040860182613d72565b505060038201546151f381615168565b6152006060860182613d72565b5050600482015461521081615168565b61521d6080860182613d72565b5050600582015461522d81615173565b61523a60a0860182613efd565b5061524481615180565b6123ac60c0860182613ddc565b61010081016152608285614672565b6116b6602083018461518f565b602981526000602082017f455243313135353a2073657474696e6720617070726f76616c2073746174757381527f20666f722073656c6600000000000000000000000000000000000000000000006020820152915061498e565b602080825281016108148161526d565b602281526000602082017f4c616e644e46543a2063616c6c6572206973206e6f7420616e204f504552415481527f4f520000000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816152d7565b602781526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a2065787069726564206481527f6561646c696e65000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615341565b602c81526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a20617574686f72697a6181527f74696f6e206973207573656400000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816153ab565b60c081016154238289613d72565b6154306020830188614672565b61543d6040830187614672565b61544a6060830186613ddc565b6154576080830185613d72565b61546460a0830184613d72565b979650505050505050565b602881526000602082017f4c616e644e46545f417574686f72697a6174696f6e3a20696e76616c6964207381527f69676e61747572650000000000000000000000000000000000000000000000006020820152915061498e565b602080825281016108148161546f565b602981526000602082017f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7281527f20617070726f76656400000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816154d9565b604081016155518285613d72565b6116b66020830184613d72565b6000815461556b816149d4565b60018216801561558257600181146155b1576155e1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008316865281860193506155e1565b60008581526020902060005b838110156155d9578154888201526001909101906020016155bd565b838801955050505b50505092915050565b60006155f4825190565b615602818560208601613df2565b9290920192915050565b6000615618828561555e565b9150612ad482846155ea565b60008154615631816149d4565b8085526020850194506001821680156156515760018114615681576155e1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00831686526020860193506155e1565b60008581526020902060005b838110156156a95781548882015260019091019060200161568d565b9096019695505050505050565b602080825281016116b68184615624565b602181526000602082017f455243313135353a206d696e7420746f20746865207a65726f2061646472657381527f73000000000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816156c7565b60a0810161573f8288614672565b61574c6020830187614672565b818103604083015261575e8186613fa3565b905081810360608301526157728185613fa3565b905081810360808301526154648184613e22565b805161081481613d88565b6000602082840312156157a6576157a6600080fd5b6000612ad48484615786565b600060033d11156151705760046000803e5060005160e01c90565b600060443d10156157db5790565b60405160043d036004823e80513d602482011167ffffffffffffffff8211171561580457505090565b808201805167ffffffffffffffff811115615820575050505090565b80602083010160043d03850181111561583b57505050505090565b61584a8260200185018661402c565b5090949350505050565b603481526000602082017f455243313135353a207472616e7366657220746f206e6f6e204552433131353581527f526563656976657220696d706c656d656e7465720000000000000000000000006020820152915061498e565b6020808252810161081481615854565b602881526000602082017f455243313135353a204552433131353552656365697665722072656a6563746581527f6420746f6b656e730000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816158be565b602f81526000602082017f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636581527f20726f6c657320666f722073656c6600000000000000000000000000000000006020820152915061498e565b6020808252810161081481615928565b602381526000602082017f455243313135353a206275726e2066726f6d20746865207a65726f206164647281527f65737300000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615992565b602481526000602082017f455243313135353a206275726e20616d6f756e7420657863656564732062616c81527f616e6365000000000000000000000000000000000000000000000000000000006020820152915061498e565b60208082528101610814816159fc565b60a08101615a748288614672565b615a816020830187614672565b615a8e6040830186613d72565b615a9b6060830185613d72565b81810360808301526154648184613e22565b602c81526000602082017f455243313135355061757361626c653a20746f6b656e207472616e736665722081527f7768696c652070617573656400000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615aad565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526017016000615b4982856155ea565b7f206973206d697373696e6720726f6c65200000000000000000000000000000008152915060118201615618565b60a08101615b858288613d72565b615b926020830187613d72565b615b9f6040830186613d72565b615bac6060830185613d72565b615bb96080830184614672565b9695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b80613d74565b7f190100000000000000000000000000000000000000000000000000000000000081526002016000615c2a8285615bf2565b602082019150615c3a8284615bf2565b5060200192915050565b60ff8116613d74565b60808101615c5b8287613d72565b615c686020830186615c44565b615c756040830185613d72565b615c826060830184613d72565b95945050505050565b601881526000602082017f45434453413a20696e76616c6964207369676e6174757265000000000000000081529150614a31565b6020808252810161081481615c8b565b601f81526000602082017f45434453413a20696e76616c6964207369676e6174757265206c656e6774680081529150614a31565b6020808252810161081481615ccf565b602281526000602082017f45434453413a20696e76616c6964207369676e6174757265202773272076616c81527f75650000000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615d13565b602281526000602082017f45434453413a20696e76616c6964207369676e6174757265202776272076616c81527f75650000000000000000000000000000000000000000000000000000000000006020820152915061498e565b6020808252810161081481615d7d565b600081615df657615df6614c2c565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b60208082527f537472696e67733a20686578206c656e67746820696e73756666696369656e7491019081526000614a31565b6020808252810161081481615e1c56fea26469706673582212209796236358e267a034314230f5b469a258e54c0f31a3fdec2501a7478fbf92f764736f6c63430008080033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ 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.