ETH Price: $3,461.89 (+1.88%)
Gas: 11 Gwei

Token

SHAKAZ (Shell Shakaz)
 

Overview

Max Total Supply

223 Shell Shakaz

Holders

90

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
2 Shell Shakaz
0xaf9390ae0c19975a8062638b6bd0c24f35694a7c
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:
MultiToken721

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 5 runs

Other Settings:
default evmVersion
File 1 of 31 : MultiToken721.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/proxy/utils/Initializable.sol";
import "@openzeppelin/contracts/utils/Strings.sol";

// the erc1155 base contract - the openzeppelin erc1155
import "../token/ERC721A/ERC721A.sol";
import "../royalties/ERC2981.sol";
import "../utils/AddressSet.sol";
import "../utils/UInt256Set.sol";

import "./ProxyRegistry.sol";
import "../access/Controllable.sol";

import "../interfaces/IMultiToken.sol";
import "../interfaces/IERC1155Mint.sol";
import "../interfaces/IERC1155Burn.sol";
import "../interfaces/IERC1155Multinetwork.sol";
import "../interfaces/IERC1155Bridge.sol";

import "../service/Service.sol";
import "../factories/FactoryElement.sol";

/**
 * @title MultiToken
 * @notice the multitoken contract. All tokens are printed on this contract. The token has all the capabilities
 * of an erc1155 contract, plus network transfer, royallty tracking and assignment and other features.
 */
contract MultiToken721 is
ERC721A,
ProxyRegistryManager,
IERC1155Multinetwork,
IMultiToken,
ERC2981,
Service,
Controllable,
Initializable,
FactoryElement
{

    // to work with token holder and held token lists
    using AddressSet for AddressSet.Set;
    using UInt256Set for UInt256Set.Set;
    using Strings for uint256;

    address internal masterMinter;
    string internal _uri;

    function initialize(address registry) public initializer {
        _addController(msg.sender);
        _serviceRegistry = registry;
    }

    function initToken(string memory symbol, string memory name) public {
        _initToken(symbol, name);
    }

    function setMasterController(address _masterMinter) public {
        require(masterMinter == address(0), "master minter must not be set");
        masterMinter = _masterMinter;
        _addController(_masterMinter);
    }

    function addDirectMinter(address directMinter) public {
        require(msg.sender == masterMinter, "only master minter can add direct minters");
        _addController(directMinter);
    }

    /// @notice only allow owner of the contract
    modifier onlyOwner() {
        require(_isController(msg.sender), "You shall not pass");
        _;
    }
    /// @notice only allow owner of the contract
    modifier onlyMinter() {
        require(_isController(msg.sender) || masterMinter == msg.sender, "You shall not pass");
        _;
    }

    /// @notice Mint a specified amount the specified token hash to the specified receiver
    /// @param recipient the address of the receiver
    /// @param amount the amount to mint
    function mint(
        address recipient,
        uint256,
        uint256 amount
    ) external override onlyMinter {

        _mint(recipient, amount, "", true);

    }

    /// @notice mint tokens of specified amount to the specified address
    /// @param recipient the mint target
    /// @param amount the amount to mint
    function mintWithCommonUri(
        address recipient,
        uint256,
        uint256 amount,
        uint256
    ) external onlyMinter {

        _mint(recipient, amount, "", true);

    }

    string internal baseUri;
    function setBaseURI(string memory value) external onlyMinter {

        baseUri = value;

    }

    function baseURI() external view returns (string memory) {

        return _baseURI();

    }

    function _baseURI() internal view virtual override returns (string memory) {

        return baseUri;

    }

    /// @notice burn a specified amount of the specified token hash from the specified target
    /// @param tokenHash the token id to burn
    function burn(
        address,
        uint256 tokenHash,
        uint256
    ) external override onlyMinter {
        _burn(tokenHash);
    }

    /// @notice override base functionality to check proxy registries for approvers
    /// @param _owner the owner address
    /// @param _operator the operator address
    /// @return isOperator true if the owner is an approver for the operator
    function isApprovedForAll(address _owner, address _operator)
    public
    view
    override
    returns (bool isOperator) {
        // check proxy whitelist
        bool _approved = _isApprovedForAll(_owner, _operator);
        return _approved || ERC721A.isApprovedForAll(_owner, _operator);
    }

    /// @notice See {IERC165-supportsInterface}. ERC165 implementor. identifies this contract as an ERC1155
    /// @param interfaceId the interface id to check
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC2981, ERC721A) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /// @notice perform a network token transfer. Transfer the specified quantity of the specified token hash to the destination address on the destination network.
    function networkTransferFrom(
        address from,
        address to,
        uint256 network,
        uint256 id,
        uint256 amount,
        bytes calldata data
    ) external virtual override {

        address _bridge = IJanusRegistry(_serviceRegistry).get("MultiToken", "NetworkBridge");
        require(_bridge != address(0), "No network bridge found");

        // call the network transfer on the bridge
        IERC1155Multinetwork(_bridge).networkTransferFrom(from, to, network, id, amount, data);

    }

    mapping(uint256 => string) internal symbolsOf;
    mapping(uint256 => string) internal namesOf;

    function symbolOf(uint256 _tokenId) external view override returns (string memory out) {
        return symbolsOf[_tokenId];
    }

    function nameOf(uint256 _tokenId) external view override returns (string memory out) {
        return namesOf[_tokenId];
    }

    function setSymbolOf(uint256 _tokenId, string memory _symbolOf) external onlyMinter {
        symbolsOf[_tokenId] = _symbolOf;
    }

    function setNameOf(uint256 _tokenId, string memory _nameOf) external onlyMinter {
        namesOf[_tokenId] = _nameOf;
    }

    function setRoyalty(uint256 tokenId, address receiver, uint256 amount) external onlyOwner {
        royaltyReceiversByHash[tokenId] = receiver;
        royaltyFeesByHash[tokenId] = amount;
    }

}

File 2 of 31 : Initializable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (proxy/utils/Initializable.sol)

pragma solidity ^0.8.0;

import "../../utils/Address.sol";

/**
 * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
 * behind a proxy. Since a proxied contract can't have a constructor, it's common to move constructor logic to an
 * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
 * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
 *
 * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
 * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
 *
 * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
 * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
 *
 * [CAUTION]
 * ====
 * Avoid leaving a contract uninitialized.
 *
 * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
 * contract, which may impact the proxy. To initialize the implementation contract, you can either invoke the
 * initializer manually, or you can include a constructor to automatically mark it as initialized when it is deployed:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * /// @custom:oz-upgrades-unsafe-allow constructor
 * constructor() initializer {}
 * ```
 * ====
 */
abstract contract Initializable {
    /**
     * @dev Indicates that the contract has been initialized.
     */
    bool private _initialized;

    /**
     * @dev Indicates that the contract is in the process of being initialized.
     */
    bool private _initializing;

    /**
     * @dev Modifier to protect an initializer function from being invoked twice.
     */
    modifier initializer() {
        // If the contract is initializing we ignore whether _initialized is set in order to support multiple
        // inheritance patterns, but we only do this in the context of a constructor, because in other contexts the
        // contract may have been reentered.
        require(_initializing ? _isConstructor() : !_initialized, "Initializable: contract is already initialized");

        bool isTopLevelCall = !_initializing;
        if (isTopLevelCall) {
            _initializing = true;
            _initialized = true;
        }

        _;

        if (isTopLevelCall) {
            _initializing = false;
        }
    }

    /**
     * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
     * {initializer} modifier, directly or indirectly.
     */
    modifier onlyInitializing() {
        require(_initializing, "Initializable: contract is not initializing");
        _;
    }

    function _isConstructor() private view returns (bool) {
        return !Address.isContract(address(this));
    }
}

File 3 of 31 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}

File 4 of 31 : ERC721A.sol
// SPDX-License-Identifier: MIT
// Creator: Chiru Labs
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol";
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";

error ApprovalCallerNotOwnerNorApproved();
error ApprovalQueryForNonexistentToken();
error ApproveToCaller();
error ApprovalToCurrentOwner();
error BalanceQueryForZeroAddress();
error MintedQueryForZeroAddress();
error BurnedQueryForZeroAddress();
error AuxQueryForZeroAddress();
error MintToZeroAddress();
error MintZeroQuantity();
error OwnerIndexOutOfBounds();
error OwnerQueryForNonexistentToken();
error TokenIndexOutOfBounds();
error TransferCallerNotOwnerNorApproved();
error TransferFromIncorrectOwner();
error TransferToNonERC721ReceiverImplementer();
error TransferToZeroAddress();
error URIQueryForNonexistentToken();

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension. Built to optimize for lower gas during batch mints.
 *
 * Assumes serials are sequentially minted starting at 0 (e.g. 0, 1, 2, 3..).
 *
 * Assumes that an owner cannot have more than 2**64 - 1 (max value of uint64) of supply.
 *
 * Assumes that the maximum token id cannot exceed 2**256 - 1 (max value of uint256).
 */
contract ERC721A is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Compiler will pack this into a single 256bit word.
    struct TokenOwnership {
        // The address of the owner.
        address addr;
        // Keeps track of the start time of ownership with minimal overhead for tokenomics.
        uint64 startTimestamp;
        // Whether the token has been burned.
        bool burned;
    }

    // Compiler will pack this into a single 256bit word.
    struct AddressData {
        // Realistically, 2**64-1 is more than enough.
        uint64 balance;
        // Keeps track of mint count with minimal overhead for tokenomics.
        uint64 numberMinted;
        // Keeps track of burn count with minimal overhead for tokenomics.
        uint64 numberBurned;
        // For miscellaneous variable(s) pertaining to the address
        // (e.g. number of whitelist mint slots used).
        // If there are multiple variables, please pack them into a uint64.
        uint64 aux;
    }

    // The tokenId of the next token to be minted.
    uint256 internal _currentIndex;

    // The number of tokens burned.
    uint256 internal _burnCounter;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to ownership details
    // An empty struct value does not necessarily mean the token is unowned. See ownershipOf implementation for details.
    mapping(uint256 => TokenOwnership) internal _ownerships;

    // Mapping owner address to address data
    mapping(address => AddressData) private _addressData;

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

    function _initToken(string memory name_, string memory symbol_) internal {
        require(bytes(_name).length == 0, "ERC721 token name already set");
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view returns (uint256) {
        // Counter underflow is impossible as _burnCounter cannot be incremented
        // more than _currentIndex times
        unchecked {
            return _currentIndex - _burnCounter;
        }
    }

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

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view override returns (uint256) {
        if (owner == address(0)) revert BalanceQueryForZeroAddress();
        return uint256(_addressData[owner].balance);
    }

    /**
     * Returns the number of tokens minted by `owner`.
     */
    function _numberMinted(address owner) internal view returns (uint256) {
        if (owner == address(0)) revert MintedQueryForZeroAddress();
        return uint256(_addressData[owner].numberMinted);
    }

    /**
     * Returns the number of tokens burned by or on behalf of `owner`.
     */
    function _numberBurned(address owner) internal view returns (uint256) {
        if (owner == address(0)) revert BurnedQueryForZeroAddress();
        return uint256(_addressData[owner].numberBurned);
    }

    /**
     * Returns the auxillary data for `owner`. (e.g. number of whitelist mint slots used).
     */
    function _getAux(address owner) internal view returns (uint64) {
        if (owner == address(0)) revert AuxQueryForZeroAddress();
        return _addressData[owner].aux;
    }

    /**
     * Sets the auxillary data for `owner`. (e.g. number of whitelist mint slots used).
     * If there are multiple variables, please pack them into a uint64.
     */
    function _setAux(address owner, uint64 aux) internal {
        if (owner == address(0)) revert AuxQueryForZeroAddress();
        _addressData[owner].aux = aux;
    }

    /**
     * Gas spent here starts off proportional to the maximum mint batch size.
     * It gradually moves to O(1) as tokens get transferred around in the collection over time.
     */
    function ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) {
        uint256 curr = tokenId;

        unchecked {
            if (curr < _currentIndex) {
                TokenOwnership memory ownership = _ownerships[curr];
                if (!ownership.burned) {
                    if (ownership.addr != address(0)) {
                        return ownership;
                    }
                    // Invariant:
                    // There will always be an ownership that has an address and is not burned
                    // before an ownership that does not have an address and is not burned.
                    // Hence, curr will not underflow.
                    while (true) {
                        curr--;
                        ownership = _ownerships[curr];
                        if (ownership.addr != address(0)) {
                            return ownership;
                        }
                    }
                }
            }
        }
        revert OwnerQueryForNonexistentToken();
    }

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

    /**
     * @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) {
        if (!_exists(tokenId)) revert URIQueryForNonexistentToken();

        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 override {
        address owner = ERC721A.ownerOf(tokenId);
        if (to == owner) revert ApprovalToCurrentOwner();

        if (_msgSender() != owner && !isApprovedForAll(owner, _msgSender())) {
            revert ApprovalCallerNotOwnerNorApproved();
        }

        _approve(to, tokenId, owner);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view override returns (address) {
        if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken();

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public override {
        if (operator == _msgSender()) revert ApproveToCaller();

        _operatorApprovals[_msgSender()][operator] = approved;
        emit ApprovalForAll(_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 {
        _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 {
        _transfer(from, to, tokenId);
        if (!_checkOnERC721Received(from, to, tokenId, _data)) {
            revert TransferToNonERC721ReceiverImplementer();
        }
    }

    /**
     * @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`),
     */
    function _exists(uint256 tokenId) internal view returns (bool) {
        return tokenId < _currentIndex && !_ownerships[tokenId].burned;
    }

    function _safeMint(address to, uint256 quantity) internal {
        _safeMint(to, quantity, "");
    }

    /**
     * @dev Safely mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called for each safe transfer.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(
        address to,
        uint256 quantity,
        bytes memory _data
    ) internal {
        _mint(to, quantity, _data, true);
    }

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _mint(
        address to,
        uint256 quantity,
        bytes memory _data,
        bool safe
    ) internal {
        uint256 startTokenId = _currentIndex;
        if (to == address(0)) revert MintToZeroAddress();
        if (quantity == 0) revert MintZeroQuantity();

        _beforeTokenTransfers(address(0), to, startTokenId, quantity);

        // Overflows are incredibly unrealistic.
        // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1
        // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1
        unchecked {
            _addressData[to].balance += uint64(quantity);
            _addressData[to].numberMinted += uint64(quantity);

            _ownerships[startTokenId].addr = to;
            _ownerships[startTokenId].startTimestamp = uint64(block.timestamp);

            uint256 updatedIndex = startTokenId;

            for (uint256 i; i < quantity; i++) {
                emit Transfer(address(0), to, updatedIndex);
                if (safe && !_checkOnERC721Received(address(0), to, updatedIndex, _data)) {
                    revert TransferToNonERC721ReceiverImplementer();
                }
                updatedIndex++;
            }

            _currentIndex = updatedIndex;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *
     * 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
    ) private {
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);

        bool isApprovedOrOwner = (_msgSender() == prevOwnership.addr ||
            isApprovedForAll(prevOwnership.addr, _msgSender()) ||
            getApproved(tokenId) == _msgSender());

        if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved();
        if (prevOwnership.addr != from) revert TransferFromIncorrectOwner();
        if (to == address(0)) revert TransferToZeroAddress();

        _beforeTokenTransfers(from, to, tokenId, 1);

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

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256.
        unchecked {
            _addressData[from].balance -= 1;
            _addressData[to].balance += 1;

            _ownerships[tokenId].addr = to;
            _ownerships[tokenId].startTimestamp = uint64(block.timestamp);

            // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint256 nextTokenId = tokenId + 1;
            if (_ownerships[nextTokenId].addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId < _currentIndex) {
                    _ownerships[nextTokenId].addr = prevOwnership.addr;
                    _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

        emit Transfer(from, to, tokenId);
        _afterTokenTransfers(from, to, tokenId, 1);
    }

    /**
     * @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 {
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);

        _beforeTokenTransfers(prevOwnership.addr, address(0), tokenId, 1);

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

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256.
        unchecked {
            _addressData[prevOwnership.addr].balance -= 1;
            _addressData[prevOwnership.addr].numberBurned += 1;

            // Keep track of who burned the token, and the timestamp of burning.
            _ownerships[tokenId].addr = prevOwnership.addr;
            _ownerships[tokenId].startTimestamp = uint64(block.timestamp);
            _ownerships[tokenId].burned = true;

            // If the ownership slot of tokenId+1 is not explicitly set, that means the burn initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint256 nextTokenId = tokenId + 1;
            if (_ownerships[nextTokenId].addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId < _currentIndex) {
                    _ownerships[nextTokenId].addr = prevOwnership.addr;
                    _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

        emit Transfer(prevOwnership.addr, address(0), tokenId);
        _afterTokenTransfers(prevOwnership.addr, address(0), tokenId, 1);

        // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times.
        unchecked {
            _burnCounter++;
        }
    }

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

    /**
     * @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(to).onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert TransferToNonERC721ReceiverImplementer();
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting.
     * And also called before burning one token.
     *
     * startTokenId - the first token id to be transferred
     * quantity - the amount to be transferred
     *
     * 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, `tokenId` will be burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _beforeTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}

    /**
     * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes
     * minting.
     * And also called after one token has been burned.
     *
     * startTokenId - the first token id to be transferred
     * quantity - the amount to be transferred
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been
     * transferred to `to`.
     * - When `from` is zero, `tokenId` has been minted for `to`.
     * - When `to` is zero, `tokenId` has been burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _afterTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}
}

File 5 of 31 : ERC2981.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/utils/introspection/ERC165.sol";

import "../interfaces/IERC2981Holder.sol";
import "../interfaces/IERC2981.sol";

///
/// @dev An implementor for the NFT Royalty Standard. Provides interface
/// response to erc2981 as well as a way to modify the royalty fees
/// per token and a way to transfer ownership of a token.
///
abstract contract ERC2981 is ERC165, IERC2981, IERC2981Holder {

    // royalty receivers by token hash
    mapping(uint256 => address) internal royaltyReceiversByHash;

    // royalties for each token hash - expressed as permilliage of total supply
    mapping(uint256 => uint256) internal royaltyFeesByHash;

    bytes4 internal constant _INTERFACE_ID_ERC2981 = 0x2a55205a;

    /// @dev only the royalty owner shall pass
    modifier onlyRoyaltyOwner(uint256 _id) {
        require(royaltyReceiversByHash[_id] == msg.sender,
        "Only the owner can modify the royalty fees");
        _;
    }

    /**
     * @dev ERC2981 - return the receiver and royalty payment given the id and sale price
     * @param _tokenId the id of the token
     * @param _salePrice the price of the token
     * @return receiver the receiver
     * @return royaltyAmount the royalty payment
     */
    function royaltyInfo(
        uint256 _tokenId,
        uint256 _salePrice
    ) external view override returns (
        address receiver,
        uint256 royaltyAmount
    ) {
        require(_salePrice > 0, "Sale price must be greater than 0");
        require(_tokenId > 0, "Token Id must be valid");

        // get the receiver of the royalty
        receiver = royaltyReceiversByHash[_tokenId];

        // calculate the royalty amount. royalty is expressed as permilliage of total supply
        royaltyAmount = royaltyFeesByHash[_tokenId] / 1000000 * _salePrice;
    }

    /// @notice ERC165 interface responder for this contract
    /// @param interfaceId - the interface id to check
    /// @return supportsIface - whether the interface is supported
    function supportsInterface(bytes4 interfaceId)
        public
        view
        virtual
        override returns (bool supportsIface) {
        supportsIface = interfaceId == type(IERC2981).interfaceId
        || super.supportsInterface(interfaceId);
    }

    /// @notice set the fee permilliage for a token hash
    /// @param _id - id of the token hash
    /// @param _fee - the fee permilliage to set
    function setFee(uint256 _id, uint256 _fee) onlyRoyaltyOwner(_id) external override {
        require(_id != 0, "Fee cannot be zero");
        royaltyFeesByHash[_id] = _fee;
    }

    /// @notice get the fee permilliage for a token hash
    /// @param _id - id of the token hash
    /// @return fee - the fee
    function getFee(uint256 _id) external view override returns (uint256 fee) {
        fee = royaltyFeesByHash[_id];
    }

    /// @notice get the royalty receiver for a token hash
    /// @param _id - id of the token hash
    /// @return owner - the royalty owner
    function royaltyOwner(uint256 _id) external view override returns (address owner) {
        owner = royaltyReceiversByHash[_id];
    }

    /// @notice get the royalty receiver for a token hash
    /// @param _id - id of the token hash
    /// @param _newOwner - address of the new owners
    function transferOwnership(uint256 _id, address _newOwner) onlyRoyaltyOwner(_id) external override {
        require(_id != 0 && _newOwner != address(0), "Invalid token id or new owner");
        royaltyReceiversByHash[_id] = _newOwner;
    }
}

File 6 of 31 : AddressSet.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.8.0;

/**
 * @notice Key sets with enumeration and delete. Uses mappings for random
 * and existence checks and dynamic arrays for enumeration. Key uniqueness is enforced.
 * @dev Sets are unordered. Delete operations reorder keys. All operations have a
 * fixed gas cost at any scale, O(1).
 * author: Rob Hitchens
 */

library AddressSet {
    struct Set {
        mapping(address => uint256) keyPointers;
        address[] keyList;
    }

    /**
     * @notice insert a key.
     * @dev duplicate keys are not permitted.
     * @param self storage pointer to a Set.
     * @param key value to insert.
     */
    function insert(Set storage self, address key) public {
        require(
            !exists(self, key),
            "AddressSet: key already exists in the set."
        );
        self.keyList.push(key);
        self.keyPointers[key] = self.keyList.length - 1;
    }

    /**
     * @notice remove a key.
     * @dev key to remove must exist.
     * @param self storage pointer to a Set.
     * @param key value to remove.
     */
    function remove(Set storage self, address key) public {
        // TODO: I commented this out do get a test to pass - need to figure out what is up here
        require(
            exists(self, key),
            "AddressSet: key does not exist in the set."
        );
        if (!exists(self, key)) return;
        uint256 last = count(self) - 1;
        uint256 rowToReplace = self.keyPointers[key];
        if (rowToReplace != last) {
            address keyToMove = self.keyList[last];
            self.keyPointers[keyToMove] = rowToReplace;
            self.keyList[rowToReplace] = keyToMove;
        }
        delete self.keyPointers[key];
        self.keyList.pop();
    }

    /**
     * @notice count the keys.
     * @param self storage pointer to a Set.
     */
    function count(Set storage self) public view returns (uint256) {
        return (self.keyList.length);
    }

    /**
     * @notice check if a key is in the Set.
     * @param self storage pointer to a Set.
     * @param key value to check.
     * @return bool true: Set member, false: not a Set member.
     */
    function exists(Set storage self, address key)
        public
        view
        returns (bool)
    {
        if (self.keyList.length == 0) return false;
        return self.keyList[self.keyPointers[key]] == key;
    }

    /**
     * @notice fetch a key by row (enumerate).
     * @param self storage pointer to a Set.
     * @param index row to enumerate. Must be < count() - 1.
     */
    function keyAtIndex(Set storage self, uint256 index)
        public
        view
        returns (address)
    {
        return self.keyList[index];
    }
}

File 7 of 31 : UInt256Set.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.8.0;

/**
 * @notice Key sets with enumeration and delete. Uses mappings for random
 * and existence checks and dynamic arrays for enumeration. Key uniqueness is enforced.
 * @dev Sets are unordered. Delete operations reorder keys. All operations have a
 * fixed gas cost at any scale, O(1).
 * author: Rob Hitchens
 */

library UInt256Set {
    struct Set {
        mapping(uint256 => uint256) keyPointers;
        uint256[] keyList;
    }

    /**
     * @notice insert a key.
     * @dev duplicate keys are not permitted.
     * @param self storage pointer to a Set.
     * @param key value to insert.
     */
    function insert(Set storage self, uint256 key) public {
        require(
            !exists(self, key),
            "UInt256Set: key already exists in the set."
        );
        self.keyList.push(key);
        self.keyPointers[key] = self.keyList.length - 1;
    }

    /**
     * @notice remove a key.
     * @dev key to remove must exist.
     * @param self storage pointer to a Set.
     * @param key value to remove.
     */
    function remove(Set storage self, uint256 key) public {
        // TODO: I commented this out do get a test to pass - need to figure out what is up here
        // require(
        //     exists(self, key),
        //     "UInt256Set: key does not exist in the set."
        // );
        if (!exists(self, key)) return;
        uint256 last = count(self) - 1;
        uint256 rowToReplace = self.keyPointers[key];
        if (rowToReplace != last) {
            uint256 keyToMove = self.keyList[last];
            self.keyPointers[keyToMove] = rowToReplace;
            self.keyList[rowToReplace] = keyToMove;
        }
        delete self.keyPointers[key];
        delete self.keyList[self.keyList.length - 1];
    }

    /**
     * @notice count the keys.
     * @param self storage pointer to a Set.
     */
    function count(Set storage self) public view returns (uint256) {
        return (self.keyList.length);
    }

    /**
     * @notice check if a key is in the Set.
     * @param self storage pointer to a Set.
     * @param key value to check.
     * @return bool true: Set member, false: not a Set member.
     */
    function exists(Set storage self, uint256 key)
        public
        view
        returns (bool)
    {
        if (self.keyList.length == 0) return false;
        return self.keyList[self.keyPointers[key]] == key;
    }

    /**
     * @notice fetch a key by row (enumerate).
     * @param self storage pointer to a Set.
     * @param index row to enumerate. Must be < count() - 1.
     */
    function keyAtIndex(Set storage self, uint256 index)
        public
        view
        returns (uint256)
    {
        return self.keyList[index];
    }
}

File 8 of 31 : ProxyRegistry.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

import "../interfaces/IProxyRegistry.sol";
import "../utils/AddressSet.sol";

/// @title ProxyRegistryManager
/// @notice a proxy registry is a registry of delegate proxies which have the ability to autoapprove transactions for some address / contract. Used by OpenSEA to enable feeless trades by a proxy account
contract ProxyRegistryManager is IProxyRegistryManager {

    // using the addressset library to store the addresses of the proxies
    using AddressSet for AddressSet.Set;

    // the set of registry managers able to manage this registry
    mapping(address => bool) internal registryManagers;

    // the set of proxy addresses
    AddressSet.Set private _proxyAddresses;

    /// @notice add a new registry manager to the registry
    /// @param newManager the address of the registry manager to add
    function addRegistryManager(address newManager) external virtual override {
        registryManagers[newManager] = true;
    }

    /// @notice remove a registry manager from the registry
    /// @param oldManager the address of the registry manager to remove
    function removeRegistryManager(address oldManager) external virtual override {
        registryManagers[oldManager] = false;
    }

    /// @notice check if an address is a registry manager
    /// @param _addr the address of the registry manager to check
    /// @return _isManager true if the address is a registry manager, false otherwise
    function isRegistryManager(address _addr)
    external
    virtual
    view
    override
    returns (bool _isManager) {
        return registryManagers[_addr];
    }

    /// @notice add a new proxy address to the registry
    /// @param newProxy the address of the proxy to add
    function addProxy(address newProxy) external virtual override {
        _proxyAddresses.insert(newProxy);
    }

    /// @notice remove a proxy address from the registry
    /// @param oldProxy the address of the proxy to remove
    function removeProxy(address oldProxy) external virtual override {
        _proxyAddresses.remove(oldProxy);
    }

    /// @notice check if an address is a proxy address
    /// @param proxy the address of the proxy to check
    /// @return _isProxy true if the address is a proxy address, false otherwise
    function isProxy(address proxy)
    external
    virtual
    view
    override
    returns (bool _isProxy) {
        _isProxy = _proxyAddresses.exists(proxy);
    }

    /// @notice get the count of proxy addresses
    /// @return _count the count of proxy addresses
    function allProxiesCount()
    external
    virtual
    view
    override
    returns (uint256 _count) {
        _count = _proxyAddresses.count();
    }

    /// @notice get the nth proxy address
    /// @param _index the index of the proxy address to get
    /// @return the nth proxy address
    function proxyAt(uint256 _index)
    external
    virtual
    view
    override
    returns (address) {
        return _proxyAddresses.keyAtIndex(_index);
    }

    /// @notice check if the proxy approves this request
    function _isApprovedForAll(address _owner, address _operator)
    internal
    view
    returns (bool isOperator)
    {
        // Whitelist OpenSea proxy contract for easy trading.
        for (uint256 i = 0; i < _proxyAddresses.keyList.length; i++) {
            IProxyRegistry proxyRegistry = IProxyRegistry(
                _proxyAddresses.keyList[i]
            );
            try proxyRegistry.proxies(_owner) returns (
                OwnableDelegateProxy thePr
            ) {
                if (address(thePr) == _operator) {
                    return true;
                }
            } catch {}
        }
        return false;
    }

}

File 9 of 31 : Controllable.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.8.0;

import "../interfaces/IControllable.sol";

abstract contract Controllable is IControllable {
    mapping(address => bool) internal _controllers;

    /**
     * @dev Throws if called by any account not in authorized list
     */
    modifier onlyController() {
        require(
            _controllers[msg.sender] == true || address(this) == msg.sender,
            "Controllable: caller is not a controller"
        );
        _;
    }

    /**
     * @dev Add an address allowed to control this contract
     */
    function addController(address _controller)
        external
        override
        onlyController
    {
        _addController(_controller);
    }
    function _addController(address _controller) internal {
        _controllers[_controller] = true;
    }

    /**
     * @dev Check if this address is a controller
     */
    function isController(address _address)
        external
        view
        override
        returns (bool allowed)
    {
        allowed = _isController(_address);
    }
    function _isController(address _address)
        internal view
        returns (bool allowed)
    {
        allowed = _controllers[_address];
    }

    /**
     * @dev Remove the sender address from the list of controllers
     */
    function relinquishControl() external override onlyController {
        _relinquishControl();
    }
    function _relinquishControl() internal onlyController{
        delete _controllers[msg.sender];
    }
}

File 10 of 31 : IMultiToken.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

import "./IERC1155Mint.sol";
import "./IERC1155Burn.sol";

/// @dev extended by the multitoken
interface IMultiToken is IERC1155Mint, IERC1155Burn {

    function symbolOf(uint256 _tokenId) external view returns (string memory);
    function nameOf(uint256 _tokenId) external view returns (string memory);

}

File 11 of 31 : IERC1155Mint.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

/// implemented by erc1155 tokens to allow mminting
interface IERC1155Mint {

    /// @notice event emitted when tokens are minted
    event MinterMinted(
        address target,
        uint256 tokenHash,
        uint256 amount
    );

    /// @notice mint tokens of specified amount to the specified address
    /// @param recipient the mint target
    /// @param tokenHash the token hash to mint
    /// @param amount the amount to mint
    function mint(
        address recipient,
        uint256 tokenHash,
        uint256 amount
    ) external;

}

File 12 of 31 : IERC1155Burn.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

/// implemented by erc1155 tokens to allow burning
interface IERC1155Burn {

    /// @notice event emitted when tokens are burned
    event MinterBurned(
        address target,
        uint256 tokenHash,
        uint256 amount
    );

    /// @notice burn tokens of specified amount from the specified address
    /// @param target the burn target
    /// @param tokenHash the token hash to burn
    /// @param amount the amount to burn
    function burn(
        address target,
        uint256 tokenHash,
        uint256 amount
    ) external;


}

File 13 of 31 : IERC1155Multinetwork.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

/// implemented by erc1155 tokens to allow the bridge to mint and burn tokens
/// bridge must be able to mint and burn tokens on the multitoken contract
interface IERC1155Multinetwork {

    // transfer token to a different address
    function networkTransferFrom(
        address from,
        address to,
        uint256 network,
        uint256 id,
        uint256 amount,
        bytes calldata data
    ) external;

    /**
     * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`.
     */
    event TransferNetworkERC1155(
        uint256 networkFrom,
        uint256 networkTo,
        address indexed operator,
        address indexed from,
        address indexed to,
        uint256 id,
        uint256 value
    );

}

File 14 of 31 : IERC1155Bridge.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

import "./IERC1155Multinetwork.sol";

/// @notice defines the interface for the bridge contract. This contract implements a decentralized
/// bridge for an erc1155 token which enables users to transfer erc1155 tokens between supported networks.
/// users request a transfer in one network, which registers the transfer in the bridge contract, and generates
/// an event. This event is seen by a validator, who validates the transfer by calling the validate method on
/// the target network. Once a majority of validators have validated the transfer, the transfer is executed on the
/// target network by minting the approriate token type and burning the appropriate amount of the source token,
/// which is held in custody by the bridge contract until the transaction is confirmed. In order to participate,
/// validators must register with the bridge contract and put up a deposit as collateral.  The deposit is returned
/// to the validator when the validator self-removes from the validator set. If the validator acts in a way that
/// violates the rules of the bridge contract - namely the validator fails to validate a number of transfers,
/// or the validator posts some number of transfers which remain unconfirmed, then the validator is removed from the
/// validator set and their bond is distributed to other validators. The validator will then need to re-bond and
/// re-register. Repeated violations of the rules of the bridge contract will result in the validator being removed
/// from the validator set permanently via a ban.
interface IERC1155Bridge is IERC1155Multinetwork {

    /// @notice the network transfer status
    /// pending = on its way to the target network
    /// confirmed = target network received the transfer
    enum NetworkTransferStatus {
        Started,
        Confirmed,
        Failed
    }

    /// @notice the network transfer request structure. contains all the expected params of a transfer plus one addition nwtwork id param
    struct NetworkTransferRequest {
        uint256 id;
        address from;
        address to;
        uint32 network;
        uint256 token;
        uint256 amount;
        bytes data;
        NetworkTransferStatus status;
    }

    /// @notice emitted when a transfer is started
    event NetworkTransferStarted(
        uint256 indexed id,
        NetworkTransferRequest data
    );

    /// @notice emitted when a transfer is confirmed
    event NetworkTransferConfirmed(
        uint256 indexed id,
        NetworkTransferRequest data
    );

    /// @notice emitted when a transfer is cancelled
    event NetworkTransferCancelled(
        uint256 indexed id,
        NetworkTransferRequest data
    );

    /// @notice the token this bridge works with
    function token() external view returns (address);

    /// @notice start the network transfer
    function transfer(
        uint256 id,
        NetworkTransferRequest memory request
    ) external;

    /// @notice confirm the transfer. called by the target-side bridge
    /// @param id the id of the transfer
    function confirm(uint256 id) external;

    /// @notice fail  the transfer. called by the target-side bridge
    /// @param id the id of the transfer
    function cancel(uint256 id) external;

    /// @notice get the transfer request struct
    /// @param id the id of the transfer
    /// @return the transfer request struct
    function get(uint256 id)
    external view returns (NetworkTransferRequest memory);


}

File 15 of 31 : Service.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

import "../interfaces/IJanusRegistry.sol";
import "../interfaces/IFactory.sol";

/// @title NextgemStakingPool
/// @notice implements a staking pool for nextgem. Intakes a token and issues another token over time
contract Service {

    address internal _serviceOwner;

    // the service registry controls everything. It tells all objects
    // what service address they are registered to, who the owner is,
    // and all other things that are good in the world.
    address internal _serviceRegistry;

    function _setRegistry(address registry) internal {

        _serviceRegistry = registry;

    }

}

File 16 of 31 : FactoryElement.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

import "../interfaces/IFactory.sol";

contract FactoryElement is IFactoryElement {

    address internal _factory;
    address internal _owner;

    modifier onlyFactory() {
        require(_factory == address(0) || _factory == msg.sender, "Only factory can call this function");
        _;
    }

    modifier onlyFactoryOwner() {
        require(_factory == address(0) ||_owner == msg.sender, "Only owner can call this function");
        _;
    }

    function factoryCreated(address factory_, address owner_) external override {
        require(_owner == address(0), "already created");
        _factory = factory_;
        _owner = owner_;
    }

    function factory() external view override returns(address) {
        return _factory;
    }

    function owner() external view override  returns(address) {
        return _owner;
    }

}

File 17 of 31 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Address.sol)

pragma solidity ^0.8.0;

/**
 * @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
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

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

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

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

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

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

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

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 18 of 31 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (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`, 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 be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

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

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

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

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

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

File 19 of 31 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (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 `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

File 20 of 31 : 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 21 of 31 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

File 22 of 31 : 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 23 of 31 : 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 24 of 31 : 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 25 of 31 : IERC2981Holder.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/interfaces/IERC165.sol";

///
/// @dev interface for a holder (owner) of an ERC2981-enabled token
/// @dev to modify the fee amount as well as transfer ownership of
/// @dev royalty to someone else.
///
interface IERC2981Holder {

    /// @dev emitted when the roalty has changed
    event RoyaltyFeeChanged(
        address indexed operator,
        uint256 indexed _id,
        uint256 _fee
    );

    /// @dev emitted when the roalty ownership has been transferred
    event RoyaltyOwnershipTransferred(
        uint256 indexed _id,
        address indexed oldOwner,
        address indexed newOwner
    );

    /// @notice set the fee amount for the fee id
    /// @param _id  the fee id
    /// @param _fee the fee amount
    function setFee(uint256 _id, uint256 _fee) external;

    /// @notice get the fee amount for the fee id
    /// @param _id  the fee id
    /// @return the fee amount
    function getFee(uint256 _id) external returns (uint256);

    /// @notice get the owner address of the royalty
    /// @param _id  the fee id
    /// @return the owner address
    function royaltyOwner(uint256 _id) external returns (address);


    /// @notice transfer ownership of the royalty to someone else
    /// @param _id  the fee id
    /// @param _newOwner  the new owner address
    function transferOwnership(uint256 _id, address _newOwner) external;

}

File 26 of 31 : IERC2981.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

/// @dev Interface for the NFT Royalty Standard
///
interface IERC2981 {
    /// @notice Called with the sale price to determine how much royalty
    //          is owed and to whom.
    /// @param _tokenId - the NFT asset queried for royalty information
    /// @param _salePrice - the sale price of the NFT asset specified by _tokenId
    /// @return receiver - address of who should be sent the royalty payment
    /// @return royaltyAmount - the royalty payment amount for _salePrice
    function royaltyInfo(uint256 _tokenId, uint256 _salePrice)
        external
        view
        returns (address receiver, uint256 royaltyAmount);
}

File 27 of 31 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC165.sol)

pragma solidity ^0.8.0;

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

File 28 of 31 : IProxyRegistry.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

interface OwnableDelegateProxy {}

/**
 * @dev a registry of proxies
 */
interface IProxyRegistry {

    function proxies(address _owner) external view returns (OwnableDelegateProxy);

}

/// @notice a proxy registry is a registry of delegate proxies which have the ability to autoapprove transactions for some address / contract. Used by OpenSEA to enable feeless trades by a proxy account
interface IProxyRegistryManager {

    /// @notice add a new registry manager to the registry
    /// @param newManager the address of the registry manager to add
    function addRegistryManager(address newManager) external;

   /// @notice remove a registry manager from the registry
    /// @param oldManager the address of the registry manager to remove
    function removeRegistryManager(address oldManager) external;

    /// @notice check if an address is a registry manager
    /// @param _addr the address of the registry manager to check
    /// @return _isRegistryManager true if the address is a registry manager, false otherwise
    function isRegistryManager(address _addr)
        external
        view
        returns (bool _isRegistryManager);

    /// @notice add a new proxy address to the registry
    /// @param newProxy the address of the proxy to add
    function addProxy(address newProxy) external;

    /// @notice remove a proxy address from the registry
    /// @param oldProxy the address of the proxy to remove
    function removeProxy(address oldProxy) external;

    /// @notice check if an address is a proxy address
    /// @param _addr the address of the proxy to check
    /// @return _is true if the address is a proxy address, false otherwise
    function isProxy(address _addr)
        external
        view
        returns (bool _is);

    /// @notice get count of proxies
    /// @return _allCount the number of proxies
    function allProxiesCount()
        external
        view
        returns (uint256 _allCount);

    /// @notice get the address of a proxy at a given index
    /// @param _index the index of the proxy to get
    /// @return _proxy the address of the proxy at the given index
    function proxyAt(uint256 _index)
        external
        view
        returns (address _proxy);

}

File 29 of 31 : IControllable.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.0;

/// @notice a controllable contract interface. allows for controllers to perform privileged actions. controllera can other controllers and remove themselves.
interface IControllable {

    /// @notice emitted when a controller is added.
    event ControllerAdded(
        address indexed contractAddress,
        address indexed controllerAddress
    );

    /// @notice emitted when a controller is removed.
    event ControllerRemoved(
        address indexed contractAddress,
        address indexed controllerAddress
    );

    /// @notice adds a controller.
    /// @param controller the controller to add.
    function addController(address controller) external;

    /// @notice removes a controller.
    /// @param controller the address to check
    /// @return true if the address is a controller
    function isController(address controller) external view returns (bool);

    /// @notice remove ourselves from the list of controllers.
    function relinquishControl() external;
}

File 30 of 31 : IJanusRegistry.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

/// @notice implements a Janus (multifaced) registry. GLobal registry items can be set by specifying 0 for the registry face. Those global items are then available to all faces, and individual faces can override the global items for
interface IJanusRegistry {

    /// @notice Get the registro address given the face name. If the face is 0, the global registry is returned.
    /// @param face the face name or 0 for the global registry
    /// @param name uint256 of the token index
    /// @return item the service token record
    function get(string memory face, string memory name)
    external
    view
    returns (address item);

    /// @notice returns whether the service is in the list
    /// @param item uint256 of the token index
    function member(address item)
    external
    view
    returns (string memory face, string memory name);

}

File 31 of 31 : IFactory.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.0;

interface IFactoryElement {
    function factoryCreated(address _factory, address _owner) external;
    function factory() external returns(address);
    function owner() external returns(address);
}

/// @title A title that should describe the contract/interface
/// @author The name of the author
/// @notice Explain to an end user what this does
/// @dev Explain to a developer any extra details
/// @notice a contract factory. Can create an instance of a new contract and return elements from that list to callers
interface IFactory {

    /// @notice a contract instance.
    struct Instance {
        address factory;
        address contractAddress;
    }

    /// @dev emitted when a new contract instance has been craeted
    event InstanceCreated(
        address factory,
        address contractAddress,
        Instance data
    );

    /// @notice a set of requirements. used for random access
    struct FactoryInstanceSet {
        mapping(uint256 => uint256) keyPointers;
        uint256[] keyList;
        Instance[] valueList;
    }

    struct FactoryData {
        FactoryInstanceSet instances;
    }

    struct FactorySettings {
        FactoryData data;
    }

    /// @notice returns the contract bytecode
    /// @return _instances the contract bytecode
    function contractBytes() external view returns (bytes memory _instances);

    /// @notice returns the contract instances as a list of instances
    /// @return _instances the contract instances
    function instances() external view returns (Instance[] memory _instances);

    /// @notice returns the contract instance at the given index
    /// @param idx the index of the instance to return
    /// @return instance the instance at the given index
    function at(uint256 idx) external view returns (Instance memory instance);

    /// @notice returns the length of the already-created contracts list
    /// @return _length the length of the list
    function count() external view returns (uint256 _length);

    /// @notice creates a new contract instance
    /// @param owner the owner of the new contract
    /// @param salt the salt to use for the new contract
    /// @return instanceOut the address of the new contract
    function create(address owner, uint256 salt)
        external
        returns (Instance memory instanceOut);

}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 5
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "metadata": {
    "useLiteralContent": true
  },
  "libraries": {
    "contracts/utils/AddressSet.sol": {
      "AddressSet": "0xae09d7b704281cf10e7bb1776b68fca3d8c94e7c"
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApprovalToCurrentOwner","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","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":"contractAddress","type":"address"},{"indexed":true,"internalType":"address","name":"controllerAddress","type":"address"}],"name":"ControllerAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"contractAddress","type":"address"},{"indexed":true,"internalType":"address","name":"controllerAddress","type":"address"}],"name":"ControllerRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"target","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenHash","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MinterBurned","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"target","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenHash","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"MinterMinted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"uint256","name":"_id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"RoyaltyFeeChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"_id","type":"uint256"},{"indexed":true,"internalType":"address","name":"oldOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"RoyaltyOwnershipTransferred","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":false,"internalType":"uint256","name":"networkFrom","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"networkTo","type":"uint256"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferNetworkERC1155","type":"event"},{"inputs":[{"internalType":"address","name":"_controller","type":"address"}],"name":"addController","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"directMinter","type":"address"}],"name":"addDirectMinter","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newProxy","type":"address"}],"name":"addProxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newManager","type":"address"}],"name":"addRegistryManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"allProxiesCount","outputs":[{"internalType":"uint256","name":"_count","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"tokenHash","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"factory_","type":"address"},{"internalType":"address","name":"owner_","type":"address"}],"name":"factoryCreated","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"getFee","outputs":[{"internalType":"uint256","name":"fee","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"symbol","type":"string"},{"internalType":"string","name":"name","type":"string"}],"name":"initToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"registry","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"isOperator","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"}],"name":"isController","outputs":[{"internalType":"bool","name":"allowed","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"proxy","type":"address"}],"name":"isProxy","outputs":[{"internalType":"bool","name":"_isProxy","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"isRegistryManager","outputs":[{"internalType":"bool","name":"_isManager","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"mintWithCommonUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"nameOf","outputs":[{"internalType":"string","name":"out","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"network","type":"uint256"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"networkTransferFrom","outputs":[],"stateMutability":"nonpayable","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":"_index","type":"uint256"}],"name":"proxyAt","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"relinquishControl","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"oldProxy","type":"address"}],"name":"removeProxy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"oldManager","type":"address"}],"name":"removeRegistryManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"royaltyAmount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"}],"name":"royaltyOwner","outputs":[{"internalType":"address","name":"owner","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"value","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_id","type":"uint256"},{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_masterMinter","type":"address"}],"name":"setMasterController","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"string","name":"_nameOf","type":"string"}],"name":"setNameOf","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"setRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"string","name":"_symbolOf","type":"string"}],"name":"setSymbolOf","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"symbolOf","outputs":[{"internalType":"string","name":"out","type":"string"}],"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":"uint256","name":"_id","type":"uint256"},{"internalType":"address","name":"_newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50612ab9806100206000396000f3fe608060405234801561001057600080fd5b50600436106102305760003560e01c806301ffc9a714610235578063051a26641461025d57806306fdde031461027d578063081812fc14610285578063095ea7b3146102a5578063148d6d85146102ba578063156e29f6146102cd57806318160ddd146102e057806323b11d8d146102f657806323b872dd1461030957806324ed0b9f1461031c57806326fc02091461032f57806329507f7314610358578063297103881461036b5780632a55205a1461037e5780632ec37933146103b05780634048d909146103df57806342842e0e1461040b57806352f7c9881461041e57806355f804b3146104315780636352211e14610444578063672cb1a8146104575780636c0360eb146104895780636e655c891461049157806370a08231146104a457806375cfbe6c146104b75780637db3c828146104ca5780638da5cb5b146104dd57806395d89b41146104ee578063a22cb465146104f6578063a307a4e314610509578063a7f80cb41461051c578063a7fc7a071461052f578063b429afeb14610542578063b88d4fde14610555578063be116c3b14610568578063bfe7418c1461057b578063c45a015514610583578063c4d66de81461059a578063c87b56dd146105ad578063d9d182a6146105c0578063dbedf573146105d3578063e1c28bef146105e6578063e985e9c5146105ee578063f03594a014610601578063f3c4a41414610614578063f5298aca14610627578063fcee45f41461063a575b600080fd5b610248610243366004612535565b61065a565b60405190151581526020015b60405180910390f35b61027061026b366004612606565b610685565b60405161025491906127f2565b610270610727565b610298610293366004612606565b6107b9565b604051610254919061273d565b6102b86102b336600461247c565b6107fd565b005b6102b86102c83660046124dd565b61088b565b6102b86102db3660046124a8565b6108f0565b600154600054035b604051908152602001610254565b6102b8610304366004612267565b610946565b6102b86103173660046122da565b6109b3565b6102b861032a366004612684565b6109be565b61029861033d366004612606565b6000908152600b60205260409020546001600160a01b031690565b6102b8610366366004612638565b610a17565b610248610379366004612267565b610ae1565b61039161038c3660046126c0565b610b6e565b604080516001600160a01b039093168352602083019190915201610254565b6102b86103be366004612267565b6001600160a01b03166000908152600860205260409020805460ff19169055565b6102486103ed366004612267565b6001600160a01b031660009081526008602052604090205460ff1690565b6102b86104193660046122da565b610c5f565b6102b861042c3660046126c0565b610c7a565b6102b861043f36600461256f565b610d07565b610298610452366004612606565b610d58565b6102b8610465366004612267565b6001600160a01b03166000908152600860205260409020805460ff19166001179055565b610270610d6a565b6102b861049f3660046125a3565b610d79565b6102e86104b2366004612267565b610d83565b6102706104c5366004612606565b610dd1565b6102b86104d836600461265d565b610dee565b6011546001600160a01b0316610298565b610270610e4c565b6102b861050436600461244e565b610e5b565b6102b8610517366004612267565b610ef1565b6102b861052a366004612267565b610f69565b6102b861053d366004612267565b610fe6565b610248610550366004612267565b611024565b6102b861056336600461231b565b61102f565b6102b8610576366004612267565b611063565b6102e861109d565b6010546201000090046001600160a01b0316610298565b6102b86105a8366004612267565b611123565b6102706105bb366004612606565b611200565b6102b86105ce3660046122a1565b611285565b6102b86105e1366004612684565b61130a565b6102b8611363565b6102486105fc3660046122a1565b6113ab565b6102b861060f36600461239a565b6113f3565b610298610622366004612606565b611576565b6102b86106353660046124a8565b611603565b6102e8610648366004612606565b6000908152600c602052604090205490565b60006001600160e01b031982166380ac58cd60e01b148061067f575061067f82611646565b92915050565b60008181526016602052604090208054606091906106a290612968565b80601f01602080910402602001604051908101604052809291908181526020018280546106ce90612968565b801561071b5780601f106106f05761010080835404028352916020019161071b565b820191906000526020600020905b8154815290600101906020018083116106fe57829003601f168201915b50505050509050919050565b60606002805461073690612968565b80601f016020809104026020016040519081016040528092919081815260200182805461076290612968565b80156107af5780601f10610784576101008083540402835291602001916107af565b820191906000526020600020905b81548152906001019060200180831161079257829003601f168201915b5050505050905090565b60006107c48261166b565b6107e1576040516333d1c03960e21b815260040160405180910390fd5b506000908152600660205260409020546001600160a01b031690565b600061080882610d58565b9050806001600160a01b0316836001600160a01b0316141561083d5760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b0382161480159061085d575061085b81336113ab565b155b1561087b576040516367d9dca160e11b815260040160405180910390fd5b610886838383611696565b505050565b610894336116f2565b806108a957506012546001600160a01b031633145b6108ce5760405162461bcd60e51b81526004016108c590612805565b60405180910390fd5b6108ea8483604051806020016040528060008152506001611710565b50505050565b6108f9336116f2565b8061090e57506012546001600160a01b031633145b61092a5760405162461bcd60e51b81526004016108c590612805565b6108868382604051806020016040528060008152506001611710565b60405163989779e960e01b815273ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063989779e9906109809060099085906004016128c3565b60006040518083038186803b15801561099857600080fd5b505af41580156109ac573d6000803e3d6000fd5b5050505050565b61088683838361185a565b6109c7336116f2565b806109dc57506012546001600160a01b031633145b6109f85760405162461bcd60e51b81526004016108c590612805565b6000828152601660209081526040909120825161088692840190612139565b6000828152600b602052604090205482906001600160a01b03163314610a4f5760405162461bcd60e51b81526004016108c590612879565b8215801590610a6657506001600160a01b03821615155b610ab25760405162461bcd60e51b815260206004820152601d60248201527f496e76616c696420746f6b656e206964206f72206e6577206f776e657200000060448201526064016108c5565b506000918252600b602052604090912080546001600160a01b0319166001600160a01b03909216919091179055565b60405163a8a37bd360e01b815260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063a8a37bd390610b1e9060099086906004016128c3565b60206040518083038186803b158015610b3657600080fd5b505af4158015610b4a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067f9190612518565b60008060008311610bcb5760405162461bcd60e51b815260206004820152602160248201527f53616c65207072696365206d7573742062652067726561746572207468616e206044820152600360fc1b60648201526084016108c5565b60008411610c145760405162461bcd60e51b8152602060048201526016602482015275151bdad95b881259081b5d5cdd081899481d985b1a5960521b60448201526064016108c5565b6000848152600b6020908152604080832054600c909252909120546001600160a01b0390911692508390610c4c90620f4240906128f2565b610c569190612906565b90509250929050565b6108868383836040518060200160405280600081525061102f565b6000828152600b602052604090205482906001600160a01b03163314610cb25760405162461bcd60e51b81526004016108c590612879565b82610cf45760405162461bcd60e51b81526020600482015260126024820152714665652063616e6e6f74206265207a65726f60701b60448201526064016108c5565b506000918252600c602052604090912055565b610d10336116f2565b80610d2557506012546001600160a01b031633145b610d415760405162461bcd60e51b81526004016108c590612805565b8051610d54906014906020840190612139565b5050565b6000610d6382611a58565b5192915050565b6060610d74611b71565b905090565b610d548282611b80565b60006001600160a01b038216610dac576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b03166000908152600560205260409020546001600160401b031690565b60008181526015602052604090208054606091906106a290612968565b610df7336116f2565b610e135760405162461bcd60e51b81526004016108c590612805565b6000928352600b6020908152604080852080546001600160a01b0319166001600160a01b039590951694909417909355600c9052912055565b60606003805461073690612968565b6001600160a01b038216331415610e855760405163b06307db60e01b815260040160405180910390fd5b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6012546001600160a01b03163314610f5d5760405162461bcd60e51b815260206004820152602960248201527f6f6e6c79206d6173746572206d696e7465722063616e2061646420646972656360448201526874206d696e7465727360b81b60648201526084016108c5565b610f6681611c03565b50565b6012546001600160a01b031615610fc25760405162461bcd60e51b815260206004820152601d60248201527f6d6173746572206d696e746572206d757374206e6f742062652073657400000060448201526064016108c5565b601280546001600160a01b0319166001600160a01b038316179055610f6681611c03565b336000908152600f602052604090205460ff1615156001148061100857503033145b610f5d5760405162461bcd60e51b81526004016108c590612831565b600061067f826116f2565b61103a84848461185a565b61104684848484611c27565b6108ea576040516368d2bf6b60e11b815260040160405180910390fd5b604051638c9d1e4160e01b815273ae09d7b704281cf10e7bb1776b68fca3d8c94e7c90638c9d1e41906109809060099085906004016128c3565b60405163300f372b60e11b81526009600482015260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063601e6e569060240160206040518083038186803b1580156110eb57600080fd5b505af41580156110ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d74919061261f565b601054610100900460ff1661113e5760105460ff1615611142565b303b155b6111a55760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016108c5565b601054610100900460ff161580156111c7576010805461ffff19166101011790555b6111d033611c03565b600e80546001600160a01b0319166001600160a01b0384161790558015610d54576010805461ff00191690555050565b606061120b8261166b565b61122857604051630a14c4b560e41b815260040160405180910390fd5b6000611232611b71565b9050805160001415611253576040518060200160405280600081525061127e565b8061125d84611d35565b60405160200161126e92919061270e565b6040516020818303038152906040525b9392505050565b6011546001600160a01b0316156112d05760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e4818dc99585d1959608a1b60448201526064016108c5565b6010805462010000600160b01b031916620100006001600160a01b0394851602179055601180546001600160a01b03191691909216179055565b611313336116f2565b8061132857506012546001600160a01b031633145b6113445760405162461bcd60e51b81526004016108c590612805565b6000828152601560209081526040909120825161088692840190612139565b336000908152600f602052604090205460ff1615156001148061138557503033145b6113a15760405162461bcd60e51b81526004016108c590612831565b6113a9611e32565b565b6000806113b88484611e89565b905080806113eb57506001600160a01b0380851660009081526007602090815260408083209387168352929052205460ff165b949350505050565b600e5460408051633e10510b60e01b81526004810191909152600a60448201526926bab63a34aa37b5b2b760b11b606482015260806024820152600d60848201526c4e6574776f726b42726964676560981b60a48201526000916001600160a01b031690633e10510b9060c40160206040518083038186803b15801561147857600080fd5b505afa15801561148c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114b09190612284565b90506001600160a01b0381166115025760405162461bcd60e51b8152602060048201526017602482015276139bc81b995d1ddbdc9ac8189c9a5919d948199bdd5b99604a1b60448201526064016108c5565b604051630781aca560e51b81526001600160a01b0382169063f03594a09061153a908b908b908b908b908b908b908b9060040161278e565b600060405180830381600087803b15801561155457600080fd5b505af1158015611568573d6000803e3d6000fd5b505050505050505050505050565b604051636f911ea160e11b8152600960048201526024810182905260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063df223d429060440160206040518083038186803b1580156115cb57600080fd5b505af41580156115df573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067f9190612284565b61160c336116f2565b8061162157506012546001600160a01b031633145b61163d5760405162461bcd60e51b81526004016108c590612805565b61088682611f81565b60006001600160e01b0319821663152a902d60e11b148061067f575061067f826120e9565b600080548210801561067f575050600090815260046020526040902054600160e01b900460ff161590565b60008281526006602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b6001600160a01b03166000908152600f602052604090205460ff1690565b6000546001600160a01b03851661173957604051622e076360e81b815260040160405180910390fd5b836117575760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260056020908152604080832080546001600160801b031981166001600160401b038083168c018116918217600160401b6001600160401b031990941690921783900481168c018116909202179091558584526004909252822080546001600160e01b031916909317600160a01b42909216919091021790915581905b858110156118515760405182906001600160a01b03891690600090600080516020612a64833981519152908290a483801561182757506118256000888488611c27565b155b15611845576040516368d2bf6b60e11b815260040160405180910390fd5b600191820191016117e2565b506000556109ac565b600061186582611a58565b80519091506000906001600160a01b0316336001600160a01b031614806118935750815161189390336113ab565b806118ae5750336118a3846107b9565b6001600160a01b0316145b9050806118ce57604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b0316146119035760405162a1148160e81b815260040160405180910390fd5b6001600160a01b03841661192a57604051633a954ecd60e21b815260040160405180910390fd5b61193a6000848460000151611696565b6001600160a01b03858116600090815260056020908152604080832080546001600160401b03198082166001600160401b0392831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600490945282852080546001600160e01b031916909417600160a01b429092169190910217909255908601808352912054909116611a2357600054811015611a2357825160008281526004602090815260409091208054918601516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b5082846001600160a01b0316866001600160a01b0316600080516020612a6483398151915260405160405180910390a46109ac565b6040805160608101825260008082526020820181905291810182905290548290811015611b5857600081815260046020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff16151591810182905290611b565780516001600160a01b031615611aed579392505050565b5060001901600081815260046020908152604091829020825160608101845290546001600160a01b038116808352600160a01b82046001600160401b031693830193909352600160e01b900460ff1615159281019290925215611b51579392505050565b611aed565b505b604051636f96cda160e11b815260040160405180910390fd5b60606014805461073690612968565b60028054611b8d90612968565b159050611bdc5760405162461bcd60e51b815260206004820152601d60248201527f45524337323120746f6b656e206e616d6520616c72656164792073657400000060448201526064016108c5565b8151611bef906002906020850190612139565b508051610886906003906020840190612139565b6001600160a01b03166000908152600f60205260409020805460ff19166001179055565b60006001600160a01b0384163b15611d2a57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611c6b903390899088908890600401612751565b602060405180830381600087803b158015611c8557600080fd5b505af1925050508015611cb5575060408051601f3d908101601f19168201909252611cb291810190612552565b60015b611d10573d808015611ce3576040519150601f19603f3d011682016040523d82523d6000602084013e611ce8565b606091505b508051611d08576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506113eb565b506001949350505050565b606081611d595750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611d835780611d6d816129a3565b9150611d7c9050600a836128f2565b9150611d5d565b6000816001600160401b03811115611d9d57611d9d612a14565b6040519080825280601f01601f191660200182016040528015611dc7576020820181803683370190505b5090505b84156113eb57611ddc600183612925565b9150611de9600a866129be565b611df49060306128da565b60f81b818381518110611e0957611e096129fe565b60200101906001600160f81b031916908160001a905350611e2b600a866128f2565b9450611dcb565b336000908152600f602052604090205460ff16151560011480611e5457503033145b611e705760405162461bcd60e51b81526004016108c590612831565b336000908152600f60205260409020805460ff19169055565b6000805b600a54811015611f7757600060096001018281548110611eaf57611eaf6129fe565b60009182526020909120015460405163c455279160e01b81526001600160a01b039091169150819063c455279190611eeb90889060040161273d565b60206040518083038186803b158015611f0357600080fd5b505afa925050508015611f33575060408051601f3d908101601f19168201909252611f3091810190612284565b60015b611f3c57611f64565b846001600160a01b0316816001600160a01b03161415611f62576001935050505061067f565b505b5080611f6f816129a3565b915050611e8d565b5060009392505050565b6000611f8c82611a58565b9050611f9e6000838360000151611696565b80516001600160a01b03908116600090815260056020908152604080832080546001600160401b031981166001600160401b03918216600019018216179091558551851684528184208054600160801b600160c01b03198116600160801b9182900484166001908101851690920217909155865188865260049094528285208054600160e01b9588166001600160e01b031990911617600160a01b42909416939093029290921760ff60e01b19169390931790559085018083529120549091166120b3576000548110156120b357815160008281526004602090815260409091208054918501516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b50805160405183916000916001600160a01b0390911690600080516020612a64833981519152908390a450506001805481019055565b60006001600160e01b031982166380ac58cd60e01b148061211a57506001600160e01b03198216635b5e139f60e01b145b8061067f57506301ffc9a760e01b6001600160e01b031983161461067f565b82805461214590612968565b90600052602060002090601f01602090048101928261216757600085556121ad565b82601f1061218057805160ff19168380011785556121ad565b828001600101855582156121ad579182015b828111156121ad578251825591602001919060010190612192565b506121b99291506121bd565b5090565b5b808211156121b957600081556001016121be565b60006001600160401b03808411156121ec576121ec612a14565b604051601f8501601f19908116603f0116810190828211818310171561221457612214612a14565b8160405280935085815286868601111561222d57600080fd5b858560208301376000602087830101525050509392505050565b600082601f83011261225857600080fd5b61127e838335602085016121d2565b60006020828403121561227957600080fd5b813561127e81612a2a565b60006020828403121561229657600080fd5b815161127e81612a2a565b600080604083850312156122b457600080fd5b82356122bf81612a2a565b915060208301356122cf81612a2a565b809150509250929050565b6000806000606084860312156122ef57600080fd5b83356122fa81612a2a565b9250602084013561230a81612a2a565b929592945050506040919091013590565b6000806000806080858703121561233157600080fd5b843561233c81612a2a565b9350602085013561234c81612a2a565b92506040850135915060608501356001600160401b0381111561236e57600080fd5b8501601f8101871361237f57600080fd5b61238e878235602084016121d2565b91505092959194509250565b600080600080600080600060c0888a0312156123b557600080fd5b87356123c081612a2a565b965060208801356123d081612a2a565b955060408801359450606088013593506080880135925060a08801356001600160401b038082111561240157600080fd5b818a0191508a601f83011261241557600080fd5b81358181111561242457600080fd5b8b602082850101111561243657600080fd5b60208301945080935050505092959891949750929550565b6000806040838503121561246157600080fd5b823561246c81612a2a565b915060208301356122cf81612a3f565b6000806040838503121561248f57600080fd5b823561249a81612a2a565b946020939093013593505050565b6000806000606084860312156124bd57600080fd5b83356124c881612a2a565b95602085013595506040909401359392505050565b600080600080608085870312156124f357600080fd5b84356124fe81612a2a565b966020860135965060408601359560600135945092505050565b60006020828403121561252a57600080fd5b815161127e81612a3f565b60006020828403121561254757600080fd5b813561127e81612a4d565b60006020828403121561256457600080fd5b815161127e81612a4d565b60006020828403121561258157600080fd5b81356001600160401b0381111561259757600080fd5b6113eb84828501612247565b600080604083850312156125b657600080fd5b82356001600160401b03808211156125cd57600080fd5b6125d986838701612247565b935060208501359150808211156125ef57600080fd5b506125fc85828601612247565b9150509250929050565b60006020828403121561261857600080fd5b5035919050565b60006020828403121561263157600080fd5b5051919050565b6000806040838503121561264b57600080fd5b8235915060208301356122cf81612a2a565b60008060006060848603121561267257600080fd5b83359250602084013561230a81612a2a565b6000806040838503121561269757600080fd5b8235915060208301356001600160401b038111156126b457600080fd5b6125fc85828601612247565b600080604083850312156126d357600080fd5b50508035926020909101359150565b600081518084526126fa81602086016020860161293c565b601f01601f19169290920160200192915050565b6000835161272081846020880161293c565b83519083019061273481836020880161293c565b01949350505050565b6001600160a01b0391909116815260200190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612784908301846126e2565b9695505050505050565b6001600160a01b0388811682528716602082015260408101869052606081018590526080810184905260c060a0820181905281018290526000828460e0840137600060e0848401015260e0601f19601f850116830101905098975050505050505050565b60208152600061127e60208301846126e2565b602080825260129082015271596f75207368616c6c206e6f74207061737360701b604082015260600190565b60208082526028908201527f436f6e74726f6c6c61626c653a2063616c6c6572206973206e6f74206120636f604082015267373a3937b63632b960c11b606082015260800190565b6020808252602a908201527f4f6e6c7920746865206f776e65722063616e206d6f646966792074686520726f60408201526979616c7479206665657360b01b606082015260800190565b9182526001600160a01b0316602082015260400190565b600082198211156128ed576128ed6129d2565b500190565b600082612901576129016129e8565b500490565b6000816000190483118215151615612920576129206129d2565b500290565b600082821015612937576129376129d2565b500390565b60005b8381101561295757818101518382015260200161293f565b838111156108ea5750506000910152565b600181811c9082168061297c57607f821691505b6020821081141561299d57634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129b7576129b76129d2565b5060010190565b6000826129cd576129cd6129e8565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610f6657600080fd5b8015158114610f6657600080fd5b6001600160e01b031981168114610f6657600080fdfeddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220c22c470116fc73ab21edcba8a93180dcc385ce41b4c4ca32227fa5e3a04527ee64736f6c63430008060033

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106102305760003560e01c806301ffc9a714610235578063051a26641461025d57806306fdde031461027d578063081812fc14610285578063095ea7b3146102a5578063148d6d85146102ba578063156e29f6146102cd57806318160ddd146102e057806323b11d8d146102f657806323b872dd1461030957806324ed0b9f1461031c57806326fc02091461032f57806329507f7314610358578063297103881461036b5780632a55205a1461037e5780632ec37933146103b05780634048d909146103df57806342842e0e1461040b57806352f7c9881461041e57806355f804b3146104315780636352211e14610444578063672cb1a8146104575780636c0360eb146104895780636e655c891461049157806370a08231146104a457806375cfbe6c146104b75780637db3c828146104ca5780638da5cb5b146104dd57806395d89b41146104ee578063a22cb465146104f6578063a307a4e314610509578063a7f80cb41461051c578063a7fc7a071461052f578063b429afeb14610542578063b88d4fde14610555578063be116c3b14610568578063bfe7418c1461057b578063c45a015514610583578063c4d66de81461059a578063c87b56dd146105ad578063d9d182a6146105c0578063dbedf573146105d3578063e1c28bef146105e6578063e985e9c5146105ee578063f03594a014610601578063f3c4a41414610614578063f5298aca14610627578063fcee45f41461063a575b600080fd5b610248610243366004612535565b61065a565b60405190151581526020015b60405180910390f35b61027061026b366004612606565b610685565b60405161025491906127f2565b610270610727565b610298610293366004612606565b6107b9565b604051610254919061273d565b6102b86102b336600461247c565b6107fd565b005b6102b86102c83660046124dd565b61088b565b6102b86102db3660046124a8565b6108f0565b600154600054035b604051908152602001610254565b6102b8610304366004612267565b610946565b6102b86103173660046122da565b6109b3565b6102b861032a366004612684565b6109be565b61029861033d366004612606565b6000908152600b60205260409020546001600160a01b031690565b6102b8610366366004612638565b610a17565b610248610379366004612267565b610ae1565b61039161038c3660046126c0565b610b6e565b604080516001600160a01b039093168352602083019190915201610254565b6102b86103be366004612267565b6001600160a01b03166000908152600860205260409020805460ff19169055565b6102486103ed366004612267565b6001600160a01b031660009081526008602052604090205460ff1690565b6102b86104193660046122da565b610c5f565b6102b861042c3660046126c0565b610c7a565b6102b861043f36600461256f565b610d07565b610298610452366004612606565b610d58565b6102b8610465366004612267565b6001600160a01b03166000908152600860205260409020805460ff19166001179055565b610270610d6a565b6102b861049f3660046125a3565b610d79565b6102e86104b2366004612267565b610d83565b6102706104c5366004612606565b610dd1565b6102b86104d836600461265d565b610dee565b6011546001600160a01b0316610298565b610270610e4c565b6102b861050436600461244e565b610e5b565b6102b8610517366004612267565b610ef1565b6102b861052a366004612267565b610f69565b6102b861053d366004612267565b610fe6565b610248610550366004612267565b611024565b6102b861056336600461231b565b61102f565b6102b8610576366004612267565b611063565b6102e861109d565b6010546201000090046001600160a01b0316610298565b6102b86105a8366004612267565b611123565b6102706105bb366004612606565b611200565b6102b86105ce3660046122a1565b611285565b6102b86105e1366004612684565b61130a565b6102b8611363565b6102486105fc3660046122a1565b6113ab565b6102b861060f36600461239a565b6113f3565b610298610622366004612606565b611576565b6102b86106353660046124a8565b611603565b6102e8610648366004612606565b6000908152600c602052604090205490565b60006001600160e01b031982166380ac58cd60e01b148061067f575061067f82611646565b92915050565b60008181526016602052604090208054606091906106a290612968565b80601f01602080910402602001604051908101604052809291908181526020018280546106ce90612968565b801561071b5780601f106106f05761010080835404028352916020019161071b565b820191906000526020600020905b8154815290600101906020018083116106fe57829003601f168201915b50505050509050919050565b60606002805461073690612968565b80601f016020809104026020016040519081016040528092919081815260200182805461076290612968565b80156107af5780601f10610784576101008083540402835291602001916107af565b820191906000526020600020905b81548152906001019060200180831161079257829003601f168201915b5050505050905090565b60006107c48261166b565b6107e1576040516333d1c03960e21b815260040160405180910390fd5b506000908152600660205260409020546001600160a01b031690565b600061080882610d58565b9050806001600160a01b0316836001600160a01b0316141561083d5760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b0382161480159061085d575061085b81336113ab565b155b1561087b576040516367d9dca160e11b815260040160405180910390fd5b610886838383611696565b505050565b610894336116f2565b806108a957506012546001600160a01b031633145b6108ce5760405162461bcd60e51b81526004016108c590612805565b60405180910390fd5b6108ea8483604051806020016040528060008152506001611710565b50505050565b6108f9336116f2565b8061090e57506012546001600160a01b031633145b61092a5760405162461bcd60e51b81526004016108c590612805565b6108868382604051806020016040528060008152506001611710565b60405163989779e960e01b815273ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063989779e9906109809060099085906004016128c3565b60006040518083038186803b15801561099857600080fd5b505af41580156109ac573d6000803e3d6000fd5b5050505050565b61088683838361185a565b6109c7336116f2565b806109dc57506012546001600160a01b031633145b6109f85760405162461bcd60e51b81526004016108c590612805565b6000828152601660209081526040909120825161088692840190612139565b6000828152600b602052604090205482906001600160a01b03163314610a4f5760405162461bcd60e51b81526004016108c590612879565b8215801590610a6657506001600160a01b03821615155b610ab25760405162461bcd60e51b815260206004820152601d60248201527f496e76616c696420746f6b656e206964206f72206e6577206f776e657200000060448201526064016108c5565b506000918252600b602052604090912080546001600160a01b0319166001600160a01b03909216919091179055565b60405163a8a37bd360e01b815260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063a8a37bd390610b1e9060099086906004016128c3565b60206040518083038186803b158015610b3657600080fd5b505af4158015610b4a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067f9190612518565b60008060008311610bcb5760405162461bcd60e51b815260206004820152602160248201527f53616c65207072696365206d7573742062652067726561746572207468616e206044820152600360fc1b60648201526084016108c5565b60008411610c145760405162461bcd60e51b8152602060048201526016602482015275151bdad95b881259081b5d5cdd081899481d985b1a5960521b60448201526064016108c5565b6000848152600b6020908152604080832054600c909252909120546001600160a01b0390911692508390610c4c90620f4240906128f2565b610c569190612906565b90509250929050565b6108868383836040518060200160405280600081525061102f565b6000828152600b602052604090205482906001600160a01b03163314610cb25760405162461bcd60e51b81526004016108c590612879565b82610cf45760405162461bcd60e51b81526020600482015260126024820152714665652063616e6e6f74206265207a65726f60701b60448201526064016108c5565b506000918252600c602052604090912055565b610d10336116f2565b80610d2557506012546001600160a01b031633145b610d415760405162461bcd60e51b81526004016108c590612805565b8051610d54906014906020840190612139565b5050565b6000610d6382611a58565b5192915050565b6060610d74611b71565b905090565b610d548282611b80565b60006001600160a01b038216610dac576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b03166000908152600560205260409020546001600160401b031690565b60008181526015602052604090208054606091906106a290612968565b610df7336116f2565b610e135760405162461bcd60e51b81526004016108c590612805565b6000928352600b6020908152604080852080546001600160a01b0319166001600160a01b039590951694909417909355600c9052912055565b60606003805461073690612968565b6001600160a01b038216331415610e855760405163b06307db60e01b815260040160405180910390fd5b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6012546001600160a01b03163314610f5d5760405162461bcd60e51b815260206004820152602960248201527f6f6e6c79206d6173746572206d696e7465722063616e2061646420646972656360448201526874206d696e7465727360b81b60648201526084016108c5565b610f6681611c03565b50565b6012546001600160a01b031615610fc25760405162461bcd60e51b815260206004820152601d60248201527f6d6173746572206d696e746572206d757374206e6f742062652073657400000060448201526064016108c5565b601280546001600160a01b0319166001600160a01b038316179055610f6681611c03565b336000908152600f602052604090205460ff1615156001148061100857503033145b610f5d5760405162461bcd60e51b81526004016108c590612831565b600061067f826116f2565b61103a84848461185a565b61104684848484611c27565b6108ea576040516368d2bf6b60e11b815260040160405180910390fd5b604051638c9d1e4160e01b815273ae09d7b704281cf10e7bb1776b68fca3d8c94e7c90638c9d1e41906109809060099085906004016128c3565b60405163300f372b60e11b81526009600482015260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063601e6e569060240160206040518083038186803b1580156110eb57600080fd5b505af41580156110ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d74919061261f565b601054610100900460ff1661113e5760105460ff1615611142565b303b155b6111a55760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084016108c5565b601054610100900460ff161580156111c7576010805461ffff19166101011790555b6111d033611c03565b600e80546001600160a01b0319166001600160a01b0384161790558015610d54576010805461ff00191690555050565b606061120b8261166b565b61122857604051630a14c4b560e41b815260040160405180910390fd5b6000611232611b71565b9050805160001415611253576040518060200160405280600081525061127e565b8061125d84611d35565b60405160200161126e92919061270e565b6040516020818303038152906040525b9392505050565b6011546001600160a01b0316156112d05760405162461bcd60e51b815260206004820152600f60248201526e185b1c9958591e4818dc99585d1959608a1b60448201526064016108c5565b6010805462010000600160b01b031916620100006001600160a01b0394851602179055601180546001600160a01b03191691909216179055565b611313336116f2565b8061132857506012546001600160a01b031633145b6113445760405162461bcd60e51b81526004016108c590612805565b6000828152601560209081526040909120825161088692840190612139565b336000908152600f602052604090205460ff1615156001148061138557503033145b6113a15760405162461bcd60e51b81526004016108c590612831565b6113a9611e32565b565b6000806113b88484611e89565b905080806113eb57506001600160a01b0380851660009081526007602090815260408083209387168352929052205460ff165b949350505050565b600e5460408051633e10510b60e01b81526004810191909152600a60448201526926bab63a34aa37b5b2b760b11b606482015260806024820152600d60848201526c4e6574776f726b42726964676560981b60a48201526000916001600160a01b031690633e10510b9060c40160206040518083038186803b15801561147857600080fd5b505afa15801561148c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114b09190612284565b90506001600160a01b0381166115025760405162461bcd60e51b8152602060048201526017602482015276139bc81b995d1ddbdc9ac8189c9a5919d948199bdd5b99604a1b60448201526064016108c5565b604051630781aca560e51b81526001600160a01b0382169063f03594a09061153a908b908b908b908b908b908b908b9060040161278e565b600060405180830381600087803b15801561155457600080fd5b505af1158015611568573d6000803e3d6000fd5b505050505050505050505050565b604051636f911ea160e11b8152600960048201526024810182905260009073ae09d7b704281cf10e7bb1776b68fca3d8c94e7c9063df223d429060440160206040518083038186803b1580156115cb57600080fd5b505af41580156115df573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067f9190612284565b61160c336116f2565b8061162157506012546001600160a01b031633145b61163d5760405162461bcd60e51b81526004016108c590612805565b61088682611f81565b60006001600160e01b0319821663152a902d60e11b148061067f575061067f826120e9565b600080548210801561067f575050600090815260046020526040902054600160e01b900460ff161590565b60008281526006602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b6001600160a01b03166000908152600f602052604090205460ff1690565b6000546001600160a01b03851661173957604051622e076360e81b815260040160405180910390fd5b836117575760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260056020908152604080832080546001600160801b031981166001600160401b038083168c018116918217600160401b6001600160401b031990941690921783900481168c018116909202179091558584526004909252822080546001600160e01b031916909317600160a01b42909216919091021790915581905b858110156118515760405182906001600160a01b03891690600090600080516020612a64833981519152908290a483801561182757506118256000888488611c27565b155b15611845576040516368d2bf6b60e11b815260040160405180910390fd5b600191820191016117e2565b506000556109ac565b600061186582611a58565b80519091506000906001600160a01b0316336001600160a01b031614806118935750815161189390336113ab565b806118ae5750336118a3846107b9565b6001600160a01b0316145b9050806118ce57604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b0316146119035760405162a1148160e81b815260040160405180910390fd5b6001600160a01b03841661192a57604051633a954ecd60e21b815260040160405180910390fd5b61193a6000848460000151611696565b6001600160a01b03858116600090815260056020908152604080832080546001600160401b03198082166001600160401b0392831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600490945282852080546001600160e01b031916909417600160a01b429092169190910217909255908601808352912054909116611a2357600054811015611a2357825160008281526004602090815260409091208054918601516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b5082846001600160a01b0316866001600160a01b0316600080516020612a6483398151915260405160405180910390a46109ac565b6040805160608101825260008082526020820181905291810182905290548290811015611b5857600081815260046020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff16151591810182905290611b565780516001600160a01b031615611aed579392505050565b5060001901600081815260046020908152604091829020825160608101845290546001600160a01b038116808352600160a01b82046001600160401b031693830193909352600160e01b900460ff1615159281019290925215611b51579392505050565b611aed565b505b604051636f96cda160e11b815260040160405180910390fd5b60606014805461073690612968565b60028054611b8d90612968565b159050611bdc5760405162461bcd60e51b815260206004820152601d60248201527f45524337323120746f6b656e206e616d6520616c72656164792073657400000060448201526064016108c5565b8151611bef906002906020850190612139565b508051610886906003906020840190612139565b6001600160a01b03166000908152600f60205260409020805460ff19166001179055565b60006001600160a01b0384163b15611d2a57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611c6b903390899088908890600401612751565b602060405180830381600087803b158015611c8557600080fd5b505af1925050508015611cb5575060408051601f3d908101601f19168201909252611cb291810190612552565b60015b611d10573d808015611ce3576040519150601f19603f3d011682016040523d82523d6000602084013e611ce8565b606091505b508051611d08576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506113eb565b506001949350505050565b606081611d595750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611d835780611d6d816129a3565b9150611d7c9050600a836128f2565b9150611d5d565b6000816001600160401b03811115611d9d57611d9d612a14565b6040519080825280601f01601f191660200182016040528015611dc7576020820181803683370190505b5090505b84156113eb57611ddc600183612925565b9150611de9600a866129be565b611df49060306128da565b60f81b818381518110611e0957611e096129fe565b60200101906001600160f81b031916908160001a905350611e2b600a866128f2565b9450611dcb565b336000908152600f602052604090205460ff16151560011480611e5457503033145b611e705760405162461bcd60e51b81526004016108c590612831565b336000908152600f60205260409020805460ff19169055565b6000805b600a54811015611f7757600060096001018281548110611eaf57611eaf6129fe565b60009182526020909120015460405163c455279160e01b81526001600160a01b039091169150819063c455279190611eeb90889060040161273d565b60206040518083038186803b158015611f0357600080fd5b505afa925050508015611f33575060408051601f3d908101601f19168201909252611f3091810190612284565b60015b611f3c57611f64565b846001600160a01b0316816001600160a01b03161415611f62576001935050505061067f565b505b5080611f6f816129a3565b915050611e8d565b5060009392505050565b6000611f8c82611a58565b9050611f9e6000838360000151611696565b80516001600160a01b03908116600090815260056020908152604080832080546001600160401b031981166001600160401b03918216600019018216179091558551851684528184208054600160801b600160c01b03198116600160801b9182900484166001908101851690920217909155865188865260049094528285208054600160e01b9588166001600160e01b031990911617600160a01b42909416939093029290921760ff60e01b19169390931790559085018083529120549091166120b3576000548110156120b357815160008281526004602090815260409091208054918501516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b50805160405183916000916001600160a01b0390911690600080516020612a64833981519152908390a450506001805481019055565b60006001600160e01b031982166380ac58cd60e01b148061211a57506001600160e01b03198216635b5e139f60e01b145b8061067f57506301ffc9a760e01b6001600160e01b031983161461067f565b82805461214590612968565b90600052602060002090601f01602090048101928261216757600085556121ad565b82601f1061218057805160ff19168380011785556121ad565b828001600101855582156121ad579182015b828111156121ad578251825591602001919060010190612192565b506121b99291506121bd565b5090565b5b808211156121b957600081556001016121be565b60006001600160401b03808411156121ec576121ec612a14565b604051601f8501601f19908116603f0116810190828211818310171561221457612214612a14565b8160405280935085815286868601111561222d57600080fd5b858560208301376000602087830101525050509392505050565b600082601f83011261225857600080fd5b61127e838335602085016121d2565b60006020828403121561227957600080fd5b813561127e81612a2a565b60006020828403121561229657600080fd5b815161127e81612a2a565b600080604083850312156122b457600080fd5b82356122bf81612a2a565b915060208301356122cf81612a2a565b809150509250929050565b6000806000606084860312156122ef57600080fd5b83356122fa81612a2a565b9250602084013561230a81612a2a565b929592945050506040919091013590565b6000806000806080858703121561233157600080fd5b843561233c81612a2a565b9350602085013561234c81612a2a565b92506040850135915060608501356001600160401b0381111561236e57600080fd5b8501601f8101871361237f57600080fd5b61238e878235602084016121d2565b91505092959194509250565b600080600080600080600060c0888a0312156123b557600080fd5b87356123c081612a2a565b965060208801356123d081612a2a565b955060408801359450606088013593506080880135925060a08801356001600160401b038082111561240157600080fd5b818a0191508a601f83011261241557600080fd5b81358181111561242457600080fd5b8b602082850101111561243657600080fd5b60208301945080935050505092959891949750929550565b6000806040838503121561246157600080fd5b823561246c81612a2a565b915060208301356122cf81612a3f565b6000806040838503121561248f57600080fd5b823561249a81612a2a565b946020939093013593505050565b6000806000606084860312156124bd57600080fd5b83356124c881612a2a565b95602085013595506040909401359392505050565b600080600080608085870312156124f357600080fd5b84356124fe81612a2a565b966020860135965060408601359560600135945092505050565b60006020828403121561252a57600080fd5b815161127e81612a3f565b60006020828403121561254757600080fd5b813561127e81612a4d565b60006020828403121561256457600080fd5b815161127e81612a4d565b60006020828403121561258157600080fd5b81356001600160401b0381111561259757600080fd5b6113eb84828501612247565b600080604083850312156125b657600080fd5b82356001600160401b03808211156125cd57600080fd5b6125d986838701612247565b935060208501359150808211156125ef57600080fd5b506125fc85828601612247565b9150509250929050565b60006020828403121561261857600080fd5b5035919050565b60006020828403121561263157600080fd5b5051919050565b6000806040838503121561264b57600080fd5b8235915060208301356122cf81612a2a565b60008060006060848603121561267257600080fd5b83359250602084013561230a81612a2a565b6000806040838503121561269757600080fd5b8235915060208301356001600160401b038111156126b457600080fd5b6125fc85828601612247565b600080604083850312156126d357600080fd5b50508035926020909101359150565b600081518084526126fa81602086016020860161293c565b601f01601f19169290920160200192915050565b6000835161272081846020880161293c565b83519083019061273481836020880161293c565b01949350505050565b6001600160a01b0391909116815260200190565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090612784908301846126e2565b9695505050505050565b6001600160a01b0388811682528716602082015260408101869052606081018590526080810184905260c060a0820181905281018290526000828460e0840137600060e0848401015260e0601f19601f850116830101905098975050505050505050565b60208152600061127e60208301846126e2565b602080825260129082015271596f75207368616c6c206e6f74207061737360701b604082015260600190565b60208082526028908201527f436f6e74726f6c6c61626c653a2063616c6c6572206973206e6f74206120636f604082015267373a3937b63632b960c11b606082015260800190565b6020808252602a908201527f4f6e6c7920746865206f776e65722063616e206d6f646966792074686520726f60408201526979616c7479206665657360b01b606082015260800190565b9182526001600160a01b0316602082015260400190565b600082198211156128ed576128ed6129d2565b500190565b600082612901576129016129e8565b500490565b6000816000190483118215151615612920576129206129d2565b500290565b600082821015612937576129376129d2565b500390565b60005b8381101561295757818101518382015260200161293f565b838111156108ea5750506000910152565b600181811c9082168061297c57607f821691505b6020821081141561299d57634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156129b7576129b76129d2565b5060010190565b6000826129cd576129cd6129e8565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610f6657600080fd5b8015158114610f6657600080fd5b6001600160e01b031981168114610f6657600080fdfeddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa2646970667358221220c22c470116fc73ab21edcba8a93180dcc385ce41b4c4ca32227fa5e3a04527ee64736f6c63430008060033

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.