ETH Price: $3,206.78 (-1.48%)
Gas: 1 Gwei

Token

TrueFreeze NFT positions (TrueFreeze)
 

Overview

Max Total Supply

0 TrueFreeze

Holders

17

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
4 TrueFreeze
0x77C2E72268576c563b4F1B81Ec33B6E801902363
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
NonFungiblePositionManager

Compiler Version
v0.8.12+commit.f00d7308

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license
File 1 of 15 : NonFungiblePositionManager.sol
//SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "ERC721.sol";
import "Ownable.sol";
import "NFTDescriptor.sol";
import "utils.sol";
import "ITrueFreezeGovernor.sol";

/// @title NonFungiblePositionManager contract
/// @author chalex.eth - CharlieDAO
/// @notice Represent position as a NFT

contract NonFungiblePositionManager is ERC721, Ownable {
    address public governorAddress;
    bool private isInitialized;

    /* ------------------ Constructor --------------*/

    constructor() ERC721("TrueFreeze NFT positions", "TrueFreeze") {}

    /* ------------------ Modifier --------------*/
    modifier onlyGovernor() {
        require(msg.sender == governorAddress, "Only Factory can call");
        _;
    }

    /* ----------- External functions --------------*/

    /// @notice set the TrueFreezeGovernor address
    /// @param _governorAddress address of the TrueFreezeGovernor contract
    function setOnlyGovernor(address _governorAddress) external onlyOwner {
        require(isInitialized == false, "Governor already set");
        governorAddress = _governorAddress;
        isInitialized = true;
    }

    /// @notice mint NFT when wAsset are locked in TrueFreezeGovernor
    /// @dev mint is only perform by the TrueFreezeGovernor
    function mint(address _to, uint256 _tokenId) external onlyGovernor {
        _mint(_to, _tokenId);
    }

    /// @notice burn NFT when wAsset are withdrawed early in TrueFreezeGovernor
    /// @dev mint is only perform by the TrueFreezeGovernor
    function burn(uint256 _tokenId) external onlyGovernor {
        _burn(_tokenId);
    }

    /* ----------- View functions --------------*/

    /// @dev return SVG code for rendering the NFT
    function tokenURI(uint256 tokenId)
        public
        view
        override(ERC721)
        returns (string memory)
    {
        require(_exists(tokenId));
        (
            uint256 _amountLocked,
            ,
            uint256 _lockingDate,
            uint256 _maturityDate,

        ) = ITrueFreezeGovernor(governorAddress).getPositions(tokenId);

        return
            NFTDescriptor._constructTokenURI(
                _amountLocked,
                _lockingDate,
                _maturityDate
            );
    }
}

File 2 of 15 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

import "IERC721.sol";
import "IERC721Receiver.sol";
import "IERC721Metadata.sol";
import "Address.sol";
import "Context.sol";
import "Strings.sol";
import "ERC165.sol";

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

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        _approve(to, tokenId);
    }

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

        return _tokenApprovals[tokenId];
    }

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

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

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

        _transfer(from, to, tokenId);
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        _beforeTokenTransfer(from, to, tokenId);

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

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

        emit Transfer(from, to, tokenId);
    }

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

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

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

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

File 3 of 15 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

import "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 4 of 15 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 5 of 15 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

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

File 6 of 15 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 7 of 15 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 8 of 15 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 9 of 15 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 10 of 15 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (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 11 of 15 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.0 (access/Ownable.sol)

pragma solidity ^0.8.0;

import "Context.sol";

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

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

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

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

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

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

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

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

File 12 of 15 : NFTDescriptor.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "base64.sol";
import "utils.sol";

/// @title NFTDescriptor
/// @author chalex.eth - CharlieDAO
/// @notice Library for rendering the NFT by returning a SVG code associated to a locked position in TrueFreezeGovernor

library NFTDescriptor {
    struct paramsTokenURI {
        string n1;
        string n2;
        string n3;
        string y1;
        string m1;
        string d1;
        string y2;
        string m2;
        string d2;
    }

    /// @dev main function for constructing the tokenURI
    function _constructTokenURI(
        uint256 _amountLocked,
        uint256 _lockingDate,
        uint256 _maturityDate
    ) internal pure returns (string memory) {
        paramsTokenURI memory params = _constructParamsTokenURI(
            _amountLocked,
            _lockingDate,
            _maturityDate
        );

        string memory imageURI = Base64.encode(bytes(generateSVG(params)));
        string memory attributes = generateAttributes(
            _amountLocked,
            _lockingDate,
            _maturityDate
        );
        return
            string(
                abi.encodePacked(
                    "data:application/json;base64,",
                    Base64.encode(
                        bytes(
                            abi.encodePacked(
                                '{"name":"',
                                "TrueFreeze NFT",
                                '", "description":"This NFT represent a locked position in TrueFreeze protocol", "image":"',
                                "data:image/svg+xml;base64,",
                                imageURI,
                                '","attributes": ',
                                attributes,
                                "}"
                            )
                        )
                    )
                )
            );
    }

    function _constructParamsTokenURI(
        uint256 _amountLocked,
        uint256 _lockingDate,
        uint256 _maturityDate
    ) internal pure returns (paramsTokenURI memory) {
        (uint256 n1, uint256 n2, uint256 n3) = Utils.getIntAndDigit(
            _amountLocked
        );
        (uint256 y1, uint256 m1, uint256 d1) = Utils.timestampToDate(
            _lockingDate
        );
        (uint256 y2, uint256 m2, uint256 d2) = Utils.timestampToDate(
            _maturityDate
        );

        string memory sm1;
        string memory sm2;
        string memory sd1;
        string memory sd2;
        if (m1 < 10) {
            sm1 = string(abi.encodePacked("0", Utils.uint2str(m1)));
        } else {
            sm1 = Utils.uint2str(m1);
        }

        if (m2 < 10) {
            sm2 = string(abi.encodePacked("0", Utils.uint2str(m2)));
        } else {
            sm2 = Utils.uint2str(m2);
        }

        if (d1 < 10) {
            sd1 = string(abi.encodePacked("0", Utils.uint2str(d1)));
        } else {
            sd1 = Utils.uint2str(d1);
        }

        if (d2 < 10) {
            sd2 = string(abi.encodePacked("0", Utils.uint2str(d2)));
        } else {
            sd2 = Utils.uint2str(d2);
        }

        return
            paramsTokenURI({
                n1: Utils.uint2str(n1),
                n2: Utils.uint2str(n2),
                n3: Utils.uint2str(n3),
                y1: Utils.uint2str(y1),
                m1: sm1,
                d1: sd1,
                y2: Utils.uint2str(y2),
                m2: sm2,
                d2: sd2
            });
    }

    function generateAttributes(
        uint256 _amountLocked,
        uint256 _lockingDate,
        uint256 _maturityDate
    ) internal pure returns (string memory attributes) {
        (uint256 n1, uint256 n2, uint256 n3) = Utils.getIntAndDigit(
            _amountLocked
        );
        return
            string(
                abi.encodePacked(
                    '[{"trait_type": "Amount locked", "value":',
                    Utils.uint2str(n1),
                    ".",
                    Utils.uint2str(n2),
                    Utils.uint2str(n3),
                    '},{"display_type": "date", "trait_type": "Locking date", "value":',
                    Utils.uint2str(_lockingDate),
                    '},{"display_type": "date", "trait_type": "Maturity date", "value":',
                    Utils.uint2str(_maturityDate),
                    "}]"
                )
            );
    }

    function generateSVG(paramsTokenURI memory _params)
        internal
        pure
        returns (string memory svg)
    {
        return
            string(
                abi.encodePacked(
                    '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 400 500">',
                    generateStyle(),
                    generateLinearGradient(),
                    generateAmountLocked(_params),
                    generateMiddle(),
                    generateMaturity(_params),
                    generateLocking(_params),
                    generateBottom()
                )
            );
    }

    function generateStyle() internal pure returns (string memory svg) {
        return
            string(
                abi.encodePacked(
                    "<style>    @import url(&apos;https://fonts.googleapis.com/css2?family=Montserrat&apos;);",
                    ".background {      fill: url(&quot;#linear-gradient&quot;);    }",
                    ".snowflake-logo {      fill: #fff;    }    .logo-text {      fill: #fff;",
                    "font-family: Montserrat, sans-serif;      font-size: 25px;    }",
                    ".amount-text {    fill: #d8b98d;    font-family: Montserrat, sans-serif;    font-size: 55px;    }",
                    ".date-text {    fill: #d8b98d;    font-family: Montserrat, sans-serif;    font-size: 30px;    }",
                    ".date-label {    fill: #8dbdd8;    font-family: Montserrat, sans-serif;    font-size: 20px;    }",
                    ".gradient-box {      fill: none;      stroke-miterlimit: 10;      stroke-width: 3px;",
                    "stroke: url(&quot;#linear-gradient&quot;);    }",
                    ".gradient-border {    fill: none;    stroke-miterlimit: 10;    stroke-width: 1px;    stroke: #bdbec5;    }  </style>"
                )
            );
    }

    function generateLinearGradient()
        internal
        pure
        returns (string memory svg)
    {
        return
            string(
                abi.encodePacked(
                    '<linearGradient id="linear-gradient" x1="0" y1="500" x2="250" y2="100" gradientUnits="userSpaceOnUse">',
                    '<stop offset="0" stop-color="#bdbec5"/>    <stop offset="0.5" stop-color="#547181"/>',
                    '<stop offset="1" stop-color="#4b4c4e"/>  </linearGradient>',
                    '<rect class="background" width="400" height="500" rx="20"/><g transform="translate(0,50)">',
                    '<g>      <linearGradient y1="50" x2="350" y2="50" gradientUnits="userSpaceOnUse">',
                    '<stop offset="0" stop-color="#bdbec5"/>        <stop offset="1" stop-color="#4b4c4e"/>      </linearGradient>'
                )
            );
    }

    function generateAmountLocked(paramsTokenURI memory _params)
        internal
        pure
        returns (string memory svg)
    {
        return
            string(
                abi.encodePacked(
                    '<rect class="gradient-border" x="50" y="10" width="300" height="100" rx="20" transform="translate(0,0)"/>',
                    '<text text-anchor="end" class="amount-text" x="345" y="70">',
                    _params.n1,
                    ".",
                    _params.n2,
                    _params.n3,
                    "</text>",
                    '<text text-anchor="middle" class="date-label" x="200" y="100">',
                    "WETH</text>    </g>"
                )
            );
    }

    function generateMiddle() internal pure returns (string memory svg) {
        return
            string(
                abi.encodePacked(
                    '<g><linearGradient y1="50" x2="350" y2="50" gradientUnits="userSpaceOnUse">',
                    '<stop offset="0" stop-color="#bdbec5"/><stop offset="1" stop-color="#4b4c4e"/></linearGradient>',
                    '<rect class="gradient-border" x="75" y="120" width="250" height="90" rx="20" transform="translate(0,0)"/>'
                )
            );
    }

    function generateMaturity(paramsTokenURI memory _params)
        internal
        pure
        returns (string memory svg)
    {
        return
            string(
                abi.encodePacked(
                    '<text text-anchor="middle" class="date-text" x="200" y="165">',
                    _params.y2,
                    "-",
                    _params.m2,
                    "-",
                    _params.d2,
                    '</text>      <text text-anchor="middle" class="date-label" x="200" y="200">',
                    "Maturity Date</text>"
                )
            );
    }

    function generateLocking(paramsTokenURI memory _params)
        internal
        pure
        returns (string memory svg)
    {
        return
            string(
                abi.encodePacked(
                    '<rect class="gradient-border" x="75" y="220" width="250" height="90" rx="20" transform="translate(0,0)"/>',
                    '<text text-anchor="middle" class="date-text" x="200" y="265">',
                    _params.y1,
                    "-",
                    _params.m1,
                    "-",
                    _params.d1,
                    '</text>      <text text-anchor="middle" class="date-label" x="200" y="300">',
                    "Lock Date </text>    </g>  </g>"
                )
            );
    }

    function generateBottom() internal pure returns (string memory svg) {
        return
            string(
                abi.encodePacked(
                    '<g transform="translate(10,420)">',
                    '<path class="snowflake-logo" d="M19.41,5.77l-3.47,4.89L12.46,5.77,15.94,0ZM7.54,7.53l1.2,4.88,',
                    "4.41.74-.74-4.41ZM0,15.93l5.77,3.48,4.89-3.48L5.77,12.45Zm7.53,8.4,      4.88-1.2.74-4.42-4.41.75Zm8.4,7.54,3.48-5.77-3.48-4.89L12.45,",
                    '26.1Zm8.4-7.53-1.2-4.88-4.42-.74.75,4.41Zm7.54-8.4L26.1,      12.46l-4.89,3.48,4.89,3.47Zm-7.53-8.4-4.88,1.2-.74,4.41,4.41-.74Z"/>',
                    '<text class="logo-text" x="40" y="25"> TRUE FREEZE        </text>  </g></svg>'
                )
            );
    }
}

File 13 of 15 : base64.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0;

/// @title Base64
/// @author Brecht Devos - <[email protected]>
/// @notice Provides functions for encoding/decoding base64
library Base64 {
    string internal constant TABLE_ENCODE =
        "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
    bytes internal constant TABLE_DECODE =
        hex"0000000000000000000000000000000000000000000000000000000000000000"
        hex"00000000000000000000003e0000003f3435363738393a3b3c3d000000000000"
        hex"00000102030405060708090a0b0c0d0e0f101112131415161718190000000000"
        hex"001a1b1c1d1e1f202122232425262728292a2b2c2d2e2f303132330000000000";

    function encode(bytes memory data) internal pure returns (string memory) {
        if (data.length == 0) return "";

        // load the table into memory
        string memory table = TABLE_ENCODE;

        // multiply by 4/3 rounded up
        uint256 encodedLen = 4 * ((data.length + 2) / 3);

        // add some extra buffer at the end required for the writing
        string memory result = new string(encodedLen + 32);

        assembly {
            // set the actual output length
            mstore(result, encodedLen)

            // prepare the lookup table
            let tablePtr := add(table, 1)

            // input ptr
            let dataPtr := data
            let endPtr := add(dataPtr, mload(data))

            // result ptr, jump over length
            let resultPtr := add(result, 32)

            // run over the input, 3 bytes at a time
            for {

            } lt(dataPtr, endPtr) {

            } {
                // read 3 bytes
                dataPtr := add(dataPtr, 3)
                let input := mload(dataPtr)

                // write 4 characters
                mstore8(
                    resultPtr,
                    mload(add(tablePtr, and(shr(18, input), 0x3F)))
                )
                resultPtr := add(resultPtr, 1)
                mstore8(
                    resultPtr,
                    mload(add(tablePtr, and(shr(12, input), 0x3F)))
                )
                resultPtr := add(resultPtr, 1)
                mstore8(
                    resultPtr,
                    mload(add(tablePtr, and(shr(6, input), 0x3F)))
                )
                resultPtr := add(resultPtr, 1)
                mstore8(resultPtr, mload(add(tablePtr, and(input, 0x3F))))
                resultPtr := add(resultPtr, 1)
            }

            // padding with '='
            switch mod(mload(data), 3)
            case 1 {
                mstore(sub(resultPtr, 2), shl(240, 0x3d3d))
            }
            case 2 {
                mstore(sub(resultPtr, 1), shl(248, 0x3d))
            }
        }

        return result;
    }

    function decode(string memory _data) internal pure returns (bytes memory) {
        bytes memory data = bytes(_data);

        if (data.length == 0) return new bytes(0);
        require(data.length % 4 == 0, "invalid base64 decoder input");

        // load the table into memory
        bytes memory table = TABLE_DECODE;

        // every 4 characters represent 3 bytes
        uint256 decodedLen = (data.length / 4) * 3;

        // add some extra buffer at the end required for the writing
        bytes memory result = new bytes(decodedLen + 32);

        assembly {
            // padding with '='
            let lastBytes := mload(add(data, mload(data)))
            if eq(and(lastBytes, 0xFF), 0x3d) {
                decodedLen := sub(decodedLen, 1)
                if eq(and(lastBytes, 0xFFFF), 0x3d3d) {
                    decodedLen := sub(decodedLen, 1)
                }
            }

            // set the actual output length
            mstore(result, decodedLen)

            // prepare the lookup table
            let tablePtr := add(table, 1)

            // input ptr
            let dataPtr := data
            let endPtr := add(dataPtr, mload(data))

            // result ptr, jump over length
            let resultPtr := add(result, 32)

            // run over the input, 4 characters at a time
            for {

            } lt(dataPtr, endPtr) {

            } {
                // read 4 characters
                dataPtr := add(dataPtr, 4)
                let input := mload(dataPtr)

                // write 3 bytes
                let output := add(
                    add(
                        shl(
                            18,
                            and(
                                mload(add(tablePtr, and(shr(24, input), 0xFF))),
                                0xFF
                            )
                        ),
                        shl(
                            12,
                            and(
                                mload(add(tablePtr, and(shr(16, input), 0xFF))),
                                0xFF
                            )
                        )
                    ),
                    add(
                        shl(
                            6,
                            and(
                                mload(add(tablePtr, and(shr(8, input), 0xFF))),
                                0xFF
                            )
                        ),
                        and(mload(add(tablePtr, and(input, 0xFF))), 0xFF)
                    )
                )
                mstore(resultPtr, shl(232, output))
                resultPtr := add(resultPtr, 3)
            }
        }

        return result;
    }
}

File 14 of 15 : utils.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

library Utils {
    function getIntAndDigit(uint256 _number)
        internal
        pure
        returns (
            uint256,
            uint256,
            uint256
        )
    {
        uint256 n1 = _number / (10**18);
        uint256 n2 = (_number - n1 * 10**18) / (10**17);
        uint256 n3 = (_number - n1 * 10**18 - n2 * 10**17) / (10**16);
        return (n1, n2, n3);
    }

    function _daysToDate(uint256 _days)
        private
        pure
        returns (
            uint256 year,
            uint256 month,
            uint256 day
        )
    {
        int256 __days = int256(_days);

        int256 L = __days + 68569 + 2440588;
        int256 N = (4 * L) / 146097;
        L = L - (146097 * N + 3) / 4;
        int256 _year = (4000 * (L + 1)) / 1461001;
        L = L - (1461 * _year) / 4 + 31;
        int256 _month = (80 * L) / 2447;
        int256 _day = L - (2447 * _month) / 80;
        L = _month / 11;
        _month = _month + 2 - 12 * L;
        _year = 100 * (N - 49) + _year + L;

        year = uint256(_year);
        month = uint256(_month);
        day = uint256(_day);
    }

    function timestampToDate(uint256 timestamp)
        internal
        pure
        returns (
            uint256,
            uint256,
            uint256
        )
    {
        (uint256 year, uint256 month, uint256 day) = _daysToDate(
            timestamp / 86400
        );
        return (year, month, day);
    }

    function uint2str(uint256 _i) internal pure returns (string memory) {
        if (_i == 0) {
            return "0";
        }
        uint256 j = _i;
        uint256 len;
        while (j != 0) {
            len++;
            j /= 10;
        }
        bytes memory bstr = new bytes(len);
        uint256 k = len;
        while (_i != 0) {
            k = k - 1;
            uint8 temp = (48 + uint8(_i - (_i / 10) * 10));
            bytes1 b1 = bytes1(temp);
            bstr[k] = b1;
            _i /= 10;
        }
        return string(bstr);
    }
}

File 15 of 15 : ITrueFreezeGovernor.sol
//SPDX-License-Identifier: GPL-3.0
pragma solidity ^0.8.0;

interface ITrueFreezeGovernor {
    function getPositions(uint256)
        external
        view
        returns (
            uint256,
            uint256,
            uint256,
            uint256,
            bool
        );

    function getTokenSymbol() external view returns (string memory);
}

Settings
{
  "evmVersion": "istanbul",
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "libraries": {
    "NonFungiblePositionManager.sol": {}
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"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":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","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"},{"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":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"burn","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":[],"name":"governorAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_governorAddress","type":"address"}],"name":"setOnlyGovernor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040523480156200001157600080fd5b50604080518082018252601881527f54727565467265657a65204e465420706f736974696f6e73000000000000000060208083019182528351808501909452600a84526954727565467265657a6560b01b908401528151919291620000799160009162000108565b5080516200008f90600190602084019062000108565b505050620000ac620000a6620000b260201b60201c565b620000b6565b620001eb565b3390565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200011690620001ae565b90600052602060002090601f0160209004810192826200013a576000855562000185565b82601f106200015557805160ff191683800117855562000185565b8280016001018555821562000185579182015b828111156200018557825182559160200191906001019062000168565b506200019392915062000197565b5090565b5b8082111562000193576000815560010162000198565b600181811c90821680620001c357607f821691505b60208210811415620001e557634e487b7160e01b600052602260045260246000fd5b50919050565b61349580620001fb6000396000f3fe608060405234801561001057600080fd5b506004361061012c5760003560e01c80636352211e116100ad578063a22cb46511610071578063a22cb46514610275578063b88d4fde14610288578063c87b56dd1461029b578063e985e9c5146102ae578063f2fde38b146102ea57600080fd5b80636352211e1461022057806370a0823114610233578063715018a6146102545780638da5cb5b1461025c57806395d89b411461026d57600080fd5b806323b872dd116100f457806323b872dd146101c1578063276f1c41146101d457806340c10f19146101e757806342842e0e146101fa57806342966c681461020d57600080fd5b806301ffc9a71461013157806306fdde0314610159578063081812fc1461016e578063095ea7b31461019957806319394588146101ae575b600080fd5b61014461013f366004611baa565b6102fd565b60405190151581526020015b60405180910390f35b61016161034f565b6040516101509190611c26565b61018161017c366004611c39565b6103e1565b6040516001600160a01b039091168152602001610150565b6101ac6101a7366004611c6e565b61047b565b005b6101ac6101bc366004611c98565b610591565b6101ac6101cf366004611cb3565b610633565b600754610181906001600160a01b031681565b6101ac6101f5366004611c6e565b610664565b6101ac610208366004611cb3565b6106c4565b6101ac61021b366004611c39565b6106df565b61018161022e366004611c39565b61073d565b610246610241366004611c98565b6107b4565b604051908152602001610150565b6101ac61083b565b6006546001600160a01b0316610181565b610161610871565b6101ac610283366004611cfd565b610880565b6101ac610296366004611d4a565b61088b565b6101616102a9366004611c39565b6108c3565b6101446102bc366004611e26565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b6101ac6102f8366004611c98565b610975565b60006001600160e01b031982166380ac58cd60e01b148061032e57506001600160e01b03198216635b5e139f60e01b145b8061034957506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461035e90611e59565b80601f016020809104026020016040519081016040528092919081815260200182805461038a90611e59565b80156103d75780601f106103ac576101008083540402835291602001916103d7565b820191906000526020600020905b8154815290600101906020018083116103ba57829003601f168201915b5050505050905090565b6000818152600260205260408120546001600160a01b031661045f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b60006104868261073d565b9050806001600160a01b0316836001600160a01b031614156104f45760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610456565b336001600160a01b0382161480610510575061051081336102bc565b6105825760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610456565b61058c8383610a0d565b505050565b6006546001600160a01b031633146105bb5760405162461bcd60e51b815260040161045690611e94565b600754600160a01b900460ff161561060c5760405162461bcd60e51b815260206004820152601460248201527311dbdd995c9b9bdc88185b1c9958591e481cd95d60621b6044820152606401610456565b600780546001600160a81b0319166001600160a01b0390921691909117600160a01b179055565b61063d3382610a7b565b6106595760405162461bcd60e51b815260040161045690611ec9565b61058c838383610b72565b6007546001600160a01b031633146106b65760405162461bcd60e51b815260206004820152601560248201527413db9b1e48119858dd1bdc9e4818d85b8818d85b1b605a1b6044820152606401610456565b6106c08282610d12565b5050565b61058c8383836040518060200160405280600081525061088b565b6007546001600160a01b031633146107315760405162461bcd60e51b815260206004820152601560248201527413db9b1e48119858dd1bdc9e4818d85b8818d85b1b605a1b6044820152606401610456565b61073a81610e54565b50565b6000818152600260205260408120546001600160a01b0316806103495760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610456565b60006001600160a01b03821661081f5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610456565b506001600160a01b031660009081526003602052604090205490565b6006546001600160a01b031633146108655760405162461bcd60e51b815260040161045690611e94565b61086f6000610eef565b565b60606001805461035e90611e59565b6106c0338383610f41565b6108953383610a7b565b6108b15760405162461bcd60e51b815260040161045690611ec9565b6108bd84848484611010565b50505050565b6000818152600260205260409020546060906001600160a01b03166108e757600080fd5b60075460405163187002cb60e11b815260048101849052600091829182916001600160a01b0316906330e005969060240160a060405180830381865afa158015610935573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109599190611f1a565b509350935050925061096c838383611043565b95945050505050565b6006546001600160a01b0316331461099f5760405162461bcd60e51b815260040161045690611e94565b6001600160a01b038116610a045760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610456565b61073a81610eef565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610a428261073d565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b0316610af45760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610456565b6000610aff8361073d565b9050806001600160a01b0316846001600160a01b03161480610b3a5750836001600160a01b0316610b2f846103e1565b6001600160a01b0316145b80610b6a57506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b0316610b858261073d565b6001600160a01b031614610bed5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610456565b6001600160a01b038216610c4f5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610456565b610c5a600082610a0d565b6001600160a01b0383166000908152600360205260408120805460019290610c83908490611f7d565b90915550506001600160a01b0382166000908152600360205260408120805460019290610cb1908490611f94565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6001600160a01b038216610d685760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610456565b6000818152600260205260409020546001600160a01b031615610dcd5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610456565b6001600160a01b0382166000908152600360205260408120805460019290610df6908490611f94565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6000610e5f8261073d565b9050610e6c600083610a0d565b6001600160a01b0381166000908152600360205260408120805460019290610e95908490611f7d565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b03161415610fa35760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610456565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61101b848484610b72565b611027848484846110cd565b6108bd5760405162461bcd60e51b815260040161045690611fac565b606060006110528585856111cb565b90506000611067611062836113e8565b611451565b905060006110768787876115b7565b90506110a2828260405160200161108e92919061201a565b604051602081830303815290604052611451565b6040516020016110b29190612138565b60405160208183030381529060405293505050509392505050565b60006001600160a01b0384163b156111c057604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061111190339089908890889060040161217d565b6020604051808303816000875af192505050801561114c575060408051601f3d908101601f19168201909252611149918101906121ba565b60015b6111a6573d80801561117a576040519150601f19603f3d011682016040523d82523d6000602084013e61117f565b606091505b50805161119e5760405162461bcd60e51b815260040161045690611fac565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610b6a565b506001949350505050565b61121a6040518061012001604052806060815260200160608152602001606081526020016060815260200160608152602001606081526020016060815260200160608152602001606081525090565b60008060006112288761160e565b925092509250600080600061123c896116b4565b92509250925060008060006112508b6116b4565b925092509250606080606080600a8910156112945761126e896116e0565b60405160200161127e91906121d7565b60405160208183030381529060405293506112a0565b61129d896116e0565b93505b600a8610156112d8576112b2866116e0565b6040516020016112c291906121d7565b60405160208183030381529060405292506112e4565b6112e1866116e0565b92505b600a88101561131c576112f6886116e0565b60405160200161130691906121d7565b6040516020818303038152906040529150611328565b611325886116e0565b91505b600a8510156113605761133a856116e0565b60405160200161134a91906121d7565b604051602081830303815290604052905061136c565b611369856116e0565b90505b6040518061012001604052806113818f6116e0565b815260200161138f8e6116e0565b815260200161139d8d6116e0565b81526020016113ab8c6116e0565b81526020018581526020018381526020016113c5896116e0565b81526020810194909452604090930152509e9d5050505050505050505050505050565b60606113f2611809565b6113fa61182e565b6114038461183f565b61140b611862565b611414866119c9565b61141d876119ed565b611425611a10565b60405160200161143b9796959493929190612200565b6040516020818303038152906040529050919050565b606081516000141561147157505060408051602081019091526000815290565b600060405180606001604052806040815260200161342060409139905060006003845160026114a09190611f94565b6114aa9190612336565b6114b590600461234a565b905060006114c4826020611f94565b67ffffffffffffffff8111156114dc576114dc611d34565b6040519080825280601f01601f191660200182016040528015611506576020820181803683370190505b509050818152600183018586518101602084015b81831015611572576003830192508251603f8160121c168501518253600182019150603f81600c1c168501518253600182019150603f8160061c168501518253600182019150603f811685015182535060010161151a565b60038951066001811461158c576002811461159d576115a9565b613d3d60f01b6001198301526115a9565b603d60f81b6000198301525b509398975050505050505050565b606060008060006115c78761160e565b9250925092506115d6836116e0565b6115df836116e0565b6115e8836116e0565b6115f1896116e0565b6115fa896116e0565b6040516020016110b2959493929190612369565b6000808080611625670de0b6b3a764000086612336565b9050600067016345785d8a000061164483670de0b6b3a764000061234a565b61164e9088611f7d565b6116589190612336565b90506000662386f26fc100006116768367016345785d8a000061234a565b61168885670de0b6b3a764000061234a565b611692908a611f7d565b61169c9190611f7d565b6116a69190612336565b929791965091945092505050565b600080808080806116d06116cb6201518089612336565b611a21565b9199909850909650945050505050565b6060816117045750506040805180820190915260018152600360fc1b602082015290565b8160005b811561172e5780611718816124e2565b91506117279050600a83612336565b9150611708565b60008167ffffffffffffffff81111561174957611749611d34565b6040519080825280601f01601f191660200182016040528015611773576020820181803683370190505b509050815b851561180057611789600182611f7d565b90506000611798600a88612336565b6117a390600a61234a565b6117ad9088611f7d565b6117b89060306124fd565b905060008160f81b9050808484815181106117d5576117d5612522565b60200101906001600160f81b031916908160001a9053506117f7600a89612336565b97505050611778565b50949350505050565b606060405160200161181a90612538565b604051602081830303815290604052905090565b606060405160200161181a90612952565b606081600001518260200151836040015160405160200161143b93929190612bf7565b606060405160200161181a907f3c673e3c6c696e6561724772616469656e742079313d223530222078323d223381527f3530222079323d22353022206772616469656e74556e6974733d22757365725360208201526a3830b1b2a7b72ab9b2911f60a91b60408201527f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d22236264604b8201527f62656335222f3e3c73746f70206f66667365743d2231222073746f702d636f6c606b8201527f6f723d2223346234633465222f3e3c2f6c696e6561724772616469656e743e00608b8201527f3c7265637420636c6173733d226772616469656e742d626f726465722220783d60aa8201527f2237352220793d22313230222077696474683d2232353022206865696768743d60ca8201527f223930222072783d22323022207472616e73666f726d3d227472616e736c617460ea8201526832941816181491179f60b91b61010a8201526101130190565b60608160c001518260e0015183610100015160405160200161143b93929190612dab565b6060816060015182608001518360a0015160405160200161143b93929190612ed5565b606060405160200161181a9061308d565b600080808381611a348262010bd96132ec565b611a419062253d8c6132ec565b9050600062023ab1611a5483600461332d565b611a5e91906133b2565b90506004611a6f8262023ab161332d565b611a7a9060036132ec565b611a8491906133b2565b611a8e90836133e0565b9150600062164b09611aa18460016132ec565b611aad90610fa061332d565b611ab791906133b2565b90506004611ac7826105b561332d565b611ad191906133b2565b611adb90846133e0565b611ae690601f6132ec565b9250600061098f611af885605061332d565b611b0291906133b2565b905060006050611b148361098f61332d565b611b1e91906133b2565b611b2890866133e0565b9050611b35600b836133b2565b9450611b4285600c61332d565b611b4d8360026132ec565b611b5791906133e0565b91508483611b666031876133e0565b611b7190606461332d565b611b7b91906132ec565b611b8591906132ec565b9a919950975095505050505050565b6001600160e01b03198116811461073a57600080fd5b600060208284031215611bbc57600080fd5b8135611bc781611b94565b9392505050565b60005b83811015611be9578181015183820152602001611bd1565b838111156108bd5750506000910152565b60008151808452611c12816020860160208601611bce565b601f01601f19169290920160200192915050565b602081526000611bc76020830184611bfa565b600060208284031215611c4b57600080fd5b5035919050565b80356001600160a01b0381168114611c6957600080fd5b919050565b60008060408385031215611c8157600080fd5b611c8a83611c52565b946020939093013593505050565b600060208284031215611caa57600080fd5b611bc782611c52565b600080600060608486031215611cc857600080fd5b611cd184611c52565b9250611cdf60208501611c52565b9150604084013590509250925092565b801515811461073a57600080fd5b60008060408385031215611d1057600080fd5b611d1983611c52565b91506020830135611d2981611cef565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611d6057600080fd5b611d6985611c52565b9350611d7760208601611c52565b925060408501359150606085013567ffffffffffffffff80821115611d9b57600080fd5b818701915087601f830112611daf57600080fd5b813581811115611dc157611dc1611d34565b604051601f8201601f19908116603f01168101908382118183101715611de957611de9611d34565b816040528281528a6020848701011115611e0257600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611e3957600080fd5b611e4283611c52565b9150611e5060208401611c52565b90509250929050565b600181811c90821680611e6d57607f821691505b60208210811415611e8e57634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600080600080600060a08688031215611f3257600080fd5b855194506020860151935060408601519250606086015191506080860151611f5981611cef565b809150509295509295909350565b634e487b7160e01b600052601160045260246000fd5b600082821015611f8f57611f8f611f67565b500390565b60008219821115611fa757611fa7611f67565b500190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60008151612010818560208601611bce565b9290920192915050565b683d913730b6b2911d1160b91b81526d151c9d59519c99595e994813919560921b60098201527f222c20226465736372697074696f6e223a2254686973204e465420726570726560178201527f73656e742061206c6f636b656420706f736974696f6e20696e2054727565467260378201527f65657a652070726f746f636f6c222c2022696d616765223a220000000000000060578201527f646174613a696d6167652f7376672b786d6c3b6261736536342c000000000000607082015282516000906120ee81608a850160208801611bce565b6f011161130ba3a3934b13aba32b9911d160851b608a91840191820152835161211e81609a840160208801611bce565b607d60f81b609a9290910191820152609b01949350505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c00000081526000825161217081601d850160208701611bce565b91909101601d0192915050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906121b090830184611bfa565b9695505050505050565b6000602082840312156121cc57600080fd5b8151611bc781611b94565b600360fc1b8152600082516121f3816001850160208701611bce565b9190910160010192915050565b7f3c73766720786d6c6e733d22687474703a2f2f7777772e77332e6f72672f32308152600060207f30302f7376672220786d6c6e733a786c696e6b3d22687474703a2f2f7777772e818401527f77332e6f72672f313939392f786c696e6b222076696577426f783d22302030206040840152681a1818101a9818111f60b91b606084015260698a5161229781838701858f01611bce565b8a51908501906122ac81848401868f01611bce565b8a519101906122c081848401868e01611bce565b89519101906122d481848401868d01611bce565b88519101906122e881848401868c01611bce565b87519101906122fc81848401868b01611bce565b865191019061231081848401868a01611bce565b01019a9950505050505050505050565b634e487b7160e01b600052601260045260246000fd5b60008261234557612345612320565b500490565b600081600019048311821515161561236457612364611f67565b500290565b7f5b7b2274726169745f74797065223a2022416d6f756e74206c6f636b6564222c81526810113b30b63ab2911d60b91b6020820152600086516123b3816029850160208b01611bce565b601760f91b60299184019182015286516123d481602a840160208b01611bce565b86519101906123ea81602a840160208a01611bce565b7f7d2c7b22646973706c61795f74797065223a202264617465222c202274726169602a92909101918201527f745f74797065223a20224c6f636b696e672064617465222c202276616c756522604a820152601d60f91b606a820152845161245881606b840160208901611bce565b6124d56124c76124c1606b848601017f7d2c7b22646973706c61795f74797065223a202264617465222c20227472616981527f745f74797065223a20224d617475726974792064617465222c202276616c7565602082015261111d60f11b604082015260420190565b87611ffe565b617d5d60f01b815260020190565b9998505050505050505050565b60006000198214156124f6576124f6611f67565b5060010190565b600060ff821660ff84168060ff0382111561251a5761251a611f67565b019392505050565b634e487b7160e01b600052603260045260246000fd5b7f3c7374796c653e2020202040696d706f72742075726c282661706f733b68747481527f70733a2f2f666f6e74732e676f6f676c65617069732e636f6d2f637373323f6660208201527f616d696c793d4d6f6e747365727261742661706f733b293b000000000000000060408201527f2e6261636b67726f756e64207b20202020202066696c6c3a2075726c2826717560588201527f6f743b236c696e6561722d6772616469656e742671756f743b293b202020207d60788201527f2e736e6f77666c616b652d6c6f676f207b20202020202066696c6c3a2023666660988201527f663b202020207d202020202e6c6f676f2d74657874207b20202020202066696c60b8820152676c3a20236666663b60c01b60d88201527f666f6e742d66616d696c793a204d6f6e747365727261742c2073616e732d736560e08201527f7269663b202020202020666f6e742d73697a653a20323570783b202020207d006101008201527f2e616d6f756e742d74657874207b2020202066696c6c3a20236438623938643b61011f8201527f20202020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e61013f8201527f732d73657269663b20202020666f6e742d73697a653a20353570783b2020202061015f820152607d60f81b61017f8201527f2e646174652d74657874207b2020202066696c6c3a20236438623938643b20206101808201527f2020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e732d6101a08201527f73657269663b20202020666f6e742d73697a653a20333070783b202020207d006101c08201527f2e646174652d6c6162656c207b2020202066696c6c3a20233864626464383b206101df8201527f202020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e736101ff8201527f2d73657269663b20202020666f6e742d73697a653a20323070783b202020207d61021f8201527f2e6772616469656e742d626f78207b20202020202066696c6c3a206e6f6e653b61023f8201527f2020202020207374726f6b652d6d697465726c696d69743a2031303b2020202061025f8201527320207374726f6b652d77696474683a203370783b60601b61027f8201527f7374726f6b653a2075726c282671756f743b236c696e6561722d6772616469656102938201526e6e742671756f743b293b202020207d60881b6102b38201527f2e6772616469656e742d626f72646572207b2020202066696c6c3a206e6f6e656102c28201527f3b202020207374726f6b652d6d697465726c696d69743a2031303b20202020736102e28201527f74726f6b652d77696474683a203170783b202020207374726f6b653a20236264610302820152733132b19a9d901010103e90101e17b9ba3cb6329f60611b61032282015260006103368201610349565b7f3c6c696e6561724772616469656e742069643d226c696e6561722d677261646981527f656e74222078313d2230222079313d22353030222078323d223235302220793260208201527f3d2231303022206772616469656e74556e6974733d227573657253706163654f604082015265372ab9b2911f60d11b60608201527f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d2223626460668201527f62656335222f3e202020203c73746f70206f66667365743d22302e352220737460868201527337b816b1b7b637b91e91119a9a1b989c1891179f60611b60a68201527f3c73746f70206f66667365743d2231222073746f702d636f6c6f723d2223346260ba8201527f34633465222f3e20203c2f6c696e6561724772616469656e743e00000000000060da8201527f3c7265637420636c6173733d226261636b67726f756e64222077696474683d2260f48201527f34303022206865696768743d22353030222072783d223230222f3e3c672074726101148201527f616e73666f726d3d227472616e736c61746528302c353029223e0000000000006101348201527f3c673e2020202020203c6c696e6561724772616469656e742079313d2235302261014e8201527f2078323d22333530222079323d22353022206772616469656e74556e6974733d61016e82015270113ab9b2b929b830b1b2a7b72ab9b2911f60791b61018e820152600061034961019f83017f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d2223626481527f62656335222f3e20202020202020203c73746f70206f66667365743d2231222060208201527f73746f702d636f6c6f723d2223346234633465222f3e2020202020203c2f6c6960408201526c3732b0b923b930b234b2b73a1f60991b6060820152606d0190565b7f3c7265637420636c6173733d226772616469656e742d626f726465722220783d81527f2235302220793d223130222077696474683d2233303022206865696768743d2260208201527f313030222072783d22323022207472616e73666f726d3d227472616e736c617460408201526832941816181491179f60b91b60608201527f3c7465787420746578742d616e63686f723d22656e642220636c6173733d226160698201527f6d6f756e742d746578742220783d223334352220793d223730223e0000000000608982015260008451612cd98160a4850160208901611bce565b601760f91b60a4918401918201528451612cfa8160a5840160208901611bce565b8451910190612d108160a5840160208801611bce565b612da0612d81612d3260a584860101661e17ba32bc3a1f60c91b815260070190565b7f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737381527f3d22646174652d6c6162656c2220783d223230302220793d22313030223e00006020820152603e0190565b722ba2aa241e17ba32bc3a1f101010101e17b39f60691b815260130190565b979650505050505050565b7f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737381527f3d22646174652d746578742220783d223230302220793d22313635223e000000602082015260008451612e0981603d850160208901611bce565b8083019050602d60f81b80603d8301528551612e2c81603e850160208a01611bce565b603e9201918201528351612e4781603f840160208801611bce565b7f3c2f746578743e2020202020203c7465787420746578742d616e63686f723d22603f92909101918201527f6d6964646c652220636c6173733d22646174652d6c6162656c2220783d223230605f8201526a1811103c9e91191818111f60a91b607f8201527326b0ba3ab934ba3c902230ba329e17ba32bc3a1f60611b608a820152609e0195945050505050565b7f3c7265637420636c6173733d226772616469656e742d626f726465722220783d81527f2237352220793d22323230222077696474683d2232353022206865696768743d60208201527f223930222072783d22323022207472616e73666f726d3d227472616e736c617460408201526832941816181491179f60b91b60608201527f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737360698201527f3d22646174652d746578742220783d223230302220793d22323635223e000000608982015260008451612fb78160a6850160208901611bce565b8083019050602d60f81b8060a68301528551612fda8160a7850160208a01611bce565b60a79201918201528351612ff58160a8840160208801611bce565b612da061306460a8838501017f3c2f746578743e2020202020203c7465787420746578742d616e63686f723d2281527f6d6964646c652220636c6173733d22646174652d6c6162656c2220783d22323060208201526a1811103c9e91199818111f60a91b6040820152604b0190565b7f4c6f636b2044617465203c2f746578743e202020203c2f673e20203c2f673e008152601f0190565b7f3c67207472616e73666f726d3d227472616e736c6174652831302c34323029228152601f60f91b60208201527f3c7061746820636c6173733d22736e6f77666c616b652d6c6f676f2220643d2260218201527f4d31392e34312c352e37376c2d332e34372c342e38394c31322e34362c352e3760418201527f372c31352e39342c305a4d372e35342c372e35336c312e322c342e38382c000060618201527f342e34312e37342d2e37342d342e34315a4d302c31352e39336c352e37372c33607f8201527f2e34382c342e38392d332e34384c352e37372c31322e34355a6d372e35332c38609f8201527f2e342c202020202020342e38382d312e322e37342d342e34322d342e34312e3760bf8201527f355a6d382e342c372e35342c332e34382d352e37372d332e34382d342e38394c60df820152650c4c8b8d0d4b60d21b60ff8201527f32362e315a6d382e342d372e35332d312e322d342e38382d342e34322d2e37346101058201527f2e37352c342e34315a6d372e35342d382e344c32362e312c20202020202031326101258201527f2e34366c2d342e38392c332e34382c342e38392c332e34375a6d2d372e35332d6101458201527f382e342d342e38382c312e322d2e37342c342e34312c342e34312d2e37345a2261016582015261179f60f11b6101858201527f3c7465787420636c6173733d226c6f676f2d746578742220783d2234302220796101878201527f3d223235223e205452554520465245455a4520202020202020203c2f746578746101a78201526c1f10101e17b39f1e17b9bb339f60991b6101c782015260006101d48201610349565b600080821280156001600160ff1b038490038513161561330e5761330e611f67565b600160ff1b839003841281161561332757613327611f67565b50500190565b60006001600160ff1b038184138284138082168684048611161561335357613353611f67565b600160ff1b600087128281168783058912161561337257613372611f67565b6000871292508782058712848416161561338e5761338e611f67565b878505871281841616156133a4576133a4611f67565b505050929093029392505050565b6000826133c1576133c1612320565b600160ff1b8214600019841416156133db576133db611f67565b500590565b60008083128015600160ff1b8501841216156133fe576133fe611f67565b6001600160ff1b038401831381161561341957613419611f67565b5050039056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220a158b7565da62cf76b9fcac2853c3770fab83053585b71b47ac0249bd4da897b64736f6c634300080c0033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061012c5760003560e01c80636352211e116100ad578063a22cb46511610071578063a22cb46514610275578063b88d4fde14610288578063c87b56dd1461029b578063e985e9c5146102ae578063f2fde38b146102ea57600080fd5b80636352211e1461022057806370a0823114610233578063715018a6146102545780638da5cb5b1461025c57806395d89b411461026d57600080fd5b806323b872dd116100f457806323b872dd146101c1578063276f1c41146101d457806340c10f19146101e757806342842e0e146101fa57806342966c681461020d57600080fd5b806301ffc9a71461013157806306fdde0314610159578063081812fc1461016e578063095ea7b31461019957806319394588146101ae575b600080fd5b61014461013f366004611baa565b6102fd565b60405190151581526020015b60405180910390f35b61016161034f565b6040516101509190611c26565b61018161017c366004611c39565b6103e1565b6040516001600160a01b039091168152602001610150565b6101ac6101a7366004611c6e565b61047b565b005b6101ac6101bc366004611c98565b610591565b6101ac6101cf366004611cb3565b610633565b600754610181906001600160a01b031681565b6101ac6101f5366004611c6e565b610664565b6101ac610208366004611cb3565b6106c4565b6101ac61021b366004611c39565b6106df565b61018161022e366004611c39565b61073d565b610246610241366004611c98565b6107b4565b604051908152602001610150565b6101ac61083b565b6006546001600160a01b0316610181565b610161610871565b6101ac610283366004611cfd565b610880565b6101ac610296366004611d4a565b61088b565b6101616102a9366004611c39565b6108c3565b6101446102bc366004611e26565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b6101ac6102f8366004611c98565b610975565b60006001600160e01b031982166380ac58cd60e01b148061032e57506001600160e01b03198216635b5e139f60e01b145b8061034957506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461035e90611e59565b80601f016020809104026020016040519081016040528092919081815260200182805461038a90611e59565b80156103d75780601f106103ac576101008083540402835291602001916103d7565b820191906000526020600020905b8154815290600101906020018083116103ba57829003601f168201915b5050505050905090565b6000818152600260205260408120546001600160a01b031661045f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b60006104868261073d565b9050806001600160a01b0316836001600160a01b031614156104f45760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610456565b336001600160a01b0382161480610510575061051081336102bc565b6105825760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610456565b61058c8383610a0d565b505050565b6006546001600160a01b031633146105bb5760405162461bcd60e51b815260040161045690611e94565b600754600160a01b900460ff161561060c5760405162461bcd60e51b815260206004820152601460248201527311dbdd995c9b9bdc88185b1c9958591e481cd95d60621b6044820152606401610456565b600780546001600160a81b0319166001600160a01b0390921691909117600160a01b179055565b61063d3382610a7b565b6106595760405162461bcd60e51b815260040161045690611ec9565b61058c838383610b72565b6007546001600160a01b031633146106b65760405162461bcd60e51b815260206004820152601560248201527413db9b1e48119858dd1bdc9e4818d85b8818d85b1b605a1b6044820152606401610456565b6106c08282610d12565b5050565b61058c8383836040518060200160405280600081525061088b565b6007546001600160a01b031633146107315760405162461bcd60e51b815260206004820152601560248201527413db9b1e48119858dd1bdc9e4818d85b8818d85b1b605a1b6044820152606401610456565b61073a81610e54565b50565b6000818152600260205260408120546001600160a01b0316806103495760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610456565b60006001600160a01b03821661081f5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610456565b506001600160a01b031660009081526003602052604090205490565b6006546001600160a01b031633146108655760405162461bcd60e51b815260040161045690611e94565b61086f6000610eef565b565b60606001805461035e90611e59565b6106c0338383610f41565b6108953383610a7b565b6108b15760405162461bcd60e51b815260040161045690611ec9565b6108bd84848484611010565b50505050565b6000818152600260205260409020546060906001600160a01b03166108e757600080fd5b60075460405163187002cb60e11b815260048101849052600091829182916001600160a01b0316906330e005969060240160a060405180830381865afa158015610935573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109599190611f1a565b509350935050925061096c838383611043565b95945050505050565b6006546001600160a01b0316331461099f5760405162461bcd60e51b815260040161045690611e94565b6001600160a01b038116610a045760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610456565b61073a81610eef565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190610a428261073d565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b0316610af45760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610456565b6000610aff8361073d565b9050806001600160a01b0316846001600160a01b03161480610b3a5750836001600160a01b0316610b2f846103e1565b6001600160a01b0316145b80610b6a57506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b0316610b858261073d565b6001600160a01b031614610bed5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610456565b6001600160a01b038216610c4f5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610456565b610c5a600082610a0d565b6001600160a01b0383166000908152600360205260408120805460019290610c83908490611f7d565b90915550506001600160a01b0382166000908152600360205260408120805460019290610cb1908490611f94565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6001600160a01b038216610d685760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610456565b6000818152600260205260409020546001600160a01b031615610dcd5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610456565b6001600160a01b0382166000908152600360205260408120805460019290610df6908490611f94565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6000610e5f8261073d565b9050610e6c600083610a0d565b6001600160a01b0381166000908152600360205260408120805460019290610e95908490611f7d565b909155505060008281526002602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b03161415610fa35760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610456565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61101b848484610b72565b611027848484846110cd565b6108bd5760405162461bcd60e51b815260040161045690611fac565b606060006110528585856111cb565b90506000611067611062836113e8565b611451565b905060006110768787876115b7565b90506110a2828260405160200161108e92919061201a565b604051602081830303815290604052611451565b6040516020016110b29190612138565b60405160208183030381529060405293505050509392505050565b60006001600160a01b0384163b156111c057604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061111190339089908890889060040161217d565b6020604051808303816000875af192505050801561114c575060408051601f3d908101601f19168201909252611149918101906121ba565b60015b6111a6573d80801561117a576040519150601f19603f3d011682016040523d82523d6000602084013e61117f565b606091505b50805161119e5760405162461bcd60e51b815260040161045690611fac565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610b6a565b506001949350505050565b61121a6040518061012001604052806060815260200160608152602001606081526020016060815260200160608152602001606081526020016060815260200160608152602001606081525090565b60008060006112288761160e565b925092509250600080600061123c896116b4565b92509250925060008060006112508b6116b4565b925092509250606080606080600a8910156112945761126e896116e0565b60405160200161127e91906121d7565b60405160208183030381529060405293506112a0565b61129d896116e0565b93505b600a8610156112d8576112b2866116e0565b6040516020016112c291906121d7565b60405160208183030381529060405292506112e4565b6112e1866116e0565b92505b600a88101561131c576112f6886116e0565b60405160200161130691906121d7565b6040516020818303038152906040529150611328565b611325886116e0565b91505b600a8510156113605761133a856116e0565b60405160200161134a91906121d7565b604051602081830303815290604052905061136c565b611369856116e0565b90505b6040518061012001604052806113818f6116e0565b815260200161138f8e6116e0565b815260200161139d8d6116e0565b81526020016113ab8c6116e0565b81526020018581526020018381526020016113c5896116e0565b81526020810194909452604090930152509e9d5050505050505050505050505050565b60606113f2611809565b6113fa61182e565b6114038461183f565b61140b611862565b611414866119c9565b61141d876119ed565b611425611a10565b60405160200161143b9796959493929190612200565b6040516020818303038152906040529050919050565b606081516000141561147157505060408051602081019091526000815290565b600060405180606001604052806040815260200161342060409139905060006003845160026114a09190611f94565b6114aa9190612336565b6114b590600461234a565b905060006114c4826020611f94565b67ffffffffffffffff8111156114dc576114dc611d34565b6040519080825280601f01601f191660200182016040528015611506576020820181803683370190505b509050818152600183018586518101602084015b81831015611572576003830192508251603f8160121c168501518253600182019150603f81600c1c168501518253600182019150603f8160061c168501518253600182019150603f811685015182535060010161151a565b60038951066001811461158c576002811461159d576115a9565b613d3d60f01b6001198301526115a9565b603d60f81b6000198301525b509398975050505050505050565b606060008060006115c78761160e565b9250925092506115d6836116e0565b6115df836116e0565b6115e8836116e0565b6115f1896116e0565b6115fa896116e0565b6040516020016110b2959493929190612369565b6000808080611625670de0b6b3a764000086612336565b9050600067016345785d8a000061164483670de0b6b3a764000061234a565b61164e9088611f7d565b6116589190612336565b90506000662386f26fc100006116768367016345785d8a000061234a565b61168885670de0b6b3a764000061234a565b611692908a611f7d565b61169c9190611f7d565b6116a69190612336565b929791965091945092505050565b600080808080806116d06116cb6201518089612336565b611a21565b9199909850909650945050505050565b6060816117045750506040805180820190915260018152600360fc1b602082015290565b8160005b811561172e5780611718816124e2565b91506117279050600a83612336565b9150611708565b60008167ffffffffffffffff81111561174957611749611d34565b6040519080825280601f01601f191660200182016040528015611773576020820181803683370190505b509050815b851561180057611789600182611f7d565b90506000611798600a88612336565b6117a390600a61234a565b6117ad9088611f7d565b6117b89060306124fd565b905060008160f81b9050808484815181106117d5576117d5612522565b60200101906001600160f81b031916908160001a9053506117f7600a89612336565b97505050611778565b50949350505050565b606060405160200161181a90612538565b604051602081830303815290604052905090565b606060405160200161181a90612952565b606081600001518260200151836040015160405160200161143b93929190612bf7565b606060405160200161181a907f3c673e3c6c696e6561724772616469656e742079313d223530222078323d223381527f3530222079323d22353022206772616469656e74556e6974733d22757365725360208201526a3830b1b2a7b72ab9b2911f60a91b60408201527f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d22236264604b8201527f62656335222f3e3c73746f70206f66667365743d2231222073746f702d636f6c606b8201527f6f723d2223346234633465222f3e3c2f6c696e6561724772616469656e743e00608b8201527f3c7265637420636c6173733d226772616469656e742d626f726465722220783d60aa8201527f2237352220793d22313230222077696474683d2232353022206865696768743d60ca8201527f223930222072783d22323022207472616e73666f726d3d227472616e736c617460ea8201526832941816181491179f60b91b61010a8201526101130190565b60608160c001518260e0015183610100015160405160200161143b93929190612dab565b6060816060015182608001518360a0015160405160200161143b93929190612ed5565b606060405160200161181a9061308d565b600080808381611a348262010bd96132ec565b611a419062253d8c6132ec565b9050600062023ab1611a5483600461332d565b611a5e91906133b2565b90506004611a6f8262023ab161332d565b611a7a9060036132ec565b611a8491906133b2565b611a8e90836133e0565b9150600062164b09611aa18460016132ec565b611aad90610fa061332d565b611ab791906133b2565b90506004611ac7826105b561332d565b611ad191906133b2565b611adb90846133e0565b611ae690601f6132ec565b9250600061098f611af885605061332d565b611b0291906133b2565b905060006050611b148361098f61332d565b611b1e91906133b2565b611b2890866133e0565b9050611b35600b836133b2565b9450611b4285600c61332d565b611b4d8360026132ec565b611b5791906133e0565b91508483611b666031876133e0565b611b7190606461332d565b611b7b91906132ec565b611b8591906132ec565b9a919950975095505050505050565b6001600160e01b03198116811461073a57600080fd5b600060208284031215611bbc57600080fd5b8135611bc781611b94565b9392505050565b60005b83811015611be9578181015183820152602001611bd1565b838111156108bd5750506000910152565b60008151808452611c12816020860160208601611bce565b601f01601f19169290920160200192915050565b602081526000611bc76020830184611bfa565b600060208284031215611c4b57600080fd5b5035919050565b80356001600160a01b0381168114611c6957600080fd5b919050565b60008060408385031215611c8157600080fd5b611c8a83611c52565b946020939093013593505050565b600060208284031215611caa57600080fd5b611bc782611c52565b600080600060608486031215611cc857600080fd5b611cd184611c52565b9250611cdf60208501611c52565b9150604084013590509250925092565b801515811461073a57600080fd5b60008060408385031215611d1057600080fd5b611d1983611c52565b91506020830135611d2981611cef565b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215611d6057600080fd5b611d6985611c52565b9350611d7760208601611c52565b925060408501359150606085013567ffffffffffffffff80821115611d9b57600080fd5b818701915087601f830112611daf57600080fd5b813581811115611dc157611dc1611d34565b604051601f8201601f19908116603f01168101908382118183101715611de957611de9611d34565b816040528281528a6020848701011115611e0257600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215611e3957600080fd5b611e4283611c52565b9150611e5060208401611c52565b90509250929050565b600181811c90821680611e6d57607f821691505b60208210811415611e8e57634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b600080600080600060a08688031215611f3257600080fd5b855194506020860151935060408601519250606086015191506080860151611f5981611cef565b809150509295509295909350565b634e487b7160e01b600052601160045260246000fd5b600082821015611f8f57611f8f611f67565b500390565b60008219821115611fa757611fa7611f67565b500190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60008151612010818560208601611bce565b9290920192915050565b683d913730b6b2911d1160b91b81526d151c9d59519c99595e994813919560921b60098201527f222c20226465736372697074696f6e223a2254686973204e465420726570726560178201527f73656e742061206c6f636b656420706f736974696f6e20696e2054727565467260378201527f65657a652070726f746f636f6c222c2022696d616765223a220000000000000060578201527f646174613a696d6167652f7376672b786d6c3b6261736536342c000000000000607082015282516000906120ee81608a850160208801611bce565b6f011161130ba3a3934b13aba32b9911d160851b608a91840191820152835161211e81609a840160208801611bce565b607d60f81b609a9290910191820152609b01949350505050565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c00000081526000825161217081601d850160208701611bce565b91909101601d0192915050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906121b090830184611bfa565b9695505050505050565b6000602082840312156121cc57600080fd5b8151611bc781611b94565b600360fc1b8152600082516121f3816001850160208701611bce565b9190910160010192915050565b7f3c73766720786d6c6e733d22687474703a2f2f7777772e77332e6f72672f32308152600060207f30302f7376672220786d6c6e733a786c696e6b3d22687474703a2f2f7777772e818401527f77332e6f72672f313939392f786c696e6b222076696577426f783d22302030206040840152681a1818101a9818111f60b91b606084015260698a5161229781838701858f01611bce565b8a51908501906122ac81848401868f01611bce565b8a519101906122c081848401868e01611bce565b89519101906122d481848401868d01611bce565b88519101906122e881848401868c01611bce565b87519101906122fc81848401868b01611bce565b865191019061231081848401868a01611bce565b01019a9950505050505050505050565b634e487b7160e01b600052601260045260246000fd5b60008261234557612345612320565b500490565b600081600019048311821515161561236457612364611f67565b500290565b7f5b7b2274726169745f74797065223a2022416d6f756e74206c6f636b6564222c81526810113b30b63ab2911d60b91b6020820152600086516123b3816029850160208b01611bce565b601760f91b60299184019182015286516123d481602a840160208b01611bce565b86519101906123ea81602a840160208a01611bce565b7f7d2c7b22646973706c61795f74797065223a202264617465222c202274726169602a92909101918201527f745f74797065223a20224c6f636b696e672064617465222c202276616c756522604a820152601d60f91b606a820152845161245881606b840160208901611bce565b6124d56124c76124c1606b848601017f7d2c7b22646973706c61795f74797065223a202264617465222c20227472616981527f745f74797065223a20224d617475726974792064617465222c202276616c7565602082015261111d60f11b604082015260420190565b87611ffe565b617d5d60f01b815260020190565b9998505050505050505050565b60006000198214156124f6576124f6611f67565b5060010190565b600060ff821660ff84168060ff0382111561251a5761251a611f67565b019392505050565b634e487b7160e01b600052603260045260246000fd5b7f3c7374796c653e2020202040696d706f72742075726c282661706f733b68747481527f70733a2f2f666f6e74732e676f6f676c65617069732e636f6d2f637373323f6660208201527f616d696c793d4d6f6e747365727261742661706f733b293b000000000000000060408201527f2e6261636b67726f756e64207b20202020202066696c6c3a2075726c2826717560588201527f6f743b236c696e6561722d6772616469656e742671756f743b293b202020207d60788201527f2e736e6f77666c616b652d6c6f676f207b20202020202066696c6c3a2023666660988201527f663b202020207d202020202e6c6f676f2d74657874207b20202020202066696c60b8820152676c3a20236666663b60c01b60d88201527f666f6e742d66616d696c793a204d6f6e747365727261742c2073616e732d736560e08201527f7269663b202020202020666f6e742d73697a653a20323570783b202020207d006101008201527f2e616d6f756e742d74657874207b2020202066696c6c3a20236438623938643b61011f8201527f20202020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e61013f8201527f732d73657269663b20202020666f6e742d73697a653a20353570783b2020202061015f820152607d60f81b61017f8201527f2e646174652d74657874207b2020202066696c6c3a20236438623938643b20206101808201527f2020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e732d6101a08201527f73657269663b20202020666f6e742d73697a653a20333070783b202020207d006101c08201527f2e646174652d6c6162656c207b2020202066696c6c3a20233864626464383b206101df8201527f202020666f6e742d66616d696c793a204d6f6e747365727261742c2073616e736101ff8201527f2d73657269663b20202020666f6e742d73697a653a20323070783b202020207d61021f8201527f2e6772616469656e742d626f78207b20202020202066696c6c3a206e6f6e653b61023f8201527f2020202020207374726f6b652d6d697465726c696d69743a2031303b2020202061025f8201527320207374726f6b652d77696474683a203370783b60601b61027f8201527f7374726f6b653a2075726c282671756f743b236c696e6561722d6772616469656102938201526e6e742671756f743b293b202020207d60881b6102b38201527f2e6772616469656e742d626f72646572207b2020202066696c6c3a206e6f6e656102c28201527f3b202020207374726f6b652d6d697465726c696d69743a2031303b20202020736102e28201527f74726f6b652d77696474683a203170783b202020207374726f6b653a20236264610302820152733132b19a9d901010103e90101e17b9ba3cb6329f60611b61032282015260006103368201610349565b7f3c6c696e6561724772616469656e742069643d226c696e6561722d677261646981527f656e74222078313d2230222079313d22353030222078323d223235302220793260208201527f3d2231303022206772616469656e74556e6974733d227573657253706163654f604082015265372ab9b2911f60d11b60608201527f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d2223626460668201527f62656335222f3e202020203c73746f70206f66667365743d22302e352220737460868201527337b816b1b7b637b91e91119a9a1b989c1891179f60611b60a68201527f3c73746f70206f66667365743d2231222073746f702d636f6c6f723d2223346260ba8201527f34633465222f3e20203c2f6c696e6561724772616469656e743e00000000000060da8201527f3c7265637420636c6173733d226261636b67726f756e64222077696474683d2260f48201527f34303022206865696768743d22353030222072783d223230222f3e3c672074726101148201527f616e73666f726d3d227472616e736c61746528302c353029223e0000000000006101348201527f3c673e2020202020203c6c696e6561724772616469656e742079313d2235302261014e8201527f2078323d22333530222079323d22353022206772616469656e74556e6974733d61016e82015270113ab9b2b929b830b1b2a7b72ab9b2911f60791b61018e820152600061034961019f83017f3c73746f70206f66667365743d2230222073746f702d636f6c6f723d2223626481527f62656335222f3e20202020202020203c73746f70206f66667365743d2231222060208201527f73746f702d636f6c6f723d2223346234633465222f3e2020202020203c2f6c6960408201526c3732b0b923b930b234b2b73a1f60991b6060820152606d0190565b7f3c7265637420636c6173733d226772616469656e742d626f726465722220783d81527f2235302220793d223130222077696474683d2233303022206865696768743d2260208201527f313030222072783d22323022207472616e73666f726d3d227472616e736c617460408201526832941816181491179f60b91b60608201527f3c7465787420746578742d616e63686f723d22656e642220636c6173733d226160698201527f6d6f756e742d746578742220783d223334352220793d223730223e0000000000608982015260008451612cd98160a4850160208901611bce565b601760f91b60a4918401918201528451612cfa8160a5840160208901611bce565b8451910190612d108160a5840160208801611bce565b612da0612d81612d3260a584860101661e17ba32bc3a1f60c91b815260070190565b7f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737381527f3d22646174652d6c6162656c2220783d223230302220793d22313030223e00006020820152603e0190565b722ba2aa241e17ba32bc3a1f101010101e17b39f60691b815260130190565b979650505050505050565b7f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737381527f3d22646174652d746578742220783d223230302220793d22313635223e000000602082015260008451612e0981603d850160208901611bce565b8083019050602d60f81b80603d8301528551612e2c81603e850160208a01611bce565b603e9201918201528351612e4781603f840160208801611bce565b7f3c2f746578743e2020202020203c7465787420746578742d616e63686f723d22603f92909101918201527f6d6964646c652220636c6173733d22646174652d6c6162656c2220783d223230605f8201526a1811103c9e91191818111f60a91b607f8201527326b0ba3ab934ba3c902230ba329e17ba32bc3a1f60611b608a820152609e0195945050505050565b7f3c7265637420636c6173733d226772616469656e742d626f726465722220783d81527f2237352220793d22323230222077696474683d2232353022206865696768743d60208201527f223930222072783d22323022207472616e73666f726d3d227472616e736c617460408201526832941816181491179f60b91b60608201527f3c7465787420746578742d616e63686f723d226d6964646c652220636c61737360698201527f3d22646174652d746578742220783d223230302220793d22323635223e000000608982015260008451612fb78160a6850160208901611bce565b8083019050602d60f81b8060a68301528551612fda8160a7850160208a01611bce565b60a79201918201528351612ff58160a8840160208801611bce565b612da061306460a8838501017f3c2f746578743e2020202020203c7465787420746578742d616e63686f723d2281527f6d6964646c652220636c6173733d22646174652d6c6162656c2220783d22323060208201526a1811103c9e91199818111f60a91b6040820152604b0190565b7f4c6f636b2044617465203c2f746578743e202020203c2f673e20203c2f673e008152601f0190565b7f3c67207472616e73666f726d3d227472616e736c6174652831302c34323029228152601f60f91b60208201527f3c7061746820636c6173733d22736e6f77666c616b652d6c6f676f2220643d2260218201527f4d31392e34312c352e37376c2d332e34372c342e38394c31322e34362c352e3760418201527f372c31352e39342c305a4d372e35342c372e35336c312e322c342e38382c000060618201527f342e34312e37342d2e37342d342e34315a4d302c31352e39336c352e37372c33607f8201527f2e34382c342e38392d332e34384c352e37372c31322e34355a6d372e35332c38609f8201527f2e342c202020202020342e38382d312e322e37342d342e34322d342e34312e3760bf8201527f355a6d382e342c372e35342c332e34382d352e37372d332e34382d342e38394c60df820152650c4c8b8d0d4b60d21b60ff8201527f32362e315a6d382e342d372e35332d312e322d342e38382d342e34322d2e37346101058201527f2e37352c342e34315a6d372e35342d382e344c32362e312c20202020202031326101258201527f2e34366c2d342e38392c332e34382c342e38392c332e34375a6d2d372e35332d6101458201527f382e342d342e38382c312e322d2e37342c342e34312c342e34312d2e37345a2261016582015261179f60f11b6101858201527f3c7465787420636c6173733d226c6f676f2d746578742220783d2234302220796101878201527f3d223235223e205452554520465245455a4520202020202020203c2f746578746101a78201526c1f10101e17b39f1e17b9bb339f60991b6101c782015260006101d48201610349565b600080821280156001600160ff1b038490038513161561330e5761330e611f67565b600160ff1b839003841281161561332757613327611f67565b50500190565b60006001600160ff1b038184138284138082168684048611161561335357613353611f67565b600160ff1b600087128281168783058912161561337257613372611f67565b6000871292508782058712848416161561338e5761338e611f67565b878505871281841616156133a4576133a4611f67565b505050929093029392505050565b6000826133c1576133c1612320565b600160ff1b8214600019841416156133db576133db611f67565b500590565b60008083128015600160ff1b8501841216156133fe576133fe611f67565b6001600160ff1b038401831381161561341957613419611f67565b5050039056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220a158b7565da62cf76b9fcac2853c3770fab83053585b71b47ac0249bd4da897b64736f6c634300080c0033

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

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