Source Code
Overview
ETH Balance
0 ETH
ETH Value
$0.00View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Cross-Chain Transactions
Loading...
Loading
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Name:
CUBE
Compiler Version
v0.8.20+commit.a1b79de6
Contract Source Code (Solidity)
/**
*Submitted for verification at uniscan.xyz on 2025-02-12
*/
/*
.____ ________
| | _____ ___.__. __________\_____ \
| | \__ \< | |/ __ \_ __ \_(__ <
| |___ / __ \\___ \ ___/| | \/ \
|_______ (____ / ____|\___ >__| /______ /
\/ \/\/ \/ \/
*/
// SPDX-License-Identifier: Apache-2.0
pragma solidity =0.8.20 ^0.8.20;
// lib/openzeppelin-contracts/contracts/utils/Address.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol)
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev The ETH balance of the account is not enough to perform the operation.
*/
error AddressInsufficientBalance(address account);
/**
* @dev There's no code at `target` (it is not a contract).
*/
error AddressEmptyCode(address target);
/**
* @dev A call to an address target failed. The target may have reverted.
*/
error FailedInnerCall();
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
if (address(this).balance < amount) {
revert AddressInsufficientBalance(address(this));
}
(bool success, ) = recipient.call{value: amount}("");
if (!success) {
revert FailedInnerCall();
}
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason or custom error, it is bubbled
* up by this function (like regular Solidity function calls). However, if
* the call reverted with no returned reason, this function reverts with a
* {FailedInnerCall} error.
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*/
function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
if (address(this).balance < value) {
revert AddressInsufficientBalance(address(this));
}
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResultFromTarget(target, success, returndata);
}
/**
* @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target
* was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an
* unsuccessful call.
*/
function verifyCallResultFromTarget(
address target,
bool success,
bytes memory returndata
) internal view returns (bytes memory) {
if (!success) {
_revert(returndata);
} else {
// only check if target is a contract if the call was successful and the return data is empty
// otherwise we already know that it was a contract
if (returndata.length == 0 && target.code.length == 0) {
revert AddressEmptyCode(target);
}
return returndata;
}
}
/**
* @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the
* revert reason or with a default {FailedInnerCall} error.
*/
function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) {
if (!success) {
_revert(returndata);
} else {
return returndata;
}
}
/**
* @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}.
*/
function _revert(bytes memory returndata) private pure {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
/// @solidity memory-safe-assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert FailedInnerCall();
}
}
}
// lib/openzeppelin-contracts/contracts/utils/cryptography/ECDSA.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/ECDSA.sol)
/**
* @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
*
* These functions can be used to verify that a message was signed by the holder
* of the private keys of a given address.
*/
library ECDSA {
enum RecoverError {
NoError,
InvalidSignature,
InvalidSignatureLength,
InvalidSignatureS
}
/**
* @dev The signature derives the `address(0)`.
*/
error ECDSAInvalidSignature();
/**
* @dev The signature has an invalid length.
*/
error ECDSAInvalidSignatureLength(uint256 length);
/**
* @dev The signature has an S value that is in the upper half order.
*/
error ECDSAInvalidSignatureS(bytes32 s);
/**
* @dev Returns the address that signed a hashed message (`hash`) with `signature` or an error. This will not
* return address(0) without also returning an error description. Errors are documented using an enum (error type)
* and a bytes32 providing additional information about the error.
*
* If no error is returned, then the address can be used for verification purposes.
*
* The `ecrecover` EVM precompile allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it.
*
* Documentation for signature generation:
* - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]
* - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]
*/
function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError, bytes32) {
if (signature.length == 65) {
bytes32 r;
bytes32 s;
uint8 v;
// ecrecover takes the signature parameters, and the only way to get them
// currently is to use assembly.
/// @solidity memory-safe-assembly
assembly {
r := mload(add(signature, 0x20))
s := mload(add(signature, 0x40))
v := byte(0, mload(add(signature, 0x60)))
}
return tryRecover(hash, v, r, s);
} else {
return (address(0), RecoverError.InvalidSignatureLength, bytes32(signature.length));
}
}
/**
* @dev Returns the address that signed a hashed message (`hash`) with
* `signature`. This address can then be used for verification purposes.
*
* The `ecrecover` EVM precompile allows for malleable (non-unique) signatures:
* this function rejects them by requiring the `s` value to be in the lower
* half order, and the `v` value to be either 27 or 28.
*
* IMPORTANT: `hash` _must_ be the result of a hash operation for the
* verification to be secure: it is possible to craft signatures that
* recover to arbitrary addresses for non-hashed data. A safe way to ensure
* this is by receiving a hash of the original message (which may otherwise
* be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it.
*/
function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, signature);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.
*
* See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]
*/
function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError, bytes32) {
unchecked {
bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff);
// We do not check for an overflow here since the shift operation results in 0 or 1.
uint8 v = uint8((uint256(vs) >> 255) + 27);
return tryRecover(hash, v, r, s);
}
}
/**
* @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.
*/
function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, r, vs);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Overload of {ECDSA-tryRecover} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function tryRecover(
bytes32 hash,
uint8 v,
bytes32 r,
bytes32 s
) internal pure returns (address, RecoverError, bytes32) {
// EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
// unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
// the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most
// signatures from current libraries generate a unique signature with an s-value in the lower half order.
//
// If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
// with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
// vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
// these malleable signatures as well.
if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {
return (address(0), RecoverError.InvalidSignatureS, s);
}
// If the signature is valid (and not malleable), return the signer address
address signer = ecrecover(hash, v, r, s);
if (signer == address(0)) {
return (address(0), RecoverError.InvalidSignature, bytes32(0));
}
return (signer, RecoverError.NoError, bytes32(0));
}
/**
* @dev Overload of {ECDSA-recover} that receives the `v`,
* `r` and `s` signature fields separately.
*/
function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
(address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, v, r, s);
_throwError(error, errorArg);
return recovered;
}
/**
* @dev Optionally reverts with the corresponding custom error according to the `error` argument provided.
*/
function _throwError(RecoverError error, bytes32 errorArg) private pure {
if (error == RecoverError.NoError) {
return; // no error: do nothing
} else if (error == RecoverError.InvalidSignature) {
revert ECDSAInvalidSignature();
} else if (error == RecoverError.InvalidSignatureLength) {
revert ECDSAInvalidSignatureLength(uint256(errorArg));
} else if (error == RecoverError.InvalidSignatureS) {
revert ECDSAInvalidSignatureS(errorArg);
}
}
}
// lib/openzeppelin-contracts/contracts/access/IAccessControl.sol
// OpenZeppelin Contracts (last updated v5.0.0) (access/IAccessControl.sol)
/**
* @dev External interface of AccessControl declared to support ERC165 detection.
*/
interface IAccessControl {
/**
* @dev The `account` is missing a role.
*/
error AccessControlUnauthorizedAccount(address account, bytes32 neededRole);
/**
* @dev The caller of a function is not the expected one.
*
* NOTE: Don't confuse with {AccessControlUnauthorizedAccount}.
*/
error AccessControlBadConfirmation();
/**
* @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
*
* `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
* {RoleAdminChanged} not being emitted signaling this.
*/
event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);
/**
* @dev Emitted when `account` is granted `role`.
*
* `sender` is the account that originated the contract call, an admin role
* bearer except when using {AccessControl-_setupRole}.
*/
event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Emitted when `account` is revoked `role`.
*
* `sender` is the account that originated the contract call:
* - if using `revokeRole`, it is the admin role bearer
* - if using `renounceRole`, it is the role bearer (i.e. `account`)
*/
event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) external view returns (bool);
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {AccessControl-_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) external view returns (bytes32);
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function grantRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*/
function revokeRole(bytes32 role, address account) external;
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been granted `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `callerConfirmation`.
*/
function renounceRole(bytes32 role, address callerConfirmation) external;
}
// lib/openzeppelin-contracts/contracts/proxy/beacon/IBeacon.sol
// OpenZeppelin Contracts (last updated v5.0.0) (proxy/beacon/IBeacon.sol)
/**
* @dev This is the interface that {BeaconProxy} expects of its beacon.
*/
interface IBeacon {
/**
* @dev Must return an address that can be used as a delegate call target.
*
* {UpgradeableBeacon} will check that this address is a contract.
*/
function implementation() external view returns (address);
}
// lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol)
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}
// lib/openzeppelin-contracts/contracts/interfaces/IERC5267.sol
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC5267.sol)
interface IERC5267 {
/**
* @dev MAY be emitted to signal that the domain could have changed.
*/
event EIP712DomainChanged();
/**
* @dev returns the fields and values that describe the domain separator used by this contract for EIP-712
* signature.
*/
function eip712Domain()
external
view
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
);
}
// lib/openzeppelin-contracts/contracts/token/ERC721/IERC721Receiver.sol
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/IERC721Receiver.sol)
/**
* @title ERC721 token receiver interface
* @dev Interface for any contract that wants to support safeTransfers
* from ERC721 asset contracts.
*/
interface IERC721Receiver {
/**
* @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
* by `operator` from `from`, this function is called.
*
* It must return its Solidity selector to confirm the token transfer.
* If any other value is returned or the interface is not implemented by the recipient, the transfer will be
* reverted.
*
* The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
*/
function onERC721Received(
address operator,
address from,
uint256 tokenId,
bytes calldata data
) external returns (bytes4);
}
// src/escrow/interfaces/ITokenType.sol
interface ITokenType {
enum TokenType {
ERC20,
ERC721,
ERC1155,
NATIVE
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/Initializable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (proxy/utils/Initializable.sol)
/**
* @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
* behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
* external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
* function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
*
* The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
* reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
* case an upgrade adds a module that needs to be initialized.
*
* For example:
*
* [.hljs-theme-light.nopadding]
* ```solidity
* contract MyToken is ERC20Upgradeable {
* function initialize() initializer public {
* __ERC20_init("MyToken", "MTK");
* }
* }
*
* contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {
* function initializeV2() reinitializer(2) public {
* __ERC20Permit_init("MyToken");
* }
* }
* ```
*
* TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
* possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
*
* CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
* that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
*
* [CAUTION]
* ====
* Avoid leaving a contract uninitialized.
*
* An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
* contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke
* the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:
*
* [.hljs-theme-light.nopadding]
* ```
* /// @custom:oz-upgrades-unsafe-allow constructor
* constructor() {
* _disableInitializers();
* }
* ```
* ====
*/
abstract contract Initializable {
/**
* @dev Storage of the initializable contract.
*
* It's implemented on a custom ERC-7201 namespace to reduce the risk of storage collisions
* when using with upgradeable contracts.
*
* @custom:storage-location erc7201:openzeppelin.storage.Initializable
*/
struct InitializableStorage {
/**
* @dev Indicates that the contract has been initialized.
*/
uint64 _initialized;
/**
* @dev Indicates that the contract is in the process of being initialized.
*/
bool _initializing;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.Initializable")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant INITIALIZABLE_STORAGE = 0xf0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00;
/**
* @dev The contract is already initialized.
*/
error InvalidInitialization();
/**
* @dev The contract is not initializing.
*/
error NotInitializing();
/**
* @dev Triggered when the contract has been initialized or reinitialized.
*/
event Initialized(uint64 version);
/**
* @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,
* `onlyInitializing` functions can be used to initialize parent contracts.
*
* Similar to `reinitializer(1)`, except that in the context of a constructor an `initializer` may be invoked any
* number of times. This behavior in the constructor can be useful during testing and is not expected to be used in
* production.
*
* Emits an {Initialized} event.
*/
modifier initializer() {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
// Cache values to avoid duplicated sloads
bool isTopLevelCall = !$._initializing;
uint64 initialized = $._initialized;
// Allowed calls:
// - initialSetup: the contract is not in the initializing state and no previous version was
// initialized
// - construction: the contract is initialized at version 1 (no reininitialization) and the
// current contract is just being deployed
bool initialSetup = initialized == 0 && isTopLevelCall;
bool construction = initialized == 1 && address(this).code.length == 0;
if (!initialSetup && !construction) {
revert InvalidInitialization();
}
$._initialized = 1;
if (isTopLevelCall) {
$._initializing = true;
}
_;
if (isTopLevelCall) {
$._initializing = false;
emit Initialized(1);
}
}
/**
* @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the
* contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be
* used to initialize parent contracts.
*
* A reinitializer may be used after the original initialization step. This is essential to configure modules that
* are added through upgrades and that require initialization.
*
* When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`
* cannot be nested. If one is invoked in the context of another, execution will revert.
*
* Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in
* a contract, executing them in the right order is up to the developer or operator.
*
* WARNING: Setting the version to 2**64 - 1 will prevent any future reinitialization.
*
* Emits an {Initialized} event.
*/
modifier reinitializer(uint64 version) {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
if ($._initializing || $._initialized >= version) {
revert InvalidInitialization();
}
$._initialized = version;
$._initializing = true;
_;
$._initializing = false;
emit Initialized(version);
}
/**
* @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
* {initializer} and {reinitializer} modifiers, directly or indirectly.
*/
modifier onlyInitializing() {
_checkInitializing();
_;
}
/**
* @dev Reverts if the contract is not in an initializing state. See {onlyInitializing}.
*/
function _checkInitializing() internal view virtual {
if (!_isInitializing()) {
revert NotInitializing();
}
}
/**
* @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.
* Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized
* to any version. It is recommended to use this to lock implementation contracts that are designed to be called
* through proxies.
*
* Emits an {Initialized} event the first time it is successfully executed.
*/
function _disableInitializers() internal virtual {
// solhint-disable-next-line var-name-mixedcase
InitializableStorage storage $ = _getInitializableStorage();
if ($._initializing) {
revert InvalidInitialization();
}
if ($._initialized != type(uint64).max) {
$._initialized = type(uint64).max;
emit Initialized(type(uint64).max);
}
}
/**
* @dev Returns the highest version that has been initialized. See {reinitializer}.
*/
function _getInitializedVersion() internal view returns (uint64) {
return _getInitializableStorage()._initialized;
}
/**
* @dev Returns `true` if the contract is currently initializing. See {onlyInitializing}.
*/
function _isInitializing() internal view returns (bool) {
return _getInitializableStorage()._initializing;
}
/**
* @dev Returns a pointer to the storage namespace.
*/
// solhint-disable-next-line var-name-mixedcase
function _getInitializableStorage() private pure returns (InitializableStorage storage $) {
assembly {
$.slot := INITIALIZABLE_STORAGE
}
}
}
// lib/openzeppelin-contracts/contracts/utils/math/Math.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/math/Math.sol)
/**
* @dev Standard math utilities missing in the Solidity language.
*/
library Math {
/**
* @dev Muldiv operation overflow.
*/
error MathOverflowedMulDiv();
enum Rounding {
Floor, // Toward negative infinity
Ceil, // Toward positive infinity
Trunc, // Toward zero
Expand // Away from zero
}
/**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*/
function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) return (false, 0);
return (true, c);
}
}
/**
* @dev Returns the subtraction of two unsigned integers, with an overflow flag.
*/
function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b > a) return (false, 0);
return (true, a - b);
}
}
/**
* @dev Returns the multiplication of two unsigned integers, with an overflow flag.
*/
function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) return (true, 0);
uint256 c = a * b;
if (c / a != b) return (false, 0);
return (true, c);
}
}
/**
* @dev Returns the division of two unsigned integers, with a division by zero flag.
*/
function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b == 0) return (false, 0);
return (true, a / b);
}
}
/**
* @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
*/
function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b == 0) return (false, 0);
return (true, a % b);
}
}
/**
* @dev Returns the largest of two numbers.
*/
function max(uint256 a, uint256 b) internal pure returns (uint256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two numbers.
*/
function min(uint256 a, uint256 b) internal pure returns (uint256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two numbers. The result is rounded towards
* zero.
*/
function average(uint256 a, uint256 b) internal pure returns (uint256) {
// (a + b) / 2 can overflow.
return (a & b) + (a ^ b) / 2;
}
/**
* @dev Returns the ceiling of the division of two numbers.
*
* This differs from standard division with `/` in that it rounds towards infinity instead
* of rounding towards zero.
*/
function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
if (b == 0) {
// Guarantee the same behavior as in a regular Solidity division.
return a / b;
}
// (a + b - 1) / b can overflow on addition, so we distribute.
return a == 0 ? 0 : (a - 1) / b + 1;
}
/**
* @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or
* denominator == 0.
* @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) with further edits by
* Uniswap Labs also under MIT license.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) {
unchecked {
// 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
// use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
// variables such that product = prod1 * 2^256 + prod0.
uint256 prod0 = x * y; // Least significant 256 bits of the product
uint256 prod1; // Most significant 256 bits of the product
assembly {
let mm := mulmod(x, y, not(0))
prod1 := sub(sub(mm, prod0), lt(mm, prod0))
}
// Handle non-overflow cases, 256 by 256 division.
if (prod1 == 0) {
// Solidity will revert if denominator == 0, unlike the div opcode on its own.
// The surrounding unchecked block does not change this fact.
// See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic.
return prod0 / denominator;
}
// Make sure the result is less than 2^256. Also prevents denominator == 0.
if (denominator <= prod1) {
revert MathOverflowedMulDiv();
}
///////////////////////////////////////////////
// 512 by 256 division.
///////////////////////////////////////////////
// Make division exact by subtracting the remainder from [prod1 prod0].
uint256 remainder;
assembly {
// Compute remainder using mulmod.
remainder := mulmod(x, y, denominator)
// Subtract 256 bit number from 512 bit number.
prod1 := sub(prod1, gt(remainder, prod0))
prod0 := sub(prod0, remainder)
}
// Factor powers of two out of denominator and compute largest power of two divisor of denominator.
// Always >= 1. See https://cs.stackexchange.com/q/138556/92363.
uint256 twos = denominator & (0 - denominator);
assembly {
// Divide denominator by twos.
denominator := div(denominator, twos)
// Divide [prod1 prod0] by twos.
prod0 := div(prod0, twos)
// Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
twos := add(div(sub(0, twos), twos), 1)
}
// Shift in bits from prod1 into prod0.
prod0 |= prod1 * twos;
// Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
// that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
// four bits. That is, denominator * inv = 1 mod 2^4.
uint256 inverse = (3 * denominator) ^ 2;
// Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also
// works in modular arithmetic, doubling the correct bits in each step.
inverse *= 2 - denominator * inverse; // inverse mod 2^8
inverse *= 2 - denominator * inverse; // inverse mod 2^16
inverse *= 2 - denominator * inverse; // inverse mod 2^32
inverse *= 2 - denominator * inverse; // inverse mod 2^64
inverse *= 2 - denominator * inverse; // inverse mod 2^128
inverse *= 2 - denominator * inverse; // inverse mod 2^256
// Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
// This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
// less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
// is no longer required.
result = prod0 * inverse;
return result;
}
}
/**
* @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
*/
function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) {
uint256 result = mulDiv(x, y, denominator);
if (unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0) {
result += 1;
}
return result;
}
/**
* @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded
* towards zero.
*
* Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
*/
function sqrt(uint256 a) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
// For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
//
// We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
// `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
//
// This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
// → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
// → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
//
// Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
uint256 result = 1 << (log2(a) >> 1);
// At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
// since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
// every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
// into the expected uint128 result.
unchecked {
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
result = (result + a / result) >> 1;
return min(result, a / result);
}
}
/**
* @notice Calculates sqrt(a), following the selected rounding direction.
*/
function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = sqrt(a);
return result + (unsignedRoundsUp(rounding) && result * result < a ? 1 : 0);
}
}
/**
* @dev Return the log in base 2 of a positive value rounded towards zero.
* Returns 0 if given 0.
*/
function log2(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 128;
}
if (value >> 64 > 0) {
value >>= 64;
result += 64;
}
if (value >> 32 > 0) {
value >>= 32;
result += 32;
}
if (value >> 16 > 0) {
value >>= 16;
result += 16;
}
if (value >> 8 > 0) {
value >>= 8;
result += 8;
}
if (value >> 4 > 0) {
value >>= 4;
result += 4;
}
if (value >> 2 > 0) {
value >>= 2;
result += 2;
}
if (value >> 1 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 2, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log2(value);
return result + (unsignedRoundsUp(rounding) && 1 << result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 10 of a positive value rounded towards zero.
* Returns 0 if given 0.
*/
function log10(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >= 10 ** 64) {
value /= 10 ** 64;
result += 64;
}
if (value >= 10 ** 32) {
value /= 10 ** 32;
result += 32;
}
if (value >= 10 ** 16) {
value /= 10 ** 16;
result += 16;
}
if (value >= 10 ** 8) {
value /= 10 ** 8;
result += 8;
}
if (value >= 10 ** 4) {
value /= 10 ** 4;
result += 4;
}
if (value >= 10 ** 2) {
value /= 10 ** 2;
result += 2;
}
if (value >= 10 ** 1) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 10, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log10(value);
return result + (unsignedRoundsUp(rounding) && 10 ** result < value ? 1 : 0);
}
}
/**
* @dev Return the log in base 256 of a positive value rounded towards zero.
* Returns 0 if given 0.
*
* Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
*/
function log256(uint256 value) internal pure returns (uint256) {
uint256 result = 0;
unchecked {
if (value >> 128 > 0) {
value >>= 128;
result += 16;
}
if (value >> 64 > 0) {
value >>= 64;
result += 8;
}
if (value >> 32 > 0) {
value >>= 32;
result += 4;
}
if (value >> 16 > 0) {
value >>= 16;
result += 2;
}
if (value >> 8 > 0) {
result += 1;
}
}
return result;
}
/**
* @dev Return the log in base 256, following the selected rounding direction, of a positive value.
* Returns 0 if given 0.
*/
function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
unchecked {
uint256 result = log256(value);
return result + (unsignedRoundsUp(rounding) && 1 << (result << 3) < value ? 1 : 0);
}
}
/**
* @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers.
*/
function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) {
return uint8(rounding) % 2 == 1;
}
}
// lib/openzeppelin-contracts/contracts/utils/math/SignedMath.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/math/SignedMath.sol)
/**
* @dev Standard signed math utilities missing in the Solidity language.
*/
library SignedMath {
/**
* @dev Returns the largest of two signed numbers.
*/
function max(int256 a, int256 b) internal pure returns (int256) {
return a > b ? a : b;
}
/**
* @dev Returns the smallest of two signed numbers.
*/
function min(int256 a, int256 b) internal pure returns (int256) {
return a < b ? a : b;
}
/**
* @dev Returns the average of two signed numbers without overflow.
* The result is rounded towards zero.
*/
function average(int256 a, int256 b) internal pure returns (int256) {
// Formula from the book "Hacker's Delight"
int256 x = (a & b) + ((a ^ b) >> 1);
return x + (int256(uint256(x) >> 255) & (a ^ b));
}
/**
* @dev Returns the absolute unsigned value of a signed value.
*/
function abs(int256 n) internal pure returns (uint256) {
unchecked {
// must be unchecked in order to support `n = type(int256).min`
return uint256(n >= 0 ? n : -n);
}
}
}
// lib/openzeppelin-contracts/contracts/utils/StorageSlot.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/StorageSlot.sol)
// This file was procedurally generated from scripts/generate/templates/StorageSlot.js.
/**
* @dev Library for reading and writing primitive types to specific storage slots.
*
* Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.
* This library helps with reading and writing to such slots without the need for inline assembly.
*
* The functions in this library return Slot structs that contain a `value` member that can be used to read or write.
*
* Example usage to set ERC1967 implementation slot:
* ```solidity
* contract ERC1967 {
* bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
*
* function _getImplementation() internal view returns (address) {
* return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;
* }
*
* function _setImplementation(address newImplementation) internal {
* require(newImplementation.code.length > 0);
* StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;
* }
* }
* ```
*/
library StorageSlot {
struct AddressSlot {
address value;
}
struct BooleanSlot {
bool value;
}
struct Bytes32Slot {
bytes32 value;
}
struct Uint256Slot {
uint256 value;
}
struct StringSlot {
string value;
}
struct BytesSlot {
bytes value;
}
/**
* @dev Returns an `AddressSlot` with member `value` located at `slot`.
*/
function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BooleanSlot` with member `value` located at `slot`.
*/
function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Bytes32Slot` with member `value` located at `slot`.
*/
function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `Uint256Slot` with member `value` located at `slot`.
*/
function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` with member `value` located at `slot`.
*/
function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `StringSlot` representation of the string storage pointer `store`.
*/
function getStringSlot(string storage store) internal pure returns (StringSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
/**
* @dev Returns an `BytesSlot` with member `value` located at `slot`.
*/
function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := slot
}
}
/**
* @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`.
*/
function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) {
/// @solidity memory-safe-assembly
assembly {
r.slot := store.slot
}
}
}
// lib/openzeppelin-contracts/contracts/interfaces/draft-IERC1822.sol
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC1822.sol)
/**
* @dev ERC1822: Universal Upgradeable Proxy Standard (UUPS) documents a method for upgradeability through a simplified
* proxy whose upgrades are fully controlled by the current implementation.
*/
interface IERC1822Proxiable {
/**
* @dev Returns the storage slot that the proxiable contract assumes is being used to store the implementation
* address.
*
* IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks
* bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this
* function revert if invoked through a proxy.
*/
function proxiableUUID() external view returns (bytes32);
}
// lib/openzeppelin-contracts/contracts/interfaces/draft-IERC6093.sol
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/draft-IERC6093.sol)
/**
* @dev Standard ERC20 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC20 tokens.
*/
interface IERC20Errors {
/**
* @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param balance Current balance for the interacting account.
* @param needed Minimum amount required to perform a transfer.
*/
error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC20InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC20InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers.
* @param spender Address that may be allowed to operate on tokens without being their owner.
* @param allowance Amount of tokens a `spender` is allowed to operate with.
* @param needed Minimum amount required to perform a transfer.
*/
error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC20InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `spender` to be approved. Used in approvals.
* @param spender Address that may be allowed to operate on tokens without being their owner.
*/
error ERC20InvalidSpender(address spender);
}
/**
* @dev Standard ERC721 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC721 tokens.
*/
interface IERC721Errors {
/**
* @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in EIP-20.
* Used in balance queries.
* @param owner Address of the current owner of a token.
*/
error ERC721InvalidOwner(address owner);
/**
* @dev Indicates a `tokenId` whose `owner` is the zero address.
* @param tokenId Identifier number of a token.
*/
error ERC721NonexistentToken(uint256 tokenId);
/**
* @dev Indicates an error related to the ownership over a particular token. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param tokenId Identifier number of a token.
* @param owner Address of the current owner of a token.
*/
error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC721InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC721InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `operator`’s approval. Used in transfers.
* @param operator Address that may be allowed to operate on tokens without being their owner.
* @param tokenId Identifier number of a token.
*/
error ERC721InsufficientApproval(address operator, uint256 tokenId);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC721InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `operator` to be approved. Used in approvals.
* @param operator Address that may be allowed to operate on tokens without being their owner.
*/
error ERC721InvalidOperator(address operator);
}
/**
* @dev Standard ERC1155 Errors
* Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC1155 tokens.
*/
interface IERC1155Errors {
/**
* @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
* @param balance Current balance for the interacting account.
* @param needed Minimum amount required to perform a transfer.
* @param tokenId Identifier number of a token.
*/
error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId);
/**
* @dev Indicates a failure with the token `sender`. Used in transfers.
* @param sender Address whose tokens are being transferred.
*/
error ERC1155InvalidSender(address sender);
/**
* @dev Indicates a failure with the token `receiver`. Used in transfers.
* @param receiver Address to which tokens are being transferred.
*/
error ERC1155InvalidReceiver(address receiver);
/**
* @dev Indicates a failure with the `operator`’s approval. Used in transfers.
* @param operator Address that may be allowed to operate on tokens without being their owner.
* @param owner Address of the current owner of a token.
*/
error ERC1155MissingApprovalForAll(address operator, address owner);
/**
* @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
* @param approver Address initiating an approval operation.
*/
error ERC1155InvalidApprover(address approver);
/**
* @dev Indicates a failure with the `operator` to be approved. Used in approvals.
* @param operator Address that may be allowed to operate on tokens without being their owner.
*/
error ERC1155InvalidOperator(address operator);
/**
* @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation.
* Used in batch transfers.
* @param idsLength Length of the array of token identifiers
* @param valuesLength Length of the array of token amounts
*/
error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength);
}
// lib/openzeppelin-contracts-upgradeable/contracts/utils/ContextUpgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/Context.sol)
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract ContextUpgradeable is Initializable {
function __Context_init() internal onlyInitializing {
}
function __Context_init_unchained() internal onlyInitializing {
}
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
// lib/openzeppelin-contracts/contracts/token/ERC721/IERC721.sol
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/IERC721.sol)
/**
* @dev Required interface of an ERC721 compliant contract.
*/
interface IERC721 is IERC165 {
/**
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
*/
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
*/
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
*/
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
/**
* @dev Returns the number of tokens in ``owner``'s account.
*/
function balanceOf(address owner) external view returns (uint256 balance);
/**
* @dev Returns the owner of the `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function ownerOf(uint256 tokenId) external view returns (address owner);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon
* a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(address from, address to, uint256 tokenId, bytes calldata data) external;
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must have been allowed to move this token by either {approve} or
* {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon
* a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(address from, address to, uint256 tokenId) external;
/**
* @dev Transfers `tokenId` token from `from` to `to`.
*
* WARNING: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721
* or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
* understand this adds an external call which potentially creates a reentrancy vulnerability.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
*
* Emits a {Transfer} event.
*/
function transferFrom(address from, address to, uint256 tokenId) external;
/**
* @dev Gives permission to `to` to transfer `tokenId` token to another account.
* The approval is cleared when the token is transferred.
*
* Only a single account can be approved at a time, so approving the zero address clears previous approvals.
*
* Requirements:
*
* - The caller must own the token or be an approved operator.
* - `tokenId` must exist.
*
* Emits an {Approval} event.
*/
function approve(address to, uint256 tokenId) external;
/**
* @dev Approve or remove `operator` as an operator for the caller.
* Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
*
* Requirements:
*
* - The `operator` cannot be the address zero.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool approved) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
*
* See {setApprovalForAll}
*/
function isApprovedForAll(address owner, address operator) external view returns (bool);
}
// lib/openzeppelin-contracts-upgradeable/contracts/utils/ReentrancyGuardUpgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/ReentrancyGuard.sol)
/**
* @dev Contract module that helps prevent reentrant calls to a function.
*
* Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
* available, which can be applied to functions to make sure there are no nested
* (reentrant) calls to them.
*
* Note that because there is a single `nonReentrant` guard, functions marked as
* `nonReentrant` may not call one another. This can be worked around by making
* those functions `private`, and then adding `external` `nonReentrant` entry
* points to them.
*
* TIP: If you would like to learn more about reentrancy and alternative ways
* to protect against it, check out our blog post
* https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
*/
abstract contract ReentrancyGuardUpgradeable is Initializable {
// Booleans are more expensive than uint256 or any type that takes up a full
// word because each write operation emits an extra SLOAD to first read the
// slot's contents, replace the bits taken up by the boolean, and then write
// back. This is the compiler's defense against contract upgrades and
// pointer aliasing, and it cannot be disabled.
// The values being non-zero value makes deployment a bit more expensive,
// but in exchange the refund on every call to nonReentrant will be lower in
// amount. Since refunds are capped to a percentage of the total
// transaction's gas, it is best to keep them low in cases like this one, to
// increase the likelihood of the full refund coming into effect.
uint256 private constant NOT_ENTERED = 1;
uint256 private constant ENTERED = 2;
/// @custom:storage-location erc7201:openzeppelin.storage.ReentrancyGuard
struct ReentrancyGuardStorage {
uint256 _status;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.ReentrancyGuard")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant ReentrancyGuardStorageLocation = 0x9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f00;
function _getReentrancyGuardStorage() private pure returns (ReentrancyGuardStorage storage $) {
assembly {
$.slot := ReentrancyGuardStorageLocation
}
}
/**
* @dev Unauthorized reentrant call.
*/
error ReentrancyGuardReentrantCall();
function __ReentrancyGuard_init() internal onlyInitializing {
__ReentrancyGuard_init_unchained();
}
function __ReentrancyGuard_init_unchained() internal onlyInitializing {
ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();
$._status = NOT_ENTERED;
}
/**
* @dev Prevents a contract from calling itself, directly or indirectly.
* Calling a `nonReentrant` function from another `nonReentrant`
* function is not supported. It is possible to prevent this from happening
* by making the `nonReentrant` function external, and making it call a
* `private` function that does the actual work.
*/
modifier nonReentrant() {
_nonReentrantBefore();
_;
_nonReentrantAfter();
}
function _nonReentrantBefore() private {
ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();
// On the first call to nonReentrant, _status will be NOT_ENTERED
if ($._status == ENTERED) {
revert ReentrancyGuardReentrantCall();
}
// Any calls to nonReentrant after this point will fail
$._status = ENTERED;
}
function _nonReentrantAfter() private {
ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();
// By storing the original value once again, a refund is triggered (see
// https://eips.ethereum.org/EIPS/eip-2200)
$._status = NOT_ENTERED;
}
/**
* @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a
* `nonReentrant` function in the call stack.
*/
function _reentrancyGuardEntered() internal view returns (bool) {
ReentrancyGuardStorage storage $ = _getReentrancyGuardStorage();
return $._status == ENTERED;
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/utils/introspection/ERC165Upgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.sol)
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*/
abstract contract ERC165Upgradeable is Initializable, IERC165 {
function __ERC165_init() internal onlyInitializing {
}
function __ERC165_init_unchained() internal onlyInitializing {
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}
// lib/openzeppelin-contracts/contracts/token/ERC721/extensions/IERC721Metadata.sol
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/extensions/IERC721Metadata.sol)
/**
* @title ERC-721 Non-Fungible Token Standard, optional metadata extension
* @dev See https://eips.ethereum.org/EIPS/eip-721
*/
interface IERC721Metadata is IERC721 {
/**
* @dev Returns the token collection name.
*/
function name() external view returns (string memory);
/**
* @dev Returns the token collection symbol.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
*/
function tokenURI(uint256 tokenId) external view returns (string memory);
}
// lib/openzeppelin-contracts/contracts/utils/Strings.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/Strings.sol)
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant HEX_DIGITS = "0123456789abcdef";
uint8 private constant ADDRESS_LENGTH = 20;
/**
* @dev The `value` string doesn't fit in the specified `length`.
*/
error StringsInsufficientHexLength(uint256 value, uint256 length);
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
unchecked {
uint256 length = Math.log10(value) + 1;
string memory buffer = new string(length);
uint256 ptr;
/// @solidity memory-safe-assembly
assembly {
ptr := add(buffer, add(32, length))
}
while (true) {
ptr--;
/// @solidity memory-safe-assembly
assembly {
mstore8(ptr, byte(mod(value, 10), HEX_DIGITS))
}
value /= 10;
if (value == 0) break;
}
return buffer;
}
}
/**
* @dev Converts a `int256` to its ASCII `string` decimal representation.
*/
function toStringSigned(int256 value) internal pure returns (string memory) {
return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value)));
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
unchecked {
return toHexString(value, Math.log256(value) + 1);
}
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
uint256 localValue = value;
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = HEX_DIGITS[localValue & 0xf];
localValue >>= 4;
}
if (localValue != 0) {
revert StringsInsufficientHexLength(value, length);
}
return string(buffer);
}
/**
* @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal
* representation.
*/
function toHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), ADDRESS_LENGTH);
}
/**
* @dev Returns true if the two strings are equal.
*/
function equal(string memory a, string memory b) internal pure returns (bool) {
return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b));
}
}
// lib/openzeppelin-contracts/contracts/proxy/ERC1967/ERC1967Utils.sol
// OpenZeppelin Contracts (last updated v5.0.0) (proxy/ERC1967/ERC1967Utils.sol)
/**
* @dev This abstract contract provides getters and event emitting update functions for
* https://eips.ethereum.org/EIPS/eip-1967[EIP1967] slots.
*/
library ERC1967Utils {
// We re-declare ERC-1967 events here because they can't be used directly from IERC1967.
// This will be fixed in Solidity 0.8.21. At that point we should remove these events.
/**
* @dev Emitted when the implementation is upgraded.
*/
event Upgraded(address indexed implementation);
/**
* @dev Emitted when the admin account has changed.
*/
event AdminChanged(address previousAdmin, address newAdmin);
/**
* @dev Emitted when the beacon is changed.
*/
event BeaconUpgraded(address indexed beacon);
/**
* @dev Storage slot with the address of the current implementation.
* This is the keccak-256 hash of "eip1967.proxy.implementation" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;
/**
* @dev The `implementation` of the proxy is invalid.
*/
error ERC1967InvalidImplementation(address implementation);
/**
* @dev The `admin` of the proxy is invalid.
*/
error ERC1967InvalidAdmin(address admin);
/**
* @dev The `beacon` of the proxy is invalid.
*/
error ERC1967InvalidBeacon(address beacon);
/**
* @dev An upgrade function sees `msg.value > 0` that may be lost.
*/
error ERC1967NonPayable();
/**
* @dev Returns the current implementation address.
*/
function getImplementation() internal view returns (address) {
return StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value;
}
/**
* @dev Stores a new address in the EIP1967 implementation slot.
*/
function _setImplementation(address newImplementation) private {
if (newImplementation.code.length == 0) {
revert ERC1967InvalidImplementation(newImplementation);
}
StorageSlot.getAddressSlot(IMPLEMENTATION_SLOT).value = newImplementation;
}
/**
* @dev Performs implementation upgrade with additional setup call if data is nonempty.
* This function is payable only if the setup call is performed, otherwise `msg.value` is rejected
* to avoid stuck value in the contract.
*
* Emits an {IERC1967-Upgraded} event.
*/
function upgradeToAndCall(address newImplementation, bytes memory data) internal {
_setImplementation(newImplementation);
emit Upgraded(newImplementation);
if (data.length > 0) {
Address.functionDelegateCall(newImplementation, data);
} else {
_checkNonPayable();
}
}
/**
* @dev Storage slot with the admin of the contract.
* This is the keccak-256 hash of "eip1967.proxy.admin" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant ADMIN_SLOT = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103;
/**
* @dev Returns the current admin.
*
* TIP: To get this value clients can read directly from the storage slot shown below (specified by EIP1967) using
* the https://eth.wiki/json-rpc/API#eth_getstorageat[`eth_getStorageAt`] RPC call.
* `0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103`
*/
function getAdmin() internal view returns (address) {
return StorageSlot.getAddressSlot(ADMIN_SLOT).value;
}
/**
* @dev Stores a new address in the EIP1967 admin slot.
*/
function _setAdmin(address newAdmin) private {
if (newAdmin == address(0)) {
revert ERC1967InvalidAdmin(address(0));
}
StorageSlot.getAddressSlot(ADMIN_SLOT).value = newAdmin;
}
/**
* @dev Changes the admin of the proxy.
*
* Emits an {IERC1967-AdminChanged} event.
*/
function changeAdmin(address newAdmin) internal {
emit AdminChanged(getAdmin(), newAdmin);
_setAdmin(newAdmin);
}
/**
* @dev The storage slot of the UpgradeableBeacon contract which defines the implementation for this proxy.
* This is the keccak-256 hash of "eip1967.proxy.beacon" subtracted by 1.
*/
// solhint-disable-next-line private-vars-leading-underscore
bytes32 internal constant BEACON_SLOT = 0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50;
/**
* @dev Returns the current beacon.
*/
function getBeacon() internal view returns (address) {
return StorageSlot.getAddressSlot(BEACON_SLOT).value;
}
/**
* @dev Stores a new beacon in the EIP1967 beacon slot.
*/
function _setBeacon(address newBeacon) private {
if (newBeacon.code.length == 0) {
revert ERC1967InvalidBeacon(newBeacon);
}
StorageSlot.getAddressSlot(BEACON_SLOT).value = newBeacon;
address beaconImplementation = IBeacon(newBeacon).implementation();
if (beaconImplementation.code.length == 0) {
revert ERC1967InvalidImplementation(beaconImplementation);
}
}
/**
* @dev Change the beacon and trigger a setup call if data is nonempty.
* This function is payable only if the setup call is performed, otherwise `msg.value` is rejected
* to avoid stuck value in the contract.
*
* Emits an {IERC1967-BeaconUpgraded} event.
*
* CAUTION: Invoking this function has no effect on an instance of {BeaconProxy} since v5, since
* it uses an immutable beacon without looking at the value of the ERC-1967 beacon slot for
* efficiency.
*/
function upgradeBeaconToAndCall(address newBeacon, bytes memory data) internal {
_setBeacon(newBeacon);
emit BeaconUpgraded(newBeacon);
if (data.length > 0) {
Address.functionDelegateCall(IBeacon(newBeacon).implementation(), data);
} else {
_checkNonPayable();
}
}
/**
* @dev Reverts if `msg.value` is not zero. It can be used to avoid `msg.value` stuck in the contract
* if an upgrade doesn't perform an initialization call.
*/
function _checkNonPayable() private {
if (msg.value > 0) {
revert ERC1967NonPayable();
}
}
}
// lib/openzeppelin-contracts/contracts/utils/cryptography/MessageHashUtils.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/MessageHashUtils.sol)
/**
* @dev Signature message hash utilities for producing digests to be consumed by {ECDSA} recovery or signing.
*
* The library provides methods for generating a hash of a message that conforms to the
* https://eips.ethereum.org/EIPS/eip-191[EIP 191] and https://eips.ethereum.org/EIPS/eip-712[EIP 712]
* specifications.
*/
library MessageHashUtils {
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x45` (`personal_sign` messages).
*
* The digest is calculated by prefixing a bytes32 `messageHash` with
* `"\x19Ethereum Signed Message:\n32"` and hashing the result. It corresponds with the
* hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method.
*
* NOTE: The `messageHash` parameter is intended to be the result of hashing a raw message with
* keccak256, although any bytes32 value can be safely used because the final digest will
* be re-hashed.
*
* See {ECDSA-recover}.
*/
function toEthSignedMessageHash(bytes32 messageHash) internal pure returns (bytes32 digest) {
/// @solidity memory-safe-assembly
assembly {
mstore(0x00, "\x19Ethereum Signed Message:\n32") // 32 is the bytes-length of messageHash
mstore(0x1c, messageHash) // 0x1c (28) is the length of the prefix
digest := keccak256(0x00, 0x3c) // 0x3c is the length of the prefix (0x1c) + messageHash (0x20)
}
}
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x45` (`personal_sign` messages).
*
* The digest is calculated by prefixing an arbitrary `message` with
* `"\x19Ethereum Signed Message:\n" + len(message)` and hashing the result. It corresponds with the
* hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method.
*
* See {ECDSA-recover}.
*/
function toEthSignedMessageHash(bytes memory message) internal pure returns (bytes32) {
return
keccak256(bytes.concat("\x19Ethereum Signed Message:\n", bytes(Strings.toString(message.length)), message));
}
/**
* @dev Returns the keccak256 digest of an EIP-191 signed data with version
* `0x00` (data with intended validator).
*
* The digest is calculated by prefixing an arbitrary `data` with `"\x19\x00"` and the intended
* `validator` address. Then hashing the result.
*
* See {ECDSA-recover}.
*/
function toDataWithIntendedValidatorHash(address validator, bytes memory data) internal pure returns (bytes32) {
return keccak256(abi.encodePacked(hex"19_00", validator, data));
}
/**
* @dev Returns the keccak256 digest of an EIP-712 typed data (EIP-191 version `0x01`).
*
* The digest is calculated from a `domainSeparator` and a `structHash`, by prefixing them with
* `\x19\x01` and hashing the result. It corresponds to the hash signed by the
* https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] JSON-RPC method as part of EIP-712.
*
* See {ECDSA-recover}.
*/
function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 digest) {
/// @solidity memory-safe-assembly
assembly {
let ptr := mload(0x40)
mstore(ptr, hex"19_01")
mstore(add(ptr, 0x02), domainSeparator)
mstore(add(ptr, 0x22), structHash)
digest := keccak256(ptr, 0x42)
}
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/access/AccessControlUpgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (access/AccessControl.sol)
/**
* @dev Contract module that allows children to implement role-based access
* control mechanisms. This is a lightweight version that doesn't allow enumerating role
* members except through off-chain means by accessing the contract event logs. Some
* applications may benefit from on-chain enumerability, for those cases see
* {AccessControlEnumerable}.
*
* Roles are referred to by their `bytes32` identifier. These should be exposed
* in the external API and be unique. The best way to achieve this is by
* using `public constant` hash digests:
*
* ```solidity
* bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
* ```
*
* Roles can be used to represent a set of permissions. To restrict access to a
* function call, use {hasRole}:
*
* ```solidity
* function foo() public {
* require(hasRole(MY_ROLE, msg.sender));
* ...
* }
* ```
*
* Roles can be granted and revoked dynamically via the {grantRole} and
* {revokeRole} functions. Each role has an associated admin role, and only
* accounts that have a role's admin role can call {grantRole} and {revokeRole}.
*
* By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
* that only accounts with this role will be able to grant or revoke other
* roles. More complex role relationships can be created by using
* {_setRoleAdmin}.
*
* WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
* grant and revoke this role. Extra precautions should be taken to secure
* accounts that have been granted it. We recommend using {AccessControlDefaultAdminRules}
* to enforce additional security measures for this role.
*/
abstract contract AccessControlUpgradeable is Initializable, ContextUpgradeable, IAccessControl, ERC165Upgradeable {
struct RoleData {
mapping(address account => bool) hasRole;
bytes32 adminRole;
}
bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;
/// @custom:storage-location erc7201:openzeppelin.storage.AccessControl
struct AccessControlStorage {
mapping(bytes32 role => RoleData) _roles;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.AccessControl")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant AccessControlStorageLocation = 0x02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800;
function _getAccessControlStorage() private pure returns (AccessControlStorage storage $) {
assembly {
$.slot := AccessControlStorageLocation
}
}
/**
* @dev Modifier that checks that an account has a specific role. Reverts
* with an {AccessControlUnauthorizedAccount} error including the required role.
*/
modifier onlyRole(bytes32 role) {
_checkRole(role);
_;
}
function __AccessControl_init() internal onlyInitializing {
}
function __AccessControl_init_unchained() internal onlyInitializing {
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
}
/**
* @dev Returns `true` if `account` has been granted `role`.
*/
function hasRole(bytes32 role, address account) public view virtual returns (bool) {
AccessControlStorage storage $ = _getAccessControlStorage();
return $._roles[role].hasRole[account];
}
/**
* @dev Reverts with an {AccessControlUnauthorizedAccount} error if `_msgSender()`
* is missing `role`. Overriding this function changes the behavior of the {onlyRole} modifier.
*/
function _checkRole(bytes32 role) internal view virtual {
_checkRole(role, _msgSender());
}
/**
* @dev Reverts with an {AccessControlUnauthorizedAccount} error if `account`
* is missing `role`.
*/
function _checkRole(bytes32 role, address account) internal view virtual {
if (!hasRole(role, account)) {
revert AccessControlUnauthorizedAccount(account, role);
}
}
/**
* @dev Returns the admin role that controls `role`. See {grantRole} and
* {revokeRole}.
*
* To change a role's admin, use {_setRoleAdmin}.
*/
function getRoleAdmin(bytes32 role) public view virtual returns (bytes32) {
AccessControlStorage storage $ = _getAccessControlStorage();
return $._roles[role].adminRole;
}
/**
* @dev Grants `role` to `account`.
*
* If `account` had not been already granted `role`, emits a {RoleGranted}
* event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleGranted} event.
*/
function grantRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {
_grantRole(role, account);
}
/**
* @dev Revokes `role` from `account`.
*
* If `account` had been granted `role`, emits a {RoleRevoked} event.
*
* Requirements:
*
* - the caller must have ``role``'s admin role.
*
* May emit a {RoleRevoked} event.
*/
function revokeRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) {
_revokeRole(role, account);
}
/**
* @dev Revokes `role` from the calling account.
*
* Roles are often managed via {grantRole} and {revokeRole}: this function's
* purpose is to provide a mechanism for accounts to lose their privileges
* if they are compromised (such as when a trusted device is misplaced).
*
* If the calling account had been revoked `role`, emits a {RoleRevoked}
* event.
*
* Requirements:
*
* - the caller must be `callerConfirmation`.
*
* May emit a {RoleRevoked} event.
*/
function renounceRole(bytes32 role, address callerConfirmation) public virtual {
if (callerConfirmation != _msgSender()) {
revert AccessControlBadConfirmation();
}
_revokeRole(role, callerConfirmation);
}
/**
* @dev Sets `adminRole` as ``role``'s admin role.
*
* Emits a {RoleAdminChanged} event.
*/
function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
AccessControlStorage storage $ = _getAccessControlStorage();
bytes32 previousAdminRole = getRoleAdmin(role);
$._roles[role].adminRole = adminRole;
emit RoleAdminChanged(role, previousAdminRole, adminRole);
}
/**
* @dev Attempts to grant `role` to `account` and returns a boolean indicating if `role` was granted.
*
* Internal function without access restriction.
*
* May emit a {RoleGranted} event.
*/
function _grantRole(bytes32 role, address account) internal virtual returns (bool) {
AccessControlStorage storage $ = _getAccessControlStorage();
if (!hasRole(role, account)) {
$._roles[role].hasRole[account] = true;
emit RoleGranted(role, account, _msgSender());
return true;
} else {
return false;
}
}
/**
* @dev Attempts to revoke `role` to `account` and returns a boolean indicating if `role` was revoked.
*
* Internal function without access restriction.
*
* May emit a {RoleRevoked} event.
*/
function _revokeRole(bytes32 role, address account) internal virtual returns (bool) {
AccessControlStorage storage $ = _getAccessControlStorage();
if (hasRole(role, account)) {
$._roles[role].hasRole[account] = false;
emit RoleRevoked(role, account, _msgSender());
return true;
} else {
return false;
}
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/utils/cryptography/EIP712Upgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/EIP712.sol)
/**
* @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
*
* The encoding scheme specified in the EIP requires a domain separator and a hash of the typed structured data, whose
* encoding is very generic and therefore its implementation in Solidity is not feasible, thus this contract
* does not implement the encoding itself. Protocols need to implement the type-specific encoding they need in order to
* produce the hash of their typed data using a combination of `abi.encode` and `keccak256`.
*
* This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
* scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
* ({_hashTypedDataV4}).
*
* The implementation of the domain separator was designed to be as efficient as possible while still properly updating
* the chain id to protect against replay attacks on an eventual fork of the chain.
*
* NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
* https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
*
* NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain
* separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the
* separator from the immutable values, which is cheaper than accessing a cached version in cold storage.
*/
abstract contract EIP712Upgradeable is Initializable, IERC5267 {
bytes32 private constant TYPE_HASH =
keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)");
/// @custom:storage-location erc7201:openzeppelin.storage.EIP712
struct EIP712Storage {
/// @custom:oz-renamed-from _HASHED_NAME
bytes32 _hashedName;
/// @custom:oz-renamed-from _HASHED_VERSION
bytes32 _hashedVersion;
string _name;
string _version;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.EIP712")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant EIP712StorageLocation = 0xa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d100;
function _getEIP712Storage() private pure returns (EIP712Storage storage $) {
assembly {
$.slot := EIP712StorageLocation
}
}
/**
* @dev Initializes the domain separator and parameter caches.
*
* The meaning of `name` and `version` is specified in
* https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:
*
* - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.
* - `version`: the current major version of the signing domain.
*
* NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart
* contract upgrade].
*/
function __EIP712_init(string memory name, string memory version) internal onlyInitializing {
__EIP712_init_unchained(name, version);
}
function __EIP712_init_unchained(string memory name, string memory version) internal onlyInitializing {
EIP712Storage storage $ = _getEIP712Storage();
$._name = name;
$._version = version;
// Reset prior values in storage if upgrading
$._hashedName = 0;
$._hashedVersion = 0;
}
/**
* @dev Returns the domain separator for the current chain.
*/
function _domainSeparatorV4() internal view returns (bytes32) {
return _buildDomainSeparator();
}
function _buildDomainSeparator() private view returns (bytes32) {
return keccak256(abi.encode(TYPE_HASH, _EIP712NameHash(), _EIP712VersionHash(), block.chainid, address(this)));
}
/**
* @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this
* function returns the hash of the fully encoded EIP712 message for this domain.
*
* This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:
*
* ```solidity
* bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(
* keccak256("Mail(address to,string contents)"),
* mailTo,
* keccak256(bytes(mailContents))
* )));
* address signer = ECDSA.recover(digest, signature);
* ```
*/
function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {
return MessageHashUtils.toTypedDataHash(_domainSeparatorV4(), structHash);
}
/**
* @dev See {IERC-5267}.
*/
function eip712Domain()
public
view
virtual
returns (
bytes1 fields,
string memory name,
string memory version,
uint256 chainId,
address verifyingContract,
bytes32 salt,
uint256[] memory extensions
)
{
EIP712Storage storage $ = _getEIP712Storage();
// If the hashed name and version in storage are non-zero, the contract hasn't been properly initialized
// and the EIP712 domain is not reliable, as it will be missing name and version.
require($._hashedName == 0 && $._hashedVersion == 0, "EIP712: Uninitialized");
return (
hex"0f", // 01111
_EIP712Name(),
_EIP712Version(),
block.chainid,
address(this),
bytes32(0),
new uint256[](0)
);
}
/**
* @dev The name parameter for the EIP712 domain.
*
* NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs
* are a concern.
*/
function _EIP712Name() internal view virtual returns (string memory) {
EIP712Storage storage $ = _getEIP712Storage();
return $._name;
}
/**
* @dev The version parameter for the EIP712 domain.
*
* NOTE: This function reads from storage by default, but can be redefined to return a constant value if gas costs
* are a concern.
*/
function _EIP712Version() internal view virtual returns (string memory) {
EIP712Storage storage $ = _getEIP712Storage();
return $._version;
}
/**
* @dev The hash of the name parameter for the EIP712 domain.
*
* NOTE: In previous versions this function was virtual. In this version you should override `_EIP712Name` instead.
*/
function _EIP712NameHash() internal view returns (bytes32) {
EIP712Storage storage $ = _getEIP712Storage();
string memory name = _EIP712Name();
if (bytes(name).length > 0) {
return keccak256(bytes(name));
} else {
// If the name is empty, the contract may have been upgraded without initializing the new storage.
// We return the name hash in storage if non-zero, otherwise we assume the name is empty by design.
bytes32 hashedName = $._hashedName;
if (hashedName != 0) {
return hashedName;
} else {
return keccak256("");
}
}
}
/**
* @dev The hash of the version parameter for the EIP712 domain.
*
* NOTE: In previous versions this function was virtual. In this version you should override `_EIP712Version` instead.
*/
function _EIP712VersionHash() internal view returns (bytes32) {
EIP712Storage storage $ = _getEIP712Storage();
string memory version = _EIP712Version();
if (bytes(version).length > 0) {
return keccak256(bytes(version));
} else {
// If the version is empty, the contract may have been upgraded without initializing the new storage.
// We return the version hash in storage if non-zero, otherwise we assume the version is empty by design.
bytes32 hashedVersion = $._hashedVersion;
if (hashedVersion != 0) {
return hashedVersion;
} else {
return keccak256("");
}
}
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/UUPSUpgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (proxy/utils/UUPSUpgradeable.sol)
/**
* @dev An upgradeability mechanism designed for UUPS proxies. The functions included here can perform an upgrade of an
* {ERC1967Proxy}, when this contract is set as the implementation behind such a proxy.
*
* A security mechanism ensures that an upgrade does not turn off upgradeability accidentally, although this risk is
* reinstated if the upgrade retains upgradeability but removes the security mechanism, e.g. by replacing
* `UUPSUpgradeable` with a custom implementation of upgrades.
*
* The {_authorizeUpgrade} function must be overridden to include access restriction to the upgrade mechanism.
*/
abstract contract UUPSUpgradeable is Initializable, IERC1822Proxiable {
/// @custom:oz-upgrades-unsafe-allow state-variable-immutable
address private immutable __self = address(this);
/**
* @dev The version of the upgrade interface of the contract. If this getter is missing, both `upgradeTo(address)`
* and `upgradeToAndCall(address,bytes)` are present, and `upgradeTo` must be used if no function should be called,
* while `upgradeToAndCall` will invoke the `receive` function if the second argument is the empty byte string.
* If the getter returns `"5.0.0"`, only `upgradeToAndCall(address,bytes)` is present, and the second argument must
* be the empty byte string if no function should be called, making it impossible to invoke the `receive` function
* during an upgrade.
*/
string public constant UPGRADE_INTERFACE_VERSION = "5.0.0";
/**
* @dev The call is from an unauthorized context.
*/
error UUPSUnauthorizedCallContext();
/**
* @dev The storage `slot` is unsupported as a UUID.
*/
error UUPSUnsupportedProxiableUUID(bytes32 slot);
/**
* @dev Check that the execution is being performed through a delegatecall call and that the execution context is
* a proxy contract with an implementation (as defined in ERC1967) pointing to self. This should only be the case
* for UUPS and transparent proxies that are using the current contract as their implementation. Execution of a
* function through ERC1167 minimal proxies (clones) would not normally pass this test, but is not guaranteed to
* fail.
*/
modifier onlyProxy() {
_checkProxy();
_;
}
/**
* @dev Check that the execution is not being performed through a delegate call. This allows a function to be
* callable on the implementing contract but not through proxies.
*/
modifier notDelegated() {
_checkNotDelegated();
_;
}
function __UUPSUpgradeable_init() internal onlyInitializing {
}
function __UUPSUpgradeable_init_unchained() internal onlyInitializing {
}
/**
* @dev Implementation of the ERC1822 {proxiableUUID} function. This returns the storage slot used by the
* implementation. It is used to validate the implementation's compatibility when performing an upgrade.
*
* IMPORTANT: A proxy pointing at a proxiable contract should not be considered proxiable itself, because this risks
* bricking a proxy that upgrades to it, by delegating to itself until out of gas. Thus it is critical that this
* function revert if invoked through a proxy. This is guaranteed by the `notDelegated` modifier.
*/
function proxiableUUID() external view virtual notDelegated returns (bytes32) {
return ERC1967Utils.IMPLEMENTATION_SLOT;
}
/**
* @dev Upgrade the implementation of the proxy to `newImplementation`, and subsequently execute the function call
* encoded in `data`.
*
* Calls {_authorizeUpgrade}.
*
* Emits an {Upgraded} event.
*
* @custom:oz-upgrades-unsafe-allow-reachable delegatecall
*/
function upgradeToAndCall(address newImplementation, bytes memory data) public payable virtual onlyProxy {
_authorizeUpgrade(newImplementation);
_upgradeToAndCallUUPS(newImplementation, data);
}
/**
* @dev Reverts if the execution is not performed via delegatecall or the execution
* context is not of a proxy with an ERC1967-compliant implementation pointing to self.
* See {_onlyProxy}.
*/
function _checkProxy() internal view virtual {
if (
address(this) == __self || // Must be called through delegatecall
ERC1967Utils.getImplementation() != __self // Must be called through an active proxy
) {
revert UUPSUnauthorizedCallContext();
}
}
/**
* @dev Reverts if the execution is performed via delegatecall.
* See {notDelegated}.
*/
function _checkNotDelegated() internal view virtual {
if (address(this) != __self) {
// Must not be called through delegatecall
revert UUPSUnauthorizedCallContext();
}
}
/**
* @dev Function that should revert when `msg.sender` is not authorized to upgrade the contract. Called by
* {upgradeToAndCall}.
*
* Normally, this function will use an xref:access.adoc[access control] modifier such as {Ownable-onlyOwner}.
*
* ```solidity
* function _authorizeUpgrade(address) internal onlyOwner {}
* ```
*/
function _authorizeUpgrade(address newImplementation) internal virtual;
/**
* @dev Performs an implementation upgrade with a security check for UUPS proxies, and additional setup call.
*
* As a security check, {proxiableUUID} is invoked in the new implementation, and the return value
* is expected to be the implementation slot in ERC1967.
*
* Emits an {IERC1967-Upgraded} event.
*/
function _upgradeToAndCallUUPS(address newImplementation, bytes memory data) private {
try IERC1822Proxiable(newImplementation).proxiableUUID() returns (bytes32 slot) {
if (slot != ERC1967Utils.IMPLEMENTATION_SLOT) {
revert UUPSUnsupportedProxiableUUID(slot);
}
ERC1967Utils.upgradeToAndCall(newImplementation, data);
} catch {
// The implementation is not UUPS
revert ERC1967Utils.ERC1967InvalidImplementation(newImplementation);
}
}
}
// lib/openzeppelin-contracts-upgradeable/contracts/token/ERC721/ERC721Upgradeable.sol
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/ERC721.sol)
/**
* @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
* the Metadata extension, but not including the Enumerable extension, which is available separately as
* {ERC721Enumerable}.
*/
abstract contract ERC721Upgradeable is Initializable, ContextUpgradeable, ERC165Upgradeable, IERC721, IERC721Metadata, IERC721Errors {
using Strings for uint256;
/// @custom:storage-location erc7201:openzeppelin.storage.ERC721
struct ERC721Storage {
// Token name
string _name;
// Token symbol
string _symbol;
mapping(uint256 tokenId => address) _owners;
mapping(address owner => uint256) _balances;
mapping(uint256 tokenId => address) _tokenApprovals;
mapping(address owner => mapping(address operator => bool)) _operatorApprovals;
}
// keccak256(abi.encode(uint256(keccak256("openzeppelin.storage.ERC721")) - 1)) & ~bytes32(uint256(0xff))
bytes32 private constant ERC721StorageLocation = 0x80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300;
function _getERC721Storage() private pure returns (ERC721Storage storage $) {
assembly {
$.slot := ERC721StorageLocation
}
}
/**
* @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
*/
function __ERC721_init(string memory name_, string memory symbol_) internal onlyInitializing {
__ERC721_init_unchained(name_, symbol_);
}
function __ERC721_init_unchained(string memory name_, string memory symbol_) internal onlyInitializing {
ERC721Storage storage $ = _getERC721Storage();
$._name = name_;
$._symbol = symbol_;
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165Upgradeable, IERC165) returns (bool) {
return
interfaceId == type(IERC721).interfaceId ||
interfaceId == type(IERC721Metadata).interfaceId ||
super.supportsInterface(interfaceId);
}
/**
* @dev See {IERC721-balanceOf}.
*/
function balanceOf(address owner) public view virtual returns (uint256) {
ERC721Storage storage $ = _getERC721Storage();
if (owner == address(0)) {
revert ERC721InvalidOwner(address(0));
}
return $._balances[owner];
}
/**
* @dev See {IERC721-ownerOf}.
*/
function ownerOf(uint256 tokenId) public view virtual returns (address) {
return _requireOwned(tokenId);
}
/**
* @dev See {IERC721Metadata-name}.
*/
function name() public view virtual returns (string memory) {
ERC721Storage storage $ = _getERC721Storage();
return $._name;
}
/**
* @dev See {IERC721Metadata-symbol}.
*/
function symbol() public view virtual returns (string memory) {
ERC721Storage storage $ = _getERC721Storage();
return $._symbol;
}
/**
* @dev See {IERC721Metadata-tokenURI}.
*/
function tokenURI(uint256 tokenId) public view virtual returns (string memory) {
_requireOwned(tokenId);
string memory baseURI = _baseURI();
return bytes(baseURI).length > 0 ? string.concat(baseURI, tokenId.toString()) : "";
}
/**
* @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
* token will be the concatenation of the `baseURI` and the `tokenId`. Empty
* by default, can be overridden in child contracts.
*/
function _baseURI() internal view virtual returns (string memory) {
return "";
}
/**
* @dev See {IERC721-approve}.
*/
function approve(address to, uint256 tokenId) public virtual {
_approve(to, tokenId, _msgSender());
}
/**
* @dev See {IERC721-getApproved}.
*/
function getApproved(uint256 tokenId) public view virtual returns (address) {
_requireOwned(tokenId);
return _getApproved(tokenId);
}
/**
* @dev See {IERC721-setApprovalForAll}.
*/
function setApprovalForAll(address operator, bool approved) public virtual {
_setApprovalForAll(_msgSender(), operator, approved);
}
/**
* @dev See {IERC721-isApprovedForAll}.
*/
function isApprovedForAll(address owner, address operator) public view virtual returns (bool) {
ERC721Storage storage $ = _getERC721Storage();
return $._operatorApprovals[owner][operator];
}
/**
* @dev See {IERC721-transferFrom}.
*/
function transferFrom(address from, address to, uint256 tokenId) public virtual {
if (to == address(0)) {
revert ERC721InvalidReceiver(address(0));
}
// Setting an "auth" arguments enables the `_isAuthorized` check which verifies that the token exists
// (from != 0). Therefore, it is not needed to verify that the return value is not 0 here.
address previousOwner = _update(to, tokenId, _msgSender());
if (previousOwner != from) {
revert ERC721IncorrectOwner(from, tokenId, previousOwner);
}
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(address from, address to, uint256 tokenId) public {
safeTransferFrom(from, to, tokenId, "");
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory data) public virtual {
transferFrom(from, to, tokenId);
_checkOnERC721Received(from, to, tokenId, data);
}
/**
* @dev Returns the owner of the `tokenId`. Does NOT revert if token doesn't exist
*
* IMPORTANT: Any overrides to this function that add ownership of tokens not tracked by the
* core ERC721 logic MUST be matched with the use of {_increaseBalance} to keep balances
* consistent with ownership. The invariant to preserve is that for any address `a` the value returned by
* `balanceOf(a)` must be equal to the number of tokens such that `_ownerOf(tokenId)` is `a`.
*/
function _ownerOf(uint256 tokenId) internal view virtual returns (address) {
ERC721Storage storage $ = _getERC721Storage();
return $._owners[tokenId];
}
/**
* @dev Returns the approved address for `tokenId`. Returns 0 if `tokenId` is not minted.
*/
function _getApproved(uint256 tokenId) internal view virtual returns (address) {
ERC721Storage storage $ = _getERC721Storage();
return $._tokenApprovals[tokenId];
}
/**
* @dev Returns whether `spender` is allowed to manage `owner`'s tokens, or `tokenId` in
* particular (ignoring whether it is owned by `owner`).
*
* WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this
* assumption.
*/
function _isAuthorized(address owner, address spender, uint256 tokenId) internal view virtual returns (bool) {
return
spender != address(0) &&
(owner == spender || isApprovedForAll(owner, spender) || _getApproved(tokenId) == spender);
}
/**
* @dev Checks if `spender` can operate on `tokenId`, assuming the provided `owner` is the actual owner.
* Reverts if `spender` does not have approval from the provided `owner` for the given token or for all its assets
* the `spender` for the specific `tokenId`.
*
* WARNING: This function assumes that `owner` is the actual owner of `tokenId` and does not verify this
* assumption.
*/
function _checkAuthorized(address owner, address spender, uint256 tokenId) internal view virtual {
if (!_isAuthorized(owner, spender, tokenId)) {
if (owner == address(0)) {
revert ERC721NonexistentToken(tokenId);
} else {
revert ERC721InsufficientApproval(spender, tokenId);
}
}
}
/**
* @dev Unsafe write access to the balances, used by extensions that "mint" tokens using an {ownerOf} override.
*
* NOTE: the value is limited to type(uint128).max. This protect against _balance overflow. It is unrealistic that
* a uint256 would ever overflow from increments when these increments are bounded to uint128 values.
*
* WARNING: Increasing an account's balance using this function tends to be paired with an override of the
* {_ownerOf} function to resolve the ownership of the corresponding tokens so that balances and ownership
* remain consistent with one another.
*/
function _increaseBalance(address account, uint128 value) internal virtual {
ERC721Storage storage $ = _getERC721Storage();
unchecked {
$._balances[account] += value;
}
}
/**
* @dev Transfers `tokenId` from its current owner to `to`, or alternatively mints (or burns) if the current owner
* (or `to`) is the zero address. Returns the owner of the `tokenId` before the update.
*
* The `auth` argument is optional. If the value passed is non 0, then this function will check that
* `auth` is either the owner of the token, or approved to operate on the token (by the owner).
*
* Emits a {Transfer} event.
*
* NOTE: If overriding this function in a way that tracks balances, see also {_increaseBalance}.
*/
function _update(address to, uint256 tokenId, address auth) internal virtual returns (address) {
ERC721Storage storage $ = _getERC721Storage();
address from = _ownerOf(tokenId);
// Perform (optional) operator check
if (auth != address(0)) {
_checkAuthorized(from, auth, tokenId);
}
// Execute the update
if (from != address(0)) {
// Clear approval. No need to re-authorize or emit the Approval event
_approve(address(0), tokenId, address(0), false);
unchecked {
$._balances[from] -= 1;
}
}
if (to != address(0)) {
unchecked {
$._balances[to] += 1;
}
}
$._owners[tokenId] = to;
emit Transfer(from, to, tokenId);
return from;
}
/**
* @dev Mints `tokenId` and transfers it to `to`.
*
* WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
*
* Requirements:
*
* - `tokenId` must not exist.
* - `to` cannot be the zero address.
*
* Emits a {Transfer} event.
*/
function _mint(address to, uint256 tokenId) internal {
if (to == address(0)) {
revert ERC721InvalidReceiver(address(0));
}
address previousOwner = _update(to, tokenId, address(0));
if (previousOwner != address(0)) {
revert ERC721InvalidSender(address(0));
}
}
/**
* @dev Mints `tokenId`, transfers it to `to` and checks for `to` acceptance.
*
* Requirements:
*
* - `tokenId` must not exist.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeMint(address to, uint256 tokenId) internal {
_safeMint(to, tokenId, "");
}
/**
* @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
* forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
*/
function _safeMint(address to, uint256 tokenId, bytes memory data) internal virtual {
_mint(to, tokenId);
_checkOnERC721Received(address(0), to, tokenId, data);
}
/**
* @dev Destroys `tokenId`.
* The approval is cleared when the token is burned.
* This is an internal function that does not check if the sender is authorized to operate on the token.
*
* Requirements:
*
* - `tokenId` must exist.
*
* Emits a {Transfer} event.
*/
function _burn(uint256 tokenId) internal {
address previousOwner = _update(address(0), tokenId, address(0));
if (previousOwner == address(0)) {
revert ERC721NonexistentToken(tokenId);
}
}
/**
* @dev Transfers `tokenId` from `from` to `to`.
* As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
*
* Requirements:
*
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
*
* Emits a {Transfer} event.
*/
function _transfer(address from, address to, uint256 tokenId) internal {
if (to == address(0)) {
revert ERC721InvalidReceiver(address(0));
}
address previousOwner = _update(to, tokenId, address(0));
if (previousOwner == address(0)) {
revert ERC721NonexistentToken(tokenId);
} else if (previousOwner != from) {
revert ERC721IncorrectOwner(from, tokenId, previousOwner);
}
}
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking that contract recipients
* are aware of the ERC721 standard to prevent tokens from being forever locked.
*
* `data` is additional data, it has no specified format and it is sent in call to `to`.
*
* This internal function is like {safeTransferFrom} in the sense that it invokes
* {IERC721Receiver-onERC721Received} on the receiver, and can be used to e.g.
* implement alternative mechanisms to perform token transfer, such as signature-based.
*
* Requirements:
*
* - `tokenId` token must exist and be owned by `from`.
* - `to` cannot be the zero address.
* - `from` cannot be the zero address.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeTransfer(address from, address to, uint256 tokenId) internal {
_safeTransfer(from, to, tokenId, "");
}
/**
* @dev Same as {xref-ERC721-_safeTransfer-address-address-uint256-}[`_safeTransfer`], with an additional `data` parameter which is
* forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
*/
function _safeTransfer(address from, address to, uint256 tokenId, bytes memory data) internal virtual {
_transfer(from, to, tokenId);
_checkOnERC721Received(from, to, tokenId, data);
}
/**
* @dev Approve `to` to operate on `tokenId`
*
* The `auth` argument is optional. If the value passed is non 0, then this function will check that `auth` is
* either the owner of the token, or approved to operate on all tokens held by this owner.
*
* Emits an {Approval} event.
*
* Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument.
*/
function _approve(address to, uint256 tokenId, address auth) internal {
_approve(to, tokenId, auth, true);
}
/**
* @dev Variant of `_approve` with an optional flag to enable or disable the {Approval} event. The event is not
* emitted in the context of transfers.
*/
function _approve(address to, uint256 tokenId, address auth, bool emitEvent) internal virtual {
ERC721Storage storage $ = _getERC721Storage();
// Avoid reading the owner unless necessary
if (emitEvent || auth != address(0)) {
address owner = _requireOwned(tokenId);
// We do not use _isAuthorized because single-token approvals should not be able to call approve
if (auth != address(0) && owner != auth && !isApprovedForAll(owner, auth)) {
revert ERC721InvalidApprover(auth);
}
if (emitEvent) {
emit Approval(owner, to, tokenId);
}
}
$._tokenApprovals[tokenId] = to;
}
/**
* @dev Approve `operator` to operate on all of `owner` tokens
*
* Requirements:
* - operator can't be the address zero.
*
* Emits an {ApprovalForAll} event.
*/
function _setApprovalForAll(address owner, address operator, bool approved) internal virtual {
ERC721Storage storage $ = _getERC721Storage();
if (operator == address(0)) {
revert ERC721InvalidOperator(operator);
}
$._operatorApprovals[owner][operator] = approved;
emit ApprovalForAll(owner, operator, approved);
}
/**
* @dev Reverts if the `tokenId` doesn't have a current owner (it hasn't been minted, or it has been burned).
* Returns the owner.
*
* Overrides to ownership logic should be done to {_ownerOf}.
*/
function _requireOwned(uint256 tokenId) internal view returns (address) {
address owner = _ownerOf(tokenId);
if (owner == address(0)) {
revert ERC721NonexistentToken(tokenId);
}
return owner;
}
/**
* @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target address. This will revert if the
* recipient doesn't accept the token transfer. The call is not executed if the target address is not a contract.
*
* @param from address representing the previous owner of the given token ID
* @param to target address that will receive the tokens
* @param tokenId uint256 ID of the token to be transferred
* @param data bytes optional data to send along with the call
*/
function _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory data) private {
if (to.code.length > 0) {
try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, data) returns (bytes4 retval) {
if (retval != IERC721Receiver.onERC721Received.selector) {
revert ERC721InvalidReceiver(to);
}
} catch (bytes memory reason) {
if (reason.length == 0) {
revert ERC721InvalidReceiver(to);
} else {
/// @solidity memory-safe-assembly
assembly {
revert(add(32, reason), mload(reason))
}
}
}
}
}
}
// src/escrow/interfaces/IFactory.sol
interface IFactory is ITokenType {
function distributeRewards(
uint256 questId,
address token,
address to,
uint256 amount,
uint256 rewardTokenId,
TokenType tokenType,
uint256 rakeBps
) external;
function withdrawFunds(
uint256 questId,
address to,
address token,
uint256 tokenId,
TokenType tokenType
) external;
function createEscrow(
uint256 questId,
address admin,
address[] memory whitelistedTokens,
address treasury
) external;
function updateEscrowAdmin(uint256 questId, address newAdmin) external;
function addTokenToWhitelist(uint256 questId, address token) external;
function removeTokenFromWhitelist(uint256 questId, address token) external;
function initialize(address admin) external;
}
// src/CUBE.sol
/*
.____ ________
| | _____ ___.__. __________\_____ \
| | \__ \< | |/ __ \_ __ \_(__ <
| |___ / __ \\___ \ ___/| | \/ \
|_______ (____ / ____|\___ >__| /______ /
\/ \/\/ \/ \/
*/
/// @title CUBE
/// @dev Implementation of an NFT smart contract with EIP712 signatures.
/// The contract is upgradeable using OpenZeppelin's UUPSUpgradeable pattern.
/// @custom:oz-upgrades-from CUBE
contract CUBE is
Initializable,
ERC721Upgradeable,
AccessControlUpgradeable,
UUPSUpgradeable,
EIP712Upgradeable,
ReentrancyGuardUpgradeable,
ITokenType
{
using ECDSA for bytes32;
error CUBE__IsNotSigner();
error CUBE__MintingIsNotActive();
error CUBE__FeeNotEnough();
error CUBE__SignatureAndCubesInputMismatch();
error CUBE__WithdrawFailed();
error CUBE__NonceAlreadyUsed();
error CUBE__TransferFailed();
error CUBE__BPSTooHigh();
error CUBE__ExcessiveFeePayout();
error CUBE__ExceedsContractBalance();
error CUBE__QuestNotActive();
uint256 internal s_nextTokenId;
bool public s_isMintingActive;
bytes32 public constant SIGNER_ROLE = keccak256("SIGNER");
bytes32 public constant UPGRADER_ROLE = keccak256("UPGRADER");
bytes32 internal constant TX_DATA_HASH =
keccak256("TransactionData(string txHash,string networkChainId)");
bytes32 internal constant RECIPIENT_DATA_HASH =
keccak256("FeeRecipient(address recipient,uint16 BPS)");
bytes32 internal constant REWARD_DATA_HASH = keccak256(
"RewardData(address tokenAddress,uint256 chainId,uint256 amount,uint256 tokenId,uint8 tokenType,uint256 rakeBps,address factoryAddress)"
);
bytes32 internal constant CUBE_DATA_HASH = keccak256(
"CubeData(uint256 questId,uint256 nonce,uint256 price,address toAddress,string walletProvider,string tokenURI,string embedOrigin,TransactionData[] transactions,FeeRecipient[] recipients,RewardData reward)FeeRecipient(address recipient,uint16 BPS)RewardData(address tokenAddress,uint256 chainId,uint256 amount,uint256 tokenId,uint8 tokenType,uint256 rakeBps,address factoryAddress)TransactionData(string txHash,string networkChainId)"
);
mapping(uint256 => uint256) internal s_questIssueNumbers;
mapping(uint256 => string) internal s_tokenURIs;
mapping(uint256 nonce => bool isConsumed) internal s_nonces;
mapping(uint256 => bool) internal s_quests;
enum QuestType {
QUEST,
STREAK
}
enum Difficulty {
BEGINNER,
INTERMEDIATE,
ADVANCED
}
/// @notice Emitted when a new quest is initialized
/// @param questId The unique identifier of the quest
/// @param questType The type of the quest (QUEST, STREAK)
/// @param difficulty The difficulty level of the quest (BEGINNER, INTERMEDIATE, ADVANCED)
/// @param title The title of the quest
/// @param tags An array of tags associated with the quest
/// @param communities An array of communities associated with the quest
event QuestMetadata(
uint256 indexed questId,
QuestType questType,
Difficulty difficulty,
string title,
string[] tags,
string[] communities
);
/// @notice Emitted when a CUBE is claimed
/// @param questId The quest ID associated with the CUBE
/// @param tokenId The token ID of the minted CUBE
/// @param claimer Address of the CUBE claimer
/// @param issueNumber The issue number of the CUBE
/// @param walletProvider The name of the wallet provider used for claiming
/// @param embedOrigin The origin of the embed associated with the CUBE
event CubeClaim(
uint256 indexed questId,
uint256 indexed tokenId,
address indexed claimer,
uint256 issueNumber,
string walletProvider,
string embedOrigin
);
/// @notice Emitted for each transaction associated with a CUBE claim
/// This event is designed to support both EVM and non-EVM blockchains
/// @param cubeTokenId The token ID of the Cube
/// @param txHash The hash of the transaction
/// @param networkChainId The network and chain ID of the transaction in the format <network>:<chain-id>
event CubeTransaction(uint256 indexed cubeTokenId, string txHash, string networkChainId);
/// @notice Emitted when there is a reward associated with a CUBE
/// @param cubeTokenId The token ID of the CUBE giving the reward
/// @param tokenAddress The token address of the reward
/// @param chainId The blockchain chain ID where the transaction occurred
/// @param amount The amount of the reward
/// @param tokenId Token ID of the reward (only applicable for ERC721 and ERC1155)
/// @param tokenType The type of reward token
event TokenReward(
uint256 indexed cubeTokenId,
address indexed tokenAddress,
uint256 indexed chainId,
uint256 amount,
uint256 tokenId,
TokenType tokenType
);
/// @notice Emitted when a fee payout is made
/// @param recipient The address of the payout recipient
/// @param amount The amount of the payout
event FeePayout(address indexed recipient, uint256 amount);
/// @notice Emitted when the minting switch is turned on/off
/// @param isActive The boolean showing if the minting is active or not
event MintingSwitch(bool isActive);
/// @notice Emitted when the contract balance is withdrawn by an admin
/// @param amount The contract's balance that was withdrawn
event ContractWithdrawal(uint256 amount);
event QuestDisabled(uint256 indexed questId);
/// @dev Represents the data needed for minting a CUBE.
/// @param questId The ID of the quest associated with the CUBE
/// @param nonce A unique number to prevent replay attacks
/// @param price The price paid for minting the CUBE
/// @param toAddress The address where the CUBE will be minted
/// @param walletProvider The wallet provider used for the transaction
/// @param tokenURI The URI pointing to the CUBE's metadata
/// @param embedOrigin The origin source of the CUBE's embed content
/// @param transactions An array of transactions related to the CUBE
/// @param recipients An array of recipients for fee payouts
/// @param reward Data about the reward associated with the CUBE
struct CubeData {
uint256 questId;
uint256 nonce;
uint256 price;
address toAddress;
string walletProvider;
string tokenURI;
string embedOrigin;
TransactionData[] transactions;
FeeRecipient[] recipients;
RewardData reward;
}
/// @dev Represents a recipient for fee distribution.
/// @param recipient The address of the fee recipient
/// @param BPS The basis points representing the fee percentage for the recipient
struct FeeRecipient {
address recipient;
uint16 BPS;
}
/// @dev Contains data about the token rewards associated with a CUBE.
/// @param tokenAddress The token address of the reward
/// @param chainId The blockchain chain ID where the transaction occurred
/// @param amount The amount of the reward
/// @param tokenId The token ID
/// @param tokenType The token type
/// @param rakeBps The rake basis points
/// @param factoryAddress The escrow factory address
struct RewardData {
address tokenAddress;
uint256 chainId;
uint256 amount;
uint256 tokenId;
TokenType tokenType;
uint256 rakeBps;
address factoryAddress;
}
/// @dev Contains data about a specific transaction related to a CUBE
/// and is designed to support both EVM and non-EVM data.
/// @param txHash The hash of the transaction
/// @param networkChainId The network and chain ID of the transaction in the format <network>:<chain-id>
struct TransactionData {
string txHash;
string networkChainId;
}
/// @custom:oz-upgrades-unsafe-allow constructor
constructor() {
_disableInitializers();
}
/// @notice Returns the version of the CUBE smart contract
function cubeVersion() external pure returns (string memory) {
return "2";
}
/// @notice Initializes the CUBE contract with necessary parameters
/// @dev Sets up the ERC721 token with given name and symbol, and grants initial roles.
/// @param _tokenName Name of the NFT collection
/// @param _tokenSymbol Symbol of the NFT collection
/// @param _signingDomain Domain used for EIP712 signing
/// @param _signatureVersion Version of the EIP712 signature
/// @param _admin Address to be granted the admin roles
function initialize(
string memory _tokenName,
string memory _tokenSymbol,
string memory _signingDomain,
string memory _signatureVersion,
address _admin
) external initializer {
__ERC721_init(_tokenName, _tokenSymbol);
__EIP712_init(_signingDomain, _signatureVersion);
__AccessControl_init();
__UUPSUpgradeable_init();
__ReentrancyGuard_init();
s_isMintingActive = true;
_grantRole(DEFAULT_ADMIN_ROLE, _admin);
}
/// @notice Authorizes an upgrade to a new contract implementation
/// @dev Overrides the UUPSUpgradeable internal function with access control.
/// @param newImplementation Address of the new contract implementation
function _authorizeUpgrade(address newImplementation)
internal
override
onlyRole(UPGRADER_ROLE)
{}
/// @notice Checks whether a quest is active or not
/// @param questId Unique identifier for the quest
function isQuestActive(uint256 questId) public view returns (bool) {
return s_quests[questId];
}
/// @notice Retrieves the URI for a given token
/// @dev Overrides the ERC721Upgradeable's tokenURI method.
/// @param _tokenId The ID of the token
/// @return _tokenURI The URI of the specified token
function tokenURI(uint256 _tokenId) public view override returns (string memory _tokenURI) {
return s_tokenURIs[_tokenId];
}
/// @notice Mints a CUBE based on the provided data
/// @param cubeData CubeData struct containing minting information
/// @param signature Signature of the CubeData struct
function mintCube(CubeData calldata cubeData, bytes calldata signature)
external
payable
nonReentrant
{
// Check if the minting function is currently active. If not, revert the transaction
if (!s_isMintingActive) {
revert CUBE__MintingIsNotActive();
}
// Check if the sent value is at least equal to the calculated total fee
if (msg.value < cubeData.price) {
revert CUBE__FeeNotEnough();
}
_mintCube(cubeData, signature);
}
/// @notice Mints multiple cubes based on provided data and signatures
/// @dev Checks if minting is active, matches cube data with signatures, and processes each mint.
/// @param cubeData Array of CubeData structures containing minting information
/// @param signatures Array of signatures corresponding to each CubeData
function mintCubes(CubeData[] calldata cubeData, bytes[] calldata signatures)
external
payable
nonReentrant
{
// Check if the minting function is currently active. If not, revert the transaction
if (!s_isMintingActive) {
revert CUBE__MintingIsNotActive();
}
// Ensure that each CubeData entry has a corresponding signature
if (cubeData.length != signatures.length) {
revert CUBE__SignatureAndCubesInputMismatch();
}
// Calculate the total fee required for all the minting requests
uint256 totalFee;
for (uint256 i = 0; i < cubeData.length;) {
totalFee = totalFee + cubeData[i].price;
unchecked {
++i;
}
}
// Check if the sent value is at least equal to the calculated total fee
if (msg.value < totalFee) {
revert CUBE__FeeNotEnough();
}
// Loop through each CubeData entry and mint a CUBE
for (uint256 i = 0; i < cubeData.length;) {
_mintCube(cubeData[i], signatures[i]);
unchecked {
++i;
}
}
}
/// @notice Internal function to handle the logic of minting a single cube
/// @dev Verifies the signer, handles nonce, transactions, referral payments, and minting.
/// @param data The CubeData containing details of the minting
/// @param signature The signature for verification
function _mintCube(CubeData calldata data, bytes calldata signature) internal {
// Cache the tokenId
uint256 tokenId = s_nextTokenId;
// Validate the signature to ensure the mint request is authorized
_validateSignature(data, signature);
// Iterate over all the transactions in the mint request and emit events
for (uint256 i = 0; i < data.transactions.length;) {
emit CubeTransaction(
tokenId, data.transactions[i].txHash, data.transactions[i].networkChainId
);
unchecked {
++i;
}
}
// Set the token URI for the CUBE
s_tokenURIs[tokenId] = data.tokenURI;
// Increment the counters for quest completion, issue numbers, and token IDs
unchecked {
++s_questIssueNumbers[data.questId];
++s_nextTokenId;
}
// Process any payouts to fee recipients if applicable
if (data.recipients.length > 0) {
_processPayouts(data);
}
// Perform the actual minting of the CUBE
_safeMint(data.toAddress, tokenId);
// Emit an event indicating a CUBE has been claimed
emit CubeClaim(
data.questId,
tokenId,
data.toAddress,
s_questIssueNumbers[data.questId],
data.walletProvider,
data.embedOrigin
);
if (data.reward.chainId != 0) {
if (data.reward.factoryAddress != address(0)) {
IFactory(data.reward.factoryAddress).distributeRewards(
data.questId,
data.reward.tokenAddress,
data.toAddress,
data.reward.amount,
data.reward.tokenId,
data.reward.tokenType,
data.reward.rakeBps
);
}
emit TokenReward(
tokenId,
data.reward.tokenAddress,
data.reward.chainId,
data.reward.amount,
data.reward.tokenId,
data.reward.tokenType
);
}
}
/// @notice Validates the signature for a Cube minting request
/// @dev Ensures that the signature is from a valid signer and the nonce hasn't been used before
/// @param data The CubeData struct containing minting details
/// @param signature The signature to be validated
function _validateSignature(CubeData calldata data, bytes calldata signature) internal {
address signer = _getSigner(data, signature);
if (!hasRole(SIGNER_ROLE, signer)) {
revert CUBE__IsNotSigner();
}
if (s_nonces[data.nonce]) {
revert CUBE__NonceAlreadyUsed();
}
s_nonces[data.nonce] = true;
}
/// @notice Processes fee payouts to specified recipients
/// @dev Distributes a portion of the minting fee to designated addresses based on their Basis Points (BPS)
/// @param data The CubeData struct containing payout details
function _processPayouts(CubeData calldata data) internal {
uint256 totalAmount;
// max basis points is 10k (100%)
uint16 maxBps = 10_000;
uint256 contractBalance = address(this).balance;
for (uint256 i = 0; i < data.recipients.length;) {
if (data.recipients[i].BPS > maxBps) {
revert CUBE__BPSTooHigh();
}
// Calculate the referral amount for each recipient
uint256 referralAmount = (data.price * data.recipients[i].BPS) / maxBps;
totalAmount = totalAmount + referralAmount;
// Ensure the total payout does not exceed the cube price or contract balance
if (totalAmount > data.price) {
revert CUBE__ExcessiveFeePayout();
}
if (totalAmount > contractBalance) {
revert CUBE__ExceedsContractBalance();
}
// Transfer the referral amount to the recipient
address recipient = data.recipients[i].recipient;
if (recipient != address(0)) {
(bool success,) = recipient.call{value: referralAmount}("");
if (!success) {
revert CUBE__TransferFailed();
}
emit FeePayout(recipient, referralAmount);
}
unchecked {
++i;
}
}
}
/// @notice Recovers the signer's address from the CubeData and its associated signature
/// @dev Utilizes EIP-712 typed data hashing and ECDSA signature recovery
/// @param data The CubeData struct containing the details of the minting request
/// @param sig The signature associated with the CubeData
/// @return The address of the signer who signed the CubeData
function _getSigner(CubeData calldata data, bytes calldata sig)
internal
view
returns (address)
{
bytes32 digest = _computeDigest(data);
return digest.recover(sig);
}
/// @notice Internal function to compute the EIP712 digest for CubeData
/// @dev Generates the digest that must be signed by the signer.
/// @param data The CubeData to generate a digest for
/// @return The computed EIP712 digest
function _computeDigest(CubeData calldata data) internal view returns (bytes32) {
return _hashTypedDataV4(keccak256(_getStructHash(data)));
}
/// @notice Internal function to generate the struct hash for CubeData
/// @dev Encodes the CubeData struct into a hash as per EIP712 standard.
/// @param data The CubeData struct to hash
/// @return A hash representing the encoded CubeData
function _getStructHash(CubeData calldata data) internal pure returns (bytes memory) {
return abi.encode(
CUBE_DATA_HASH,
data.questId,
data.nonce,
data.price,
data.toAddress,
_encodeString(data.walletProvider),
_encodeString(data.tokenURI),
_encodeString(data.embedOrigin),
_encodeCompletedTxs(data.transactions),
_encodeRecipients(data.recipients),
_encodeReward(data.reward)
);
}
/// @notice Encodes a string into a bytes32 hash
/// @dev Used for converting strings into a consistent format for EIP712 encoding
/// @param _string The string to be encoded
/// @return The keccak256 hash of the encoded string
function _encodeString(string calldata _string) internal pure returns (bytes32) {
return keccak256(bytes(_string));
}
/// @notice Encodes a transaction data into a byte array
/// @dev Used for converting transaction data into a consistent format for EIP712 encoding
/// @param transaction The TransactionData struct to be encoded
/// @return A byte array representing the encoded transaction data
function _encodeTx(TransactionData calldata transaction) internal pure returns (bytes memory) {
return abi.encode(
TX_DATA_HASH,
_encodeString(transaction.txHash),
_encodeString(transaction.networkChainId)
);
}
/// @notice Encodes an array of transaction data into a single bytes32 hash
/// @dev Used to aggregate multiple transactions into a single hash for EIP712 encoding
/// @param txData An array of TransactionData structs to be encoded
/// @return A bytes32 hash representing the aggregated and encoded transaction data
function _encodeCompletedTxs(TransactionData[] calldata txData)
internal
pure
returns (bytes32)
{
bytes32[] memory encodedTxs = new bytes32[](txData.length);
for (uint256 i = 0; i < txData.length;) {
encodedTxs[i] = keccak256(_encodeTx(txData[i]));
unchecked {
++i;
}
}
return keccak256(abi.encodePacked(encodedTxs));
}
/// @notice Encodes a fee recipient data into a byte array
/// @dev Used for converting fee recipient information into a consistent format for EIP712 encoding
/// @param data The FeeRecipient struct to be encoded
/// @return A byte array representing the encoded fee recipient data
function _encodeRecipient(FeeRecipient calldata data) internal pure returns (bytes memory) {
return abi.encode(RECIPIENT_DATA_HASH, data.recipient, data.BPS);
}
/// @notice Encodes an array of fee recipient data into a single bytes32 hash
/// @dev Used to aggregate multiple fee recipient entries into a single hash for EIP712 encoding
/// @param data An array of FeeRecipient structs to be encoded
/// @return A bytes32 hash representing the aggregated and encoded fee recipient data
function _encodeRecipients(FeeRecipient[] calldata data) internal pure returns (bytes32) {
bytes32[] memory encodedRecipients = new bytes32[](data.length);
for (uint256 i = 0; i < data.length;) {
encodedRecipients[i] = keccak256(_encodeRecipient(data[i]));
unchecked {
++i;
}
}
return keccak256(abi.encodePacked(encodedRecipients));
}
/// @notice Encodes the reward data for a CUBE mint
/// @param data An array of FeeRecipient structs to be encoded
/// @return A bytes32 hash representing the encoded reward data
function _encodeReward(RewardData calldata data) internal pure returns (bytes32) {
return keccak256(
abi.encode(
REWARD_DATA_HASH,
data.tokenAddress,
data.chainId,
data.amount,
data.tokenId,
data.tokenType,
data.rakeBps,
data.factoryAddress
)
);
}
/// @notice Enables or disables the minting process
/// @dev Can only be called by an account with the default admin role.
/// @param _isMintingActive Boolean indicating whether minting should be active
function setIsMintingActive(bool _isMintingActive) external onlyRole(DEFAULT_ADMIN_ROLE) {
s_isMintingActive = _isMintingActive;
emit MintingSwitch(_isMintingActive);
}
/// @notice Withdraws the contract's balance to the message sender
/// @dev Can only be called by an account with the default admin role.
function withdraw() external onlyRole(DEFAULT_ADMIN_ROLE) {
(bool success,) = msg.sender.call{value: address(this).balance}("");
if (!success) {
revert CUBE__WithdrawFailed();
}
emit ContractWithdrawal(address(this).balance);
}
/// @notice Initializes a new quest with given parameters
/// @dev Can only be called by an account with the signer role.
/// @param questId Unique identifier for the quest
/// @param communities Array of community names associated with the quest
/// @param title Title of the quest
/// @param difficulty Difficulty level of the quest
/// @param questType Type of the quest
function initializeQuest(
uint256 questId,
string[] memory communities,
string memory title,
Difficulty difficulty,
QuestType questType,
string[] memory tags
) external onlyRole(SIGNER_ROLE) {
s_quests[questId] = true;
emit QuestMetadata(questId, questType, difficulty, title, tags, communities);
}
/// @notice Unpublishes and disables a quest
/// @dev Can only be called by an account with the signer role
/// @param questId Unique identifier for the quest
function unpublishQuest(uint256 questId) external onlyRole(SIGNER_ROLE) {
s_quests[questId] = false;
emit QuestDisabled(questId);
}
/// @notice Checks if the contract implements an interface
/// @dev Overrides the supportsInterface function of ERC721Upgradeable and AccessControlUpgradeable.
/// @param interfaceId The interface identifier, as specified in ERC-165
/// @return True if the contract implements the interface, false otherwise
function supportsInterface(bytes4 interfaceId)
public
view
override(ERC721Upgradeable, AccessControlUpgradeable)
returns (bool)
{
return super.supportsInterface(interfaceId);
}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"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":[],"name":"CUBE__BPSTooHigh","type":"error"},{"inputs":[],"name":"CUBE__ExceedsContractBalance","type":"error"},{"inputs":[],"name":"CUBE__ExcessiveFeePayout","type":"error"},{"inputs":[],"name":"CUBE__FeeNotEnough","type":"error"},{"inputs":[],"name":"CUBE__IsNotSigner","type":"error"},{"inputs":[],"name":"CUBE__MintingIsNotActive","type":"error"},{"inputs":[],"name":"CUBE__NonceAlreadyUsed","type":"error"},{"inputs":[],"name":"CUBE__QuestNotActive","type":"error"},{"inputs":[],"name":"CUBE__SignatureAndCubesInputMismatch","type":"error"},{"inputs":[],"name":"CUBE__TransferFailed","type":"error"},{"inputs":[],"name":"CUBE__WithdrawFailed","type":"error"},{"inputs":[],"name":"ECDSAInvalidSignature","type":"error"},{"inputs":[{"internalType":"uint256","name":"length","type":"uint256"}],"name":"ECDSAInvalidSignatureLength","type":"error"},{"inputs":[{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"ECDSAInvalidSignatureS","type":"error"},{"inputs":[{"internalType":"address","name":"implementation","type":"address"}],"name":"ERC1967InvalidImplementation","type":"error"},{"inputs":[],"name":"ERC1967NonPayable","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721IncorrectOwner","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721InsufficientApproval","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC721InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"ERC721InvalidOperator","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"ERC721InvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC721InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC721InvalidSender","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ERC721NonexistentToken","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"inputs":[],"name":"InvalidInitialization","type":"error"},{"inputs":[],"name":"NotInitializing","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","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":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ContractWithdrawal","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"questId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"claimer","type":"address"},{"indexed":false,"internalType":"uint256","name":"issueNumber","type":"uint256"},{"indexed":false,"internalType":"string","name":"walletProvider","type":"string"},{"indexed":false,"internalType":"string","name":"embedOrigin","type":"string"}],"name":"CubeClaim","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"cubeTokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"txHash","type":"string"},{"indexed":false,"internalType":"string","name":"networkChainId","type":"string"}],"name":"CubeTransaction","type":"event"},{"anonymous":false,"inputs":[],"name":"EIP712DomainChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"recipient","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"FeePayout","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":"isActive","type":"bool"}],"name":"MintingSwitch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"questId","type":"uint256"}],"name":"QuestDisabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"questId","type":"uint256"},{"indexed":false,"internalType":"enum CUBE.QuestType","name":"questType","type":"uint8"},{"indexed":false,"internalType":"enum CUBE.Difficulty","name":"difficulty","type":"uint8"},{"indexed":false,"internalType":"string","name":"title","type":"string"},{"indexed":false,"internalType":"string[]","name":"tags","type":"string[]"},{"indexed":false,"internalType":"string[]","name":"communities","type":"string[]"}],"name":"QuestMetadata","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":"uint256","name":"cubeTokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"tokenAddress","type":"address"},{"indexed":true,"internalType":"uint256","name":"chainId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"enum ITokenType.TokenType","name":"tokenType","type":"uint8"}],"name":"TokenReward","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"implementation","type":"address"}],"name":"Upgraded","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SIGNER_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":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cubeVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"eip712Domain","outputs":[{"internalType":"bytes1","name":"fields","type":"bytes1"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"version","type":"string"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"address","name":"verifyingContract","type":"address"},{"internalType":"bytes32","name":"salt","type":"bytes32"},{"internalType":"uint256[]","name":"extensions","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"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":"_tokenName","type":"string"},{"internalType":"string","name":"_tokenSymbol","type":"string"},{"internalType":"string","name":"_signingDomain","type":"string"},{"internalType":"string","name":"_signatureVersion","type":"string"},{"internalType":"address","name":"_admin","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"questId","type":"uint256"},{"internalType":"string[]","name":"communities","type":"string[]"},{"internalType":"string","name":"title","type":"string"},{"internalType":"enum CUBE.Difficulty","name":"difficulty","type":"uint8"},{"internalType":"enum CUBE.QuestType","name":"questType","type":"uint8"},{"internalType":"string[]","name":"tags","type":"string[]"}],"name":"initializeQuest","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"questId","type":"uint256"}],"name":"isQuestActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"questId","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"price","type":"uint256"},{"internalType":"address","name":"toAddress","type":"address"},{"internalType":"string","name":"walletProvider","type":"string"},{"internalType":"string","name":"tokenURI","type":"string"},{"internalType":"string","name":"embedOrigin","type":"string"},{"components":[{"internalType":"string","name":"txHash","type":"string"},{"internalType":"string","name":"networkChainId","type":"string"}],"internalType":"struct CUBE.TransactionData[]","name":"transactions","type":"tuple[]"},{"components":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint16","name":"BPS","type":"uint16"}],"internalType":"struct CUBE.FeeRecipient[]","name":"recipients","type":"tuple[]"},{"components":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"enum ITokenType.TokenType","name":"tokenType","type":"uint8"},{"internalType":"uint256","name":"rakeBps","type":"uint256"},{"internalType":"address","name":"factoryAddress","type":"address"}],"internalType":"struct CUBE.RewardData","name":"reward","type":"tuple"}],"internalType":"struct CUBE.CubeData","name":"cubeData","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"}],"name":"mintCube","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"questId","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"price","type":"uint256"},{"internalType":"address","name":"toAddress","type":"address"},{"internalType":"string","name":"walletProvider","type":"string"},{"internalType":"string","name":"tokenURI","type":"string"},{"internalType":"string","name":"embedOrigin","type":"string"},{"components":[{"internalType":"string","name":"txHash","type":"string"},{"internalType":"string","name":"networkChainId","type":"string"}],"internalType":"struct CUBE.TransactionData[]","name":"transactions","type":"tuple[]"},{"components":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint16","name":"BPS","type":"uint16"}],"internalType":"struct CUBE.FeeRecipient[]","name":"recipients","type":"tuple[]"},{"components":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"enum ITokenType.TokenType","name":"tokenType","type":"uint8"},{"internalType":"uint256","name":"rakeBps","type":"uint256"},{"internalType":"address","name":"factoryAddress","type":"address"}],"internalType":"struct CUBE.RewardData","name":"reward","type":"tuple"}],"internalType":"struct CUBE.CubeData[]","name":"cubeData","type":"tuple[]"},{"internalType":"bytes[]","name":"signatures","type":"bytes[]"}],"name":"mintCubes","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proxiableUUID","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"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":[],"name":"s_isMintingActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isMintingActive","type":"bool"}],"name":"setIsMintingActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"_tokenURI","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"questId","type":"uint256"}],"name":"unpublishQuest","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":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
60a0604052306080523480156200001557600080fd5b506200002062000026565b620000da565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000900460ff1615620000775760405163f92ee8a960e01b815260040160405180910390fd5b80546001600160401b0390811614620000d75780546001600160401b0319166001600160401b0390811782556040519081527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50565b60805161463162000104600039600081816117ac015281816117d501526119a701526146316000f3fe6080604052600436106102345760003560e01c806386954d5b11610138578063ad170ff7116100b0578063d123b4d81161007f578063e985e9c511610064578063e985e9c51461070a578063f72c0d8b14610772578063f907497c146107a657600080fd5b8063d123b4d8146106d7578063d547741f146106ea57600080fd5b8063ad170ff71461062e578063ad3cb1cc1461064e578063b88d4fde14610697578063c87b56dd146106b757600080fd5b8063a1ebf35d11610107578063a22cb465116100ec578063a22cb465146105d4578063a35d3d86146105f4578063aab416011461061457600080fd5b8063a1ebf35d1461058b578063a217fddf146105bf57600080fd5b806386954d5b146104ce57806389e7217e146104fe57806391d148541461051157806395d89b411461057657600080fd5b80632f2ff15d116101cb5780634f1ef2861161019a5780636352211e1161017f5780636352211e1461046657806370a082311461048657806384b0196e146104a657600080fd5b80634f1ef2861461043e57806352d1902d1461045157600080fd5b80632f2ff15d146103c957806336568abe146103e95780633ccfd60b1461040957806342842e0e1461041e57600080fd5b8063095ea7b311610207578063095ea7b31461030a57806323b872dd1461032c578063248a9ca31461034c5780632e640024146103a957600080fd5b806301ffc9a71461023957806302e4da091461026e57806306fdde03146102bd578063081812fc146102d2575b600080fd5b34801561024557600080fd5b5061025961025436600461360d565b6107c6565b60405190151581526020015b60405180910390f35b34801561027a57600080fd5b5060408051808201909152600181527f320000000000000000000000000000000000000000000000000000000000000060208201525b604051610265919061367a565b3480156102c957600080fd5b506102b06107d7565b3480156102de57600080fd5b506102f26102ed36600461368d565b61088d565b6040516001600160a01b039091168152602001610265565b34801561031657600080fd5b5061032a6103253660046136c2565b6108d5565b005b34801561033857600080fd5b5061032a6103473660046136ec565b6108e4565b34801561035857600080fd5b5061039b61036736600461368d565b60009081527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602052604090206001015490565b604051908152602001610265565b3480156103b557600080fd5b5061032a6103c43660046137f8565b6109a6565b3480156103d557600080fd5b5061032a6103e43660046138b6565b610b65565b3480156103f557600080fd5b5061032a6104043660046138b6565b610ba9565b34801561041557600080fd5b5061032a610bfa565b34801561042a57600080fd5b5061032a6104393660046136ec565b610cbf565b61032a61044c3660046138e2565b610cda565b34801561045d57600080fd5b5061039b610cf5565b34801561047257600080fd5b506102f261048136600461368d565b610d24565b34801561049257600080fd5b5061039b6104a1366004613930565b610d2f565b3480156104b257600080fd5b506104bb610db6565b604051610265979695949392919061394b565b3480156104da57600080fd5b506102596104e936600461368d565b60009081526005602052604090205460ff1690565b61032a61050c366004613a49565b610eb2565b34801561051d57600080fd5b5061025961052c3660046138b6565b60009182527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602090815260408084206001600160a01b0393909316845291905290205460ff1690565b34801561058257600080fd5b506102b0611040565b34801561059757600080fd5b5061039b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca4081565b3480156105cb57600080fd5b5061039b600081565b3480156105e057600080fd5b5061032a6105ef366004613ac5565b611091565b34801561060057600080fd5b5061032a61060f366004613aef565b61109c565b34801561062057600080fd5b506001546102599060ff1681565b34801561063a57600080fd5b5061032a61064936600461368d565b6110e8565b34801561065a57600080fd5b506102b06040518060400160405280600581526020017f352e302e3000000000000000000000000000000000000000000000000000000081525081565b3480156106a357600080fd5b5061032a6106b2366004613b0a565b611153565b3480156106c357600080fd5b506102b06106d236600461368d565b61116a565b61032a6106e5366004613b72565b61120c565b3480156106f657600080fd5b5061032a6107053660046138b6565b6112c2565b34801561071657600080fd5b50610259610725366004613c12565b6001600160a01b0391821660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793056020908152604080832093909416825291909152205460ff1690565b34801561077e57600080fd5b5061039b7fa615a8afb6fffcb8c6809ac0997b5c9c12b8cc97651150f14c8f6203168cff4c81565b3480156107b257600080fd5b5061032a6107c1366004613cea565b611306565b60006107d182611394565b92915050565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300805460609190819061080990613da5565b80601f016020809104026020016040519081016040528092919081815260200182805461083590613da5565b80156108825780601f1061085757610100808354040283529160200191610882565b820191906000526020600020905b81548152906001019060200180831161086557829003601f168201915b505050505091505090565b6000610898826113ea565b5060008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930460205260409020546001600160a01b03166107d1565b6108e082823361145b565b5050565b6001600160a01b03821661092c576040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600060048201526024015b60405180910390fd5b6000610939838333611468565b9050836001600160a01b0316816001600160a01b0316146109a0576040517f64283d7b0000000000000000000000000000000000000000000000000000000081526001600160a01b0380861660048301526024820184905282166044820152606401610923565b50505050565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000810460ff16159067ffffffffffffffff166000811580156109f15750825b905060008267ffffffffffffffff166001148015610a0e5750303b155b905081158015610a1c575080155b15610a53576040517ff92ee8a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001660011785558315610ab45784547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000001785555b610abe8a8a6115e1565b610ac888886115f3565b610ad0611605565b610ad8611605565b610ae061160f565b6001805460ff191681179055610af760008761161f565b508315610b595784547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50505050505050505050565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b6268006020526040902060010154610b9f816116ee565b6109a0838361161f565b6001600160a01b0381163314610beb576040517f6697b23200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610bf582826116fb565b505050565b6000610c05816116ee565b604051600090339047908381818185875af1925050503d8060008114610c47576040519150601f19603f3d011682016040523d82523d6000602084013e610c4c565b606091505b5050905080610c87576040517f2baafbf900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040514781527f6c9cf7ce96a10a51ae8b3fc5aca25e4754a77b3e821c133c5cebb1d30abe7e8e906020015b60405180910390a15050565b610bf583838360405180602001604052806000815250611153565b610ce26117a1565b610ceb82611871565b6108e0828261189b565b6000610cff61199c565b507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc90565b60006107d1826113ea565b60007f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793006001600160a01b038316610d95576040517f89c62b6400000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b6001600160a01b039092166000908152600390920160205250604090205490565b600060608082808083817fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1008054909150158015610df557506001810154155b610e5b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4549503731323a20556e696e697469616c697a656400000000000000000000006044820152606401610923565b610e636119fe565b610e6b611a4f565b604080516000808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009c939b5091995046985030975095509350915050565b610eba611aa0565b60015460ff16610ef6576040517f9d2c8e7300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828114610f2f576040517fc70ea82800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b84811015610f7757858582818110610f4d57610f4d613df8565b9050602002810190610f5f9190613e27565b610f6d906040013583613e94565b9150600101610f33565b5080341015610fb2576040517fea259f9100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b848110156110155761100d868683818110610fd257610fd2613df8565b9050602002810190610fe49190613e27565b858584818110610ff657610ff6613df8565b90506020028101906110089190613ea7565b611b21565b600101610fb5565b50506109a060017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930180546060917f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793009161080990613da5565b6108e0338383611eaf565b60006110a7816116ee565b6001805460ff19168315159081179091556040519081527f7d16763644b2f7d5a11e2b05fe3a9cc4edb4568049295f4e62024269ae2f6eab90602001610cb3565b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca40611112816116ee565b600082815260056020526040808220805460ff191690555183917f5de3fc4fb6d1f5f0d44014df7fcc3824b081ef3fc3946a361a7cc926a499035191a25050565b61115e8484846108e4565b6109a084848484611f8b565b600081815260036020526040902080546060919061118790613da5565b80601f01602080910402602001604051908101604052809291908181526020018280546111b390613da5565b80156112005780601f106111d557610100808354040283529160200191611200565b820191906000526020600020905b8154815290600101906020018083116111e357829003601f168201915b50505050509050919050565b611214611aa0565b60015460ff16611250576040517f9d2c8e7300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826040013534101561128e576040517fea259f9100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611299838383611b21565b610bf560017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b62680060205260409020600101546112fc816116ee565b6109a083836116fb565b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca40611330816116ee565b60008781526005602052604090819020805460ff191660011790555187907f8a2c815542d43af541960cd9124f5ec6a55c4b8c69f0dda02ed413b401e309cd9061138390869088908a9088908d90613f90565b60405180910390a250505050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b0000000000000000000000000000000000000000000000000000000014806107d157506107d182612130565b60008181527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930260205260408120546001600160a01b0316806107d1576040517f7e27328900000000000000000000000000000000000000000000000000000000815260048101849052602401610923565b610bf58383836001612213565b60008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930260205260408120547f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300906001600160a01b03908116908416156114d6576114d68185876123aa565b6001600160a01b03811615611534576114f3600086600080612213565b6001600160a01b0381166000908152600383016020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190555b6001600160a01b03861615611565576001600160a01b03861660009081526003830160205260409020805460010190555b600085815260028301602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b038a811691821790925591518893918516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a49150505b9392505050565b6115e9612440565b6108e082826124a7565b6115fb612440565b6108e082826124ea565b61160d612440565b565b611617612440565b61160d61255d565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602081815260408084206001600160a01b038616855290915282205460ff166116e4576000848152602082815260408083206001600160a01b03871684529091529020805460ff1916600117905561169a3390565b6001600160a01b0316836001600160a01b0316857f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a460019150506107d1565b60009150506107d1565b6116f88133612565565b50565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602081815260408084206001600160a01b038616855290915282205460ff16156116e4576000848152602082815260408083206001600160a01b0387168085529252808320805460ff1916905551339287917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a460019150506107d1565b306001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016148061183a57507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031661182e7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b6001600160a01b031614155b1561160d576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fa615a8afb6fffcb8c6809ac0997b5c9c12b8cc97651150f14c8f6203168cff4c6108e0816116ee565b816001600160a01b03166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa9250505080156118f5575060408051601f3d908101601f191682019092526118f291810190613ff5565b60015b611936576040517f4c9c8ce30000000000000000000000000000000000000000000000000000000081526001600160a01b0383166004820152602401610923565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc8114611992576040517faa1d49a400000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b610bf583836125f2565b306001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461160d576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10280546060917fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1009161080990613da5565b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10380546060917fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1009161080990613da5565b7f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0080547ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01611b1b576040517f3ee5aeb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60029055565b600054611b2f848484612648565b60005b611b3f60e086018661400e565b9050811015611c0057817fabd48d213cb20ec6f191e95c191131c8fc3832f194f53febcb53d4834baae507611b7760e088018861400e565b84818110611b8757611b87613df8565b9050602002810190611b999190614076565b611ba39080613ea7565b611bb060e08a018a61400e565b86818110611bc057611bc0613df8565b9050602002810190611bd29190614076565b611be0906020810190613ea7565b604051611bf094939291906140d5565b60405180910390a2600101611b32565b50611c0e60a0850185613ea7565b600083815260036020526040902091611c28919083614155565b5083356000908152600260205260408120805460019081019091558154018155611c56610100860186614251565b90501115611c6757611c678461273c565b611c80611c7a6080860160608701613930565b826129d4565b611c906080850160608601613930565b84356000818152600260205260409020546001600160a01b0392909216918391907ffe94555d033bd3fc0f75671674d030640f03095d8345426fcab3a9a0bffdc4fb90611ce060808a018a613ea7565b611ced60c08c018c613ea7565b604051611cfe9594939291906142b9565b60405180910390a4610140840135156109a0576000611d2561020086016101e08701613930565b6001600160a01b031614611e0d57611d4561020085016101e08601613930565b6001600160a01b031663e836239c8535611d6761014088016101208901613930565b611d776080890160608a01613930565b6101608901356101808a0135611d956101c08c016101a08d016142e6565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b168152611dda969594939291906101c08e01359060040161431b565b600060405180830381600087803b158015611df457600080fd5b505af1158015611e08573d6000803e3d6000fd5b505050505b6101408401803590611e23906101208701613930565b6001600160a01b0316827f6d6039156ec873b5c217b996d727775a9eea208e1329e87aaa4b617c76d2bb94610160880135610180890135611e6c6101c08b016101a08c016142e6565b604051611e7b93929190614366565b60405180910390a450505050565b60017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793006001600160a01b038316611f1b576040517f5b08ba180000000000000000000000000000000000000000000000000000000081526001600160a01b0384166004820152602401610923565b6001600160a01b038481166000818152600584016020908152604080832094881680845294825291829020805460ff191687151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a350505050565b6001600160a01b0383163b156109a0576040517f150b7a020000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063150b7a0290611fe6903390889087908790600401614381565b6020604051808303816000875af1925050508015612021575060408051601f3d908101601f1916820190925261201e918101906143bd565b60015b6120a3573d80801561204f576040519150601f19603f3d011682016040523d82523d6000602084013e612054565b606091505b50805160000361209b576040517f64a0ae920000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b805181602001fd5b7fffffffff0000000000000000000000000000000000000000000000000000000081167f150b7a020000000000000000000000000000000000000000000000000000000014612129576040517f64a0ae920000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b5050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd0000000000000000000000000000000000000000000000000000000014806121c357507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806107d157507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146107d1565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300818061224857506001600160a01b03831615155b15612361576000612258856113ea565b90506001600160a01b038416158015906122845750836001600160a01b0316816001600160a01b031614155b80156122d557506001600160a01b0380821660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079305602090815260408083209388168352929052205460ff16155b15612317576040517fa9fbf51f0000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b821561235f5784866001600160a01b0316826001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45b505b600093845260040160205250506040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6123b58383836129ee565b610bf5576001600160a01b0383166123fc576040517f7e27328900000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b6040517f177e802f0000000000000000000000000000000000000000000000000000000081526001600160a01b038316600482015260248101829052604401610923565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a005468010000000000000000900460ff1661160d576040517fd7e6bcf800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6124af612440565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300806124db84826143da565b50600181016109a083826143da565b6124f2612440565b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10261253e84826143da565b506003810161254d83826143da565b5060008082556001909101555050565b611e89612440565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602090815260408083206001600160a01b038516845290915290205460ff166108e0576040517fe2517d3f0000000000000000000000000000000000000000000000000000000081526001600160a01b038216600482015260248101839052604401610923565b6125fb82612ab2565b6040516001600160a01b038316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a280511561264057610bf58282612b5a565b6108e0612bd0565b6000612655848484612c08565b6001600160a01b03811660009081527fbc6704768de17ac743a4c41122099f7a3464fc20363467b8527e22c7572f5d3a602052604090205490915060ff166126c9576040517f0f3c13fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208085013560009081526004909152604090205460ff1615612718576040517f76abf21400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050506020908101356000908152600490915260409020805460ff19166001179055565b600061271047825b612752610100860186614251565b90508110156121295761ffff831661276e610100870187614251565b8381811061277e5761277e613df8565b905060400201602001602081019061279691906144d6565b61ffff1611156127d2576040517f635015ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061ffff84166127e7610100880188614251565b848181106127f7576127f7613df8565b905060400201602001602081019061280f91906144d6565b6128219061ffff1660408901356144fa565b61282b9190614511565b90506128378186613e94565b94508560400135851115612877576040517fcc3b3ebc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828511156128b1576040517f2c2cae9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006128c1610100880188614251565b848181106128d1576128d1613df8565b6128e79260206040909202019081019150613930565b90506001600160a01b038116156129ca576000816001600160a01b03168360405160006040518083038185875af1925050503d8060008114612945576040519150601f19603f3d011682016040523d82523d6000602084013e61294a565b606091505b5050905080612985576040517f7327470c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816001600160a01b03167fc9a9861643a061bfa3739f3b26e5d64578cd78bb863dbd5dac0aca396728d9a7846040516129c091815260200190565b60405180910390a2505b5050600101612744565b6108e0828260405180602001604052806000815250612c58565b60006001600160a01b03831615801590612aaa5750826001600160a01b0316846001600160a01b03161480612a6757506001600160a01b0380851660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079305602090815260408083209387168352929052205460ff165b80612aaa575060008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930460205260409020546001600160a01b038481169116145b949350505050565b806001600160a01b03163b600003612b01576040517f4c9c8ce30000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610923565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6060600080846001600160a01b031684604051612b77919061454c565b600060405180830381855af49150503d8060008114612bb2576040519150601f19603f3d011682016040523d82523d6000602084013e612bb7565b606091505b5091509150612bc7858383612c6f565b95945050505050565b341561160d576040517fb398979f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080612c1485612ce4565b9050612bc784848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508593925050612cfe9050565b612c628383612d28565b610bf56000848484611f8b565b606082612c8457612c7f82612dbf565b6115da565b8151158015612c9b57506001600160a01b0384163b155b15612cdd576040517f9996b3150000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b50806115da565b60006107d1612cf283612e01565b80519060200120612f1e565b600080600080612d0e8686612f66565b925092509250612d1e8282612fb3565b5090949350505050565b6001600160a01b038216612d6b576040517f64a0ae9200000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b6000612d7983836000611468565b90506001600160a01b03811615610bf5576040517f73c6ac6e00000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b805115612dcf5780518082602001fd5b6040517f1425ea4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60607fe078867cdfa0acd2e4d8e43793b771c2d3670af784116b0765aa2425c5bbb021823560208401356040850135612e3f60808701878701613930565b612e54612e4f6080890189613ea7565b6130b7565b612e64612e4f60a08a018a613ea7565b612e74612e4f60c08b018b613ea7565b612e89612e8460e08c018c61400e565b6130d9565b612e9f612e9a6101008d018d614251565b6131b5565b612eac8c61012001613254565b60408051602081019c909c528b019990995260608a019790975260808901959095526001600160a01b0390931660a088015260c087019190915260e0860152610100850152610120840152610140830152610160820152610180015b6040516020818303038152906040529050919050565b60006107d1612f2b6132ec565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b60008060008351604103612fa05760208401516040850151606086015160001a612f92888285856132fb565b955095509550505050612fac565b50508151600091506002905b9250925092565b6000826003811115612fc757612fc7613f0c565b03612fd0575050565b6001826003811115612fe457612fe4613f0c565b0361301b576040517ff645eedf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600282600381111561302f5761302f613f0c565b03613069576040517ffce698f700000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b600382600381111561307d5761307d613f0c565b036108e0576040517fd78bce0c00000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b600082826040516130c992919061455e565b6040518091039020905092915050565b6000808267ffffffffffffffff8111156130f5576130f5613728565b60405190808252806020026020018201604052801561311e578160200160208202803683370190505b50905060005b838110156131845761315885858381811061314157613141613df8565b90506020028101906131539190614076565b6133ca565b8051906020012082828151811061317157613171613df8565b6020908102919091010152600101613124565b5080604051602001613196919061456e565b6040516020818303038152906040528051906020012091505092915050565b6000808267ffffffffffffffff8111156131d1576131d1613728565b6040519080825280602002602001820160405280156131fa578160200160208202803683370190505b50905060005b838110156131845761322885858381811061321d5761321d613df8565b905060400201613429565b8051906020012082828151811061324157613241613df8565b6020908102919091010152600101613200565b60007f07dcd7fc8540e6630daaa95c4bf6d1951796f3e22e2e1c1bcbdbd5055c7ab37c6132846020840184613930565b6020840135604085013560608601356132a360a08801608089016142e6565b60a08801356132b860e08a0160c08b01613930565b6040516020016132cf9897969594939291906145a4565b604051602081830303815290604052805190602001209050919050565b60006132f6613499565b905090565b600080807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a084111561333657506000915060039050826133c0565b604080516000808252602082018084528a905260ff891692820192909252606081018790526080810186905260019060a0016020604051602081039080840390855afa15801561338a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166133b6575060009250600191508290506133c0565b9250600091508190505b9450945094915050565b60607f93dc1bac6b117acdbb889b9a825b9bc731449f703cc02b69049722fcba5dbe346133fa612e4f8480613ea7565b61340a612e4f6020860186613ea7565b6040805160208101949094528301919091526060820152608001612f08565b60607fdf3d1189f68f42c28f9fad9d69ff7a974d0a800a2e4420ed400e45a46d2fac2f6134596020840184613930565b61346960408501602086016144d6565b604051602001612f08939291909283526001600160a01b0391909116602083015261ffff16604082015260600190565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6134c461350d565b6134cc613589565b60408051602081019490945283019190915260608201524660808201523060a082015260c00160405160208183030381529060405280519060200120905090565b60007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d100816135396119fe565b80519091501561355157805160209091012092915050565b81548015613560579392505050565b7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470935050505090565b60007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d100816135b5611a4f565b8051909150156135cd57805160209091012092915050565b60018201548015613560579392505050565b7fffffffff00000000000000000000000000000000000000000000000000000000811681146116f857600080fd5b60006020828403121561361f57600080fd5b81356115da816135df565b60005b8381101561364557818101518382015260200161362d565b50506000910152565b6000815180845261366681602086016020860161362a565b601f01601f19169290920160200192915050565b6020815260006115da602083018461364e565b60006020828403121561369f57600080fd5b5035919050565b80356001600160a01b03811681146136bd57600080fd5b919050565b600080604083850312156136d557600080fd5b6136de836136a6565b946020939093013593505050565b60008060006060848603121561370157600080fd5b61370a846136a6565b9250613718602085016136a6565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561378057613780613728565b604052919050565b600082601f83011261379957600080fd5b813567ffffffffffffffff8111156137b3576137b3613728565b6137c66020601f19601f84011601613757565b8181528460208386010111156137db57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561381057600080fd5b853567ffffffffffffffff8082111561382857600080fd5b61383489838a01613788565b9650602088013591508082111561384a57600080fd5b61385689838a01613788565b9550604088013591508082111561386c57600080fd5b61387889838a01613788565b9450606088013591508082111561388e57600080fd5b5061389b88828901613788565b9250506138aa608087016136a6565b90509295509295909350565b600080604083850312156138c957600080fd5b823591506138d9602084016136a6565b90509250929050565b600080604083850312156138f557600080fd5b6138fe836136a6565b9150602083013567ffffffffffffffff81111561391a57600080fd5b61392685828601613788565b9150509250929050565b60006020828403121561394257600080fd5b6115da826136a6565b7fff00000000000000000000000000000000000000000000000000000000000000881681526000602060e08184015261398760e084018a61364e565b8381036040850152613999818a61364e565b606085018990526001600160a01b038816608086015260a0850187905284810360c0860152855180825283870192509083019060005b818110156139eb578351835292840192918401916001016139cf565b50909c9b505050505050505050505050565b60008083601f840112613a0f57600080fd5b50813567ffffffffffffffff811115613a2757600080fd5b6020830191508360208260051b8501011115613a4257600080fd5b9250929050565b60008060008060408587031215613a5f57600080fd5b843567ffffffffffffffff80821115613a7757600080fd5b613a83888389016139fd565b90965094506020870135915080821115613a9c57600080fd5b50613aa9878288016139fd565b95989497509550505050565b803580151581146136bd57600080fd5b60008060408385031215613ad857600080fd5b613ae1836136a6565b91506138d960208401613ab5565b600060208284031215613b0157600080fd5b6115da82613ab5565b60008060008060808587031215613b2057600080fd5b613b29856136a6565b9350613b37602086016136a6565b925060408501359150606085013567ffffffffffffffff811115613b5a57600080fd5b613b6687828801613788565b91505092959194509250565b600080600060408486031215613b8757600080fd5b833567ffffffffffffffff80821115613b9f57600080fd5b908501906102008288031215613bb457600080fd5b90935060208501359080821115613bca57600080fd5b818601915086601f830112613bde57600080fd5b813581811115613bed57600080fd5b876020828501011115613bff57600080fd5b6020830194508093505050509250925092565b60008060408385031215613c2557600080fd5b613c2e836136a6565b91506138d9602084016136a6565b600082601f830112613c4d57600080fd5b8135602067ffffffffffffffff80831115613c6a57613c6a613728565b8260051b613c79838201613757565b9384528581018301938381019088861115613c9357600080fd5b84880192505b85831015613ccf57823584811115613cb15760008081fd5b613cbf8a87838c0101613788565b8352509184019190840190613c99565b98975050505050505050565b8035600281106136bd57600080fd5b60008060008060008060c08789031215613d0357600080fd5b86359550602087013567ffffffffffffffff80821115613d2257600080fd5b613d2e8a838b01613c3c565b96506040890135915080821115613d4457600080fd5b613d508a838b01613788565b95506060890135915060038210613d6657600080fd5b819450613d7560808a01613cdb565b935060a0890135915080821115613d8b57600080fd5b50613d9889828a01613c3c565b9150509295509295509295565b600181811c90821680613db957607f821691505b602082108103613df2577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01833603018112613e5b57600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156107d1576107d1613e65565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613edc57600080fd5b83018035915067ffffffffffffffff821115613ef757600080fd5b602001915036819003821315613a4257600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600081518084526020808501808196508360051b8101915082860160005b85811015613f83578284038952613f7184835161364e565b98850198935090840190600101613f59565b5091979650505050505050565b600060028710613fa257613fa2613f0c565b86825260038610613fb557613fb5613f0c565b85602083015260a06040830152613fcf60a083018661364e565b8281036060840152613fe18186613f3b565b90508281036080840152613ccf8185613f3b565b60006020828403121561400757600080fd5b5051919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261404357600080fd5b83018035915067ffffffffffffffff82111561405e57600080fd5b6020019150600581901b3603821315613a4257600080fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc1833603018112613e5b57600080fd5b818352818160208501375060006020828401015260006020601f19601f840116840101905092915050565b6040815260006140e96040830186886140aa565b82810360208401526140fc8185876140aa565b979650505050505050565b601f821115610bf557600081815260208120601f850160051c8101602086101561412e5750805b601f850160051c820191505b8181101561414d5782815560010161413a565b505050505050565b67ffffffffffffffff83111561416d5761416d613728565b6141818361417b8354613da5565b83614107565b6000601f8411600181146141d3576000851561419d5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355612129565b600083815260209020601f19861690835b8281101561420457868501358255602094850194600190920191016141e4565b508682101561423f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261428657600080fd5b83018035915067ffffffffffffffff8211156142a157600080fd5b6020019150600681901b3603821315613a4257600080fd5b8581526060602082015260006142d36060830186886140aa565b8281036040840152613ccf8185876140aa565b6000602082840312156142f857600080fd5b8135600481106115da57600080fd5b6004811061431757614317613f0c565b9052565b8781526001600160a01b03878116602083015286166040820152606081018590526080810184905260e0810161435460a0830185614307565b8260c083015298975050505050505050565b8381526020810183905260608101612aaa6040830184614307565b60006001600160a01b038087168352808616602084015250836040830152608060608301526143b3608083018461364e565b9695505050505050565b6000602082840312156143cf57600080fd5b81516115da816135df565b815167ffffffffffffffff8111156143f4576143f4613728565b614408816144028454613da5565b84614107565b602080601f83116001811461445b57600084156144255750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561414d565b600085815260208120601f198616915b8281101561448a5788860151825594840194600190910190840161446b565b50858210156144c657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156144e857600080fd5b813561ffff811681146115da57600080fd5b80820281158282048414176107d1576107d1613e65565b600082614547577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b60008251613e5b81846020870161362a565b8183823760009101908152919050565b815160009082906020808601845b838110156145985781518552938201939082019060010161457c565b50929695505050505050565b6000610100820190508982526001600160a01b03808a1660208401528860408401528760608401528660808401526145df60a0840187614307565b8460c084015280841660e084015250999850505050505050505056fea2646970667358221220d641aad21c3ca498622dfeb8388974c2087706c65ed04e2442b2f0907474a09064736f6c63430008140033
Deployed Bytecode
0x6080604052600436106102345760003560e01c806386954d5b11610138578063ad170ff7116100b0578063d123b4d81161007f578063e985e9c511610064578063e985e9c51461070a578063f72c0d8b14610772578063f907497c146107a657600080fd5b8063d123b4d8146106d7578063d547741f146106ea57600080fd5b8063ad170ff71461062e578063ad3cb1cc1461064e578063b88d4fde14610697578063c87b56dd146106b757600080fd5b8063a1ebf35d11610107578063a22cb465116100ec578063a22cb465146105d4578063a35d3d86146105f4578063aab416011461061457600080fd5b8063a1ebf35d1461058b578063a217fddf146105bf57600080fd5b806386954d5b146104ce57806389e7217e146104fe57806391d148541461051157806395d89b411461057657600080fd5b80632f2ff15d116101cb5780634f1ef2861161019a5780636352211e1161017f5780636352211e1461046657806370a082311461048657806384b0196e146104a657600080fd5b80634f1ef2861461043e57806352d1902d1461045157600080fd5b80632f2ff15d146103c957806336568abe146103e95780633ccfd60b1461040957806342842e0e1461041e57600080fd5b8063095ea7b311610207578063095ea7b31461030a57806323b872dd1461032c578063248a9ca31461034c5780632e640024146103a957600080fd5b806301ffc9a71461023957806302e4da091461026e57806306fdde03146102bd578063081812fc146102d2575b600080fd5b34801561024557600080fd5b5061025961025436600461360d565b6107c6565b60405190151581526020015b60405180910390f35b34801561027a57600080fd5b5060408051808201909152600181527f320000000000000000000000000000000000000000000000000000000000000060208201525b604051610265919061367a565b3480156102c957600080fd5b506102b06107d7565b3480156102de57600080fd5b506102f26102ed36600461368d565b61088d565b6040516001600160a01b039091168152602001610265565b34801561031657600080fd5b5061032a6103253660046136c2565b6108d5565b005b34801561033857600080fd5b5061032a6103473660046136ec565b6108e4565b34801561035857600080fd5b5061039b61036736600461368d565b60009081527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602052604090206001015490565b604051908152602001610265565b3480156103b557600080fd5b5061032a6103c43660046137f8565b6109a6565b3480156103d557600080fd5b5061032a6103e43660046138b6565b610b65565b3480156103f557600080fd5b5061032a6104043660046138b6565b610ba9565b34801561041557600080fd5b5061032a610bfa565b34801561042a57600080fd5b5061032a6104393660046136ec565b610cbf565b61032a61044c3660046138e2565b610cda565b34801561045d57600080fd5b5061039b610cf5565b34801561047257600080fd5b506102f261048136600461368d565b610d24565b34801561049257600080fd5b5061039b6104a1366004613930565b610d2f565b3480156104b257600080fd5b506104bb610db6565b604051610265979695949392919061394b565b3480156104da57600080fd5b506102596104e936600461368d565b60009081526005602052604090205460ff1690565b61032a61050c366004613a49565b610eb2565b34801561051d57600080fd5b5061025961052c3660046138b6565b60009182527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602090815260408084206001600160a01b0393909316845291905290205460ff1690565b34801561058257600080fd5b506102b0611040565b34801561059757600080fd5b5061039b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca4081565b3480156105cb57600080fd5b5061039b600081565b3480156105e057600080fd5b5061032a6105ef366004613ac5565b611091565b34801561060057600080fd5b5061032a61060f366004613aef565b61109c565b34801561062057600080fd5b506001546102599060ff1681565b34801561063a57600080fd5b5061032a61064936600461368d565b6110e8565b34801561065a57600080fd5b506102b06040518060400160405280600581526020017f352e302e3000000000000000000000000000000000000000000000000000000081525081565b3480156106a357600080fd5b5061032a6106b2366004613b0a565b611153565b3480156106c357600080fd5b506102b06106d236600461368d565b61116a565b61032a6106e5366004613b72565b61120c565b3480156106f657600080fd5b5061032a6107053660046138b6565b6112c2565b34801561071657600080fd5b50610259610725366004613c12565b6001600160a01b0391821660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793056020908152604080832093909416825291909152205460ff1690565b34801561077e57600080fd5b5061039b7fa615a8afb6fffcb8c6809ac0997b5c9c12b8cc97651150f14c8f6203168cff4c81565b3480156107b257600080fd5b5061032a6107c1366004613cea565b611306565b60006107d182611394565b92915050565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300805460609190819061080990613da5565b80601f016020809104026020016040519081016040528092919081815260200182805461083590613da5565b80156108825780601f1061085757610100808354040283529160200191610882565b820191906000526020600020905b81548152906001019060200180831161086557829003601f168201915b505050505091505090565b6000610898826113ea565b5060008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930460205260409020546001600160a01b03166107d1565b6108e082823361145b565b5050565b6001600160a01b03821661092c576040517f64a0ae92000000000000000000000000000000000000000000000000000000008152600060048201526024015b60405180910390fd5b6000610939838333611468565b9050836001600160a01b0316816001600160a01b0316146109a0576040517f64283d7b0000000000000000000000000000000000000000000000000000000081526001600160a01b0380861660048301526024820184905282166044820152606401610923565b50505050565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a00805468010000000000000000810460ff16159067ffffffffffffffff166000811580156109f15750825b905060008267ffffffffffffffff166001148015610a0e5750303b155b905081158015610a1c575080155b15610a53576040517ff92ee8a900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001660011785558315610ab45784547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000001785555b610abe8a8a6115e1565b610ac888886115f3565b610ad0611605565b610ad8611605565b610ae061160f565b6001805460ff191681179055610af760008761161f565b508315610b595784547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff168555604051600181527fc7f505b2f371ae2175ee4913f4499e1f2633a7b5936321eed1cdaeb6115181d29060200160405180910390a15b50505050505050505050565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b6268006020526040902060010154610b9f816116ee565b6109a0838361161f565b6001600160a01b0381163314610beb576040517f6697b23200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610bf582826116fb565b505050565b6000610c05816116ee565b604051600090339047908381818185875af1925050503d8060008114610c47576040519150601f19603f3d011682016040523d82523d6000602084013e610c4c565b606091505b5050905080610c87576040517f2baafbf900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040514781527f6c9cf7ce96a10a51ae8b3fc5aca25e4754a77b3e821c133c5cebb1d30abe7e8e906020015b60405180910390a15050565b610bf583838360405180602001604052806000815250611153565b610ce26117a1565b610ceb82611871565b6108e0828261189b565b6000610cff61199c565b507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc90565b60006107d1826113ea565b60007f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793006001600160a01b038316610d95576040517f89c62b6400000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b6001600160a01b039092166000908152600390920160205250604090205490565b600060608082808083817fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1008054909150158015610df557506001810154155b610e5b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4549503731323a20556e696e697469616c697a656400000000000000000000006044820152606401610923565b610e636119fe565b610e6b611a4f565b604080516000808252602082019092527f0f000000000000000000000000000000000000000000000000000000000000009c939b5091995046985030975095509350915050565b610eba611aa0565b60015460ff16610ef6576040517f9d2c8e7300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828114610f2f576040517fc70ea82800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b84811015610f7757858582818110610f4d57610f4d613df8565b9050602002810190610f5f9190613e27565b610f6d906040013583613e94565b9150600101610f33565b5080341015610fb2576040517fea259f9100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b848110156110155761100d868683818110610fd257610fd2613df8565b9050602002810190610fe49190613e27565b858584818110610ff657610ff6613df8565b90506020028101906110089190613ea7565b611b21565b600101610fb5565b50506109a060017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930180546060917f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793009161080990613da5565b6108e0338383611eaf565b60006110a7816116ee565b6001805460ff19168315159081179091556040519081527f7d16763644b2f7d5a11e2b05fe3a9cc4edb4568049295f4e62024269ae2f6eab90602001610cb3565b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca40611112816116ee565b600082815260056020526040808220805460ff191690555183917f5de3fc4fb6d1f5f0d44014df7fcc3824b081ef3fc3946a361a7cc926a499035191a25050565b61115e8484846108e4565b6109a084848484611f8b565b600081815260036020526040902080546060919061118790613da5565b80601f01602080910402602001604051908101604052809291908181526020018280546111b390613da5565b80156112005780601f106111d557610100808354040283529160200191611200565b820191906000526020600020905b8154815290600101906020018083116111e357829003601f168201915b50505050509050919050565b611214611aa0565b60015460ff16611250576040517f9d2c8e7300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826040013534101561128e576040517fea259f9100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611299838383611b21565b610bf560017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b62680060205260409020600101546112fc816116ee565b6109a083836116fb565b7f2aeb38be3df14d720aeb10a2de6df09b0fb3cd5c5ec256283a22d4593110ca40611330816116ee565b60008781526005602052604090819020805460ff191660011790555187907f8a2c815542d43af541960cd9124f5ec6a55c4b8c69f0dda02ed413b401e309cd9061138390869088908a9088908d90613f90565b60405180910390a250505050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b0000000000000000000000000000000000000000000000000000000014806107d157506107d182612130565b60008181527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930260205260408120546001600160a01b0316806107d1576040517f7e27328900000000000000000000000000000000000000000000000000000000815260048101849052602401610923565b610bf58383836001612213565b60008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930260205260408120547f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300906001600160a01b03908116908416156114d6576114d68185876123aa565b6001600160a01b03811615611534576114f3600086600080612213565b6001600160a01b0381166000908152600383016020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190555b6001600160a01b03861615611565576001600160a01b03861660009081526003830160205260409020805460010190555b600085815260028301602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b038a811691821790925591518893918516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a49150505b9392505050565b6115e9612440565b6108e082826124a7565b6115fb612440565b6108e082826124ea565b61160d612440565b565b611617612440565b61160d61255d565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602081815260408084206001600160a01b038616855290915282205460ff166116e4576000848152602082815260408083206001600160a01b03871684529091529020805460ff1916600117905561169a3390565b6001600160a01b0316836001600160a01b0316857f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a460019150506107d1565b60009150506107d1565b6116f88133612565565b50565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602081815260408084206001600160a01b038616855290915282205460ff16156116e4576000848152602082815260408083206001600160a01b0387168085529252808320805460ff1916905551339287917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a460019150506107d1565b306001600160a01b037f000000000000000000000000d0ab2d3621dc8a862389f89f52f08c097e3fe8b516148061183a57507f000000000000000000000000d0ab2d3621dc8a862389f89f52f08c097e3fe8b56001600160a01b031661182e7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc546001600160a01b031690565b6001600160a01b031614155b1561160d576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fa615a8afb6fffcb8c6809ac0997b5c9c12b8cc97651150f14c8f6203168cff4c6108e0816116ee565b816001600160a01b03166352d1902d6040518163ffffffff1660e01b8152600401602060405180830381865afa9250505080156118f5575060408051601f3d908101601f191682019092526118f291810190613ff5565b60015b611936576040517f4c9c8ce30000000000000000000000000000000000000000000000000000000081526001600160a01b0383166004820152602401610923565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc8114611992576040517faa1d49a400000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b610bf583836125f2565b306001600160a01b037f000000000000000000000000d0ab2d3621dc8a862389f89f52f08c097e3fe8b5161461160d576040517fe07c8dba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10280546060917fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1009161080990613da5565b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10380546060917fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1009161080990613da5565b7f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0080547ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01611b1b576040517f3ee5aeb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60029055565b600054611b2f848484612648565b60005b611b3f60e086018661400e565b9050811015611c0057817fabd48d213cb20ec6f191e95c191131c8fc3832f194f53febcb53d4834baae507611b7760e088018861400e565b84818110611b8757611b87613df8565b9050602002810190611b999190614076565b611ba39080613ea7565b611bb060e08a018a61400e565b86818110611bc057611bc0613df8565b9050602002810190611bd29190614076565b611be0906020810190613ea7565b604051611bf094939291906140d5565b60405180910390a2600101611b32565b50611c0e60a0850185613ea7565b600083815260036020526040902091611c28919083614155565b5083356000908152600260205260408120805460019081019091558154018155611c56610100860186614251565b90501115611c6757611c678461273c565b611c80611c7a6080860160608701613930565b826129d4565b611c906080850160608601613930565b84356000818152600260205260409020546001600160a01b0392909216918391907ffe94555d033bd3fc0f75671674d030640f03095d8345426fcab3a9a0bffdc4fb90611ce060808a018a613ea7565b611ced60c08c018c613ea7565b604051611cfe9594939291906142b9565b60405180910390a4610140840135156109a0576000611d2561020086016101e08701613930565b6001600160a01b031614611e0d57611d4561020085016101e08601613930565b6001600160a01b031663e836239c8535611d6761014088016101208901613930565b611d776080890160608a01613930565b6101608901356101808a0135611d956101c08c016101a08d016142e6565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e089901b168152611dda969594939291906101c08e01359060040161431b565b600060405180830381600087803b158015611df457600080fd5b505af1158015611e08573d6000803e3d6000fd5b505050505b6101408401803590611e23906101208701613930565b6001600160a01b0316827f6d6039156ec873b5c217b996d727775a9eea208e1329e87aaa4b617c76d2bb94610160880135610180890135611e6c6101c08b016101a08c016142e6565b604051611e7b93929190614366565b60405180910390a450505050565b60017f9b779b17422d0df92223018b32b4d1fa46e071723d6817e2486d003becc55f0055565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab00793006001600160a01b038316611f1b576040517f5b08ba180000000000000000000000000000000000000000000000000000000081526001600160a01b0384166004820152602401610923565b6001600160a01b038481166000818152600584016020908152604080832094881680845294825291829020805460ff191687151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a350505050565b6001600160a01b0383163b156109a0576040517f150b7a020000000000000000000000000000000000000000000000000000000081526001600160a01b0384169063150b7a0290611fe6903390889087908790600401614381565b6020604051808303816000875af1925050508015612021575060408051601f3d908101601f1916820190925261201e918101906143bd565b60015b6120a3573d80801561204f576040519150601f19603f3d011682016040523d82523d6000602084013e612054565b606091505b50805160000361209b576040517f64a0ae920000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b805181602001fd5b7fffffffff0000000000000000000000000000000000000000000000000000000081167f150b7a020000000000000000000000000000000000000000000000000000000014612129576040517f64a0ae920000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b5050505050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd0000000000000000000000000000000000000000000000000000000014806121c357507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806107d157507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146107d1565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300818061224857506001600160a01b03831615155b15612361576000612258856113ea565b90506001600160a01b038416158015906122845750836001600160a01b0316816001600160a01b031614155b80156122d557506001600160a01b0380821660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079305602090815260408083209388168352929052205460ff16155b15612317576040517fa9fbf51f0000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b821561235f5784866001600160a01b0316826001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45b505b600093845260040160205250506040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6123b58383836129ee565b610bf5576001600160a01b0383166123fc576040517f7e27328900000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b6040517f177e802f0000000000000000000000000000000000000000000000000000000081526001600160a01b038316600482015260248101829052604401610923565b7ff0c57e16840df040f15088dc2f81fe391c3923bec73e23a9662efc9c229c6a005468010000000000000000900460ff1661160d576040517fd7e6bcf800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6124af612440565b7f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079300806124db84826143da565b50600181016109a083826143da565b6124f2612440565b7fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d1007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d10261253e84826143da565b506003810161254d83826143da565b5060008082556001909101555050565b611e89612440565b60008281527f02dd7bc7dec4dceedda775e58dd541e08a116c6c53815c0bd028192f7b626800602090815260408083206001600160a01b038516845290915290205460ff166108e0576040517fe2517d3f0000000000000000000000000000000000000000000000000000000081526001600160a01b038216600482015260248101839052604401610923565b6125fb82612ab2565b6040516001600160a01b038316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a280511561264057610bf58282612b5a565b6108e0612bd0565b6000612655848484612c08565b6001600160a01b03811660009081527fbc6704768de17ac743a4c41122099f7a3464fc20363467b8527e22c7572f5d3a602052604090205490915060ff166126c9576040517f0f3c13fc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208085013560009081526004909152604090205460ff1615612718576040517f76abf21400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050506020908101356000908152600490915260409020805460ff19166001179055565b600061271047825b612752610100860186614251565b90508110156121295761ffff831661276e610100870187614251565b8381811061277e5761277e613df8565b905060400201602001602081019061279691906144d6565b61ffff1611156127d2576040517f635015ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061ffff84166127e7610100880188614251565b848181106127f7576127f7613df8565b905060400201602001602081019061280f91906144d6565b6128219061ffff1660408901356144fa565b61282b9190614511565b90506128378186613e94565b94508560400135851115612877576040517fcc3b3ebc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828511156128b1576040517f2c2cae9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006128c1610100880188614251565b848181106128d1576128d1613df8565b6128e79260206040909202019081019150613930565b90506001600160a01b038116156129ca576000816001600160a01b03168360405160006040518083038185875af1925050503d8060008114612945576040519150601f19603f3d011682016040523d82523d6000602084013e61294a565b606091505b5050905080612985576040517f7327470c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816001600160a01b03167fc9a9861643a061bfa3739f3b26e5d64578cd78bb863dbd5dac0aca396728d9a7846040516129c091815260200190565b60405180910390a2505b5050600101612744565b6108e0828260405180602001604052806000815250612c58565b60006001600160a01b03831615801590612aaa5750826001600160a01b0316846001600160a01b03161480612a6757506001600160a01b0380851660009081527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab0079305602090815260408083209387168352929052205460ff165b80612aaa575060008281527f80bb2b638cc20bc4d0a60d66940f3ab4a00c1d7b313497ca82fb0b4ab007930460205260409020546001600160a01b038481169116145b949350505050565b806001600160a01b03163b600003612b01576040517f4c9c8ce30000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610923565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6060600080846001600160a01b031684604051612b77919061454c565b600060405180830381855af49150503d8060008114612bb2576040519150601f19603f3d011682016040523d82523d6000602084013e612bb7565b606091505b5091509150612bc7858383612c6f565b95945050505050565b341561160d576040517fb398979f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080612c1485612ce4565b9050612bc784848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508593925050612cfe9050565b612c628383612d28565b610bf56000848484611f8b565b606082612c8457612c7f82612dbf565b6115da565b8151158015612c9b57506001600160a01b0384163b155b15612cdd576040517f9996b3150000000000000000000000000000000000000000000000000000000081526001600160a01b0385166004820152602401610923565b50806115da565b60006107d1612cf283612e01565b80519060200120612f1e565b600080600080612d0e8686612f66565b925092509250612d1e8282612fb3565b5090949350505050565b6001600160a01b038216612d6b576040517f64a0ae9200000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b6000612d7983836000611468565b90506001600160a01b03811615610bf5576040517f73c6ac6e00000000000000000000000000000000000000000000000000000000815260006004820152602401610923565b805115612dcf5780518082602001fd5b6040517f1425ea4200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60607fe078867cdfa0acd2e4d8e43793b771c2d3670af784116b0765aa2425c5bbb021823560208401356040850135612e3f60808701878701613930565b612e54612e4f6080890189613ea7565b6130b7565b612e64612e4f60a08a018a613ea7565b612e74612e4f60c08b018b613ea7565b612e89612e8460e08c018c61400e565b6130d9565b612e9f612e9a6101008d018d614251565b6131b5565b612eac8c61012001613254565b60408051602081019c909c528b019990995260608a019790975260808901959095526001600160a01b0390931660a088015260c087019190915260e0860152610100850152610120840152610140830152610160820152610180015b6040516020818303038152906040529050919050565b60006107d1612f2b6132ec565b836040517f19010000000000000000000000000000000000000000000000000000000000008152600281019290925260228201526042902090565b60008060008351604103612fa05760208401516040850151606086015160001a612f92888285856132fb565b955095509550505050612fac565b50508151600091506002905b9250925092565b6000826003811115612fc757612fc7613f0c565b03612fd0575050565b6001826003811115612fe457612fe4613f0c565b0361301b576040517ff645eedf00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600282600381111561302f5761302f613f0c565b03613069576040517ffce698f700000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b600382600381111561307d5761307d613f0c565b036108e0576040517fd78bce0c00000000000000000000000000000000000000000000000000000000815260048101829052602401610923565b600082826040516130c992919061455e565b6040518091039020905092915050565b6000808267ffffffffffffffff8111156130f5576130f5613728565b60405190808252806020026020018201604052801561311e578160200160208202803683370190505b50905060005b838110156131845761315885858381811061314157613141613df8565b90506020028101906131539190614076565b6133ca565b8051906020012082828151811061317157613171613df8565b6020908102919091010152600101613124565b5080604051602001613196919061456e565b6040516020818303038152906040528051906020012091505092915050565b6000808267ffffffffffffffff8111156131d1576131d1613728565b6040519080825280602002602001820160405280156131fa578160200160208202803683370190505b50905060005b838110156131845761322885858381811061321d5761321d613df8565b905060400201613429565b8051906020012082828151811061324157613241613df8565b6020908102919091010152600101613200565b60007f07dcd7fc8540e6630daaa95c4bf6d1951796f3e22e2e1c1bcbdbd5055c7ab37c6132846020840184613930565b6020840135604085013560608601356132a360a08801608089016142e6565b60a08801356132b860e08a0160c08b01613930565b6040516020016132cf9897969594939291906145a4565b604051602081830303815290604052805190602001209050919050565b60006132f6613499565b905090565b600080807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a084111561333657506000915060039050826133c0565b604080516000808252602082018084528a905260ff891692820192909252606081018790526080810186905260019060a0016020604051602081039080840390855afa15801561338a573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166133b6575060009250600191508290506133c0565b9250600091508190505b9450945094915050565b60607f93dc1bac6b117acdbb889b9a825b9bc731449f703cc02b69049722fcba5dbe346133fa612e4f8480613ea7565b61340a612e4f6020860186613ea7565b6040805160208101949094528301919091526060820152608001612f08565b60607fdf3d1189f68f42c28f9fad9d69ff7a974d0a800a2e4420ed400e45a46d2fac2f6134596020840184613930565b61346960408501602086016144d6565b604051602001612f08939291909283526001600160a01b0391909116602083015261ffff16604082015260600190565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6134c461350d565b6134cc613589565b60408051602081019490945283019190915260608201524660808201523060a082015260c00160405160208183030381529060405280519060200120905090565b60007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d100816135396119fe565b80519091501561355157805160209091012092915050565b81548015613560579392505050565b7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470935050505090565b60007fa16a46d94261c7517cc8ff89f61c0ce93598e3c849801011dee649a6a557d100816135b5611a4f565b8051909150156135cd57805160209091012092915050565b60018201548015613560579392505050565b7fffffffff00000000000000000000000000000000000000000000000000000000811681146116f857600080fd5b60006020828403121561361f57600080fd5b81356115da816135df565b60005b8381101561364557818101518382015260200161362d565b50506000910152565b6000815180845261366681602086016020860161362a565b601f01601f19169290920160200192915050565b6020815260006115da602083018461364e565b60006020828403121561369f57600080fd5b5035919050565b80356001600160a01b03811681146136bd57600080fd5b919050565b600080604083850312156136d557600080fd5b6136de836136a6565b946020939093013593505050565b60008060006060848603121561370157600080fd5b61370a846136a6565b9250613718602085016136a6565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff8111828210171561378057613780613728565b604052919050565b600082601f83011261379957600080fd5b813567ffffffffffffffff8111156137b3576137b3613728565b6137c66020601f19601f84011601613757565b8181528460208386010111156137db57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a0868803121561381057600080fd5b853567ffffffffffffffff8082111561382857600080fd5b61383489838a01613788565b9650602088013591508082111561384a57600080fd5b61385689838a01613788565b9550604088013591508082111561386c57600080fd5b61387889838a01613788565b9450606088013591508082111561388e57600080fd5b5061389b88828901613788565b9250506138aa608087016136a6565b90509295509295909350565b600080604083850312156138c957600080fd5b823591506138d9602084016136a6565b90509250929050565b600080604083850312156138f557600080fd5b6138fe836136a6565b9150602083013567ffffffffffffffff81111561391a57600080fd5b61392685828601613788565b9150509250929050565b60006020828403121561394257600080fd5b6115da826136a6565b7fff00000000000000000000000000000000000000000000000000000000000000881681526000602060e08184015261398760e084018a61364e565b8381036040850152613999818a61364e565b606085018990526001600160a01b038816608086015260a0850187905284810360c0860152855180825283870192509083019060005b818110156139eb578351835292840192918401916001016139cf565b50909c9b505050505050505050505050565b60008083601f840112613a0f57600080fd5b50813567ffffffffffffffff811115613a2757600080fd5b6020830191508360208260051b8501011115613a4257600080fd5b9250929050565b60008060008060408587031215613a5f57600080fd5b843567ffffffffffffffff80821115613a7757600080fd5b613a83888389016139fd565b90965094506020870135915080821115613a9c57600080fd5b50613aa9878288016139fd565b95989497509550505050565b803580151581146136bd57600080fd5b60008060408385031215613ad857600080fd5b613ae1836136a6565b91506138d960208401613ab5565b600060208284031215613b0157600080fd5b6115da82613ab5565b60008060008060808587031215613b2057600080fd5b613b29856136a6565b9350613b37602086016136a6565b925060408501359150606085013567ffffffffffffffff811115613b5a57600080fd5b613b6687828801613788565b91505092959194509250565b600080600060408486031215613b8757600080fd5b833567ffffffffffffffff80821115613b9f57600080fd5b908501906102008288031215613bb457600080fd5b90935060208501359080821115613bca57600080fd5b818601915086601f830112613bde57600080fd5b813581811115613bed57600080fd5b876020828501011115613bff57600080fd5b6020830194508093505050509250925092565b60008060408385031215613c2557600080fd5b613c2e836136a6565b91506138d9602084016136a6565b600082601f830112613c4d57600080fd5b8135602067ffffffffffffffff80831115613c6a57613c6a613728565b8260051b613c79838201613757565b9384528581018301938381019088861115613c9357600080fd5b84880192505b85831015613ccf57823584811115613cb15760008081fd5b613cbf8a87838c0101613788565b8352509184019190840190613c99565b98975050505050505050565b8035600281106136bd57600080fd5b60008060008060008060c08789031215613d0357600080fd5b86359550602087013567ffffffffffffffff80821115613d2257600080fd5b613d2e8a838b01613c3c565b96506040890135915080821115613d4457600080fd5b613d508a838b01613788565b95506060890135915060038210613d6657600080fd5b819450613d7560808a01613cdb565b935060a0890135915080821115613d8b57600080fd5b50613d9889828a01613c3c565b9150509295509295509295565b600181811c90821680613db957607f821691505b602082108103613df2577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01833603018112613e5b57600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156107d1576107d1613e65565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613edc57600080fd5b83018035915067ffffffffffffffff821115613ef757600080fd5b602001915036819003821315613a4257600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600081518084526020808501808196508360051b8101915082860160005b85811015613f83578284038952613f7184835161364e565b98850198935090840190600101613f59565b5091979650505050505050565b600060028710613fa257613fa2613f0c565b86825260038610613fb557613fb5613f0c565b85602083015260a06040830152613fcf60a083018661364e565b8281036060840152613fe18186613f3b565b90508281036080840152613ccf8185613f3b565b60006020828403121561400757600080fd5b5051919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261404357600080fd5b83018035915067ffffffffffffffff82111561405e57600080fd5b6020019150600581901b3603821315613a4257600080fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc1833603018112613e5b57600080fd5b818352818160208501375060006020828401015260006020601f19601f840116840101905092915050565b6040815260006140e96040830186886140aa565b82810360208401526140fc8185876140aa565b979650505050505050565b601f821115610bf557600081815260208120601f850160051c8101602086101561412e5750805b601f850160051c820191505b8181101561414d5782815560010161413a565b505050505050565b67ffffffffffffffff83111561416d5761416d613728565b6141818361417b8354613da5565b83614107565b6000601f8411600181146141d3576000851561419d5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355612129565b600083815260209020601f19861690835b8281101561420457868501358255602094850194600190920191016141e4565b508682101561423f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261428657600080fd5b83018035915067ffffffffffffffff8211156142a157600080fd5b6020019150600681901b3603821315613a4257600080fd5b8581526060602082015260006142d36060830186886140aa565b8281036040840152613ccf8185876140aa565b6000602082840312156142f857600080fd5b8135600481106115da57600080fd5b6004811061431757614317613f0c565b9052565b8781526001600160a01b03878116602083015286166040820152606081018590526080810184905260e0810161435460a0830185614307565b8260c083015298975050505050505050565b8381526020810183905260608101612aaa6040830184614307565b60006001600160a01b038087168352808616602084015250836040830152608060608301526143b3608083018461364e565b9695505050505050565b6000602082840312156143cf57600080fd5b81516115da816135df565b815167ffffffffffffffff8111156143f4576143f4613728565b614408816144028454613da5565b84614107565b602080601f83116001811461445b57600084156144255750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561414d565b600085815260208120601f198616915b8281101561448a5788860151825594840194600190910190840161446b565b50858210156144c657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156144e857600080fd5b813561ffff811681146115da57600080fd5b80820281158282048414176107d1576107d1613e65565b600082614547577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b60008251613e5b81846020870161362a565b8183823760009101908152919050565b815160009082906020808601845b838110156145985781518552938201939082019060010161457c565b50929695505050505050565b6000610100820190508982526001600160a01b03808a1660208401528860408401528760608401528660808401526145df60a0840187614307565b8460c084015280841660e084015250999850505050505050505056fea2646970667358221220d641aad21c3ca498622dfeb8388974c2087706c65ed04e2442b2f0907474a09064736f6c63430008140033
Deployed Bytecode Sourcemap
129445:25364:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;154575:231;;;;;;;;;;-1:-1:-1;154575:231:0;;;;;:::i;:::-;;:::i;:::-;;;611:14:1;;604:22;586:41;;574:2;559:18;154575:231:0;;;;;;;;137405:90;;;;;;;;;;-1:-1:-1;137477:10:0;;;;;;;;;;;;;;;;;137405:90;;;;;;;:::i;111717:149::-;;;;;;;;;;;;;:::i;113005:158::-;;;;;;;;;;-1:-1:-1;113005:158:0;;;;;:::i;:::-;;:::i;:::-;;;-1:-1:-1;;;;;1802:55:1;;;1784:74;;1772:2;1757:18;113005:158:0;1638:226:1;112824:115:0;;;;;;;;;;-1:-1:-1;112824:115:0;;;;;:::i;:::-;;:::i;:::-;;113732:588;;;;;;;;;;-1:-1:-1;113732:588:0;;;;;:::i;:::-;;:::i;89906:194::-;;;;;;;;;;-1:-1:-1;89906:194:0;;;;;:::i;:::-;89971:7;90068:14;;;88010:28;90068:14;;;;;:24;;;;89906:194;;;;2993:25:1;;;2981:2;2966:18;89906:194:0;2847:177:1;137970:532:0;;;;;;;;;;-1:-1:-1;137970:532:0;;;;;:::i;:::-;;:::i;90410:138::-;;;;;;;;;;-1:-1:-1;90410:138:0;;;;;:::i;:::-;;:::i;91547:251::-;;;;;;;;;;-1:-1:-1;91547:251:0;;;;;:::i;:::-;;:::i;152825:281::-;;;;;;;;;;;;;:::i;114391:134::-;;;;;;;;;;-1:-1:-1;114391:134:0;;;;;:::i;:::-;;:::i;106280:217::-;;;;;;:::i;:::-;;:::i;105813:136::-;;;;;;;;;;;;;:::i;111530:120::-;;;;;;;;;;-1:-1:-1;111530:120:0;;;;;:::i;:::-;;:::i;111197:271::-;;;;;;;;;;-1:-1:-1;111197:271:0;;;;;:::i;:::-;;:::i;98618:931::-;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;:::i;138993:110::-;;;;;;;;;;-1:-1:-1;138993:110:0;;;;;:::i;:::-;139054:4;139078:17;;;:8;:17;;;;;;;;;138993:110;140569:1232;;;;;;:::i;:::-;;:::i;88850:210::-;;;;;;;;;;-1:-1:-1;88850:210:0;;;;;:::i;:::-;88927:4;89021:14;;;88010:28;89021:14;;;;;;;;-1:-1:-1;;;;;89021:31:0;;;;;;;;;;;;;;;88850:210;111935:153;;;;;;;;;;;;;:::i;130159:57::-;;;;;;;;;;;;130197:19;130159:57;;87396:49;;;;;;;;;;-1:-1:-1;87396:49:0;87441:4;87396:49;;113235:146;;;;;;;;;;-1:-1:-1;113235:146:0;;;;;:::i;:::-;;:::i;152478:191::-;;;;;;;;;;-1:-1:-1;152478:191:0;;;;;:::i;:::-;;:::i;130121:29::-;;;;;;;;;;-1:-1:-1;130121:29:0;;;;;;;;154085:154;;;;;;;;;;-1:-1:-1;154085:154:0;;;;;:::i;:::-;;:::i;103881:58::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;114596:211;;;;;;;;;;-1:-1:-1;114596:211:0;;;;;:::i;:::-;;:::i;139332:138::-;;;;;;;;;;-1:-1:-1;139332:138:0;;;;;:::i;:::-;;:::i;139666:553::-;;;;;;:::i;:::-;;:::i;90841:140::-;;;;;;;;;;-1:-1:-1;90841:140:0;;;;;:::i;:::-;;:::i;113452:213::-;;;;;;;;;;-1:-1:-1;113452:213:0;;;;;:::i;:::-;-1:-1:-1;;;;;113620:27:0;;;113540:4;113620:27;;;:20;:27;;;;;;;;:37;;;;;;;;;;;;;;;113452:213;130223:61;;;;;;;;;;;;130263:21;130223:61;;153523:380;;;;;;;;;;-1:-1:-1;153523:380:0;;;;;:::i;:::-;;:::i;154575:231::-;154733:4;154762:36;154786:11;154762:23;:36::i;:::-;154755:43;154575:231;-1:-1:-1;;154575:231:0:o;111717:149::-;110200:21;111844:14;;111762:13;;110200:21;;;111844:14;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;111717:149;:::o;113005:158::-;113072:7;113092:22;113106:7;113092:13;:22::i;:::-;-1:-1:-1;115697:7:0;115780:26;;;:17;:26;;;;;;-1:-1:-1;;;;;115780:26:0;113134:21;115627:187;112824:115;112896:35;112905:2;112909:7;60115:10;112896:8;:35::i;:::-;112824:115;;:::o;113732:588::-;-1:-1:-1;;;;;113827:16:0;;113823:89;;113867:33;;;;;113897:1;113867:33;;;1784:74:1;1757:18;;113867:33:0;;;;;;;;113823:89;114133:21;114157:34;114165:2;114169:7;60115:10;114157:7;:34::i;:::-;114133:58;;114223:4;-1:-1:-1;;;;;114206:21:0;:13;-1:-1:-1;;;;;114206:21:0;;114202:111;;114251:50;;;;;-1:-1:-1;;;;;14036:15:1;;;114251:50:0;;;14018:34:1;14068:18;;;14061:34;;;14131:15;;14111:18;;;14104:43;13930:18;;114251:50:0;13755:398:1;114202:111:0;113812:508;113732:588;;;:::o;137970:532::-;30573:21;25889:15;;;;;;;25888:16;;25936:14;;25742:30;26321:16;;:34;;;;;26341:14;26321:34;26301:54;;26366:17;26386:11;:16;;26401:1;26386:16;:50;;;;-1:-1:-1;26414:4:0;26406:25;:30;26386:50;26366:70;;26454:12;26453:13;:30;;;;;26471:12;26470:13;26453:30;26449:93;;;26507:23;;;;;;;;;;;;;;26449:93;26552:18;;;;26569:1;26552:18;;;26581:69;;;;26616:22;;;;;;;;26581:69;138207:39:::1;138221:10;138233:12;138207:13;:39::i;:::-;138257:48;138271:14;138287:17;138257:13;:48::i;:::-;138316:22;:20;:22::i;:::-;138349:24;:22;:24::i;:::-;138384;:22;:24::i;:::-;138439:4;138419:24:::0;;-1:-1:-1;;138419:24:0::1;::::0;::::1;::::0;;138456:38:::1;138419:17;138487:6:::0;138456:10:::1;:38::i;:::-;;26676:14:::0;26672:104;;;26707:23;;;;;;26750:14;;-1:-1:-1;14311:50:1;;26750:14:0;;14299:2:1;14284:18;26750:14:0;;;;;;;26672:104;25674:1109;;;;;137970:532;;;;;:::o;90410:138::-;89971:7;90068:14;;;88010:28;90068:14;;;;;:24;;;88290:16;88301:4;88290:10;:16::i;:::-;90515:25:::1;90526:4;90532:7;90515:10;:25::i;91547:251::-:0;-1:-1:-1;;;;;91641:34:0;;60115:10;91641:34;91637:104;;91699:30;;;;;;;;;;;;;;91637:104;91753:37;91765:4;91771:18;91753:11;:37::i;:::-;;91547:251;;:::o;152825:281::-;87441:4;88290:16;87441:4;88290:10;:16::i;:::-;152912:49:::1;::::0;152895:12:::1;::::0;152912:10:::1;::::0;152935:21:::1;::::0;152895:12;152912:49;152895:12;152912:49;152935:21;152912:10;:49:::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;152894:67;;;152977:7;152972:70;;153008:22;;;;;;;;;;;;;;152972:70;153057:41;::::0;153076:21:::1;2993:25:1::0;;153057:41:0::1;::::0;2981:2:1;2966:18;153057:41:0::1;;;;;;;;152883:223;152825:281:::0;:::o;114391:134::-;114478:39;114495:4;114501:2;114505:7;114478:39;;;;;;;;;;;;:16;:39::i;106280:217::-;104735:13;:11;:13::i;:::-;106396:36:::1;106414:17;106396;:36::i;:::-;106443:46;106465:17;106484:4;106443:21;:46::i;105813:136::-:0;105882:7;105015:20;:18;:20::i;:::-;-1:-1:-1;75915:66:0::1;105813:136:::0;:::o;111530:120::-;111593:7;111620:22;111634:7;111620:13;:22::i;111197:271::-;111260:7;110200:21;-1:-1:-1;;;;;111340:19:0;;111336:89;;111383:30;;;;;111410:1;111383:30;;;1784:74:1;1757:18;;111383:30:0;1638:226:1;111336:89:0;-1:-1:-1;;;;;111442:18:0;;;;;;;:11;;;;:18;;-1:-1:-1;111442:18:0;;;;;111197:271::o;98618:931::-;98721:13;98749:18;;98721:13;;;98749:18;98721:13;96221:21;99239:13;;98970:45;;-1:-1:-1;99239:18:0;:43;;;;-1:-1:-1;99261:16:0;;;;:21;99239:43;99231:77;;;;;;;14784:2:1;99231:77:0;;;14766:21:1;14823:2;14803:18;;;14796:30;14862:23;14842:18;;;14835:51;14903:18;;99231:77:0;14582:345:1;99231:77:0;99374:13;:11;:13::i;:::-;99402:16;:14;:16::i;:::-;99514;;;99497:1;99514:16;;;;;;;;;99321:220;;;;-1:-1:-1;99321:220:0;;-1:-1:-1;99433:13:0;;-1:-1:-1;99469:4:0;;-1:-1:-1;99497:1:0;-1:-1:-1;99514:16:0;-1:-1:-1;99321:220:0;-1:-1:-1;;98618:931:0:o;140569:1232::-;68543:21;:19;:21::i;:::-;140819:17:::1;::::0;::::1;;140814:84;;140860:26;;;;;;;;;;;;;;140814:84;140986:36:::0;;::::1;140982:114;;141046:38;;;;;;;;;;;;;;140982:114;141182:16;::::0;141209:170:::1;141229:19:::0;;::::1;141209:170;;;141288:8;;141297:1;141288:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;141277:28;::::0;141288:17:::1;;;141277:8:::0;:28:::1;:::i;:::-;141266:39:::0;-1:-1:-1;141349:3:0::1;;141209:170;;;;141489:8;141477:9;:20;141473:80;;;141521:20;;;;;;;;;;;;;;141473:80;141631:9;141626:168;141646:19:::0;;::::1;141626:168;;;141683:37;141693:8;;141702:1;141693:11;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;141706:10;;141717:1;141706:13;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;141683:9;:37::i;:::-;141764:3;;141626:168;;;;140709:1092;68587:20:::0;67058:1;67654:30;69281:23;69024:288;111935:153;112071:9;112064:16;;111982:13;;110200:21;;112064:16;;;:::i;113235:146::-;113321:52;60115:10;113354:8;113364;113321:18;:52::i;152478:191::-;87441:4;88290:16;87441:4;88290:10;:16::i;:::-;152578:17:::1;:36:::0;;-1:-1:-1;;152578:36:0::1;::::0;::::1;;::::0;;::::1;::::0;;;152630:31:::1;::::0;586:41:1;;;152630:31:0::1;::::0;574:2:1;559:18;152630:31:0::1;446:187:1::0;154085:154:0;130197:19;88290:16;88301:4;88290:10;:16::i;:::-;154188:5:::1;154168:17:::0;;;:8:::1;:17;::::0;;;;;:25;;-1:-1:-1;;154168:25:0::1;::::0;;154209:22;154177:7;;154209:22:::1;::::0;::::1;154085:154:::0;;:::o;114596:211::-;114710:31;114723:4;114729:2;114733:7;114710:12;:31::i;:::-;114752:47;114775:4;114781:2;114785:7;114794:4;114752:22;:47::i;139332:138::-;139441:21;;;;:11;:21;;;;;139434:28;;139398:23;;139441:21;139434:28;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;139332:138;;;:::o;139666:553::-;68543:21;:19;:21::i;:::-;139910:17:::1;::::0;::::1;;139905:84;;139951:26;;;;;;;;;;;;;;139905:84;140099:8;:14;;;140087:9;:26;140083:86;;;140137:20;;;;;;;;;;;;;;140083:86;140181:30;140191:8;140201:9;;140181;:30::i;:::-;68587:20:::0;67058:1;67654:30;69281:23;69024:288;90841:140;89971:7;90068:14;;;88010:28;90068:14;;;;;:24;;;88290:16;88301:4;88290:10;:16::i;:::-;90947:26:::1;90959:4;90965:7;90947:11;:26::i;153523:380::-:0;130197:19;88290:16;88301:4;88290:10;:16::i;:::-;153784:17:::1;::::0;;;:8:::1;:17;::::0;;;;;;:24;;-1:-1:-1;;153784:24:0::1;153804:4;153784:24;::::0;;153824:71;153793:7;;153824:71:::1;::::0;::::1;::::0;153847:9;;153858:10;;153870:5;;153877:4;;153883:11;;153824:71:::1;:::i;:::-;;;;;;;;153523:380:::0;;;;;;;:::o;88554:204::-;88639:4;88663:47;;;88678:32;88663:47;;:87;;;88714:36;88738:11;88714:23;:36::i;126390:247::-;126453:7;115480:18;;;:9;:18;;;;;;-1:-1:-1;;;;;115480:18:0;;126517:90;;126564:31;;;;;;;;2993:25:1;;;2966:18;;126564:31:0;2847:177:1;124506:122:0;124587:33;124596:2;124600:7;124609:4;124615;124587:8;:33::i;118705:886::-;118791:7;115480:18;;;:9;:18;;;;;;110200:21;;-1:-1:-1;;;;;115480:18:0;;;;118962;;;118958:88;;118997:37;119014:4;119020;119026:7;118997:16;:37::i;:::-;-1:-1:-1;;;;;119093:18:0;;;119089:265;;119211:48;119228:1;119232:7;119249:1;119253:5;119211:8;:48::i;:::-;-1:-1:-1;;;;;119305:17:0;;;;;;:11;;;:17;;;;;:22;;;;;;119089:265;-1:-1:-1;;;;;119370:16:0;;;119366:113;;-1:-1:-1;;;;;119432:15:0;;;;;;:11;;;:15;;;;;:20;;119451:1;119432:20;;;119366:113;119491:18;;;;:9;;;:18;;;;;;:23;;;;-1:-1:-1;;;;;119491:23:0;;;;;;;;;119532:27;;119491:18;;119532:27;;;;;;;119579:4;-1:-1:-1;;118705:886:0;;;;;;:::o;110363:151::-;28580:20;:18;:20::i;:::-;110467:39:::1;110491:5;110498:7;110467:23;:39::i;96844:149::-:0;28580:20;:18;:20::i;:::-;96947:38:::1;96971:4;96977:7;96947:23;:38::i;88334:66::-:0;28580:20;:18;:20::i;:::-;88334:66::o;67815:113::-;28580:20;:18;:20::i;:::-;67886:34:::1;:32;:34::i;92496:396::-:0;92573:4;89021:14;;;88010:28;89021:14;;;;;;;;-1:-1:-1;;;;;89021:31:0;;;;;;;;;;;;92660:225;;92704:8;:14;;;;;;;;;;;-1:-1:-1;;;;;92704:31:0;;;;;;;;;:38;;-1:-1:-1;;92704:38:0;92738:4;92704:38;;;92789:12;60115:10;;60035:98;92789:12;-1:-1:-1;;;;;92762:40:0;92780:7;-1:-1:-1;;;;;92762:40:0;92774:4;92762:40;;;;;;;;;;92824:4;92817:11;;;;;92660:225;92868:5;92861:12;;;;;89275:105;89342:30;89353:4;60115:10;89342;:30::i;:::-;89275:105;:::o;93136:397::-;93214:4;89021:14;;;88010:28;89021:14;;;;;;;;-1:-1:-1;;;;;89021:31:0;;;;;;;;;;;;93301:225;;;93378:5;93344:14;;;;;;;;;;;-1:-1:-1;;;;;93344:31:0;;;;;;;;;;:39;;-1:-1:-1;;93344:39:0;;;93403:40;60115:10;;93344:14;;93403:40;;93378:5;93403:40;93465:4;93458:11;;;;;106731:319;106813:4;-1:-1:-1;;;;;106822:6:0;106805:23;;;:121;;;106920:6;-1:-1:-1;;;;;106884:42:0;:32;75915:66;76649:53;-1:-1:-1;;;;;76649:53:0;;76570:140;106884:32;-1:-1:-1;;;;;106884:42:0;;;106805:121;106787:256;;;107002:29;;;;;;;;;;;;;;138742:130;130263:21;88290:16;88301:4;88290:10;:16::i;108224:548::-;108342:17;-1:-1:-1;;;;;108324:50:0;;:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;108324:52:0;;;;;;;;-1:-1:-1;;108324:52:0;;;;;;;;;;;;:::i;:::-;;;108320:445;;108693:60;;;;;-1:-1:-1;;;;;1802:55:1;;108693:60:0;;;1784:74:1;1757:18;;108693:60:0;1638:226:1;108320:445:0;75915:66;108419:40;;108415:122;;108487:34;;;;;;;;2993:25:1;;;2966:18;;108487:34:0;2847:177:1;108415:122:0;108551:54;108581:17;108600:4;108551:29;:54::i;107173:218::-;107248:4;-1:-1:-1;;;;;107257:6:0;107240:23;;107236:148;;107343:29;;;;;;;;;;;;;;99781:158;99924:7;99917:14;;99835:13;;96221:21;;99917:14;;;:::i;100174:164::-;100320:10;100313:17;;100231:13;;96221:21;;100313:17;;;:::i;68623:393::-;67654:30;68826:9;;:20;;68822:90;;68870:30;;;;;;;;;;;;;;68822:90;67101:1;68989:19;;68623:393::o;142110:2257::-;142229:15;142247:13;142349:35;142368:4;142374:9;;142349:18;:35::i;:::-;142484:9;142479:267;142503:17;;;;:4;:17;:::i;:::-;:24;;142499:1;:28;142479:267;;;142584:7;142550:122;142593:17;;;;:4;:17;:::i;:::-;142611:1;142593:20;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;:27;;;;:::i;:::-;142622:17;;;;:4;:17;:::i;:::-;142640:1;142622:20;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;:35;;;;;;;:::i;:::-;142550:122;;;;;;;;;:::i;:::-;;;;;;;;142716:3;;142479:267;;;-1:-1:-1;142824:13:0;;;;:4;:13;:::i;:::-;142801:20;;;;:11;:20;;;;;;:36;;;:20;:36;:::i;:::-;-1:-1:-1;142983:12:0;;142963:33;;;;:19;:33;;;;;142961:35;;;;;;;;;143011:15;;;;;143118;;;;142983:4;143118:15;:::i;:::-;:22;;:26;143114:80;;;143161:21;143177:4;143161:15;:21::i;:::-;143255:34;143265:14;;;;;;;;:::i;:::-;143281:7;143255:9;:34::i;:::-;143441:14;;;;;;;;:::i;:::-;143392:12;;;143470:33;;;:19;:33;;;;;;-1:-1:-1;;;;;143368:211:0;;;;;143419:7;;143392:12;143368:211;;143518:19;;;;143392:4;143518:19;:::i;:::-;143552:16;;;;:4;:16;:::i;:::-;143368:211;;;;;;;;;;:::i;:::-;;;;;;;;143596:19;;;;:24;143592:768;;143679:1;143641:26;;;;;;;;:::i;:::-;-1:-1:-1;;;;;143641:40:0;;143637:442;;143711:26;;;;;;;;:::i;:::-;-1:-1:-1;;;;;143702:54:0;;143779:12;;143814:24;;;;:11;;;:24;:::i;:::-;143861:14;;;;;;;;:::i;:::-;143898:18;;;;143939:19;;;;143981:21;;;;;;;;:::i;:::-;143702:361;;;;;;;;;;;;;;;;;;144025:19;;;;;143702:361;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;143637:442;144199:19;;;;;;144156:24;;144199:11;;;144156:24;:::i;:::-;-1:-1:-1;;;;;144100:248:0;144130:7;144100:248;144237:18;;;;144274:19;;;;144312:21;;;;;;;;:::i;:::-;144100:248;;;;;;;;:::i;:::-;;;;;;;;142188:2179;142110:2257;;;:::o;69024:288::-;67058:1;67654:30;69281:23;69024:288::o;125771:376::-;110200:21;-1:-1:-1;;;;;125935:22:0;;125931:93;;125981:31;;;;;-1:-1:-1;;;;;1802:55:1;;125981:31:0;;;1784:74:1;1757:18;;125981:31:0;1638:226:1;125931:93:0;-1:-1:-1;;;;;126034:27:0;;;;;;;:20;;;:27;;;;;;;;:37;;;;;;;;;;;;;:48;;-1:-1:-1;;126034:48:0;;;;;;;;;;126098:41;;586::1;;;126098::0;;559:18:1;126098:41:0;;;;;;;125864:283;125771:376;;;:::o;127187:799::-;-1:-1:-1;;;;;127304:14:0;;;:18;127300:679;;127343:71;;;;;-1:-1:-1;;;;;127343:36:0;;;;;:71;;60115:10;;127394:4;;127400:7;;127409:4;;127343:71;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;-1:-1:-1;127343:71:0;;;;;;;;-1:-1:-1;;127343:71:0;;;;;;;;;;;;:::i;:::-;;;127339:629;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;127657:6;:13;127674:1;127657:18;127653:300;;127707:25;;;;;-1:-1:-1;;;;;1802:55:1;;127707:25:0;;;1784:74:1;1757:18;;127707:25:0;1638:226:1;127653:300:0;127903:6;127897:13;127888:6;127884:2;127880:15;127873:38;127339:629;127462:51;;;127472:41;127462:51;127458:132;;127545:25;;;;;-1:-1:-1;;;;;1802:55:1;;127545:25:0;;;1784:74:1;1757:18;;127545:25:0;1638:226:1;127458:132:0;127415:190;127187:799;;;;:::o;110817:316::-;110930:4;110967:40;;;110982:25;110967:40;;:105;;-1:-1:-1;111024:48:0;;;111039:33;111024:48;110967:105;:158;;;-1:-1:-1;70750:25:0;70735:40;;;;111089:36;70635:148;124816:736;110200:21;125034:9;;:31;;-1:-1:-1;;;;;;125047:18:0;;;;125034:31;125030:471;;;125082:13;125098:22;125112:7;125098:13;:22::i;:::-;125082:38;-1:-1:-1;;;;;;125251:18:0;;;;;;:35;;;125282:4;-1:-1:-1;;;;;125273:13:0;:5;-1:-1:-1;;;;;125273:13:0;;;125251:35;:69;;;;-1:-1:-1;;;;;;113620:27:0;;;113540:4;113620:27;;;:20;:27;;;;;;;;:37;;;;;;;;;;;;125290:30;125251:69;125247:144;;;125348:27;;;;;-1:-1:-1;;;;;1802:55:1;;125348:27:0;;;1784:74:1;1757:18;;125348:27:0;1638:226:1;125247:144:0;125411:9;125407:83;;;125466:7;125462:2;-1:-1:-1;;;;;125446:28:0;125455:5;-1:-1:-1;;;;;125446:28:0;;;;;;;;;;;125407:83;125067:434;125030:471;125513:26;;;;:17;;:26;;-1:-1:-1;;125513:26:0;;;:31;;;;-1:-1:-1;;;;;125513:31:0;;;;;;;;;;124816:736::o;116854:376::-;116967:38;116981:5;116988:7;116997;116967:13;:38::i;:::-;116962:261;;-1:-1:-1;;;;;117026:19:0;;117022:190;;117073:31;;;;;;;;2993:25:1;;;2966:18;;117073:31:0;2847:177:1;117022:190:0;117152:44;;;;;-1:-1:-1;;;;;26613:55:1;;117152:44:0;;;26595:74:1;26685:18;;;26678:34;;;26568:18;;117152:44:0;26421:297:1;28740:145:0;30573:21;30254:40;;;;;;28803:75;;28849:17;;;;;;;;;;;;;;110522:223;28580:20;:18;:20::i;:::-;110200:21;;110692:15:::1;110702:5:::0;110200:21;110692:15:::1;:::i;:::-;-1:-1:-1::0;110718:9:0::1;::::0;::::1;:19;110730:7:::0;110718:9;:19:::1;:::i;97001:338::-:0;28580:20;:18;:20::i;:::-;96221:21;97170:7;:14:::1;97180:4:::0;97170:7;:14:::1;:::i;:::-;-1:-1:-1::0;97195:10:0::1;::::0;::::1;:20;97208:7:::0;97195:10;:20:::1;:::i;:::-;-1:-1:-1::0;97299:1:0::1;97283:17:::0;;;97311:16:::1;::::0;;::::1;:20:::0;-1:-1:-1;;97001:338:0:o;67936:186::-;28580:20;:18;:20::i;89516:201::-;88927:4;89021:14;;;88010:28;89021:14;;;;;;;;-1:-1:-1;;;;;89021:31:0;;;;;;;;;;;;89600:110;;89651:47;;;;;-1:-1:-1;;;;;26613:55:1;;89651:47:0;;;26595:74:1;26685:18;;;26678:34;;;26568:18;;89651:47:0;26421:297:1;77413:344:0;77505:37;77524:17;77505:18;:37::i;:::-;77558:27;;-1:-1:-1;;;;;77558:27:0;;;;;;;;77602:11;;:15;77598:152;;77634:53;77663:17;77682:4;77634:28;:53::i;77598:152::-;77720:18;:16;:18::i;144669:380::-;144767:14;144784:27;144795:4;144801:9;;144784:10;:27::i;:::-;-1:-1:-1;;;;;89021:31:0;;88927:4;89021:31;;;:14;;:31;:14;:31;;;144767:44;;-1:-1:-1;89021:31:0;;144822:88;;144879:19;;;;;;;;;;;;;;144822:88;144933:10;;;;;144924:20;;;;:8;:20;;;;;;;;;144920:84;;;144968:24;;;;;;;;;;;;;;144920:84;-1:-1:-1;;;145023:10:0;;;;;145014:20;;;;:8;:20;;;;;;:27;;-1:-1:-1;;145014:27:0;145037:4;145014:27;;;144669:380::o;145300:1440::-;145369:19;145460:6;145503:21;145369:19;145535:1198;145559:15;;;;:4;:15;:::i;:::-;:22;;145555:1;:26;145535:1198;;;145603:31;;;:15;;;;:4;:15;:::i;:::-;145619:1;145603:18;;;;;;;:::i;:::-;;;;;;:22;;;;;;;;;;:::i;:::-;:31;;;145599:97;;;145662:18;;;;;;;;;;;;;;145599:97;145777:22;145802:46;;;145816:15;;;;:4;:15;:::i;:::-;145832:1;145816:18;;;;;;;:::i;:::-;;;;;;:22;;;;;;;;;;:::i;:::-;145803:35;;;;:10;;;;:35;:::i;:::-;145802:46;;;;:::i;:::-;145777:71;-1:-1:-1;145877:28:0;145777:71;145877:11;:28;:::i;:::-;145863:42;;146031:4;:10;;;146017:11;:24;146013:98;;;146069:26;;;;;;;;;;;;;;146013:98;146143:15;146129:11;:29;146125:107;;;146186:30;;;;;;;;;;;;;;146125:107;146310:17;146330:15;;;;:4;:15;:::i;:::-;146346:1;146330:18;;;;;;;:::i;:::-;:28;;;:18;;;;;:28;;;;-1:-1:-1;146330:28:0;:::i;:::-;146310:48;-1:-1:-1;;;;;;146377:23:0;;;146373:287;;146422:12;146439:9;-1:-1:-1;;;;;146439:14:0;146461;146439:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;146421:59;;;146504:7;146499:86;;146543:22;;;;;;;;;;;;;;146499:86;146618:9;-1:-1:-1;;;;;146608:36:0;;146629:14;146608:36;;;;2993:25:1;;2981:2;2966:18;;2847:177;146608:36:0;;;;;;;;146402:258;146373:287;-1:-1:-1;;146703:3:0;;145535:1198;;120625:102;120693:26;120703:2;120707:7;120693:26;;;;;;;;;;;;:9;:26::i;116134:276::-;116237:4;-1:-1:-1;;;;;116274:21:0;;;;;;:128;;;116322:7;-1:-1:-1;;;;;116313:16:0;:5;-1:-1:-1;;;;;116313:16:0;;:52;;;-1:-1:-1;;;;;;113620:27:0;;;113540:4;113620:27;;;:20;:27;;;;;;;;:37;;;;;;;;;;;;116333:32;116313:88;;;-1:-1:-1;115697:7:0;115780:26;;;:17;:26;;;;;;-1:-1:-1;;;;;116369:32:0;;;115780:26;;116369:32;116313:88;116254:148;116134:276;-1:-1:-1;;;;116134:276:0:o;76806:286::-;76884:17;-1:-1:-1;;;;;76884:29:0;;76917:1;76884:34;76880:121;;76942:47;;;;;-1:-1:-1;;;;;1802:55:1;;76942:47:0;;;1784:74:1;1757:18;;76942:47:0;1638:226:1;76880:121:0;75915:66;77011:73;;;;-1:-1:-1;;;;;77011:73:0;;;;;;;;;;76806:286::o;4566:256::-;4649:12;4675;4689:23;4716:6;-1:-1:-1;;;;;4716:19:0;4736:4;4716:25;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4674:67;;;;4759:55;4786:6;4794:7;4803:10;4759:26;:55::i;:::-;4752:62;4566:256;-1:-1:-1;;;;;4566:256:0:o;81337:126::-;81388:9;:13;81384:72;;81425:19;;;;;;;;;;;;;;147138:221;147252:7;147277:14;147294:20;147309:4;147294:14;:20::i;:::-;147277:37;;147332:19;147347:3;;147332:19;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;147332:6:0;;:19;-1:-1:-1;;147332:14:0;:19;-1:-1:-1;147332:19:0:i;120954:185::-;121049:18;121055:2;121059:7;121049:5;:18::i;:::-;121078:53;121109:1;121113:2;121117:7;121126:4;121078:22;:53::i;5095:597::-;5243:12;5273:7;5268:417;;5297:19;5305:10;5297:7;:19::i;:::-;5268:417;;;5525:17;;:22;:49;;;;-1:-1:-1;;;;;;5551:18:0;;;:23;5525:49;5521:121;;;5602:24;;;;;-1:-1:-1;;;;;1802:55:1;;5602:24:0;;;1784:74:1;1757:18;;5602:24:0;1638:226:1;5521:121:0;-1:-1:-1;5663:10:0;5656:17;;147617:155;147688:7;147715:49;147742:20;147757:4;147742:14;:20::i;:::-;147732:31;;;;;;147715:16;:49::i;10581:259::-;10659:7;10680:17;10699:18;10719:16;10739:27;10750:4;10756:9;10739:10;:27::i;:::-;10679:87;;;;;;10777:28;10789:5;10796:8;10777:11;:28::i;:::-;-1:-1:-1;10823:9:0;;10581:259;-1:-1:-1;;;;10581:259:0:o;119927:335::-;-1:-1:-1;;;;;119995:16:0;;119991:89;;120035:33;;;;;120065:1;120035:33;;;1784:74:1;1757:18;;120035:33:0;1638:226:1;119991:89:0;120090:21;120114:32;120122:2;120126:7;120143:1;120114:7;:32::i;:::-;120090:56;-1:-1:-1;;;;;;120161:27:0;;;120157:98;;120212:31;;;;;120240:1;120212:31;;;1784:74:1;1757:18;;120212:31:0;1638:226:1;6245:528:0;6378:17;;:21;6374:392;;6610:10;6604:17;6667:15;6654:10;6650:2;6646:19;6639:44;6374:392;6737:17;;;;;;;;;;;;;;148041:548;148112:12;130792:460;148198:12;;148225:10;;;;148250;;;;148275:14;;;;;;;;:::i;:::-;148304:34;148318:19;;;;:4;:19;:::i;:::-;148304:13;:34::i;:::-;148353:28;148367:13;;;;:4;:13;:::i;148353:28::-;148396:31;148410:16;;;;:4;:16;:::i;148396:31::-;148442:38;148462:17;;;;:4;:17;:::i;:::-;148442:19;:38::i;:::-;148495:34;148513:15;;;;:4;:15;:::i;:::-;148495:17;:34::i;:::-;148544:26;148558:4;:11;;148544:13;:26::i;:::-;148144:437;;;;;;29950:25:1;;;;29991:18;;29984:34;;;;30034:18;;;30027:34;;;;30077:18;;;30070:34;;;;-1:-1:-1;;;;;30141:55:1;;;30120:19;;;30113:84;30213:19;;;30206:35;;;;30257:19;;;30250:35;30301:19;;;30294:35;30345:19;;;30338:35;30389:19;;;30382:35;30433:19;;;30426:36;29922:19;;148144:437:0;;;;;;;;;;;;;148137:444;;148041:548;;;:::o;98384:178::-;98461:7;98488:66;98521:20;:18;:20::i;:::-;98543:10;85082:4;85076:11;85113:10;85101:23;;85154:4;85145:14;;85138:39;;;;85207:4;85198:14;;85191:34;85264:4;85249:20;;;84877:410;8975:783;9056:7;9065:12;9079:7;9103:9;:16;9123:2;9103:22;9099:652;;9447:4;9432:20;;9426:27;9497:4;9482:20;;9476:27;9555:4;9540:20;;9534:27;9142:9;9526:36;9598:25;9609:4;9526:36;9426:27;9476;9598:10;:25::i;:::-;9591:32;;;;;;;;;;;9099:652;-1:-1:-1;;9721:16:0;;9672:1;;-1:-1:-1;9676:35:0;;9099:652;8975:783;;;;;:::o;14149:542::-;14245:20;14236:5;:29;;;;;;;;:::i;:::-;;14232:452;;14149:542;;:::o;14232:452::-;14343:29;14334:5;:38;;;;;;;;:::i;:::-;;14330:354;;14396:23;;;;;;;;;;;;;;14330:354;14450:35;14441:5;:44;;;;;;;;:::i;:::-;;14437:247;;14509:46;;;;;;;;2993:25:1;;;2966:18;;14509:46:0;2847:177:1;14437:247:0;14586:30;14577:5;:39;;;;;;;;:::i;:::-;;14573:111;;14640:32;;;;;;;;2993:25:1;;;2966:18;;14640:32:0;2847:177:1;148845:131:0;148916:7;148959;;148943:25;;;;;;;:::i;:::-;;;;;;;;148936:32;;148845:131;;;;:::o;149899:450::-;150013:7;;150082:6;150068:28;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;150068:28:0;;150038:58;;150112:9;150107:176;150127:17;;;150107:176;;;150188:20;150198:6;;150205:1;150198:9;;;;;;;:::i;:::-;;;;;;;;;;;;:::i;:::-;150188;:20::i;:::-;150178:31;;;;;;150162:10;150173:1;150162:13;;;;;;;;:::i;:::-;;;;;;;;;;:47;150253:3;;150107:176;;;;150329:10;150312:28;;;;;;;;:::i;:::-;;;;;;;;;;;;;150302:39;;;;;;150295:46;;;149899:450;;;;:::o;151185:433::-;151265:7;;151336:4;151322:26;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;151322:26:0;;151285:63;;151364:9;151359:186;151379:15;;;151359:186;;;151445:25;151462:4;;151467:1;151462:7;;;;;;;:::i;:::-;;;;;;151445:16;:25::i;:::-;151435:36;;;;;;151412:17;151430:1;151412:20;;;;;;;;:::i;:::-;;;;;;;;;;:59;151515:3;;151359:186;;151820:432;151892:7;130579:163;152007:17;;;;:4;:17;:::i;:::-;152043:12;;;;152074:11;;;;152104:12;;;;152135:14;;;;;;;;:::i;:::-;152168:12;;;;152199:19;;;;;;;;:::i;:::-;151943:290;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;151919:325;;;;;;151912:332;;151820:432;;;:::o;97430:111::-;97483:7;97510:23;:21;:23::i;:::-;97503:30;;97430:111;:::o;12052:1556::-;12183:7;;;13126:66;13113:79;;13109:166;;;-1:-1:-1;13225:1:0;;-1:-1:-1;13229:30:0;;-1:-1:-1;13261:1:0;13209:54;;13109:166;13389:24;;;13372:14;13389:24;;;;;;;;;32317:25:1;;;32390:4;32378:17;;32358:18;;;32351:45;;;;32412:18;;;32405:34;;;32455:18;;;32448:34;;;13389:24:0;;32289:19:1;;13389:24:0;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;13389:24:0;;-1:-1:-1;;13389:24:0;;;-1:-1:-1;;;;;;;13428:20:0;;13424:115;;-1:-1:-1;13481:1:0;;-1:-1:-1;13485:29:0;;-1:-1:-1;13481:1:0;;-1:-1:-1;13465:62:0;;13424:115;13559:6;-1:-1:-1;13567:20:0;;-1:-1:-1;13567:20:0;;-1:-1:-1;12052:1556:0;;;;;;;;;:::o;149283:272::-;149363:12;130343:65;149447:33;149461:18;:11;;:18;:::i;149447:33::-;149495:41;149509:26;;;;:11;:26;:::i;149495:41::-;149395:152;;;;;;32695:25:1;;;;32736:18;;32729:34;;;;32779:18;;;32772:34;32668:18;;149395:152:0;32493:319:1;150659:174:0;150736:12;130472:55;150800:14;;;;:4;:14;:::i;:::-;150816:8;;;;;;;;:::i;:::-;150768:57;;;;;;;;;33017:25:1;;;-1:-1:-1;;;;;33078:55:1;;;;33073:2;33058:18;;33051:83;33182:6;33170:19;33165:2;33150:18;;33143:47;33005:2;32990:18;;32817:379;97549:193:0;97604:7;95437:95;97663:17;:15;:17::i;:::-;97682:20;:18;:20::i;:::-;97641:92;;;;;;33460:25:1;;;;33501:18;;33494:34;;;;33544:18;;;33537:34;97704:13:0;33587:18:1;;;33580:34;97727:4:0;33630:19:1;;;33623:84;33432:19;;97641:92:0;;;;;;;;;;;;97631:103;;;;;;97624:110;;97549:193;:::o;100560:702::-;100610:7;96221:21;100610:7;100707:13;:11;:13::i;:::-;100735:18;;100686:34;;-1:-1:-1;100735:22:0;100731:524;;100781:22;;;;;;;;100560:702;-1:-1:-1;;100560:702:0:o;100731:524::-;101082:13;;101114:15;;101110:134;;101157:10;100560:702;-1:-1:-1;;;100560:702:0:o;101110:134::-;101215:13;101208:20;;;;;100560:702;:::o;101490:738::-;101543:7;96221:21;101543:7;101643:16;:14;:16::i;:::-;101674:21;;101619:40;;-1:-1:-1;101674:25:0;101670:551;;101723:25;;;;;;;;101490:738;-1:-1:-1;;101490:738:0:o;101670:551::-;102039:16;;;;102074:18;;102070:140;;102120:13;101490:738;-1:-1:-1;;;101490:738:0:o;14:177:1:-;99:66;92:5;88:78;81:5;78:89;68:117;;181:1;178;171:12;196:245;254:6;307:2;295:9;286:7;282:23;278:32;275:52;;;323:1;320;313:12;275:52;362:9;349:23;381:30;405:5;381:30;:::i;638:250::-;723:1;733:113;747:6;744:1;741:13;733:113;;;823:11;;;817:18;804:11;;;797:39;769:2;762:10;733:113;;;-1:-1:-1;;880:1:1;862:16;;855:27;638:250::o;893:330::-;935:3;973:5;967:12;1000:6;995:3;988:19;1016:76;1085:6;1078:4;1073:3;1069:14;1062:4;1055:5;1051:16;1016:76;:::i;:::-;1137:2;1125:15;-1:-1:-1;;1121:88:1;1112:98;;;;1212:4;1108:109;;893:330;-1:-1:-1;;893:330:1:o;1228:220::-;1377:2;1366:9;1359:21;1340:4;1397:45;1438:2;1427:9;1423:18;1415:6;1397:45;:::i;1453:180::-;1512:6;1565:2;1553:9;1544:7;1540:23;1536:32;1533:52;;;1581:1;1578;1571:12;1533:52;-1:-1:-1;1604:23:1;;1453:180;-1:-1:-1;1453:180:1:o;1869:196::-;1937:20;;-1:-1:-1;;;;;1986:54:1;;1976:65;;1966:93;;2055:1;2052;2045:12;1966:93;1869:196;;;:::o;2070:254::-;2138:6;2146;2199:2;2187:9;2178:7;2174:23;2170:32;2167:52;;;2215:1;2212;2205:12;2167:52;2238:29;2257:9;2238:29;:::i;:::-;2228:39;2314:2;2299:18;;;;2286:32;;-1:-1:-1;;;2070:254:1:o;2329:328::-;2406:6;2414;2422;2475:2;2463:9;2454:7;2450:23;2446:32;2443:52;;;2491:1;2488;2481:12;2443:52;2514:29;2533:9;2514:29;:::i;:::-;2504:39;;2562:38;2596:2;2585:9;2581:18;2562:38;:::i;:::-;2552:48;;2647:2;2636:9;2632:18;2619:32;2609:42;;2329:328;;;;;:::o;3029:184::-;3081:77;3078:1;3071:88;3178:4;3175:1;3168:15;3202:4;3199:1;3192:15;3218:334;3289:2;3283:9;3345:2;3335:13;;-1:-1:-1;;3331:86:1;3319:99;;3448:18;3433:34;;3469:22;;;3430:62;3427:88;;;3495:18;;:::i;:::-;3531:2;3524:22;3218:334;;-1:-1:-1;3218:334:1:o;3557:590::-;3600:5;3653:3;3646:4;3638:6;3634:17;3630:27;3620:55;;3671:1;3668;3661:12;3620:55;3707:6;3694:20;3733:18;3729:2;3726:26;3723:52;;;3755:18;;:::i;:::-;3799:114;3907:4;-1:-1:-1;;3831:4:1;3827:2;3823:13;3819:86;3815:97;3799:114;:::i;:::-;3938:2;3929:7;3922:19;3984:3;3977:4;3972:2;3964:6;3960:15;3956:26;3953:35;3950:55;;;4001:1;3998;3991:12;3950:55;4066:2;4059:4;4051:6;4047:17;4040:4;4031:7;4027:18;4014:55;4114:1;4089:16;;;4107:4;4085:27;4078:38;;;;4093:7;3557:590;-1:-1:-1;;;3557:590:1:o;4152:1019::-;4287:6;4295;4303;4311;4319;4372:3;4360:9;4351:7;4347:23;4343:33;4340:53;;;4389:1;4386;4379:12;4340:53;4429:9;4416:23;4458:18;4499:2;4491:6;4488:14;4485:34;;;4515:1;4512;4505:12;4485:34;4538:50;4580:7;4571:6;4560:9;4556:22;4538:50;:::i;:::-;4528:60;;4641:2;4630:9;4626:18;4613:32;4597:48;;4670:2;4660:8;4657:16;4654:36;;;4686:1;4683;4676:12;4654:36;4709:52;4753:7;4742:8;4731:9;4727:24;4709:52;:::i;:::-;4699:62;;4814:2;4803:9;4799:18;4786:32;4770:48;;4843:2;4833:8;4830:16;4827:36;;;4859:1;4856;4849:12;4827:36;4882:52;4926:7;4915:8;4904:9;4900:24;4882:52;:::i;:::-;4872:62;;4987:2;4976:9;4972:18;4959:32;4943:48;;5016:2;5006:8;5003:16;5000:36;;;5032:1;5029;5022:12;5000:36;;5055:52;5099:7;5088:8;5077:9;5073:24;5055:52;:::i;:::-;5045:62;;;5126:39;5160:3;5149:9;5145:19;5126:39;:::i;:::-;5116:49;;4152:1019;;;;;;;;:::o;5176:254::-;5244:6;5252;5305:2;5293:9;5284:7;5280:23;5276:32;5273:52;;;5321:1;5318;5311:12;5273:52;5357:9;5344:23;5334:33;;5386:38;5420:2;5409:9;5405:18;5386:38;:::i;:::-;5376:48;;5176:254;;;;;:::o;5435:395::-;5512:6;5520;5573:2;5561:9;5552:7;5548:23;5544:32;5541:52;;;5589:1;5586;5579:12;5541:52;5612:29;5631:9;5612:29;:::i;:::-;5602:39;;5692:2;5681:9;5677:18;5664:32;5719:18;5711:6;5708:30;5705:50;;;5751:1;5748;5741:12;5705:50;5774;5816:7;5807:6;5796:9;5792:22;5774:50;:::i;:::-;5764:60;;;5435:395;;;;;:::o;5835:186::-;5894:6;5947:2;5935:9;5926:7;5922:23;5918:32;5915:52;;;5963:1;5960;5953:12;5915:52;5986:29;6005:9;5986:29;:::i;6208:1335::-;6605:66;6597:6;6593:79;6582:9;6575:98;6556:4;6692:2;6730:3;6725:2;6714:9;6710:18;6703:31;6757:46;6798:3;6787:9;6783:19;6775:6;6757:46;:::i;:::-;6851:9;6843:6;6839:22;6834:2;6823:9;6819:18;6812:50;6885:33;6911:6;6903;6885:33;:::i;:::-;6949:2;6934:18;;6927:34;;;-1:-1:-1;;;;;6998:55:1;;6992:3;6977:19;;6970:84;7085:3;7070:19;;7063:35;;;7135:22;;;7129:3;7114:19;;7107:51;7207:13;;7229:22;;;7305:15;;;;-1:-1:-1;7267:15:1;;;;-1:-1:-1;7348:169:1;7362:6;7359:1;7356:13;7348:169;;;7423:13;;7411:26;;7492:15;;;;7457:12;;;;7384:1;7377:9;7348:169;;;-1:-1:-1;7534:3:1;;6208:1335;-1:-1:-1;;;;;;;;;;;;6208:1335:1:o;7548:384::-;7628:8;7638:6;7692:3;7685:4;7677:6;7673:17;7669:27;7659:55;;7710:1;7707;7700:12;7659:55;-1:-1:-1;7733:20:1;;7776:18;7765:30;;7762:50;;;7808:1;7805;7798:12;7762:50;7845:4;7837:6;7833:17;7821:29;;7905:3;7898:4;7888:6;7885:1;7881:14;7873:6;7869:27;7865:38;7862:47;7859:67;;;7922:1;7919;7912:12;7859:67;7548:384;;;;;:::o;7937:846::-;8098:6;8106;8114;8122;8175:2;8163:9;8154:7;8150:23;8146:32;8143:52;;;8191:1;8188;8181:12;8143:52;8231:9;8218:23;8260:18;8301:2;8293:6;8290:14;8287:34;;;8317:1;8314;8307:12;8287:34;8356:87;8435:7;8426:6;8415:9;8411:22;8356:87;:::i;:::-;8462:8;;-1:-1:-1;8330:113:1;-1:-1:-1;8550:2:1;8535:18;;8522:32;;-1:-1:-1;8566:16:1;;;8563:36;;;8595:1;8592;8585:12;8563:36;;8634:89;8715:7;8704:8;8693:9;8689:24;8634:89;:::i;:::-;7937:846;;;;-1:-1:-1;8742:8:1;-1:-1:-1;;;;7937:846:1:o;8788:160::-;8853:20;;8909:13;;8902:21;8892:32;;8882:60;;8938:1;8935;8928:12;8953:254;9018:6;9026;9079:2;9067:9;9058:7;9054:23;9050:32;9047:52;;;9095:1;9092;9085:12;9047:52;9118:29;9137:9;9118:29;:::i;:::-;9108:39;;9166:35;9197:2;9186:9;9182:18;9166:35;:::i;9212:180::-;9268:6;9321:2;9309:9;9300:7;9296:23;9292:32;9289:52;;;9337:1;9334;9327:12;9289:52;9360:26;9376:9;9360:26;:::i;9397:538::-;9492:6;9500;9508;9516;9569:3;9557:9;9548:7;9544:23;9540:33;9537:53;;;9586:1;9583;9576:12;9537:53;9609:29;9628:9;9609:29;:::i;:::-;9599:39;;9657:38;9691:2;9680:9;9676:18;9657:38;:::i;:::-;9647:48;;9742:2;9731:9;9727:18;9714:32;9704:42;;9797:2;9786:9;9782:18;9769:32;9824:18;9816:6;9813:30;9810:50;;;9856:1;9853;9846:12;9810:50;9879;9921:7;9912:6;9901:9;9897:22;9879:50;:::i;:::-;9869:60;;;9397:538;;;;;;;:::o;9940:857::-;10047:6;10055;10063;10116:2;10104:9;10095:7;10091:23;10087:32;10084:52;;;10132:1;10129;10122:12;10084:52;10172:9;10159:23;10201:18;10242:2;10234:6;10231:14;10228:34;;;10258:1;10255;10248:12;10228:34;10281:22;;;;10337:3;10319:16;;;10315:26;10312:46;;;10354:1;10351;10344:12;10312:46;10377:2;;-1:-1:-1;10432:2:1;10417:18;;10404:32;;10448:16;;;10445:36;;;10477:1;10474;10467:12;10445:36;10515:8;10504:9;10500:24;10490:34;;10562:7;10555:4;10551:2;10547:13;10543:27;10533:55;;10584:1;10581;10574:12;10533:55;10624:2;10611:16;10650:2;10642:6;10639:14;10636:34;;;10666:1;10663;10656:12;10636:34;10711:7;10706:2;10697:6;10693:2;10689:15;10685:24;10682:37;10679:57;;;10732:1;10729;10722:12;10679:57;10763:2;10759;10755:11;10745:21;;10785:6;10775:16;;;;;9940:857;;;;;:::o;10802:260::-;10870:6;10878;10931:2;10919:9;10910:7;10906:23;10902:32;10899:52;;;10947:1;10944;10937:12;10899:52;10970:29;10989:9;10970:29;:::i;:::-;10960:39;;11018:38;11052:2;11041:9;11037:18;11018:38;:::i;11067:943::-;11120:5;11173:3;11166:4;11158:6;11154:17;11150:27;11140:55;;11191:1;11188;11181:12;11140:55;11227:6;11214:20;11253:4;11276:18;11313:2;11309;11306:10;11303:36;;;11319:18;;:::i;:::-;11365:2;11362:1;11358:10;11388:28;11412:2;11408;11404:11;11388:28;:::i;:::-;11450:15;;;11520;;;11516:24;;;11481:12;;;;11552:15;;;11549:35;;;11580:1;11577;11570:12;11549:35;11616:2;11608:6;11604:15;11593:26;;11628:353;11644:6;11639:3;11636:15;11628:353;;;11730:3;11717:17;11766:2;11753:11;11750:19;11747:109;;;11810:1;11839:2;11835;11828:14;11747:109;11881:57;11934:3;11929:2;11915:11;11907:6;11903:24;11899:33;11881:57;:::i;:::-;11869:70;;-1:-1:-1;11661:12:1;;;;11959;;;;11628:353;;;11999:5;11067:943;-1:-1:-1;;;;;;;;11067:943:1:o;12015:150::-;12090:20;;12139:1;12129:12;;12119:40;;12155:1;12152;12145:12;12170:1138;12383:6;12391;12399;12407;12415;12423;12476:3;12464:9;12455:7;12451:23;12447:33;12444:53;;;12493:1;12490;12483:12;12444:53;12529:9;12516:23;12506:33;;12590:2;12579:9;12575:18;12562:32;12613:18;12654:2;12646:6;12643:14;12640:34;;;12670:1;12667;12660:12;12640:34;12693:60;12745:7;12736:6;12725:9;12721:22;12693:60;:::i;:::-;12683:70;;12806:2;12795:9;12791:18;12778:32;12762:48;;12835:2;12825:8;12822:16;12819:36;;;12851:1;12848;12841:12;12819:36;12874:52;12918:7;12907:8;12896:9;12892:24;12874:52;:::i;:::-;12864:62;;12976:2;12965:9;12961:18;12948:32;12935:45;;13009:1;13002:5;12999:12;12989:40;;13025:1;13022;13015:12;12989:40;13048:5;13038:15;;13072:46;13113:3;13102:9;13098:19;13072:46;:::i;:::-;13062:56;;13171:3;13160:9;13156:19;13143:33;13127:49;;13201:2;13191:8;13188:16;13185:36;;;13217:1;13214;13207:12;13185:36;;13240:62;13294:7;13283:8;13272:9;13268:24;13240:62;:::i;:::-;13230:72;;;12170:1138;;;;;;;;:::o;13313:437::-;13392:1;13388:12;;;;13435;;;13456:61;;13510:4;13502:6;13498:17;13488:27;;13456:61;13563:2;13555:6;13552:14;13532:18;13529:38;13526:218;;13600:77;13597:1;13590:88;13701:4;13698:1;13691:15;13729:4;13726:1;13719:15;13526:218;;13313:437;;;:::o;14932:184::-;14984:77;14981:1;14974:88;15081:4;15078:1;15071:15;15105:4;15102:1;15095:15;15121:384;15215:4;15273:11;15260:25;15363:66;15352:8;15336:14;15332:29;15328:102;15308:18;15304:127;15294:155;;15445:1;15442;15435:12;15294:155;15466:33;;;;;15121:384;-1:-1:-1;;15121:384:1:o;15510:184::-;15562:77;15559:1;15552:88;15659:4;15656:1;15649:15;15683:4;15680:1;15673:15;15699:125;15764:9;;;15785:10;;;15782:36;;;15798:18;;:::i;15829:580::-;15906:4;15912:6;15972:11;15959:25;16062:66;16051:8;16035:14;16031:29;16027:102;16007:18;16003:127;15993:155;;16144:1;16141;16134:12;15993:155;16171:33;;16223:20;;;-1:-1:-1;16266:18:1;16255:30;;16252:50;;;16298:1;16295;16288:12;16252:50;16331:4;16319:17;;-1:-1:-1;16362:14:1;16358:27;;;16348:38;;16345:58;;;16399:1;16396;16389:12;16414:184;16466:77;16463:1;16456:88;16563:4;16560:1;16553:15;16587:4;16584:1;16577:15;16603:616;16655:3;16693:5;16687:12;16720:6;16715:3;16708:19;16746:4;16787:2;16782:3;16778:12;16812:11;16839;16832:18;;16889:6;16886:1;16882:14;16875:5;16871:26;16859:38;;16931:2;16924:5;16920:14;16952:1;16962:231;16976:6;16973:1;16970:13;16962:231;;;17047:5;17041:4;17037:16;17032:3;17025:29;17075:38;17108:4;17099:6;17093:13;17075:38;:::i;:::-;17171:12;;;;17067:46;-1:-1:-1;17136:15:1;;;;16998:1;16991:9;16962:231;;;-1:-1:-1;17209:4:1;;16603:616;-1:-1:-1;;;;;;;16603:616:1:o;17224:948::-;17613:4;17653:1;17645:6;17642:13;17632:47;;17659:18;;:::i;:::-;17706:6;17695:9;17688:25;17743:1;17735:6;17732:13;17722:47;;17749:18;;:::i;:::-;17805:6;17800:2;17789:9;17785:18;17778:34;17848:3;17843:2;17832:9;17828:18;17821:31;17875:46;17916:3;17905:9;17901:19;17893:6;17875:46;:::i;:::-;17969:9;17961:6;17957:22;17952:2;17941:9;17937:18;17930:50;18003:43;18039:6;18031;18003:43;:::i;:::-;17989:57;;18095:9;18087:6;18083:22;18077:3;18066:9;18062:19;18055:51;18123:43;18159:6;18151;18123:43;:::i;18177:184::-;18247:6;18300:2;18288:9;18279:7;18275:23;18271:32;18268:52;;;18316:1;18313;18306:12;18268:52;-1:-1:-1;18339:16:1;;18177:184;-1:-1:-1;18177:184:1:o;18366:639::-;18494:4;18500:6;18560:11;18547:25;18650:66;18639:8;18623:14;18619:29;18615:102;18595:18;18591:127;18581:155;;18732:1;18729;18722:12;18581:155;18759:33;;18811:20;;;-1:-1:-1;18854:18:1;18843:30;;18840:50;;;18886:1;18883;18876:12;18840:50;18919:4;18907:17;;-1:-1:-1;18970:1:1;18966:14;;;18950;18946:35;18936:46;;18933:66;;;18995:1;18992;18985:12;19010:391;19111:4;19169:11;19156:25;19259:66;19248:8;19232:14;19228:29;19224:102;19204:18;19200:127;19190:155;;19341:1;19338;19331:12;19992:326;20081:6;20076:3;20069:19;20133:6;20126:5;20119:4;20114:3;20110:14;20097:43;;20185:1;20178:4;20169:6;20164:3;20160:16;20156:27;20149:38;20051:3;20307:4;-1:-1:-1;;20232:2:1;20224:6;20220:15;20216:88;20211:3;20207:98;20203:109;20196:116;;19992:326;;;;:::o;20323:437::-;20540:2;20529:9;20522:21;20503:4;20566:62;20624:2;20613:9;20609:18;20601:6;20593;20566:62;:::i;:::-;20676:9;20668:6;20664:22;20659:2;20648:9;20644:18;20637:50;20704;20747:6;20739;20731;20704:50;:::i;:::-;20696:58;20323:437;-1:-1:-1;;;;;;;20323:437:1:o;20891:545::-;20993:2;20988:3;20985:11;20982:448;;;21029:1;21054:5;21050:2;21043:17;21099:4;21095:2;21085:19;21169:2;21157:10;21153:19;21150:1;21146:27;21140:4;21136:38;21205:4;21193:10;21190:20;21187:47;;;-1:-1:-1;21228:4:1;21187:47;21283:2;21278:3;21274:12;21271:1;21267:20;21261:4;21257:31;21247:41;;21338:82;21356:2;21349:5;21346:13;21338:82;;;21401:17;;;21382:1;21371:13;21338:82;;;21342:3;;;20891:545;;;:::o;21672:1325::-;21796:18;21791:3;21788:27;21785:53;;;21818:18;;:::i;:::-;21847:94;21937:3;21897:38;21929:4;21923:11;21897:38;:::i;:::-;21891:4;21847:94;:::i;:::-;21967:1;21992:2;21987:3;21984:11;22009:1;22004:735;;;;22783:1;22800:3;22797:93;;;-1:-1:-1;22856:19:1;;;22843:33;22797:93;21578:66;21569:1;21565:11;;;21561:84;21557:89;21547:100;21653:1;21649:11;;;21544:117;22903:78;;21977:1014;;22004:735;20838:1;20831:14;;;20875:4;20862:18;;-1:-1:-1;;22040:76:1;;;22200:9;22222:229;22236:7;22233:1;22230:14;22222:229;;;22325:19;;;22312:33;22297:49;;22432:4;22417:20;;;;22385:1;22373:14;;;;22252:12;22222:229;;;22226:3;22479;22470:7;22467:16;22464:219;;;22599:66;22593:3;22587;22584:1;22580:11;22576:21;22572:94;22568:99;22555:9;22550:3;22546:19;22533:33;22529:139;22521:6;22514:155;22464:219;;;22726:1;22720:3;22717:1;22713:11;22709:19;22703:4;22696:33;21977:1014;;21672:1325;;;:::o;23002:636::-;23127:4;23133:6;23193:11;23180:25;23283:66;23272:8;23256:14;23252:29;23248:102;23228:18;23224:127;23214:155;;23365:1;23362;23355:12;23214:155;23392:33;;23444:20;;;-1:-1:-1;23487:18:1;23476:30;;23473:50;;;23519:1;23516;23509:12;23473:50;23552:4;23540:17;;-1:-1:-1;23603:1:1;23599:14;;;23583;23579:35;23569:46;;23566:66;;;23628:1;23625;23618:12;23643:508;23888:6;23877:9;23870:25;23931:2;23926;23915:9;23911:18;23904:30;23851:4;23957:62;24015:2;24004:9;24000:18;23992:6;23984;23957:62;:::i;:::-;24067:9;24059:6;24055:22;24050:2;24039:9;24035:18;24028:50;24095;24138:6;24130;24122;24095:50;:::i;24156:269::-;24228:6;24281:2;24269:9;24260:7;24256:23;24252:32;24249:52;;;24297:1;24294;24287:12;24249:52;24336:9;24323:23;24375:1;24368:5;24365:12;24355:40;;24391:1;24388;24381:12;24430:140;24511:1;24504:5;24501:12;24491:46;;24517:18;;:::i;:::-;24546;;24430:140::o;24575:716::-;24901:25;;;-1:-1:-1;;;;;25023:15:1;;;25018:2;25003:18;;24996:43;25075:15;;25070:2;25055:18;;25048:43;25122:2;25107:18;;25100:34;;;25165:3;25150:19;;25143:35;;;24888:3;24873:19;;25187:54;25236:3;25221:19;;25213:6;25187:54;:::i;:::-;25278:6;25272:3;25261:9;25257:19;25250:35;24575:716;;;;;;;;;;:::o;25296:349::-;25509:25;;;25565:2;25550:18;;25543:34;;;25497:2;25482:18;;25586:53;25635:2;25620:18;;25612:6;25586:53;:::i;25650:512::-;25844:4;-1:-1:-1;;;;;25954:2:1;25946:6;25942:15;25931:9;25924:34;26006:2;25998:6;25994:15;25989:2;25978:9;25974:18;25967:43;;26046:6;26041:2;26030:9;26026:18;26019:34;26089:3;26084:2;26073:9;26069:18;26062:31;26110:46;26151:3;26140:9;26136:19;26128:6;26110:46;:::i;:::-;26102:54;25650:512;-1:-1:-1;;;;;;25650:512:1:o;26167:249::-;26236:6;26289:2;26277:9;26268:7;26264:23;26260:32;26257:52;;;26305:1;26302;26295:12;26257:52;26337:9;26331:16;26356:30;26380:5;26356:30;:::i;26723:1471::-;26849:3;26843:10;26876:18;26868:6;26865:30;26862:56;;;26898:18;;:::i;:::-;26927:97;27017:6;26977:38;27009:4;27003:11;26977:38;:::i;:::-;26971:4;26927:97;:::i;:::-;27079:4;;27143:2;27132:14;;27160:1;27155:782;;;;27981:1;27998:6;27995:89;;;-1:-1:-1;28050:19:1;;;28044:26;27995:89;21578:66;21569:1;21565:11;;;21561:84;21557:89;21547:100;21653:1;21649:11;;;21544:117;28097:81;;27125:1063;;27155:782;20838:1;20831:14;;;20875:4;20862:18;;-1:-1:-1;;27191:79:1;;;27368:236;27382:7;27379:1;27376:14;27368:236;;;27471:19;;;27465:26;27450:42;;27563:27;;;;27531:1;27519:14;;;;27398:19;;27368:236;;;27372:3;27632:6;27623:7;27620:19;27617:261;;;27693:19;;;27687:26;27794:66;27776:1;27772:14;;;27788:3;27768:24;27764:97;27760:102;27745:118;27730:134;;27617:261;-1:-1:-1;;;;;27924:1:1;27908:14;;;27904:22;27891:36;;-1:-1:-1;26723:1471:1:o;28501:272::-;28559:6;28612:2;28600:9;28591:7;28587:23;28583:32;28580:52;;;28628:1;28625;28618:12;28580:52;28667:9;28654:23;28717:6;28710:5;28706:18;28699:5;28696:29;28686:57;;28739:1;28736;28729:12;28778:168;28851:9;;;28882;;28899:15;;;28893:22;;28879:37;28869:71;;28920:18;;:::i;28951:274::-;28991:1;29017;29007:189;;29052:77;29049:1;29042:88;29153:4;29150:1;29143:15;29181:4;29178:1;29171:15;29007:189;-1:-1:-1;29210:9:1;;28951:274::o;29230:287::-;29359:3;29397:6;29391:13;29413:66;29472:6;29467:3;29460:4;29452:6;29448:17;29413:66;:::i;30473:271::-;30656:6;30648;30643:3;30630:33;30612:3;30682:16;;30707:13;;;30682:16;30473:271;-1:-1:-1;30473:271:1:o;30749:543::-;30967:13;;30910:3;;30941;;31020:4;31047:15;;;30910:3;31090:175;31104:6;31101:1;31098:13;31090:175;;;31167:13;;31153:28;;31203:14;;;;31240:15;;;;31126:1;31119:9;31090:175;;;-1:-1:-1;31281:5:1;;30749:543;-1:-1:-1;;;;;;30749:543:1:o;31297:788::-;31596:4;31638:3;31627:9;31623:19;31615:27;;31669:6;31658:9;31651:25;-1:-1:-1;;;;;31785:2:1;31777:6;31773:15;31768:2;31757:9;31753:18;31746:43;31825:6;31820:2;31809:9;31805:18;31798:34;31868:6;31863:2;31852:9;31848:18;31841:34;31912:6;31906:3;31895:9;31891:19;31884:35;31928:54;31977:3;31966:9;31962:19;31954:6;31928:54;:::i;:::-;32019:6;32013:3;32002:9;31998:19;31991:35;32075:2;32067:6;32063:15;32057:3;32046:9;32042:19;32035:44;;31297:788;;;;;;;;;;;:::o
Swarm Source
ipfs://d641aad21c3ca498622dfeb8388974c2087706c65ed04e2442b2f0907474a090
Loading...
Loading
Loading...
Loading
Loading...
Loading
Net Worth in USD
$0.00
Net Worth in ETH
0
Multichain Portfolio | 35 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.