{"constructor_args":null,"is_partially_verified":false,"is_changed_bytecode":false,"abi":[{"inputs":[],"name":"AccessControlBadConfirmation","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"neededRole","type":"bytes32"}],"name":"AccessControlUnauthorizedAccount","type":"error"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"AddressEmptyCode","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"AddressInsufficientBalance","type":"error"},{"inputs":[{"internalType":"bool","name":"currentStatus","type":"bool"}],"name":"BlacklistableStatusUnchanged","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"BlacklistedError","type":"error"},{"inputs":[{"internalType":"address","name":"implementation","type":"address"}],"name":"ERC1967InvalidImplementation","type":"error"},{"inputs":[],"name":"ERC1967NonPayable","type":"error"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"allowance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientAllowance","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"balance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientBalance","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC20InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC20InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC20InvalidSender","type":"error"},{"inputs":[{"internalType":"address","name":"spender","type":"address"}],"name":"ERC20InvalidSpender","type":"error"},{"inputs":[],"name":"EmptyKey","type":"error"},{"inputs":[],"name":"EmptyValue","type":"error"},{"inputs":[],"name":"EnforcedPause","type":"error"},{"inputs":[],"name":"ExpectedPause","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[],"name":"InvalidAddress","type":"error"},{"inputs":[],"name":"InvalidInitialization","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"KYCNotApprovedError","type":"error"},{"inputs":[{"internalType":"bool","name":"currentStatus","type":"bool"}],"name":"KYCableStatusUnchanged","type":"error"},{"inputs":[],"name":"KeysLengthMismatch","type":"error"},{"inputs":[],"name":"NotInitializing","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[{"internalType":"address","name":"token","type":"address"}],"name":"SafeERC20FailedOperation","type":"error"},{"inputs":[],"name":"TokenAlreadyRegistered","type":"error"},{"inputs":[],"name":"TokenNotRegistered","type":"error"},{"inputs":[],"name":"UUPSUnauthorizedCallContext","type":"error"},{"inputs":[{"internalType":"bytes32","name":"slot","type":"bytes32"}],"name":"UUPSUnsupportedProxiableUUID","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"BlacklistableStatusChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"value","type":"bytes32"}],"name":"DocumentHashAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"value","type":"bytes32"}],"name":"DocumentHashRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"key","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"oldValue","type":"bytes32"},{"indexed":false,"internalType":"bytes32","name":"newValue","type":"bytes32"}],"name":"DocumentHashUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"tokenAddress","type":"address"},{"indexed":true,"internalType":"address","name":"recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20TokenTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"tokenAddress","type":"address"},{"indexed":true,"internalType":"address","name":"recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721TokenTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint64","name":"version","type":"uint64"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"KYCableStatusChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"tokenAddress","type":"address"}],"name":"TokenRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"tokenAddress","type":"address"}],"name":"TokenUnregistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"inputs":[],"name":"BLACKLISTED_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"KYC_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UPGRADER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UPGRADE_INTERFACE_VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WIPER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"__DocumentHashRegistry_init","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address[]","name":"accounts","type":"address[]"}],"name":"batchGrantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address[]","name":"accounts","type":"address[]"}],"name":"batchRevokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwnerAddress","type":"address"}],"name":"changeOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"documentHashes","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"key","type":"bytes32"}],"name":"getDocumentHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"name_","type":"string"},{"internalType":"string","name":"symbol_","type":"string"},{"internalType":"uint256","name":"premintAmount","type":"uint256"},{"internalType":"bool","name":"kycEnabled_","type":"bool"},{"internalType":"bool","name":"blacklistEnabled_","type":"bool"},{"internalType":"uint8","name":"decimals_","type":"uint8"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isBlacklistable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"documentHash","type":"bytes32"}],"name":"isHashRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isKYCable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"isTokenRegistered","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proxiableUUID","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"registerToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"registeredHashes","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"callerConfirmation","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"enabled","type":"bool"}],"name":"setBlacklistableStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"enabled","type":"bool"}],"name":"setKYCableStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferERC20","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferERC721","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"unregisterToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"keys","type":"bytes32[]"},{"internalType":"bytes32[]","name":"values","type":"bytes32[]"}],"name":"updateDocumentHashes","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newImplementation","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"upgradeToAndCall","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"wipe","outputs":[],"stateMutability":"nonpayable","type":"function"}],"conflicting_implementations":null,"certified":false,"additional_sources":[{"file_path":"@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (access/AccessControl.sol)\n\npragma solidity ^0.8.20;\n\nimport {IAccessControl} from \"@openzeppelin/contracts/access/IAccessControl.sol\";\nimport {ContextUpgradeable} from \"../utils/ContextUpgradeable.sol\";\nimport {ERC165Upgradeable} from \"../utils/introspection/ERC165Upgradeable.sol\";\nimport {Initializable} from \"../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Contract module that allows children to implement role-based access\n * control mechanisms. This is a lightweight version that doesn't allow enumerating role\n * members except through off-chain means by accessing the contract event logs. Some\n * applications may benefit from on-chain enumerability, for those cases see\n * {AccessControlEnumerable}.\n *\n * Roles are referred to by their `bytes32` identifier. These should be exposed\n * in the external API and be unique. The best way to achieve this is by\n * using `public constant` hash digests:\n *\n * ```solidity\n * bytes32 public constant MY_ROLE = keccak256(\"MY_ROLE\");\n * ```\n *\n * Roles can be used to represent a set of permissions. To restrict access to a\n * function call, use {hasRole}:\n *\n * ```solidity\n * function foo() public {\n *     require(hasRole(MY_ROLE, msg.sender));\n *     ...\n * }\n * ```\n *\n * Roles can be granted and revoked dynamically via the {grantRole} and\n * {revokeRole} functions. Each role has an associated admin role, and only\n * accounts that have a role's admin role can call {grantRole} and {revokeRole}.\n *\n * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means\n * that only accounts with this role will be able to grant or revoke other\n * roles. More complex role relationships can be created by using\n * {_setRoleAdmin}.\n *\n * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to\n * grant and revoke this role. Extra precautions should be taken to secure\n * accounts that have been granted it. We recommend using {AccessControlDefaultAdminRules}\n * to enforce additional security measures for this role.\n */\nabstract contract AccessControlUpgradeable is Initializable, ContextUpgradeable, IAccessControl, ERC165Upgradeable {\n    struct RoleData {\n        mapping(address account => bool) hasRole;\n        bytes32 adminRole;\n    }\n\n    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;\n\n\n    /// @custom:storage-location erc7201:openzeppelin.storage.AccessControl\n    struct AccessControlStorage {\n        mapping(bytes32 role => RoleData) _roles;\n    }\n\n    // keccak256(abi.encode(uint256(keccak256(\"openzeppelin.storage.AccessControl\")) - 1)) & ~bytes32(uint256(0xff))\n    bytes32 private constant AccessControlStorageLocation = 0x02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800;\n\n    function _getAccessControlStorage() private pure returns (AccessControlStorage storage $) {\n        assembly {\n            $.slot := AccessControlStorageLocation\n        }\n    }\n\n    /**\n     * @dev Modifier that checks that an account has a specific role. Reverts\n     * with an {AccessControlUnauthorizedAccount} error including the required role.\n     */\n    modifier onlyRole(bytes32 role) {\n        _checkRole(role);\n        _;\n    }\n\n    function __AccessControl_init() internal onlyInitializing {\n    }\n\n    function __AccessControl_init_unchained() internal onlyInitializing {\n    }\n    /**\n     * @dev See {IERC165-supportsInterface}.\n     */\n    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {\n        return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);\n    }\n\n    /**\n     * @dev Returns `true` if `account` has been granted `role`.\n     */\n    function hasRole(bytes32 role, address account) public view virtual returns (bool) {\n        AccessControlStorage storage $ = _getAccessControlStorage();\n        return $._roles[role].hasRole[account];\n    }\n\n    /**\n     * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `_msgSender()`\n     * is missing `role`. Overriding this function changes the behavior of the {onlyRole} modifier.\n     */\n    function _checkRole(bytes32 role) internal view virtual {\n        _checkRole(role, _msgSender());\n    }\n\n    /**\n     * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `account`\n     * is missing `role`.\n     */\n    function _checkRole(bytes32 role, address account) internal view virtual {\n        if (!hasRole(role, account)) {\n            revert AccessControlUnauthorizedAccount(account, role);\n        }\n    }\n\n    /**\n     * @dev Returns the admin role that controls `role`. See {grantRole} and\n     * {revokeRole}.\n     *\n     * To change a role's admin, use {_setRoleAdmin}.\n     */\n    function getRoleAdmin(bytes32 role) public view virtual returns (bytes32) {\n        AccessControlStorage storage $ = _getAccessControlStorage();\n        return $._roles[role].adminRole;\n    }\n\n    /**\n     * @dev Grants `role` to `account`.\n     *\n     * If `account` had not been already granted `role`, emits a {RoleGranted}\n     * event.\n     *\n     * Requirements:\n     *\n     * - the caller must have ``role``'s admin role.\n     *\n     * May emit a {RoleGranted} event.\n     */\n    function grantRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {\n        _grantRole(role, account);\n    }\n\n    /**\n     * @dev Revokes `role` from `account`.\n     *\n     * If `account` had been granted `role`, emits a {RoleRevoked} event.\n     *\n     * Requirements:\n     *\n     * - the caller must have ``role``'s admin role.\n     *\n     * May emit a {RoleRevoked} event.\n     */\n    function revokeRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {\n        _revokeRole(role, account);\n    }\n\n    /**\n     * @dev Revokes `role` from the calling account.\n     *\n     * Roles are often managed via {grantRole} and {revokeRole}: this function's\n     * purpose is to provide a mechanism for accounts to lose their privileges\n     * if they are compromised (such as when a trusted device is misplaced).\n     *\n     * If the calling account had been revoked `role`, emits a {RoleRevoked}\n     * event.\n     *\n     * Requirements:\n     *\n     * - the caller must be `callerConfirmation`.\n     *\n     * May emit a {RoleRevoked} event.\n     */\n    function renounceRole(bytes32 role, address callerConfirmation) public virtual {\n        if (callerConfirmation != _msgSender()) {\n            revert AccessControlBadConfirmation();\n        }\n\n        _revokeRole(role, callerConfirmation);\n    }\n\n    /**\n     * @dev Sets `adminRole` as ``role``'s admin role.\n     *\n     * Emits a {RoleAdminChanged} event.\n     */\n    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {\n        AccessControlStorage storage $ = _getAccessControlStorage();\n        bytes32 previousAdminRole = getRoleAdmin(role);\n        $._roles[role].adminRole = adminRole;\n        emit RoleAdminChanged(role, previousAdminRole, adminRole);\n    }\n\n    /**\n     * @dev Attempts to grant `role` to `account` and returns a boolean indicating if `role` was granted.\n     *\n     * Internal function without access restriction.\n     *\n     * May emit a {RoleGranted} event.\n     */\n    function _grantRole(bytes32 role, address account) internal virtual returns (bool) {\n        AccessControlStorage storage $ = _getAccessControlStorage();\n        if (!hasRole(role, account)) {\n            $._roles[role].hasRole[account] = true;\n            emit RoleGranted(role, account, _msgSender());\n            return true;\n        } else {\n            return false;\n        }\n    }\n\n    /**\n     * @dev Attempts to revoke `role` to `account` and returns a boolean indicating if `role` was revoked.\n     *\n     * Internal function without access restriction.\n     *\n     * May emit a {RoleRevoked} event.\n     */\n    function _revokeRole(bytes32 role, address account) internal virtual returns (bool) {\n        AccessControlStorage storage $ = _getAccessControlStorage();\n        if (hasRole(role, account)) {\n            $._roles[role].hasRole[account] = false;\n            emit RoleRevoked(role, account, _msgSender());\n            return true;\n        } else {\n            return false;\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (proxy/utils/Initializable.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed\n * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an\n * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer\n * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.\n *\n * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be\n * reused. This mechanism prevents re-execution of each \"step\" but allows the creation of new initialization steps in\n * case an upgrade adds a module that needs to be initialized.\n *\n * For example:\n *\n * [.hljs-theme-light.nopadding]\n * ```solidity\n * contract MyToken is ERC20Upgradeable {\n *     function initialize() initializer public {\n *         __ERC20_init(\"MyToken\", \"MTK\");\n *     }\n * }\n *\n * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {\n *     function initializeV2() reinitializer(2) public {\n *         __ERC20Permit_init(\"MyToken\");\n *     }\n * }\n * ```\n *\n * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as\n * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.\n *\n * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure\n * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.\n *\n * [CAUTION]\n * ====\n * Avoid leaving a contract uninitialized.\n *\n * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation\n * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke\n * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:\n *\n * [.hljs-theme-light.nopadding]\n * ```\n * /// @custom:oz-upgrades-unsafe-allow constructor\n * constructor() {\n *     _disableInitializers();\n * }\n * ```\n * ====\n */\nabstract contract Initializable {\n    /**\n     * @dev Storage of the initializable contract.\n     *\n     * It's implemented on a custom ERC-7201 namespace to reduce the risk of storage collisions\n     * when using with upgradeable contracts.\n     *\n     * @custom:storage-location erc7201:openzeppelin.storage.Initializable\n     */\n    struct InitializableStorage {\n        /**\n         * @dev Indicates that the contract has been initialized.\n         */\n        uint64 _initialized;\n        /**\n         * @dev Indicates that the contract is in the process of being initialized.\n         */\n        bool _initializing;\n    }\n\n    // keccak256(abi.encode(uint256(keccak256(\"openzeppelin.storage.Initializable\")) - 1)) & ~bytes32(uint256(0xff))\n    bytes32 private constant INITIALIZABLE_STORAGE = 0xf0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00;\n\n    /**\n     * @dev The contract is already initialized.\n     */\n    error InvalidInitialization();\n\n    /**\n     * @dev The contract is not initializing.\n     */\n    error NotInitializing();\n\n    /**\n     * @dev Triggered when the contract has been initialized or reinitialized.\n     */\n    event Initialized(uint64 version);\n\n    /**\n     * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,\n     * `onlyInitializing` functions can be used to initialize parent contracts.\n     *\n     * Similar to `reinitializer(1)`, except that in the context of a constructor an `initializer` may be invoked any\n     * number of times. This behavior in the constructor can be useful during testing and is not expected to be used in\n     * production.\n     *\n     * Emits an {Initialized} event.\n     */\n    modifier initializer() {\n        // solhint-disable-next-line var-name-mixedcase\n        InitializableStorage storage $ = _getInitializableStorage();\n\n        // Cache values to avoid duplicated sloads\n        bool isTopLevelCall = !$._initializing;\n        uint64 initialized = $._initialized;\n\n        // Allowed calls:\n        // - initialSetup: the contract is not in the initializing state and no previous version was\n        //                 initialized\n        // - construction: the contract is initialized at version 1 (no reininitialization) and the\n        //                 current contract is just being deployed\n        bool initialSetup = initialized == 0 && isTopLevelCall;\n        bool construction = initialized == 1 && address(this).code.length == 0;\n\n        if (!initialSetup && !construction) {\n            revert InvalidInitialization();\n        }\n        $._initialized = 1;\n        if (isTopLevelCall) {\n            $._initializing = true;\n        }\n        _;\n        if (isTopLevelCall) {\n            $._initializing = false;\n            emit Initialized(1);\n        }\n    }\n\n    /**\n     * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the\n     * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be\n     * used to initialize parent contracts.\n     *\n     * A reinitializer may be used after the original initialization step. This is essential to configure modules that\n     * are added through upgrades and that require initialization.\n     *\n     * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`\n     * cannot be nested. If one is invoked in the context of another, execution will revert.\n     *\n     * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in\n     * a contract, executing them in the right order is up to the developer or operator.\n     *\n     * WARNING: Setting the version to 2**64 - 1 will prevent any future reinitialization.\n     *\n     * Emits an {Initialized} event.\n     */\n    modifier reinitializer(uint64 version) {\n        // solhint-disable-next-line var-name-mixedcase\n        InitializableStorage storage $ = _getInitializableStorage();\n\n        if ($._initializing || $._initialized >= version) {\n            revert InvalidInitialization();\n        }\n        $._initialized = version;\n        $._initializing = true;\n        _;\n        $._initializing = false;\n        emit Initialized(version);\n    }\n\n    /**\n     * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the\n     * {initializer} and {reinitializer} modifiers, directly or indirectly.\n     */\n    modifier onlyInitializing() {\n        _checkInitializing();\n        _;\n    }\n\n    /**\n     * @dev Reverts if the contract is not in an initializing state. See {onlyInitializing}.\n     */\n    function _checkInitializing() internal view virtual {\n        if (!_isInitializing()) {\n            revert NotInitializing();\n        }\n    }\n\n    /**\n     * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.\n     * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized\n     * to any version. It is recommended to use this to lock implementation contracts that are designed to be called\n     * through proxies.\n     *\n     * Emits an {Initialized} event the first time it is successfully executed.\n     */\n    function _disableInitializers() internal virtual {\n        // solhint-disable-next-line var-name-mixedcase\n        InitializableStorage storage $ = _getInitializableStorage();\n\n        if ($._initializing) {\n            revert InvalidInitialization();\n        }\n        if ($._initialized != type(uint64).max) {\n            $._initialized = type(uint64).max;\n            emit Initialized(type(uint64).max);\n        }\n    }\n\n    /**\n     * @dev Returns the highest version that has been initialized. See {reinitializer}.\n     */\n    function _getInitializedVersion() internal view returns (uint64) {\n        return _getInitializableStorage()._initialized;\n    }\n\n    /**\n     * @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}.\n     */\n    function _isInitializing() internal view returns (bool) {\n        return _getInitializableStorage()._initializing;\n    }\n\n    /**\n     * @dev Returns a pointer to the storage namespace.\n     */\n    // solhint-disable-next-line var-name-mixedcase\n    function _getInitializableStorage() private pure returns (InitializableStorage storage $) {\n        assembly {\n            $.slot := INITIALIZABLE_STORAGE\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (proxy/utils/UUPSUpgradeable.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC1822Proxiable} from \"@openzeppelin/contracts/interfaces/draft-IERC1822.sol\";\nimport {ERC1967Utils} from \"@openzeppelin/contracts/proxy/ERC1967/ERC1967Utils.sol\";\nimport {Initializable} from \"./Initializable.sol\";\n\n/**\n * @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an\n * {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy.\n *\n * A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is\n * reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing\n * `UUPSUpgradeable` with a custom implementation of upgrades.\n *\n * The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism.\n */\nabstract contract UUPSUpgradeable is Initializable, IERC1822Proxiable {\n    /// @custom:oz-upgrades-unsafe-allow state-variable-immutable\n    address private immutable __self = address(this);\n\n    /**\n     * @dev The version of the upgrade interface of the contract. If this getter is missing, both `upgradeTo(address)`\n     * and `upgradeToAndCall(address,bytes)` are present, and `upgradeTo` must be used if no function should be called,\n     * while `upgradeToAndCall` will invoke the `receive` function if the second argument is the empty byte string.\n     * If the getter returns `\"5.0.0\"`, only `upgradeToAndCall(address,bytes)` is present, and the second argument must\n     * be the empty byte string if no function should be called, making it impossible to invoke the `receive` function\n     * during an upgrade.\n     */\n    string public constant UPGRADE_INTERFACE_VERSION = \"5.0.0\";\n\n    /**\n     * @dev The call is from an unauthorized context.\n     */\n    error UUPSUnauthorizedCallContext();\n\n    /**\n     * @dev The storage `slot` is unsupported as a UUID.\n     */\n    error UUPSUnsupportedProxiableUUID(bytes32 slot);\n\n    /**\n     * @dev Check that the execution is being performed through a delegatecall call and that the execution context is\n     * a proxy contract with an implementation (as defined in ERC1967) pointing to self. This should only be the case\n     * for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a\n     * function through ERC1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to\n     * fail.\n     */\n    modifier onlyProxy() {\n        _checkProxy();\n        _;\n    }\n\n    /**\n     * @dev Check that the execution is not being performed through a delegate call. This allows a function to be\n     * callable on the implementing contract but not through proxies.\n     */\n    modifier notDelegated() {\n        _checkNotDelegated();\n        _;\n    }\n\n    function __UUPSUpgradeable_init() internal onlyInitializing {\n    }\n\n    function __UUPSUpgradeable_init_unchained() internal onlyInitializing {\n    }\n    /**\n     * @dev Implementation of the ERC1822 {proxiableUUID} function. This returns the storage slot used by the\n     * implementation. It is used to validate the implementation's compatibility when performing an upgrade.\n     *\n     * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\n     * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\n     * function revert if invoked through a proxy. This is guaranteed by the `notDelegated` modifier.\n     */\n    function proxiableUUID() external view virtual notDelegated returns (bytes32) {\n        return ERC1967Utils.IMPLEMENTATION_SLOT;\n    }\n\n    /**\n     * @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call\n     * encoded in `data`.\n     *\n     * Calls {_authorizeUpgrade}.\n     *\n     * Emits an {Upgraded} event.\n     *\n     * @custom:oz-upgrades-unsafe-allow-reachable delegatecall\n     */\n    function upgradeToAndCall(address newImplementation, bytes memory data) public payable virtual onlyProxy {\n        _authorizeUpgrade(newImplementation);\n        _upgradeToAndCallUUPS(newImplementation, data);\n    }\n\n    /**\n     * @dev Reverts if the execution is not performed via delegatecall or the execution\n     * context is not of a proxy with an ERC1967-compliant implementation pointing to self.\n     * See {_onlyProxy}.\n     */\n    function _checkProxy() internal view virtual {\n        if (\n            address(this) == __self || // Must be called through delegatecall\n            ERC1967Utils.getImplementation() != __self // Must be called through an active proxy\n        ) {\n            revert UUPSUnauthorizedCallContext();\n        }\n    }\n\n    /**\n     * @dev Reverts if the execution is performed via delegatecall.\n     * See {notDelegated}.\n     */\n    function _checkNotDelegated() internal view virtual {\n        if (address(this) != __self) {\n            // Must not be called through delegatecall\n            revert UUPSUnauthorizedCallContext();\n        }\n    }\n\n    /**\n     * @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by\n     * {upgradeToAndCall}.\n     *\n     * Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}.\n     *\n     * ```solidity\n     * function _authorizeUpgrade(address) internal onlyOwner {}\n     * ```\n     */\n    function _authorizeUpgrade(address newImplementation) internal virtual;\n\n    /**\n     * @dev Performs an implementation upgrade with a security check for UUPS proxies, and additional setup call.\n     *\n     * As a security check, {proxiableUUID} is invoked in the new implementation, and the return value\n     * is expected to be the implementation slot in ERC1967.\n     *\n     * Emits an {IERC1967-Upgraded} event.\n     */\n    function _upgradeToAndCallUUPS(address newImplementation, bytes memory data) private {\n        try IERC1822Proxiable(newImplementation).proxiableUUID() returns (bytes32 slot) {\n            if (slot != ERC1967Utils.IMPLEMENTATION_SLOT) {\n                revert UUPSUnsupportedProxiableUUID(slot);\n            }\n            ERC1967Utils.upgradeToAndCall(newImplementation, data);\n        } catch {\n            // The implementation is not UUPS\n            revert ERC1967Utils.ERC1967InvalidImplementation(newImplementation);\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/ERC20.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC20} from \"@openzeppelin/contracts/token/ERC20/IERC20.sol\";\nimport {IERC20Metadata} from \"@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol\";\nimport {ContextUpgradeable} from \"../../utils/ContextUpgradeable.sol\";\nimport {IERC20Errors} from \"@openzeppelin/contracts/interfaces/draft-IERC6093.sol\";\nimport {Initializable} from \"../../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Implementation of the {IERC20} interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply mechanism has to be added in a derived contract using {_mint}.\n *\n * TIP: For a detailed writeup see our guide\n * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How\n * to implement supply mechanisms].\n *\n * The default value of {decimals} is 18. To change this, you should override\n * this function so it returns a different value.\n *\n * We have followed general OpenZeppelin Contracts guidelines: functions revert\n * instead returning `false` on failure. This behavior is nonetheless\n * conventional and does not conflict with the expectations of ERC20\n * applications.\n *\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to said events. Other implementations of the EIP may not emit\n * these events, as it isn't required by the specification.\n */\nabstract contract ERC20Upgradeable is Initializable, ContextUpgradeable, IERC20, IERC20Metadata, IERC20Errors {\n    /// @custom:storage-location erc7201:openzeppelin.storage.ERC20\n    struct ERC20Storage {\n        mapping(address account => uint256) _balances;\n\n        mapping(address account => mapping(address spender => uint256)) _allowances;\n\n        uint256 _totalSupply;\n\n        string _name;\n        string _symbol;\n    }\n\n    // keccak256(abi.encode(uint256(keccak256(\"openzeppelin.storage.ERC20\")) - 1)) & ~bytes32(uint256(0xff))\n    bytes32 private constant ERC20StorageLocation = 0x52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace00;\n\n    function _getERC20Storage() private pure returns (ERC20Storage storage $) {\n        assembly {\n            $.slot := ERC20StorageLocation\n        }\n    }\n\n    /**\n     * @dev Sets the values for {name} and {symbol}.\n     *\n     * All two of these values are immutable: they can only be set once during\n     * construction.\n     */\n    function __ERC20_init(string memory name_, string memory symbol_) internal onlyInitializing {\n        __ERC20_init_unchained(name_, symbol_);\n    }\n\n    function __ERC20_init_unchained(string memory name_, string memory symbol_) internal onlyInitializing {\n        ERC20Storage storage $ = _getERC20Storage();\n        $._name = name_;\n        $._symbol = symbol_;\n    }\n\n    /**\n     * @dev Returns the name of the token.\n     */\n    function name() public view virtual returns (string memory) {\n        ERC20Storage storage $ = _getERC20Storage();\n        return $._name;\n    }\n\n    /**\n     * @dev Returns the symbol of the token, usually a shorter version of the\n     * name.\n     */\n    function symbol() public view virtual returns (string memory) {\n        ERC20Storage storage $ = _getERC20Storage();\n        return $._symbol;\n    }\n\n    /**\n     * @dev Returns the number of decimals used to get its user representation.\n     * For example, if `decimals` equals `2`, a balance of `505` tokens should\n     * be displayed to a user as `5.05` (`505 / 10 ** 2`).\n     *\n     * Tokens usually opt for a value of 18, imitating the relationship between\n     * Ether and Wei. This is the default value returned by this function, unless\n     * it's overridden.\n     *\n     * NOTE: This information is only used for _display_ purposes: it in\n     * no way affects any of the arithmetic of the contract, including\n     * {IERC20-balanceOf} and {IERC20-transfer}.\n     */\n    function decimals() public view virtual returns (uint8) {\n        return 18;\n    }\n\n    /**\n     * @dev See {IERC20-totalSupply}.\n     */\n    function totalSupply() public view virtual returns (uint256) {\n        ERC20Storage storage $ = _getERC20Storage();\n        return $._totalSupply;\n    }\n\n    /**\n     * @dev See {IERC20-balanceOf}.\n     */\n    function balanceOf(address account) public view virtual returns (uint256) {\n        ERC20Storage storage $ = _getERC20Storage();\n        return $._balances[account];\n    }\n\n    /**\n     * @dev See {IERC20-transfer}.\n     *\n     * Requirements:\n     *\n     * - `to` cannot be the zero address.\n     * - the caller must have a balance of at least `value`.\n     */\n    function transfer(address to, uint256 value) public virtual returns (bool) {\n        address owner = _msgSender();\n        _transfer(owner, to, value);\n        return true;\n    }\n\n    /**\n     * @dev See {IERC20-allowance}.\n     */\n    function allowance(address owner, address spender) public view virtual returns (uint256) {\n        ERC20Storage storage $ = _getERC20Storage();\n        return $._allowances[owner][spender];\n    }\n\n    /**\n     * @dev See {IERC20-approve}.\n     *\n     * NOTE: If `value` is the maximum `uint256`, the allowance is not updated on\n     * `transferFrom`. This is semantically equivalent to an infinite approval.\n     *\n     * Requirements:\n     *\n     * - `spender` cannot be the zero address.\n     */\n    function approve(address spender, uint256 value) public virtual returns (bool) {\n        address owner = _msgSender();\n        _approve(owner, spender, value);\n        return true;\n    }\n\n    /**\n     * @dev See {IERC20-transferFrom}.\n     *\n     * Emits an {Approval} event indicating the updated allowance. This is not\n     * required by the EIP. See the note at the beginning of {ERC20}.\n     *\n     * NOTE: Does not update the allowance if the current allowance\n     * is the maximum `uint256`.\n     *\n     * Requirements:\n     *\n     * - `from` and `to` cannot be the zero address.\n     * - `from` must have a balance of at least `value`.\n     * - the caller must have allowance for ``from``'s tokens of at least\n     * `value`.\n     */\n    function transferFrom(address from, address to, uint256 value) public virtual returns (bool) {\n        address spender = _msgSender();\n        _spendAllowance(from, spender, value);\n        _transfer(from, to, value);\n        return true;\n    }\n\n    /**\n     * @dev Moves a `value` amount of tokens from `from` to `to`.\n     *\n     * This internal function is equivalent to {transfer}, and can be used to\n     * e.g. implement automatic token fees, slashing mechanisms, etc.\n     *\n     * Emits a {Transfer} event.\n     *\n     * NOTE: This function is not virtual, {_update} should be overridden instead.\n     */\n    function _transfer(address from, address to, uint256 value) internal {\n        if (from == address(0)) {\n            revert ERC20InvalidSender(address(0));\n        }\n        if (to == address(0)) {\n            revert ERC20InvalidReceiver(address(0));\n        }\n        _update(from, to, value);\n    }\n\n    /**\n     * @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`\n     * (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding\n     * this function.\n     *\n     * Emits a {Transfer} event.\n     */\n    function _update(address from, address to, uint256 value) internal virtual {\n        ERC20Storage storage $ = _getERC20Storage();\n        if (from == address(0)) {\n            // Overflow check required: The rest of the code assumes that totalSupply never overflows\n            $._totalSupply += value;\n        } else {\n            uint256 fromBalance = $._balances[from];\n            if (fromBalance < value) {\n                revert ERC20InsufficientBalance(from, fromBalance, value);\n            }\n            unchecked {\n                // Overflow not possible: value <= fromBalance <= totalSupply.\n                $._balances[from] = fromBalance - value;\n            }\n        }\n\n        if (to == address(0)) {\n            unchecked {\n                // Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply.\n                $._totalSupply -= value;\n            }\n        } else {\n            unchecked {\n                // Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256.\n                $._balances[to] += value;\n            }\n        }\n\n        emit Transfer(from, to, value);\n    }\n\n    /**\n     * @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0).\n     * Relies on the `_update` mechanism\n     *\n     * Emits a {Transfer} event with `from` set to the zero address.\n     *\n     * NOTE: This function is not virtual, {_update} should be overridden instead.\n     */\n    function _mint(address account, uint256 value) internal {\n        if (account == address(0)) {\n            revert ERC20InvalidReceiver(address(0));\n        }\n        _update(address(0), account, value);\n    }\n\n    /**\n     * @dev Destroys a `value` amount of tokens from `account`, lowering the total supply.\n     * Relies on the `_update` mechanism.\n     *\n     * Emits a {Transfer} event with `to` set to the zero address.\n     *\n     * NOTE: This function is not virtual, {_update} should be overridden instead\n     */\n    function _burn(address account, uint256 value) internal {\n        if (account == address(0)) {\n            revert ERC20InvalidSender(address(0));\n        }\n        _update(account, address(0), value);\n    }\n\n    /**\n     * @dev Sets `value` as the allowance of `spender` over the `owner` s tokens.\n     *\n     * This internal function is equivalent to `approve`, and can be used to\n     * e.g. set automatic allowances for certain subsystems, etc.\n     *\n     * Emits an {Approval} event.\n     *\n     * Requirements:\n     *\n     * - `owner` cannot be the zero address.\n     * - `spender` cannot be the zero address.\n     *\n     * Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument.\n     */\n    function _approve(address owner, address spender, uint256 value) internal {\n        _approve(owner, spender, value, true);\n    }\n\n    /**\n     * @dev Variant of {_approve} with an optional flag to enable or disable the {Approval} event.\n     *\n     * By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by\n     * `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any\n     * `Approval` event during `transferFrom` operations.\n     *\n     * Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to\n     * true using the following override:\n     * ```\n     * function _approve(address owner, address spender, uint256 value, bool) internal virtual override {\n     *     super._approve(owner, spender, value, true);\n     * }\n     * ```\n     *\n     * Requirements are the same as {_approve}.\n     */\n    function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual {\n        ERC20Storage storage $ = _getERC20Storage();\n        if (owner == address(0)) {\n            revert ERC20InvalidApprover(address(0));\n        }\n        if (spender == address(0)) {\n            revert ERC20InvalidSpender(address(0));\n        }\n        $._allowances[owner][spender] = value;\n        if (emitEvent) {\n            emit Approval(owner, spender, value);\n        }\n    }\n\n    /**\n     * @dev Updates `owner` s allowance for `spender` based on spent `value`.\n     *\n     * Does not update the allowance value in case of infinite allowance.\n     * Revert if not enough allowance is available.\n     *\n     * Does not emit an {Approval} event.\n     */\n    function _spendAllowance(address owner, address spender, uint256 value) internal virtual {\n        uint256 currentAllowance = allowance(owner, spender);\n        if (currentAllowance != type(uint256).max) {\n            if (currentAllowance < value) {\n                revert ERC20InsufficientAllowance(spender, currentAllowance, value);\n            }\n            unchecked {\n                _approve(owner, spender, currentAllowance - value, false);\n            }\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/token/ERC20/extensions/ERC20PausableUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/ERC20Pausable.sol)\n\npragma solidity ^0.8.20;\n\nimport {ERC20Upgradeable} from \"../ERC20Upgradeable.sol\";\nimport {PausableUpgradeable} from \"../../../utils/PausableUpgradeable.sol\";\nimport {Initializable} from \"../../../proxy/utils/Initializable.sol\";\n\n/**\n * @dev ERC20 token with pausable token transfers, minting and burning.\n *\n * Useful for scenarios such as preventing trades until the end of an evaluation\n * period, or having an emergency switch for freezing all token transfers in the\n * event of a large bug.\n *\n * IMPORTANT: This contract does not include public pause and unpause functions. In\n * addition to inheriting this contract, you must define both functions, invoking the\n * {Pausable-_pause} and {Pausable-_unpause} internal functions, with appropriate\n * access control, e.g. using {AccessControl} or {Ownable}. Not doing so will\n * make the contract pause mechanism of the contract unreachable, and thus unusable.\n */\nabstract contract ERC20PausableUpgradeable is Initializable, ERC20Upgradeable, PausableUpgradeable {\n    function __ERC20Pausable_init() internal onlyInitializing {\n        __Pausable_init_unchained();\n    }\n\n    function __ERC20Pausable_init_unchained() internal onlyInitializing {\n    }\n    /**\n     * @dev See {ERC20-_update}.\n     *\n     * Requirements:\n     *\n     * - the contract must not be paused.\n     */\n    function _update(address from, address to, uint256 value) internal virtual override whenNotPaused {\n        super._update(from, to, value);\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)\n\npragma solidity ^0.8.20;\nimport {Initializable} from \"../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Provides information about the current execution context, including the\n * sender of the transaction and its data. While these are generally available\n * via msg.sender and msg.data, they should not be accessed in such a direct\n * manner, since when dealing with meta-transactions the account sending and\n * paying for execution may not be the actual sender (as far as an application\n * is concerned).\n *\n * This contract is only required for intermediate, library-like contracts.\n */\nabstract contract ContextUpgradeable is Initializable {\n    function __Context_init() internal onlyInitializing {\n    }\n\n    function __Context_init_unchained() internal onlyInitializing {\n    }\n    function _msgSender() internal view virtual returns (address) {\n        return msg.sender;\n    }\n\n    function _msgData() internal view virtual returns (bytes calldata) {\n        return msg.data;\n    }\n\n    function _contextSuffixLength() internal view virtual returns (uint256) {\n        return 0;\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/utils/PausableUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/Pausable.sol)\n\npragma solidity ^0.8.20;\n\nimport {ContextUpgradeable} from \"../utils/ContextUpgradeable.sol\";\nimport {Initializable} from \"../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Contract module which allows children to implement an emergency stop\n * mechanism that can be triggered by an authorized account.\n *\n * This module is used through inheritance. It will make available the\n * modifiers `whenNotPaused` and `whenPaused`, which can be applied to\n * the functions of your contract. Note that they will not be pausable by\n * simply including this module, only once the modifiers are put in place.\n */\nabstract contract PausableUpgradeable is Initializable, ContextUpgradeable {\n    /// @custom:storage-location erc7201:openzeppelin.storage.Pausable\n    struct PausableStorage {\n        bool _paused;\n    }\n\n    // keccak256(abi.encode(uint256(keccak256(\"openzeppelin.storage.Pausable\")) - 1)) & ~bytes32(uint256(0xff))\n    bytes32 private constant PausableStorageLocation = 0xcd5ed15c6e187e77e9aee88184c21f4f2182ab5827cb3b7e07fbedcd63f03300;\n\n    function _getPausableStorage() private pure returns (PausableStorage storage $) {\n        assembly {\n            $.slot := PausableStorageLocation\n        }\n    }\n\n    /**\n     * @dev Emitted when the pause is triggered by `account`.\n     */\n    event Paused(address account);\n\n    /**\n     * @dev Emitted when the pause is lifted by `account`.\n     */\n    event Unpaused(address account);\n\n    /**\n     * @dev The operation failed because the contract is paused.\n     */\n    error EnforcedPause();\n\n    /**\n     * @dev The operation failed because the contract is not paused.\n     */\n    error ExpectedPause();\n\n    /**\n     * @dev Initializes the contract in unpaused state.\n     */\n    function __Pausable_init() internal onlyInitializing {\n        __Pausable_init_unchained();\n    }\n\n    function __Pausable_init_unchained() internal onlyInitializing {\n        PausableStorage storage $ = _getPausableStorage();\n        $._paused = false;\n    }\n\n    /**\n     * @dev Modifier to make a function callable only when the contract is not paused.\n     *\n     * Requirements:\n     *\n     * - The contract must not be paused.\n     */\n    modifier whenNotPaused() {\n        _requireNotPaused();\n        _;\n    }\n\n    /**\n     * @dev Modifier to make a function callable only when the contract is paused.\n     *\n     * Requirements:\n     *\n     * - The contract must be paused.\n     */\n    modifier whenPaused() {\n        _requirePaused();\n        _;\n    }\n\n    /**\n     * @dev Returns true if the contract is paused, and false otherwise.\n     */\n    function paused() public view virtual returns (bool) {\n        PausableStorage storage $ = _getPausableStorage();\n        return $._paused;\n    }\n\n    /**\n     * @dev Throws if the contract is paused.\n     */\n    function _requireNotPaused() internal view virtual {\n        if (paused()) {\n            revert EnforcedPause();\n        }\n    }\n\n    /**\n     * @dev Throws if the contract is not paused.\n     */\n    function _requirePaused() internal view virtual {\n        if (!paused()) {\n            revert ExpectedPause();\n        }\n    }\n\n    /**\n     * @dev Triggers stopped state.\n     *\n     * Requirements:\n     *\n     * - The contract must not be paused.\n     */\n    function _pause() internal virtual whenNotPaused {\n        PausableStorage storage $ = _getPausableStorage();\n        $._paused = true;\n        emit Paused(_msgSender());\n    }\n\n    /**\n     * @dev Returns to normal state.\n     *\n     * Requirements:\n     *\n     * - The contract must be paused.\n     */\n    function _unpause() internal virtual whenPaused {\n        PausableStorage storage $ = _getPausableStorage();\n        $._paused = false;\n        emit Unpaused(_msgSender());\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/utils/ReentrancyGuardUpgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/ReentrancyGuard.sol)\n\npragma solidity ^0.8.20;\nimport {Initializable} from \"../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n *\n * TIP: If you would like to learn more about reentrancy and alternative ways\n * to protect against it, check out our blog post\n * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].\n */\nabstract contract ReentrancyGuardUpgradeable is Initializable {\n    // Booleans are more expensive than uint256 or any type that takes up a full\n    // word because each write operation emits an extra SLOAD to first read the\n    // slot's contents, replace the bits taken up by the boolean, and then write\n    // back. This is the compiler's defense against contract upgrades and\n    // pointer aliasing, and it cannot be disabled.\n\n    // The values being non-zero value makes deployment a bit more expensive,\n    // but in exchange the refund on every call to nonReentrant will be lower in\n    // amount. Since refunds are capped to a percentage of the total\n    // transaction's gas, it is best to keep them low in cases like this one, to\n    // increase the likelihood of the full refund coming into effect.\n    uint256 private constant NOT_ENTERED = 1;\n    uint256 private constant ENTERED = 2;\n\n    /// @custom:storage-location erc7201:openzeppelin.storage.ReentrancyGuard\n    struct ReentrancyGuardStorage {\n        uint256 _status;\n    }\n\n    // keccak256(abi.encode(uint256(keccak256(\"openzeppelin.storage.ReentrancyGuard\")) - 1)) & ~bytes32(uint256(0xff))\n    bytes32 private constant ReentrancyGuardStorageLocation = 0x9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00;\n\n    function _getReentrancyGuardStorage() private pure returns (ReentrancyGuardStorage storage $) {\n        assembly {\n            $.slot := ReentrancyGuardStorageLocation\n        }\n    }\n\n    /**\n     * @dev Unauthorized reentrant call.\n     */\n    error ReentrancyGuardReentrantCall();\n\n    function __ReentrancyGuard_init() internal onlyInitializing {\n        __ReentrancyGuard_init_unchained();\n    }\n\n    function __ReentrancyGuard_init_unchained() internal onlyInitializing {\n        ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();\n        $._status = NOT_ENTERED;\n    }\n\n    /**\n     * @dev Prevents a contract from calling itself, directly or indirectly.\n     * Calling a `nonReentrant` function from another `nonReentrant`\n     * function is not supported. It is possible to prevent this from happening\n     * by making the `nonReentrant` function external, and making it call a\n     * `private` function that does the actual work.\n     */\n    modifier nonReentrant() {\n        _nonReentrantBefore();\n        _;\n        _nonReentrantAfter();\n    }\n\n    function _nonReentrantBefore() private {\n        ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();\n        // On the first call to nonReentrant, _status will be NOT_ENTERED\n        if ($._status == ENTERED) {\n            revert ReentrancyGuardReentrantCall();\n        }\n\n        // Any calls to nonReentrant after this point will fail\n        $._status = ENTERED;\n    }\n\n    function _nonReentrantAfter() private {\n        ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();\n        // By storing the original value once again, a refund is triggered (see\n        // https://eips.ethereum.org/EIPS/eip-2200)\n        $._status = NOT_ENTERED;\n    }\n\n    /**\n     * @dev Returns true if the reentrancy guard is currently set to \"entered\", which indicates there is a\n     * `nonReentrant` function in the call stack.\n     */\n    function _reentrancyGuardEntered() internal view returns (bool) {\n        ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();\n        return $._status == ENTERED;\n    }\n}\n"},{"file_path":"@openzeppelin/contracts-upgradeable/utils/introspection/ERC165Upgradeable.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC165} from \"@openzeppelin/contracts/utils/introspection/IERC165.sol\";\nimport {Initializable} from \"../../proxy/utils/Initializable.sol\";\n\n/**\n * @dev Implementation of the {IERC165} interface.\n *\n * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check\n * for the additional interface id that will be supported. For example:\n *\n * ```solidity\n * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {\n *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);\n * }\n * ```\n */\nabstract contract ERC165Upgradeable is Initializable, IERC165 {\n    function __ERC165_init() internal onlyInitializing {\n    }\n\n    function __ERC165_init_unchained() internal onlyInitializing {\n    }\n    /**\n     * @dev See {IERC165-supportsInterface}.\n     */\n    function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {\n        return interfaceId == type(IERC165).interfaceId;\n    }\n}\n"},{"file_path":"@openzeppelin/contracts/access/IAccessControl.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (access/IAccessControl.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev External interface of AccessControl declared to support ERC165 detection.\n */\ninterface IAccessControl {\n    /**\n     * @dev The `account` is missing a role.\n     */\n    error AccessControlUnauthorizedAccount(address account, bytes32 neededRole);\n\n    /**\n     * @dev The caller of a function is not the expected one.\n     *\n     * NOTE: Don't confuse with {AccessControlUnauthorizedAccount}.\n     */\n    error AccessControlBadConfirmation();\n\n    /**\n     * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`\n     *\n     * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite\n     * {RoleAdminChanged} not being emitted signaling this.\n     */\n    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);\n\n    /**\n     * @dev Emitted when `account` is granted `role`.\n     *\n     * `sender` is the account that originated the contract call, an admin role\n     * bearer except when using {AccessControl-_setupRole}.\n     */\n    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);\n\n    /**\n     * @dev Emitted when `account` is revoked `role`.\n     *\n     * `sender` is the account that originated the contract call:\n     *   - if using `revokeRole`, it is the admin role bearer\n     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)\n     */\n    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);\n\n    /**\n     * @dev Returns `true` if `account` has been granted `role`.\n     */\n    function hasRole(bytes32 role, address account) external view returns (bool);\n\n    /**\n     * @dev Returns the admin role that controls `role`. See {grantRole} and\n     * {revokeRole}.\n     *\n     * To change a role's admin, use {AccessControl-_setRoleAdmin}.\n     */\n    function getRoleAdmin(bytes32 role) external view returns (bytes32);\n\n    /**\n     * @dev Grants `role` to `account`.\n     *\n     * If `account` had not been already granted `role`, emits a {RoleGranted}\n     * event.\n     *\n     * Requirements:\n     *\n     * - the caller must have ``role``'s admin role.\n     */\n    function grantRole(bytes32 role, address account) external;\n\n    /**\n     * @dev Revokes `role` from `account`.\n     *\n     * If `account` had been granted `role`, emits a {RoleRevoked} event.\n     *\n     * Requirements:\n     *\n     * - the caller must have ``role``'s admin role.\n     */\n    function revokeRole(bytes32 role, address account) external;\n\n    /**\n     * @dev Revokes `role` from the calling account.\n     *\n     * Roles are often managed via {grantRole} and {revokeRole}: this function's\n     * purpose is to provide a mechanism for accounts to lose their privileges\n     * if they are compromised (such as when a trusted device is misplaced).\n     *\n     * If the calling account had been granted `role`, emits a {RoleRevoked}\n     * event.\n     *\n     * Requirements:\n     *\n     * - the caller must be `callerConfirmation`.\n     */\n    function renounceRole(bytes32 role, address callerConfirmation) external;\n}\n"},{"file_path":"@openzeppelin/contracts/interfaces/draft-IERC1822.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC1822.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified\n * proxy whose upgrades are fully controlled by the current implementation.\n */\ninterface IERC1822Proxiable {\n    /**\n     * @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation\n     * address.\n     *\n     * IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks\n     * bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this\n     * function revert if invoked through a proxy.\n     */\n    function proxiableUUID() external view returns (bytes32);\n}\n"},{"file_path":"@openzeppelin/contracts/interfaces/draft-IERC6093.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC6093.sol)\npragma solidity ^0.8.20;\n\n/**\n * @dev Standard ERC20 Errors\n * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC20 tokens.\n */\ninterface IERC20Errors {\n    /**\n     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     * @param balance Current balance for the interacting account.\n     * @param needed Minimum amount required to perform a transfer.\n     */\n    error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);\n\n    /**\n     * @dev Indicates a failure with the token `sender`. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     */\n    error ERC20InvalidSender(address sender);\n\n    /**\n     * @dev Indicates a failure with the token `receiver`. Used in transfers.\n     * @param receiver Address to which tokens are being transferred.\n     */\n    error ERC20InvalidReceiver(address receiver);\n\n    /**\n     * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers.\n     * @param spender Address that may be allowed to operate on tokens without being their owner.\n     * @param allowance Amount of tokens a `spender` is allowed to operate with.\n     * @param needed Minimum amount required to perform a transfer.\n     */\n    error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);\n\n    /**\n     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.\n     * @param approver Address initiating an approval operation.\n     */\n    error ERC20InvalidApprover(address approver);\n\n    /**\n     * @dev Indicates a failure with the `spender` to be approved. Used in approvals.\n     * @param spender Address that may be allowed to operate on tokens without being their owner.\n     */\n    error ERC20InvalidSpender(address spender);\n}\n\n/**\n * @dev Standard ERC721 Errors\n * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC721 tokens.\n */\ninterface IERC721Errors {\n    /**\n     * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in EIP-20.\n     * Used in balance queries.\n     * @param owner Address of the current owner of a token.\n     */\n    error ERC721InvalidOwner(address owner);\n\n    /**\n     * @dev Indicates a `tokenId` whose `owner` is the zero address.\n     * @param tokenId Identifier number of a token.\n     */\n    error ERC721NonexistentToken(uint256 tokenId);\n\n    /**\n     * @dev Indicates an error related to the ownership over a particular token. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     * @param tokenId Identifier number of a token.\n     * @param owner Address of the current owner of a token.\n     */\n    error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner);\n\n    /**\n     * @dev Indicates a failure with the token `sender`. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     */\n    error ERC721InvalidSender(address sender);\n\n    /**\n     * @dev Indicates a failure with the token `receiver`. Used in transfers.\n     * @param receiver Address to which tokens are being transferred.\n     */\n    error ERC721InvalidReceiver(address receiver);\n\n    /**\n     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.\n     * @param operator Address that may be allowed to operate on tokens without being their owner.\n     * @param tokenId Identifier number of a token.\n     */\n    error ERC721InsufficientApproval(address operator, uint256 tokenId);\n\n    /**\n     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.\n     * @param approver Address initiating an approval operation.\n     */\n    error ERC721InvalidApprover(address approver);\n\n    /**\n     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.\n     * @param operator Address that may be allowed to operate on tokens without being their owner.\n     */\n    error ERC721InvalidOperator(address operator);\n}\n\n/**\n * @dev Standard ERC1155 Errors\n * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC1155 tokens.\n */\ninterface IERC1155Errors {\n    /**\n     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     * @param balance Current balance for the interacting account.\n     * @param needed Minimum amount required to perform a transfer.\n     * @param tokenId Identifier number of a token.\n     */\n    error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId);\n\n    /**\n     * @dev Indicates a failure with the token `sender`. Used in transfers.\n     * @param sender Address whose tokens are being transferred.\n     */\n    error ERC1155InvalidSender(address sender);\n\n    /**\n     * @dev Indicates a failure with the token `receiver`. Used in transfers.\n     * @param receiver Address to which tokens are being transferred.\n     */\n    error ERC1155InvalidReceiver(address receiver);\n\n    /**\n     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.\n     * @param operator Address that may be allowed to operate on tokens without being their owner.\n     * @param owner Address of the current owner of a token.\n     */\n    error ERC1155MissingApprovalForAll(address operator, address owner);\n\n    /**\n     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.\n     * @param approver Address initiating an approval operation.\n     */\n    error ERC1155InvalidApprover(address approver);\n\n    /**\n     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.\n     * @param operator Address that may be allowed to operate on tokens without being their owner.\n     */\n    error ERC1155InvalidOperator(address operator);\n\n    /**\n     * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation.\n     * Used in batch transfers.\n     * @param idsLength Length of the array of token identifiers\n     * @param valuesLength Length of the array of token amounts\n     */\n    error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength);\n}\n"},{"file_path":"@openzeppelin/contracts/proxy/ERC1967/ERC1967Utils.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (proxy/ERC1967/ERC1967Utils.sol)\n\npragma solidity ^0.8.20;\n\nimport {IBeacon} from \"../beacon/IBeacon.sol\";\nimport {Address} from \"../../utils/Address.sol\";\nimport {StorageSlot} from \"../../utils/StorageSlot.sol\";\n\n/**\n * @dev This abstract contract provides getters and event emitting update functions for\n * https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.\n */\nlibrary ERC1967Utils {\n    // We re-declare ERC-1967 events here because they can't be used directly from IERC1967.\n    // This will be fixed in Solidity 0.8.21. At that point we should remove these events.\n    /**\n     * @dev Emitted when the implementation is upgraded.\n     */\n    event Upgraded(address indexed implementation);\n\n    /**\n     * @dev Emitted when the admin account has changed.\n     */\n    event AdminChanged(address previousAdmin, address newAdmin);\n\n    /**\n     * @dev Emitted when the beacon is changed.\n     */\n    event BeaconUpgraded(address indexed beacon);\n\n    /**\n     * @dev Storage slot with the address of the current implementation.\n     * This is the keccak-256 hash of \"eip1967.proxy.implementation\" subtracted by 1.\n     */\n    // solhint-disable-next-line private-vars-leading-underscore\n    bytes32 internal constant IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n\n    /**\n     * @dev The `implementation` of the proxy is invalid.\n     */\n    error ERC1967InvalidImplementation(address implementation);\n\n    /**\n     * @dev The `admin` of the proxy is invalid.\n     */\n    error ERC1967InvalidAdmin(address admin);\n\n    /**\n     * @dev The `beacon` of the proxy is invalid.\n     */\n    error ERC1967InvalidBeacon(address beacon);\n\n    /**\n     * @dev An upgrade function sees `msg.value > 0` that may be lost.\n     */\n    error ERC1967NonPayable();\n\n    /**\n     * @dev Returns the current implementation address.\n     */\n    function getImplementation() internal view returns (address) {\n        return StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value;\n    }\n\n    /**\n     * @dev Stores a new address in the EIP1967 implementation slot.\n     */\n    function _setImplementation(address newImplementation) private {\n        if (newImplementation.code.length == 0) {\n            revert ERC1967InvalidImplementation(newImplementation);\n        }\n        StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value = newImplementation;\n    }\n\n    /**\n     * @dev Performs implementation upgrade with additional setup call if data is nonempty.\n     * This function is payable only if the setup call is performed, otherwise `msg.value` is rejected\n     * to avoid stuck value in the contract.\n     *\n     * Emits an {IERC1967-Upgraded} event.\n     */\n    function upgradeToAndCall(address newImplementation, bytes memory data) internal {\n        _setImplementation(newImplementation);\n        emit Upgraded(newImplementation);\n\n        if (data.length > 0) {\n            Address.functionDelegateCall(newImplementation, data);\n        } else {\n            _checkNonPayable();\n        }\n    }\n\n    /**\n     * @dev Storage slot with the admin of the contract.\n     * This is the keccak-256 hash of \"eip1967.proxy.admin\" subtracted by 1.\n     */\n    // solhint-disable-next-line private-vars-leading-underscore\n    bytes32 internal constant ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;\n\n    /**\n     * @dev Returns the current admin.\n     *\n     * TIP: To get this value clients can read directly from the storage slot shown below (specified by EIP1967) using\n     * the https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.\n     * `0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103`\n     */\n    function getAdmin() internal view returns (address) {\n        return StorageSlot.getAddressSlot(ADMIN_SLOT).value;\n    }\n\n    /**\n     * @dev Stores a new address in the EIP1967 admin slot.\n     */\n    function _setAdmin(address newAdmin) private {\n        if (newAdmin == address(0)) {\n            revert ERC1967InvalidAdmin(address(0));\n        }\n        StorageSlot.getAddressSlot(ADMIN_SLOT).value = newAdmin;\n    }\n\n    /**\n     * @dev Changes the admin of the proxy.\n     *\n     * Emits an {IERC1967-AdminChanged} event.\n     */\n    function changeAdmin(address newAdmin) internal {\n        emit AdminChanged(getAdmin(), newAdmin);\n        _setAdmin(newAdmin);\n    }\n\n    /**\n     * @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.\n     * This is the keccak-256 hash of \"eip1967.proxy.beacon\" subtracted by 1.\n     */\n    // solhint-disable-next-line private-vars-leading-underscore\n    bytes32 internal constant BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;\n\n    /**\n     * @dev Returns the current beacon.\n     */\n    function getBeacon() internal view returns (address) {\n        return StorageSlot.getAddressSlot(BEACON_SLOT).value;\n    }\n\n    /**\n     * @dev Stores a new beacon in the EIP1967 beacon slot.\n     */\n    function _setBeacon(address newBeacon) private {\n        if (newBeacon.code.length == 0) {\n            revert ERC1967InvalidBeacon(newBeacon);\n        }\n\n        StorageSlot.getAddressSlot(BEACON_SLOT).value = newBeacon;\n\n        address beaconImplementation = IBeacon(newBeacon).implementation();\n        if (beaconImplementation.code.length == 0) {\n            revert ERC1967InvalidImplementation(beaconImplementation);\n        }\n    }\n\n    /**\n     * @dev Change the beacon and trigger a setup call if data is nonempty.\n     * This function is payable only if the setup call is performed, otherwise `msg.value` is rejected\n     * to avoid stuck value in the contract.\n     *\n     * Emits an {IERC1967-BeaconUpgraded} event.\n     *\n     * CAUTION: Invoking this function has no effect on an instance of {BeaconProxy} since v5, since\n     * it uses an immutable beacon without looking at the value of the ERC-1967 beacon slot for\n     * efficiency.\n     */\n    function upgradeBeaconToAndCall(address newBeacon, bytes memory data) internal {\n        _setBeacon(newBeacon);\n        emit BeaconUpgraded(newBeacon);\n\n        if (data.length > 0) {\n            Address.functionDelegateCall(IBeacon(newBeacon).implementation(), data);\n        } else {\n            _checkNonPayable();\n        }\n    }\n\n    /**\n     * @dev Reverts if `msg.value` is not zero. It can be used to avoid `msg.value` stuck in the contract\n     * if an upgrade doesn't perform an initialization call.\n     */\n    function _checkNonPayable() private {\n        if (msg.value > 0) {\n            revert ERC1967NonPayable();\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts/proxy/beacon/IBeacon.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (proxy/beacon/IBeacon.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev This is the interface that {BeaconProxy} expects of its beacon.\n */\ninterface IBeacon {\n    /**\n     * @dev Must return an address that can be used as a delegate call target.\n     *\n     * {UpgradeableBeacon} will check that this address is a contract.\n     */\n    function implementation() external view returns (address);\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC20/IERC20.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP.\n */\ninterface IERC20 {\n    /**\n     * @dev Emitted when `value` tokens are moved from one account (`from`) to\n     * another (`to`).\n     *\n     * Note that `value` may be zero.\n     */\n    event Transfer(address indexed from, address indexed to, uint256 value);\n\n    /**\n     * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n     * a call to {approve}. `value` is the new allowance.\n     */\n    event Approval(address indexed owner, address indexed spender, uint256 value);\n\n    /**\n     * @dev Returns the value of tokens in existence.\n     */\n    function totalSupply() external view returns (uint256);\n\n    /**\n     * @dev Returns the value of tokens owned by `account`.\n     */\n    function balanceOf(address account) external view returns (uint256);\n\n    /**\n     * @dev Moves a `value` amount of tokens from the caller's account to `to`.\n     *\n     * Returns a boolean value indicating whether the operation succeeded.\n     *\n     * Emits a {Transfer} event.\n     */\n    function transfer(address to, uint256 value) external returns (bool);\n\n    /**\n     * @dev Returns the remaining number of tokens that `spender` will be\n     * allowed to spend on behalf of `owner` through {transferFrom}. This is\n     * zero by default.\n     *\n     * This value changes when {approve} or {transferFrom} are called.\n     */\n    function allowance(address owner, address spender) external view returns (uint256);\n\n    /**\n     * @dev Sets a `value` amount of tokens as the allowance of `spender` over the\n     * caller's tokens.\n     *\n     * Returns a boolean value indicating whether the operation succeeded.\n     *\n     * IMPORTANT: Beware that changing an allowance with this method brings the risk\n     * that someone may use both the old and the new allowance by unfortunate\n     * transaction ordering. One possible solution to mitigate this race\n     * condition is to first reduce the spender's allowance to 0 and set the\n     * desired value afterwards:\n     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n     *\n     * Emits an {Approval} event.\n     */\n    function approve(address spender, uint256 value) external returns (bool);\n\n    /**\n     * @dev Moves a `value` amount of tokens from `from` to `to` using the\n     * allowance mechanism. `value` is then deducted from the caller's\n     * allowance.\n     *\n     * Returns a boolean value indicating whether the operation succeeded.\n     *\n     * Emits a {Transfer} event.\n     */\n    function transferFrom(address from, address to, uint256 value) external returns (bool);\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Metadata.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC20} from \"../IERC20.sol\";\n\n/**\n * @dev Interface for the optional metadata functions from the ERC20 standard.\n */\ninterface IERC20Metadata is IERC20 {\n    /**\n     * @dev Returns the name of the token.\n     */\n    function name() external view returns (string memory);\n\n    /**\n     * @dev Returns the symbol of the token.\n     */\n    function symbol() external view returns (string memory);\n\n    /**\n     * @dev Returns the decimals places of the token.\n     */\n    function decimals() external view returns (uint8);\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC20/extensions/IERC20Permit.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/extensions/IERC20Permit.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in\n * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].\n *\n * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by\n * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't\n * need to send a transaction, and thus is not required to hold Ether at all.\n *\n * ==== Security Considerations\n *\n * There are two important considerations concerning the use of `permit`. The first is that a valid permit signature\n * expresses an allowance, and it should not be assumed to convey additional meaning. In particular, it should not be\n * considered as an intention to spend the allowance in any specific way. The second is that because permits have\n * built-in replay protection and can be submitted by anyone, they can be frontrun. A protocol that uses permits should\n * take this into consideration and allow a `permit` call to fail. Combining these two aspects, a pattern that may be\n * generally recommended is:\n *\n * ```solidity\n * function doThingWithPermit(..., uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) public {\n *     try token.permit(msg.sender, address(this), value, deadline, v, r, s) {} catch {}\n *     doThing(..., value);\n * }\n *\n * function doThing(..., uint256 value) public {\n *     token.safeTransferFrom(msg.sender, address(this), value);\n *     ...\n * }\n * ```\n *\n * Observe that: 1) `msg.sender` is used as the owner, leaving no ambiguity as to the signer intent, and 2) the use of\n * `try/catch` allows the permit to fail and makes the code tolerant to frontrunning. (See also\n * {SafeERC20-safeTransferFrom}).\n *\n * Additionally, note that smart contract wallets (such as Argent or Safe) are not able to produce permit signatures, so\n * contracts should have entry points that don't rely on permit.\n */\ninterface IERC20Permit {\n    /**\n     * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,\n     * given ``owner``'s signed approval.\n     *\n     * IMPORTANT: The same issues {IERC20-approve} has related to transaction\n     * ordering also apply here.\n     *\n     * Emits an {Approval} event.\n     *\n     * Requirements:\n     *\n     * - `spender` cannot be the zero address.\n     * - `deadline` must be a timestamp in the future.\n     * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`\n     * over the EIP712-formatted function arguments.\n     * - the signature must use ``owner``'s current nonce (see {nonces}).\n     *\n     * For more information on the signature format, see the\n     * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP\n     * section].\n     *\n     * CAUTION: See Security Considerations above.\n     */\n    function permit(\n        address owner,\n        address spender,\n        uint256 value,\n        uint256 deadline,\n        uint8 v,\n        bytes32 r,\n        bytes32 s\n    ) external;\n\n    /**\n     * @dev Returns the current nonce for `owner`. This value must be\n     * included whenever a signature is generated for {permit}.\n     *\n     * Every successful call to {permit} increases ``owner``'s nonce by one. This\n     * prevents a signature from being used multiple times.\n     */\n    function nonces(address owner) external view returns (uint256);\n\n    /**\n     * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.\n     */\n    // solhint-disable-next-line func-name-mixedcase\n    function DOMAIN_SEPARATOR() external view returns (bytes32);\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/utils/SafeERC20.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC20} from \"../IERC20.sol\";\nimport {IERC20Permit} from \"../extensions/IERC20Permit.sol\";\nimport {Address} from \"../../../utils/Address.sol\";\n\n/**\n * @title SafeERC20\n * @dev Wrappers around ERC20 operations that throw on failure (when the token\n * contract returns false). Tokens that return no value (and instead revert or\n * throw on failure) are also supported, non-reverting calls are assumed to be\n * successful.\n * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,\n * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.\n */\nlibrary SafeERC20 {\n    using Address for address;\n\n    /**\n     * @dev An operation with an ERC20 token failed.\n     */\n    error SafeERC20FailedOperation(address token);\n\n    /**\n     * @dev Indicates a failed `decreaseAllowance` request.\n     */\n    error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease);\n\n    /**\n     * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value,\n     * non-reverting calls are assumed to be successful.\n     */\n    function safeTransfer(IERC20 token, address to, uint256 value) internal {\n        _callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value)));\n    }\n\n    /**\n     * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the\n     * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful.\n     */\n    function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {\n        _callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value)));\n    }\n\n    /**\n     * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value,\n     * non-reverting calls are assumed to be successful.\n     */\n    function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {\n        uint256 oldAllowance = token.allowance(address(this), spender);\n        forceApprove(token, spender, oldAllowance + value);\n    }\n\n    /**\n     * @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no\n     * value, non-reverting calls are assumed to be successful.\n     */\n    function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal {\n        unchecked {\n            uint256 currentAllowance = token.allowance(address(this), spender);\n            if (currentAllowance < requestedDecrease) {\n                revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease);\n            }\n            forceApprove(token, spender, currentAllowance - requestedDecrease);\n        }\n    }\n\n    /**\n     * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value,\n     * non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval\n     * to be set to zero before setting it to a non-zero value, such as USDT.\n     */\n    function forceApprove(IERC20 token, address spender, uint256 value) internal {\n        bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value));\n\n        if (!_callOptionalReturnBool(token, approvalCall)) {\n            _callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0)));\n            _callOptionalReturn(token, approvalCall);\n        }\n    }\n\n    /**\n     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\n     * on the return value: the return value is optional (but if data is returned, it must not be false).\n     * @param token The token targeted by the call.\n     * @param data The call data (encoded using abi.encode or one of its variants).\n     */\n    function _callOptionalReturn(IERC20 token, bytes memory data) private {\n        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since\n        // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that\n        // the target address contains contract code and also asserts for success in the low-level call.\n\n        bytes memory returndata = address(token).functionCall(data);\n        if (returndata.length != 0 && !abi.decode(returndata, (bool))) {\n            revert SafeERC20FailedOperation(address(token));\n        }\n    }\n\n    /**\n     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\n     * on the return value: the return value is optional (but if data is returned, it must not be false).\n     * @param token The token targeted by the call.\n     * @param data The call data (encoded using abi.encode or one of its variants).\n     *\n     * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead.\n     */\n    function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) {\n        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since\n        // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false\n        // and not revert is the subcall reverts.\n\n        (bool success, bytes memory returndata) = address(token).call(data);\n        return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0;\n    }\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC721/IERC721.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/IERC721.sol)\n\npragma solidity ^0.8.20;\n\nimport {IERC165} from \"../../utils/introspection/IERC165.sol\";\n\n/**\n * @dev Required interface of an ERC721 compliant contract.\n */\ninterface IERC721 is IERC165 {\n    /**\n     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.\n     */\n    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);\n\n    /**\n     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.\n     */\n    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);\n\n    /**\n     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.\n     */\n    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);\n\n    /**\n     * @dev Returns the number of tokens in ``owner``'s account.\n     */\n    function balanceOf(address owner) external view returns (uint256 balance);\n\n    /**\n     * @dev Returns the owner of the `tokenId` token.\n     *\n     * Requirements:\n     *\n     * - `tokenId` must exist.\n     */\n    function ownerOf(uint256 tokenId) external view returns (address owner);\n\n    /**\n     * @dev Safely transfers `tokenId` token from `from` to `to`.\n     *\n     * Requirements:\n     *\n     * - `from` cannot be the zero address.\n     * - `to` cannot be the zero address.\n     * - `tokenId` token must exist and be owned by `from`.\n     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.\n     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon\n     *   a safe transfer.\n     *\n     * Emits a {Transfer} event.\n     */\n    function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external;\n\n    /**\n     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients\n     * are aware of the ERC721 protocol to prevent tokens from being forever locked.\n     *\n     * Requirements:\n     *\n     * - `from` cannot be the zero address.\n     * - `to` cannot be the zero address.\n     * - `tokenId` token must exist and be owned by `from`.\n     * - If the caller is not `from`, it must have been allowed to move this token by either {approve} or\n     *   {setApprovalForAll}.\n     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon\n     *   a safe transfer.\n     *\n     * Emits a {Transfer} event.\n     */\n    function safeTransferFrom(address from, address to, uint256 tokenId) external;\n\n    /**\n     * @dev Transfers `tokenId` token from `from` to `to`.\n     *\n     * WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721\n     * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must\n     * understand this adds an external call which potentially creates a reentrancy vulnerability.\n     *\n     * Requirements:\n     *\n     * - `from` cannot be the zero address.\n     * - `to` cannot be the zero address.\n     * - `tokenId` token must be owned by `from`.\n     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.\n     *\n     * Emits a {Transfer} event.\n     */\n    function transferFrom(address from, address to, uint256 tokenId) external;\n\n    /**\n     * @dev Gives permission to `to` to transfer `tokenId` token to another account.\n     * The approval is cleared when the token is transferred.\n     *\n     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.\n     *\n     * Requirements:\n     *\n     * - The caller must own the token or be an approved operator.\n     * - `tokenId` must exist.\n     *\n     * Emits an {Approval} event.\n     */\n    function approve(address to, uint256 tokenId) external;\n\n    /**\n     * @dev Approve or remove `operator` as an operator for the caller.\n     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.\n     *\n     * Requirements:\n     *\n     * - The `operator` cannot be the address zero.\n     *\n     * Emits an {ApprovalForAll} event.\n     */\n    function setApprovalForAll(address operator, bool approved) external;\n\n    /**\n     * @dev Returns the account approved for `tokenId` token.\n     *\n     * Requirements:\n     *\n     * - `tokenId` must exist.\n     */\n    function getApproved(uint256 tokenId) external view returns (address operator);\n\n    /**\n     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.\n     *\n     * See {setApprovalForAll}\n     */\n    function isApprovedForAll(address owner, address operator) external view returns (bool);\n}\n"},{"file_path":"@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/IERC721Receiver.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @title ERC721 token receiver interface\n * @dev Interface for any contract that wants to support safeTransfers\n * from ERC721 asset contracts.\n */\ninterface IERC721Receiver {\n    /**\n     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}\n     * by `operator` from `from`, this function is called.\n     *\n     * It must return its Solidity selector to confirm the token transfer.\n     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be\n     * reverted.\n     *\n     * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.\n     */\n    function onERC721Received(\n        address operator,\n        address from,\n        uint256 tokenId,\n        bytes calldata data\n    ) external returns (bytes4);\n}\n"},{"file_path":"@openzeppelin/contracts/utils/Address.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev Collection of functions related to the address type\n */\nlibrary Address {\n    /**\n     * @dev The ETH balance of the account is not enough to perform the operation.\n     */\n    error AddressInsufficientBalance(address account);\n\n    /**\n     * @dev There's no code at `target` (it is not a contract).\n     */\n    error AddressEmptyCode(address target);\n\n    /**\n     * @dev A call to an address target failed. The target may have reverted.\n     */\n    error FailedInnerCall();\n\n    /**\n     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to\n     * `recipient`, forwarding all available gas and reverting on errors.\n     *\n     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\n     * of certain opcodes, possibly making contracts go over the 2300 gas limit\n     * imposed by `transfer`, making them unable to receive funds via\n     * `transfer`. {sendValue} removes this limitation.\n     *\n     * https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n     *\n     * IMPORTANT: because control is transferred to `recipient`, care must be\n     * taken to not create reentrancy vulnerabilities. Consider using\n     * {ReentrancyGuard} or the\n     * https://solidity.readthedocs.io/en/v0.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\n     */\n    function sendValue(address payable recipient, uint256 amount) internal {\n        if (address(this).balance < amount) {\n            revert AddressInsufficientBalance(address(this));\n        }\n\n        (bool success, ) = recipient.call{value: amount}(\"\");\n        if (!success) {\n            revert FailedInnerCall();\n        }\n    }\n\n    /**\n     * @dev Performs a Solidity function call using a low level `call`. A\n     * plain `call` is an unsafe replacement for a function call: use this\n     * function instead.\n     *\n     * If `target` reverts with a revert reason or custom error, it is bubbled\n     * up by this function (like regular Solidity function calls). However, if\n     * the call reverted with no returned reason, this function reverts with a\n     * {FailedInnerCall} error.\n     *\n     * Returns the raw returned data. To convert to the expected return value,\n     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n     *\n     * Requirements:\n     *\n     * - `target` must be a contract.\n     * - calling `target` with `data` must not revert.\n     */\n    function functionCall(address target, bytes memory data) internal returns (bytes memory) {\n        return functionCallWithValue(target, data, 0);\n    }\n\n    /**\n     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n     * but also transferring `value` wei to `target`.\n     *\n     * Requirements:\n     *\n     * - the calling contract must have an ETH balance of at least `value`.\n     * - the called Solidity function must be `payable`.\n     */\n    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {\n        if (address(this).balance < value) {\n            revert AddressInsufficientBalance(address(this));\n        }\n        (bool success, bytes memory returndata) = target.call{value: value}(data);\n        return verifyCallResultFromTarget(target, success, returndata);\n    }\n\n    /**\n     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n     * but performing a static call.\n     */\n    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\n        (bool success, bytes memory returndata) = target.staticcall(data);\n        return verifyCallResultFromTarget(target, success, returndata);\n    }\n\n    /**\n     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n     * but performing a delegate call.\n     */\n    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {\n        (bool success, bytes memory returndata) = target.delegatecall(data);\n        return verifyCallResultFromTarget(target, success, returndata);\n    }\n\n    /**\n     * @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target\n     * was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an\n     * unsuccessful call.\n     */\n    function verifyCallResultFromTarget(\n        address target,\n        bool success,\n        bytes memory returndata\n    ) internal view returns (bytes memory) {\n        if (!success) {\n            _revert(returndata);\n        } else {\n            // only check if target is a contract if the call was successful and the return data is empty\n            // otherwise we already know that it was a contract\n            if (returndata.length == 0 && target.code.length == 0) {\n                revert AddressEmptyCode(target);\n            }\n            return returndata;\n        }\n    }\n\n    /**\n     * @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the\n     * revert reason or with a default {FailedInnerCall} error.\n     */\n    function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) {\n        if (!success) {\n            _revert(returndata);\n        } else {\n            return returndata;\n        }\n    }\n\n    /**\n     * @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}.\n     */\n    function _revert(bytes memory returndata) private pure {\n        // Look for revert reason and bubble it up if present\n        if (returndata.length > 0) {\n            // The easiest way to bubble the revert reason is using memory via assembly\n            /// @solidity memory-safe-assembly\n            assembly {\n                let returndata_size := mload(returndata)\n                revert(add(32, returndata), returndata_size)\n            }\n        } else {\n            revert FailedInnerCall();\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts/utils/StorageSlot.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/StorageSlot.sol)\n// This file was procedurally generated from scripts/generate/templates/StorageSlot.js.\n\npragma solidity ^0.8.20;\n\n/**\n * @dev Library for reading and writing primitive types to specific storage slots.\n *\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\n * This library helps with reading and writing to such slots without the need for inline assembly.\n *\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\n *\n * Example usage to set ERC1967 implementation slot:\n * ```solidity\n * contract ERC1967 {\n *     bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n *\n *     function _getImplementation() internal view returns (address) {\n *         return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\n *     }\n *\n *     function _setImplementation(address newImplementation) internal {\n *         require(newImplementation.code.length > 0);\n *         StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\n *     }\n * }\n * ```\n */\nlibrary StorageSlot {\n    struct AddressSlot {\n        address value;\n    }\n\n    struct BooleanSlot {\n        bool value;\n    }\n\n    struct Bytes32Slot {\n        bytes32 value;\n    }\n\n    struct Uint256Slot {\n        uint256 value;\n    }\n\n    struct StringSlot {\n        string value;\n    }\n\n    struct BytesSlot {\n        bytes value;\n    }\n\n    /**\n     * @dev Returns an `AddressSlot` with member `value` located at `slot`.\n     */\n    function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\n     */\n    function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\n     */\n    function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\n     */\n    function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `StringSlot` with member `value` located at `slot`.\n     */\n    function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `StringSlot` representation of the string storage pointer `store`.\n     */\n    function getStringSlot(string storage store) internal pure returns (StringSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := store.slot\n        }\n    }\n\n    /**\n     * @dev Returns an `BytesSlot` with member `value` located at `slot`.\n     */\n    function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := slot\n        }\n    }\n\n    /**\n     * @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`.\n     */\n    function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) {\n        /// @solidity memory-safe-assembly\n        assembly {\n            r.slot := store.slot\n        }\n    }\n}\n"},{"file_path":"@openzeppelin/contracts/utils/introspection/IERC165.sol","source_code":"// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol)\n\npragma solidity ^0.8.20;\n\n/**\n * @dev Interface of the ERC165 standard, as defined in the\n * https://eips.ethereum.org/EIPS/eip-165[EIP].\n *\n * Implementers can declare support of contract interfaces, which can then be\n * queried by others ({ERC165Checker}).\n *\n * For an implementation, see {ERC165}.\n */\ninterface IERC165 {\n    /**\n     * @dev Returns true if this contract implements the interface defined by\n     * `interfaceId`. See the corresponding\n     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]\n     * to learn more about how these ids are created.\n     *\n     * This function call must use less than 30 000 gas.\n     */\n    function supportsInterface(bytes4 interfaceId) external view returns (bool);\n}\n"},{"file_path":"contracts/DocumentHashRegistry.sol","source_code":"// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\nimport '@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol';\n\ncontract DocumentHashRegistry is Initializable, AccessControlUpgradeable {\n  // Events\n  event DocumentHashAdded(bytes32 indexed key, bytes32 value);\n  event DocumentHashUpdated(bytes32 indexed key, bytes32 oldValue, bytes32 newValue);\n  event DocumentHashRemoved(bytes32 indexed key, bytes32 value);\n\n  // Custom errors\n  error EmptyKey();\n  error EmptyValue();\n  error KeysLengthMismatch();\n\n  /**\n   * @dev Mapping from file name (hashed) to document hash. An empty document hash means the document does not exist.\n   */\n  mapping(bytes32 => bytes32) public documentHashes;\n\n  /**\n   * @dev Mapping to track whether a document hash is registered. Used to check if a document hash exists in the dictionary.\n   */\n  mapping(bytes32 => bool) public registeredHashes;\n\n  /**\n   * @dev Initializes the contract by setting up the AccessControl and granting the default admin role to the deployer.\n   */\n  function __DocumentHashRegistry_init() public virtual initializer {\n    __AccessControl_init();\n    __DocumentHashRegistry_init_unchained();\n  }\n\n  function __DocumentHashRegistry_init_unchained() internal onlyInitializing {\n    _grantRole(DEFAULT_ADMIN_ROLE, msg.sender);\n  }\n\n  /**\n   * @dev Updates the document hashes in the registry. If a key already exists, it will be overwritten.\n   *      An empty document hash represents that the document does not exist.\n   * @param keys Array of the document names (hashed).\n   * @param values Array of the document hashes.\n   */\n  function updateDocumentHashes(bytes32[] memory keys, bytes32[] memory values) public onlyRole(DEFAULT_ADMIN_ROLE) {\n    if (keys.length != values.length) {\n      revert KeysLengthMismatch();\n    }\n\n    // Check for empty strings in keys and values\n    for (uint i = 0; i < keys.length; i++) {\n      bytes32 key = keys[i];\n      if (key == bytes32(0)) {\n        revert EmptyKey();\n      }\n      bytes32 value = values[i];\n      bytes32 existingHash = documentHashes[key];\n\n      // Adding a new document (most common case)\n      if (existingHash == bytes32(0) && value != bytes32(0)) {\n        documentHashes[key] = value;\n        registeredHashes[value] = true;\n        emit DocumentHashAdded(key, value);\n\n        // Updating an existing document\n      } else if (existingHash != bytes32(0) && value != bytes32(0) && existingHash != value) {\n        documentHashes[key] = value;\n        registeredHashes[existingHash] = false;\n        registeredHashes[value] = true;\n        emit DocumentHashUpdated(key, existingHash, value);\n\n        // Removing a document\n      } else if (value == bytes32(0) && existingHash != bytes32(0)) {\n        documentHashes[key] = bytes32(0);\n        registeredHashes[existingHash] = false;\n        emit DocumentHashRemoved(key, existingHash);\n      }\n    }\n  }\n\n  /**\n   * @dev Returns the document hash associated with the given key.\n   * @param key The hashed file name.\n   * @return The document hash associated with the key.\n   */\n  function getDocumentHash(bytes32 key) public view returns (bytes32) {\n    return documentHashes[key];\n  }\n\n  /**\n   * @dev Checks if a document hash exists in the dictionary as a value.\n   * @param documentHash The document hash to check.\n   * @return True if the document hash is registered, false otherwise.\n   */\n  function isHashRegistered(bytes32 documentHash) public view virtual returns (bool) {\n    return registeredHashes[documentHash];\n  }\n}\n"},{"file_path":"contracts/ExtendedERC20.sol","source_code":"// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\nimport '@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.sol';\nimport '@openzeppelin/contracts-upgradeable/token/ERC20/extensions/ERC20PausableUpgradeable.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol';\nimport './DocumentHashRegistry.sol';\nimport './utils/ExtendedAccessControl.sol';\n\ncontract ExtendedERC20 is\n  Initializable,\n  ERC20Upgradeable,\n  ERC20PausableUpgradeable,\n  ExtendedAccessControl,\n  DocumentHashRegistry,\n  UUPSUpgradeable\n{\n  bytes32 public constant UPGRADER_ROLE = keccak256('UPGRADER_ROLE');\n  bytes32 public constant PAUSER_ROLE = keccak256('PAUSER_ROLE');\n  bytes32 public constant MINTER_ROLE = keccak256('MINTER_ROLE');\n  bytes32 public constant WIPER_ROLE = keccak256('WIPER_ROLE');\n  bytes32 public constant KYC_ROLE = keccak256('KYC_ROLE');\n  bytes32 public constant BLACKLISTED_ROLE = keccak256('BLACKLISTED_ROLE');\n  bool private _isKYCable;\n  bool private _isBlacklistable;\n  uint8 private _decimals;\n\n  event KYCableStatusChanged(bool enabled);\n  event BlacklistableStatusChanged(bool enabled);\n\n  error KYCableStatusUnchanged(bool currentStatus);\n  error BlacklistableStatusUnchanged(bool currentStatus);\n  error BlacklistedError(address account);\n  error KYCNotApprovedError(address account);\n\n  /// @custom:oz-upgrades-unsafe-allow constructor\n  constructor() {\n    _disableInitializers();\n  }\n\n  function initialize(\n    string memory name_,\n    string memory symbol_,\n    uint256 premintAmount,\n    bool isKYCable_,\n    bool isBlacklistable_,\n    uint8 decimals_\n  ) public virtual initializer {\n    __ERC20_init(name_, symbol_);\n    __ERC20Pausable_init();\n    __DocumentHashRegistry_init();\n    __UUPSUpgradeable_init();\n\n    _grantRole(DEFAULT_ADMIN_ROLE, msg.sender);\n    _grantRole(PAUSER_ROLE, msg.sender);\n    _grantRole(MINTER_ROLE, msg.sender);\n    _grantRole(WIPER_ROLE, msg.sender);\n    _grantRole(KYC_ROLE, msg.sender);\n    _grantRole(UPGRADER_ROLE, msg.sender);\n\n    if (premintAmount > 0) {\n      _mint(msg.sender, premintAmount);\n    }\n    _isKYCable = isKYCable_;\n    _isBlacklistable = isBlacklistable_;\n    _decimals = decimals_;\n  }\n\n  function decimals() public view virtual override returns (uint8) {\n    return _decimals;\n  }\n\n  function isKYCable() public view virtual returns (bool) {\n    return _isKYCable;\n  }\n\n  function isBlacklistable() public view virtual returns (bool) {\n    return _isBlacklistable;\n  }\n\n  function setKYCableStatus(bool enabled) public onlyRole(DEFAULT_ADMIN_ROLE) {\n    if (_isKYCable == enabled) {\n      revert KYCableStatusUnchanged(enabled);\n    }\n    _isKYCable = enabled;\n    emit KYCableStatusChanged(enabled);\n  }\n\n  function setBlacklistableStatus(bool enabled) public onlyRole(DEFAULT_ADMIN_ROLE) {\n    if (_isBlacklistable == enabled) {\n      revert BlacklistableStatusUnchanged(enabled);\n    }\n    _isBlacklistable = enabled;\n    emit BlacklistableStatusChanged(enabled);\n  }\n\n  function pause() public onlyRole(PAUSER_ROLE) {\n    _pause();\n  }\n\n  function unpause() public onlyRole(PAUSER_ROLE) {\n    _unpause();\n  }\n\n  function transfer(address to, uint256 amount) public virtual override returns (bool) {\n    _canTransfer(_msgSender(), to);\n    return super.transfer(to, amount);\n  }\n\n  function transferFrom(address from, address to, uint256 amount) public virtual override returns (bool) {\n    _canTransfer(from, to);\n    return super.transferFrom(from, to, amount);\n  }\n\n  /**\n   * @dev Destroys `amount` tokens from the caller.\n   *\n   * See {ERC20-_burn}.\n   */\n  function burn(uint256 amount) public virtual onlyRole(DEFAULT_ADMIN_ROLE) {\n    _burn(_msgSender(), amount);\n  }\n\n  function mint(address to, uint256 amount) public onlyRole(MINTER_ROLE) {\n    if (_isBlacklistable && hasRole(BLACKLISTED_ROLE, to)) {\n      revert BlacklistedError(to);\n    }\n\n    if (_isKYCable && !hasRole(KYC_ROLE, to)) {\n      revert KYCNotApprovedError(to);\n    }\n\n    _mint(to, amount);\n  }\n\n  /**\n   * @dev Wipes the provided amount of tokens from the specified account.\n   * This transaction does not delete tokens from the treasury account.\n   * Wiping an account's tokens burns the tokens and decreases the total supply.\n   *\n   * See {ERC20-_burn}.\n   */\n  function wipe(address from, uint256 amount) public onlyRole(WIPER_ROLE) {\n    _burn(from, amount);\n  }\n\n  /**\n   * @dev Changes the owner of the contract.\n   * This function revokes all roles from the current owner and grants them to the new owner.\n   * The function can only be called by an account with the DEFAULT_ADMIN_ROLE.\n   *\n   * @param newOwnerAddress The address of the new owner to whom all roles will be granted.\n   */\n  function changeOwner(address newOwnerAddress) public virtual onlyRole(DEFAULT_ADMIN_ROLE) {\n    _revokeRole(DEFAULT_ADMIN_ROLE, _msgSender());\n    _revokeRole(PAUSER_ROLE, _msgSender());\n    _revokeRole(MINTER_ROLE, _msgSender());\n    _revokeRole(WIPER_ROLE, _msgSender());\n    _revokeRole(KYC_ROLE, _msgSender());\n    _grantRole(DEFAULT_ADMIN_ROLE, newOwnerAddress);\n    _grantRole(PAUSER_ROLE, newOwnerAddress);\n    _grantRole(MINTER_ROLE, newOwnerAddress);\n    _grantRole(WIPER_ROLE, newOwnerAddress);\n    _grantRole(KYC_ROLE, newOwnerAddress);\n  }\n\n  function _checkBlacklistStatus(address account) internal view {\n    if (_isBlacklistable && hasRole(BLACKLISTED_ROLE, account)) {\n      revert BlacklistedError(account);\n    }\n  }\n\n  function _checkKYCStatus(address account) internal view {\n    if (_isKYCable && !hasRole(KYC_ROLE, account)) {\n      revert KYCNotApprovedError(account);\n    }\n  }\n\n  function _canTransfer(address from, address to) internal view {\n    _checkBlacklistStatus(from);\n    _checkBlacklistStatus(to);\n    _checkKYCStatus(from);\n    _checkKYCStatus(to);\n  }\n\n  // The following functions are overrides required by Solidity.\n\n  function _update(\n    address from,\n    address to,\n    uint256 value\n  ) internal override(ERC20Upgradeable, ERC20PausableUpgradeable) {\n    super._update(from, to, value);\n  }\n\n  // UUPS upgrade authorization\n  function _authorizeUpgrade(address newImplementation) internal virtual override onlyRole(UPGRADER_ROLE) {}\n}\n"},{"file_path":"contracts/utils/ExtendedAccessControl.sol","source_code":"// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\nimport '@openzeppelin/contracts-upgradeable/access/AccessControlUpgradeable.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol';\n\nabstract contract ExtendedAccessControl is Initializable, AccessControlUpgradeable {\n  // Batch grant a role to multiple accounts\n  function batchGrantRole(bytes32 role, address[] calldata accounts) public onlyRole(getRoleAdmin(role)) {\n    for (uint256 i = 0; i < accounts.length; ++i) {\n      _grantRole(role, accounts[i]);\n    }\n  }\n\n  // Batch revoke a role from multiple accounts\n  function batchRevokeRole(bytes32 role, address[] calldata accounts) public onlyRole(getRoleAdmin(role)) {\n    for (uint256 i = 0; i < accounts.length; ++i) {\n      _revokeRole(role, accounts[i]);\n    }\n  }\n}\n"}],"is_verified_via_sourcify":false,"can_be_visualized_via_sol2uml":true,"evm_version":"paris","language":"solidity","is_verified_via_eth_bytecode_db":true,"is_fully_verified":true,"license_type":"none","is_blueprint":false,"name":"ERC20PoolToken","creation_bytecode":"0x60a0604052306080523480156200001557600080fd5b506200002062000026565b620000da565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff1615620000775760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b0390811614620000d75780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b608051612ff06200010460003960008181611ab101528181611ada0152611c3f0152612ff06000f3fe6080604052600436106102e45760003560e01c80636f39feec11610190578063b319031c116100dc578063e63ab1e911610095578063f72c0d8b1161006f578063f72c0d8b1461097c578063f9c8dec3146109b0578063fc079f12146109d2578063fe06a994146109f257600080fd5b8063e63ab1e914610915578063e785b64a14610937578063f05b24f81461094c57600080fd5b8063b319031c1461085c578063d539139314610879578063d547741f1461089b578063db01f21d146108bb578063dd62ed3e146108dd578063e29f5bff146108fd57600080fd5b806395d89b4111610149578063a5a515fa11610123578063a5a515fa146107cb578063a6f9dae1146107eb578063a9059cbb1461080b578063ad3cb1cc1461082b57600080fd5b806395d89b41146107815780639db5dbe414610796578063a217fddf146107b657600080fd5b80636f39feec1461069c57806370a08231146106bc57806377860cdd146106ff578063806d8a8f1461071f5780638456cb591461074c57806391d148541461076157600080fd5b8063313ce5671161024f57806346b5cb5911610208578063513b5814116101e2578063513b5814146105fe57806352d1902d1461062e5780635c975abb1461064357806362b199c51461066857600080fd5b806346b5cb59146105ab5780634cfd24c3146105cb5780634f1ef286146105eb57600080fd5b8063313ce567146104eb57806336568abe146105165780633f4ba83a1461053657806340c10f191461054b578063410937a51461056b57806342966c681461058b57600080fd5b80631aca6376116102a15780631aca63761461040557806323b872dd14610425578063248a9ca31461044557806326aa101f146104655780632f2ff15d1461049e57806330e3952a146104be57600080fd5b806301ffc9a7146102e957806306fdde031461031e578063095ea7b31461034057806309824a8014610360578063150b7a021461038257806318160ddd146103c7575b600080fd5b3480156102f557600080fd5b50610309610304366004612738565b610a12565b60405190151581526020015b60405180910390f35b34801561032a57600080fd5b50610333610a49565b6040516103159190612786565b34801561034c57600080fd5b5061030961035b3660046127d5565b610b0c565b34801561036c57600080fd5b5061038061037b3660046127ff565b610b24565b005b34801561038e57600080fd5b506103ae61039d36600461281a565b630a85bd0160e11b95945050505050565b6040516001600160e01b03199091168152602001610315565b3480156103d357600080fd5b507f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace02545b604051908152602001610315565b34801561041157600080fd5b506103806104203660046128b4565b610bdd565b34801561043157600080fd5b506103096104403660046128b4565b610cd8565b34801561045157600080fd5b506103f76104603660046128f0565b610cf9565b34801561047157600080fd5b506103096104803660046127ff565b6001600160a01b031660009081526003602052604090205460ff1690565b3480156104aa57600080fd5b506103806104b9366004612909565b610d1b565b3480156104ca57600080fd5b506103f76104d93660046128f0565b60009081526020819052604090205490565b3480156104f757600080fd5b5060025462010000900460ff1660405160ff9091168152602001610315565b34801561052257600080fd5b50610380610531366004612909565b610d37565b34801561054257600080fd5b50610380610d6f565b34801561055757600080fd5b506103806105663660046127d5565b610d92565b34801561057757600080fd5b506103806105863660046127d5565b610e6e565b34801561059757600080fd5b506103806105a63660046128f0565b610e90565b3480156105b757600080fd5b506103806105c6366004612935565b610ea9565b3480156105d757600080fd5b506103806105e63660046129c1565b610f0e565b6103806105f9366004612a7b565b610fa5565b34801561060a57600080fd5b506103096106193660046128f0565b60016020526000908152604090205460ff1681565b34801561063a57600080fd5b506103f7610fc0565b34801561064f57600080fd5b50600080516020612f7b8339815191525460ff16610309565b34801561067457600080fd5b506103f77f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed81565b3480156106a857600080fd5b506103806106b7366004612935565b610fdd565b3480156106c857600080fd5b506103f76106d73660046127ff565b6001600160a01b03166000908152600080516020612ebb833981519152602052604090205490565b34801561070b57600080fd5b5061038061071a3660046127ff565b61103b565b34801561072b57600080fd5b506103f761073a3660046128f0565b60006020819052908152604090205481565b34801561075857600080fd5b506103806110c9565b34801561076d57600080fd5b5061030961077c366004612909565b6110e9565b34801561078d57600080fd5b50610333611121565b3480156107a257600080fd5b506103806107b13660046128b4565b611160565b3480156107c257600080fd5b506103f7600081565b3480156107d757600080fd5b506103806107e6366004612b5b565b6111cd565b3480156107f757600080fd5b506103806108063660046127ff565b6113f9565b34801561081757600080fd5b506103096108263660046127d5565b6114e3565b34801561083757600080fd5b50610333604051806040016040528060058152602001640352e302e360dc1b81525081565b34801561086857600080fd5b50600254610100900460ff16610309565b34801561088557600080fd5b506103f7600080516020612f1b83398151915281565b3480156108a757600080fd5b506103806108b6366004612909565b6114f9565b3480156108c757600080fd5b506103f7600080516020612f5b83398151915281565b3480156108e957600080fd5b506103f76108f8366004612bb4565b611515565b34801561090957600080fd5b5060025460ff16610309565b34801561092157600080fd5b506103f7600080516020612efb83398151915281565b34801561094357600080fd5b5061038061155f565b34801561095857600080fd5b506103096109673660046128f0565b60009081526001602052604090205460ff1690565b34801561098857600080fd5b506103f77f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e381565b3480156109bc57600080fd5b506103f7600080516020612e9b83398151915281565b3480156109de57600080fd5b506103806109ed366004612bfe565b611660565b3480156109fe57600080fd5b50610380610a0d3660046129c1565b61176f565b60006001600160e01b03198216637965db0b60e01b1480610a4357506301ffc9a760e01b6001600160e01b03198316145b92915050565b7f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace038054606091600080516020612ebb83398151915291610a8890612ca9565b80601f0160208091040260200160405190810160405280929190818152602001828054610ab490612ca9565b8015610b015780601f10610ad657610100808354040283529160200191610b01565b820191906000526020600020905b815481529060010190602001808311610ae457829003601f168201915b505050505091505090565b600033610b1a8185856117ea565b5060019392505050565b6000610b2f816117f7565b6001600160a01b038216610b565760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03821660009081526003602052604090205460ff1615610b9057604051633ea7ffd960e11b815260040160405180910390fd5b6001600160a01b038216600081815260036020526040808220805460ff19166001179055517f158412daecdc1456d01568828bcdb18464cc7f1ce0215ddbc3f3cfede9d1e63d9190a25050565b6000610be8816117f7565b610bf0611801565b604051632142170760e11b81523060048201526001600160a01b038481166024830152604482018490528591908216906342842e0e90606401600060405180830381600087803b158015610c4357600080fd5b505af1158015610c57573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b03167fce89e9903068be3bbda353daa8f2c2ab97ff49f18cfd316bcc47d05f3bd7a92085604051610ca091815260200190565b60405180910390a350610cd260017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b50505050565b6000610ce48484611871565b610cef848484611895565b90505b9392505050565b6000908152600080516020612f3b833981519152602052604090206001015490565b610d2482610cf9565b610d2d816117f7565b610cd283836118b9565b6001600160a01b0381163314610d605760405163334bd91960e11b815260040160405180910390fd5b610d6a828261195e565b505050565b600080516020612efb833981519152610d87816117f7565b610d8f6119da565b50565b600080516020612f1b833981519152610daa816117f7565b600254610100900460ff168015610de65750610de67f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed846110e9565b15610e145760405163022c4fa960e01b81526001600160a01b03841660048201526024015b60405180910390fd5b60025460ff168015610e3b5750610e39600080516020612e9b833981519152846110e9565b155b15610e6457604051632a6856d760e11b81526001600160a01b0384166004820152602401610e0b565b610d6a8383611a3a565b600080516020612f5b833981519152610e86816117f7565b610d6a8383611a70565b6000610e9b816117f7565b610ea53383611a70565b5050565b610eb283610cf9565b610ebb816117f7565b60005b82811015610f0757610ef685858584818110610edc57610edc612ce3565b9050602002016020810190610ef191906127ff565b6118b9565b50610f0081612d0f565b9050610ebe565b5050505050565b6000610f19816117f7565b811515600260019054906101000a900460ff16151503610f5057604051630f4d6f2760e11b81528215156004820152602401610e0b565b600280548315156101000261ff00199091161790556040517f16dc46028b5226742a08e6f10c301fae24989e418fd8aece3456b6052375a71d90610f9990841515815260200190565b60405180910390a15050565b610fad611aa6565b610fb682611b4d565b610ea58282611b77565b6000610fca611c34565b50600080516020612edb83398151915290565b610fe683610cf9565b610fef816117f7565b60005b82811015610f075761102a8585858481811061101057611010612ce3565b905060200201602081019061102591906127ff565b61195e565b5061103481612d0f565b9050610ff2565b6000611046816117f7565b6001600160a01b03821660009081526003602052604090205460ff1661107f5760405163259ba1ad60e01b815260040160405180910390fd5b6001600160a01b038216600081815260036020526040808220805460ff19169055517fb02d270f645215800cec778b856004c753ad0c8c6ca520a91a8399acf4c63d4b9190a25050565b600080516020612efb8339815191526110e1816117f7565b610d8f611c7d565b6000918252600080516020612f3b833981519152602090815260408084206001600160a01b0393909316845291905290205460ff1690565b7f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace048054606091600080516020612ebb83398151915291610a8890612ca9565b600061116b816117f7565b611173611801565b836111886001600160a01b0382168585611cc6565b836001600160a01b0316856001600160a01b03167fd36a970ad3efed17af12006f29eaf44048bdf0096effd1b3fb426cc98f23277b85604051610ca091815260200190565b60006111d8816117f7565b81518351146111fa5760405163cf5b436960e01b815260040160405180910390fd5b60005b8351811015610cd257600084828151811061121a5761121a612ce3565b602002602001015190506000801b810361124757604051630f35a7eb60e21b815260040160405180910390fd5b600084838151811061125b5761125b612ce3565b6020908102919091018101516000848152918290526040909120549091508015801561128657508115155b156112ed57600083815260208181526040808320859055848352600180835292819020805460ff1916909317909255905183815284917f3bf104aa503388aadee80ee675bda8af3de8e7f1134417ff8e2d2d8d77c16b6f91015b60405180910390a26113e3565b80158015906112fb57508115155b80156113075750818114155b15611379576000838152602081815260408083208590558383526001808352818420805460ff1990811690915586855293829020805490941617909255815183815290810184905284917fc67b89aeb01609ba2f55d736aea365b6a20eeea02dc94704405acf825b5002f691016112e0565b8115801561138657508015155b156113e3576000838152602081815260408083208390558383526001825291829020805460ff19169055905182815284917f37434ebe6abf067f2de01b885e3ae9fc97210a7d71f438a352b0c0467c85ee07910160405180910390a25b50505080806113f190612d0f565b9150506111fd565b6000611404816117f7565b61140f60003361195e565b50611428600080516020612efb8339815191523361195e565b50611441600080516020612f1b8339815191523361195e565b5061145a600080516020612f5b8339815191523361195e565b50611473600080516020612e9b8339815191523361195e565b5061147f6000836118b9565b50611498600080516020612efb833981519152836118b9565b506114b1600080516020612f1b833981519152836118b9565b506114ca600080516020612f5b833981519152836118b9565b50610d6a600080516020612e9b833981519152836118b9565b60006114ef3384611871565b610cf28383611d18565b61150282610cf9565b61150b816117f7565b610cd2838361195e565b6001600160a01b0391821660009081527f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace016020908152604080832093909416825291909152205490565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b03166000811580156115925750825b90506000826001600160401b031660011480156115ae5750303b155b9050811580156115bc575080155b156115da5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff19166001178555831561160457845460ff60401b1916600160401b1785555b61160c611d26565b611614611d2e565b8315610f0757845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15050505050565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b03166000811580156116935750825b90506000826001600160401b031660011480156116af5750303b155b9050811580156116bd575080155b156116db5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff19166001178555831561170557845460ff60401b1916600160401b1785555b61170d611d41565b61171b8b8b8b8b8b8b611d51565b831561176257845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d2906020015b60405180910390a15b5050505050505050505050565b600061177a816117f7565b60025482151560ff9091161515036117a957604051631bdf9bdd60e21b81528215156004820152602401610e0b565b6002805460ff19168315159081179091556040519081527fadc7bcae4349ef307e9a436ce8c8719fa58882d755f83d7f8d99f551a791869f90602001610f99565b610d6a8383836001611f31565b610d8f8133612018565b7f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0080546001190161184557604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b60017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b61187a82612051565b61188381612051565b61188c826120b6565b610ea5816120b6565b6000336118a3858285612106565b6118ae858585612166565b506001949350505050565b6000600080516020612f3b8339815191526118d484846110e9565b611954576000848152602082815260408083206001600160a01b03871684529091529020805460ff1916600117905561190a3390565b6001600160a01b0316836001600160a01b0316857f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a46001915050610a43565b6000915050610a43565b6000600080516020612f3b83398151915261197984846110e9565b15611954576000848152602082815260408083206001600160a01b0387168085529252808320805460ff1916905551339287917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a46001915050610a43565b6119e26121c5565b600080516020612f7b833981519152805460ff191681557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a150565b6001600160a01b038216611a645760405163ec442f0560e01b815260006004820152602401610e0b565b610ea5600083836121f5565b6001600160a01b038216611a9a57604051634b637e8f60e11b815260006004820152602401610e0b565b610ea5826000836121f5565b306001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161480611b2d57507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316611b21600080516020612edb833981519152546001600160a01b031690565b6001600160a01b031614155b15611b4b5760405163703e46dd60e11b815260040160405180910390fd5b565b7f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e3610ea5816117f7565b816001600160a01b03166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa925050508015611bd1575060408051601f3d908101601f19168201909252611bce91810190612d28565b60015b611bf957604051634c9c8ce360e01b81526001600160a01b0383166004820152602401610e0b565b600080516020612edb8339815191528114611c2a57604051632a87526960e21b815260048101829052602401610e0b565b610d6a8383612200565b306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614611b4b5760405163703e46dd60e11b815260040160405180910390fd5b611c85612256565b600080516020612f7b833981519152805460ff191660011781557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25833611a1c565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610d6a908490612287565b600033610b1a818585612166565b611b4b6122ea565b611d366122ea565b610d8f6000336118b9565b611d496122ea565b611b4b612321565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b0316600081158015611d845750825b90506000826001600160401b03166001148015611da05750303b155b905081158015611dae575080155b15611dcc5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff191660011785558315611df657845460ff60401b1916600160401b1785555b611e008b8b612329565b611e0861233b565b611e1061155f565b611e18611d26565b611e236000336118b9565b50611e3c600080516020612efb833981519152336118b9565b50611e55600080516020612f1b833981519152336118b9565b50611e6e600080516020612f5b833981519152336118b9565b50611e87600080516020612e9b833981519152336118b9565b50611eb27f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e3336118b9565b508815611ec357611ec3338a611a3a565b6002805461ffff191689151561ff00191617610100891515021762ff000019166201000060ff891602179055831561176257845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d290602001611759565b600080516020612ebb8339815191526001600160a01b038516611f6a5760405163e602df0560e01b815260006004820152602401610e0b565b6001600160a01b038416611f9457604051634a1406b160e11b815260006004820152602401610e0b565b6001600160a01b03808616600090815260018301602090815260408083209388168352929052208390558115610f0757836001600160a01b0316856001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258560405161200991815260200190565b60405180910390a35050505050565b61202282826110e9565b610ea55760405163e2517d3f60e01b81526001600160a01b038216600482015260248101839052604401610e0b565b600254610100900460ff16801561208d575061208d7f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed826110e9565b15610d8f5760405163022c4fa960e01b81526001600160a01b0382166004820152602401610e0b565b60025460ff1680156120dd57506120db600080516020612e9b833981519152826110e9565b155b15610d8f57604051632a6856d760e11b81526001600160a01b0382166004820152602401610e0b565b60006121128484611515565b90506000198114610cd2578181101561215757604051637dc7a0d960e11b81526001600160a01b03841660048201526024810182905260448101839052606401610e0b565b610cd284848484036000611f31565b6001600160a01b03831661219057604051634b637e8f60e11b815260006004820152602401610e0b565b6001600160a01b0382166121ba5760405163ec442f0560e01b815260006004820152602401610e0b565b610d6a8383836121f5565b600080516020612f7b8339815191525460ff16611b4b57604051638dfc202b60e01b815260040160405180910390fd5b610d6a83838361234b565b6122098261235e565b6040516001600160a01b038316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a280511561224e57610d6a82826123c3565b610ea5612439565b600080516020612f7b8339815191525460ff1615611b4b5760405163d93c066560e01b815260040160405180910390fd5b600061229c6001600160a01b03841683612458565b905080516000141580156122c15750808060200190518101906122bf9190612d41565b155b15610d6a57604051635274afe760e01b81526001600160a01b0384166004820152602401610e0b565b600080516020612f9b83398151915254600160401b900460ff16611b4b57604051631afcd79f60e31b815260040160405180910390fd5b61184b6122ea565b6123316122ea565b610ea58282612466565b6123436122ea565b611b4b6124b7565b612353612256565b610d6a8383836124d8565b806001600160a01b03163b60000361239457604051634c9c8ce360e01b81526001600160a01b0382166004820152602401610e0b565b600080516020612edb83398151915280546001600160a01b0319166001600160a01b0392909216919091179055565b6060600080846001600160a01b0316846040516123e09190612d5e565b600060405180830381855af49150503d806000811461241b576040519150601f19603f3d011682016040523d82523d6000602084013e612420565b606091505b5091509150612430858383612616565b95945050505050565b3415611b4b5760405163b398979f60e01b815260040160405180910390fd5b6060610cf283836000612672565b61246e6122ea565b600080516020612ebb8339815191527f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace036124a88482612dc8565b5060048101610cd28382612dc8565b6124bf6122ea565b600080516020612f7b833981519152805460ff19169055565b600080516020612ebb8339815191526001600160a01b03841661251457818160020160008282546125099190612e87565b909155506125869050565b6001600160a01b038416600090815260208290526040902054828110156125675760405163391434e360e21b81526001600160a01b03861660048201526024810182905260448101849052606401610e0b565b6001600160a01b03851660009081526020839052604090209083900390555b6001600160a01b0383166125a45760028101805483900390556125c3565b6001600160a01b03831660009081526020829052604090208054830190555b826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161260891815260200190565b60405180910390a350505050565b60608261262b576126268261270f565b610cf2565b815115801561264257506001600160a01b0384163b155b1561266b57604051639996b31560e01b81526001600160a01b0385166004820152602401610e0b565b5080610cf2565b6060814710156126975760405163cd78605960e01b8152306004820152602401610e0b565b600080856001600160a01b031684866040516126b39190612d5e565b60006040518083038185875af1925050503d80600081146126f0576040519150601f19603f3d011682016040523d82523d6000602084013e6126f5565b606091505b5091509150612705868383612616565b9695505050505050565b80511561271f5780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b60006020828403121561274a57600080fd5b81356001600160e01b031981168114610cf257600080fd5b60005b8381101561277d578181015183820152602001612765565b50506000910152565b60208152600082518060208401526127a5816040850160208701612762565b601f01601f19169190910160400192915050565b80356001600160a01b03811681146127d057600080fd5b919050565b600080604083850312156127e857600080fd5b6127f1836127b9565b946020939093013593505050565b60006020828403121561281157600080fd5b610cf2826127b9565b60008060008060006080868803121561283257600080fd5b61283b866127b9565b9450612849602087016127b9565b93506040860135925060608601356001600160401b038082111561286c57600080fd5b818801915088601f83011261288057600080fd5b81358181111561288f57600080fd5b8960208285010111156128a157600080fd5b9699959850939650602001949392505050565b6000806000606084860312156128c957600080fd5b6128d2846127b9565b92506128e0602085016127b9565b9150604084013590509250925092565b60006020828403121561290257600080fd5b5035919050565b6000806040838503121561291c57600080fd5b8235915061292c602084016127b9565b90509250929050565b60008060006040848603121561294a57600080fd5b8335925060208401356001600160401b038082111561296857600080fd5b818601915086601f83011261297c57600080fd5b81358181111561298b57600080fd5b8760208260051b85010111156129a057600080fd5b6020830194508093505050509250925092565b8015158114610d8f57600080fd5b6000602082840312156129d357600080fd5b8135610cf2816129b3565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715612a1c57612a1c6129de565b604052919050565b60006001600160401b03831115612a3d57612a3d6129de565b612a50601f8401601f19166020016129f4565b9050828152838383011115612a6457600080fd5b828260208301376000602084830101529392505050565b60008060408385031215612a8e57600080fd5b612a97836127b9565b915060208301356001600160401b03811115612ab257600080fd5b8301601f81018513612ac357600080fd5b612ad285823560208401612a24565b9150509250929050565b600082601f830112612aed57600080fd5b813560206001600160401b03821115612b0857612b086129de565b8160051b612b178282016129f4565b9283528481018201928281019087851115612b3157600080fd5b83870192505b84831015612b5057823582529183019190830190612b37565b979650505050505050565b60008060408385031215612b6e57600080fd5b82356001600160401b0380821115612b8557600080fd5b612b9186838701612adc565b93506020850135915080821115612ba757600080fd5b50612ad285828601612adc565b60008060408385031215612bc757600080fd5b612bd0836127b9565b915061292c602084016127b9565b600082601f830112612bef57600080fd5b610cf283833560208501612a24565b60008060008060008060c08789031215612c1757600080fd5b86356001600160401b0380821115612c2e57600080fd5b612c3a8a838b01612bde565b97506020890135915080821115612c5057600080fd5b50612c5d89828a01612bde565b955050604087013593506060870135612c75816129b3565b92506080870135612c85816129b3565b915060a087013560ff81168114612c9b57600080fd5b809150509295509295509295565b600181811c90821680612cbd57607f821691505b602082108103612cdd57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201612d2157612d21612cf9565b5060010190565b600060208284031215612d3a57600080fd5b5051919050565b600060208284031215612d5357600080fd5b8151610cf2816129b3565b60008251612d70818460208701612762565b9190910192915050565b601f821115610d6a57600081815260208120601f850160051c81016020861015612da15750805b601f850160051c820191505b81811015612dc057828155600101612dad565b505050505050565b81516001600160401b03811115612de157612de16129de565b612df581612def8454612ca9565b84612d7a565b602080601f831160018114612e2a5760008415612e125750858301515b600019600386901b1c1916600185901b178555612dc0565b600085815260208120601f198616915b82811015612e5957888601518255948401946001909101908401612e3a565b5085821015612e775787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b80820180821115610a4357610a43612cf956fedb11624602202c396fa347735a55e345a3aeb3e60f8885e1a71f1bf8d5886db752c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace00360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a602dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800d56817b5e92c021c50ae1aff5d257ac047bd15b5d932bc8425da922be2b8f4a9cd5ed15c6e187e77e9aee88184c21f4f2182ab5827cb3b7e07fbedcd63f03300f0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00a26469706673582212208e598281697e9c4422780453b59f1da05705cf6f996edc2000d713da322c749264736f6c63430008140033","external_libraries":[],"proxy_type":null,"implementations":[],"verified_at":"2024-11-19T15:55:17.905973Z","is_verified_via_verifier_alliance":false,"compiler_version":"v0.8.20+commit.a1b79de6","decoded_constructor_args":null,"sourcify_repo_url":null,"optimization_runs":200,"compiler_settings":{"evmVersion":"paris","libraries":{},"optimizer":{"enabled":true,"runs":200},"outputSelection":{"*":{"":["ast"],"*":["abi","evm.bytecode","evm.deployedBytecode","evm.methodIdentifiers","metadata","storageLayout"]}}},"is_verified":true,"verified_twin_address_hash":null,"optimization_enabled":true,"deployed_bytecode":"0x6080604052600436106102e45760003560e01c80636f39feec11610190578063b319031c116100dc578063e63ab1e911610095578063f72c0d8b1161006f578063f72c0d8b1461097c578063f9c8dec3146109b0578063fc079f12146109d2578063fe06a994146109f257600080fd5b8063e63ab1e914610915578063e785b64a14610937578063f05b24f81461094c57600080fd5b8063b319031c1461085c578063d539139314610879578063d547741f1461089b578063db01f21d146108bb578063dd62ed3e146108dd578063e29f5bff146108fd57600080fd5b806395d89b4111610149578063a5a515fa11610123578063a5a515fa146107cb578063a6f9dae1146107eb578063a9059cbb1461080b578063ad3cb1cc1461082b57600080fd5b806395d89b41146107815780639db5dbe414610796578063a217fddf146107b657600080fd5b80636f39feec1461069c57806370a08231146106bc57806377860cdd146106ff578063806d8a8f1461071f5780638456cb591461074c57806391d148541461076157600080fd5b8063313ce5671161024f57806346b5cb5911610208578063513b5814116101e2578063513b5814146105fe57806352d1902d1461062e5780635c975abb1461064357806362b199c51461066857600080fd5b806346b5cb59146105ab5780634cfd24c3146105cb5780634f1ef286146105eb57600080fd5b8063313ce567146104eb57806336568abe146105165780633f4ba83a1461053657806340c10f191461054b578063410937a51461056b57806342966c681461058b57600080fd5b80631aca6376116102a15780631aca63761461040557806323b872dd14610425578063248a9ca31461044557806326aa101f146104655780632f2ff15d1461049e57806330e3952a146104be57600080fd5b806301ffc9a7146102e957806306fdde031461031e578063095ea7b31461034057806309824a8014610360578063150b7a021461038257806318160ddd146103c7575b600080fd5b3480156102f557600080fd5b50610309610304366004612738565b610a12565b60405190151581526020015b60405180910390f35b34801561032a57600080fd5b50610333610a49565b6040516103159190612786565b34801561034c57600080fd5b5061030961035b3660046127d5565b610b0c565b34801561036c57600080fd5b5061038061037b3660046127ff565b610b24565b005b34801561038e57600080fd5b506103ae61039d36600461281a565b630a85bd0160e11b95945050505050565b6040516001600160e01b03199091168152602001610315565b3480156103d357600080fd5b507f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace02545b604051908152602001610315565b34801561041157600080fd5b506103806104203660046128b4565b610bdd565b34801561043157600080fd5b506103096104403660046128b4565b610cd8565b34801561045157600080fd5b506103f76104603660046128f0565b610cf9565b34801561047157600080fd5b506103096104803660046127ff565b6001600160a01b031660009081526003602052604090205460ff1690565b3480156104aa57600080fd5b506103806104b9366004612909565b610d1b565b3480156104ca57600080fd5b506103f76104d93660046128f0565b60009081526020819052604090205490565b3480156104f757600080fd5b5060025462010000900460ff1660405160ff9091168152602001610315565b34801561052257600080fd5b50610380610531366004612909565b610d37565b34801561054257600080fd5b50610380610d6f565b34801561055757600080fd5b506103806105663660046127d5565b610d92565b34801561057757600080fd5b506103806105863660046127d5565b610e6e565b34801561059757600080fd5b506103806105a63660046128f0565b610e90565b3480156105b757600080fd5b506103806105c6366004612935565b610ea9565b3480156105d757600080fd5b506103806105e63660046129c1565b610f0e565b6103806105f9366004612a7b565b610fa5565b34801561060a57600080fd5b506103096106193660046128f0565b60016020526000908152604090205460ff1681565b34801561063a57600080fd5b506103f7610fc0565b34801561064f57600080fd5b50600080516020612f7b8339815191525460ff16610309565b34801561067457600080fd5b506103f77f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed81565b3480156106a857600080fd5b506103806106b7366004612935565b610fdd565b3480156106c857600080fd5b506103f76106d73660046127ff565b6001600160a01b03166000908152600080516020612ebb833981519152602052604090205490565b34801561070b57600080fd5b5061038061071a3660046127ff565b61103b565b34801561072b57600080fd5b506103f761073a3660046128f0565b60006020819052908152604090205481565b34801561075857600080fd5b506103806110c9565b34801561076d57600080fd5b5061030961077c366004612909565b6110e9565b34801561078d57600080fd5b50610333611121565b3480156107a257600080fd5b506103806107b13660046128b4565b611160565b3480156107c257600080fd5b506103f7600081565b3480156107d757600080fd5b506103806107e6366004612b5b565b6111cd565b3480156107f757600080fd5b506103806108063660046127ff565b6113f9565b34801561081757600080fd5b506103096108263660046127d5565b6114e3565b34801561083757600080fd5b50610333604051806040016040528060058152602001640352e302e360dc1b81525081565b34801561086857600080fd5b50600254610100900460ff16610309565b34801561088557600080fd5b506103f7600080516020612f1b83398151915281565b3480156108a757600080fd5b506103806108b6366004612909565b6114f9565b3480156108c757600080fd5b506103f7600080516020612f5b83398151915281565b3480156108e957600080fd5b506103f76108f8366004612bb4565b611515565b34801561090957600080fd5b5060025460ff16610309565b34801561092157600080fd5b506103f7600080516020612efb83398151915281565b34801561094357600080fd5b5061038061155f565b34801561095857600080fd5b506103096109673660046128f0565b60009081526001602052604090205460ff1690565b34801561098857600080fd5b506103f77f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e381565b3480156109bc57600080fd5b506103f7600080516020612e9b83398151915281565b3480156109de57600080fd5b506103806109ed366004612bfe565b611660565b3480156109fe57600080fd5b50610380610a0d3660046129c1565b61176f565b60006001600160e01b03198216637965db0b60e01b1480610a4357506301ffc9a760e01b6001600160e01b03198316145b92915050565b7f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace038054606091600080516020612ebb83398151915291610a8890612ca9565b80601f0160208091040260200160405190810160405280929190818152602001828054610ab490612ca9565b8015610b015780601f10610ad657610100808354040283529160200191610b01565b820191906000526020600020905b815481529060010190602001808311610ae457829003601f168201915b505050505091505090565b600033610b1a8185856117ea565b5060019392505050565b6000610b2f816117f7565b6001600160a01b038216610b565760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03821660009081526003602052604090205460ff1615610b9057604051633ea7ffd960e11b815260040160405180910390fd5b6001600160a01b038216600081815260036020526040808220805460ff19166001179055517f158412daecdc1456d01568828bcdb18464cc7f1ce0215ddbc3f3cfede9d1e63d9190a25050565b6000610be8816117f7565b610bf0611801565b604051632142170760e11b81523060048201526001600160a01b038481166024830152604482018490528591908216906342842e0e90606401600060405180830381600087803b158015610c4357600080fd5b505af1158015610c57573d6000803e3d6000fd5b50505050836001600160a01b0316856001600160a01b03167fce89e9903068be3bbda353daa8f2c2ab97ff49f18cfd316bcc47d05f3bd7a92085604051610ca091815260200190565b60405180910390a350610cd260017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b50505050565b6000610ce48484611871565b610cef848484611895565b90505b9392505050565b6000908152600080516020612f3b833981519152602052604090206001015490565b610d2482610cf9565b610d2d816117f7565b610cd283836118b9565b6001600160a01b0381163314610d605760405163334bd91960e11b815260040160405180910390fd5b610d6a828261195e565b505050565b600080516020612efb833981519152610d87816117f7565b610d8f6119da565b50565b600080516020612f1b833981519152610daa816117f7565b600254610100900460ff168015610de65750610de67f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed846110e9565b15610e145760405163022c4fa960e01b81526001600160a01b03841660048201526024015b60405180910390fd5b60025460ff168015610e3b5750610e39600080516020612e9b833981519152846110e9565b155b15610e6457604051632a6856d760e11b81526001600160a01b0384166004820152602401610e0b565b610d6a8383611a3a565b600080516020612f5b833981519152610e86816117f7565b610d6a8383611a70565b6000610e9b816117f7565b610ea53383611a70565b5050565b610eb283610cf9565b610ebb816117f7565b60005b82811015610f0757610ef685858584818110610edc57610edc612ce3565b9050602002016020810190610ef191906127ff565b6118b9565b50610f0081612d0f565b9050610ebe565b5050505050565b6000610f19816117f7565b811515600260019054906101000a900460ff16151503610f5057604051630f4d6f2760e11b81528215156004820152602401610e0b565b600280548315156101000261ff00199091161790556040517f16dc46028b5226742a08e6f10c301fae24989e418fd8aece3456b6052375a71d90610f9990841515815260200190565b60405180910390a15050565b610fad611aa6565b610fb682611b4d565b610ea58282611b77565b6000610fca611c34565b50600080516020612edb83398151915290565b610fe683610cf9565b610fef816117f7565b60005b82811015610f075761102a8585858481811061101057611010612ce3565b905060200201602081019061102591906127ff565b61195e565b5061103481612d0f565b9050610ff2565b6000611046816117f7565b6001600160a01b03821660009081526003602052604090205460ff1661107f5760405163259ba1ad60e01b815260040160405180910390fd5b6001600160a01b038216600081815260036020526040808220805460ff19169055517fb02d270f645215800cec778b856004c753ad0c8c6ca520a91a8399acf4c63d4b9190a25050565b600080516020612efb8339815191526110e1816117f7565b610d8f611c7d565b6000918252600080516020612f3b833981519152602090815260408084206001600160a01b0393909316845291905290205460ff1690565b7f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace048054606091600080516020612ebb83398151915291610a8890612ca9565b600061116b816117f7565b611173611801565b836111886001600160a01b0382168585611cc6565b836001600160a01b0316856001600160a01b03167fd36a970ad3efed17af12006f29eaf44048bdf0096effd1b3fb426cc98f23277b85604051610ca091815260200190565b60006111d8816117f7565b81518351146111fa5760405163cf5b436960e01b815260040160405180910390fd5b60005b8351811015610cd257600084828151811061121a5761121a612ce3565b602002602001015190506000801b810361124757604051630f35a7eb60e21b815260040160405180910390fd5b600084838151811061125b5761125b612ce3565b6020908102919091018101516000848152918290526040909120549091508015801561128657508115155b156112ed57600083815260208181526040808320859055848352600180835292819020805460ff1916909317909255905183815284917f3bf104aa503388aadee80ee675bda8af3de8e7f1134417ff8e2d2d8d77c16b6f91015b60405180910390a26113e3565b80158015906112fb57508115155b80156113075750818114155b15611379576000838152602081815260408083208590558383526001808352818420805460ff1990811690915586855293829020805490941617909255815183815290810184905284917fc67b89aeb01609ba2f55d736aea365b6a20eeea02dc94704405acf825b5002f691016112e0565b8115801561138657508015155b156113e3576000838152602081815260408083208390558383526001825291829020805460ff19169055905182815284917f37434ebe6abf067f2de01b885e3ae9fc97210a7d71f438a352b0c0467c85ee07910160405180910390a25b50505080806113f190612d0f565b9150506111fd565b6000611404816117f7565b61140f60003361195e565b50611428600080516020612efb8339815191523361195e565b50611441600080516020612f1b8339815191523361195e565b5061145a600080516020612f5b8339815191523361195e565b50611473600080516020612e9b8339815191523361195e565b5061147f6000836118b9565b50611498600080516020612efb833981519152836118b9565b506114b1600080516020612f1b833981519152836118b9565b506114ca600080516020612f5b833981519152836118b9565b50610d6a600080516020612e9b833981519152836118b9565b60006114ef3384611871565b610cf28383611d18565b61150282610cf9565b61150b816117f7565b610cd2838361195e565b6001600160a01b0391821660009081527f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace016020908152604080832093909416825291909152205490565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b03166000811580156115925750825b90506000826001600160401b031660011480156115ae5750303b155b9050811580156115bc575080155b156115da5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff19166001178555831561160457845460ff60401b1916600160401b1785555b61160c611d26565b611614611d2e565b8315610f0757845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15050505050565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b03166000811580156116935750825b90506000826001600160401b031660011480156116af5750303b155b9050811580156116bd575080155b156116db5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff19166001178555831561170557845460ff60401b1916600160401b1785555b61170d611d41565b61171b8b8b8b8b8b8b611d51565b831561176257845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d2906020015b60405180910390a15b5050505050505050505050565b600061177a816117f7565b60025482151560ff9091161515036117a957604051631bdf9bdd60e21b81528215156004820152602401610e0b565b6002805460ff19168315159081179091556040519081527fadc7bcae4349ef307e9a436ce8c8719fa58882d755f83d7f8d99f551a791869f90602001610f99565b610d6a8383836001611f31565b610d8f8133612018565b7f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0080546001190161184557604051633ee5aeb560e01b815260040160405180910390fd5b60029055565b60017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b61187a82612051565b61188381612051565b61188c826120b6565b610ea5816120b6565b6000336118a3858285612106565b6118ae858585612166565b506001949350505050565b6000600080516020612f3b8339815191526118d484846110e9565b611954576000848152602082815260408083206001600160a01b03871684529091529020805460ff1916600117905561190a3390565b6001600160a01b0316836001600160a01b0316857f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a46001915050610a43565b6000915050610a43565b6000600080516020612f3b83398151915261197984846110e9565b15611954576000848152602082815260408083206001600160a01b0387168085529252808320805460ff1916905551339287917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a46001915050610a43565b6119e26121c5565b600080516020612f7b833981519152805460ff191681557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a150565b6001600160a01b038216611a645760405163ec442f0560e01b815260006004820152602401610e0b565b610ea5600083836121f5565b6001600160a01b038216611a9a57604051634b637e8f60e11b815260006004820152602401610e0b565b610ea5826000836121f5565b306001600160a01b037f00000000000000000000000045f8110bc03c9396ccfbb07a16d58785bfd67f22161480611b2d57507f00000000000000000000000045f8110bc03c9396ccfbb07a16d58785bfd67f226001600160a01b0316611b21600080516020612edb833981519152546001600160a01b031690565b6001600160a01b031614155b15611b4b5760405163703e46dd60e11b815260040160405180910390fd5b565b7f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e3610ea5816117f7565b816001600160a01b03166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa925050508015611bd1575060408051601f3d908101601f19168201909252611bce91810190612d28565b60015b611bf957604051634c9c8ce360e01b81526001600160a01b0383166004820152602401610e0b565b600080516020612edb8339815191528114611c2a57604051632a87526960e21b815260048101829052602401610e0b565b610d6a8383612200565b306001600160a01b037f00000000000000000000000045f8110bc03c9396ccfbb07a16d58785bfd67f221614611b4b5760405163703e46dd60e11b815260040160405180910390fd5b611c85612256565b600080516020612f7b833981519152805460ff191660011781557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25833611a1c565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610d6a908490612287565b600033610b1a818585612166565b611b4b6122ea565b611d366122ea565b610d8f6000336118b9565b611d496122ea565b611b4b612321565b600080516020612f9b8339815191528054600160401b810460ff1615906001600160401b0316600081158015611d845750825b90506000826001600160401b03166001148015611da05750303b155b905081158015611dae575080155b15611dcc5760405163f92ee8a960e01b815260040160405180910390fd5b845467ffffffffffffffff191660011785558315611df657845460ff60401b1916600160401b1785555b611e008b8b612329565b611e0861233b565b611e1061155f565b611e18611d26565b611e236000336118b9565b50611e3c600080516020612efb833981519152336118b9565b50611e55600080516020612f1b833981519152336118b9565b50611e6e600080516020612f5b833981519152336118b9565b50611e87600080516020612e9b833981519152336118b9565b50611eb27f189ab7a9244df0848122154315af71fe140f3db0fe014031783b0946b8c9d2e3336118b9565b508815611ec357611ec3338a611a3a565b6002805461ffff191689151561ff00191617610100891515021762ff000019166201000060ff891602179055831561176257845460ff60401b19168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d290602001611759565b600080516020612ebb8339815191526001600160a01b038516611f6a5760405163e602df0560e01b815260006004820152602401610e0b565b6001600160a01b038416611f9457604051634a1406b160e11b815260006004820152602401610e0b565b6001600160a01b03808616600090815260018301602090815260408083209388168352929052208390558115610f0757836001600160a01b0316856001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258560405161200991815260200190565b60405180910390a35050505050565b61202282826110e9565b610ea55760405163e2517d3f60e01b81526001600160a01b038216600482015260248101839052604401610e0b565b600254610100900460ff16801561208d575061208d7f548c7f0307ab2a7ea894e5c7e8c5353cc750bb9385ee2e945f189a9a83daa8ed826110e9565b15610d8f5760405163022c4fa960e01b81526001600160a01b0382166004820152602401610e0b565b60025460ff1680156120dd57506120db600080516020612e9b833981519152826110e9565b155b15610d8f57604051632a6856d760e11b81526001600160a01b0382166004820152602401610e0b565b60006121128484611515565b90506000198114610cd2578181101561215757604051637dc7a0d960e11b81526001600160a01b03841660048201526024810182905260448101839052606401610e0b565b610cd284848484036000611f31565b6001600160a01b03831661219057604051634b637e8f60e11b815260006004820152602401610e0b565b6001600160a01b0382166121ba5760405163ec442f0560e01b815260006004820152602401610e0b565b610d6a8383836121f5565b600080516020612f7b8339815191525460ff16611b4b57604051638dfc202b60e01b815260040160405180910390fd5b610d6a83838361234b565b6122098261235e565b6040516001600160a01b038316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a280511561224e57610d6a82826123c3565b610ea5612439565b600080516020612f7b8339815191525460ff1615611b4b5760405163d93c066560e01b815260040160405180910390fd5b600061229c6001600160a01b03841683612458565b905080516000141580156122c15750808060200190518101906122bf9190612d41565b155b15610d6a57604051635274afe760e01b81526001600160a01b0384166004820152602401610e0b565b600080516020612f9b83398151915254600160401b900460ff16611b4b57604051631afcd79f60e31b815260040160405180910390fd5b61184b6122ea565b6123316122ea565b610ea58282612466565b6123436122ea565b611b4b6124b7565b612353612256565b610d6a8383836124d8565b806001600160a01b03163b60000361239457604051634c9c8ce360e01b81526001600160a01b0382166004820152602401610e0b565b600080516020612edb83398151915280546001600160a01b0319166001600160a01b0392909216919091179055565b6060600080846001600160a01b0316846040516123e09190612d5e565b600060405180830381855af49150503d806000811461241b576040519150601f19603f3d011682016040523d82523d6000602084013e612420565b606091505b5091509150612430858383612616565b95945050505050565b3415611b4b5760405163b398979f60e01b815260040160405180910390fd5b6060610cf283836000612672565b61246e6122ea565b600080516020612ebb8339815191527f52c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace036124a88482612dc8565b5060048101610cd28382612dc8565b6124bf6122ea565b600080516020612f7b833981519152805460ff19169055565b600080516020612ebb8339815191526001600160a01b03841661251457818160020160008282546125099190612e87565b909155506125869050565b6001600160a01b038416600090815260208290526040902054828110156125675760405163391434e360e21b81526001600160a01b03861660048201526024810182905260448101849052606401610e0b565b6001600160a01b03851660009081526020839052604090209083900390555b6001600160a01b0383166125a45760028101805483900390556125c3565b6001600160a01b03831660009081526020829052604090208054830190555b826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161260891815260200190565b60405180910390a350505050565b60608261262b576126268261270f565b610cf2565b815115801561264257506001600160a01b0384163b155b1561266b57604051639996b31560e01b81526001600160a01b0385166004820152602401610e0b565b5080610cf2565b6060814710156126975760405163cd78605960e01b8152306004820152602401610e0b565b600080856001600160a01b031684866040516126b39190612d5e565b60006040518083038185875af1925050503d80600081146126f0576040519150601f19603f3d011682016040523d82523d6000602084013e6126f5565b606091505b5091509150612705868383612616565b9695505050505050565b80511561271f5780518082602001fd5b604051630a12f52160e11b815260040160405180910390fd5b60006020828403121561274a57600080fd5b81356001600160e01b031981168114610cf257600080fd5b60005b8381101561277d578181015183820152602001612765565b50506000910152565b60208152600082518060208401526127a5816040850160208701612762565b601f01601f19169190910160400192915050565b80356001600160a01b03811681146127d057600080fd5b919050565b600080604083850312156127e857600080fd5b6127f1836127b9565b946020939093013593505050565b60006020828403121561281157600080fd5b610cf2826127b9565b60008060008060006080868803121561283257600080fd5b61283b866127b9565b9450612849602087016127b9565b93506040860135925060608601356001600160401b038082111561286c57600080fd5b818801915088601f83011261288057600080fd5b81358181111561288f57600080fd5b8960208285010111156128a157600080fd5b9699959850939650602001949392505050565b6000806000606084860312156128c957600080fd5b6128d2846127b9565b92506128e0602085016127b9565b9150604084013590509250925092565b60006020828403121561290257600080fd5b5035919050565b6000806040838503121561291c57600080fd5b8235915061292c602084016127b9565b90509250929050565b60008060006040848603121561294a57600080fd5b8335925060208401356001600160401b038082111561296857600080fd5b818601915086601f83011261297c57600080fd5b81358181111561298b57600080fd5b8760208260051b85010111156129a057600080fd5b6020830194508093505050509250925092565b8015158114610d8f57600080fd5b6000602082840312156129d357600080fd5b8135610cf2816129b3565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715612a1c57612a1c6129de565b604052919050565b60006001600160401b03831115612a3d57612a3d6129de565b612a50601f8401601f19166020016129f4565b9050828152838383011115612a6457600080fd5b828260208301376000602084830101529392505050565b60008060408385031215612a8e57600080fd5b612a97836127b9565b915060208301356001600160401b03811115612ab257600080fd5b8301601f81018513612ac357600080fd5b612ad285823560208401612a24565b9150509250929050565b600082601f830112612aed57600080fd5b813560206001600160401b03821115612b0857612b086129de565b8160051b612b178282016129f4565b9283528481018201928281019087851115612b3157600080fd5b83870192505b84831015612b5057823582529183019190830190612b37565b979650505050505050565b60008060408385031215612b6e57600080fd5b82356001600160401b0380821115612b8557600080fd5b612b9186838701612adc565b93506020850135915080821115612ba757600080fd5b50612ad285828601612adc565b60008060408385031215612bc757600080fd5b612bd0836127b9565b915061292c602084016127b9565b600082601f830112612bef57600080fd5b610cf283833560208501612a24565b60008060008060008060c08789031215612c1757600080fd5b86356001600160401b0380821115612c2e57600080fd5b612c3a8a838b01612bde565b97506020890135915080821115612c5057600080fd5b50612c5d89828a01612bde565b955050604087013593506060870135612c75816129b3565b92506080870135612c85816129b3565b915060a087013560ff81168114612c9b57600080fd5b809150509295509295509295565b600181811c90821680612cbd57607f821691505b602082108103612cdd57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060018201612d2157612d21612cf9565b5060010190565b600060208284031215612d3a57600080fd5b5051919050565b600060208284031215612d5357600080fd5b8151610cf2816129b3565b60008251612d70818460208701612762565b9190910192915050565b601f821115610d6a57600081815260208120601f850160051c81016020861015612da15750805b601f850160051c820191505b81811015612dc057828155600101612dad565b505050505050565b81516001600160401b03811115612de157612de16129de565b612df581612def8454612ca9565b84612d7a565b602080601f831160018114612e2a5760008415612e125750858301515b600019600386901b1c1916600185901b178555612dc0565b600085815260208120601f198616915b82811015612e5957888601518255948401946001909101908401612e3a565b5085821015612e775787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b80820180821115610a4357610a43612cf956fedb11624602202c396fa347735a55e345a3aeb3e60f8885e1a71f1bf8d5886db752c63247e1f47db19d5ce0460030c497f067ca4cebf71ba98eeadabe20bace00360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc65d7a28e3265b37a6474929f336521b332c1681b933f6cb9f3376673440d862a9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a602dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800d56817b5e92c021c50ae1aff5d257ac047bd15b5d932bc8425da922be2b8f4a9cd5ed15c6e187e77e9aee88184c21f4f2182ab5827cb3b7e07fbedcd63f03300f0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00a26469706673582212208e598281697e9c4422780453b59f1da05705cf6f996edc2000d713da322c749264736f6c63430008140033","source_code":"// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\nimport './ExtendedERC20.sol';\nimport '@openzeppelin/contracts-upgradeable/utils/ReentrancyGuardUpgradeable.sol';\nimport { IERC20, SafeERC20 } from '@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol';\nimport { IERC721 } from '@openzeppelin/contracts/token/ERC721/IERC721.sol';\nimport '@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol';\nimport '@openzeppelin/contracts-upgradeable/proxy/utils/UUPSUpgradeable.sol';\n\ncontract ERC20PoolToken is ExtendedERC20, ReentrancyGuardUpgradeable, IERC721Receiver {\n  using SafeERC20 for IERC20;\n\n  // Custom error for trying to register a zero address\n  error InvalidAddress();\n\n  // Custom error for attempting to register a token that's already registered\n  error TokenAlreadyRegistered();\n\n  // Custom error for attempting to unregister a token that's not registered\n  error TokenNotRegistered();\n\n  // Emitted when a token is successfully registered\n  event TokenRegistered(address indexed tokenAddress);\n\n  // Emitted when a token is successfully unregistered\n  event TokenUnregistered(address indexed tokenAddress);\n\n  // Emitted when an ERC20 token is transferred out of the contract\n  event ERC20TokenTransferred(address indexed tokenAddress, address indexed recipient, uint256 amount);\n\n  // Emitted when an ERC721 token is transferred out of the contract\n  event ERC721TokenTransferred(address indexed tokenAddress, address indexed recipient, uint256 tokenId);\n\n  // Mapping of tokens considered for the pool value calculations\n  mapping(address => bool) private registeredTokens;\n\n  function initialize(\n    string memory name_,\n    string memory symbol_,\n    uint256 premintAmount,\n    bool kycEnabled_,\n    bool blacklistEnabled_,\n    uint8 decimals_\n  ) public virtual override initializer {\n    __ReentrancyGuard_init();\n    super.initialize(name_, symbol_, premintAmount, kycEnabled_, blacklistEnabled_, decimals_);\n  }\n\n  function registerToken(address tokenAddress) public onlyRole(DEFAULT_ADMIN_ROLE) {\n    if (tokenAddress == address(0)) revert InvalidAddress();\n    if (registeredTokens[tokenAddress]) revert TokenAlreadyRegistered();\n    registeredTokens[tokenAddress] = true;\n    emit TokenRegistered(tokenAddress);\n  }\n\n  function unregisterToken(address tokenAddress) public onlyRole(DEFAULT_ADMIN_ROLE) {\n    if (!registeredTokens[tokenAddress]) revert TokenNotRegistered();\n    registeredTokens[tokenAddress] = false;\n    emit TokenUnregistered(tokenAddress);\n  }\n\n  function isTokenRegistered(address tokenAddress) public view returns (bool) {\n    return registeredTokens[tokenAddress];\n  }\n\n  /**\n   * @dev Transfers amy ERC20 token from the contract to the recipient.\n   * In the event that an ERC20 token is accidentally sent to the contract, this function can be used to transfer it out.\n   */\n  function transferERC20(\n    address tokenAddress,\n    address recipient,\n    uint256 amount\n  ) public onlyRole(DEFAULT_ADMIN_ROLE) nonReentrant {\n    IERC20 token = IERC20(tokenAddress);\n    token.safeTransfer(recipient, amount);\n    emit ERC20TokenTransferred(tokenAddress, recipient, amount);\n  }\n\n  /**\n   * @dev Transfer any ERC721 token from the contract to the recipient.\n   * In the event that an ERC721 token is accidentally sent to the contract, this function can be used to transfer it out.\n   */\n  function transferERC721(\n    address tokenAddress,\n    address recipient,\n    uint256 tokenId\n  ) public onlyRole(DEFAULT_ADMIN_ROLE) nonReentrant {\n    IERC721 token = IERC721(tokenAddress);\n    token.safeTransferFrom(address(this), recipient, tokenId);\n    emit ERC721TokenTransferred(tokenAddress, recipient, tokenId);\n  }\n\n  /**\n   * @dev Allows the contract to safely receive ERC721 tokens.\n   * @param - operator The address which called `safeTransferFrom` function.\n   * @param - from The address which previously owned the token.\n   * @param - tokenId The NFT identifier which is being transferred.\n   * @param - data Additional data with no specified format.\n   * @return bytes4 Returns `bytes4(keccak256(\"onERC721Received(address,address,uint256,bytes)\"))`\n   */\n  function onERC721Received(\n    address /* operator */,\n    address /* from */,\n    uint256 /* tokenId */,\n    bytes calldata /* data */\n  ) external pure override returns (bytes4) {\n    return this.onERC721Received.selector;\n  }\n\n  // UUPS upgrade authorization\n  function _authorizeUpgrade(address newImplementation) internal override onlyRole(UPGRADER_ROLE) {}\n}\n","creation_status":"success","file_path":"contracts/ERC20PoolToken.sol"}