Address Details
contract
token

0x8D4ab1a461DAa1937c6a7F1f6584106aF311Ea9C

Token
PlastikNFTV4 (PLASTIK)
Creator
0xa9e89c–06f442 at 0xfdf9ac–a13f3f
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
26 Transactions
Transfers
0 Transfers
Gas Used
1,229,548
Last Balance Update
23475051
This contract has been verified via Sourcify. View contract in Sourcify repository
Contract name:
PlastikNFTV4




Optimization enabled
false
Compiler version
v0.8.9+commit.e5eed63a




EVM Version
london




Verified at
2022-12-19T06:58:28.515496Z

contracts/PlastikNFTV4.sol

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;
import "./UtilsV2.sol";
import "./PlastikBaseERC721V4.sol";

/// @custom:security-contact daniel@nozama.green
contract PlastikNFTV4 is PlastikBaseERC721V4, IPlastikArtLazyMint {
    event PlastikNFTMinted(address mintTo, uint256 tokenId);

    constructor(
        PlastikCryptoV2 _plastikCrypto,
        PlastikRoleV2 _plastikRole,
        string memory name,
        string memory symbol
    )
        PlastikBaseERC721V4(
            _plastikCrypto,
            _plastikRole,
            name,
            symbol
        )
    {}

    function safeLazyMint(
        address buyer,
        NFTVoucherV2 calldata voucher,
        bytes calldata signature
    ) external payable onlyMinterRoleOrOwner 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"
        );

        // mint to signer first to establish on-chain history
        _safeMint(signer, voucher.tokenId);
        _setTokenURI(voucher.tokenId, voucher.tokenURI);

        emit PlastikNFTMinted(signer, voucher.tokenId);

        _setTokenRoyalty(voucher.tokenId, signer, voucher.royalty);

        // transfer to the buyer
        transferFrom(signer, buyer, voucher.tokenId);
        return voucher.tokenId;
    }

    function safeMint(string memory tokenURI, uint256 tokenId, uint96 royaltyFee) onlyMinterRoleOrOwner public returns (uint256) {
        _safeMint(msg.sender, tokenId);
        _setTokenURI(tokenId, tokenURI);
        emit PlastikNFTMinted(msg.sender, tokenId);

        _setTokenRoyalty(tokenId, msg.sender, royaltyFee);

        return tokenId;
    }

}
        

/_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/ERC721/ERC721.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        require(owner != address(0), "ERC721: address zero is not a valid owner");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _owners[tokenId];
        require(owner != address(0), "ERC721: invalid token ID");
        return owner;
    }

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overridden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not token owner nor approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        _requireMinted(tokenId);

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        _setApprovalForAll(_msgSender(), operator, approved);
    }

    /**
     * @dev See {IERC721-isApprovedForAll}.
     */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved");

        _transfer(from, to, tokenId);
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public virtual override {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved");
        _safeTransfer(from, to, tokenId, data);
    }

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * `data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender);
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId);

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);

        _afterTokenTransfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);

        _afterTokenTransfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId);

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits an {Approval} event.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _tokenApprovals[tokenId] = to;
        emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
    }

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits an {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC721: approve to caller");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

    /**
     * @dev Reverts if the `tokenId` has not been minted yet.
     */
    function _requireMinted(uint256 tokenId) internal view virtual {
        require(_exists(tokenId), "ERC721: invalid token ID");
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a contract.
     *
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) {
                return retval == IERC721Receiver.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    /// @solidity memory-safe-assembly
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}
          

/_openzeppelin/contracts/token/ERC721/IERC721.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);
}
          

/_openzeppelin/contracts/token/ERC721/IERC721Receiver.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}
          

/_openzeppelin/contracts/token/ERC721/extensions/ERC721Burnable.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721Burnable.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "../../../utils/Context.sol";

/**
 * @title ERC721 Burnable Token
 * @dev ERC721 Token that can be burned (destroyed).
 */
abstract contract ERC721Burnable is Context, ERC721 {
    /**
     * @dev Burns `tokenId`. See {ERC721-_burn}.
     *
     * Requirements:
     *
     * - The caller must own `tokenId` or be an approved operator.
     */
    function burn(uint256 tokenId) public virtual {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: caller is not token owner nor approved");
        _burn(tokenId);
    }
}
          

/_openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) {
        return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}
          

/_openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/extensions/ERC721URIStorage.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";

/**
 * @dev ERC721 token with storage based token URI management.
 */
abstract contract ERC721URIStorage is ERC721 {
    using Strings for uint256;

    // Optional mapping for token URIs
    mapping(uint256 => string) private _tokenURIs;

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

        string memory _tokenURI = _tokenURIs[tokenId];
        string memory base = _baseURI();

        // If there is no base URI, return the token URI.
        if (bytes(base).length == 0) {
            return _tokenURI;
        }
        // If both are set, concatenate the baseURI and tokenURI (via abi.encodePacked).
        if (bytes(_tokenURI).length > 0) {
            return string(abi.encodePacked(base, _tokenURI));
        }

        return super.tokenURI(tokenId);
    }

    /**
     * @dev Sets `_tokenURI` as the tokenURI of `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal virtual {
        require(_exists(tokenId), "ERC721URIStorage: URI set of nonexistent token");
        _tokenURIs[tokenId] = _tokenURI;
    }

    /**
     * @dev See {ERC721-_burn}. This override additionally checks to see if a
     * token-specific URI was set for the token, and if so, it deletes the token URI from
     * the storage mapping.
     */
    function _burn(uint256 tokenId) internal virtual override {
        super._burn(tokenId);

        if (bytes(_tokenURIs[tokenId]).length != 0) {
            delete _tokenURIs[tokenId];
        }
    }
}
          

/_openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}
          

/_openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}
          

/_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/PlastikBaseERC721V4.sol

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721URIStorage.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Burnable.sol";
import "@openzeppelin/contracts/token/common/ERC2981.sol";
import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol";

import "./PlastikCryptoV2.sol";
import "./PlastikRoleV2.sol";
import "./UtilsV2.sol";

/// @custom:security-contact daniel@nozama.green
abstract contract PlastikBaseERC721V4 is
    Ownable,
    ERC721,
    ERC721Enumerable,
    ERC721URIStorage,
    ERC721Burnable,
    ERC2981
{
    string internal __baseURI;
    PlastikCryptoV2 internal plastikCrypto;
    PlastikRoleV2 internal plastikRole;

    constructor(
        PlastikCryptoV2 _plastikCrypto,
        PlastikRoleV2 _plastikRole,
        string memory name,
        string memory symbol
    ) ERC721(name, symbol) {
        __baseURI = Constants.BASE_URI;
        plastikCrypto = _plastikCrypto;
        plastikRole = _plastikRole;
    }

    function _baseURI() internal view override returns (string memory) {
        return __baseURI;
    }

    function setBaseURI(string memory baseURI_) public onlyOwner {
        __baseURI = baseURI_;
    }

    modifier onlyMinterRoleOrOwner() {
        if (_msgSender() != owner()) {
            plastikRole.verifyMinterRole(_msgSender());
        }
        _;
    }

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal override(ERC721, ERC721Enumerable) {
        super._beforeTokenTransfer(from, to, tokenId);
    }

    function _burn(uint256 tokenId)
        internal
        virtual
        override(ERC721, ERC721URIStorage)
    {
        super._burn(tokenId);
        _resetTokenRoyalty(tokenId);
    }

    function tokenURI(uint256 tokenId)
        public
        view
        virtual
        override(ERC721, ERC721URIStorage)
        returns (string memory)
    {
        return super.tokenURI(tokenId);
    }

    function supportsInterface(bytes4 interfaceId)
        public
        view
        override(ERC721, ERC721Enumerable, ERC2981)
        returns (bool)
    {
        return
            interfaceId == type(IERC721Metadata).interfaceId ||
            interfaceId == type(IERC721Enumerable).interfaceId ||
            interfaceId == type(ERC2981).interfaceId ||
            super.supportsInterface(interfaceId);
    }
}
          

/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 can mint");
        }
    }
}
          

/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":"_plastikCrypto","internalType":"contract PlastikCryptoV2"},{"type":"address","name":"_plastikRole","internalType":"contract PlastikRoleV2"},{"type":"string","name":"name","internalType":"string"},{"type":"string","name":"symbol","internalType":"string"}]},{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"approved","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"event","name":"ApprovalForAll","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"operator","internalType":"address","indexed":true},{"type":"bool","name":"approved","internalType":"bool","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"PlastikNFTMinted","inputs":[{"type":"address","name":"mintTo","internalType":"address","indexed":false},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"tokenId","internalType":"uint256","indexed":true}],"anonymous":false},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"approve","inputs":[{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"owner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"burn","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"getApproved","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isApprovedForAll","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"operator","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"ownerOf","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"},{"type":"uint256","name":"","internalType":"uint256"}],"name":"royaltyInfo","inputs":[{"type":"uint256","name":"_tokenId","internalType":"uint256"},{"type":"uint256","name":"_salePrice","internalType":"uint256"}]},{"type":"function","stateMutability":"payable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"safeLazyMint","inputs":[{"type":"address","name":"buyer","internalType":"address"},{"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":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"safeMint","inputs":[{"type":"string","name":"tokenURI","internalType":"string"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"uint96","name":"royaltyFee","internalType":"uint96"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"safeTransferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"},{"type":"bytes","name":"data","internalType":"bytes"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setApprovalForAll","inputs":[{"type":"address","name":"operator","internalType":"address"},{"type":"bool","name":"approved","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setBaseURI","inputs":[{"type":"string","name":"baseURI_","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":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenByIndex","inputs":[{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenOfOwnerByIndex","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"uint256","name":"index","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"tokenURI","inputs":[{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferFrom","inputs":[{"type":"address","name":"from","internalType":"address"},{"type":"address","name":"to","internalType":"address"},{"type":"uint256","name":"tokenId","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]}]
              

Contract Creation Code

0x60806040523480156200001157600080fd5b506040516200510538038062005105833981810160405281019062000037919062000546565b8383838381816200005d620000516200016f60201b60201c565b6200017760201b60201c565b8160019080519060200190620000759291906200023b565b5080600290805190602001906200008e9291906200023b565b5050506040518060400160405280601981526020017f68747470733a2f2f706c617374696b732e696f2f697066732f00000000000000815250600e9080519060200190620000de9291906200023b565b5083600f60006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555082601060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505050505050506200065b565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b828054620002499062000625565b90600052602060002090601f0160209004810192826200026d5760008555620002b9565b82601f106200028857805160ff1916838001178555620002b9565b82800160010185558215620002b9579182015b82811115620002b85782518255916020019190600101906200029b565b5b509050620002c89190620002cc565b5090565b5b80821115620002e7576000816000905550600101620002cd565b5090565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200032c82620002ff565b9050919050565b600062000340826200031f565b9050919050565b620003528162000333565b81146200035e57600080fd5b50565b600081519050620003728162000347565b92915050565b600062000385826200031f565b9050919050565b620003978162000378565b8114620003a357600080fd5b50565b600081519050620003b7816200038c565b92915050565b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6200041282620003c7565b810181811067ffffffffffffffff82111715620004345762000433620003d8565b5b80604052505050565b600062000449620002eb565b905062000457828262000407565b919050565b600067ffffffffffffffff8211156200047a5762000479620003d8565b5b6200048582620003c7565b9050602081019050919050565b60005b83811015620004b257808201518184015260208101905062000495565b83811115620004c2576000848401525b50505050565b6000620004df620004d9846200045c565b6200043d565b905082815260208101848484011115620004fe57620004fd620003c2565b5b6200050b84828562000492565b509392505050565b600082601f8301126200052b576200052a620003bd565b5b81516200053d848260208601620004c8565b91505092915050565b60008060008060808587031215620005635762000562620002f5565b5b6000620005738782880162000361565b94505060206200058687828801620003a6565b935050604085015167ffffffffffffffff811115620005aa57620005a9620002fa565b5b620005b88782880162000513565b925050606085015167ffffffffffffffff811115620005dc57620005db620002fa565b5b620005ea8782880162000513565b91505092959194509250565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806200063e57607f821691505b60208210811415620006555762000654620005f6565b5b50919050565b614a9a806200066b6000396000f3fe60806040526004361061014b5760003560e01c80636352211e116100b6578063a22cb4651161006f578063a22cb465146104bc578063a9badddf146104e5578063b88d4fde14610522578063c87b56dd1461054b578063e985e9c514610588578063f2fde38b146105c55761014b565b80636352211e146103a557806370a08231146103e2578063715018a61461041f57806386f7dfc3146104365780638da5cb5b1461046657806395d89b41146104915761014b565b80632a55205a116101085780632a55205a146102725780632f745c59146102b057806342842e0e146102ed57806342966c68146103165780634f6ccce71461033f57806355f804b31461037c5761014b565b806301ffc9a71461015057806306fdde031461018d578063081812fc146101b8578063095ea7b3146101f557806318160ddd1461021e57806323b872dd14610249575b600080fd5b34801561015c57600080fd5b5061017760048036038101906101729190613082565b6105ee565b60405161018491906130ca565b60405180910390f35b34801561019957600080fd5b506101a2610738565b6040516101af919061317e565b60405180910390f35b3480156101c457600080fd5b506101df60048036038101906101da91906131d6565b6107ca565b6040516101ec9190613244565b60405180910390f35b34801561020157600080fd5b5061021c6004803603810190610217919061328b565b610810565b005b34801561022a57600080fd5b50610233610928565b60405161024091906132da565b60405180910390f35b34801561025557600080fd5b50610270600480360381019061026b91906132f5565b610935565b005b34801561027e57600080fd5b5061029960048036038101906102949190613348565b610995565b6040516102a7929190613388565b60405180910390f35b3480156102bc57600080fd5b506102d760048036038101906102d2919061328b565b610b80565b6040516102e491906132da565b60405180910390f35b3480156102f957600080fd5b50610314600480360381019061030f91906132f5565b610c25565b005b34801561032257600080fd5b5061033d600480360381019061033891906131d6565b610c45565b005b34801561034b57600080fd5b50610366600480360381019061036191906131d6565b610ca1565b60405161037391906132da565b60405180910390f35b34801561038857600080fd5b506103a3600480360381019061039e91906134e6565b610d12565b005b3480156103b157600080fd5b506103cc60048036038101906103c791906131d6565b610d34565b6040516103d99190613244565b60405180910390f35b3480156103ee57600080fd5b506104096004803603810190610404919061352f565b610de6565b60405161041691906132da565b60405180910390f35b34801561042b57600080fd5b50610434610e9e565b005b610450600480360381019061044b91906135e0565b610eb2565b60405161045d91906132da565b60405180910390f35b34801561047257600080fd5b5061047b611226565b6040516104889190613244565b60405180910390f35b34801561049d57600080fd5b506104a661124f565b6040516104b3919061317e565b60405180910390f35b3480156104c857600080fd5b506104e360048036038101906104de919061369c565b6112e1565b005b3480156104f157600080fd5b5061050c60048036038101906105079190613720565b6112f7565b60405161051991906132da565b60405180910390f35b34801561052e57600080fd5b5061054960048036038101906105449190613830565b61142f565b005b34801561055757600080fd5b50610572600480360381019061056d91906131d6565b611491565b60405161057f919061317e565b60405180910390f35b34801561059457600080fd5b506105af60048036038101906105aa91906138b3565b6114a3565b6040516105bc91906130ca565b60405180910390f35b3480156105d157600080fd5b506105ec60048036038101906105e7919061352f565b611537565b005b60007f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806106b957507f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b8061072157507f2baae9fd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b806107315750610730826115bb565b5b9050919050565b60606001805461074790613922565b80601f016020809104026020016040519081016040528092919081815260200182805461077390613922565b80156107c05780601f10610795576101008083540402835291602001916107c0565b820191906000526020600020905b8154815290600101906020018083116107a357829003601f168201915b5050505050905090565b60006107d582611635565b6005600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b600061081b82610d34565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561088c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610883906139c6565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166108ab611680565b73ffffffffffffffffffffffffffffffffffffffff1614806108da57506108d9816108d4611680565b6114a3565b5b610919576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161091090613a58565b60405180910390fd5b6109238383611688565b505050565b6000600980549050905090565b610946610940611680565b82611741565b610985576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161097c90613aea565b60405180910390fd5b6109908383836117d6565b505050565b6000806000600d60008681526020019081526020016000206040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250509050600073ffffffffffffffffffffffffffffffffffffffff16816000015173ffffffffffffffffffffffffffffffffffffffff161415610b2b57600c6040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff168152505090505b6000610b35611a3d565b6bffffffffffffffffffffffff1682602001516bffffffffffffffffffffffff1686610b619190613b39565b610b6b9190613bc2565b90508160000151819350935050509250929050565b6000610b8b83610de6565b8210610bcc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610bc390613c65565b60405180910390fd5b600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905092915050565b610c408383836040518060200160405280600081525061142f565b505050565b610c56610c50611680565b82611741565b610c95576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c8c90613aea565b60405180910390fd5b610c9e81611a47565b50565b6000610cab610928565b8210610cec576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ce390613cf7565b60405180910390fd5b60098281548110610d0057610cff613d17565b5b90600052602060002001549050919050565b610d1a611a5c565b80600e9080519060200190610d30929190612f33565b5050565b6000806003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610ddd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dd490613d92565b60405180910390fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610e57576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e4e90613e24565b60405180910390fd5b600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610ea6611a5c565b610eb06000611ada565b565b6000610ebc611226565b73ffffffffffffffffffffffffffffffffffffffff16610eda611680565b73ffffffffffffffffffffffffffffffffffffffff1614610f8857601060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610f3b611680565b6040518263ffffffff1660e01b8152600401610f579190613244565b60006040518083038186803b158015610f6f57600080fd5b505afa158015610f83573d6000803e3d6000fd5b505050505b3073ffffffffffffffffffffffffffffffffffffffff16846000016020810190610fb2919061352f565b73ffffffffffffffffffffffffffffffffffffffff1614611008576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fff90613eb6565b60405180910390fd5b6000600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d879253a8686866040518463ffffffff1660e01b8152600401611069939291906140f1565b60206040518083038186803b15801561108157600080fd5b505afa158015611095573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b9919061413f565b90508460800160208101906110ce919061352f565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461113b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611132906141b8565b60405180910390fd5b611149818660200135611b9e565b6111a9856020013586806060019061116191906141e7565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611bbc565b7f6096becae9000a69ba5373170a4963544a42f71cc937a76fc0d7741745bcbd168186602001356040516111de929190613388565b60405180910390a16112078560200135828760a0016020810190611202919061424a565b611c30565b61121681878760200135610935565b8460200135915050949350505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60606002805461125e90613922565b80601f016020809104026020016040519081016040528092919081815260200182805461128a90613922565b80156112d75780601f106112ac576101008083540402835291602001916112d7565b820191906000526020600020905b8154815290600101906020018083116112ba57829003601f168201915b5050505050905090565b6112f36112ec611680565b8383611dd8565b5050565b6000611301611226565b73ffffffffffffffffffffffffffffffffffffffff1661131f611680565b73ffffffffffffffffffffffffffffffffffffffff16146113cd57601060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e611380611680565b6040518263ffffffff1660e01b815260040161139c9190613244565b60006040518083038186803b1580156113b457600080fd5b505afa1580156113c8573d6000803e3d6000fd5b505050505b6113d73384611b9e565b6113e18385611bbc565b7f6096becae9000a69ba5373170a4963544a42f71cc937a76fc0d7741745bcbd163384604051611412929190613388565b60405180910390a1611425833384611c30565b8290509392505050565b61144061143a611680565b83611741565b61147f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161147690613aea565b60405180910390fd5b61148b84848484611f45565b50505050565b606061149c82611fa1565b9050919050565b6000600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b61153f611a5c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156115af576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115a6906142e9565b60405180910390fd5b6115b881611ada565b50565b60007f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061162e575061162d826120b4565b5b9050919050565b61163e8161212e565b61167d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161167490613d92565b60405180910390fd5b50565b600033905090565b816005600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff166116fb83610d34565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061174d83610d34565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061178f575061178e81856114a3565b5b806117cd57508373ffffffffffffffffffffffffffffffffffffffff166117b5846107ca565b73ffffffffffffffffffffffffffffffffffffffff16145b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff166117f682610d34565b73ffffffffffffffffffffffffffffffffffffffff161461184c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016118439061437b565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156118bc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016118b39061440d565b60405180910390fd5b6118c783838361219a565b6118d2600082611688565b6001600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254611922919061442d565b925050819055506001600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546119799190614461565b92505081905550816003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4611a388383836121aa565b505050565b6000612710905090565b611a50816121af565b611a5981612202565b50565b611a64611680565b73ffffffffffffffffffffffffffffffffffffffff16611a82611226565b73ffffffffffffffffffffffffffffffffffffffff1614611ad8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611acf90614503565b60405180910390fd5b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b611bb8828260405180602001604052806000815250612261565b5050565b611bc58261212e565b611c04576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bfb90614595565b60405180910390fd5b80600b60008481526020019081526020016000209080519060200190611c2b929190612f33565b505050565b611c38611a3d565b6bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115611c96576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c8d90614627565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611d06576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cfd90614693565b60405180910390fd5b60405180604001604052808373ffffffffffffffffffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff16815250600d600085815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160000160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550905050505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611e47576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e3e906146ff565b60405180910390fd5b80600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051611f3891906130ca565b60405180910390a3505050565b611f508484846117d6565b611f5c848484846122bc565b611f9b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f9290614791565b60405180910390fd5b50505050565b6060611fac82611635565b6000600b60008481526020019081526020016000208054611fcc90613922565b80601f0160208091040260200160405190810160405280929190818152602001828054611ff890613922565b80156120455780601f1061201a57610100808354040283529160200191612045565b820191906000526020600020905b81548152906001019060200180831161202857829003601f168201915b505050505090506000612056612453565b905060008151141561206c5781925050506120af565b6000825111156120a15780826040516020016120899291906147ed565b604051602081830303815290604052925050506120af565b6120aa846124e5565b925050505b919050565b60007f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061212757506121268261254d565b5b9050919050565b60008073ffffffffffffffffffffffffffffffffffffffff166003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614159050919050565b6121a583838361262f565b505050565b505050565b6121b881612743565b6000600b600083815260200190815260200160002080546121d890613922565b9050146121ff57600b600082815260200190815260200160002060006121fe9190612fb9565b5b50565b600d6000828152602001908152602001600020600080820160006101000a81549073ffffffffffffffffffffffffffffffffffffffff02191690556000820160146101000a8154906bffffffffffffffffffffffff0219169055505050565b61226b8383612860565b61227860008484846122bc565b6122b7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ae90614791565b60405180910390fd5b505050565b60006122dd8473ffffffffffffffffffffffffffffffffffffffff16612a3a565b15612446578373ffffffffffffffffffffffffffffffffffffffff1663150b7a02612306611680565b8786866040518563ffffffff1660e01b81526004016123289493929190614855565b602060405180830381600087803b15801561234257600080fd5b505af192505050801561237357506040513d601f19601f8201168201806040525081019061237091906148b6565b60015b6123f6573d80600081146123a3576040519150601f19603f3d011682016040523d82523d6000602084013e6123a8565b606091505b506000815114156123ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016123e590614791565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161491505061244b565b600190505b949350505050565b6060600e805461246290613922565b80601f016020809104026020016040519081016040528092919081815260200182805461248e90613922565b80156124db5780601f106124b0576101008083540402835291602001916124db565b820191906000526020600020905b8154815290600101906020018083116124be57829003601f168201915b5050505050905090565b60606124f082611635565b60006124fa612453565b9050600081511161251a5760405180602001604052806000815250612545565b8061252484612a5d565b6040516020016125359291906147ed565b6040516020818303038152906040525b915050919050565b60007f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061261857507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80612628575061262782612bbe565b5b9050919050565b61263a838383612c28565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561267d5761267881612c2d565b6126bc565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146126bb576126ba8382612c76565b5b5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156126ff576126fa81612de3565b61273e565b8273ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161461273d5761273c8282612eb4565b5b5b505050565b600061274e82610d34565b905061275c8160008461219a565b612767600083611688565b6001600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546127b7919061442d565b925050819055506003600083815260200190815260200160002060006101000a81549073ffffffffffffffffffffffffffffffffffffffff021916905581600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a461285c816000846121aa565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156128d0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016128c79061492f565b60405180910390fd5b6128d98161212e565b15612919576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016129109061499b565b60405180910390fd5b6129256000838361219a565b6001600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546129759190614461565b92505081905550816003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612a36600083836121aa565b5050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b60606000821415612aa5576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050612bb9565b600082905060005b60008214612ad7578080612ac0906149bb565b915050600a82612ad09190613bc2565b9150612aad565b60008167ffffffffffffffff811115612af357612af26133bb565b5b6040519080825280601f01601f191660200182016040528015612b255781602001600182028036833780820191505090505b5090505b60008514612bb257600182612b3e919061442d565b9150600a85612b4d9190614a04565b6030612b599190614461565b60f81b818381518110612b6f57612b6e613d17565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a85612bab9190613bc2565b9450612b29565b8093505050505b919050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600980549050600a600083815260200190815260200160002081905550600981908060018154018082558091505060019003906000526020600020016000909190919091505550565b60006001612c8384610de6565b612c8d919061442d565b9050600060086000848152602001908152602001600020549050818114612d72576000600760008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002054905080600760008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002081905550816008600083815260200190815260200160002081905550505b6008600084815260200190815260200160002060009055600760008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000206000905550505050565b60006001600980549050612df7919061442d565b90506000600a6000848152602001908152602001600020549050600060098381548110612e2757612e26613d17565b5b906000526020600020015490508060098381548110612e4957612e48613d17565b5b906000526020600020018190555081600a600083815260200190815260200160002081905550600a6000858152602001908152602001600020600090556009805480612e9857612e97614a35565b5b6001900381819060005260206000200160009055905550505050565b6000612ebf83610de6565b905081600760008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550806008600084815260200190815260200160002081905550505050565b828054612f3f90613922565b90600052602060002090601f016020900481019282612f615760008555612fa8565b82601f10612f7a57805160ff1916838001178555612fa8565b82800160010185558215612fa8579182015b82811115612fa7578251825591602001919060010190612f8c565b5b509050612fb59190612ff9565b5090565b508054612fc590613922565b6000825580601f10612fd75750612ff6565b601f016020900490600052602060002090810190612ff59190612ff9565b5b50565b5b80821115613012576000816000905550600101612ffa565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61305f8161302a565b811461306a57600080fd5b50565b60008135905061307c81613056565b92915050565b60006020828403121561309857613097613020565b5b60006130a68482850161306d565b91505092915050565b60008115159050919050565b6130c4816130af565b82525050565b60006020820190506130df60008301846130bb565b92915050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561311f578082015181840152602081019050613104565b8381111561312e576000848401525b50505050565b6000601f19601f8301169050919050565b6000613150826130e5565b61315a81856130f0565b935061316a818560208601613101565b61317381613134565b840191505092915050565b600060208201905081810360008301526131988184613145565b905092915050565b6000819050919050565b6131b3816131a0565b81146131be57600080fd5b50565b6000813590506131d0816131aa565b92915050565b6000602082840312156131ec576131eb613020565b5b60006131fa848285016131c1565b91505092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061322e82613203565b9050919050565b61323e81613223565b82525050565b60006020820190506132596000830184613235565b92915050565b61326881613223565b811461327357600080fd5b50565b6000813590506132858161325f565b92915050565b600080604083850312156132a2576132a1613020565b5b60006132b085828601613276565b92505060206132c1858286016131c1565b9150509250929050565b6132d4816131a0565b82525050565b60006020820190506132ef60008301846132cb565b92915050565b60008060006060848603121561330e5761330d613020565b5b600061331c86828701613276565b935050602061332d86828701613276565b925050604061333e868287016131c1565b9150509250925092565b6000806040838503121561335f5761335e613020565b5b600061336d858286016131c1565b925050602061337e858286016131c1565b9150509250929050565b600060408201905061339d6000830185613235565b6133aa60208301846132cb565b9392505050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6133f382613134565b810181811067ffffffffffffffff82111715613412576134116133bb565b5b80604052505050565b6000613425613016565b905061343182826133ea565b919050565b600067ffffffffffffffff821115613451576134506133bb565b5b61345a82613134565b9050602081019050919050565b82818337600083830152505050565b600061348961348484613436565b61341b565b9050828152602081018484840111156134a5576134a46133b6565b5b6134b0848285613467565b509392505050565b600082601f8301126134cd576134cc6133b1565b5b81356134dd848260208601613476565b91505092915050565b6000602082840312156134fc576134fb613020565b5b600082013567ffffffffffffffff81111561351a57613519613025565b5b613526848285016134b8565b91505092915050565b60006020828403121561354557613544613020565b5b600061355384828501613276565b91505092915050565b600080fd5b600060c082840312156135775761357661355c565b5b81905092915050565b600080fd5b600080fd5b60008083601f8401126135a05761359f6133b1565b5b8235905067ffffffffffffffff8111156135bd576135bc613580565b5b6020830191508360018202830111156135d9576135d8613585565b5b9250929050565b600080600080606085870312156135fa576135f9613020565b5b600061360887828801613276565b945050602085013567ffffffffffffffff81111561362957613628613025565b5b61363587828801613561565b935050604085013567ffffffffffffffff81111561365657613655613025565b5b6136628782880161358a565b925092505092959194509250565b613679816130af565b811461368457600080fd5b50565b60008135905061369681613670565b92915050565b600080604083850312156136b3576136b2613020565b5b60006136c185828601613276565b92505060206136d285828601613687565b9150509250929050565b60006bffffffffffffffffffffffff82169050919050565b6136fd816136dc565b811461370857600080fd5b50565b60008135905061371a816136f4565b92915050565b60008060006060848603121561373957613738613020565b5b600084013567ffffffffffffffff81111561375757613756613025565b5b613763868287016134b8565b9350506020613774868287016131c1565b92505060406137858682870161370b565b9150509250925092565b600067ffffffffffffffff8211156137aa576137a96133bb565b5b6137b382613134565b9050602081019050919050565b60006137d36137ce8461378f565b61341b565b9050828152602081018484840111156137ef576137ee6133b6565b5b6137fa848285613467565b509392505050565b600082601f830112613817576138166133b1565b5b81356138278482602086016137c0565b91505092915050565b6000806000806080858703121561384a57613849613020565b5b600061385887828801613276565b945050602061386987828801613276565b935050604061387a878288016131c1565b925050606085013567ffffffffffffffff81111561389b5761389a613025565b5b6138a787828801613802565b91505092959194509250565b600080604083850312156138ca576138c9613020565b5b60006138d885828601613276565b92505060206138e985828601613276565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061393a57607f821691505b6020821081141561394e5761394d6138f3565b5b50919050565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b60006139b06021836130f0565b91506139bb82613954565b604082019050919050565b600060208201905081810360008301526139df816139a3565b9050919050565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60008201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c0000602082015250565b6000613a42603e836130f0565b9150613a4d826139e6565b604082019050919050565b60006020820190508181036000830152613a7181613a35565b9050919050565b7f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560008201527f72206e6f7220617070726f766564000000000000000000000000000000000000602082015250565b6000613ad4602e836130f0565b9150613adf82613a78565b604082019050919050565b60006020820190508181036000830152613b0381613ac7565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000613b44826131a0565b9150613b4f836131a0565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613b8857613b87613b0a565b5b828202905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000613bcd826131a0565b9150613bd8836131a0565b925082613be857613be7613b93565b5b828204905092915050565b7f455243373231456e756d657261626c653a206f776e657220696e646578206f7560008201527f74206f6620626f756e6473000000000000000000000000000000000000000000602082015250565b6000613c4f602b836130f0565b9150613c5a82613bf3565b604082019050919050565b60006020820190508181036000830152613c7e81613c42565b9050919050565b7f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60008201527f7574206f6620626f756e64730000000000000000000000000000000000000000602082015250565b6000613ce1602c836130f0565b9150613cec82613c85565b604082019050919050565b60006020820190508181036000830152613d1081613cd4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4552433732313a20696e76616c696420746f6b656e2049440000000000000000600082015250565b6000613d7c6018836130f0565b9150613d8782613d46565b602082019050919050565b60006020820190508181036000830152613dab81613d6f565b9050919050565b7f4552433732313a2061646472657373207a65726f206973206e6f74206120766160008201527f6c6964206f776e65720000000000000000000000000000000000000000000000602082015250565b6000613e0e6029836130f0565b9150613e1982613db2565b604082019050919050565b60006020820190508181036000830152613e3d81613e01565b9050919050565b7f54686520766f7563686572206d75737420626520666f72207468697320636f6e60008201527f7472616374000000000000000000000000000000000000000000000000000000602082015250565b6000613ea06025836130f0565b9150613eab82613e44565b604082019050919050565b60006020820190508181036000830152613ecf81613e93565b9050919050565b6000613ee56020840184613276565b905092915050565b613ef681613223565b82525050565b6000613f0b60208401846131c1565b905092915050565b613f1c816131a0565b82525050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112613f4e57613f4d613f2c565b5b83810192508235915060208301925067ffffffffffffffff821115613f7657613f75613f22565b5b600182023603841315613f8c57613f8b613f27565b5b509250929050565b600082825260208201905092915050565b6000613fb18385613f94565b9350613fbe838584613467565b613fc783613134565b840190509392505050565b6000613fe1602084018461370b565b905092915050565b613ff2816136dc565b82525050565b600060c0830161400b6000840184613ed6565b6140186000860182613eed565b506140266020840184613efc565b6140336020860182613f13565b506140416040840184613efc565b61404e6040860182613f13565b5061405c6060840184613f31565b858303606087015261406f838284613fa5565b925050506140806080840184613ed6565b61408d6080860182613eed565b5061409b60a0840184613fd2565b6140a860a0860182613fe9565b508091505092915050565b600082825260208201905092915050565b60006140d083856140b3565b93506140dd838584613467565b6140e683613134565b840190509392505050565b6000604082019050818103600083015261410b8186613ff8565b905081810360208301526141208184866140c4565b9050949350505050565b6000815190506141398161325f565b92915050565b60006020828403121561415557614154613020565b5b60006141638482850161412a565b91505092915050565b7f43726561746f72204164647265737320646f6573206e6f74206d617463680000600082015250565b60006141a2601e836130f0565b91506141ad8261416c565b602082019050919050565b600060208201905081810360008301526141d181614195565b9050919050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112614204576142036141d8565b5b80840192508235915067ffffffffffffffff821115614226576142256141dd565b5b602083019250600182023603831315614242576142416141e2565b5b509250929050565b6000602082840312156142605761425f613020565b5b600061426e8482850161370b565b91505092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b60006142d36026836130f0565b91506142de82614277565b604082019050919050565b60006020820190508181036000830152614302816142c6565b9050919050565b7f4552433732313a207472616e736665722066726f6d20696e636f72726563742060008201527f6f776e6572000000000000000000000000000000000000000000000000000000602082015250565b60006143656025836130f0565b915061437082614309565b604082019050919050565b6000602082019050818103600083015261439481614358565b9050919050565b7f4552433732313a207472616e7366657220746f20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b60006143f76024836130f0565b91506144028261439b565b604082019050919050565b60006020820190508181036000830152614426816143ea565b9050919050565b6000614438826131a0565b9150614443836131a0565b92508282101561445657614455613b0a565b5b828203905092915050565b600061446c826131a0565b9150614477836131a0565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156144ac576144ab613b0a565b5b828201905092915050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b60006144ed6020836130f0565b91506144f8826144b7565b602082019050919050565b6000602082019050818103600083015261451c816144e0565b9050919050565b7f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60008201527f6578697374656e7420746f6b656e000000000000000000000000000000000000602082015250565b600061457f602e836130f0565b915061458a82614523565b604082019050919050565b600060208201905081810360008301526145ae81614572565b9050919050565b7f455243323938313a20726f79616c7479206665652077696c6c2065786365656460008201527f2073616c65507269636500000000000000000000000000000000000000000000602082015250565b6000614611602a836130f0565b915061461c826145b5565b604082019050919050565b6000602082019050818103600083015261464081614604565b9050919050565b7f455243323938313a20496e76616c696420706172616d65746572730000000000600082015250565b600061467d601b836130f0565b915061468882614647565b602082019050919050565b600060208201905081810360008301526146ac81614670565b9050919050565b7f4552433732313a20617070726f766520746f2063616c6c657200000000000000600082015250565b60006146e96019836130f0565b91506146f4826146b3565b602082019050919050565b60006020820190508181036000830152614718816146dc565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b600061477b6032836130f0565b91506147868261471f565b604082019050919050565b600060208201905081810360008301526147aa8161476e565b9050919050565b600081905092915050565b60006147c7826130e5565b6147d181856147b1565b93506147e1818560208601613101565b80840191505092915050565b60006147f982856147bc565b915061480582846147bc565b91508190509392505050565b600081519050919050565b600061482782614811565b61483181856140b3565b9350614841818560208601613101565b61484a81613134565b840191505092915050565b600060808201905061486a6000830187613235565b6148776020830186613235565b61488460408301856132cb565b8181036060830152614896818461481c565b905095945050505050565b6000815190506148b081613056565b92915050565b6000602082840312156148cc576148cb613020565b5b60006148da848285016148a1565b91505092915050565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b60006149196020836130f0565b9150614924826148e3565b602082019050919050565b600060208201905081810360008301526149488161490c565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b6000614985601c836130f0565b91506149908261494f565b602082019050919050565b600060208201905081810360008301526149b481614978565b9050919050565b60006149c6826131a0565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156149f9576149f8613b0a565b5b600182019050919050565b6000614a0f826131a0565b9150614a1a836131a0565b925082614a2a57614a29613b93565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea26469706673582212201120869435d97d1590746349dd9e6898e9e8dab0873b47cdf5495389cda7741164736f6c6343000809003300000000000000000000000099695202bbfe9fd393f5fff182d07cdc360c37a00000000000000000000000009e20075484d34d1bc32e13e194ed25f1d1c8b41c000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000c506c617374696b4e4654563400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007504c415354494b00000000000000000000000000000000000000000000000000

Deployed ByteCode

0x60806040526004361061014b5760003560e01c80636352211e116100b6578063a22cb4651161006f578063a22cb465146104bc578063a9badddf146104e5578063b88d4fde14610522578063c87b56dd1461054b578063e985e9c514610588578063f2fde38b146105c55761014b565b80636352211e146103a557806370a08231146103e2578063715018a61461041f57806386f7dfc3146104365780638da5cb5b1461046657806395d89b41146104915761014b565b80632a55205a116101085780632a55205a146102725780632f745c59146102b057806342842e0e146102ed57806342966c68146103165780634f6ccce71461033f57806355f804b31461037c5761014b565b806301ffc9a71461015057806306fdde031461018d578063081812fc146101b8578063095ea7b3146101f557806318160ddd1461021e57806323b872dd14610249575b600080fd5b34801561015c57600080fd5b5061017760048036038101906101729190613082565b6105ee565b60405161018491906130ca565b60405180910390f35b34801561019957600080fd5b506101a2610738565b6040516101af919061317e565b60405180910390f35b3480156101c457600080fd5b506101df60048036038101906101da91906131d6565b6107ca565b6040516101ec9190613244565b60405180910390f35b34801561020157600080fd5b5061021c6004803603810190610217919061328b565b610810565b005b34801561022a57600080fd5b50610233610928565b60405161024091906132da565b60405180910390f35b34801561025557600080fd5b50610270600480360381019061026b91906132f5565b610935565b005b34801561027e57600080fd5b5061029960048036038101906102949190613348565b610995565b6040516102a7929190613388565b60405180910390f35b3480156102bc57600080fd5b506102d760048036038101906102d2919061328b565b610b80565b6040516102e491906132da565b60405180910390f35b3480156102f957600080fd5b50610314600480360381019061030f91906132f5565b610c25565b005b34801561032257600080fd5b5061033d600480360381019061033891906131d6565b610c45565b005b34801561034b57600080fd5b50610366600480360381019061036191906131d6565b610ca1565b60405161037391906132da565b60405180910390f35b34801561038857600080fd5b506103a3600480360381019061039e91906134e6565b610d12565b005b3480156103b157600080fd5b506103cc60048036038101906103c791906131d6565b610d34565b6040516103d99190613244565b60405180910390f35b3480156103ee57600080fd5b506104096004803603810190610404919061352f565b610de6565b60405161041691906132da565b60405180910390f35b34801561042b57600080fd5b50610434610e9e565b005b610450600480360381019061044b91906135e0565b610eb2565b60405161045d91906132da565b60405180910390f35b34801561047257600080fd5b5061047b611226565b6040516104889190613244565b60405180910390f35b34801561049d57600080fd5b506104a661124f565b6040516104b3919061317e565b60405180910390f35b3480156104c857600080fd5b506104e360048036038101906104de919061369c565b6112e1565b005b3480156104f157600080fd5b5061050c60048036038101906105079190613720565b6112f7565b60405161051991906132da565b60405180910390f35b34801561052e57600080fd5b5061054960048036038101906105449190613830565b61142f565b005b34801561055757600080fd5b50610572600480360381019061056d91906131d6565b611491565b60405161057f919061317e565b60405180910390f35b34801561059457600080fd5b506105af60048036038101906105aa91906138b3565b6114a3565b6040516105bc91906130ca565b60405180910390f35b3480156105d157600080fd5b506105ec60048036038101906105e7919061352f565b611537565b005b60007f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806106b957507f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b8061072157507f2baae9fd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b806107315750610730826115bb565b5b9050919050565b60606001805461074790613922565b80601f016020809104026020016040519081016040528092919081815260200182805461077390613922565b80156107c05780601f10610795576101008083540402835291602001916107c0565b820191906000526020600020905b8154815290600101906020018083116107a357829003601f168201915b5050505050905090565b60006107d582611635565b6005600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b600061081b82610d34565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561088c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610883906139c6565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166108ab611680565b73ffffffffffffffffffffffffffffffffffffffff1614806108da57506108d9816108d4611680565b6114a3565b5b610919576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161091090613a58565b60405180910390fd5b6109238383611688565b505050565b6000600980549050905090565b610946610940611680565b82611741565b610985576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161097c90613aea565b60405180910390fd5b6109908383836117d6565b505050565b6000806000600d60008681526020019081526020016000206040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250509050600073ffffffffffffffffffffffffffffffffffffffff16816000015173ffffffffffffffffffffffffffffffffffffffff161415610b2b57600c6040518060400160405290816000820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016000820160149054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff168152505090505b6000610b35611a3d565b6bffffffffffffffffffffffff1682602001516bffffffffffffffffffffffff1686610b619190613b39565b610b6b9190613bc2565b90508160000151819350935050509250929050565b6000610b8b83610de6565b8210610bcc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610bc390613c65565b60405180910390fd5b600760008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002054905092915050565b610c408383836040518060200160405280600081525061142f565b505050565b610c56610c50611680565b82611741565b610c95576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c8c90613aea565b60405180910390fd5b610c9e81611a47565b50565b6000610cab610928565b8210610cec576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ce390613cf7565b60405180910390fd5b60098281548110610d0057610cff613d17565b5b90600052602060002001549050919050565b610d1a611a5c565b80600e9080519060200190610d30929190612f33565b5050565b6000806003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610ddd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dd490613d92565b60405180910390fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610e57576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e4e90613e24565b60405180910390fd5b600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610ea6611a5c565b610eb06000611ada565b565b6000610ebc611226565b73ffffffffffffffffffffffffffffffffffffffff16610eda611680565b73ffffffffffffffffffffffffffffffffffffffff1614610f8857601060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e610f3b611680565b6040518263ffffffff1660e01b8152600401610f579190613244565b60006040518083038186803b158015610f6f57600080fd5b505afa158015610f83573d6000803e3d6000fd5b505050505b3073ffffffffffffffffffffffffffffffffffffffff16846000016020810190610fb2919061352f565b73ffffffffffffffffffffffffffffffffffffffff1614611008576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610fff90613eb6565b60405180910390fd5b6000600f60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d879253a8686866040518463ffffffff1660e01b8152600401611069939291906140f1565b60206040518083038186803b15801561108157600080fd5b505afa158015611095573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110b9919061413f565b90508460800160208101906110ce919061352f565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461113b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611132906141b8565b60405180910390fd5b611149818660200135611b9e565b6111a9856020013586806060019061116191906141e7565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050611bbc565b7f6096becae9000a69ba5373170a4963544a42f71cc937a76fc0d7741745bcbd168186602001356040516111de929190613388565b60405180910390a16112078560200135828760a0016020810190611202919061424a565b611c30565b61121681878760200135610935565b8460200135915050949350505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60606002805461125e90613922565b80601f016020809104026020016040519081016040528092919081815260200182805461128a90613922565b80156112d75780601f106112ac576101008083540402835291602001916112d7565b820191906000526020600020905b8154815290600101906020018083116112ba57829003601f168201915b5050505050905090565b6112f36112ec611680565b8383611dd8565b5050565b6000611301611226565b73ffffffffffffffffffffffffffffffffffffffff1661131f611680565b73ffffffffffffffffffffffffffffffffffffffff16146113cd57601060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632657131e611380611680565b6040518263ffffffff1660e01b815260040161139c9190613244565b60006040518083038186803b1580156113b457600080fd5b505afa1580156113c8573d6000803e3d6000fd5b505050505b6113d73384611b9e565b6113e18385611bbc565b7f6096becae9000a69ba5373170a4963544a42f71cc937a76fc0d7741745bcbd163384604051611412929190613388565b60405180910390a1611425833384611c30565b8290509392505050565b61144061143a611680565b83611741565b61147f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161147690613aea565b60405180910390fd5b61148b84848484611f45565b50505050565b606061149c82611fa1565b9050919050565b6000600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b61153f611a5c565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156115af576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115a6906142e9565b60405180910390fd5b6115b881611ada565b50565b60007f2a55205a000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061162e575061162d826120b4565b5b9050919050565b61163e8161212e565b61167d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161167490613d92565b60405180910390fd5b50565b600033905090565b816005600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff166116fb83610d34565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061174d83610d34565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061178f575061178e81856114a3565b5b806117cd57508373ffffffffffffffffffffffffffffffffffffffff166117b5846107ca565b73ffffffffffffffffffffffffffffffffffffffff16145b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff166117f682610d34565b73ffffffffffffffffffffffffffffffffffffffff161461184c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016118439061437b565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156118bc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016118b39061440d565b60405180910390fd5b6118c783838361219a565b6118d2600082611688565b6001600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254611922919061442d565b925050819055506001600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546119799190614461565b92505081905550816003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4611a388383836121aa565b505050565b6000612710905090565b611a50816121af565b611a5981612202565b50565b611a64611680565b73ffffffffffffffffffffffffffffffffffffffff16611a82611226565b73ffffffffffffffffffffffffffffffffffffffff1614611ad8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611acf90614503565b60405180910390fd5b565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b611bb8828260405180602001604052806000815250612261565b5050565b611bc58261212e565b611c04576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bfb90614595565b60405180910390fd5b80600b60008481526020019081526020016000209080519060200190611c2b929190612f33565b505050565b611c38611a3d565b6bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115611c96576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c8d90614627565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611d06576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cfd90614693565b60405180910390fd5b60405180604001604052808373ffffffffffffffffffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff16815250600d600085815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160000160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550905050505050565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415611e47576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e3e906146ff565b60405180910390fd5b80600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3183604051611f3891906130ca565b60405180910390a3505050565b611f508484846117d6565b611f5c848484846122bc565b611f9b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f9290614791565b60405180910390fd5b50505050565b6060611fac82611635565b6000600b60008481526020019081526020016000208054611fcc90613922565b80601f0160208091040260200160405190810160405280929190818152602001828054611ff890613922565b80156120455780601f1061201a57610100808354040283529160200191612045565b820191906000526020600020905b81548152906001019060200180831161202857829003601f168201915b505050505090506000612056612453565b905060008151141561206c5781925050506120af565b6000825111156120a15780826040516020016120899291906147ed565b604051602081830303815290604052925050506120af565b6120aa846124e5565b925050505b919050565b60007f780e9d63000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061212757506121268261254d565b5b9050919050565b60008073ffffffffffffffffffffffffffffffffffffffff166003600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614159050919050565b6121a583838361262f565b505050565b505050565b6121b881612743565b6000600b600083815260200190815260200160002080546121d890613922565b9050146121ff57600b600082815260200190815260200160002060006121fe9190612fb9565b5b50565b600d6000828152602001908152602001600020600080820160006101000a81549073ffffffffffffffffffffffffffffffffffffffff02191690556000820160146101000a8154906bffffffffffffffffffffffff0219169055505050565b61226b8383612860565b61227860008484846122bc565b6122b7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016122ae90614791565b60405180910390fd5b505050565b60006122dd8473ffffffffffffffffffffffffffffffffffffffff16612a3a565b15612446578373ffffffffffffffffffffffffffffffffffffffff1663150b7a02612306611680565b8786866040518563ffffffff1660e01b81526004016123289493929190614855565b602060405180830381600087803b15801561234257600080fd5b505af192505050801561237357506040513d601f19601f8201168201806040525081019061237091906148b6565b60015b6123f6573d80600081146123a3576040519150601f19603f3d011682016040523d82523d6000602084013e6123a8565b606091505b506000815114156123ee576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016123e590614791565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161491505061244b565b600190505b949350505050565b6060600e805461246290613922565b80601f016020809104026020016040519081016040528092919081815260200182805461248e90613922565b80156124db5780601f106124b0576101008083540402835291602001916124db565b820191906000526020600020905b8154815290600101906020018083116124be57829003601f168201915b5050505050905090565b60606124f082611635565b60006124fa612453565b9050600081511161251a5760405180602001604052806000815250612545565b8061252484612a5d565b6040516020016125359291906147ed565b6040516020818303038152906040525b915050919050565b60007f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916148061261857507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b80612628575061262782612bbe565b5b9050919050565b61263a838383612c28565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561267d5761267881612c2d565b6126bc565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146126bb576126ba8382612c76565b5b5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156126ff576126fa81612de3565b61273e565b8273ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161461273d5761273c8282612eb4565b5b5b505050565b600061274e82610d34565b905061275c8160008461219a565b612767600083611688565b6001600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546127b7919061442d565b925050819055506003600083815260200190815260200160002060006101000a81549073ffffffffffffffffffffffffffffffffffffffff021916905581600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a461285c816000846121aa565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156128d0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016128c79061492f565b60405180910390fd5b6128d98161212e565b15612919576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016129109061499b565b60405180910390fd5b6129256000838361219a565b6001600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546129759190614461565b92505081905550816003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4612a36600083836121aa565b5050565b6000808273ffffffffffffffffffffffffffffffffffffffff163b119050919050565b60606000821415612aa5576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050612bb9565b600082905060005b60008214612ad7578080612ac0906149bb565b915050600a82612ad09190613bc2565b9150612aad565b60008167ffffffffffffffff811115612af357612af26133bb565b5b6040519080825280601f01601f191660200182016040528015612b255781602001600182028036833780820191505090505b5090505b60008514612bb257600182612b3e919061442d565b9150600a85612b4d9190614a04565b6030612b599190614461565b60f81b818381518110612b6f57612b6e613d17565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a85612bab9190613bc2565b9450612b29565b8093505050505b919050565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b505050565b600980549050600a600083815260200190815260200160002081905550600981908060018154018082558091505060019003906000526020600020016000909190919091505550565b60006001612c8384610de6565b612c8d919061442d565b9050600060086000848152602001908152602001600020549050818114612d72576000600760008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002054905080600760008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600084815260200190815260200160002081905550816008600083815260200190815260200160002081905550505b6008600084815260200190815260200160002060009055600760008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008381526020019081526020016000206000905550505050565b60006001600980549050612df7919061442d565b90506000600a6000848152602001908152602001600020549050600060098381548110612e2757612e26613d17565b5b906000526020600020015490508060098381548110612e4957612e48613d17565b5b906000526020600020018190555081600a600083815260200190815260200160002081905550600a6000858152602001908152602001600020600090556009805480612e9857612e97614a35565b5b6001900381819060005260206000200160009055905550505050565b6000612ebf83610de6565b905081600760008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600083815260200190815260200160002081905550806008600084815260200190815260200160002081905550505050565b828054612f3f90613922565b90600052602060002090601f016020900481019282612f615760008555612fa8565b82601f10612f7a57805160ff1916838001178555612fa8565b82800160010185558215612fa8579182015b82811115612fa7578251825591602001919060010190612f8c565b5b509050612fb59190612ff9565b5090565b508054612fc590613922565b6000825580601f10612fd75750612ff6565b601f016020900490600052602060002090810190612ff59190612ff9565b5b50565b5b80821115613012576000816000905550600101612ffa565b5090565b6000604051905090565b600080fd5b600080fd5b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b61305f8161302a565b811461306a57600080fd5b50565b60008135905061307c81613056565b92915050565b60006020828403121561309857613097613020565b5b60006130a68482850161306d565b91505092915050565b60008115159050919050565b6130c4816130af565b82525050565b60006020820190506130df60008301846130bb565b92915050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561311f578082015181840152602081019050613104565b8381111561312e576000848401525b50505050565b6000601f19601f8301169050919050565b6000613150826130e5565b61315a81856130f0565b935061316a818560208601613101565b61317381613134565b840191505092915050565b600060208201905081810360008301526131988184613145565b905092915050565b6000819050919050565b6131b3816131a0565b81146131be57600080fd5b50565b6000813590506131d0816131aa565b92915050565b6000602082840312156131ec576131eb613020565b5b60006131fa848285016131c1565b91505092915050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061322e82613203565b9050919050565b61323e81613223565b82525050565b60006020820190506132596000830184613235565b92915050565b61326881613223565b811461327357600080fd5b50565b6000813590506132858161325f565b92915050565b600080604083850312156132a2576132a1613020565b5b60006132b085828601613276565b92505060206132c1858286016131c1565b9150509250929050565b6132d4816131a0565b82525050565b60006020820190506132ef60008301846132cb565b92915050565b60008060006060848603121561330e5761330d613020565b5b600061331c86828701613276565b935050602061332d86828701613276565b925050604061333e868287016131c1565b9150509250925092565b6000806040838503121561335f5761335e613020565b5b600061336d858286016131c1565b925050602061337e858286016131c1565b9150509250929050565b600060408201905061339d6000830185613235565b6133aa60208301846132cb565b9392505050565b600080fd5b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6133f382613134565b810181811067ffffffffffffffff82111715613412576134116133bb565b5b80604052505050565b6000613425613016565b905061343182826133ea565b919050565b600067ffffffffffffffff821115613451576134506133bb565b5b61345a82613134565b9050602081019050919050565b82818337600083830152505050565b600061348961348484613436565b61341b565b9050828152602081018484840111156134a5576134a46133b6565b5b6134b0848285613467565b509392505050565b600082601f8301126134cd576134cc6133b1565b5b81356134dd848260208601613476565b91505092915050565b6000602082840312156134fc576134fb613020565b5b600082013567ffffffffffffffff81111561351a57613519613025565b5b613526848285016134b8565b91505092915050565b60006020828403121561354557613544613020565b5b600061355384828501613276565b91505092915050565b600080fd5b600060c082840312156135775761357661355c565b5b81905092915050565b600080fd5b600080fd5b60008083601f8401126135a05761359f6133b1565b5b8235905067ffffffffffffffff8111156135bd576135bc613580565b5b6020830191508360018202830111156135d9576135d8613585565b5b9250929050565b600080600080606085870312156135fa576135f9613020565b5b600061360887828801613276565b945050602085013567ffffffffffffffff81111561362957613628613025565b5b61363587828801613561565b935050604085013567ffffffffffffffff81111561365657613655613025565b5b6136628782880161358a565b925092505092959194509250565b613679816130af565b811461368457600080fd5b50565b60008135905061369681613670565b92915050565b600080604083850312156136b3576136b2613020565b5b60006136c185828601613276565b92505060206136d285828601613687565b9150509250929050565b60006bffffffffffffffffffffffff82169050919050565b6136fd816136dc565b811461370857600080fd5b50565b60008135905061371a816136f4565b92915050565b60008060006060848603121561373957613738613020565b5b600084013567ffffffffffffffff81111561375757613756613025565b5b613763868287016134b8565b9350506020613774868287016131c1565b92505060406137858682870161370b565b9150509250925092565b600067ffffffffffffffff8211156137aa576137a96133bb565b5b6137b382613134565b9050602081019050919050565b60006137d36137ce8461378f565b61341b565b9050828152602081018484840111156137ef576137ee6133b6565b5b6137fa848285613467565b509392505050565b600082601f830112613817576138166133b1565b5b81356138278482602086016137c0565b91505092915050565b6000806000806080858703121561384a57613849613020565b5b600061385887828801613276565b945050602061386987828801613276565b935050604061387a878288016131c1565b925050606085013567ffffffffffffffff81111561389b5761389a613025565b5b6138a787828801613802565b91505092959194509250565b600080604083850312156138ca576138c9613020565b5b60006138d885828601613276565b92505060206138e985828601613276565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000600282049050600182168061393a57607f821691505b6020821081141561394e5761394d6138f3565b5b50919050565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b60006139b06021836130f0565b91506139bb82613954565b604082019050919050565b600060208201905081810360008301526139df816139a3565b9050919050565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60008201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c0000602082015250565b6000613a42603e836130f0565b9150613a4d826139e6565b604082019050919050565b60006020820190508181036000830152613a7181613a35565b9050919050565b7f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560008201527f72206e6f7220617070726f766564000000000000000000000000000000000000602082015250565b6000613ad4602e836130f0565b9150613adf82613a78565b604082019050919050565b60006020820190508181036000830152613b0381613ac7565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000613b44826131a0565b9150613b4f836131a0565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613b8857613b87613b0a565b5b828202905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000613bcd826131a0565b9150613bd8836131a0565b925082613be857613be7613b93565b5b828204905092915050565b7f455243373231456e756d657261626c653a206f776e657220696e646578206f7560008201527f74206f6620626f756e6473000000000000000000000000000000000000000000602082015250565b6000613c4f602b836130f0565b9150613c5a82613bf3565b604082019050919050565b60006020820190508181036000830152613c7e81613c42565b9050919050565b7f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60008201527f7574206f6620626f756e64730000000000000000000000000000000000000000602082015250565b6000613ce1602c836130f0565b9150613cec82613c85565b604082019050919050565b60006020820190508181036000830152613d1081613cd4565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4552433732313a20696e76616c696420746f6b656e2049440000000000000000600082015250565b6000613d7c6018836130f0565b9150613d8782613d46565b602082019050919050565b60006020820190508181036000830152613dab81613d6f565b9050919050565b7f4552433732313a2061646472657373207a65726f206973206e6f74206120766160008201527f6c6964206f776e65720000000000000000000000000000000000000000000000602082015250565b6000613e0e6029836130f0565b9150613e1982613db2565b604082019050919050565b60006020820190508181036000830152613e3d81613e01565b9050919050565b7f54686520766f7563686572206d75737420626520666f72207468697320636f6e60008201527f7472616374000000000000000000000000000000000000000000000000000000602082015250565b6000613ea06025836130f0565b9150613eab82613e44565b604082019050919050565b60006020820190508181036000830152613ecf81613e93565b9050919050565b6000613ee56020840184613276565b905092915050565b613ef681613223565b82525050565b6000613f0b60208401846131c1565b905092915050565b613f1c816131a0565b82525050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112613f4e57613f4d613f2c565b5b83810192508235915060208301925067ffffffffffffffff821115613f7657613f75613f22565b5b600182023603841315613f8c57613f8b613f27565b5b509250929050565b600082825260208201905092915050565b6000613fb18385613f94565b9350613fbe838584613467565b613fc783613134565b840190509392505050565b6000613fe1602084018461370b565b905092915050565b613ff2816136dc565b82525050565b600060c0830161400b6000840184613ed6565b6140186000860182613eed565b506140266020840184613efc565b6140336020860182613f13565b506140416040840184613efc565b61404e6040860182613f13565b5061405c6060840184613f31565b858303606087015261406f838284613fa5565b925050506140806080840184613ed6565b61408d6080860182613eed565b5061409b60a0840184613fd2565b6140a860a0860182613fe9565b508091505092915050565b600082825260208201905092915050565b60006140d083856140b3565b93506140dd838584613467565b6140e683613134565b840190509392505050565b6000604082019050818103600083015261410b8186613ff8565b905081810360208301526141208184866140c4565b9050949350505050565b6000815190506141398161325f565b92915050565b60006020828403121561415557614154613020565b5b60006141638482850161412a565b91505092915050565b7f43726561746f72204164647265737320646f6573206e6f74206d617463680000600082015250565b60006141a2601e836130f0565b91506141ad8261416c565b602082019050919050565b600060208201905081810360008301526141d181614195565b9050919050565b600080fd5b600080fd5b600080fd5b60008083356001602003843603038112614204576142036141d8565b5b80840192508235915067ffffffffffffffff821115614226576142256141dd565b5b602083019250600182023603831315614242576142416141e2565b5b509250929050565b6000602082840312156142605761425f613020565b5b600061426e8482850161370b565b91505092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b60006142d36026836130f0565b91506142de82614277565b604082019050919050565b60006020820190508181036000830152614302816142c6565b9050919050565b7f4552433732313a207472616e736665722066726f6d20696e636f72726563742060008201527f6f776e6572000000000000000000000000000000000000000000000000000000602082015250565b60006143656025836130f0565b915061437082614309565b604082019050919050565b6000602082019050818103600083015261439481614358565b9050919050565b7f4552433732313a207472616e7366657220746f20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b60006143f76024836130f0565b91506144028261439b565b604082019050919050565b60006020820190508181036000830152614426816143ea565b9050919050565b6000614438826131a0565b9150614443836131a0565b92508282101561445657614455613b0a565b5b828203905092915050565b600061446c826131a0565b9150614477836131a0565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156144ac576144ab613b0a565b5b828201905092915050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b60006144ed6020836130f0565b91506144f8826144b7565b602082019050919050565b6000602082019050818103600083015261451c816144e0565b9050919050565b7f45524337323155524953746f726167653a2055524920736574206f66206e6f6e60008201527f6578697374656e7420746f6b656e000000000000000000000000000000000000602082015250565b600061457f602e836130f0565b915061458a82614523565b604082019050919050565b600060208201905081810360008301526145ae81614572565b9050919050565b7f455243323938313a20726f79616c7479206665652077696c6c2065786365656460008201527f2073616c65507269636500000000000000000000000000000000000000000000602082015250565b6000614611602a836130f0565b915061461c826145b5565b604082019050919050565b6000602082019050818103600083015261464081614604565b9050919050565b7f455243323938313a20496e76616c696420706172616d65746572730000000000600082015250565b600061467d601b836130f0565b915061468882614647565b602082019050919050565b600060208201905081810360008301526146ac81614670565b9050919050565b7f4552433732313a20617070726f766520746f2063616c6c657200000000000000600082015250565b60006146e96019836130f0565b91506146f4826146b3565b602082019050919050565b60006020820190508181036000830152614718816146dc565b9050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b600061477b6032836130f0565b91506147868261471f565b604082019050919050565b600060208201905081810360008301526147aa8161476e565b9050919050565b600081905092915050565b60006147c7826130e5565b6147d181856147b1565b93506147e1818560208601613101565b80840191505092915050565b60006147f982856147bc565b915061480582846147bc565b91508190509392505050565b600081519050919050565b600061482782614811565b61483181856140b3565b9350614841818560208601613101565b61484a81613134565b840191505092915050565b600060808201905061486a6000830187613235565b6148776020830186613235565b61488460408301856132cb565b8181036060830152614896818461481c565b905095945050505050565b6000815190506148b081613056565b92915050565b6000602082840312156148cc576148cb613020565b5b60006148da848285016148a1565b91505092915050565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b60006149196020836130f0565b9150614924826148e3565b602082019050919050565b600060208201905081810360008301526149488161490c565b9050919050565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b6000614985601c836130f0565b91506149908261494f565b602082019050919050565b600060208201905081810360008301526149b481614978565b9050919050565b60006149c6826131a0565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156149f9576149f8613b0a565b5b600182019050919050565b6000614a0f826131a0565b9150614a1a836131a0565b925082614a2a57614a29613b93565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea26469706673582212201120869435d97d1590746349dd9e6898e9e8dab0873b47cdf5495389cda7741164736f6c63430008090033