Address Details
contract
0xbE3d1dD4b487C1436e319a4AF55F43d69559E54D
- Contract Name
- PlastikNFTMulV3
- Creator
- 0x4c45c6–9e9f2c at 0xa88668–b05bb6
- Balance
- 0 CELO ( )
- Locked CELO Balance
- 0.00 CELO
- Voting CELO Balance
- 0.00 CELO
- Pending Unlocked Gold
- 0.00 CELO
- Tokens
-
Fetching tokens...
- Transactions
- 1 Transactions
- Transfers
- 0 Transfers
- Gas Used
- 29,067
- Last Balance Update
- 15962124
This contract has been verified via Sourcify.
View contract in Sourcify repository
- Contract name:
- PlastikNFTMulV3
- Optimization enabled
- false
- Compiler version
- v0.8.9+commit.e5eed63a
- EVM Version
- london
- Verified at
- 2022-11-03T12:30:00.629789Z
contracts/PlastikNFTMulV3.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol"; import "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155Burnable.sol"; import "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155Supply.sol"; import "./UtilsV2.sol"; import "./PlastikCryptoV2.sol"; import "./PlastikRoleV2.sol"; import "./PlastikRoyaltyCal.sol"; /// @custom:security-contact daniel@nozama.green contract PlastikNFTMulV3 is Ownable, ERC1155URIStorage, ERC1155Burnable, ERC1155Supply { IPlastikRoyaltyCal internal royaltyCal; PlastikCryptoV2 internal plastikCrypto; PlastikRoleV2 internal plastikRole; event PlastikNFTMultiMinted( address mintTo, uint256 tokenId, uint256 amount ); constructor( address _royaltyCal, address _plastikCrypto, address _plastikRole ) ERC1155("https://plastiks.io/ipfs") { royaltyCal = IPlastikRoyaltyCal(_royaltyCal); plastikCrypto = PlastikCryptoV2(_plastikCrypto); plastikRole = PlastikRoleV2(_plastikRole); } modifier onlyMinter() { if (_msgSender() != owner()) { plastikRole.verifyMinterRole(_msgSender()); } _; } function setBaseURI(string memory newuri) public onlyOwner { _setBaseURI(newuri); } function mint( address to, uint256 id, uint256 amount, string memory tokenURI, uint96 royaltyFee, bytes memory data ) external onlyMinter returns (uint256) { _mint(to, id, amount, data); _setURI(id, tokenURI); royaltyCal.setTokenRoyalty(id, to, royaltyFee); emit PlastikNFTMultiMinted(to, id, amount); return id; } function mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, string[] memory uris, uint96[] memory royaltyFee, bytes memory data ) public onlyMinter { require( uris.length == amounts.length, "ERC1155: uris and amounts length mismatch" ); _mintBatch(to, ids, amounts, data); for (uint256 i = 0; i < uris.length; i++) { _setURI(ids[i], uris[i]); royaltyCal.setTokenRoyalty(ids[i], to, royaltyFee[i]); emit PlastikNFTMultiMinted(to, ids[i], amounts[i]); } } function uri(uint256 tokenId) public view virtual override(ERC1155, ERC1155URIStorage) returns (string memory) { return super.uri(tokenId); } function safeLazyMint( address buyer, uint256 amount, NFTVoucherV2 calldata voucher, bytes memory signature, bytes memory data ) external payable onlyMinter returns (uint256) { require( voucher.tokenAddress == address(this), "The voucher must be for this contract" ); // must be compatible with eth_signTypedDataV4 in MetaMask address signer = plastikCrypto.verifyNFTVoucher(voucher, signature); require( signer == voucher.creatorAddress, "Creator Address does not match" ); if (!exists(voucher.tokenId)) { _mint(signer, voucher.tokenId, voucher.amount, data); _setURI(voucher.tokenId, voucher.tokenURI); royaltyCal.setTokenRoyalty( voucher.tokenId, signer, voucher.royalty ); emit PlastikNFTMultiMinted(signer, voucher.tokenId, voucher.amount); } safeTransferFrom(signer, buyer, voucher.tokenId, amount, data); return voucher.tokenId; } function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal override(ERC1155, ERC1155Supply) { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); } function supportsInterface(bytes4 interfaceId) public view override(ERC1155) returns (bool) { return super.supportsInterface(interfaceId); } }
/_openzeppelin/contracts/access/AccessControl.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/AccessControl.sol) pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.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 AccessControl is Context, IAccessControl, ERC165 { 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); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view virtual override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `_msgSender()` is missing `role`. * Overriding this function changes the behavior of the {onlyRole} modifier. * * Format of the revert message is described in {_checkRole}. * * _Available since v4.6._ */ function _checkRole(bytes32 role) internal view virtual { _checkRole(role, _msgSender()); } /** * @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 virtual { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.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 virtual 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. * * May emit a {RoleGranted} event. */ 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. * * May emit a {RoleRevoked} event. */ 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 revoked `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. * * May emit a {RoleRevoked} event. */ 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. * * May emit a {RoleGranted} event. * * [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}. * ==== * * NOTE: This function is deprecated in favor of {_grantRole}. */ 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); } /** * @dev Grants `role` to `account`. * * Internal function without access restriction. * * May emit a {RoleGranted} event. */ function _grantRole(bytes32 role, address account) internal virtual { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } /** * @dev Revokes `role` from `account`. * * Internal function without access restriction. * * May emit a {RoleRevoked} event. */ function _revokeRole(bytes32 role, address account) internal virtual { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
/_openzeppelin/contracts/access/IAccessControl.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol) pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @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; }
/_openzeppelin/contracts/access/Ownable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
/_openzeppelin/contracts/interfaces/IERC2981.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.0; import "../utils/introspection/IERC165.sol"; /** * @dev Interface for the NFT Royalty Standard. * * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal * support for royalty payments across all NFT marketplaces and ecosystem participants. * * _Available since v4.5._ */ interface IERC2981 is IERC165 { /** * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of * exchange. The royalty amount is denominated and should be paid in that same unit of exchange. */ function royaltyInfo(uint256 tokenId, uint256 salePrice) external view returns (address receiver, uint256 royaltyAmount); }
/_openzeppelin/contracts/token/ERC1155/ERC1155.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC1155/ERC1155.sol) pragma solidity ^0.8.0; import "./IERC1155.sol"; import "./IERC1155Receiver.sol"; import "./extensions/IERC1155MetadataURI.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/introspection/ERC165.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 ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address 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)) private _operatorApprovals; // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json string private _uri; /** * @dev See {_setURI}. */ constructor(string memory uri_) { _setURI(uri_); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155).interfaceId || interfaceId == type(IERC1155MetadataURI).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: address zero is not a valid owner"); 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 { _setApprovalForAll(_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( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not token owner nor approved" ); _safeTransferFrom(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( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not token owner nor approved" ); _safeBatchTransferFrom(from, to, ids, amounts, data); } /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - `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 memory data ) internal virtual { require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, from, to, ids, amounts, data); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; emit TransferSingle(operator, from, to, id, amount); _afterTokenTransfer(operator, from, to, ids, amounts, data); _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - 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[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zero address"); 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"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; } emit TransferBatch(operator, from, to, ids, amounts); _afterTokenTransfer(operator, from, to, ids, amounts, data); _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 `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint( address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); _balances[id][to] += amount; emit TransferSingle(operator, address(0), to, id, amount); _afterTokenTransfer(operator, address(0), to, ids, amounts, data); _doSafeTransferAcceptanceCheck(operator, address(0), to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * 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 _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 (uint256 i = 0; i < ids.length; i++) { _balances[ids[i]][to] += amounts[i]; } emit TransferBatch(operator, address(0), to, ids, amounts); _afterTokenTransfer(operator, address(0), to, ids, amounts, data); _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data); } /** * @dev Destroys `amount` tokens of token type `id` from `from` * * Emits a {TransferSingle} event. * * Requirements: * * - `from` cannot be the zero address. * - `from` must have at least `amount` tokens of token type `id`. */ function _burn( address from, uint256 id, uint256 amount ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, from, address(0), ids, amounts, ""); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } emit TransferSingle(operator, from, address(0), id, amount); _afterTokenTransfer(operator, from, address(0), ids, amounts, ""); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Emits a {TransferBatch} event. * * Requirements: * * - `ids` and `amounts` must have the same length. */ function _burnBatch( address from, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, address(0), ids, amounts, ""); 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: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } } emit TransferBatch(operator, from, address(0), ids, amounts); _afterTokenTransfer(operator, from, address(0), ids, amounts, ""); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits an {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC1155: setting approval status for self"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @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 `ids` and `amounts` 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 {} /** * @dev Hook that is called after 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 _afterTokenTransfer( 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 IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) { if (response != IERC1155Receiver.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 IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns ( bytes4 response ) { if (response != IERC1155Receiver.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; } }
/_openzeppelin/contracts/token/ERC1155/IERC1155.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC1155/IERC1155.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.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 IERC1155 is IERC165 { /** * @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 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; }
/_openzeppelin/contracts/token/ERC1155/IERC1155Receiver.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev _Available since v3.1._ */ interface IERC1155Receiver is IERC165 { /** * @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. * * NOTE: 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. * * NOTE: 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); }
/_openzeppelin/contracts/token/ERC1155/extensions/ERC1155Burnable.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC1155/extensions/ERC1155Burnable.sol) pragma solidity ^0.8.0; import "../ERC1155.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 ERC1155Burnable is ERC1155 { function burn( address account, uint256 id, uint256 value ) public virtual { require( account == _msgSender() || isApprovedForAll(account, _msgSender()), "ERC1155: caller is not token 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 token owner nor approved" ); _burnBatch(account, ids, values); } }
/_openzeppelin/contracts/token/ERC1155/extensions/ERC1155Supply.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC1155/extensions/ERC1155Supply.sol) pragma solidity ^0.8.0; import "../ERC1155.sol"; /** * @dev Extension of ERC1155 that adds tracking of total supply per id. * * Useful for scenarios where Fungible and Non-fungible tokens have to be * clearly identified. Note: While a totalSupply of 1 might mean the * corresponding is an NFT, there is no guarantees that no other token with the * same id are not going to be minted. */ abstract contract ERC1155Supply is ERC1155 { mapping(uint256 => uint256) private _totalSupply; /** * @dev Total amount of tokens in with a given id. */ function totalSupply(uint256 id) public view virtual returns (uint256) { return _totalSupply[id]; } /** * @dev Indicates whether any token exist with a given id, or not. */ function exists(uint256 id) public view virtual returns (bool) { return ERC1155Supply.totalSupply(id) > 0; } /** * @dev See {ERC1155-_beforeTokenTransfer}. */ 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); if (from == address(0)) { for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] += amounts[i]; } } if (to == address(0)) { for (uint256 i = 0; i < ids.length; ++i) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 supply = _totalSupply[id]; require(supply >= amount, "ERC1155: burn amount exceeds totalSupply"); unchecked { _totalSupply[id] = supply - amount; } } } } }
/_openzeppelin/contracts/token/ERC1155/extensions/ERC1155URIStorage.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC1155/extensions/ERC1155URIStorage.sol) pragma solidity ^0.8.0; import "../../../utils/Strings.sol"; import "../ERC1155.sol"; /** * @dev ERC1155 token with storage based token URI management. * Inspired by the ERC721URIStorage extension * * _Available since v4.6._ */ abstract contract ERC1155URIStorage is ERC1155 { using Strings for uint256; // Optional base URI string private _baseURI = ""; // Optional mapping for token URIs mapping(uint256 => string) private _tokenURIs; /** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the concatenation of the `_baseURI` * and the token-specific uri if the latter is set * * This enables the following behaviors: * * - if `_tokenURIs[tokenId]` is set, then the result is the concatenation * of `_baseURI` and `_tokenURIs[tokenId]` (keep in mind that `_baseURI` * is empty per default); * * - if `_tokenURIs[tokenId]` is NOT set then we fallback to `super.uri()` * which in most cases will contain `ERC1155._uri`; * * - if `_tokenURIs[tokenId]` is NOT set, and if the parents do not have a * uri value set, then the result is empty. */ function uri(uint256 tokenId) public view virtual override returns (string memory) { string memory tokenURI = _tokenURIs[tokenId]; // If token URI is set, concatenate base URI and tokenURI (via abi.encodePacked). return bytes(tokenURI).length > 0 ? string(abi.encodePacked(_baseURI, tokenURI)) : super.uri(tokenId); } /** * @dev Sets `tokenURI` as the tokenURI of `tokenId`. */ function _setURI(uint256 tokenId, string memory tokenURI) internal virtual { _tokenURIs[tokenId] = tokenURI; emit URI(uri(tokenId), tokenId); } /** * @dev Sets `baseURI` as the `_baseURI` for all tokens */ function _setBaseURI(string memory baseURI) internal virtual { _baseURI = baseURI; } }
/_openzeppelin/contracts/token/ERC1155/extensions/IERC1155MetadataURI.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/IERC1155MetadataURI.sol) pragma solidity ^0.8.0; import "../IERC1155.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 IERC1155MetadataURI is IERC1155 { /** * @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); }
/_openzeppelin/contracts/token/common/ERC2981.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (token/common/ERC2981.sol) pragma solidity ^0.8.0; import "../../interfaces/IERC2981.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information. * * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first. * * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the * fee is specified in basis points by default. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. * * _Available since v4.5._ */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @inheritdoc IERC2981 */ function royaltyInfo(uint256 _tokenId, uint256 _salePrice) public view virtual override returns (address, uint256) { RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId]; if (royalty.receiver == address(0)) { royalty = _defaultRoyaltyInfo; } uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator(); return (royalty.receiver, royaltyAmount); } /** * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an * override. */ function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } /** * @dev Sets the royalty information that all ids in this contract will default to. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: invalid receiver"); _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Removes default royalty information. */ function _deleteDefaultRoyalty() internal virtual { delete _defaultRoyaltyInfo; } /** * @dev Sets the royalty information for a specific token id, overriding the global default. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: Invalid parameters"); _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Resets royalty information for the token id back to the global default. */ function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; } }
/_openzeppelin/contracts/utils/Address.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
/_openzeppelin/contracts/utils/Context.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
/_openzeppelin/contracts/utils/Strings.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
/_openzeppelin/contracts/utils/cryptography/ECDSA.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; import "../Strings.sol"; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, 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. /// @solidity memory-safe-assembly assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else 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. /// @solidity memory-safe-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 = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); uint8 v = uint8((uint256(vs) >> 255) + 27); return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _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 Message, created from `s`. 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(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @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)); } }
/_openzeppelin/contracts/utils/cryptography/draft-EIP712.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/cryptography/draft-EIP712.sol) pragma solidity ^0.8.0; import "./ECDSA.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 EIP712 { /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; uint256 private immutable _CACHED_CHAIN_ID; address private immutable _CACHED_THIS; bytes32 private immutable _HASHED_NAME; bytes32 private immutable _HASHED_VERSION; bytes32 private immutable _TYPE_HASH; /* 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]. */ constructor(string memory name, string memory version) { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); bytes32 typeHash = keccak256( "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)" ); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; _CACHED_CHAIN_ID = block.chainid; _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion); _CACHED_THIS = address(this); _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) { return _CACHED_DOMAIN_SEPARATOR; } else { return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION); } } 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 ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } }
/_openzeppelin/contracts/utils/introspection/ERC165.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
/_openzeppelin/contracts/utils/introspection/IERC165.sol
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
/contracts/PlastikCryptoV2.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol"; import "./UtilsV2.sol"; contract PlastikCryptoV2 is Ownable, EIP712 { address priceValidator; constructor(address _priceSigner) EIP712("PLASTIK", "2.0") { priceValidator = _priceSigner; } function setPriceValidator(address newValidator) public onlyOwner returns (bool) { priceValidator = newValidator; return true; } /// @notice Verifies the signature for a given NFTVoucher, returning the address of the signer. /// @dev Will revert if the signature is invalid. Does not verify that the signer is authorized to mint NFTs. /// @param voucher An NFTVoucher describing an unminted NFT. function verifyNFTVoucher( NFTVoucherV2 calldata voucher, bytes memory signature ) public view returns (address) { bytes32 digest = _hashTypedDataV4( keccak256( abi.encode( Constants.NFTVOUCHERV2_TYPEHASH, voucher.tokenAddress, voucher.tokenId, voucher.amount, keccak256(bytes(voucher.tokenURI)), voucher.creatorAddress, voucher.royalty ) ) ); return ECDSA.recover(digest, signature); } function verifyPriceSignature( address sender, PlastikSellPrice calldata item, bytes calldata signature, address ercToken ) public view returns (address) { bytes32 digest = _hashTypedDataV4( keccak256( abi.encode( Constants.PLASTIKSELLPRICEREQUEST_TYPEHASH, item.buyer, item.ratio, item.decimals, item.currency, item.timestamp, item.tokenAddress ) ) ); address sig = ECDSA.recover(digest, signature); require(sig == priceValidator, "Price validator invalid"); require(sender == item.buyer, "Buyer sign price invalid"); require(ercToken == item.tokenAddress, "ercToken invalid"); require( block.timestamp < item.timestamp + 10 minutes, "Price is expired" ); return sig; } function verifySellerSign( SellRequest calldata item, bytes calldata signature ) public view returns (address) { bytes32 digest = _hashTypedDataV4( keccak256( abi.encode( Constants.SELLREQUEST_TYPEHASH, item.tokenAddress, item.tokenId, item.price, item.amount, item.erc20Address, item.ngoFeePct, item.sellerAddress ) ) ); return ECDSA.recover(digest, signature); } function verifySellerSellRequest( address seller, SellRequest calldata sellRequest, address tokenAddress, uint256 tokenId ) public pure { require(seller == sellRequest.sellerAddress, "Invalid seller address"); require( sellRequest.tokenAddress == tokenAddress, "Invalid token address" ); require(sellRequest.tokenId == tokenId, "Invalid token id"); } function verifyPRGVoucher(PRGVoucher calldata voucher, bytes memory signature) public view returns (address) { bytes32 digest = _hashTypedDataV4( keccak256( abi.encode( Constants.PRGVOUCHER_TYPEHASH, voucher.tokenAddress, voucher.tokenId, voucher.amount, keccak256(bytes(voucher.tokenURI)), voucher.creatorAddress ) ) ); return ECDSA.recover(digest, signature); } }
/contracts/PlastikRoleV2.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/access/AccessControl.sol"; import "./UtilsV2.sol"; contract PlastikRoleV2 is AccessControl { constructor() { _grantRole(DEFAULT_ADMIN_ROLE, _msgSender()); _grantRole(Constants.MINTER_ROLE, _msgSender()); } function grantMinterRole(address account) public { grantRole(Constants.MINTER_ROLE, account); } function verifyMinterRole(address account) public view { if (!hasRole(Constants.MINTER_ROLE, account)) { revert("Only minter role can mint"); } } }
/contracts/PlastikRoyaltyCal.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/token/common/ERC2981.sol"; interface IPlastikRoyaltyCal is IERC2981 { function setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) external; function resetTokenRoyalty(uint256 _tokenId) external; } contract PlastikRoyaltyCal is ERC2981, IPlastikRoyaltyCal { event TokenRoyaltySet(uint256 tokenId, address receiver, uint96 fee); event TokenRoyaltyReset(uint256 tokenId); function setTokenRoyalty( uint256 tokenId, address receiver, uint96 feeNumerator ) public { super._setTokenRoyalty(tokenId, receiver, feeNumerator); emit TokenRoyaltySet(tokenId, receiver, feeNumerator); } function resetTokenRoyalty(uint256 tokenId) public { super._resetTokenRoyalty(tokenId); emit TokenRoyaltyReset(tokenId); } }
/contracts/UtilsV2.sol
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; library Constants { bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE"); bytes32 constant NFTVOUCHER_TYPEHASH = keccak256( "NFTVoucher(address tokenAddress,uint256 tokenId,string tokenURI,address creatorAddress,uint96 royalty)" ); bytes32 constant NFTVOUCHERV2_TYPEHASH = keccak256( "NFTVoucherV2(address tokenAddress,uint256 tokenId,uint256 amount,string tokenURI,address creatorAddress,uint96 royalty)" ); bytes32 constant PRGVOUCHER_TYPEHASH = keccak256( "PRGVoucher(address tokenAddress,uint256 tokenId,uint256 amount,string tokenURI,address creatorAddress)" ); bytes32 constant SELLREQUEST_TYPEHASH = keccak256( "SellRequest(address tokenAddress,uint256 tokenId,uint256 price,uint256 amount,address erc20Address,uint96 ngoFeePct,address sellerAddress)" ); bytes32 constant PLASTIKSELLPRICEREQUEST_TYPEHASH = keccak256( "PlastikSellPrice(address buyer,uint256 ratio,uint256 decimals,uint96 currency,uint256 timestamp,address tokenAddress)" ); bytes32 constant BIDREQUEST_TYPEHASH = keccak256( "BidRequest(address tokenAddress,uint256 tokenId,address erc20Address,address sellerAddress,address bidderAddress,uint256 biddingPrice)" ); string public constant BASE_URI = "https://plastiks.io/ipfs/"; } /// @notice Represents an un-minted NFT, which has not yet been recorded into the blockchain. A signed voucher can be redeemed for a real NFT using the redeem function. struct NFTVoucher { /// @notice The address of the ERC721 or ERC1155 address tokenAddress; /// @notice The id of the token to be redeemed. Must be unique - if another token with this ID already exists, the redeem function will revert. uint256 tokenId; /// @notice The metadata URI to associate with this token. string tokenURI; /// @notice The address of the original signer of this lazy minting address creatorAddress; /// @notice The royalty percentage for the original creator (offset 2 digits) uint96 royalty; } /// @notice Represents an un-minted NFT, which has not yet been recorded into the blockchain. A signed voucher can be redeemed for a real NFT using the redeem function. struct NFTVoucherV2 { /// @notice The address of the ERC721 or ERC1155 address tokenAddress; /// @notice The id of the token to be redeemed. Must be unique - if another token with this ID already exists, the redeem function will revert. uint256 tokenId; /// @notice The amount of tokens to mint uint256 amount; /// @notice The metadata URI to associate with this token. string tokenURI; /// @notice The address of the original signer of this lazy minting address creatorAddress; /// @notice The royalty percentage for the original creator (offset 2 digits) uint96 royalty; } struct PRGVoucher { /// @notice The address of the ERC721 or ERC1155 address tokenAddress; /// @notice The id of the token to be redeemed. Must be unique - if another token with this ID already exists, the redeem function will revert. uint256 tokenId; /// @notice The amount of tokens to mint uint256 amount; /// @notice The metadata URI to associate with this token. string tokenURI; /// @notice The address of the original signer of this lazy minting address creatorAddress; } struct SellRequest { address tokenAddress; uint256 tokenId; uint256 price; uint256 amount; address erc20Address; uint96 ngoFeePct; address sellerAddress; } struct PlastikSellPrice { address buyer; uint256 ratio; uint256 decimals; uint96 currency; uint256 timestamp; address tokenAddress; } interface IPlastikArtLazyMint { function safeLazyMint( address buyer, NFTVoucherV2 calldata voucher, bytes calldata signature ) external payable returns (uint256); } interface IPlastikRRGLazyMint { function safeLazyMint( address buyer, NFTVoucherV2 calldata voucher, bytes calldata signature ) external payable returns (uint256); } interface IPlastikPRGLazyMint { function safeLazyMint( address buyer, PRGVoucher calldata voucher, bytes calldata signature ) external payable returns (uint256); }
Contract ABI
[{"type":"constructor","stateMutability":"nonpayable","inputs":[{"type":"address","name":"_royaltyCal","internalType":"address"},{"type":"address","name":"_plastikCrypto","internalType":"address"},{"type":"address","name":"_plastikRole","internalType":"address"}]},{"type":"event","name":"ApprovalForAll","inputs":[{"type":"address","name":"account","internalType":"address","indexed":true},{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"bool","name":"approved","internalType":"bool","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"PlastikNFTMultiMinted","inputs":[{"type":"address","name":"mintTo","internalType":"address","indexed":false},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":false},{"type":"uint256","name":"amount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"TransferBatch","inputs":[{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256[]","name":"ids","internalType":"uint256[]","indexed":false},{"type":"uint256[]","name":"values","internalType":"uint256[]","indexed":false}],"anonymous":false},{"type":"event","name":"TransferSingle","inputs":[{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"id","internalType":"uint256","indexed":false},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"URI","inputs":[{"type":"string","name":"value","internalType":"string","indexed":false},{"type":"uint256","name":"id","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"account","internalType":"address"},{"type":"uint256","name":"id","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256[]","name":"","internalType":"uint256[]"}],"name":"balanceOfBatch","inputs":[{"type":"address[]","name":"accounts","internalType":"address[]"},{"type":"uint256[]","name":"ids","internalType":"uint256[]"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"burn","inputs":[{"type":"address","name":"account","internalType":"address"},{"type":"uint256","name":"id","internalType":"uint256"},{"type":"uint256","name":"value","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"burnBatch","inputs":[{"type":"address","name":"account","internalType":"address"},{"type":"uint256[]","name":"ids","internalType":"uint256[]"},{"type":"uint256[]","name":"values","internalType":"uint256[]"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"exists","inputs":[{"type":"uint256","name":"id","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isApprovedForAll","inputs":[{"type":"address","name":"account","internalType":"address"},{"type":"address","name":"operator","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"mint","inputs":[{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"id","internalType":"uint256"},{"type":"uint256","name":"amount","internalType":"uint256"},{"type":"string","name":"tokenURI","internalType":"string"},{"type":"uint96","name":"royaltyFee","internalType":"uint96"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"mintBatch","inputs":[{"type":"address","name":"to","internalType":"address"},{"type":"uint256[]","name":"ids","internalType":"uint256[]"},{"type":"uint256[]","name":"amounts","internalType":"uint256[]"},{"type":"string[]","name":"uris","internalType":"string[]"},{"type":"uint96[]","name":"royaltyFee","internalType":"uint96[]"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeBatchTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256[]","name":"ids","internalType":"uint256[]"},{"type":"uint256[]","name":"amounts","internalType":"uint256[]"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"payable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"safeLazyMint","inputs":[{"type":"address","name":"buyer","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"},{"type":"tuple","name":"voucher","internalType":"struct NFTVoucherV2","components":[{"type":"address","name":"tokenAddress","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"uint256","name":"amount","internalType":"uint256"},{"type":"string","name":"tokenURI","internalType":"string"},{"type":"address","name":"creatorAddress","internalType":"address"},{"type":"uint96","name":"royalty","internalType":"uint96"}]},{"type":"bytes","name":"signature","internalType":"bytes"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"id","internalType":"uint256"},{"type":"uint256","name":"amount","internalType":"uint256"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setApprovalForAll","inputs":[{"type":"address","name":"operator","internalType":"address"},{"type":"bool","name":"approved","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setBaseURI","inputs":[{"type":"string","name":"newuri","internalType":"string"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"supportsInterface","inputs":[{"type":"bytes4","name":"interfaceId","internalType":"bytes4"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[{"type":"uint256","name":"id","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"uri","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]}]
Contract Creation Code
0x608060405260405180602001604052806000815250600490805190602001906200002b9291906200027b565b503480156200003957600080fd5b50604051620055cd380380620055cd83398181016040528101906200005f919062000395565b6040518060400160405280601881526020017f68747470733a2f2f706c617374696b732e696f2f697066730000000000000000815250620000b5620000a96200019360201b60201c565b6200019b60201b60201c565b620000c6816200025f60201b60201c565b5082600760006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555081600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080600960006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505062000456565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8060039080519060200190620002779291906200027b565b5050565b828054620002899062000420565b90600052602060002090601f016020900481019282620002ad5760008555620002f9565b82601f10620002c857805160ff1916838001178555620002f9565b82800160010185558215620002f9579182015b82811115620002f8578251825591602001919060010190620002db565b5b5090506200030891906200030c565b5090565b5b80821115620003275760008160009055506001016200030d565b5090565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200035d8262000330565b9050919050565b6200036f8162000350565b81146200037b57600080fd5b50565b6000815190506200038f8162000364565b92915050565b600080600060608486031215620003b157620003b06200032b565b5b6000620003c1868287016200037e565b9350506020620003d4868287016200037e565b9250506040620003e7868287016200037e565b9150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806200043957607f821691505b6020821081141562000450576200044f620003f1565b5b50919050565b61516780620004666000396000f3fe6080604052600436106101135760003560e01c80636b20c454116100a0578063caeeef1a11610064578063caeeef1a146103d9578063e985e9c514610402578063f242432a1461043f578063f2fde38b14610468578063f5298aca1461049157610113565b80636b20c45414610308578063715018a6146103315780638da5cb5b14610348578063a22cb46514610373578063bd85b0391461039c57610113565b80632eb2c2d6116100e75780632eb2c2d6146101ff578063309b9a98146102285780634e1273f4146102655780634f558e79146102a257806355f804b3146102df57610113565b8062fdd58e1461011857806301ffc9a7146101555780630e89341c146101925780631dca5f9b146101cf575b600080fd5b34801561012457600080fd5b5061013f600480360381019061013a9190612ff7565b6104ba565b60405161014c9190613046565b60405180910390f35b34801561016157600080fd5b5061017c600480360381019061017791906130b9565b610584565b6040516101899190613101565b60405180910390f35b34801561019e57600080fd5b506101b960048036038101906101b4919061311c565b610596565b6040516101c691906131e2565b60405180910390f35b6101e960048036038101906101e4919061335d565b6105a8565b6040516101f69190613046565b60405180910390f35b34801561020b57600080fd5b50610226600480360381019061022191906134f4565b6109c1565b005b34801561023457600080fd5b5061024f600480360381019061024a91906136a8565b610a62565b60405161025c9190613046565b60405180910390f35b34801561027157600080fd5b5061028c60048036038101906102879190613830565b610c27565b6040516102999190613966565b60405180910390f35b3480156102ae57600080fd5b506102c960048036038101906102c4919061311c565b610d40565b6040516102d69190613101565b60405180910390f35b3480156102eb57600080fd5b5061030660048036038101906103019190613988565b610d54565b005b34801561031457600080fd5b5061032f600480360381019061032a91906139d1565b610d68565b005b34801561033d57600080fd5b50610346610e05565b005b34801561035457600080fd5b5061035d610e19565b60405161036a9190613a6b565b60405180910390f35b34801561037f57600080fd5b5061039a60048036038101906103959190613ab2565b610e42565b005b3480156103a857600080fd5b506103c360048036038101906103be919061311c565b610e58565b6040516103d09190613046565b60405180910390f35b3480156103e557600080fd5b5061040060048036038101906103fb9190613c96565b610e75565b005b34801561040e57600080fd5b5061042960048036038101906104249190613daf565b611133565b6040516104369190613101565b60405180910390f35b34801561044b57600080fd5b5061046660048036038101906104619190613def565b6111c7565b005b34801561047457600080fd5b5061048f600480360381019061048a9190613e86565b611268565b005b34801561049d57600080fd5b506104b860048036038101906104b39190613eb3565b6112ec565b005b60008073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561052b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161052290613f78565b60405180910390fd5b6001600083815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600061058f82611389565b9050919050565b60606105a18261146b565b9050919050565b60006105b2610e19565b73ffffffffffffffffffffffffffffffffffffffff166105d0611550565b73ffffffffffffffffffffffffffffffffffffffff161461067e57600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610631611550565b6040518263ffffffff1660e01b815260040161064d9190613a6b565b60006040518083038186803b15801561066557600080fd5b505afa158015610679573d6000803e3d6000fd5b505050505b3073ffffffffffffffffffffffffffffffffffffffff168460000160208101906106a89190613e86565b73ffffffffffffffffffffffffffffffffffffffff16146106fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106f59061400a565b60405180910390fd5b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d879253a86866040518363ffffffff1660e01b815260040161075d92919061424d565b60206040518083038186803b15801561077557600080fd5b505afa158015610789573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ad9190614299565b90508460800160208101906107c29190613e86565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461082f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161082690614312565b60405180910390fd5b61083c8560200135610d40565b61099f57610854818660200135876040013586611558565b6108b4856020013586806060019061086c9190614341565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505061170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c7538660200135838860a001602081019061090b91906143a4565b6040518463ffffffff1660e01b8152600401610929939291906143e0565b600060405180830381600087803b15801561094357600080fd5b505af1158015610957573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f818660200135876040013560405161099693929190614417565b60405180910390a15b6109b08188876020013589876111c7565b846020013591505095945050505050565b6109c9611550565b73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161480610a0f5750610a0e85610a09611550565b611133565b5b610a4e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a45906144c0565b60405180910390fd5b610a5b8585858585611776565b5050505050565b6000610a6c610e19565b73ffffffffffffffffffffffffffffffffffffffff16610a8a611550565b73ffffffffffffffffffffffffffffffffffffffff1614610b3857600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610aeb611550565b6040518263ffffffff1660e01b8152600401610b079190613a6b565b60006040518083038186803b158015610b1f57600080fd5b505afa158015610b33573d6000803e3d6000fd5b505050505b610b4487878785611558565b610b4e868561170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c7538789866040518463ffffffff1660e01b8152600401610bad939291906143e0565b600060405180830381600087803b158015610bc757600080fd5b505af1158015610bdb573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f878787604051610c1293929190614417565b60405180910390a18590509695505050505050565b60608151835114610c6d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c6490614552565b60405180910390fd5b6000835167ffffffffffffffff811115610c8a57610c89613232565b5b604051908082528060200260200182016040528015610cb85781602001602082028036833780820191505090505b50905060005b8451811015610d3557610d05858281518110610cdd57610cdc614572565b5b6020026020010151858381518110610cf857610cf7614572565b5b60200260200101516104ba565b828281518110610d1857610d17614572565b5b60200260200101818152505080610d2e906145d0565b9050610cbe565b508091505092915050565b600080610d4c83610e58565b119050919050565b610d5c611a9b565b610d6581611b19565b50565b610d70611550565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161480610db65750610db583610db0611550565b611133565b5b610df5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dec906144c0565b60405180910390fd5b610e00838383611b33565b505050565b610e0d611a9b565b610e176000611e04565b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610e54610e4d611550565b8383611ec8565b5050565b600060066000838152602001908152602001600020549050919050565b610e7d610e19565b73ffffffffffffffffffffffffffffffffffffffff16610e9b611550565b73ffffffffffffffffffffffffffffffffffffffff1614610f4957600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610efc611550565b6040518263ffffffff1660e01b8152600401610f189190613a6b565b60006040518083038186803b158015610f3057600080fd5b505afa158015610f44573d6000803e3d6000fd5b505050505b8351835114610f8d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f849061468b565b60405180910390fd5b610f9986868684612035565b60005b835181101561112a57610fe3868281518110610fbb57610fba614572565b5b6020026020010151858381518110610fd657610fd5614572565b5b602002602001015161170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c75387838151811061103457611033614572565b5b6020026020010151898685815181106110505761104f614572565b5b60200260200101516040518463ffffffff1660e01b8152600401611076939291906143e0565b600060405180830381600087803b15801561109057600080fd5b505af11580156110a4573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f878783815181106110dd576110dc614572565b5b60200260200101518784815181106110f8576110f7614572565b5b602002602001015160405161110f93929190614417565b60405180910390a18080611122906145d0565b915050610f9c565b50505050505050565b6000600260008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6111cf611550565b73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff16148061121557506112148561120f611550565b611133565b5b611254576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161124b906144c0565b60405180910390fd5b6112618585858585612263565b5050505050565b611270611a9b565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156112e0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016112d79061471d565b60405180910390fd5b6112e981611e04565b50565b6112f4611550565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16148061133a575061133983611334611550565b611133565b5b611379576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611370906144c0565b60405180910390fd5b611384838383612502565b505050565b60007fd9b67a26000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061145457507f0e89341c000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b8061146457506114638261274b565b5b9050919050565b6060600060056000848152602001908152602001600020805461148d9061476c565b80601f01602080910402602001604051908101604052809291908181526020018280546114b99061476c565b80156115065780601f106114db57610100808354040283529160200191611506565b820191906000526020600020905b8154815290600101906020018083116114e957829003601f168201915b5050505050905060008151116115245761151f836127b5565b611548565b60048160405160200161153892919061486e565b6040516020818303038152906040525b915050919050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156115c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115bf90614904565b60405180910390fd5b60006115d2611550565b905060006115df85612849565b905060006115ec85612849565b90506115fd836000898585896128c3565b846001600088815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825461165d9190614924565b925050819055508673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6289896040516116db92919061497a565b60405180910390a46116f2836000898585896128d9565b611701836000898989896128e1565b50505050505050565b80600560008481526020019081526020016000209080519060200190611731929190612eac565b50817f6bb7ff708619ba0610cba295a58592e0451dee2622938c8755667688daf3529b61175d84610596565b60405161176a91906131e2565b60405180910390a25050565b81518351146117ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117b190614a15565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16141561182a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161182190614aa7565b60405180910390fd5b6000611834611550565b90506118448187878787876128c3565b60005b84518110156119f857600085828151811061186557611864614572565b5b60200260200101519050600085838151811061188457611883614572565b5b6020026020010151905060006001600084815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015611926576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161191d90614b39565b60405180910390fd5b8181036001600085815260200190815260200160002060008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816001600085815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546119dd9190614924565b92505081905550505050806119f1906145d0565b9050611847565b508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611a6f929190614b59565b60405180910390a4611a858187878787876128d9565b611a93818787878787612ac8565b505050505050565b611aa3611550565b73ffffffffffffffffffffffffffffffffffffffff16611ac1610e19565b73ffffffffffffffffffffffffffffffffffffffff1614611b17576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b0e90614bdc565b60405180910390fd5b565b8060049080519060200190611b2f929190612eac565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611ba3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b9a90614c6e565b60405180910390fd5b8051825114611be7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bde90614a15565b60405180910390fd5b6000611bf1611550565b9050611c11818560008686604051806020016040528060008152506128c3565b60005b8351811015611d60576000848281518110611c3257611c31614572565b5b602002602001015190506000848381518110611c5157611c50614572565b5b6020026020010151905060006001600084815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015611cf3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cea90614d00565b60405180910390fd5b8181036001600085815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050508080611d58906145d0565b915050611c14565b50600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051611dd8929190614b59565b60405180910390a4611dfe818560008686604051806020016040528060008152506128d9565b50505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611f37576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f2e90614d92565b60405180910390fd5b80600260008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516120289190613101565b60405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156120a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161209c90614904565b60405180910390fd5b81518351146120e9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120e090614a15565b60405180910390fd5b60006120f3611550565b9050612104816000878787876128c3565b60005b84518110156121be5783818151811061212357612122614572565b5b60200260200101516001600087848151811061214257612141614572565b5b6020026020010151815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546121a49190614924565b9250508190555080806121b6906145d0565b915050612107565b508473ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612236929190614b59565b60405180910390a461224d816000878787876128d9565b61225c81600087878787612ac8565b5050505050565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156122d3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ca90614aa7565b60405180910390fd5b60006122dd611550565b905060006122ea85612849565b905060006122f785612849565b90506123078389898585896128c3565b60006001600088815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508581101561239f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161239690614b39565b60405180910390fd5b8581036001600089815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550856001600089815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546124569190614924565b925050819055508773ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628a8a6040516124d392919061497a565b60405180910390a46124e9848a8a86868a6128d9565b6124f7848a8a8a8a8a6128e1565b505050505050505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612572576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161256990614c6e565b60405180910390fd5b600061257c611550565b9050600061258984612849565b9050600061259684612849565b90506125b6838760008585604051806020016040528060008152506128c3565b60006001600087815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508481101561264e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161264590614d00565b60405180910390fd5b8481036001600088815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62898960405161271c92919061497a565b60405180910390a4612742848860008686604051806020016040528060008152506128d9565b50505050505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b6060600380546127c49061476c565b80601f01602080910402602001604051908101604052809291908181526020018280546127f09061476c565b801561283d5780601f106128125761010080835404028352916020019161283d565b820191906000526020600020905b81548152906001019060200180831161282057829003601f168201915b50505050509050919050565b60606000600167ffffffffffffffff81111561286857612867613232565b5b6040519080825280602002602001820160405280156128965781602001602082028036833780820191505090505b50905082816000815181106128ae576128ad614572565b5b60200260200101818152505080915050919050565b6128d1868686868686612caf565b505050505050565b505050505050565b6129008473ffffffffffffffffffffffffffffffffffffffff16612e81565b15612ac0578373ffffffffffffffffffffffffffffffffffffffff1663f23a6e6187878686866040518663ffffffff1660e01b8152600401612946959493929190614db2565b602060405180830381600087803b15801561296057600080fd5b505af192505050801561299157506040513d601f19601f8201168201806040525081019061298e9190614e21565b60015b612a375761299d614e5b565b806308c379a014156129fa57506129b2614e7d565b806129bd57506129fc565b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016129f191906131e2565b60405180910390fd5b505b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612a2e90614f85565b60405180910390fd5b63f23a6e6160e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612abe576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612ab590615017565b60405180910390fd5b505b505050505050565b612ae78473ffffffffffffffffffffffffffffffffffffffff16612e81565b15612ca7578373ffffffffffffffffffffffffffffffffffffffff1663bc197c8187878686866040518663ffffffff1660e01b8152600401612b2d959493929190615037565b602060405180830381600087803b158015612b4757600080fd5b505af1925050508015612b7857506040513d601f19601f82011682018060405250810190612b759190614e21565b60015b612c1e57612b84614e5b565b806308c379a01415612be15750612b99614e7d565b80612ba45750612be3565b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bd891906131e2565b60405180910390fd5b505b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612c1590614f85565b60405180910390fd5b63bc197c8160e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612ca5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612c9c90615017565b60405180910390fd5b505b505050505050565b612cbd868686868686612ea4565b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415612d6f5760005b8351811015612d6d57828181518110612d1157612d10614572565b5b602002602001015160066000868481518110612d3057612d2f614572565b5b602002602001015181526020019081526020016000206000828254612d559190614924565b9250508190555080612d66906145d0565b9050612cf5565b505b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161415612e795760005b8351811015612e77576000848281518110612dc557612dc4614572565b5b602002602001015190506000848381518110612de457612de3614572565b5b6020026020010151905060006006600084815260200190815260200160002054905081811015612e49576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612e4090615111565b60405180910390fd5b818103600660008581526020019081526020016000208190555050505080612e70906145d0565b9050612da7565b505b505050505050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b505050505050565b828054612eb89061476c565b90600052602060002090601f016020900481019282612eda5760008555612f21565b82601f10612ef357805160ff1916838001178555612f21565b82800160010185558215612f21579182015b82811115612f20578251825591602001919060010190612f05565b5b509050612f2e9190612f32565b5090565b5b80821115612f4b576000816000905550600101612f33565b5090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000612f8e82612f63565b9050919050565b612f9e81612f83565b8114612fa957600080fd5b50565b600081359050612fbb81612f95565b92915050565b6000819050919050565b612fd481612fc1565b8114612fdf57600080fd5b50565b600081359050612ff181612fcb565b92915050565b6000806040838503121561300e5761300d612f59565b5b600061301c85828601612fac565b925050602061302d85828601612fe2565b9150509250929050565b61304081612fc1565b82525050565b600060208201905061305b6000830184613037565b92915050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61309681613061565b81146130a157600080fd5b50565b6000813590506130b38161308d565b92915050565b6000602082840312156130cf576130ce612f59565b5b60006130dd848285016130a4565b91505092915050565b60008115159050919050565b6130fb816130e6565b82525050565b600060208201905061311660008301846130f2565b92915050565b60006020828403121561313257613131612f59565b5b600061314084828501612fe2565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613183578082015181840152602081019050613168565b83811115613192576000848401525b50505050565b6000601f19601f8301169050919050565b60006131b482613149565b6131be8185613154565b93506131ce818560208601613165565b6131d781613198565b840191505092915050565b600060208201905081810360008301526131fc81846131a9565b905092915050565b600080fd5b600060c0828403121561321f5761321e613204565b5b81905092915050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61326a82613198565b810181811067ffffffffffffffff8211171561328957613288613232565b5b80604052505050565b600061329c612f4f565b90506132a88282613261565b919050565b600067ffffffffffffffff8211156132c8576132c7613232565b5b6132d182613198565b9050602081019050919050565b82818337600083830152505050565b60006133006132fb846132ad565b613292565b90508281526020810184848401111561331c5761331b61322d565b5b6133278482856132de565b509392505050565b600082601f83011261334457613343613228565b5b81356133548482602086016132ed565b91505092915050565b600080600080600060a0868803121561337957613378612f59565b5b600061338788828901612fac565b955050602061339888828901612fe2565b945050604086013567ffffffffffffffff8111156133b9576133b8612f5e565b5b6133c588828901613209565b935050606086013567ffffffffffffffff8111156133e6576133e5612f5e565b5b6133f28882890161332f565b925050608086013567ffffffffffffffff81111561341357613412612f5e565b5b61341f8882890161332f565b9150509295509295909350565b600067ffffffffffffffff82111561344757613446613232565b5b602082029050602081019050919050565b600080fd5b600061347061346b8461342c565b613292565b9050808382526020820190506020840283018581111561349357613492613458565b5b835b818110156134bc57806134a88882612fe2565b845260208401935050602081019050613495565b5050509392505050565b600082601f8301126134db576134da613228565b5b81356134eb84826020860161345d565b91505092915050565b600080600080600060a086880312156135105761350f612f59565b5b600061351e88828901612fac565b955050602061352f88828901612fac565b945050604086013567ffffffffffffffff8111156135505761354f612f5e565b5b61355c888289016134c6565b935050606086013567ffffffffffffffff81111561357d5761357c612f5e565b5b613589888289016134c6565b925050608086013567ffffffffffffffff8111156135aa576135a9612f5e565b5b6135b68882890161332f565b9150509295509295909350565b600067ffffffffffffffff8211156135de576135dd613232565b5b6135e782613198565b9050602081019050919050565b6000613607613602846135c3565b613292565b9050828152602081018484840111156136235761362261322d565b5b61362e8482856132de565b509392505050565b600082601f83011261364b5761364a613228565b5b813561365b8482602086016135f4565b91505092915050565b60006bffffffffffffffffffffffff82169050919050565b61368581613664565b811461369057600080fd5b50565b6000813590506136a28161367c565b92915050565b60008060008060008060c087890312156136c5576136c4612f59565b5b60006136d389828a01612fac565b96505060206136e489828a01612fe2565b95505060406136f589828a01612fe2565b945050606087013567ffffffffffffffff81111561371657613715612f5e565b5b61372289828a01613636565b935050608061373389828a01613693565b92505060a087013567ffffffffffffffff81111561375457613753612f5e565b5b61376089828a0161332f565b9150509295509295509295565b600067ffffffffffffffff82111561378857613787613232565b5b602082029050602081019050919050565b60006137ac6137a78461376d565b613292565b905080838252602082019050602084028301858111156137cf576137ce613458565b5b835b818110156137f857806137e48882612fac565b8452602084019350506020810190506137d1565b5050509392505050565b600082601f83011261381757613816613228565b5b8135613827848260208601613799565b91505092915050565b6000806040838503121561384757613846612f59565b5b600083013567ffffffffffffffff81111561386557613864612f5e565b5b61387185828601613802565b925050602083013567ffffffffffffffff81111561389257613891612f5e565b5b61389e858286016134c6565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6138dd81612fc1565b82525050565b60006138ef83836138d4565b60208301905092915050565b6000602082019050919050565b6000613913826138a8565b61391d81856138b3565b9350613928836138c4565b8060005b8381101561395957815161394088826138e3565b975061394b836138fb565b92505060018101905061392c565b5085935050505092915050565b600060208201905081810360008301526139808184613908565b905092915050565b60006020828403121561399e5761399d612f59565b5b600082013567ffffffffffffffff8111156139bc576139bb612f5e565b5b6139c884828501613636565b91505092915050565b6000806000606084860312156139ea576139e9612f59565b5b60006139f886828701612fac565b935050602084013567ffffffffffffffff811115613a1957613a18612f5e565b5b613a25868287016134c6565b925050604084013567ffffffffffffffff811115613a4657613a45612f5e565b5b613a52868287016134c6565b9150509250925092565b613a6581612f83565b82525050565b6000602082019050613a806000830184613a5c565b92915050565b613a8f816130e6565b8114613a9a57600080fd5b50565b600081359050613aac81613a86565b92915050565b60008060408385031215613ac957613ac8612f59565b5b6000613ad785828601612fac565b9250506020613ae885828601613a9d565b9150509250929050565b600067ffffffffffffffff821115613b0d57613b0c613232565b5b602082029050602081019050919050565b6000613b31613b2c84613af2565b613292565b90508083825260208201905060208402830185811115613b5457613b53613458565b5b835b81811015613b9b57803567ffffffffffffffff811115613b7957613b78613228565b5b808601613b868982613636565b85526020850194505050602081019050613b56565b5050509392505050565b600082601f830112613bba57613bb9613228565b5b8135613bca848260208601613b1e565b91505092915050565b600067ffffffffffffffff821115613bee57613bed613232565b5b602082029050602081019050919050565b6000613c12613c0d84613bd3565b613292565b90508083825260208201905060208402830185811115613c3557613c34613458565b5b835b81811015613c5e5780613c4a8882613693565b845260208401935050602081019050613c37565b5050509392505050565b600082601f830112613c7d57613c7c613228565b5b8135613c8d848260208601613bff565b91505092915050565b60008060008060008060c08789031215613cb357613cb2612f59565b5b6000613cc189828a01612fac565b965050602087013567ffffffffffffffff811115613ce257613ce1612f5e565b5b613cee89828a016134c6565b955050604087013567ffffffffffffffff811115613d0f57613d0e612f5e565b5b613d1b89828a016134c6565b945050606087013567ffffffffffffffff811115613d3c57613d3b612f5e565b5b613d4889828a01613ba5565b935050608087013567ffffffffffffffff811115613d6957613d68612f5e565b5b613d7589828a01613c68565b92505060a087013567ffffffffffffffff811115613d9657613d95612f5e565b5b613da289828a0161332f565b9150509295509295509295565b60008060408385031215613dc657613dc5612f59565b5b6000613dd485828601612fac565b9250506020613de585828601612fac565b9150509250929050565b600080600080600060a08688031215613e0b57613e0a612f59565b5b6000613e1988828901612fac565b9550506020613e2a88828901612fac565b9450506040613e3b88828901612fe2565b9350506060613e4c88828901612fe2565b925050608086013567ffffffffffffffff811115613e6d57613e6c612f5e565b5b613e798882890161332f565b9150509295509295909350565b600060208284031215613e9c57613e9b612f59565b5b6000613eaa84828501612fac565b91505092915050565b600080600060608486031215613ecc57613ecb612f59565b5b6000613eda86828701612fac565b9350506020613eeb86828701612fe2565b9250506040613efc86828701612fe2565b9150509250925092565b7f455243313135353a2061646472657373207a65726f206973206e6f742061207660008201527f616c6964206f776e657200000000000000000000000000000000000000000000602082015250565b6000613f62602a83613154565b9150613f6d82613f06565b604082019050919050565b60006020820190508181036000830152613f9181613f55565b9050919050565b7f54686520766f7563686572206d75737420626520666f72207468697320636f6e60008201527f7472616374000000000000000000000000000000000000000000000000000000602082015250565b6000613ff4602583613154565b9150613fff82613f98565b604082019050919050565b6000602082019050818103600083015261402381613fe7565b9050919050565b60006140396020840184612fac565b905092915050565b61404a81612f83565b82525050565b600061405f6020840184612fe2565b905092915050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261409357614092614071565b5b83810192508235915060208301925067ffffffffffffffff8211156140bb576140ba614067565b5b6001820236038413156140d1576140d061406c565b5b509250929050565b600082825260208201905092915050565b60006140f683856140d9565b93506141038385846132de565b61410c83613198565b840190509392505050565b60006141266020840184613693565b905092915050565b61413781613664565b82525050565b600060c08301614150600084018461402a565b61415d6000860182614041565b5061416b6020840184614050565b61417860208601826138d4565b506141866040840184614050565b61419360408601826138d4565b506141a16060840184614076565b85830360608701526141b48382846140ea565b925050506141c5608084018461402a565b6141d26080860182614041565b506141e060a0840184614117565b6141ed60a086018261412e565b508091505092915050565b600081519050919050565b600082825260208201905092915050565b600061421f826141f8565b6142298185614203565b9350614239818560208601613165565b61424281613198565b840191505092915050565b60006040820190508181036000830152614267818561413d565b9050818103602083015261427b8184614214565b90509392505050565b60008151905061429381612f95565b92915050565b6000602082840312156142af576142ae612f59565b5b60006142bd84828501614284565b91505092915050565b7f43726561746f72204164647265737320646f6573206e6f74206d617463680000600082015250565b60006142fc601e83613154565b9150614307826142c6565b602082019050919050565b6000602082019050818103600083015261432b816142ef565b9050919050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261435e5761435d614332565b5b80840192508235915067ffffffffffffffff8211156143805761437f614337565b5b60208301925060018202360383131561439c5761439b61433c565b5b509250929050565b6000602082840312156143ba576143b9612f59565b5b60006143c884828501613693565b91505092915050565b6143da81613664565b82525050565b60006060820190506143f56000830186613037565b6144026020830185613a5c565b61440f60408301846143d1565b949350505050565b600060608201905061442c6000830186613a5c565b6144396020830185613037565b6144466040830184613037565b949350505050565b7f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60008201527f6572206e6f7220617070726f7665640000000000000000000000000000000000602082015250565b60006144aa602f83613154565b91506144b58261444e565b604082019050919050565b600060208201905081810360008301526144d98161449d565b9050919050565b7f455243313135353a206163636f756e747320616e6420696473206c656e67746860008201527f206d69736d617463680000000000000000000000000000000000000000000000602082015250565b600061453c602983613154565b9150614547826144e0565b604082019050919050565b6000602082019050818103600083015261456b8161452f565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006145db82612fc1565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561460e5761460d6145a1565b5b600182019050919050565b7f455243313135353a207572697320616e6420616d6f756e7473206c656e67746860008201527f206d69736d617463680000000000000000000000000000000000000000000000602082015250565b6000614675602983613154565b915061468082614619565b604082019050919050565b600060208201905081810360008301526146a481614668565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614707602683613154565b9150614712826146ab565b604082019050919050565b60006020820190508181036000830152614736816146fa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061478457607f821691505b602082108114156147985761479761473d565b5b50919050565b600081905092915050565b60008190508160005260206000209050919050565b600081546147cb8161476c565b6147d5818661479e565b945060018216600081146147f0576001811461480157614834565b60ff19831686528186019350614834565b61480a856147a9565b60005b8381101561482c5781548189015260018201915060208101905061480d565b838801955050505b50505092915050565b600061484882613149565b614852818561479e565b9350614862818560208601613165565b80840191505092915050565b600061487a82856147be565b9150614886828461483d565b91508190509392505050565b7f455243313135353a206d696e7420746f20746865207a65726f2061646472657360008201527f7300000000000000000000000000000000000000000000000000000000000000602082015250565b60006148ee602183613154565b91506148f982614892565b604082019050919050565b6000602082019050818103600083015261491d816148e1565b9050919050565b600061492f82612fc1565b915061493a83612fc1565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0382111561496f5761496e6145a1565b5b828201905092915050565b600060408201905061498f6000830185613037565b61499c6020830184613037565b9392505050565b7f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682060008201527f6d69736d61746368000000000000000000000000000000000000000000000000602082015250565b60006149ff602883613154565b9150614a0a826149a3565b604082019050919050565b60006020820190508181036000830152614a2e816149f2565b9050919050565b7f455243313135353a207472616e7366657220746f20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b6000614a91602583613154565b9150614a9c82614a35565b604082019050919050565b60006020820190508181036000830152614ac081614a84565b9050919050565b7f455243313135353a20696e73756666696369656e742062616c616e636520666f60008201527f72207472616e7366657200000000000000000000000000000000000000000000602082015250565b6000614b23602a83613154565b9150614b2e82614ac7565b604082019050919050565b60006020820190508181036000830152614b5281614b16565b9050919050565b60006040820190508181036000830152614b738185613908565b90508181036020830152614b878184613908565b90509392505050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614bc6602083613154565b9150614bd182614b90565b602082019050919050565b60006020820190508181036000830152614bf581614bb9565b9050919050565b7f455243313135353a206275726e2066726f6d20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b6000614c58602383613154565b9150614c6382614bfc565b604082019050919050565b60006020820190508181036000830152614c8781614c4b565b9050919050565b7f455243313135353a206275726e20616d6f756e7420657863656564732062616c60008201527f616e636500000000000000000000000000000000000000000000000000000000602082015250565b6000614cea602483613154565b9150614cf582614c8e565b604082019050919050565b60006020820190508181036000830152614d1981614cdd565b9050919050565b7f455243313135353a2073657474696e6720617070726f76616c2073746174757360008201527f20666f722073656c660000000000000000000000000000000000000000000000602082015250565b6000614d7c602983613154565b9150614d8782614d20565b604082019050919050565b60006020820190508181036000830152614dab81614d6f565b9050919050565b600060a082019050614dc76000830188613a5c565b614dd46020830187613a5c565b614de16040830186613037565b614dee6060830185613037565b8181036080830152614e008184614214565b90509695505050505050565b600081519050614e1b8161308d565b92915050565b600060208284031215614e3757614e36612f59565b5b6000614e4584828501614e0c565b91505092915050565b60008160e01c9050919050565b600060033d1115614e7a5760046000803e614e77600051614e4e565b90505b90565b600060443d1015614e8d57614f10565b614e95612f4f565b60043d036004823e80513d602482011167ffffffffffffffff82111715614ebd575050614f10565b808201805167ffffffffffffffff811115614edb5750505050614f10565b80602083010160043d038501811115614ef8575050505050614f10565b614f0782602001850186613261565b82955050505050505b90565b7f455243313135353a207472616e7366657220746f206e6f6e204552433131353560008201527f526563656976657220696d706c656d656e746572000000000000000000000000602082015250565b6000614f6f603483613154565b9150614f7a82614f13565b604082019050919050565b60006020820190508181036000830152614f9e81614f62565b9050919050565b7f455243313135353a204552433131353552656365697665722072656a6563746560008201527f6420746f6b656e73000000000000000000000000000000000000000000000000602082015250565b6000615001602883613154565b915061500c82614fa5565b604082019050919050565b6000602082019050818103600083015261503081614ff4565b9050919050565b600060a08201905061504c6000830188613a5c565b6150596020830187613a5c565b818103604083015261506b8186613908565b9050818103606083015261507f8185613908565b905081810360808301526150938184614214565b90509695505050505050565b7f455243313135353a206275726e20616d6f756e74206578636565647320746f7460008201527f616c537570706c79000000000000000000000000000000000000000000000000602082015250565b60006150fb602883613154565b91506151068261509f565b604082019050919050565b6000602082019050818103600083015261512a816150ee565b905091905056fea2646970667358221220c21316744a9f859f1f6a7eeff58767e40e89d2cf0e9d0b2e9870e4087c87c8f464736f6c634300080900330000000000000000000000004311ba6e4584f1b5ce5237f23e80a0360ba9763e00000000000000000000000033c37b39f226823d23bfe74aa538948c0e999293000000000000000000000000389dcc5a90523ad23d5e846f067fd461668b1779
Deployed ByteCode
0x6080604052600436106101135760003560e01c80636b20c454116100a0578063caeeef1a11610064578063caeeef1a146103d9578063e985e9c514610402578063f242432a1461043f578063f2fde38b14610468578063f5298aca1461049157610113565b80636b20c45414610308578063715018a6146103315780638da5cb5b14610348578063a22cb46514610373578063bd85b0391461039c57610113565b80632eb2c2d6116100e75780632eb2c2d6146101ff578063309b9a98146102285780634e1273f4146102655780634f558e79146102a257806355f804b3146102df57610113565b8062fdd58e1461011857806301ffc9a7146101555780630e89341c146101925780631dca5f9b146101cf575b600080fd5b34801561012457600080fd5b5061013f600480360381019061013a9190612ff7565b6104ba565b60405161014c9190613046565b60405180910390f35b34801561016157600080fd5b5061017c600480360381019061017791906130b9565b610584565b6040516101899190613101565b60405180910390f35b34801561019e57600080fd5b506101b960048036038101906101b4919061311c565b610596565b6040516101c691906131e2565b60405180910390f35b6101e960048036038101906101e4919061335d565b6105a8565b6040516101f69190613046565b60405180910390f35b34801561020b57600080fd5b50610226600480360381019061022191906134f4565b6109c1565b005b34801561023457600080fd5b5061024f600480360381019061024a91906136a8565b610a62565b60405161025c9190613046565b60405180910390f35b34801561027157600080fd5b5061028c60048036038101906102879190613830565b610c27565b6040516102999190613966565b60405180910390f35b3480156102ae57600080fd5b506102c960048036038101906102c4919061311c565b610d40565b6040516102d69190613101565b60405180910390f35b3480156102eb57600080fd5b5061030660048036038101906103019190613988565b610d54565b005b34801561031457600080fd5b5061032f600480360381019061032a91906139d1565b610d68565b005b34801561033d57600080fd5b50610346610e05565b005b34801561035457600080fd5b5061035d610e19565b60405161036a9190613a6b565b60405180910390f35b34801561037f57600080fd5b5061039a60048036038101906103959190613ab2565b610e42565b005b3480156103a857600080fd5b506103c360048036038101906103be919061311c565b610e58565b6040516103d09190613046565b60405180910390f35b3480156103e557600080fd5b5061040060048036038101906103fb9190613c96565b610e75565b005b34801561040e57600080fd5b5061042960048036038101906104249190613daf565b611133565b6040516104369190613101565b60405180910390f35b34801561044b57600080fd5b5061046660048036038101906104619190613def565b6111c7565b005b34801561047457600080fd5b5061048f600480360381019061048a9190613e86565b611268565b005b34801561049d57600080fd5b506104b860048036038101906104b39190613eb3565b6112ec565b005b60008073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561052b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161052290613f78565b60405180910390fd5b6001600083815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600061058f82611389565b9050919050565b60606105a18261146b565b9050919050565b60006105b2610e19565b73ffffffffffffffffffffffffffffffffffffffff166105d0611550565b73ffffffffffffffffffffffffffffffffffffffff161461067e57600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610631611550565b6040518263ffffffff1660e01b815260040161064d9190613a6b565b60006040518083038186803b15801561066557600080fd5b505afa158015610679573d6000803e3d6000fd5b505050505b3073ffffffffffffffffffffffffffffffffffffffff168460000160208101906106a89190613e86565b73ffffffffffffffffffffffffffffffffffffffff16146106fe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106f59061400a565b60405180910390fd5b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d879253a86866040518363ffffffff1660e01b815260040161075d92919061424d565b60206040518083038186803b15801561077557600080fd5b505afa158015610789573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107ad9190614299565b90508460800160208101906107c29190613e86565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461082f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161082690614312565b60405180910390fd5b61083c8560200135610d40565b61099f57610854818660200135876040013586611558565b6108b4856020013586806060019061086c9190614341565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505061170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c7538660200135838860a001602081019061090b91906143a4565b6040518463ffffffff1660e01b8152600401610929939291906143e0565b600060405180830381600087803b15801561094357600080fd5b505af1158015610957573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f818660200135876040013560405161099693929190614417565b60405180910390a15b6109b08188876020013589876111c7565b846020013591505095945050505050565b6109c9611550565b73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161480610a0f5750610a0e85610a09611550565b611133565b5b610a4e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a45906144c0565b60405180910390fd5b610a5b8585858585611776565b5050505050565b6000610a6c610e19565b73ffffffffffffffffffffffffffffffffffffffff16610a8a611550565b73ffffffffffffffffffffffffffffffffffffffff1614610b3857600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610aeb611550565b6040518263ffffffff1660e01b8152600401610b079190613a6b565b60006040518083038186803b158015610b1f57600080fd5b505afa158015610b33573d6000803e3d6000fd5b505050505b610b4487878785611558565b610b4e868561170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c7538789866040518463ffffffff1660e01b8152600401610bad939291906143e0565b600060405180830381600087803b158015610bc757600080fd5b505af1158015610bdb573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f878787604051610c1293929190614417565b60405180910390a18590509695505050505050565b60608151835114610c6d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c6490614552565b60405180910390fd5b6000835167ffffffffffffffff811115610c8a57610c89613232565b5b604051908082528060200260200182016040528015610cb85781602001602082028036833780820191505090505b50905060005b8451811015610d3557610d05858281518110610cdd57610cdc614572565b5b6020026020010151858381518110610cf857610cf7614572565b5b60200260200101516104ba565b828281518110610d1857610d17614572565b5b60200260200101818152505080610d2e906145d0565b9050610cbe565b508091505092915050565b600080610d4c83610e58565b119050919050565b610d5c611a9b565b610d6581611b19565b50565b610d70611550565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161480610db65750610db583610db0611550565b611133565b5b610df5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dec906144c0565b60405180910390fd5b610e00838383611b33565b505050565b610e0d611a9b565b610e176000611e04565b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610e54610e4d611550565b8383611ec8565b5050565b600060066000838152602001908152602001600020549050919050565b610e7d610e19565b73ffffffffffffffffffffffffffffffffffffffff16610e9b611550565b73ffffffffffffffffffffffffffffffffffffffff1614610f4957600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610efc611550565b6040518263ffffffff1660e01b8152600401610f189190613a6b565b60006040518083038186803b158015610f3057600080fd5b505afa158015610f44573d6000803e3d6000fd5b505050505b8351835114610f8d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f849061468b565b60405180910390fd5b610f9986868684612035565b60005b835181101561112a57610fe3868281518110610fbb57610fba614572565b5b6020026020010151858381518110610fd657610fd5614572565b5b602002602001015161170a565b600760009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635944c75387838151811061103457611033614572565b5b6020026020010151898685815181106110505761104f614572565b5b60200260200101516040518463ffffffff1660e01b8152600401611076939291906143e0565b600060405180830381600087803b15801561109057600080fd5b505af11580156110a4573d6000803e3d6000fd5b505050507f9bc7986536d52bafddb9331a0c9c6dcba169f0a92384e9ba503bd889be84643f878783815181106110dd576110dc614572565b5b60200260200101518784815181106110f8576110f7614572565b5b602002602001015160405161110f93929190614417565b60405180910390a18080611122906145d0565b915050610f9c565b50505050505050565b6000600260008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6111cf611550565b73ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff16148061121557506112148561120f611550565b611133565b5b611254576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161124b906144c0565b60405180910390fd5b6112618585858585612263565b5050505050565b611270611a9b565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156112e0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016112d79061471d565b60405180910390fd5b6112e981611e04565b50565b6112f4611550565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16148061133a575061133983611334611550565b611133565b5b611379576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611370906144c0565b60405180910390fd5b611384838383612502565b505050565b60007fd9b67a26000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061145457507f0e89341c000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b8061146457506114638261274b565b5b9050919050565b6060600060056000848152602001908152602001600020805461148d9061476c565b80601f01602080910402602001604051908101604052809291908181526020018280546114b99061476c565b80156115065780601f106114db57610100808354040283529160200191611506565b820191906000526020600020905b8154815290600101906020018083116114e957829003601f168201915b5050505050905060008151116115245761151f836127b5565b611548565b60048160405160200161153892919061486e565b6040516020818303038152906040525b915050919050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156115c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115bf90614904565b60405180910390fd5b60006115d2611550565b905060006115df85612849565b905060006115ec85612849565b90506115fd836000898585896128c3565b846001600088815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825461165d9190614924565b925050819055508673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f6289896040516116db92919061497a565b60405180910390a46116f2836000898585896128d9565b611701836000898989896128e1565b50505050505050565b80600560008481526020019081526020016000209080519060200190611731929190612eac565b50817f6bb7ff708619ba0610cba295a58592e0451dee2622938c8755667688daf3529b61175d84610596565b60405161176a91906131e2565b60405180910390a25050565b81518351146117ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117b190614a15565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16141561182a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161182190614aa7565b60405180910390fd5b6000611834611550565b90506118448187878787876128c3565b60005b84518110156119f857600085828151811061186557611864614572565b5b60200260200101519050600085838151811061188457611883614572565b5b6020026020010151905060006001600084815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015611926576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161191d90614b39565b60405180910390fd5b8181036001600085815260200190815260200160002060008c73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816001600085815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546119dd9190614924565b92505081905550505050806119f1906145d0565b9050611847565b508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611a6f929190614b59565b60405180910390a4611a858187878787876128d9565b611a93818787878787612ac8565b505050505050565b611aa3611550565b73ffffffffffffffffffffffffffffffffffffffff16611ac1610e19565b73ffffffffffffffffffffffffffffffffffffffff1614611b17576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b0e90614bdc565b60405180910390fd5b565b8060049080519060200190611b2f929190612eac565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611ba3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b9a90614c6e565b60405180910390fd5b8051825114611be7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bde90614a15565b60405180910390fd5b6000611bf1611550565b9050611c11818560008686604051806020016040528060008152506128c3565b60005b8351811015611d60576000848281518110611c3257611c31614572565b5b602002602001015190506000848381518110611c5157611c50614572565b5b6020026020010151905060006001600084815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015611cf3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cea90614d00565b60405180910390fd5b8181036001600085815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050508080611d58906145d0565b915050611c14565b50600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8686604051611dd8929190614b59565b60405180910390a4611dfe818560008686604051806020016040528060008152506128d9565b50505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611f37576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f2e90614d92565b60405180910390fd5b80600260008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516120289190613101565b60405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156120a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161209c90614904565b60405180910390fd5b81518351146120e9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120e090614a15565b60405180910390fd5b60006120f3611550565b9050612104816000878787876128c3565b60005b84518110156121be5783818151811061212357612122614572565b5b60200260200101516001600087848151811061214257612141614572565b5b6020026020010151815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546121a49190614924565b9250508190555080806121b6906145d0565b915050612107565b508473ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612236929190614b59565b60405180910390a461224d816000878787876128d9565b61225c81600087878787612ac8565b5050505050565b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156122d3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ca90614aa7565b60405180910390fd5b60006122dd611550565b905060006122ea85612849565b905060006122f785612849565b90506123078389898585896128c3565b60006001600088815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508581101561239f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161239690614b39565b60405180910390fd5b8581036001600089815260200190815260200160002060008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550856001600089815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546124569190614924565b925050819055508773ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f628a8a6040516124d392919061497a565b60405180910390a46124e9848a8a86868a6128d9565b6124f7848a8a8a8a8a6128e1565b505050505050505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612572576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161256990614c6e565b60405180910390fd5b600061257c611550565b9050600061258984612849565b9050600061259684612849565b90506125b6838760008585604051806020016040528060008152506128c3565b60006001600087815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508481101561264e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161264590614d00565b60405180910390fd5b8481036001600088815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550600073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62898960405161271c92919061497a565b60405180910390a4612742848860008686604051806020016040528060008152506128d9565b50505050505050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b6060600380546127c49061476c565b80601f01602080910402602001604051908101604052809291908181526020018280546127f09061476c565b801561283d5780601f106128125761010080835404028352916020019161283d565b820191906000526020600020905b81548152906001019060200180831161282057829003601f168201915b50505050509050919050565b60606000600167ffffffffffffffff81111561286857612867613232565b5b6040519080825280602002602001820160405280156128965781602001602082028036833780820191505090505b50905082816000815181106128ae576128ad614572565b5b60200260200101818152505080915050919050565b6128d1868686868686612caf565b505050505050565b505050505050565b6129008473ffffffffffffffffffffffffffffffffffffffff16612e81565b15612ac0578373ffffffffffffffffffffffffffffffffffffffff1663f23a6e6187878686866040518663ffffffff1660e01b8152600401612946959493929190614db2565b602060405180830381600087803b15801561296057600080fd5b505af192505050801561299157506040513d601f19601f8201168201806040525081019061298e9190614e21565b60015b612a375761299d614e5b565b806308c379a014156129fa57506129b2614e7d565b806129bd57506129fc565b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016129f191906131e2565b60405180910390fd5b505b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612a2e90614f85565b60405180910390fd5b63f23a6e6160e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612abe576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612ab590615017565b60405180910390fd5b505b505050505050565b612ae78473ffffffffffffffffffffffffffffffffffffffff16612e81565b15612ca7578373ffffffffffffffffffffffffffffffffffffffff1663bc197c8187878686866040518663ffffffff1660e01b8152600401612b2d959493929190615037565b602060405180830381600087803b158015612b4757600080fd5b505af1925050508015612b7857506040513d601f19601f82011682018060405250810190612b759190614e21565b60015b612c1e57612b84614e5b565b806308c379a01415612be15750612b99614e7d565b80612ba45750612be3565b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612bd891906131e2565b60405180910390fd5b505b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612c1590614f85565b60405180910390fd5b63bc197c8160e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612ca5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612c9c90615017565b60405180910390fd5b505b505050505050565b612cbd868686868686612ea4565b600073ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161415612d6f5760005b8351811015612d6d57828181518110612d1157612d10614572565b5b602002602001015160066000868481518110612d3057612d2f614572565b5b602002602001015181526020019081526020016000206000828254612d559190614924565b9250508190555080612d66906145d0565b9050612cf5565b505b600073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161415612e795760005b8351811015612e77576000848281518110612dc557612dc4614572565b5b602002602001015190506000848381518110612de457612de3614572565b5b6020026020010151905060006006600084815260200190815260200160002054905081811015612e49576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612e4090615111565b60405180910390fd5b818103600660008581526020019081526020016000208190555050505080612e70906145d0565b9050612da7565b505b505050505050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b505050505050565b828054612eb89061476c565b90600052602060002090601f016020900481019282612eda5760008555612f21565b82601f10612ef357805160ff1916838001178555612f21565b82800160010185558215612f21579182015b82811115612f20578251825591602001919060010190612f05565b5b509050612f2e9190612f32565b5090565b5b80821115612f4b576000816000905550600101612f33565b5090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000612f8e82612f63565b9050919050565b612f9e81612f83565b8114612fa957600080fd5b50565b600081359050612fbb81612f95565b92915050565b6000819050919050565b612fd481612fc1565b8114612fdf57600080fd5b50565b600081359050612ff181612fcb565b92915050565b6000806040838503121561300e5761300d612f59565b5b600061301c85828601612fac565b925050602061302d85828601612fe2565b9150509250929050565b61304081612fc1565b82525050565b600060208201905061305b6000830184613037565b92915050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61309681613061565b81146130a157600080fd5b50565b6000813590506130b38161308d565b92915050565b6000602082840312156130cf576130ce612f59565b5b60006130dd848285016130a4565b91505092915050565b60008115159050919050565b6130fb816130e6565b82525050565b600060208201905061311660008301846130f2565b92915050565b60006020828403121561313257613131612f59565b5b600061314084828501612fe2565b91505092915050565b600081519050919050565b600082825260208201905092915050565b60005b83811015613183578082015181840152602081019050613168565b83811115613192576000848401525b50505050565b6000601f19601f8301169050919050565b60006131b482613149565b6131be8185613154565b93506131ce818560208601613165565b6131d781613198565b840191505092915050565b600060208201905081810360008301526131fc81846131a9565b905092915050565b600080fd5b600060c0828403121561321f5761321e613204565b5b81905092915050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b61326a82613198565b810181811067ffffffffffffffff8211171561328957613288613232565b5b80604052505050565b600061329c612f4f565b90506132a88282613261565b919050565b600067ffffffffffffffff8211156132c8576132c7613232565b5b6132d182613198565b9050602081019050919050565b82818337600083830152505050565b60006133006132fb846132ad565b613292565b90508281526020810184848401111561331c5761331b61322d565b5b6133278482856132de565b509392505050565b600082601f83011261334457613343613228565b5b81356133548482602086016132ed565b91505092915050565b600080600080600060a0868803121561337957613378612f59565b5b600061338788828901612fac565b955050602061339888828901612fe2565b945050604086013567ffffffffffffffff8111156133b9576133b8612f5e565b5b6133c588828901613209565b935050606086013567ffffffffffffffff8111156133e6576133e5612f5e565b5b6133f28882890161332f565b925050608086013567ffffffffffffffff81111561341357613412612f5e565b5b61341f8882890161332f565b9150509295509295909350565b600067ffffffffffffffff82111561344757613446613232565b5b602082029050602081019050919050565b600080fd5b600061347061346b8461342c565b613292565b9050808382526020820190506020840283018581111561349357613492613458565b5b835b818110156134bc57806134a88882612fe2565b845260208401935050602081019050613495565b5050509392505050565b600082601f8301126134db576134da613228565b5b81356134eb84826020860161345d565b91505092915050565b600080600080600060a086880312156135105761350f612f59565b5b600061351e88828901612fac565b955050602061352f88828901612fac565b945050604086013567ffffffffffffffff8111156135505761354f612f5e565b5b61355c888289016134c6565b935050606086013567ffffffffffffffff81111561357d5761357c612f5e565b5b613589888289016134c6565b925050608086013567ffffffffffffffff8111156135aa576135a9612f5e565b5b6135b68882890161332f565b9150509295509295909350565b600067ffffffffffffffff8211156135de576135dd613232565b5b6135e782613198565b9050602081019050919050565b6000613607613602846135c3565b613292565b9050828152602081018484840111156136235761362261322d565b5b61362e8482856132de565b509392505050565b600082601f83011261364b5761364a613228565b5b813561365b8482602086016135f4565b91505092915050565b60006bffffffffffffffffffffffff82169050919050565b61368581613664565b811461369057600080fd5b50565b6000813590506136a28161367c565b92915050565b60008060008060008060c087890312156136c5576136c4612f59565b5b60006136d389828a01612fac565b96505060206136e489828a01612fe2565b95505060406136f589828a01612fe2565b945050606087013567ffffffffffffffff81111561371657613715612f5e565b5b61372289828a01613636565b935050608061373389828a01613693565b92505060a087013567ffffffffffffffff81111561375457613753612f5e565b5b61376089828a0161332f565b9150509295509295509295565b600067ffffffffffffffff82111561378857613787613232565b5b602082029050602081019050919050565b60006137ac6137a78461376d565b613292565b905080838252602082019050602084028301858111156137cf576137ce613458565b5b835b818110156137f857806137e48882612fac565b8452602084019350506020810190506137d1565b5050509392505050565b600082601f83011261381757613816613228565b5b8135613827848260208601613799565b91505092915050565b6000806040838503121561384757613846612f59565b5b600083013567ffffffffffffffff81111561386557613864612f5e565b5b61387185828601613802565b925050602083013567ffffffffffffffff81111561389257613891612f5e565b5b61389e858286016134c6565b9150509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6138dd81612fc1565b82525050565b60006138ef83836138d4565b60208301905092915050565b6000602082019050919050565b6000613913826138a8565b61391d81856138b3565b9350613928836138c4565b8060005b8381101561395957815161394088826138e3565b975061394b836138fb565b92505060018101905061392c565b5085935050505092915050565b600060208201905081810360008301526139808184613908565b905092915050565b60006020828403121561399e5761399d612f59565b5b600082013567ffffffffffffffff8111156139bc576139bb612f5e565b5b6139c884828501613636565b91505092915050565b6000806000606084860312156139ea576139e9612f59565b5b60006139f886828701612fac565b935050602084013567ffffffffffffffff811115613a1957613a18612f5e565b5b613a25868287016134c6565b925050604084013567ffffffffffffffff811115613a4657613a45612f5e565b5b613a52868287016134c6565b9150509250925092565b613a6581612f83565b82525050565b6000602082019050613a806000830184613a5c565b92915050565b613a8f816130e6565b8114613a9a57600080fd5b50565b600081359050613aac81613a86565b92915050565b60008060408385031215613ac957613ac8612f59565b5b6000613ad785828601612fac565b9250506020613ae885828601613a9d565b9150509250929050565b600067ffffffffffffffff821115613b0d57613b0c613232565b5b602082029050602081019050919050565b6000613b31613b2c84613af2565b613292565b90508083825260208201905060208402830185811115613b5457613b53613458565b5b835b81811015613b9b57803567ffffffffffffffff811115613b7957613b78613228565b5b808601613b868982613636565b85526020850194505050602081019050613b56565b5050509392505050565b600082601f830112613bba57613bb9613228565b5b8135613bca848260208601613b1e565b91505092915050565b600067ffffffffffffffff821115613bee57613bed613232565b5b602082029050602081019050919050565b6000613c12613c0d84613bd3565b613292565b90508083825260208201905060208402830185811115613c3557613c34613458565b5b835b81811015613c5e5780613c4a8882613693565b845260208401935050602081019050613c37565b5050509392505050565b600082601f830112613c7d57613c7c613228565b5b8135613c8d848260208601613bff565b91505092915050565b60008060008060008060c08789031215613cb357613cb2612f59565b5b6000613cc189828a01612fac565b965050602087013567ffffffffffffffff811115613ce257613ce1612f5e565b5b613cee89828a016134c6565b955050604087013567ffffffffffffffff811115613d0f57613d0e612f5e565b5b613d1b89828a016134c6565b945050606087013567ffffffffffffffff811115613d3c57613d3b612f5e565b5b613d4889828a01613ba5565b935050608087013567ffffffffffffffff811115613d6957613d68612f5e565b5b613d7589828a01613c68565b92505060a087013567ffffffffffffffff811115613d9657613d95612f5e565b5b613da289828a0161332f565b9150509295509295509295565b60008060408385031215613dc657613dc5612f59565b5b6000613dd485828601612fac565b9250506020613de585828601612fac565b9150509250929050565b600080600080600060a08688031215613e0b57613e0a612f59565b5b6000613e1988828901612fac565b9550506020613e2a88828901612fac565b9450506040613e3b88828901612fe2565b9350506060613e4c88828901612fe2565b925050608086013567ffffffffffffffff811115613e6d57613e6c612f5e565b5b613e798882890161332f565b9150509295509295909350565b600060208284031215613e9c57613e9b612f59565b5b6000613eaa84828501612fac565b91505092915050565b600080600060608486031215613ecc57613ecb612f59565b5b6000613eda86828701612fac565b9350506020613eeb86828701612fe2565b9250506040613efc86828701612fe2565b9150509250925092565b7f455243313135353a2061646472657373207a65726f206973206e6f742061207660008201527f616c6964206f776e657200000000000000000000000000000000000000000000602082015250565b6000613f62602a83613154565b9150613f6d82613f06565b604082019050919050565b60006020820190508181036000830152613f9181613f55565b9050919050565b7f54686520766f7563686572206d75737420626520666f72207468697320636f6e60008201527f7472616374000000000000000000000000000000000000000000000000000000602082015250565b6000613ff4602583613154565b9150613fff82613f98565b604082019050919050565b6000602082019050818103600083015261402381613fe7565b9050919050565b60006140396020840184612fac565b905092915050565b61404a81612f83565b82525050565b600061405f6020840184612fe2565b905092915050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261409357614092614071565b5b83810192508235915060208301925067ffffffffffffffff8211156140bb576140ba614067565b5b6001820236038413156140d1576140d061406c565b5b509250929050565b600082825260208201905092915050565b60006140f683856140d9565b93506141038385846132de565b61410c83613198565b840190509392505050565b60006141266020840184613693565b905092915050565b61413781613664565b82525050565b600060c08301614150600084018461402a565b61415d6000860182614041565b5061416b6020840184614050565b61417860208601826138d4565b506141866040840184614050565b61419360408601826138d4565b506141a16060840184614076565b85830360608701526141b48382846140ea565b925050506141c5608084018461402a565b6141d26080860182614041565b506141e060a0840184614117565b6141ed60a086018261412e565b508091505092915050565b600081519050919050565b600082825260208201905092915050565b600061421f826141f8565b6142298185614203565b9350614239818560208601613165565b61424281613198565b840191505092915050565b60006040820190508181036000830152614267818561413d565b9050818103602083015261427b8184614214565b90509392505050565b60008151905061429381612f95565b92915050565b6000602082840312156142af576142ae612f59565b5b60006142bd84828501614284565b91505092915050565b7f43726561746f72204164647265737320646f6573206e6f74206d617463680000600082015250565b60006142fc601e83613154565b9150614307826142c6565b602082019050919050565b6000602082019050818103600083015261432b816142ef565b9050919050565b600080fd5b600080fd5b600080fd5b6000808335600160200384360303811261435e5761435d614332565b5b80840192508235915067ffffffffffffffff8211156143805761437f614337565b5b60208301925060018202360383131561439c5761439b61433c565b5b509250929050565b6000602082840312156143ba576143b9612f59565b5b60006143c884828501613693565b91505092915050565b6143da81613664565b82525050565b60006060820190506143f56000830186613037565b6144026020830185613a5c565b61440f60408301846143d1565b949350505050565b600060608201905061442c6000830186613a5c565b6144396020830185613037565b6144466040830184613037565b949350505050565b7f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60008201527f6572206e6f7220617070726f7665640000000000000000000000000000000000602082015250565b60006144aa602f83613154565b91506144b58261444e565b604082019050919050565b600060208201905081810360008301526144d98161449d565b9050919050565b7f455243313135353a206163636f756e747320616e6420696473206c656e67746860008201527f206d69736d617463680000000000000000000000000000000000000000000000602082015250565b600061453c602983613154565b9150614547826144e0565b604082019050919050565b6000602082019050818103600083015261456b8161452f565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006145db82612fc1565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561460e5761460d6145a1565b5b600182019050919050565b7f455243313135353a207572697320616e6420616d6f756e7473206c656e67746860008201527f206d69736d617463680000000000000000000000000000000000000000000000602082015250565b6000614675602983613154565b915061468082614619565b604082019050919050565b600060208201905081810360008301526146a481614668565b9050919050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000614707602683613154565b9150614712826146ab565b604082019050919050565b60006020820190508181036000830152614736816146fa565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061478457607f821691505b602082108114156147985761479761473d565b5b50919050565b600081905092915050565b60008190508160005260206000209050919050565b600081546147cb8161476c565b6147d5818661479e565b945060018216600081146147f0576001811461480157614834565b60ff19831686528186019350614834565b61480a856147a9565b60005b8381101561482c5781548189015260018201915060208101905061480d565b838801955050505b50505092915050565b600061484882613149565b614852818561479e565b9350614862818560208601613165565b80840191505092915050565b600061487a82856147be565b9150614886828461483d565b91508190509392505050565b7f455243313135353a206d696e7420746f20746865207a65726f2061646472657360008201527f7300000000000000000000000000000000000000000000000000000000000000602082015250565b60006148ee602183613154565b91506148f982614892565b604082019050919050565b6000602082019050818103600083015261491d816148e1565b9050919050565b600061492f82612fc1565b915061493a83612fc1565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0382111561496f5761496e6145a1565b5b828201905092915050565b600060408201905061498f6000830185613037565b61499c6020830184613037565b9392505050565b7f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682060008201527f6d69736d61746368000000000000000000000000000000000000000000000000602082015250565b60006149ff602883613154565b9150614a0a826149a3565b604082019050919050565b60006020820190508181036000830152614a2e816149f2565b9050919050565b7f455243313135353a207472616e7366657220746f20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b6000614a91602583613154565b9150614a9c82614a35565b604082019050919050565b60006020820190508181036000830152614ac081614a84565b9050919050565b7f455243313135353a20696e73756666696369656e742062616c616e636520666f60008201527f72207472616e7366657200000000000000000000000000000000000000000000602082015250565b6000614b23602a83613154565b9150614b2e82614ac7565b604082019050919050565b60006020820190508181036000830152614b5281614b16565b9050919050565b60006040820190508181036000830152614b738185613908565b90508181036020830152614b878184613908565b90509392505050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000614bc6602083613154565b9150614bd182614b90565b602082019050919050565b60006020820190508181036000830152614bf581614bb9565b9050919050565b7f455243313135353a206275726e2066726f6d20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b6000614c58602383613154565b9150614c6382614bfc565b604082019050919050565b60006020820190508181036000830152614c8781614c4b565b9050919050565b7f455243313135353a206275726e20616d6f756e7420657863656564732062616c60008201527f616e636500000000000000000000000000000000000000000000000000000000602082015250565b6000614cea602483613154565b9150614cf582614c8e565b604082019050919050565b60006020820190508181036000830152614d1981614cdd565b9050919050565b7f455243313135353a2073657474696e6720617070726f76616c2073746174757360008201527f20666f722073656c660000000000000000000000000000000000000000000000602082015250565b6000614d7c602983613154565b9150614d8782614d20565b604082019050919050565b60006020820190508181036000830152614dab81614d6f565b9050919050565b600060a082019050614dc76000830188613a5c565b614dd46020830187613a5c565b614de16040830186613037565b614dee6060830185613037565b8181036080830152614e008184614214565b90509695505050505050565b600081519050614e1b8161308d565b92915050565b600060208284031215614e3757614e36612f59565b5b6000614e4584828501614e0c565b91505092915050565b60008160e01c9050919050565b600060033d1115614e7a5760046000803e614e77600051614e4e565b90505b90565b600060443d1015614e8d57614f10565b614e95612f4f565b60043d036004823e80513d602482011167ffffffffffffffff82111715614ebd575050614f10565b808201805167ffffffffffffffff811115614edb5750505050614f10565b80602083010160043d038501811115614ef8575050505050614f10565b614f0782602001850186613261565b82955050505050505b90565b7f455243313135353a207472616e7366657220746f206e6f6e204552433131353560008201527f526563656976657220696d706c656d656e746572000000000000000000000000602082015250565b6000614f6f603483613154565b9150614f7a82614f13565b604082019050919050565b60006020820190508181036000830152614f9e81614f62565b9050919050565b7f455243313135353a204552433131353552656365697665722072656a6563746560008201527f6420746f6b656e73000000000000000000000000000000000000000000000000602082015250565b6000615001602883613154565b915061500c82614fa5565b604082019050919050565b6000602082019050818103600083015261503081614ff4565b9050919050565b600060a08201905061504c6000830188613a5c565b6150596020830187613a5c565b818103604083015261506b8186613908565b9050818103606083015261507f8185613908565b905081810360808301526150938184614214565b90509695505050505050565b7f455243313135353a206275726e20616d6f756e74206578636565647320746f7460008201527f616c537570706c79000000000000000000000000000000000000000000000000602082015250565b60006150fb602883613154565b91506151068261509f565b604082019050919050565b6000602082019050818103600083015261512a816150ee565b905091905056fea2646970667358221220c21316744a9f859f1f6a7eeff58767e40e89d2cf0e9d0b2e9870e4087c87c8f464736f6c63430008090033