ETH Price: $2,480.23 (+3.18%)
 

Overview

Max Total Supply

6,666 HYA

Holders

1,820

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A

Other Info

Balance
2 HYA
0x9fb2c4a7fd4b1d1db2bc96e748d2f5ed6843892e
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume
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 Source Code Verified (Exact Match)

Contract Name:
NFT

Compiler Version
v0.8.13+commit.abaa5c0e

Optimization Enabled:
Yes with 1000000 runs

Other Settings:
default evmVersion
File 1 of 25 : NFT.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";
import "./ERC721M.sol";
import "./DefaultOperatorFilterer.sol";

contract NFT is ERC721M, ReentrancyGuard, Ownable, DefaultOperatorFilterer {
    using EnumerableSet for EnumerableSet.AddressSet;
    using EnumerableSet for EnumerableSet.UintSet;
    using SafeMath for uint256;

    event CrossChain(
        address indexed from,
        bytes32 indexed h,
        bytes32 indexed f,
        uint256 tokenId
    );
    event Redeem(address indexed receiver, uint256 indexed tokenId);
    event Stake(
        address indexed account,
        uint256 indexed tokenId,
        uint256 indexed timestamp
    );
    event UnStake(
        address indexed account,
        uint256 indexed tokenId,
        uint256 indexed timestamp
    );
    event OperationResult(bool result);

    EnumerableSet.AddressSet private _customDisableMarket;
    EnumerableSet.AddressSet private _rota;
    EnumerableSet.UintSet private _ticket;

    // CROSS-CHAIN
    uint256 public crossChainPrice = 0.009 ether;
    bool public crossChainOpen = false;

    // TEAM
    uint256 _teamLimit = 1400;
    uint256 public teamMinted;

    // OG
    uint256 _ogLimit = 3;
    uint256 _ogPrice = 0.035 ether;
    bool public ogMintingOpen = false;
    mapping(address => uint256) public ogMinted;
    bytes32 public ogRoot;

    // WL
    uint256 _wlLimit = 2;
    uint256 _wlPrice = 0.04 ether;
    bool public wlMintingOpen = false;
    mapping(address => uint256) public wlMinted;
    bytes32 public wlRoot;

    // PUBLIC
    uint256 _publicPrice = 0.12 ether;
    bool public publicMintingOpen = false;

    // STAKE
    bool public stakingOpen = false;
    uint256 _stakeBase = 1 days;
    mapping(uint256 => uint256) private stakingStarted;
    mapping(uint256 => uint256) private stakingTotal;
    mapping(uint256 => uint256) private tokenStakingCycle;

    // SPECIAL
    bytes32 public bcnRoot;
    mapping(uint256 => uint256) public bcnMinted;

    // ETHEREUM
    string _baseTokenURI;
    uint256 _counter;
    uint256 _maxSupply = 7388;
    uint256 _maxIndex = 8888;

    constructor(string memory name, string memory symbol)
        ERC721M(name, symbol, _maxIndex)
    {
        addDisableMarket(0xF849de01B080aDC3A814FaBE1E2087475cF2E354);
        addDisableMarket(0x024aC22ACdB367a3ae52A3D94aC6649fdc1f0779);
    }

    // ACCESS
    modifier onlyMinter() {
        require(
            isMinter(_msgSender()),
            "Roles: Caller does not have the minter role"
        );
        _;
    }

    modifier onlyApprovedOrOwner(uint256 tokenId) {
        require(
            _isApprovedOrOwner(_msgSender(), tokenId),
            "ERC721Common: Not approved nor owner"
        );
        _;
    }

    // METADATA
    function baseURI() public view returns (string memory) {
        return _baseURI();
    }

    function setBaseURI(string memory newBaseTokenURI) public onlyOwner {
        _baseTokenURI = newBaseTokenURI;
    }

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

    // FOR MARKET
    function addDisableMarket(address value) public onlyOwner{
        bool result = _customDisableMarket.add(value);
        emit OperationResult(result);
    }

    function removeDisableMarket(address value) public onlyOwner {
        bool result = _customDisableMarket.remove(value);
        emit OperationResult(result);
    }

    // FOR CROSS-CHAIN
    function isMinter(address value) public view returns (bool) {
        return _rota.contains(value);
    }

    function addMinter(address value) public onlyOwner {
        bool result = _rota.add(value);
        emit OperationResult(result);
    }

    function removeMinter(address value) public onlyOwner {
        bool result = _rota.remove(value);
        emit OperationResult(result);
    }

    function minterNumber() public view returns (uint256) {
        return _rota.length();
    }

    function minterList() public view returns (address[] memory) {
        return _rota.values();
    }

    // FOR STAKING
    function isStakingCycle(uint256 value) public view returns (bool) {
        return _ticket.contains(value);
    }

    function addStakingCycle(uint256 value) public {
        bool result = _ticket.add(value);
        emit OperationResult(result);
    }

    function removeStakingCycle(uint256 value) public {
        bool result = _ticket.remove(value);
        emit OperationResult(result);
    }

    function stakingCycleList() public view returns (uint256[] memory) {
        return _ticket.values();
    }

    // UTILS
    function _reverse(bool state) internal pure returns (bool) {
        if (state) {
            return false;
        }
        return true;
    }

    function _verify(
        address addr,
        bytes32[] calldata proof,
        bytes32 root
    ) internal pure {
        bytes32 leaf = keccak256(abi.encodePacked(addr));
        require(MerkleProof.verify(proof, root, leaf), "Invalid address!");
    }

    // USUAL
    function exists(uint256 tokenId) public view returns (bool) {
        return _exists(tokenId);
    }

    function totalSupply() public view returns (uint256) {
        return _counter;
    }

    function _multiMintV2(
        address to,
        uint256 fromTokenId,
        uint256 quantity
    ) internal {
        _multiMint(to, fromTokenId, quantity);
        _counter = SafeMath.add(_counter, quantity);
    }

    // USUAL SPECIAL
    function _checkNotDisableMarket(address operator) internal view {
       if (_customDisableMarket.contains(operator)) {
            revert OperatorNotAllowed(msg.sender);
        }
    }

    function setApprovalForAll(address operator, bool approved)
        public
        override
        onlyAllowedOperator(operator)
    {
        _checkNotDisableMarket(operator);
        super.setApprovalForAll(operator, approved);
    }

    function approve(address operator, uint256 tokenId)
        public
        override
        onlyAllowedOperator(operator)
    {
        _checkNotDisableMarket(operator);
        super.approve(operator, tokenId);
    }

    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override onlyAllowedOperator(from) {
        _checkNotDisableMarket(from);
        super.transferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override onlyAllowedOperator(from) {
        _checkNotDisableMarket(from);        
        super.safeTransferFrom(from, to, tokenId);
    }

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public override onlyAllowedOperator(from) {
        _checkNotDisableMarket(from);
        super.safeTransferFrom(from, to, tokenId, data);
    }

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal override {
        super._beforeTokenTransfer(from, to, tokenId);
        require(stakingStarted[tokenId] == 0, "Error: staking");
    }

    // SETTINGS
    function setRoot(
        bytes32 _og,
        bytes32 _wl,
        bytes32 _bcn
    ) public onlyOwner {
        ogRoot = _og;
        wlRoot = _wl;
        bcnRoot = _bcn;
    }

    function setOgMintingOpen() public onlyOwner {
        ogMintingOpen = _reverse(ogMintingOpen);
    }

    function setWlMintingOpen() public onlyOwner {
        wlMintingOpen = _reverse(wlMintingOpen);
    }

    function setPublicMintingOpen() public onlyOwner {
        publicMintingOpen = _reverse(publicMintingOpen);
    }

    function setStakingOpen() public onlyOwner {
        stakingOpen = _reverse(stakingOpen);
    }

    function setCrossChainOpen() public onlyOwner {
        crossChainOpen = _reverse(crossChainOpen);
    }

    function setCrossChainPrice(uint256 amount) public onlyOwner {
        crossChainPrice = amount;
    }

    // MINT
    function _ensureMint(
        bool state,
        uint256 quantity,
        uint256 price
    ) internal view {
        require(state, "Mint Closed!");
        require(_msgSender() == tx.origin, "Invalid address");
        require(quantity > 0, "Invalid mint quantity!");
        require(msg.value >= SafeMath.mul(price, quantity), "Insufficient funds!");
        require(SafeMath.add(_counter, quantity) <= _maxSupply, "Current chain mint limit");
    }

    function mintByBcn(
        bytes32[] calldata proof,
        address bcn,
        uint256 bcnTokenId,
        address receiver,
        uint256 quantity
    ) public payable nonReentrant {
        _ensureMint(wlMintingOpen, quantity, _wlPrice);

        uint256 minted = wlMinted[_msgSender()].add(quantity);
        require(minted <= _wlLimit, "Address receive number Limited");
        require(
            isBcnOwner(proof, bcn, bcnTokenId, receiver),
            "Not bcn family owner"
        );

        wlMinted[receiver] = minted;
        _multiMintV2(receiver, _counter, quantity);
    }

    function ogMint(bytes32[] calldata proof, uint256 quantity) public payable nonReentrant {
        _ensureMint(ogMintingOpen, quantity, _ogPrice);

        uint256 minted = ogMinted[_msgSender()].add(quantity);
        require(minted <= _ogLimit, "Mint Limited!");
        _verify(_msgSender(), proof, ogRoot);

        ogMinted[_msgSender()] = minted;
        _multiMintV2(_msgSender(), _counter, quantity);
    }

    function wlMint(bytes32[] calldata proof, uint256 quantity) public payable nonReentrant {
        _ensureMint(wlMintingOpen, quantity, _wlPrice);
        uint256 minted = wlMinted[_msgSender()].add(quantity);
        require(minted <= _wlLimit, "Mint Limited!");

        _verify(_msgSender(), proof, wlRoot);
        wlMinted[_msgSender()] = minted;
        _multiMintV2(_msgSender(), _counter, quantity);
    }

    function publicMint(uint256 quantity) public payable nonReentrant {
        _ensureMint(publicMintingOpen, quantity, _publicPrice);
        _multiMintV2(_msgSender(), _counter, quantity);
    }

    function teamMint(address receiver, uint256 quantity) public onlyOwner {
        uint256 minted = teamMinted.add(quantity);
        require(minted <= _teamLimit, "Mint Limited!");
        teamMinted = minted;
        _multiMintV2(receiver, _counter, quantity);
    }

    // STAKE
    function toggleStaking(uint256 tokenId, uint256 cycle)
        internal
        onlyApprovedOrOwner(tokenId)
    {
        require(isStakingCycle(cycle), "Invalid staking cycle");
        uint256 start = stakingStarted[tokenId];
        uint256 currentTime = block.timestamp;

        if (start == 0) {
            require(stakingOpen, "Staking closed");

            tokenStakingCycle[tokenId] = cycle;
            stakingStarted[tokenId] = currentTime;

            emit Stake(_msgSender(), tokenId, cycle);
        } else {
            uint256 pasted = SafeMath.sub(block.timestamp, start);
            uint256 needed = SafeMath.mul(tokenStakingCycle[tokenId], _stakeBase);
            require(pasted > needed, "Not unstake time");

            stakingTotal[tokenId] = SafeMath.mul(stakingTotal[tokenId], needed);
            stakingStarted[tokenId] = 0;
            emit UnStake(_msgSender(), tokenId, needed);
        }
    }

    function toggleStaking(
        uint256[] calldata tokenIds,
        uint256[] calldata cycles
    ) external nonReentrant {
        require(stakingOpen, "Staking closed");

        uint256 n = tokenIds.length;
        for (uint256 i = 0; i < n; ++i) {
            toggleStaking(tokenIds[i], cycles[i]);
        }
    }

    function stakingPeriod(uint256 tokenId)
        external
        view
        returns (
            bool staking,
            uint256 pasted,
            uint256 needed,
            uint256 total
        )
    {
        uint256 start = stakingStarted[tokenId];
        if (start != 0) {
            staking = true;
            pasted = SafeMath.sub(block.timestamp, start);
            needed = SafeMath.mul(tokenStakingCycle[tokenId], _stakeBase);
        }
        total = stakingTotal[tokenId];
    }

    // OTHERS
    function isBcnOwner(
        bytes32[] calldata proof,
        address bcn,
        uint256 bcnTokenId,
        address receiver
    ) public view returns (bool) {
        _verify(bcn, proof, bcnRoot);

        address tokenOwner = IERC721(bcn).ownerOf(bcnTokenId);
        if (receiver == tokenOwner) {
            return true;
        }
        return false;
    }

    // CROSS-CHAIN
    function redeem(address receiver, uint256 tokenId) public onlyMinter {
        require(crossChainOpen, "Cross-chain Closed");
        require(tokenId < _maxIndex, "Token");

        _multiMintV2(receiver, tokenId, 1);
        emit Redeem(receiver, tokenId);
    }

    function transferToAnotherChain(
        uint256 tokenId,
        bytes32 h,
        bytes32 f
    ) public payable onlyApprovedOrOwner(tokenId) nonReentrant {
        require(crossChainOpen, "Cross-chain Closed");
        require(
            msg.value == crossChainPrice,
            "Just send correct number of ether"
        );

        _burn(tokenId);
        _counter--;
        emit CrossChain(_msgSender(), h, f, tokenId);
    }

    // MONEY
    function withdraw() public onlyOwner nonReentrant {
        (bool success, ) = payable(_msgSender()).call{
            value: address(this).balance
        }("");
        require(
            success,
            "Address: unable to send value, recipient may have reverted"
        );
    }
}

File 2 of 25 : ERC721M.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import "./BaseERC721.sol";
import "./EnumerableBitMaps.sol";


abstract contract ERC721M is BaseERC721 {
    using BitMaps for BitMaps.BitMap;
    using EnumerableBitMaps for BitMaps.BitMap;

    struct Ownership {
        address owner;
        uint64 startedAt;
    }

    struct Holdings {
        BitMaps.BitMap tokens;
    }

    uint256 private immutable _size; // the maximum number of token IDs (fixed at construction)
    mapping(uint256 => Ownership) private _owners; // token ID => owner mapping
    mapping(address => Holdings) private _holdings; // per-user bitmap of owned token IDs

    constructor(
        string memory name,
        string memory symbol,
        uint256 size_
    ) BaseERC721(name, symbol) {
        _size = size_;
    }

    function balanceOf(address owner)
    public
    view
    virtual
    override
    returns (uint256)
    {
        require(
            owner != address(0),
            "ERC721: balance query for the zero address"
        );
        return _holdings[owner].tokens.countSet(_size);
    }

    function ownerOf(uint256 tokenId)
    public
    view
    virtual
    override
    returns (address)
    {
        address owner = _owners[tokenId].owner;
        require(
            owner != address(0),
            "ERC721: owner query for nonexistent token"
        );
        return owner;
    }

    function _exists(uint256 tokenId)
    internal
    view
    virtual
    override
    returns (bool)
    {
        return _owners[tokenId].owner != address(0);
    }

    function _anyExists(uint256 fromTokenId, uint256 quantity)
    internal
    view
    virtual
    override
    returns (bool)
    {
        for (uint256 i = 0; i < quantity; i++) {
            if (_owners[fromTokenId + i].owner != address(0)) {
                return true;
            }
        }
        return false;
    }

    function _doMint(address to, uint256 tokenId) internal virtual override {
        require(tokenId < _size, "token ID out of range");
        _owners[tokenId].owner = to;
        _owners[tokenId].startedAt = uint64(block.timestamp);

        _holdings[to].tokens.set(tokenId);
    }

    function _doMultiMint(
        address to,
        uint256 fromTokenId,
        uint256 quantity
    ) internal virtual override {
        require(fromTokenId + quantity <= _size, "token ID out of range");
        for (uint256 i = 0; i < quantity; i++) {
            _owners[fromTokenId + i].owner = to;
            _owners[fromTokenId + i].startedAt = uint64(block.timestamp);
        }
        _holdings[to].tokens.setMulti(fromTokenId, quantity);
    }

    function _doBurn(address owner, uint256 tokenId) internal virtual override {
        _owners[tokenId].owner = address(0);
        _owners[tokenId].startedAt = 0;
        _holdings[owner].tokens.unset(tokenId);
    }

    function _doTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        _holdings[from].tokens.unset(tokenId);
        _holdings[to].tokens.set(tokenId);

        _owners[tokenId].owner = to;
        _owners[tokenId].startedAt = uint64(block.timestamp);
    }

    function tokenOfOwnerByIndex(address owner, uint256 index)
    public
    view
    returns (uint256)
    {
        (bool wasFound, uint256 position) = _holdings[owner].tokens.indexOfNth(
            index + 1,
            _size
        );
        require(wasFound, "ERC721Enumerable: owner index out of bounds");
        return position;
    }
}

File 3 of 25 : DefaultOperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {OperatorFilterer} from "./OperatorFilterer.sol";

/**
 * @title  DefaultOperatorFilterer
 * @notice Inherits from OperatorFilterer and automatically subscribes to the default OpenSea subscription.
 */
abstract contract DefaultOperatorFilterer is OperatorFilterer {
    address constant DEFAULT_SUBSCRIPTION = address(0x3cc6CddA760b79bAfa08dF41ECFA224f810dCeB6);

    constructor() OperatorFilterer(DEFAULT_SUBSCRIPTION, true) {}
}

File 4 of 25 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 5 of 25 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (security/ReentrancyGuard.sol)

pragma solidity ^0.8.0;

/**
 * @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 ReentrancyGuard {
    // 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;

    uint256 private _status;

    constructor() {
        _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 {
        // On the first call to nonReentrant, _status will be _NOT_ENTERED
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;
    }

    function _nonReentrantAfter() private {
        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}

File 6 of 25 : EnumerableSet.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/structs/EnumerableSet.sol)
// This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.

pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 *
 * [WARNING]
 * ====
 * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure
 * unusable.
 * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info.
 *
 * In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an
 * array of EnumerableSet.
 * ====
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;
        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) {
            // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastValue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastValue;
                // Update the index for the moved value
                set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        return set._values[index];
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function _values(Set storage set) private view returns (bytes32[] memory) {
        return set._values;
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
        bytes32[] memory store = _values(set._inner);
        bytes32[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(AddressSet storage set) internal view returns (address[] memory) {
        bytes32[] memory store = _values(set._inner);
        address[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(UintSet storage set) internal view returns (uint256[] memory) {
        bytes32[] memory store = _values(set._inner);
        uint256[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }
}

File 7 of 25 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Tree proofs.
 *
 * The tree and the proofs can be generated using our
 * https://github.com/OpenZeppelin/merkle-tree[JavaScript library].
 * You will find a quickstart guide in the readme.
 *
 * WARNING: You should avoid using leaf values that are 64 bytes long prior to
 * hashing, or use a hash function other than keccak256 for hashing leaves.
 * This is because the concatenation of a sorted pair of internal nodes in
 * the merkle tree could be reinterpreted as a leaf value.
 * OpenZeppelin's JavaScript library generates merkle trees that are safe
 * against this attack out of the box.
 */
library MerkleProof {
    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    function verify(
        bytes32[] memory proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProof(proof, leaf) == root;
    }

    /**
     * @dev Calldata version of {verify}
     *
     * _Available since v4.7._
     */
    function verifyCalldata(
        bytes32[] calldata proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProofCalldata(proof, leaf) == root;
    }

    /**
     * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up
     * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt
     * hash matches the root of the tree. When processing the proof, the pairs
     * of leafs & pre-images are assumed to be sorted.
     *
     * _Available since v4.4._
     */
    function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Calldata version of {processProof}
     *
     * _Available since v4.7._
     */
    function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Returns true if the `leaves` can be simultaneously proven to be a part of a merkle tree defined by
     * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function multiProofVerify(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProof(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Calldata version of {multiProofVerify}
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function multiProofVerifyCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProofCalldata(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Returns the root of a tree reconstructed from `leaves` and sibling nodes in `proof`. The reconstruction
     * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another
     * leaf/inner node or a proof sibling node, depending on whether each `proofFlags` item is true or false
     * respectively.
     *
     * CAUTION: Not all merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree
     * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the
     * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer).
     *
     * _Available since v4.7._
     */
    function processMultiProof(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    /**
     * @dev Calldata version of {processMultiProof}.
     *
     * CAUTION: Not all merkle trees admit multiproofs. See {processMultiProof} for details.
     *
     * _Available since v4.7._
     */
    function processMultiProofCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuild the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        require(leavesLen + proof.length - 1 == totalHashes, "MerkleProof: invalid multiproof");

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value for the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i] ? leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++] : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            return hashes[totalHashes - 1];
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) {
        return a < b ? _efficientHash(a, b) : _efficientHash(b, a);
    }

    function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) {
        /// @solidity memory-safe-assembly
        assembly {
            mstore(0x00, a)
            mstore(0x20, b)
            value := keccak256(0x00, 0x40)
        }
    }
}

File 8 of 25 : SafeMath.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol)

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    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.
     *
     * _Available since v3.4._
     */
    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.
     *
     * _Available since v3.4._
     */
    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.
     *
     * _Available since v3.4._
     */
    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.
     *
     * _Available since v3.4._
     */
    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 addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        return a + b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

File 9 of 25 : BaseERC721.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import "@openzeppelin/contracts/utils/Address.sol";
import "@openzeppelin/contracts/utils/Context.sol";
import "@openzeppelin/contracts/utils/Strings.sol";
import "@openzeppelin/contracts/utils/introspection/ERC165.sol";
import "@openzeppelin/contracts/interfaces/IERC721.sol";
import "@openzeppelin/contracts/interfaces/IERC721Metadata.sol";
import "@openzeppelin/contracts/interfaces/IERC721Receiver.sol";


abstract contract BaseERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

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

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

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

    /**
     * @dev Returns whether any of `quantity` tokens `fromTokenId` exists.
     */
    function _anyExists(uint256 fromTokenId, uint256 quantity)
    internal
    view
    virtual
    returns (bool);

    function _doMint(address to, uint256 tokenId) internal virtual;

    function _doMultiMint(
        address to,
        uint256 fromTokenId,
        uint256 quantity
    ) internal virtual;

    function _doBurn(address owner, uint256 tokenId) internal virtual;

    function _doTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual;

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

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

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

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId)
    public
    view
    virtual
    override
    returns (string memory)
    {
        require(
            _exists(tokenId),
            "ERC721Metadata: URI query for nonexistent token"
        );

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

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

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

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

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId)
    public
    view
    virtual
    override
    returns (address)
    {
        require(
            _exists(tokenId),
            "ERC721: approved query for nonexistent token"
        );
        return _tokenApprovals[uint8(tokenId)];
    }

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

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

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

        _transfer(from, to, tokenId);
    }

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

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

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

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

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

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

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

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

        _doMint(to, tokenId);

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

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

    /**
     * @dev Mints `quantity` tokens `fromTokenId` and transfers them to `to`.
     */
    function _multiMint(
        address to,
        uint256 fromTokenId,
        uint256 quantity
    ) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(
            !_anyExists(fromTokenId, quantity),
            "ERC721: token already minted"
        );

        for (uint256 i = 0; i < quantity; i++) {
            _beforeTokenTransfer(address(0), to, fromTokenId + i);
        }

        _doMultiMint(to, fromTokenId, quantity);

        for (uint256 i = 0; i < quantity; i++) {
            emit Transfer(address(0), to, fromTokenId + i);
            _afterTokenTransfer(address(0), to, fromTokenId + i);
        }
    }

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

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

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

        _doBurn(owner, tokenId);

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

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

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

        _beforeTokenTransfer(from, to, tokenId);

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

        _doTransfer(from, to, tokenId);

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

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

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

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

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

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

File 10 of 25 : EnumerableBitMaps.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import "@openzeppelin/contracts/utils/structs/BitMaps.sol";

library EnumerableBitMaps {
    function countSet(BitMaps.BitMap storage bitmap, uint256 indexLimit)
    internal
    view
    returns (uint256)
    {
        uint256 count = 0;
        uint256 bucketIndex = 0;
        uint256 bucketLimit = ((indexLimit - 1) >> 8) + 1;
        while (bucketIndex < bucketLimit) {
            uint256 bucketData = bitmap._data[bucketIndex];
            while (bucketData != 0) {
                bucketData &= (bucketData - 1);
                count++;
            }
            bucketIndex++;
        }
        return count;
    }

    function indexOfNth(
        BitMaps.BitMap storage bitmap,
        uint256 n,
        uint256 indexLimit
    )
    internal
    view
    returns (
        bool found,
        uint256 position
    )
    {
        (
        bool bucketFound,
        uint256 bucketIndex,
        uint256 count
        ) = indexOfNthBucket(bitmap, n, indexLimit);

        if (!bucketFound) {
            return (false, 0);
        }

        uint256 bucketData = bitmap._data[bucketIndex];
        for (uint256 i = 0; i < 256; i++) {
            if (bucketData & 1 != 0) {
                count++;
                if (count == n) {
                    return (true, i + bucketIndex * 256);
                }
            }
            bucketData >>= 1;
        }

        return (false, 0);
    }

    function indexOfNthBucket(
        BitMaps.BitMap storage bitmap,
        uint256 n,
        uint256 indexLimit
    )
    internal
    view
    returns (
        bool found,
        uint256 bucketIndex,
        uint256 bucketStartCount
    )
    {
        found = false;
        bucketIndex = 0;
        bucketStartCount = 0;
        uint256 count = 0;
        uint256 bucketLimit = ((indexLimit - 1) >> 8) + 1;
        while (bucketIndex < bucketLimit) {
            uint256 bucketData = bitmap._data[bucketIndex];
            bucketStartCount = count;
            while (bucketData != 0) {
                bucketData &= (bucketData - 1);
                count++;
                if (count == n) {
                    found = true;
                    return (found, bucketIndex, bucketStartCount);
                }
            }
            bucketIndex++;
        }
        return (found, bucketIndex, bucketStartCount);
    }

    function setMulti(
        BitMaps.BitMap storage bitmap,
        uint256 fromIndex,
        uint256 count
    ) internal {
        uint256 index = fromIndex;
        uint256 toIndex = fromIndex + count;
        while (index < toIndex) {
            uint256 bucket = index >> 8;
            uint256 remainingBitOnCount = toIndex - index;
            uint256 bucketBitOnStartIndex = index & 0xff;
            uint256 bucketBitOnCount = 256 - bucketBitOnStartIndex;
            if (bucketBitOnCount > remainingBitOnCount) {
                bucketBitOnCount = remainingBitOnCount;
            }
            uint256 mask = maskN(bucketBitOnCount) << bucketBitOnStartIndex;
            bitmap._data[bucket] |= mask;
            index += bucketBitOnCount;
        }
    }

    function maskN(uint256 n) internal pure returns (uint256) {
        if (n >= 256) {
            return type(uint256).max;
        }
        return (1 << n) - 1;
    }
}

File 11 of 25 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

File 12 of 25 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) 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(errorMessage);
        }
    }
}

File 13 of 25 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)

pragma solidity ^0.8.0;

import "./math/Math.sol";

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _SYMBOLS = "0123456789abcdef";
    uint8 private constant _ADDRESS_LENGTH = 20;

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        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), _SYMBOLS))
                }
                value /= 10;
                if (value == 0) break;
            }
            return buffer;
        }
    }

    /**
     * @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) {
        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] = _SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }

    /**
     * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
     */
    function toHexString(address addr) internal pure returns (string memory) {
        return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
    }
}

File 14 of 25 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC721.sol)

pragma solidity ^0.8.0;

import "../token/ERC721/IERC721.sol";

File 15 of 25 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC721Metadata.sol)

pragma solidity ^0.8.0;

import "../token/ERC721/extensions/IERC721Metadata.sol";

File 16 of 25 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC721Receiver.sol)

pragma solidity ^0.8.0;

import "../token/ERC721/IERC721Receiver.sol";

File 17 of 25 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 18 of 25 : Math.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)

pragma solidity ^0.8.0;

/**
 * @dev Standard math utilities missing in the Solidity language.
 */
library Math {
    enum Rounding {
        Down, // Toward negative infinity
        Up, // Toward infinity
        Zero // Toward zero
    }

    /**
     * @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 up instead
     * of rounding down.
     */
    function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
        // (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; // Least significant 256 bits of the product
            uint256 prod1; // Most significant 256 bits of the product
            assembly {
                let mm := mulmod(x, y, not(0))
                prod0 := mul(x, y)
                prod1 := sub(sub(mm, prod0), lt(mm, prod0))
            }

            // Handle non-overflow cases, 256 by 256 division.
            if (prod1 == 0) {
                return prod0 / denominator;
            }

            // Make sure the result is less than 2^256. Also prevents denominator == 0.
            require(denominator > prod1);

            ///////////////////////////////////////////////
            // 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.

            // Does not overflow because the denominator cannot be zero at this stage in the function.
            uint256 twos = denominator & (~denominator + 1);
            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 (rounding == Rounding.Up && 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 down.
     *
     * 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 + (rounding == Rounding.Up && result * result < a ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 2, rounded down, of a positive value.
     * 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 + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 10, rounded down, of a positive value.
     * 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 + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 256, rounded down, of a positive value.
     * 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 10, 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 + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
        }
    }
}

File 19 of 25 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: 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 caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

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

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

File 20 of 25 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

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

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

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

pragma solidity ^0.8.0;

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

File 23 of 25 : BitMaps.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/structs/BitMaps.sol)
pragma solidity ^0.8.0;

/**
 * @dev Library for managing uint256 to bool mapping in a compact and efficient way, providing the keys are sequential.
 * Largely inspired by Uniswap's https://github.com/Uniswap/merkle-distributor/blob/master/contracts/MerkleDistributor.sol[merkle-distributor].
 */
library BitMaps {
    struct BitMap {
        mapping(uint256 => uint256) _data;
    }

    /**
     * @dev Returns whether the bit at `index` is set.
     */
    function get(BitMap storage bitmap, uint256 index) internal view returns (bool) {
        uint256 bucket = index >> 8;
        uint256 mask = 1 << (index & 0xff);
        return bitmap._data[bucket] & mask != 0;
    }

    /**
     * @dev Sets the bit at `index` to the boolean `value`.
     */
    function setTo(
        BitMap storage bitmap,
        uint256 index,
        bool value
    ) internal {
        if (value) {
            set(bitmap, index);
        } else {
            unset(bitmap, index);
        }
    }

    /**
     * @dev Sets the bit at `index`.
     */
    function set(BitMap storage bitmap, uint256 index) internal {
        uint256 bucket = index >> 8;
        uint256 mask = 1 << (index & 0xff);
        bitmap._data[bucket] |= mask;
    }

    /**
     * @dev Unsets the bit at `index`.
     */
    function unset(BitMap storage bitmap, uint256 index) internal {
        uint256 bucket = index >> 8;
        uint256 mask = 1 << (index & 0xff);
        bitmap._data[bucket] &= ~mask;
    }
}

File 24 of 25 : OperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {IOperatorFilterRegistry} from "./IOperatorFilterRegistry.sol";

/**
 * @title  OperatorFilterer
 * @notice Abstract contract whose constructor automatically registers and optionally subscribes to or copies another
 *         registrant's entries in the OperatorFilterRegistry.
 */
abstract contract OperatorFilterer {
    error OperatorNotAllowed(address operator);

    IOperatorFilterRegistry constant OPERATOR_FILTER_REGISTRY =
        IOperatorFilterRegistry(0x000000000000AAeB6D7670E522A718067333cd4E);

    constructor(address subscriptionOrRegistrantToCopy, bool subscribe) {
        // If an inheriting token contract is deployed to a network without the registry deployed, the modifier
        // will not revert, but the contract will need to be registered with the registry once it is deployed in
        // order for the modifier to filter addresses.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (subscribe) {
                OPERATOR_FILTER_REGISTRY.registerAndSubscribe(address(this), subscriptionOrRegistrantToCopy);
            } else {
                if (subscriptionOrRegistrantToCopy != address(0)) {
                    OPERATOR_FILTER_REGISTRY.registerAndCopyEntries(address(this), subscriptionOrRegistrantToCopy);
                } else {
                    OPERATOR_FILTER_REGISTRY.register(address(this));
                }
            }
        }
    }

    modifier onlyAllowedOperator(address from) virtual {
        // Check registry code length to facilitate testing in environments without a deployed registry.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            // Allow spending tokens from addresses with balance
            // Note that this still allows listings and marketplaces with escrow to transfer tokens if transferred
            // from an EOA.
            if (from == msg.sender) {
                _;
                return;
            }
            if (!(
                    OPERATOR_FILTER_REGISTRY.isOperatorAllowed(address(this), msg.sender)
                    && OPERATOR_FILTER_REGISTRY.isOperatorAllowed(address(this), from)
                )) {
                revert OperatorNotAllowed(msg.sender);
            }
        }
        _;
    }
}

File 25 of 25 : IOperatorFilterRegistry.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

interface IOperatorFilterRegistry {
    function isOperatorAllowed(address registrant, address operator) external view returns (bool);
    function register(address registrant) external;
    function registerAndSubscribe(address registrant, address subscription) external;
    function registerAndCopyEntries(address registrant, address registrantToCopy) external;
    function unregister(address addr) external;
    function updateOperator(address registrant, address operator, bool filtered) external;
    function updateOperators(address registrant, address[] calldata operators, bool filtered) external;
    function updateCodeHash(address registrant, bytes32 codehash, bool filtered) external;
    function updateCodeHashes(address registrant, bytes32[] calldata codeHashes, bool filtered) external;
    function subscribe(address registrant, address registrantToSubscribe) external;
    function unsubscribe(address registrant, bool copyExistingEntries) external;
    function subscriptionOf(address addr) external returns (address registrant);
    function subscribers(address registrant) external returns (address[] memory);
    function subscriberAt(address registrant, uint256 index) external returns (address);
    function copyEntriesOf(address registrant, address registrantToCopy) external;
    function isOperatorFiltered(address registrant, address operator) external returns (bool);
    function isCodeHashOfFiltered(address registrant, address operatorWithCode) external returns (bool);
    function isCodeHashFiltered(address registrant, bytes32 codeHash) external returns (bool);
    function filteredOperators(address addr) external returns (address[] memory);
    function filteredCodeHashes(address addr) external returns (bytes32[] memory);
    function filteredOperatorAt(address registrant, uint256 index) external returns (address);
    function filteredCodeHashAt(address registrant, uint256 index) external returns (bytes32);
    function isRegistered(address addr) external returns (bool);
    function codeHashOf(address addr) external returns (bytes32);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 1000000
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"OperatorNotAllowed","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":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"bytes32","name":"h","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"f","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"CrossChain","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"result","type":"bool"}],"name":"OperationResult","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"receiver","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Redeem","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"Stake","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":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"UnStake","type":"event"},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"name":"addDisableMarket","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"name":"addMinter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"addStakingCycle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","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":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"bcnMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"bcnRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"crossChainOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"crossChainPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":"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":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"address","name":"bcn","type":"address"},{"internalType":"uint256","name":"bcnTokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"}],"name":"isBcnOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"name":"isMinter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"isStakingCycle","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"address","name":"bcn","type":"address"},{"internalType":"uint256","name":"bcnTokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"mintByBcn","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"minterList","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minterNumber","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"ogMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"ogMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ogMintingOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ogRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"publicMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"publicMintingOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"redeem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"name":"removeDisableMarket","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"value","type":"address"}],"name":"removeMinter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"}],"name":"removeStakingCycle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","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":"string","name":"newBaseTokenURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setCrossChainOpen","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"setCrossChainPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setOgMintingOpen","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setPublicMintingOpen","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_og","type":"bytes32"},{"internalType":"bytes32","name":"_wl","type":"bytes32"},{"internalType":"bytes32","name":"_bcn","type":"bytes32"}],"name":"setRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setStakingOpen","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"setWlMintingOpen","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stakingCycleList","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stakingOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"stakingPeriod","outputs":[{"internalType":"bool","name":"staking","type":"bool"},{"internalType":"uint256","name":"pasted","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"},{"internalType":"uint256","name":"total","type":"uint256"}],"stateMutability":"view","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":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"teamMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"teamMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"cycles","type":"uint256[]"}],"name":"toggleStaking","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes32","name":"h","type":"bytes32"},{"internalType":"bytes32","name":"f","type":"bytes32"}],"name":"transferToAnotherChain","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"wlMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"wlMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wlMintingOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"wlRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"}]

60a0604052661ff973cafa8000600e55600f805460ff199081169091556105786010556003601255667c58508723800060135560148054821690556002601755668e1bc9bf0400006018556019805490911690556701aa535d3d0c0000601c55601d805461ffff1916905562015180601e55611cdc6026556122b86027553480156200008a57600080fd5b506040516200586038038062005860833981016040819052620000ad91620005a0565b733cc6cdda760b79bafa08df41ecfa224f810dceb66001838360275482828160009080519060200190620000e39291906200042d565b508051620000f99060019060208401906200042d565b5050506080525050600160065562000111336200029f565b6daaeb6d7670e522a718067333cd4e3b1562000256578015620001a457604051633e9f1edf60e11b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e90637d3e3dbe906044015b600060405180830381600087803b1580156200018557600080fd5b505af11580156200019a573d6000803e3d6000fd5b5050505062000256565b6001600160a01b03821615620001f55760405163a0af290360e01b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e9063a0af2903906044016200016a565b604051632210724360e11b81523060048201526daaeb6d7670e522a718067333cd4e90634420e48690602401600060405180830381600087803b1580156200023c57600080fd5b505af115801562000251573d6000803e3d6000fd5b505050505b5062000278905073f849de01b080adc3a814fabe1e2087475cf2e354620002f1565b6200029773024ac22acdb367a3ae52a3d94ac6649fdc1f0779620002f1565b505062000646565b600780546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b620002fb6200035a565b600062000318826008620003bb60201b620029041790919060201c565b90507fed9840e0775590557ad736875d96c95cf1458b766335f74339951a32c82a9e33816040516200034e911515815260200190565b60405180910390a15050565b6007546001600160a01b03163314620003b95760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640160405180910390fd5b565b6000620003d2836001600160a01b038416620003db565b90505b92915050565b60008181526001830160205260408120546200042457508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620003d5565b506000620003d5565b8280546200043b906200060a565b90600052602060002090601f0160209004810192826200045f5760008555620004aa565b82601f106200047a57805160ff1916838001178555620004aa565b82800160010185558215620004aa579182015b82811115620004aa5782518255916020019190600101906200048d565b50620004b8929150620004bc565b5090565b5b80821115620004b85760008155600101620004bd565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620004fb57600080fd5b81516001600160401b0380821115620005185762000518620004d3565b604051601f8301601f19908116603f01168101908282118183101715620005435762000543620004d3565b816040528381526020925086838588010111156200056057600080fd5b600091505b8382101562000584578582018301518183018401529082019062000565565b83821115620005965760008385830101525b9695505050505050565b60008060408385031215620005b457600080fd5b82516001600160401b0380821115620005cc57600080fd5b620005da86838701620004e9565b93506020850151915080821115620005f157600080fd5b506200060085828601620004e9565b9150509250929050565b600181811c908216806200061f57607f821691505b6020821081036200064057634e487b7160e01b600052602260045260246000fd5b50919050565b6080516151f0620006706000396000818161155601528181611bfd015261436901526151f06000f3fe6080604052600436106103b85760003560e01c806378a92380116101f2578063b4742cdf1161010d578063e682b93d116100a0578063e9b1683a1161006f578063e9b1683a14610ae7578063f0dff7d314610b14578063f2fde38b14610b2e578063f9df0f4b14610b4e57600080fd5b8063e682b93d14610a48578063e8b5498d14610a5b578063e985e9c514610a71578063e99b7a8614610ac757600080fd5b8063c9447bb2116100dc578063c9447bb2146109dc578063cd0dcdbd146109f1578063cd2364c214610a13578063d23577a714610a3357600080fd5b8063b4742cdf14610945578063b88d4fde1461095a578063c1027c981461097a578063c87b56dd146109bc57600080fd5b806395d89b4111610185578063a7acd26311610154578063a7acd263146108d1578063aa271e1a146108eb578063ad26d7621461090b578063add5a4fa1461092557600080fd5b806395d89b411461085c578063983b2d5614610871578063a11d23d914610891578063a22cb465146108b157600080fd5b806382c30987116101c157806382c30987146107f257806384f5184f146108085780638da5cb5b1461081b578063903afdc01461084657600080fd5b806378a923801461077a5780637cb9dd51146107a75780637ee1683d146107bd578063800149b9146107d257600080fd5b80632f745c59116102e25780634f558e79116102755780636c0360eb116102445780636c0360eb1461071d57806370a08231146107325780637116abf914610752578063715018a61461076557600080fd5b80634f558e791461069d578063523cfe03146106bd57806355f804b3146106dd5780636352211e146106fd57600080fd5b80633ccfd60b116102b15780633ccfd60b1461063157806341f08b521461064657806342842e0e146106685780634ea913861461068857600080fd5b80632f745c59146105b25780633092afd5146105d2578063325c4324146105f2578063387602981461061257600080fd5b80631e9a69501161035a57806326cca8a81161032957806326cca8a81461053c57806326f430e21461055c57806329412191146105895780632db115441461059f57600080fd5b80631e9a6950146104c957806322f74bcb146104e957806323b872dd146104fc5780632499d0691461051c57600080fd5b8063095ea7b311610396578063095ea7b3146104595780630bdb1a301461047b57806318160ddd146104955780631d056ca1146104b457600080fd5b806301ffc9a7146103bd57806306fdde03146103f2578063081812fc14610414575b600080fd5b3480156103c957600080fd5b506103dd6103d8366004614914565b610b6e565b60405190151581526020015b60405180910390f35b3480156103fe57600080fd5b50610407610c53565b6040516103e991906149a7565b34801561042057600080fd5b5061043461042f3660046149ba565b610ce5565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016103e9565b34801561046557600080fd5b506104796104743660046149f5565b610dc7565b005b34801561048757600080fd5b506014546103dd9060ff1681565b3480156104a157600080fd5b506025545b6040519081526020016103e9565b3480156104c057600080fd5b50610479610f88565b3480156104d557600080fd5b506104796104e43660046149f5565b610fd0565b6104796104f7366004614a6d565b61118f565b34801561050857600080fd5b50610479610517366004614ab9565b6112a6565b34801561052857600080fd5b50610479610537366004614afa565b611479565b34801561054857600080fd5b50610479610557366004614b17565b6114cf565b34801561056857600080fd5b506104a66105773660046149ba565b60236020526000908152604090205481565b34801561059557600080fd5b506104a660225481565b6104796105ad3660046149ba565b6114e5565b3480156105be57600080fd5b506104a66105cd3660046149f5565b61151c565b3480156105de57600080fd5b506104796105ed366004614afa565b611613565b3480156105fe57600080fd5b506103dd61060d3660046149ba565b611628565b34801561061e57600080fd5b50601d546103dd90610100900460ff1681565b34801561063d57600080fd5b50610479611635565b34801561065257600080fd5b5061065b61172a565b6040516103e99190614b43565b34801561067457600080fd5b50610479610683366004614ab9565b61173b565b34801561069457600080fd5b50610479611903565b3480156106a957600080fd5b506103dd6106b83660046149ba565b61194b565b3480156106c957600080fd5b506104796106d8366004614b9d565b611977565b3480156106e957600080fd5b506104796106f8366004614ccc565b611a52565b34801561070957600080fd5b506104346107183660046149ba565b611a71565b34801561072957600080fd5b50610407611b23565b34801561073e57600080fd5b506104a661074d366004614afa565b611b2d565b610479610760366004614a6d565b611c21565b34801561077157600080fd5b50610479611cd4565b34801561078657600080fd5b506104a6610795366004614afa565b601a6020526000908152604090205481565b3480156107b357600080fd5b506104a6600e5481565b3480156107c957600080fd5b50610479611ce6565b3480156107de57600080fd5b506104796107ed366004614afa565b611d2e565b3480156107fe57600080fd5b506104a6601b5481565b610479610816366004614b17565b611d43565b34801561082757600080fd5b5060075473ffffffffffffffffffffffffffffffffffffffff16610434565b34801561085257600080fd5b506104a660165481565b34801561086857600080fd5b50610407611f5f565b34801561087d57600080fd5b5061047961088c366004614afa565b611f6e565b34801561089d57600080fd5b506104796108ac3660046149ba565b611f83565b3480156108bd57600080fd5b506104796108cc366004614d23565b611f90565b3480156108dd57600080fd5b506019546103dd9060ff1681565b3480156108f757600080fd5b506103dd610906366004614afa565b61214c565b34801561091757600080fd5b50600f546103dd9060ff1681565b34801561093157600080fd5b506104796109403660046149f5565b612159565b34801561095157600080fd5b506104796121f3565b34801561096657600080fd5b50610479610975366004614d5c565b61223b565b34801561098657600080fd5b5061099a6109953660046149ba565b612411565b60408051941515855260208501939093529183015260608201526080016103e9565b3480156109c857600080fd5b506104076109d73660046149ba565b612474565b3480156109e857600080fd5b50610479612584565b3480156109fd57600080fd5b50610a066125d7565b6040516103e99190614ddc565b348015610a1f57600080fd5b50610479610a2e3660046149ba565b6125e3565b348015610a3f57600080fd5b506104a66125f0565b610479610a56366004614e14565b6125fc565b348015610a6757600080fd5b506104a660115481565b348015610a7d57600080fd5b506103dd610a8c366004614e90565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260036020908152604080832093909416825291909152205460ff1690565b348015610ad357600080fd5b506103dd610ae2366004614ebe565b612753565b348015610af357600080fd5b506104a6610b02366004614afa565b60156020526000908152604090205481565b348015610b2057600080fd5b50601d546103dd9060ff1681565b348015610b3a57600080fd5b50610479610b49366004614afa565b612843565b348015610b5a57600080fd5b50610479610b693660046149ba565b6128f7565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd000000000000000000000000000000000000000000000000000000001480610c0157507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b80610c4d57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b606060008054610c6290614f32565b80601f0160208091040260200160405190810160405280929190818152602001828054610c8e90614f32565b8015610cdb5780601f10610cb057610100808354040283529160200191610cdb565b820191906000526020600020905b815481529060010190602001808311610cbe57829003601f168201915b5050505050905090565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b5060ff1660009081526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b816daaeb6d7670e522a718067333cd4e3b15610f7f573373ffffffffffffffffffffffffffffffffffffffff821603610e1257610e0383612926565b610e0d838361296a565b505050565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e9190614f85565b8015610f4757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015610f23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f479190614f85565b610f7f576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b610e0383612926565b610f90612af1565b601454610f9f9060ff16612b72565b601480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b610fd93361214c565b611065576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f526f6c65733a2043616c6c657220646f6573206e6f742068617665207468652060448201527f6d696e74657220726f6c650000000000000000000000000000000000000000006064820152608401610d92565b600f5460ff166110d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f43726f73732d636861696e20436c6f73656400000000000000000000000000006044820152606401610d92565b602754811061113c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600560248201527f546f6b656e0000000000000000000000000000000000000000000000000000006044820152606401610d92565b61114882826001612b8a565b604051819073ffffffffffffffffffffffffffffffffffffffff8416907f222838db2794d11532d940e8dec38ae307ed0b63cd97c233322e221f998767a690600090a35050565b611197612ba9565b6019546018546111ac9160ff16908390612c1c565b60006111e482601a83335b73ffffffffffffffffffffffffffffffffffffffff16815260208101919091526040016000205490612e40565b9050601754811115611252576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b611260338585601b54612e4c565b80601a6000335b73ffffffffffffffffffffffffffffffffffffffff16815260208101919091526040016000205561129b3360255484612b8a565b50610e0d6001600655565b826daaeb6d7670e522a718067333cd4e3b1561145f573373ffffffffffffffffffffffffffffffffffffffff8216036112f2576112e284612926565b6112ed848484612f3f565b611473565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa15801561135a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061137e9190614f85565b801561142757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015611403573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114279190614f85565b61145f576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b61146884612926565b611473848484612f3f565b50505050565b611481612af1565b600061148e600883612fdf565b90507fed9840e0775590557ad736875d96c95cf1458b766335f74339951a32c82a9e33816040516114c3911515815260200190565b60405180910390a15050565b6114d7612af1565b601692909255601b55602255565b6114ed612ba9565b601d54601c546115029160ff16908390612c1c565b61150f3360255483612b8a565b6115196001600655565b50565b6000808061157a61152e856001614fd1565b73ffffffffffffffffffffffffffffffffffffffff87166000908152600560205260409020907f0000000000000000000000000000000000000000000000000000000000000000613001565b915091508161160b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610d92565b949350505050565b61161b612af1565b600061148e600a83612fdf565b6000610c4d600c836130ba565b61163d612af1565b611645612ba9565b604051600090339047908381818185875af1925050503d8060008114611687576040519150601f19603f3d011682016040523d82523d6000602084013e61168c565b606091505b505090508061171d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610d92565b506117286001600655565b565b6060611736600a6130d2565b905090565b826daaeb6d7670e522a718067333cd4e3b156118ef573373ffffffffffffffffffffffffffffffffffffffff8216036117825761177784612926565b6112ed8484846130df565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156117ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061180e9190614f85565b80156118b757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015611893573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118b79190614f85565b6118ef576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b6118f884612926565b6114738484846130df565b61190b612af1565b601d5461191a9060ff16612b72565b601d80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff161515610c4d565b61197f612ba9565b601d54610100900460ff166119f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f5374616b696e6720636c6f7365640000000000000000000000000000000000006044820152606401610d92565b8260005b81811015611a4657611a36868683818110611a1157611a11614fe9565b90506020020135858584818110611a2a57611a2a614fe9565b905060200201356130fa565b611a3f81615018565b90506119f4565b50506114736001600655565b611a5a612af1565b8051611a6d90602490602084019061484d565b5050565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff1680610c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610d92565b60606117366133d9565b600073ffffffffffffffffffffffffffffffffffffffff8216611bd2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610d92565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600560205260409020610c4d907f00000000000000000000000000000000000000000000000000000000000000006133e8565b611c29612ba9565b601454601354611c3e9160ff16908390612c1c565b6000611c4d82601583336111b7565b9050601254811115611cbb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b611cc9338585601654612e4c565b806015600033611267565b611cdc612af1565b6117286000613462565b611cee612af1565b600f54611cfd9060ff16612b72565b600f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b611d36612af1565b600061148e600883612904565b82611d4f335b826134d9565b611dda576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f455243373231436f6d6d6f6e3a204e6f7420617070726f766564206e6f72206f60448201527f776e6572000000000000000000000000000000000000000000000000000000006064820152608401610d92565b611de2612ba9565b600f5460ff16611e4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f43726f73732d636861696e20436c6f73656400000000000000000000000000006044820152606401610d92565b600e543414611edf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4a7573742073656e6420636f7272656374206e756d626572206f66206574686560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610d92565b611ee884613645565b60258054906000611ef883615050565b91905055508183611f063390565b73ffffffffffffffffffffffffffffffffffffffff167fa7c999ffbee909d86d70b612fb2a6d4f5136af62814e23bbfd3a3e74063f20d587604051611f4d91815260200190565b60405180910390a46114736001600655565b606060018054610c6290614f32565b611f76612af1565b600061148e600a83612904565b600061148e600c83613709565b816daaeb6d7670e522a718067333cd4e3b15612143573373ffffffffffffffffffffffffffffffffffffffff821603611fd657611fcc83612926565b610e0d8383613715565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa15801561203e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120629190614f85565b801561210b57506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156120e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061210b9190614f85565b612143576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b611fcc83612926565b6000610c4d600a83613720565b612161612af1565b6011546000906121719083612e40565b90506010548111156121df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b80601181905550610e0d8360255484612b8a565b6121fb612af1565b60195461220a9060ff16612b72565b601980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b836daaeb6d7670e522a718067333cd4e3b156123f5573373ffffffffffffffffffffffffffffffffffffffff8216036122885761227785612926565b6122838585858561374f565b61240a565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156122f0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123149190614f85565b80156123bd57506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015612399573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123bd9190614f85565b6123f5576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b6123fe85612926565b61240a8585858561374f565b5050505050565b6000818152601f6020526040812054819081908190801561245b576001945061243a42826137f1565b600087815260216020526040902054601e54919550612458916137fd565b92505b5050600093845260208052604090932054919390929190565b60008181526004602052604090205460609073ffffffffffffffffffffffffffffffffffffffff16612528576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201527f6e6578697374656e7420746f6b656e00000000000000000000000000000000006064820152608401610d92565b60006125326133d9565b90506000815111612552576040518060200160405280600081525061257d565b8061255c84613809565b60405160200161256d929190615085565b6040516020818303038152906040525b9392505050565b61258c612af1565b601d546125a090610100900460ff16612b72565b601d8054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b6060611736600c6130d2565b6125eb612af1565b600e55565b6000611736600a6138c7565b612604612ba9565b6019546018546126199160ff16908390612c1c565b600061262882601a83336111b7565b9050601754811115612696576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f416464726573732072656365697665206e756d626572204c696d6974656400006044820152606401610d92565b6126a38787878787612753565b612709576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f742062636e2066616d696c79206f776e65720000000000000000000000006044820152606401610d92565b73ffffffffffffffffffffffffffffffffffffffff83166000908152601a6020526040902081905560255461274090849084612b8a565b5061274b6001600655565b505050505050565b6000612763848787602254612e4c565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810184905260009073ffffffffffffffffffffffffffffffffffffffff861690636352211e90602401602060405180830381865afa1580156127d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127f591906150b4565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361283457600191505061283a565b60009150505b95945050505050565b61284b612af1565b73ffffffffffffffffffffffffffffffffffffffff81166128ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610d92565b61151981613462565b600061148e600c836138d1565b600061257d8373ffffffffffffffffffffffffffffffffffffffff84166138dd565b612931600882613720565b15611519576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b600061297582611a71565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603612a32576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610d92565b3373ffffffffffffffffffffffffffffffffffffffff82161480612a5b5750612a5b8133610a8c565b612ae7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610d92565b610e0d838361392c565b60075473ffffffffffffffffffffffffffffffffffffffff163314611728576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610d92565b60008115612b8257506000919050565b506001919050565b612b958383836139d0565b612ba160255482612e40565b602555505050565b600260065403612c15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610d92565b6002600655565b82612c83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f4d696e7420436c6f7365642100000000000000000000000000000000000000006044820152606401610d92565b333214612cec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f496e76616c6964206164647265737300000000000000000000000000000000006044820152606401610d92565b60008211612d56576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f496e76616c6964206d696e74207175616e7469747921000000000000000000006044820152606401610d92565b612d6081836137fd565b341015612dc9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f496e73756666696369656e742066756e647321000000000000000000000000006044820152606401610d92565b602654612dd860255484612e40565b1115610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f43757272656e7420636861696e206d696e74206c696d697400000000000000006044820152606401610d92565b600061257d8284614fd1565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606086901b166020820152600090603401604051602081830303815290604052805190602001209050612ed9848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250869250859150613b769050565b61240a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f496e76616c6964206164647265737321000000000000000000000000000000006044820152606401610d92565b612f4833611d49565b612fd4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610d92565b610e0d838383613b8c565b600061257d8373ffffffffffffffffffffffffffffffffffffffff8416613dee565b6000806000806000613014888888613ee1565b9250925092508261302e57600080945094505050506130b2565b600082815260208990526040812054905b6101008110156130a557600182161561308c578261305c81615018565b93505088830361308c576001613074856101006150d1565b61307e9083614fd1565b9650965050505050506130b2565b60019190911c908061309d81615018565b91505061303f565b5060008095509550505050505b935093915050565b6000818152600183016020526040812054151561257d565b6060600061257d83613f76565b610e0d8383836040518060200160405280600081525061223b565b8161310433611d49565b61318f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f455243373231436f6d6d6f6e3a204e6f7420617070726f766564206e6f72206f60448201527f776e6572000000000000000000000000000000000000000000000000000000006064820152608401610d92565b61319882611628565b6131fe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f496e76616c6964207374616b696e67206379636c6500000000000000000000006044820152606401610d92565b6000838152601f60205260408120549042908290036132d657601d54610100900460ff16613288576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f5374616b696e6720636c6f7365640000000000000000000000000000000000006044820152606401610d92565b6000858152602160209081526040808320879055601f909152808220839055518591879133917f5af417134f72a9d41143ace85b0a26dce6f550f894f2cbc1eeee8810603d91b691a461240a565b60006132e242846137f1565b905060006133056021600089815260200190815260200160002054601e546137fd565b9050808211613370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4e6f7420756e7374616b652074696d65000000000000000000000000000000006044820152606401610d92565b600087815260208052604090205461338890826137fd565b60008881526020808052604080832093909355601f905281812081905590518291899133917f54a9763035584fc4fcad1bc4e0e7a83f93e016f50ae32bd527530a77257393ee91a450505050505050565b606060248054610c6290614f32565b600080808060086133fa60018761510e565b613406911c6001614fd1565b90505b80821015613458576000828152602087905260409020545b80156134455761343260018261510e565b168361343d81615018565b945050613421565b8261344f81615018565b93505050613409565b5090949350505050565b6007805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff1661358a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610d92565b600061359583611a71565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061360457508373ffffffffffffffffffffffffffffffffffffffff166135ec84610ce5565b73ffffffffffffffffffffffffffffffffffffffff16145b8061160b575073ffffffffffffffffffffffffffffffffffffffff80821660009081526003602090815260408083209388168352929052205460ff1661160b565b600061365082611a71565b905061365e81600084613fd2565b61366960008361392c565b600082815260046020908152604080832080547fffffffff0000000000000000000000000000000000000000000000000000000016905573ffffffffffffffffffffffffffffffffffffffff841680845260058352818420600887901c85529092528083208054600160ff88161b1916905551849291907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b600061257d83836138dd565b611a6d338383614048565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561257d565b61375933836134d9565b6137e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610d92565b61147384848484614175565b600061257d828461510e565b600061257d82846150d1565b6060600061381683614218565b600101905060008167ffffffffffffffff81111561383657613836614c09565b6040519080825280601f01601f191660200182016040528015613860576020820181803683370190505b5090508181016020015b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff017f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a850494508461386a57509392505050565b6000610c4d825490565b600061257d8383613dee565b600081815260018301602052604081205461392457508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610c4d565b506000610c4d565b60ff8116600090815260026020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8416908117909155819061398a82611a71565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b73ffffffffffffffffffffffffffffffffffffffff8316613a4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610d92565b613a5782826142fa565b15613abe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610d92565b60005b81811015613af057613ade600085613ad98487614fd1565b613fd2565b80613ae881615018565b915050613ac1565b50613afc838383614367565b60005b8181101561147357613b118184614fd1565b60405173ffffffffffffffffffffffffffffffffffffffff8616906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4613b64600085610e0d8487614fd1565b80613b6e81615018565b915050613aff565b600082613b838584614517565b14949350505050565b8273ffffffffffffffffffffffffffffffffffffffff16613bac82611a71565b73ffffffffffffffffffffffffffffffffffffffff1614613c4f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152608401610d92565b73ffffffffffffffffffffffffffffffffffffffff8216613cf1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610d92565b613cfc838383613fd2565b613d0760008261392c565b73ffffffffffffffffffffffffffffffffffffffff8381166000818152600560208181526040808420600888901c8086529083528185208054600160ff8b161b8019909116909155968916808652938352818520908552825280842080549096179095558583526004905283822080547fffffffff00000000000000000000000000000000000000000000000000000000168217740100000000000000000000000000000000000000004267ffffffffffffffff16021790559251849392917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b60008181526001830160205260408120548015613ed7576000613e1260018361510e565b8554909150600090613e269060019061510e565b9050818114613e8b576000866000018281548110613e4657613e46614fe9565b9060005260206000200154905080876000018481548110613e6957613e69614fe9565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613e9c57613e9c615125565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610c4d565b6000915050610c4d565b6000808080806008613ef460018861510e565b613f00911c6001614fd1565b90505b80841015613f6a5760008481526020899052604090205491925082915b8015613f5757613f3160018261510e565b1682613f3c81615018565b935050878303613f525760019550505050613f6d565b613f20565b84613f6181615018565b95505050613f03565b50505b93509350939050565b606081600001805480602002602001604051908101604052809291908181526020018280548015613fc657602002820191906000526020600020905b815481526020019060010190808311613fb2575b50505050509050919050565b6000818152601f602052604090205415610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f4572726f723a207374616b696e670000000000000000000000000000000000006044820152606401610d92565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036140dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610d92565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526003602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b614180848484613b8c565b61418c84848484614564565b611473576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610d92565b6000807a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310614261577a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000830492506040015b6d04ee2d6d415b85acef8100000000831061428d576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106142ab57662386f26fc10000830492506010015b6305f5e10083106142c3576305f5e100830492506008015b61271083106142d757612710830492506004015b606483106142e9576064830492506002015b600a8310610c4d5760010192915050565b6000805b8281101561435d5760006004816143158488614fd1565b815260208101919091526040016000205473ffffffffffffffffffffffffffffffffffffffff161461434b576001915050610c4d565b8061435581615018565b9150506142fe565b5060009392505050565b7f00000000000000000000000000000000000000000000000000000000000000006143928284614fd1565b11156143fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f746f6b656e204944206f7574206f662072616e676500000000000000000000006044820152606401610d92565b60005b818110156144e65783600460006144148487614fd1565b815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550426004600083866144749190614fd1565b81526020810191909152604001600020805467ffffffffffffffff9290921674010000000000000000000000000000000000000000027fffffffff0000000000000000ffffffffffffffffffffffffffffffffffffffff909216919091179055806144de81615018565b9150506143fd565b5073ffffffffffffffffffffffffffffffffffffffff83166000908152600560205260409020610e0d908383614757565b600081815b845181101561455c576145488286838151811061453b5761453b614fe9565b60200260200101516147df565b91508061455481615018565b91505061451c565b509392505050565b600073ffffffffffffffffffffffffffffffffffffffff84163b1561474c576040517f150b7a0200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063150b7a02906145db903390899088908890600401615154565b6020604051808303816000875af1925050508015614634575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526146319181019061519d565b60015b614701573d808015614662576040519150601f19603f3d011682016040523d82523d6000602084013e614667565b606091505b5080516000036146f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610d92565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a020000000000000000000000000000000000000000000000000000000014905061160b565b506001949350505050565b8160006147648383614fd1565b90505b8082101561240a57600882901c6000614780848461510e565b905060ff841660006147948261010061510e565b9050828111156147a15750815b6000826147ad8361480e565b600087815260208d90526040902080549190921b90811790915590506147d38288614fd1565b96505050505050614767565b60008183106147fb57600082815260208490526040902061257d565b600083815260208390526040902061257d565b6000610100821061484057507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff919050565b610c4d600180841b61510e565b82805461485990614f32565b90600052602060002090601f01602090048101928261487b57600085556148c1565b82601f1061489457805160ff19168380011785556148c1565b828001600101855582156148c1579182015b828111156148c15782518255916020019190600101906148a6565b506148cd9291506148d1565b5090565b5b808211156148cd57600081556001016148d2565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461151957600080fd5b60006020828403121561492657600080fd5b813561257d816148e6565b60005b8381101561494c578181015183820152602001614934565b838111156114735750506000910152565b60008151808452614975816020860160208601614931565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061257d602083018461495d565b6000602082840312156149cc57600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461151957600080fd5b60008060408385031215614a0857600080fd5b8235614a13816149d3565b946020939093013593505050565b60008083601f840112614a3357600080fd5b50813567ffffffffffffffff811115614a4b57600080fd5b6020830191508360208260051b8501011115614a6657600080fd5b9250929050565b600080600060408486031215614a8257600080fd5b833567ffffffffffffffff811115614a9957600080fd5b614aa586828701614a21565b909790965060209590950135949350505050565b600080600060608486031215614ace57600080fd5b8335614ad9816149d3565b92506020840135614ae9816149d3565b929592945050506040919091013590565b600060208284031215614b0c57600080fd5b813561257d816149d3565b600080600060608486031215614b2c57600080fd5b505081359360208301359350604090920135919050565b6020808252825182820181905260009190848201906040850190845b81811015614b9157835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101614b5f565b50909695505050505050565b60008060008060408587031215614bb357600080fd5b843567ffffffffffffffff80821115614bcb57600080fd5b614bd788838901614a21565b90965094506020870135915080821115614bf057600080fd5b50614bfd87828801614a21565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600067ffffffffffffffff80841115614c5357614c53614c09565b604051601f85017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715614c9957614c99614c09565b81604052809350858152868686011115614cb257600080fd5b858560208301376000602087830101525050509392505050565b600060208284031215614cde57600080fd5b813567ffffffffffffffff811115614cf557600080fd5b8201601f81018413614d0657600080fd5b61160b84823560208401614c38565b801515811461151957600080fd5b60008060408385031215614d3657600080fd5b8235614d41816149d3565b91506020830135614d5181614d15565b809150509250929050565b60008060008060808587031215614d7257600080fd5b8435614d7d816149d3565b93506020850135614d8d816149d3565b925060408501359150606085013567ffffffffffffffff811115614db057600080fd5b8501601f81018713614dc157600080fd5b614dd087823560208401614c38565b91505092959194509250565b6020808252825182820181905260009190848201906040850190845b81811015614b9157835183529284019291840191600101614df8565b60008060008060008060a08789031215614e2d57600080fd5b863567ffffffffffffffff811115614e4457600080fd5b614e5089828a01614a21565b9097509550506020870135614e64816149d3565b9350604087013592506060870135614e7b816149d3565b80925050608087013590509295509295509295565b60008060408385031215614ea357600080fd5b8235614eae816149d3565b91506020830135614d51816149d3565b600080600080600060808688031215614ed657600080fd5b853567ffffffffffffffff811115614eed57600080fd5b614ef988828901614a21565b9096509450506020860135614f0d816149d3565b9250604086013591506060860135614f24816149d3565b809150509295509295909350565b600181811c90821680614f4657607f821691505b602082108103614f7f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b600060208284031215614f9757600080fd5b815161257d81614d15565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115614fe457614fe4614fa2565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361504957615049614fa2565b5060010190565b60008161505f5761505f614fa2565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b60008351615097818460208801614931565b8351908301906150ab818360208801614931565b01949350505050565b6000602082840312156150c657600080fd5b815161257d816149d3565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561510957615109614fa2565b500290565b60008282101561512057615120614fa2565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525083604083015260806060830152615193608083018461495d565b9695505050505050565b6000602082840312156151af57600080fd5b815161257d816148e656fea2646970667358221220f88e15b8d2e4f3c7e40b5d818489ba1ff1bcf5c83bc1e9cc79fb56446a28825464736f6c634300080d00330000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000064879616b6b69000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034859410000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x6080604052600436106103b85760003560e01c806378a92380116101f2578063b4742cdf1161010d578063e682b93d116100a0578063e9b1683a1161006f578063e9b1683a14610ae7578063f0dff7d314610b14578063f2fde38b14610b2e578063f9df0f4b14610b4e57600080fd5b8063e682b93d14610a48578063e8b5498d14610a5b578063e985e9c514610a71578063e99b7a8614610ac757600080fd5b8063c9447bb2116100dc578063c9447bb2146109dc578063cd0dcdbd146109f1578063cd2364c214610a13578063d23577a714610a3357600080fd5b8063b4742cdf14610945578063b88d4fde1461095a578063c1027c981461097a578063c87b56dd146109bc57600080fd5b806395d89b4111610185578063a7acd26311610154578063a7acd263146108d1578063aa271e1a146108eb578063ad26d7621461090b578063add5a4fa1461092557600080fd5b806395d89b411461085c578063983b2d5614610871578063a11d23d914610891578063a22cb465146108b157600080fd5b806382c30987116101c157806382c30987146107f257806384f5184f146108085780638da5cb5b1461081b578063903afdc01461084657600080fd5b806378a923801461077a5780637cb9dd51146107a75780637ee1683d146107bd578063800149b9146107d257600080fd5b80632f745c59116102e25780634f558e79116102755780636c0360eb116102445780636c0360eb1461071d57806370a08231146107325780637116abf914610752578063715018a61461076557600080fd5b80634f558e791461069d578063523cfe03146106bd57806355f804b3146106dd5780636352211e146106fd57600080fd5b80633ccfd60b116102b15780633ccfd60b1461063157806341f08b521461064657806342842e0e146106685780634ea913861461068857600080fd5b80632f745c59146105b25780633092afd5146105d2578063325c4324146105f2578063387602981461061257600080fd5b80631e9a69501161035a57806326cca8a81161032957806326cca8a81461053c57806326f430e21461055c57806329412191146105895780632db115441461059f57600080fd5b80631e9a6950146104c957806322f74bcb146104e957806323b872dd146104fc5780632499d0691461051c57600080fd5b8063095ea7b311610396578063095ea7b3146104595780630bdb1a301461047b57806318160ddd146104955780631d056ca1146104b457600080fd5b806301ffc9a7146103bd57806306fdde03146103f2578063081812fc14610414575b600080fd5b3480156103c957600080fd5b506103dd6103d8366004614914565b610b6e565b60405190151581526020015b60405180910390f35b3480156103fe57600080fd5b50610407610c53565b6040516103e991906149a7565b34801561042057600080fd5b5061043461042f3660046149ba565b610ce5565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016103e9565b34801561046557600080fd5b506104796104743660046149f5565b610dc7565b005b34801561048757600080fd5b506014546103dd9060ff1681565b3480156104a157600080fd5b506025545b6040519081526020016103e9565b3480156104c057600080fd5b50610479610f88565b3480156104d557600080fd5b506104796104e43660046149f5565b610fd0565b6104796104f7366004614a6d565b61118f565b34801561050857600080fd5b50610479610517366004614ab9565b6112a6565b34801561052857600080fd5b50610479610537366004614afa565b611479565b34801561054857600080fd5b50610479610557366004614b17565b6114cf565b34801561056857600080fd5b506104a66105773660046149ba565b60236020526000908152604090205481565b34801561059557600080fd5b506104a660225481565b6104796105ad3660046149ba565b6114e5565b3480156105be57600080fd5b506104a66105cd3660046149f5565b61151c565b3480156105de57600080fd5b506104796105ed366004614afa565b611613565b3480156105fe57600080fd5b506103dd61060d3660046149ba565b611628565b34801561061e57600080fd5b50601d546103dd90610100900460ff1681565b34801561063d57600080fd5b50610479611635565b34801561065257600080fd5b5061065b61172a565b6040516103e99190614b43565b34801561067457600080fd5b50610479610683366004614ab9565b61173b565b34801561069457600080fd5b50610479611903565b3480156106a957600080fd5b506103dd6106b83660046149ba565b61194b565b3480156106c957600080fd5b506104796106d8366004614b9d565b611977565b3480156106e957600080fd5b506104796106f8366004614ccc565b611a52565b34801561070957600080fd5b506104346107183660046149ba565b611a71565b34801561072957600080fd5b50610407611b23565b34801561073e57600080fd5b506104a661074d366004614afa565b611b2d565b610479610760366004614a6d565b611c21565b34801561077157600080fd5b50610479611cd4565b34801561078657600080fd5b506104a6610795366004614afa565b601a6020526000908152604090205481565b3480156107b357600080fd5b506104a6600e5481565b3480156107c957600080fd5b50610479611ce6565b3480156107de57600080fd5b506104796107ed366004614afa565b611d2e565b3480156107fe57600080fd5b506104a6601b5481565b610479610816366004614b17565b611d43565b34801561082757600080fd5b5060075473ffffffffffffffffffffffffffffffffffffffff16610434565b34801561085257600080fd5b506104a660165481565b34801561086857600080fd5b50610407611f5f565b34801561087d57600080fd5b5061047961088c366004614afa565b611f6e565b34801561089d57600080fd5b506104796108ac3660046149ba565b611f83565b3480156108bd57600080fd5b506104796108cc366004614d23565b611f90565b3480156108dd57600080fd5b506019546103dd9060ff1681565b3480156108f757600080fd5b506103dd610906366004614afa565b61214c565b34801561091757600080fd5b50600f546103dd9060ff1681565b34801561093157600080fd5b506104796109403660046149f5565b612159565b34801561095157600080fd5b506104796121f3565b34801561096657600080fd5b50610479610975366004614d5c565b61223b565b34801561098657600080fd5b5061099a6109953660046149ba565b612411565b60408051941515855260208501939093529183015260608201526080016103e9565b3480156109c857600080fd5b506104076109d73660046149ba565b612474565b3480156109e857600080fd5b50610479612584565b3480156109fd57600080fd5b50610a066125d7565b6040516103e99190614ddc565b348015610a1f57600080fd5b50610479610a2e3660046149ba565b6125e3565b348015610a3f57600080fd5b506104a66125f0565b610479610a56366004614e14565b6125fc565b348015610a6757600080fd5b506104a660115481565b348015610a7d57600080fd5b506103dd610a8c366004614e90565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260036020908152604080832093909416825291909152205460ff1690565b348015610ad357600080fd5b506103dd610ae2366004614ebe565b612753565b348015610af357600080fd5b506104a6610b02366004614afa565b60156020526000908152604090205481565b348015610b2057600080fd5b50601d546103dd9060ff1681565b348015610b3a57600080fd5b50610479610b49366004614afa565b612843565b348015610b5a57600080fd5b50610479610b693660046149ba565b6128f7565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd000000000000000000000000000000000000000000000000000000001480610c0157507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b80610c4d57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b606060008054610c6290614f32565b80601f0160208091040260200160405190810160405280929190818152602001828054610c8e90614f32565b8015610cdb5780601f10610cb057610100808354040283529160200191610cdb565b820191906000526020600020905b815481529060010190602001808311610cbe57829003601f168201915b5050505050905090565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b5060ff1660009081526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b816daaeb6d7670e522a718067333cd4e3b15610f7f573373ffffffffffffffffffffffffffffffffffffffff821603610e1257610e0383612926565b610e0d838361296a565b505050565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015610e7a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e9e9190614f85565b8015610f4757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015610f23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f479190614f85565b610f7f576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b610e0383612926565b610f90612af1565b601454610f9f9060ff16612b72565b601480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b610fd93361214c565b611065576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f526f6c65733a2043616c6c657220646f6573206e6f742068617665207468652060448201527f6d696e74657220726f6c650000000000000000000000000000000000000000006064820152608401610d92565b600f5460ff166110d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f43726f73732d636861696e20436c6f73656400000000000000000000000000006044820152606401610d92565b602754811061113c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600560248201527f546f6b656e0000000000000000000000000000000000000000000000000000006044820152606401610d92565b61114882826001612b8a565b604051819073ffffffffffffffffffffffffffffffffffffffff8416907f222838db2794d11532d940e8dec38ae307ed0b63cd97c233322e221f998767a690600090a35050565b611197612ba9565b6019546018546111ac9160ff16908390612c1c565b60006111e482601a83335b73ffffffffffffffffffffffffffffffffffffffff16815260208101919091526040016000205490612e40565b9050601754811115611252576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b611260338585601b54612e4c565b80601a6000335b73ffffffffffffffffffffffffffffffffffffffff16815260208101919091526040016000205561129b3360255484612b8a565b50610e0d6001600655565b826daaeb6d7670e522a718067333cd4e3b1561145f573373ffffffffffffffffffffffffffffffffffffffff8216036112f2576112e284612926565b6112ed848484612f3f565b611473565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa15801561135a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061137e9190614f85565b801561142757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015611403573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114279190614f85565b61145f576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b61146884612926565b611473848484612f3f565b50505050565b611481612af1565b600061148e600883612fdf565b90507fed9840e0775590557ad736875d96c95cf1458b766335f74339951a32c82a9e33816040516114c3911515815260200190565b60405180910390a15050565b6114d7612af1565b601692909255601b55602255565b6114ed612ba9565b601d54601c546115029160ff16908390612c1c565b61150f3360255483612b8a565b6115196001600655565b50565b6000808061157a61152e856001614fd1565b73ffffffffffffffffffffffffffffffffffffffff87166000908152600560205260409020907f00000000000000000000000000000000000000000000000000000000000022b8613001565b915091508161160b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610d92565b949350505050565b61161b612af1565b600061148e600a83612fdf565b6000610c4d600c836130ba565b61163d612af1565b611645612ba9565b604051600090339047908381818185875af1925050503d8060008114611687576040519150601f19603f3d011682016040523d82523d6000602084013e61168c565b606091505b505090508061171d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401610d92565b506117286001600655565b565b6060611736600a6130d2565b905090565b826daaeb6d7670e522a718067333cd4e3b156118ef573373ffffffffffffffffffffffffffffffffffffffff8216036117825761177784612926565b6112ed8484846130df565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156117ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061180e9190614f85565b80156118b757506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015611893573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118b79190614f85565b6118ef576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b6118f884612926565b6114738484846130df565b61190b612af1565b601d5461191a9060ff16612b72565b601d80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff161515610c4d565b61197f612ba9565b601d54610100900460ff166119f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f5374616b696e6720636c6f7365640000000000000000000000000000000000006044820152606401610d92565b8260005b81811015611a4657611a36868683818110611a1157611a11614fe9565b90506020020135858584818110611a2a57611a2a614fe9565b905060200201356130fa565b611a3f81615018565b90506119f4565b50506114736001600655565b611a5a612af1565b8051611a6d90602490602084019061484d565b5050565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff1680610c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610d92565b60606117366133d9565b600073ffffffffffffffffffffffffffffffffffffffff8216611bd2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610d92565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600560205260409020610c4d907f00000000000000000000000000000000000000000000000000000000000022b86133e8565b611c29612ba9565b601454601354611c3e9160ff16908390612c1c565b6000611c4d82601583336111b7565b9050601254811115611cbb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b611cc9338585601654612e4c565b806015600033611267565b611cdc612af1565b6117286000613462565b611cee612af1565b600f54611cfd9060ff16612b72565b600f80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b611d36612af1565b600061148e600883612904565b82611d4f335b826134d9565b611dda576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f455243373231436f6d6d6f6e3a204e6f7420617070726f766564206e6f72206f60448201527f776e6572000000000000000000000000000000000000000000000000000000006064820152608401610d92565b611de2612ba9565b600f5460ff16611e4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f43726f73732d636861696e20436c6f73656400000000000000000000000000006044820152606401610d92565b600e543414611edf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4a7573742073656e6420636f7272656374206e756d626572206f66206574686560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610d92565b611ee884613645565b60258054906000611ef883615050565b91905055508183611f063390565b73ffffffffffffffffffffffffffffffffffffffff167fa7c999ffbee909d86d70b612fb2a6d4f5136af62814e23bbfd3a3e74063f20d587604051611f4d91815260200190565b60405180910390a46114736001600655565b606060018054610c6290614f32565b611f76612af1565b600061148e600a83612904565b600061148e600c83613709565b816daaeb6d7670e522a718067333cd4e3b15612143573373ffffffffffffffffffffffffffffffffffffffff821603611fd657611fcc83612926565b610e0d8383613715565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa15801561203e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120629190614f85565b801561210b57506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156120e7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061210b9190614f85565b612143576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b611fcc83612926565b6000610c4d600a83613720565b612161612af1565b6011546000906121719083612e40565b90506010548111156121df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f4d696e74204c696d6974656421000000000000000000000000000000000000006044820152606401610d92565b80601181905550610e0d8360255484612b8a565b6121fb612af1565b60195461220a9060ff16612b72565b601980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b836daaeb6d7670e522a718067333cd4e3b156123f5573373ffffffffffffffffffffffffffffffffffffffff8216036122885761227785612926565b6122838585858561374f565b61240a565b6040517fc61711340000000000000000000000000000000000000000000000000000000081523060048201523360248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156122f0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123149190614f85565b80156123bd57506040517fc617113400000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa158015612399573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123bd9190614f85565b6123f5576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b6123fe85612926565b61240a8585858561374f565b5050505050565b6000818152601f6020526040812054819081908190801561245b576001945061243a42826137f1565b600087815260216020526040902054601e54919550612458916137fd565b92505b5050600093845260208052604090932054919390929190565b60008181526004602052604090205460609073ffffffffffffffffffffffffffffffffffffffff16612528576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201527f6e6578697374656e7420746f6b656e00000000000000000000000000000000006064820152608401610d92565b60006125326133d9565b90506000815111612552576040518060200160405280600081525061257d565b8061255c84613809565b60405160200161256d929190615085565b6040516020818303038152906040525b9392505050565b61258c612af1565b601d546125a090610100900460ff16612b72565b601d8054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b6060611736600c6130d2565b6125eb612af1565b600e55565b6000611736600a6138c7565b612604612ba9565b6019546018546126199160ff16908390612c1c565b600061262882601a83336111b7565b9050601754811115612696576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f416464726573732072656365697665206e756d626572204c696d6974656400006044820152606401610d92565b6126a38787878787612753565b612709576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4e6f742062636e2066616d696c79206f776e65720000000000000000000000006044820152606401610d92565b73ffffffffffffffffffffffffffffffffffffffff83166000908152601a6020526040902081905560255461274090849084612b8a565b5061274b6001600655565b505050505050565b6000612763848787602254612e4c565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810184905260009073ffffffffffffffffffffffffffffffffffffffff861690636352211e90602401602060405180830381865afa1580156127d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127f591906150b4565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361283457600191505061283a565b60009150505b95945050505050565b61284b612af1565b73ffffffffffffffffffffffffffffffffffffffff81166128ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610d92565b61151981613462565b600061148e600c836138d1565b600061257d8373ffffffffffffffffffffffffffffffffffffffff84166138dd565b612931600882613720565b15611519576040517fede71dcc000000000000000000000000000000000000000000000000000000008152336004820152602401610d92565b600061297582611a71565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603612a32576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610d92565b3373ffffffffffffffffffffffffffffffffffffffff82161480612a5b5750612a5b8133610a8c565b612ae7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610d92565b610e0d838361392c565b60075473ffffffffffffffffffffffffffffffffffffffff163314611728576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610d92565b60008115612b8257506000919050565b506001919050565b612b958383836139d0565b612ba160255482612e40565b602555505050565b600260065403612c15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610d92565b6002600655565b82612c83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f4d696e7420436c6f7365642100000000000000000000000000000000000000006044820152606401610d92565b333214612cec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f496e76616c6964206164647265737300000000000000000000000000000000006044820152606401610d92565b60008211612d56576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f496e76616c6964206d696e74207175616e7469747921000000000000000000006044820152606401610d92565b612d6081836137fd565b341015612dc9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f496e73756666696369656e742066756e647321000000000000000000000000006044820152606401610d92565b602654612dd860255484612e40565b1115610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f43757272656e7420636861696e206d696e74206c696d697400000000000000006044820152606401610d92565b600061257d8284614fd1565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606086901b166020820152600090603401604051602081830303815290604052805190602001209050612ed9848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250869250859150613b769050565b61240a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f496e76616c6964206164647265737321000000000000000000000000000000006044820152606401610d92565b612f4833611d49565b612fd4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610d92565b610e0d838383613b8c565b600061257d8373ffffffffffffffffffffffffffffffffffffffff8416613dee565b6000806000806000613014888888613ee1565b9250925092508261302e57600080945094505050506130b2565b600082815260208990526040812054905b6101008110156130a557600182161561308c578261305c81615018565b93505088830361308c576001613074856101006150d1565b61307e9083614fd1565b9650965050505050506130b2565b60019190911c908061309d81615018565b91505061303f565b5060008095509550505050505b935093915050565b6000818152600183016020526040812054151561257d565b6060600061257d83613f76565b610e0d8383836040518060200160405280600081525061223b565b8161310433611d49565b61318f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f455243373231436f6d6d6f6e3a204e6f7420617070726f766564206e6f72206f60448201527f776e6572000000000000000000000000000000000000000000000000000000006064820152608401610d92565b61319882611628565b6131fe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f496e76616c6964207374616b696e67206379636c6500000000000000000000006044820152606401610d92565b6000838152601f60205260408120549042908290036132d657601d54610100900460ff16613288576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f5374616b696e6720636c6f7365640000000000000000000000000000000000006044820152606401610d92565b6000858152602160209081526040808320879055601f909152808220839055518591879133917f5af417134f72a9d41143ace85b0a26dce6f550f894f2cbc1eeee8810603d91b691a461240a565b60006132e242846137f1565b905060006133056021600089815260200190815260200160002054601e546137fd565b9050808211613370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4e6f7420756e7374616b652074696d65000000000000000000000000000000006044820152606401610d92565b600087815260208052604090205461338890826137fd565b60008881526020808052604080832093909355601f905281812081905590518291899133917f54a9763035584fc4fcad1bc4e0e7a83f93e016f50ae32bd527530a77257393ee91a450505050505050565b606060248054610c6290614f32565b600080808060086133fa60018761510e565b613406911c6001614fd1565b90505b80821015613458576000828152602087905260409020545b80156134455761343260018261510e565b168361343d81615018565b945050613421565b8261344f81615018565b93505050613409565b5090949350505050565b6007805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60008181526004602052604081205473ffffffffffffffffffffffffffffffffffffffff1661358a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610d92565b600061359583611a71565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061360457508373ffffffffffffffffffffffffffffffffffffffff166135ec84610ce5565b73ffffffffffffffffffffffffffffffffffffffff16145b8061160b575073ffffffffffffffffffffffffffffffffffffffff80821660009081526003602090815260408083209388168352929052205460ff1661160b565b600061365082611a71565b905061365e81600084613fd2565b61366960008361392c565b600082815260046020908152604080832080547fffffffff0000000000000000000000000000000000000000000000000000000016905573ffffffffffffffffffffffffffffffffffffffff841680845260058352818420600887901c85529092528083208054600160ff88161b1916905551849291907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b600061257d83836138dd565b611a6d338383614048565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561257d565b61375933836134d9565b6137e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610d92565b61147384848484614175565b600061257d828461510e565b600061257d82846150d1565b6060600061381683614218565b600101905060008167ffffffffffffffff81111561383657613836614c09565b6040519080825280601f01601f191660200182016040528015613860576020820181803683370190505b5090508181016020015b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff017f3031323334353637383961626364656600000000000000000000000000000000600a86061a8153600a850494508461386a57509392505050565b6000610c4d825490565b600061257d8383613dee565b600081815260018301602052604081205461392457508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610c4d565b506000610c4d565b60ff8116600090815260026020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8416908117909155819061398a82611a71565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b73ffffffffffffffffffffffffffffffffffffffff8316613a4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610d92565b613a5782826142fa565b15613abe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610d92565b60005b81811015613af057613ade600085613ad98487614fd1565b613fd2565b80613ae881615018565b915050613ac1565b50613afc838383614367565b60005b8181101561147357613b118184614fd1565b60405173ffffffffffffffffffffffffffffffffffffffff8616906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4613b64600085610e0d8487614fd1565b80613b6e81615018565b915050613aff565b600082613b838584614517565b14949350505050565b8273ffffffffffffffffffffffffffffffffffffffff16613bac82611a71565b73ffffffffffffffffffffffffffffffffffffffff1614613c4f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152608401610d92565b73ffffffffffffffffffffffffffffffffffffffff8216613cf1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610d92565b613cfc838383613fd2565b613d0760008261392c565b73ffffffffffffffffffffffffffffffffffffffff8381166000818152600560208181526040808420600888901c8086529083528185208054600160ff8b161b8019909116909155968916808652938352818520908552825280842080549096179095558583526004905283822080547fffffffff00000000000000000000000000000000000000000000000000000000168217740100000000000000000000000000000000000000004267ffffffffffffffff16021790559251849392917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b60008181526001830160205260408120548015613ed7576000613e1260018361510e565b8554909150600090613e269060019061510e565b9050818114613e8b576000866000018281548110613e4657613e46614fe9565b9060005260206000200154905080876000018481548110613e6957613e69614fe9565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613e9c57613e9c615125565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610c4d565b6000915050610c4d565b6000808080806008613ef460018861510e565b613f00911c6001614fd1565b90505b80841015613f6a5760008481526020899052604090205491925082915b8015613f5757613f3160018261510e565b1682613f3c81615018565b935050878303613f525760019550505050613f6d565b613f20565b84613f6181615018565b95505050613f03565b50505b93509350939050565b606081600001805480602002602001604051908101604052809291908181526020018280548015613fc657602002820191906000526020600020905b815481526020019060010190808311613fb2575b50505050509050919050565b6000818152601f602052604090205415610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f4572726f723a207374616b696e670000000000000000000000000000000000006044820152606401610d92565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036140dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610d92565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526003602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b614180848484613b8c565b61418c84848484614564565b611473576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610d92565b6000807a184f03e93ff9f4daa797ed6e38ed64bf6a1f0100000000000000008310614261577a184f03e93ff9f4daa797ed6e38ed64bf6a1f010000000000000000830492506040015b6d04ee2d6d415b85acef8100000000831061428d576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc1000083106142ab57662386f26fc10000830492506010015b6305f5e10083106142c3576305f5e100830492506008015b61271083106142d757612710830492506004015b606483106142e9576064830492506002015b600a8310610c4d5760010192915050565b6000805b8281101561435d5760006004816143158488614fd1565b815260208101919091526040016000205473ffffffffffffffffffffffffffffffffffffffff161461434b576001915050610c4d565b8061435581615018565b9150506142fe565b5060009392505050565b7f00000000000000000000000000000000000000000000000000000000000022b86143928284614fd1565b11156143fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f746f6b656e204944206f7574206f662072616e676500000000000000000000006044820152606401610d92565b60005b818110156144e65783600460006144148487614fd1565b815260200190815260200160002060000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550426004600083866144749190614fd1565b81526020810191909152604001600020805467ffffffffffffffff9290921674010000000000000000000000000000000000000000027fffffffff0000000000000000ffffffffffffffffffffffffffffffffffffffff909216919091179055806144de81615018565b9150506143fd565b5073ffffffffffffffffffffffffffffffffffffffff83166000908152600560205260409020610e0d908383614757565b600081815b845181101561455c576145488286838151811061453b5761453b614fe9565b60200260200101516147df565b91508061455481615018565b91505061451c565b509392505050565b600073ffffffffffffffffffffffffffffffffffffffff84163b1561474c576040517f150b7a0200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063150b7a02906145db903390899088908890600401615154565b6020604051808303816000875af1925050508015614634575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682019092526146319181019061519d565b60015b614701573d808015614662576040519150601f19603f3d011682016040523d82523d6000602084013e614667565b606091505b5080516000036146f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610d92565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a020000000000000000000000000000000000000000000000000000000014905061160b565b506001949350505050565b8160006147648383614fd1565b90505b8082101561240a57600882901c6000614780848461510e565b905060ff841660006147948261010061510e565b9050828111156147a15750815b6000826147ad8361480e565b600087815260208d90526040902080549190921b90811790915590506147d38288614fd1565b96505050505050614767565b60008183106147fb57600082815260208490526040902061257d565b600083815260208390526040902061257d565b6000610100821061484057507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff919050565b610c4d600180841b61510e565b82805461485990614f32565b90600052602060002090601f01602090048101928261487b57600085556148c1565b82601f1061489457805160ff19168380011785556148c1565b828001600101855582156148c1579182015b828111156148c15782518255916020019190600101906148a6565b506148cd9291506148d1565b5090565b5b808211156148cd57600081556001016148d2565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461151957600080fd5b60006020828403121561492657600080fd5b813561257d816148e6565b60005b8381101561494c578181015183820152602001614934565b838111156114735750506000910152565b60008151808452614975816020860160208601614931565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061257d602083018461495d565b6000602082840312156149cc57600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461151957600080fd5b60008060408385031215614a0857600080fd5b8235614a13816149d3565b946020939093013593505050565b60008083601f840112614a3357600080fd5b50813567ffffffffffffffff811115614a4b57600080fd5b6020830191508360208260051b8501011115614a6657600080fd5b9250929050565b600080600060408486031215614a8257600080fd5b833567ffffffffffffffff811115614a9957600080fd5b614aa586828701614a21565b909790965060209590950135949350505050565b600080600060608486031215614ace57600080fd5b8335614ad9816149d3565b92506020840135614ae9816149d3565b929592945050506040919091013590565b600060208284031215614b0c57600080fd5b813561257d816149d3565b600080600060608486031215614b2c57600080fd5b505081359360208301359350604090920135919050565b6020808252825182820181905260009190848201906040850190845b81811015614b9157835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101614b5f565b50909695505050505050565b60008060008060408587031215614bb357600080fd5b843567ffffffffffffffff80821115614bcb57600080fd5b614bd788838901614a21565b90965094506020870135915080821115614bf057600080fd5b50614bfd87828801614a21565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600067ffffffffffffffff80841115614c5357614c53614c09565b604051601f85017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715614c9957614c99614c09565b81604052809350858152868686011115614cb257600080fd5b858560208301376000602087830101525050509392505050565b600060208284031215614cde57600080fd5b813567ffffffffffffffff811115614cf557600080fd5b8201601f81018413614d0657600080fd5b61160b84823560208401614c38565b801515811461151957600080fd5b60008060408385031215614d3657600080fd5b8235614d41816149d3565b91506020830135614d5181614d15565b809150509250929050565b60008060008060808587031215614d7257600080fd5b8435614d7d816149d3565b93506020850135614d8d816149d3565b925060408501359150606085013567ffffffffffffffff811115614db057600080fd5b8501601f81018713614dc157600080fd5b614dd087823560208401614c38565b91505092959194509250565b6020808252825182820181905260009190848201906040850190845b81811015614b9157835183529284019291840191600101614df8565b60008060008060008060a08789031215614e2d57600080fd5b863567ffffffffffffffff811115614e4457600080fd5b614e5089828a01614a21565b9097509550506020870135614e64816149d3565b9350604087013592506060870135614e7b816149d3565b80925050608087013590509295509295509295565b60008060408385031215614ea357600080fd5b8235614eae816149d3565b91506020830135614d51816149d3565b600080600080600060808688031215614ed657600080fd5b853567ffffffffffffffff811115614eed57600080fd5b614ef988828901614a21565b9096509450506020860135614f0d816149d3565b9250604086013591506060860135614f24816149d3565b809150509295509295909350565b600181811c90821680614f4657607f821691505b602082108103614f7f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b600060208284031215614f9757600080fd5b815161257d81614d15565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115614fe457614fe4614fa2565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361504957615049614fa2565b5060010190565b60008161505f5761505f614fa2565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b60008351615097818460208801614931565b8351908301906150ab818360208801614931565b01949350505050565b6000602082840312156150c657600080fd5b815161257d816149d3565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561510957615109614fa2565b500290565b60008282101561512057615120614fa2565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525083604083015260806060830152615193608083018461495d565b9695505050505050565b6000602082840312156151af57600080fd5b815161257d816148e656fea2646970667358221220f88e15b8d2e4f3c7e40b5d818489ba1ff1bcf5c83bc1e9cc79fb56446a28825464736f6c634300080d0033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

0000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000064879616b6b69000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000034859410000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : name (string): Hyakki
Arg [1] : symbol (string): HYA

-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [3] : 4879616b6b690000000000000000000000000000000000000000000000000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [5] : 4859410000000000000000000000000000000000000000000000000000000000


Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.