Token TradeStars TSX

 

Overview ERC-20

Price
$0.00 @ 0.000000 MATIC
Fully Diluted Market Cap
Total Supply:
69,992,871.842739 TSX

Holders:
1,573 addresses

Transfers:
-

 
Loading
[ Download CSV Export  ] 
Loading
[ Download CSV Export  ] 
Loading

OVERVIEW

TradeStars is a fantasy sports game aiming to connect a DeFi “trading” layer with a DFS “gaming” layer in a play-to-earn model. Users Trade fantasy stocks that represent real-life athletes’ performances, compete against each other on different types of DFS contests, and earn rewards.


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

Contract Source Code Verified (Exact Match)

Contract Name:
TSXChild

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2021-08-30
*/

// Sources flattened with hardhat v2.1.2 https://hardhat.org

// File @openzeppelin/contracts/utils/[email protected]

// SPDX-License-Identifier: MIT

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) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}


// File @openzeppelin/contracts/access/[email protected]


pragma solidity ^0.8.0;

/**
 * @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 () {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), 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 {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}


// File @openzeppelin/contracts/token/ERC20/[email protected]


pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}


// File @openzeppelin/contracts/token/ERC20/extensions/[email protected]


pragma solidity ^0.8.0;

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

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

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}


// File @openzeppelin/contracts/token/ERC20/[email protected]


pragma solidity ^0.8.0;



/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20, IERC20Metadata {
    mapping (address => uint256) private _balances;

    mapping (address => mapping (address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * The defaut value of {decimals} is 18. To select a different value for
     * {decimals} you should overload it.
     *
     * All two of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5,05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless this function is
     * overridden;
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual override returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * Requirements:
     *
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);

        uint256 currentAllowance = _allowances[sender][_msgSender()];
        require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance");
        _approve(sender, _msgSender(), currentAllowance - amount);

        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue);
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        uint256 currentAllowance = _allowances[_msgSender()][spender];
        require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero");
        _approve(_msgSender(), spender, currentAllowance - subtractedValue);

        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        uint256 senderBalance = _balances[sender];
        require(senderBalance >= amount, "ERC20: transfer amount exceeds balance");
        _balances[sender] = senderBalance - amount;
        _balances[recipient] += amount;

        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply += amount;
        _balances[account] += amount;
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        _balances[account] = accountBalance - amount;
        _totalSupply -= amount;

        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens 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 amount) internal virtual { }
}


// File @openzeppelin/contracts/token/ERC20/extensions/[email protected]


pragma solidity ^0.8.0;


/**
 * @dev Extension of {ERC20} that allows token holders to destroy both their own
 * tokens and those that they have an allowance for, in a way that can be
 * recognized off-chain (via event analysis).
 */
abstract contract ERC20Burnable is Context, ERC20 {
    /**
     * @dev Destroys `amount` tokens from the caller.
     *
     * See {ERC20-_burn}.
     */
    function burn(uint256 amount) public virtual {
        _burn(_msgSender(), amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, deducting from the caller's
     * allowance.
     *
     * See {ERC20-_burn} and {ERC20-allowance}.
     *
     * Requirements:
     *
     * - the caller must have allowance for ``accounts``'s tokens of at least
     * `amount`.
     */
    function burnFrom(address account, uint256 amount) public virtual {
        uint256 currentAllowance = allowance(account, _msgSender());
        require(currentAllowance >= amount, "ERC20: burn amount exceeds allowance");
        _approve(account, _msgSender(), currentAllowance - amount);
        _burn(account, amount);
    }
}


// File @openzeppelin/contracts/utils/cryptography/[email protected]


pragma solidity ^0.8.0;

/**
 * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
 *
 * These functions can be used to verify that a message was signed by the holder
 * of the private keys of a given address.
 */
library ECDSA {
    /**
     * @dev Returns the address that signed a hashed message (`hash`) with
     * `signature`. This address can then be used for verification purposes.
     *
     * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
     * this function rejects them by requiring the `s` value to be in the lower
     * half order, and the `v` value to be either 27 or 28.
     *
     * IMPORTANT: `hash` _must_ be the result of a hash operation for the
     * verification to be secure: it is possible to craft signatures that
     * recover to arbitrary addresses for non-hashed data. A safe way to ensure
     * this is by receiving a hash of the original message (which may otherwise
     * be too long), and then calling {toEthSignedMessageHash} on it.
     */
    function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
        // Divide the signature in r, s and v variables
        bytes32 r;
        bytes32 s;
        uint8 v;

        // Check the signature length
        // - case 65: r,s,v signature (standard)
        // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._
        if (signature.length == 65) {
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            // solhint-disable-next-line no-inline-assembly
            assembly {
                r := mload(add(signature, 0x20))
                s := mload(add(signature, 0x40))
                v := byte(0, mload(add(signature, 0x60)))
            }
        } else if (signature.length == 64) {
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            // solhint-disable-next-line no-inline-assembly
            assembly {
                let vs := mload(add(signature, 0x40))
                r := mload(add(signature, 0x20))
                s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff)
                v := add(shr(255, vs), 27)
            }
        } else {
            revert("ECDSA: invalid signature length");
        }

        return recover(hash, v, r, s);
    }

    /**
     * @dev Overload of {ECDSA-recover} that receives the `v`,
     * `r` and `s` signature fields separately.
     */
    function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
        // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
        // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
        // the valid range for s in (281): 0 < s < secp256k1n ÷ 2 + 1, and for v in (282): v ∈ {27, 28}. Most
        // signatures from current libraries generate a unique signature with an s-value in the lower half order.
        //
        // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
        // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
        // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
        // these malleable signatures as well.
        require(uint256(s) <= 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0, "ECDSA: invalid signature 's' value");
        require(v == 27 || v == 28, "ECDSA: invalid signature 'v' value");

        // If the signature is valid (and not malleable), return the signer address
        address signer = ecrecover(hash, v, r, s);
        require(signer != address(0), "ECDSA: invalid signature");

        return signer;
    }

    /**
     * @dev Returns an Ethereum Signed Message, created from a `hash`. This
     * produces hash corresponding to the one signed with the
     * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]
     * JSON-RPC method as part of EIP-191.
     *
     * See {recover}.
     */
    function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {
        // 32 is the length in bytes of hash,
        // enforced by the type signature above
        return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash));
    }

    /**
     * @dev Returns an Ethereum Signed Typed Data, created from a
     * `domainSeparator` and a `structHash`. This produces hash corresponding
     * to the one signed with the
     * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]
     * JSON-RPC method as part of EIP-712.
     *
     * See {recover}.
     */
    function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {
        return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash));
    }
}


// File contracts/eip712/EIP712Base.sol


pragma solidity ^0.8.0;


contract EIP712Base {

    struct EIP712Domain {
        string name;
        string version;
        uint256 chainId;
        address verifyingContract;
    }
    
    bytes32 private constant EIP712DOMAIN_TYPEHASH = keccak256(
        "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"
    );

    string internal constant EIP712_DOMAIN_NAME = "TradeStars";
    string internal constant EIP712_DOMAIN_VERSION = "1.0";

    bytes32 DOMAIN_SEPARATOR;

    // initialize on contructor
    constructor() {
        DOMAIN_SEPARATOR = keccak256(
            abi.encode(
                EIP712DOMAIN_TYPEHASH,
                keccak256(bytes(EIP712_DOMAIN_NAME)),
                keccak256(bytes(EIP712_DOMAIN_VERSION)),
                bytes32(block.chainid),
                address(this)
            )
        );
    }

    /**
     * Accept message hash and returns hash message in EIP712 compatible form
     * So that it can be used to recover signer from signature signed using EIP712 formatted data
     * https://eips.ethereum.org/EIPS/eip-712
     * "\\x19" makes the encoding deterministic
     * "\\x01" is the version byte to make it compatible to EIP-191
     */
    function toTypedMessageHash(bytes32 _messageHash)
        internal
        view
        returns (bytes32)
    {
        return keccak256(
            abi.encodePacked("\x19\x01", DOMAIN_SEPARATOR, _messageHash)
        );
    }
}


// File contracts/eip712/EIP712Transfer.sol


pragma solidity ^0.8.0;

contract EIP712Transfer is EIP712Base {

    struct TokenTransferOrder {
        address spender;
        address from;
        uint256 tokenAmount;
        bytes32 data;
        uint256 expiration;
    }

    bytes32 private constant TRANSFER_TYPEHASH = keccak256(
        "TokenTransferOrder(address spender,address from,uint256 tokenAmount,bytes32 data,uint256 expiration)"
    );

    function getTokenTransferOrderHash(
        address _spender,
        address _from,
        uint256 _tokenAmount,
        bytes32 _data,
        uint256 _expiration
    )
        public view returns (bytes32 orderHash)
    {
        orderHash = toTypedMessageHash(
            hashTransferOrder(
                _spender, 
                _from,
                _tokenAmount, 
                _data, 
                _expiration
            )
        );
    }

    function hashTransferOrder(
        address _spender,
        address _from,
        uint256 _tokenAmount,
        bytes32 _data,
        uint256 _expiration
    )
        private
        pure
        returns (bytes32)
    {
        return keccak256(
            abi.encode(
                TRANSFER_TYPEHASH,
                _spender,
                _from,
                _tokenAmount,
                _data,
                _expiration
            )
        );
    }
}


// File contracts/eip712/ITransferWithSig.sol


pragma solidity ^0.8.0;


interface ITransferWithSig {
    function transferWithSig(
        bytes calldata sig,
        uint256 tokenAmount,
        bytes32 data,
        uint256 expiration,
        address from,
        address to
    ) external returns (address);
}


// File contracts/erc20/TransferWithSigERC20.sol


pragma solidity ^0.8.0;



abstract contract TransferWithSigERC20 is ERC20, EIP712Transfer, ITransferWithSig  {

    using ECDSA for bytes32;

    // eip712 order hashes
    mapping(bytes32 => bool) public disabledHashes;

    /**
     * @dev transfers with owner's signature
     * @param _sig caller's signature
     * @param _amount amount of tokens to transfer
     * @param _data keccak256(abi.encodePacked(_orderId, _tokenAddress, _tokenAmount));
     * @param _expiration order
     * @param _from token owner
     * @param _spender beneficiary
     */
    function transferWithSig(
        bytes calldata _sig,
        uint256 _amount,
        bytes32 _data,
        uint256 _expiration,
        address _from,
        address _spender
    ) 
        external override returns (address from) 
    {
        require(_amount > 0, "transferWithSig(): amount should be > 0");
        require(
            _expiration == 0 || block.number <= _expiration,
            "transferWithSig(): signature is expired"
        );

        bytes32 dataHash = getTokenTransferOrderHash(
            _spender, 
            _from,
            _amount, 
            _data, 
            _expiration
        );
        
        require(
            disabledHashes[dataHash] == false, 
            "transferWithSig(): signature disabled"
        );
        disabledHashes[dataHash] = true;

        from = dataHash.recover(_sig);

        require(from == _from, "transferWithSig(): invalid from");

        // call transfer without approval clearance
        _transfer(from, address(uint160(_spender)), _amount);
    }
}


// File contracts/matic/IChildToken.sol


pragma solidity ^0.8.0;


interface IChildToken {
    function withdraw(uint256 amount) external;
    function deposit(address user, bytes calldata depositData) external;
}


// File contracts/erc20/TSXChild.sol


pragma solidity ^0.8.0;



contract TSXChild is 
    Ownable, 
    TransferWithSigERC20, 
    ERC20Burnable, 
    IChildToken
{
    /// Token details
    string public constant NAME = "TradeStars TSX";
    string public constant SYMBOL = "TSX";

    // Allowed deposit
    address private depositorRole;

    constructor() Ownable() ERC20(NAME, SYMBOL) {

    }

    /**
     * @dev changes the depositor address. called by owner only
     * @param _depositorAddress allowed depositor
     */
    function setDepositor(address _depositorAddress) public onlyOwner {
        depositorRole = _depositorAddress;
    }

    /**
     * @notice called when token is deposited on root chain
     * @dev Should be callable only by depositorRole
     *  Should handle deposit by minting the required amount for user
     * @param user user address for whom deposit is being done
     * @param depositData abi encoded amount
     */
    function deposit(address user, bytes calldata depositData) external override {
        require(
            msg.sender == depositorRole,
            "deposit: caller not allowed"
        );

        uint256 amount = abi.decode(depositData, (uint256));
        _mint(user, amount);
    }

    /**
     * @notice called when user wants to withdraw tokens back to root chain.
     *  Can be called relayed
     * @dev Should burn user's tokens. This transaction will be verified when exiting on root chain
     * @param amount amount of tokens to withdraw
     */
    function withdraw(uint256 amount) external override {
        _burn(msg.sender, amount);
    }
}

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":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","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":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"NAME","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SYMBOL","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"bytes","name":"depositData","type":"bytes"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"disabledHashes","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_spender","type":"address"},{"internalType":"address","name":"_from","type":"address"},{"internalType":"uint256","name":"_tokenAmount","type":"uint256"},{"internalType":"bytes32","name":"_data","type":"bytes32"},{"internalType":"uint256","name":"_expiration","type":"uint256"}],"name":"getTokenTransferOrderHash","outputs":[{"internalType":"bytes32","name":"orderHash","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_depositorAddress","type":"address"}],"name":"setDepositor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"_sig","type":"bytes"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"bytes32","name":"_data","type":"bytes32"},{"internalType":"uint256","name":"_expiration","type":"uint256"},{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_spender","type":"address"}],"name":"transferWithSig","outputs":[{"internalType":"address","name":"from","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040523480156200001157600080fd5b506040518060400160405280600e81526020016d0a8e4c2c8caa6e8c2e4e640a8a6b60931b815250604051806040016040528060038152602001620a8a6b60eb1b815250600062000067620001b860201b60201c565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3508151620000c6906004906020850190620001bc565b508051620000dc906005906020840190620001bc565b5050604080518082018252600a8152695472616465537461727360b01b6020918201528151808301835260038152620312e360ec1b9082015281517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818301527f7eff23c4885cef289ec23ef7edea6917ba684f2eab1c1df22c4ae44f8becdc23818401527fe6bbd6277e1bf288eed5e8d1780f9a50b239e86b153736bceebccf4ea79d90b360608201524660808201523060a0808301919091528351808303909101815260c09091019092528151910120600655506200029f565b3390565b828054620001ca9062000262565b90600052602060002090601f016020900481019282620001ee576000855562000239565b82601f106200020957805160ff191683800117855562000239565b8280016001018555821562000239579182015b82811115620002395782518255916020019190600101906200021c565b50620002479291506200024b565b5090565b5b808211156200024757600081556001016200024c565b600181811c908216806200027757607f821691505b602082108114156200029957634e487b7160e01b600052602260045260246000fd5b50919050565b61168780620002af6000396000f3fe608060405234801561001057600080fd5b50600436106101585760003560e01c80638da5cb5b116100c3578063cf2c52cb1161007c578063cf2c52cb146102f4578063dd62ed3e14610307578063f2c098b714610340578063f2fde38b14610353578063f76f8d7814610366578063ff83fc5b1461038857600080fd5b80638da5cb5b1461025157806395d89b4114610276578063a3f4df7e1461027e578063a457c2d7146102ab578063a9059cbb146102be578063acd06cb3146102d157600080fd5b8063313ce56711610115578063313ce567146101eb57806339509351146101fa57806342966c68146101d657806370a082311461020d578063715018a61461023657806379cc67901461023e57600080fd5b806306fdde031461015d578063095ea7b31461017b57806318160ddd1461019e57806323b872dd146101b0578063250e38bf146101c35780632e1a7d4d146101d6575b600080fd5b61016561039b565b6040516101729190611547565b60405180910390f35b61018e610189366004611483565b61042d565b6040519015158152602001610172565b6003545b604051908152602001610172565b61018e6101be3660046113a7565b610443565b6101a26101d13660046113e3565b6104f9565b6101e96101e43660046114ad565b6105ae565b005b60405160128152602001610172565b61018e610208366004611483565b6105bb565b6101a261021b366004611352565b6001600160a01b031660009081526001602052604090205490565b6101e96105f2565b6101e961024c366004611483565b610666565b6000546001600160a01b03165b6040516001600160a01b039091168152602001610172565b6101656106ee565b6101656040518060400160405280600e81526020016d0a8e4c2c8caa6e8c2e4e640a8a6b60931b81525081565b61018e6102b9366004611483565b6106fd565b61018e6102cc366004611483565b610798565b61018e6102df3660046114ad565b60076020526000908152604090205460ff1681565b6101e9610302366004611430565b6107a5565b6101a2610315366004611374565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6101e961034e366004611352565b61081f565b6101e9610361366004611352565b61086b565b610165604051806040016040528060038152602001620a8a6b60eb1b81525081565b61025e6103963660046114c6565b610955565b6060600480546103aa90611600565b80601f01602080910402602001604051908101604052809291908181526020018280546103d690611600565b80156104235780601f106103f857610100808354040283529160200191610423565b820191906000526020600020905b81548152906001019060200180831161040657829003601f168201915b5050505050905090565b600061043a338484610b72565b50600192915050565b6000610450848484610c97565b6001600160a01b0384166000908152600260209081526040808320338452909152902054828110156104da5760405162461bcd60e51b815260206004820152602860248201527f45524332303a207472616e7366657220616d6f756e74206578636565647320616044820152676c6c6f77616e636560c01b60648201526084015b60405180910390fd5b6104ee85336104e986856115e9565b610b72565b506001949350505050565b604080517f95640c2abab3596023a439b6aee44b2d9085f80109550c8afaa58b41cd9edc716020808301919091526001600160a01b0388811683850152871660608301526080820186905260a0820185905260c08083018590528351808403909101815260e08301845280519082012060065461190160f01b610100850152610102840152610122808401919091528351808403909101815261014290920190925280519101206000905b9695505050505050565b6105b83382610e6f565b50565b3360008181526002602090815260408083206001600160a01b0387168452909152812054909161043a9185906104e99086906115d1565b6000546001600160a01b0316331461061c5760405162461bcd60e51b81526004016104d19061159c565b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b60006106728333610315565b9050818110156106d05760405162461bcd60e51b8152602060048201526024808201527f45524332303a206275726e20616d6f756e74206578636565647320616c6c6f77604482015263616e636560e01b60648201526084016104d1565b6106df83336104e985856115e9565b6106e98383610e6f565b505050565b6060600580546103aa90611600565b3360009081526002602090815260408083206001600160a01b03861684529091528120548281101561077f5760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084016104d1565b61078e33856104e986856115e9565b5060019392505050565b600061043a338484610c97565b6008546001600160a01b031633146107ff5760405162461bcd60e51b815260206004820152601b60248201527f6465706f7369743a2063616c6c6572206e6f7420616c6c6f776564000000000060448201526064016104d1565b600061080d828401846114ad565b90506108198482610fbe565b50505050565b6000546001600160a01b031633146108495760405162461bcd60e51b81526004016104d19061159c565b600880546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146108955760405162461bcd60e51b81526004016104d19061159c565b6001600160a01b0381166108fa5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104d1565b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b60008086116109b65760405162461bcd60e51b815260206004820152602760248201527f7472616e736665725769746853696728293a20616d6f756e742073686f756c646044820152660206265203e20360cc1b60648201526084016104d1565b8315806109c35750834311155b610a1f5760405162461bcd60e51b815260206004820152602760248201527f7472616e736665725769746853696728293a207369676e617475726520697320604482015266195e1c1a5c995960ca1b60648201526084016104d1565b6000610a2e83858989896104f9565b60008181526007602052604090205490915060ff1615610a9e5760405162461bcd60e51b815260206004820152602560248201527f7472616e736665725769746853696728293a207369676e61747572652064697360448201526418589b195960da1b60648201526084016104d1565b600081815260076020908152604091829020805460ff191660011790558151601f8b01829004820281018201909252898252610af891908b908b9081908401838280828437600092019190915250859392505061109d9050565b9150836001600160a01b0316826001600160a01b031614610b5b5760405162461bcd60e51b815260206004820152601f60248201527f7472616e736665725769746853696728293a20696e76616c69642066726f6d0060448201526064016104d1565b610b66828489610c97565b50979650505050505050565b6001600160a01b038316610bd45760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b60648201526084016104d1565b6001600160a01b038216610c355760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b60648201526084016104d1565b6001600160a01b0383811660008181526002602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6001600160a01b038316610cfb5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016104d1565b6001600160a01b038216610d5d5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016104d1565b6001600160a01b03831660009081526001602052604090205481811015610dd55760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b60648201526084016104d1565b610ddf82826115e9565b6001600160a01b038086166000908152600160205260408082209390935590851681529081208054849290610e159084906115d1565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610e6191815260200190565b60405180910390a350505050565b6001600160a01b038216610ecf5760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b60648201526084016104d1565b6001600160a01b03821660009081526001602052604090205481811015610f435760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b60648201526084016104d1565b610f4d82826115e9565b6001600160a01b03841660009081526001602052604081209190915560038054849290610f7b9084906115e9565b90915550506040518281526000906001600160a01b038516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610c8a565b6001600160a01b0382166110145760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016104d1565b806003600082825461102691906115d1565b90915550506001600160a01b038216600090815260016020526040812080548392906110539084906115d1565b90915550506040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b6000806000808451604114156110c75750505060208201516040830151606084015160001a61113d565b8451604014156110f55750505060408201516020830151906001600160ff1b0381169060ff1c601b0161113d565b60405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016104d1565b6105a48682858560007f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08211156111c15760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016104d1565b8360ff16601b14806111d657508360ff16601c145b61122d5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016104d1565b6040805160008082526020820180845288905260ff871692820192909252606081018590526080810184905260019060a0016020604051602081039080840390855afa158015611281573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166112e45760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016104d1565b95945050505050565b80356001600160a01b038116811461130457600080fd5b919050565b60008083601f84011261131b57600080fd5b50813567ffffffffffffffff81111561133357600080fd5b60208301915083602082850101111561134b57600080fd5b9250929050565b60006020828403121561136457600080fd5b61136d826112ed565b9392505050565b6000806040838503121561138757600080fd5b611390836112ed565b915061139e602084016112ed565b90509250929050565b6000806000606084860312156113bc57600080fd5b6113c5846112ed565b92506113d3602085016112ed565b9150604084013590509250925092565b600080600080600060a086880312156113fb57600080fd5b611404866112ed565b9450611412602087016112ed565b94979496505050506040830135926060810135926080909101359150565b60008060006040848603121561144557600080fd5b61144e846112ed565b9250602084013567ffffffffffffffff81111561146a57600080fd5b61147686828701611309565b9497909650939450505050565b6000806040838503121561149657600080fd5b61149f836112ed565b946020939093013593505050565b6000602082840312156114bf57600080fd5b5035919050565b600080600080600080600060c0888a0312156114e157600080fd5b873567ffffffffffffffff8111156114f857600080fd5b6115048a828b01611309565b90985096505060208801359450604088013593506060880135925061152b608089016112ed565b915061153960a089016112ed565b905092959891949750929550565b600060208083528351808285015260005b8181101561157457858101830151858201604001528201611558565b81811115611586576000604083870101525b50601f01601f1916929092016040019392505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600082198211156115e4576115e461163b565b500190565b6000828210156115fb576115fb61163b565b500390565b600181811c9082168061161457607f821691505b6020821081141561163557634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fdfea2646970667358221220f672d472fee16b734b9136a1078b458e609f9e97be1c1a50cd98caf11f8df91a64736f6c63430008070033

Deployed ByteCode Sourcemap

29640:1611:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8917:100;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;11084:169;;;;;;:::i;:::-;;:::i;:::-;;;4460:14:1;;4453:22;4435:41;;4423:2;4408:18;11084:169:0;4295:187:1;10037:108:0;10125:12;;10037:108;;;4633:25:1;;;4621:2;4606:18;10037:108:0;4487:177:1;11735:422:0;;;;;;:::i;:::-;;:::i;26293:478::-;;;;;;:::i;:::-;;:::i;31152:96::-;;;;;;:::i;:::-;;:::i;:::-;;9879:93;;;9962:2;15229:36:1;;15217:2;15202:18;9879:93:0;15087:184:1;12566:215:0;;;;;;:::i;:::-;;:::i;10208:127::-;;;;;;:::i;:::-;-1:-1:-1;;;;;10309:18:0;10282:7;10309:18;;;:9;:18;;;;;;;10208:127;2824:148;;;:::i;18593:332::-;;;;;;:::i;:::-;;:::i;2173:87::-;2219:7;2246:6;-1:-1:-1;;;;;2246:6:0;2173:87;;;-1:-1:-1;;;;;4251:32:1;;;4233:51;;4221:2;4206:18;2173:87:0;4087:203:1;9136:104:0;;;:::i;29774:46::-;;;;;;;;;;;;;;;-1:-1:-1;;;29774:46:0;;;;;13284:377;;;;;;:::i;:::-;;:::i;10548:175::-;;;;;;:::i;:::-;;:::i;27853:46::-;;;;;;:::i;:::-;;;;;;;;;;;;;;;;30571:294;;;;;;:::i;:::-;;:::i;10786:151::-;;;;;;:::i;:::-;-1:-1:-1;;;;;10902:18:0;;;10875:7;10902:18;;;:11;:18;;;;;;;;:27;;;;;;;;;;;;;10786:151;30131:118;;;;;;:::i;:::-;;:::i;3127:244::-;;;;;;:::i;:::-;;:::i;29827:37::-;;;;;;;;;;;;;;;-1:-1:-1;;;29827:37:0;;;;;28254:1075;;;;;;:::i;:::-;;:::i;8917:100::-;8971:13;9004:5;8997:12;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8917:100;:::o;11084:169::-;11167:4;11184:39;805:10;11207:7;11216:6;11184:8;:39::i;:::-;-1:-1:-1;11241:4:0;11084:169;;;;:::o;11735:422::-;11841:4;11858:36;11868:6;11876:9;11887:6;11858:9;:36::i;:::-;-1:-1:-1;;;;;11934:19:0;;11907:24;11934:19;;;:11;:19;;;;;;;;805:10;11934:33;;;;;;;;11986:26;;;;11978:79;;;;-1:-1:-1;;;11978:79:0;;11547:2:1;11978:79:0;;;11529:21:1;11586:2;11566:18;;;11559:30;11625:34;11605:18;;;11598:62;-1:-1:-1;;;11676:18:1;;;11669:38;11724:19;;11978:79:0;;;;;;;;;12068:57;12077:6;805:10;12099:25;12118:6;12099:16;:25;:::i;:::-;12068:8;:57::i;:::-;-1:-1:-1;12145:4:0;;11735:422;-1:-1:-1;;;;11735:422:0:o;26293:478::-;27054:197;;;26155:129;27054:197;;;;4956:25:1;;;;-1:-1:-1;;;;;5055:15:1;;;5035:18;;;5028:43;5107:15;;5087:18;;;5080:43;5139:18;;;5132:34;;;5182:19;;;5175:35;;;5226:19;;;;5219:35;;;27054:197:0;;;;;;;;;;4928:19:1;;;27054:197:0;;27030:232;;;;;;25755:16;;-1:-1:-1;;;25726:60:0;;;3948:27:1;3991:11;;;3984:27;4027:12;;;;4020:28;;;;25726:60:0;;;;;;;;;;4064:12:1;;;;25726:60:0;;;25702:95;;;;;-1:-1:-1;;26548:215:0;26536:227;26293:478;-1:-1:-1;;;;;;26293:478:0:o;31152:96::-;31215:25;31221:10;31233:6;31215:5;:25::i;:::-;31152:96;:::o;12566:215::-;805:10;12654:4;12703:25;;;:11;:25;;;;;;;;-1:-1:-1;;;;;12703:34:0;;;;;;;;;;12654:4;;12671:80;;12694:7;;12703:47;;12740:10;;12703:47;:::i;2824:148::-;2219:7;2246:6;-1:-1:-1;;;;;2246:6:0;805:10;2393:23;2385:68;;;;-1:-1:-1;;;2385:68:0;;;;;;;:::i;:::-;2931:1:::1;2915:6:::0;;2894:40:::1;::::0;-1:-1:-1;;;;;2915:6:0;;::::1;::::0;2894:40:::1;::::0;2931:1;;2894:40:::1;2962:1;2945:19:::0;;-1:-1:-1;;;;;;2945:19:0::1;::::0;;2824:148::o;18593:332::-;18670:24;18697:32;18707:7;805:10;10786:151;:::i;18697:32::-;18670:59;;18768:6;18748:16;:26;;18740:75;;;;-1:-1:-1;;;18740:75:0;;12317:2:1;18740:75:0;;;12299:21:1;12356:2;12336:18;;;12329:30;12395:34;12375:18;;;12368:62;-1:-1:-1;;;12446:18:1;;;12439:34;12490:19;;18740:75:0;12115:400:1;18740:75:0;18826:58;18835:7;805:10;18858:25;18877:6;18858:16;:25;:::i;18826:58::-;18895:22;18901:7;18910:6;18895:5;:22::i;:::-;18659:266;18593:332;;:::o;9136:104::-;9192:13;9225:7;9218:14;;;;;:::i;13284:377::-;805:10;13377:4;13421:25;;;:11;:25;;;;;;;;-1:-1:-1;;;;;13421:34:0;;;;;;;;;;13474:35;;;;13466:85;;;;-1:-1:-1;;;13466:85:0;;14341:2:1;13466:85:0;;;14323:21:1;14380:2;14360:18;;;14353:30;14419:34;14399:18;;;14392:62;-1:-1:-1;;;14470:18:1;;;14463:35;14515:19;;13466:85:0;14139:401:1;13466:85:0;13562:67;805:10;13585:7;13594:34;13613:15;13594:16;:34;:::i;13562:67::-;-1:-1:-1;13649:4:0;;13284:377;-1:-1:-1;;;13284:377:0:o;10548:175::-;10634:4;10651:42;805:10;10675:9;10686:6;10651:9;:42::i;30571:294::-;30695:13;;-1:-1:-1;;;;;30695:13:0;30681:10;:27;30659:104;;;;-1:-1:-1;;;30659:104:0;;10375:2:1;30659:104:0;;;10357:21:1;10414:2;10394:18;;;10387:30;10453:29;10433:18;;;10426:57;10500:18;;30659:104:0;10173:351:1;30659:104:0;30776:14;30793:34;;;;30804:11;30793:34;:::i;:::-;30776:51;;30838:19;30844:4;30850:6;30838:5;:19::i;:::-;30648:217;30571:294;;;:::o;30131:118::-;2219:7;2246:6;-1:-1:-1;;;;;2246:6:0;805:10;2393:23;2385:68;;;;-1:-1:-1;;;2385:68:0;;;;;;;:::i;:::-;30208:13:::1;:33:::0;;-1:-1:-1;;;;;;30208:33:0::1;-1:-1:-1::0;;;;;30208:33:0;;;::::1;::::0;;;::::1;::::0;;30131:118::o;3127:244::-;2219:7;2246:6;-1:-1:-1;;;;;2246:6:0;805:10;2393:23;2385:68;;;;-1:-1:-1;;;2385:68:0;;;;;;;:::i;:::-;-1:-1:-1;;;;;3216:22:0;::::1;3208:73;;;::::0;-1:-1:-1;;;3208:73:0;;8352:2:1;3208:73:0::1;::::0;::::1;8334:21:1::0;8391:2;8371:18;;;8364:30;8430:34;8410:18;;;8403:62;-1:-1:-1;;;8481:18:1;;;8474:36;8527:19;;3208:73:0::1;8150:402:1::0;3208:73:0::1;3318:6;::::0;;3297:38:::1;::::0;-1:-1:-1;;;;;3297:38:0;;::::1;::::0;3318:6;::::1;::::0;3297:38:::1;::::0;::::1;3346:6;:17:::0;;-1:-1:-1;;;;;;3346:17:0::1;-1:-1:-1::0;;;;;3346:17:0;;;::::1;::::0;;;::::1;::::0;;3127:244::o;28254:1075::-;28484:12;28533:1;28523:7;:11;28515:63;;;;-1:-1:-1;;;28515:63:0;;11139:2:1;28515:63:0;;;11121:21:1;11178:2;11158:18;;;11151:30;11217:34;11197:18;;;11190:62;-1:-1:-1;;;11268:18:1;;;11261:37;11315:19;;28515:63:0;10937:403:1;28515:63:0;28611:16;;;:47;;;28647:11;28631:12;:27;;28611:47;28589:136;;;;-1:-1:-1;;;28589:136:0;;10731:2:1;28589:136:0;;;10713:21:1;10770:2;10750:18;;;10743:30;10809:34;10789:18;;;10782:62;-1:-1:-1;;;10860:18:1;;;10853:37;10907:19;;28589:136:0;10529:403:1;28589:136:0;28738:16;28757:150;28797:8;28821:5;28841:7;28864:5;28885:11;28757:25;:150::i;:::-;28950:24;;;;:14;:24;;;;;;28738:169;;-1:-1:-1;28950:24:0;;:33;28928:121;;;;-1:-1:-1;;;28928:121:0;;13935:2:1;28928:121:0;;;13917:21:1;13974:2;13954:18;;;13947:30;14013:34;13993:18;;;13986:62;-1:-1:-1;;;14064:18:1;;;14057:35;14109:19;;28928:121:0;13733:401:1;28928:121:0;29060:24;;;;:14;:24;;;;;;;;;:31;;-1:-1:-1;;29060:31:0;29087:4;29060:31;;;29111:22;;;;;;;;;;;;;;;;;;;;;;;29128:4;;;;;;29111:22;;29128:4;;;;29111:22;;;;;;;;;-1:-1:-1;29111:8:0;;:22;-1:-1:-1;;29111:16:0;:22;-1:-1:-1;29111:22:0:i;:::-;29104:29;;29162:5;-1:-1:-1;;;;;29154:13:0;:4;-1:-1:-1;;;;;29154:13:0;;29146:57;;;;-1:-1:-1;;;29146:57:0;;7992:2:1;29146:57:0;;;7974:21:1;8031:2;8011:18;;;8004:30;8070:33;8050:18;;;8043:61;8121:18;;29146:57:0;7790:355:1;29146:57:0;29269:52;29279:4;29301:8;29313:7;29269:9;:52::i;:::-;28504:825;28254:1075;;;;;;;;;:::o;16640:346::-;-1:-1:-1;;;;;16742:19:0;;16734:68;;;;-1:-1:-1;;;16734:68:0;;13530:2:1;16734:68:0;;;13512:21:1;13569:2;13549:18;;;13542:30;13608:34;13588:18;;;13581:62;-1:-1:-1;;;13659:18:1;;;13652:34;13703:19;;16734:68:0;13328:400:1;16734:68:0;-1:-1:-1;;;;;16821:21:0;;16813:68;;;;-1:-1:-1;;;16813:68:0;;8759:2:1;16813:68:0;;;8741:21:1;8798:2;8778:18;;;8771:30;8837:34;8817:18;;;8810:62;-1:-1:-1;;;8888:18:1;;;8881:32;8930:19;;16813:68:0;8557:398:1;16813:68:0;-1:-1:-1;;;;;16894:18:0;;;;;;;:11;:18;;;;;;;;:27;;;;;;;;;;;;;:36;;;16946:32;;4633:25:1;;;16946:32:0;;4606:18:1;16946:32:0;;;;;;;;16640:346;;;:::o;14151:604::-;-1:-1:-1;;;;;14257:20:0;;14249:70;;;;-1:-1:-1;;;14249:70:0;;13124:2:1;14249:70:0;;;13106:21:1;13163:2;13143:18;;;13136:30;13202:34;13182:18;;;13175:62;-1:-1:-1;;;13253:18:1;;;13246:35;13298:19;;14249:70:0;12922:401:1;14249:70:0;-1:-1:-1;;;;;14338:23:0;;14330:71;;;;-1:-1:-1;;;14330:71:0;;6825:2:1;14330:71:0;;;6807:21:1;6864:2;6844:18;;;6837:30;6903:34;6883:18;;;6876:62;-1:-1:-1;;;6954:18:1;;;6947:33;6997:19;;14330:71:0;6623:399:1;14330:71:0;-1:-1:-1;;;;;14498:17:0;;14474:21;14498:17;;;:9;:17;;;;;;14534:23;;;;14526:74;;;;-1:-1:-1;;;14526:74:0;;9162:2:1;14526:74:0;;;9144:21:1;9201:2;9181:18;;;9174:30;9240:34;9220:18;;;9213:62;-1:-1:-1;;;9291:18:1;;;9284:36;9337:19;;14526:74:0;8960:402:1;14526:74:0;14631:22;14647:6;14631:13;:22;:::i;:::-;-1:-1:-1;;;;;14611:17:0;;;;;;;:9;:17;;;;;;:42;;;;14664:20;;;;;;;;:30;;14688:6;;14611:17;14664:30;;14688:6;;14664:30;:::i;:::-;;;;;;;;14729:9;-1:-1:-1;;;;;14712:35:0;14721:6;-1:-1:-1;;;;;14712:35:0;;14740:6;14712:35;;;;4633:25:1;;4621:2;4606:18;;4487:177;14712:35:0;;;;;;;;14238:517;14151:604;;;:::o;15708:494::-;-1:-1:-1;;;;;15792:21:0;;15784:67;;;;-1:-1:-1;;;15784:67:0;;12722:2:1;15784:67:0;;;12704:21:1;12761:2;12741:18;;;12734:30;12800:34;12780:18;;;12773:62;-1:-1:-1;;;12851:18:1;;;12844:31;12892:19;;15784:67:0;12520:397:1;15784:67:0;-1:-1:-1;;;;;15951:18:0;;15926:22;15951:18;;;:9;:18;;;;;;15988:24;;;;15980:71;;;;-1:-1:-1;;;15980:71:0;;7229:2:1;15980:71:0;;;7211:21:1;7268:2;7248:18;;;7241:30;7307:34;7287:18;;;7280:62;-1:-1:-1;;;7358:18:1;;;7351:32;7400:19;;15980:71:0;7027:398:1;15980:71:0;16083:23;16100:6;16083:14;:23;:::i;:::-;-1:-1:-1;;;;;16062:18:0;;;;;;:9;:18;;;;;:44;;;;16117:12;:22;;16133:6;;16062:18;16117:22;;16133:6;;16117:22;:::i;:::-;;;;-1:-1:-1;;16157:37:0;;4633:25:1;;;16183:1:0;;-1:-1:-1;;;;;16157:37:0;;;;;4621:2:1;4606:18;16157:37:0;4487:177:1;15037:338:0;-1:-1:-1;;;;;15121:21:0;;15113:65;;;;-1:-1:-1;;;15113:65:0;;14747:2:1;15113:65:0;;;14729:21:1;14786:2;14766:18;;;14759:30;14825:33;14805:18;;;14798:61;14876:18;;15113:65:0;14545:355:1;15113:65:0;15269:6;15253:12;;:22;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;;;15286:18:0;;;;;;:9;:18;;;;;:28;;15308:6;;15286:18;:28;;15308:6;;15286:28;:::i;:::-;;;;-1:-1:-1;;15330:37:0;;4633:25:1;;;-1:-1:-1;;;;;15330:37:0;;;15347:1;;15330:37;;4621:2:1;4606:18;15330:37:0;;;;;;;15037:338;;:::o;20061:1492::-;20139:7;20216:9;20236;20256:7;20476:9;:16;20496:2;20476:22;20472:1032;;;-1:-1:-1;;;20763:4:0;20748:20;;20742:27;20813:4;20798:20;;20792:27;20871:4;20856:20;;20850:27;20847:1;20842:36;20472:1032;;;20914:9;:16;20934:2;20914:22;20910:594;;;-1:-1:-1;;;21206:4:0;21191:20;;21185:27;21256:4;21241:20;;21235:27;;-1:-1:-1;;;;;21285:75:0;;;21391:3;21387:12;21401:2;21383:21;20910:594;;;21451:41;;-1:-1:-1;;;21451:41:0;;7632:2:1;21451:41:0;;;7614:21:1;7671:2;7651:18;;;7644:30;7710:33;7690:18;;;7683:61;7761:18;;21451:41:0;7430:355:1;20910:594:0;21523:22;21531:4;21537:1;21540;21543;21777:7;22702:66;22688:80;;;22680:127;;;;-1:-1:-1;;;22680:127:0;;9569:2:1;22680:127:0;;;9551:21:1;9608:2;9588:18;;;9581:30;9647:34;9627:18;;;9620:62;-1:-1:-1;;;9698:18:1;;;9691:32;9740:19;;22680:127:0;9367:398:1;22680:127:0;22826:1;:7;;22831:2;22826:7;:18;;;;22837:1;:7;;22842:2;22837:7;22826:18;22818:65;;;;-1:-1:-1;;;22818:65:0;;9972:2:1;22818:65:0;;;9954:21:1;10011:2;9991:18;;;9984:30;10050:34;10030:18;;;10023:62;-1:-1:-1;;;10101:18:1;;;10094:32;10143:19;;22818:65:0;9770:398:1;22818:65:0;22998:24;;;22981:14;22998:24;;;;;;;;;5492:25:1;;;5565:4;5553:17;;5533:18;;;5526:45;;;;5587:18;;;5580:34;;;5630:18;;;5623:34;;;22998:24:0;;5464:19:1;;22998:24:0;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;22998:24:0;;-1:-1:-1;;22998:24:0;;;-1:-1:-1;;;;;;;23041:20:0;;23033:57;;;;-1:-1:-1;;;23033:57:0;;6472:2:1;23033:57:0;;;6454:21:1;6511:2;6491:18;;;6484:30;6550:26;6530:18;;;6523:54;6594:18;;23033:57:0;6270:348:1;23033:57:0;23110:6;21692:1432;-1:-1:-1;;;;;21692:1432:0:o;14:173:1:-;82:20;;-1:-1:-1;;;;;131:31:1;;121:42;;111:70;;177:1;174;167:12;111:70;14:173;;;:::o;192:347::-;243:8;253:6;307:3;300:4;292:6;288:17;284:27;274:55;;325:1;322;315:12;274:55;-1:-1:-1;348:20:1;;391:18;380:30;;377:50;;;423:1;420;413:12;377:50;460:4;452:6;448:17;436:29;;512:3;505:4;496:6;488;484:19;480:30;477:39;474:59;;;529:1;526;519:12;474:59;192:347;;;;;:::o;544:186::-;603:6;656:2;644:9;635:7;631:23;627:32;624:52;;;672:1;669;662:12;624:52;695:29;714:9;695:29;:::i;:::-;685:39;544:186;-1:-1:-1;;;544:186:1:o;735:260::-;803:6;811;864:2;852:9;843:7;839:23;835:32;832:52;;;880:1;877;870:12;832:52;903:29;922:9;903:29;:::i;:::-;893:39;;951:38;985:2;974:9;970:18;951:38;:::i;:::-;941:48;;735:260;;;;;:::o;1000:328::-;1077:6;1085;1093;1146:2;1134:9;1125:7;1121:23;1117:32;1114:52;;;1162:1;1159;1152:12;1114:52;1185:29;1204:9;1185:29;:::i;:::-;1175:39;;1233:38;1267:2;1256:9;1252:18;1233:38;:::i;:::-;1223:48;;1318:2;1307:9;1303:18;1290:32;1280:42;;1000:328;;;;;:::o;1333:466::-;1428:6;1436;1444;1452;1460;1513:3;1501:9;1492:7;1488:23;1484:33;1481:53;;;1530:1;1527;1520:12;1481:53;1553:29;1572:9;1553:29;:::i;:::-;1543:39;;1601:38;1635:2;1624:9;1620:18;1601:38;:::i;:::-;1333:466;;1591:48;;-1:-1:-1;;;;1686:2:1;1671:18;;1658:32;;1737:2;1722:18;;1709:32;;1788:3;1773:19;;;1760:33;;-1:-1:-1;1333:466:1:o;1804:483::-;1883:6;1891;1899;1952:2;1940:9;1931:7;1927:23;1923:32;1920:52;;;1968:1;1965;1958:12;1920:52;1991:29;2010:9;1991:29;:::i;:::-;1981:39;;2071:2;2060:9;2056:18;2043:32;2098:18;2090:6;2087:30;2084:50;;;2130:1;2127;2120:12;2084:50;2169:58;2219:7;2210:6;2199:9;2195:22;2169:58;:::i;:::-;1804:483;;2246:8;;-1:-1:-1;2143:84:1;;-1:-1:-1;;;;1804:483:1:o;2292:254::-;2360:6;2368;2421:2;2409:9;2400:7;2396:23;2392:32;2389:52;;;2437:1;2434;2427:12;2389:52;2460:29;2479:9;2460:29;:::i;:::-;2450:39;2536:2;2521:18;;;;2508:32;;-1:-1:-1;;;2292:254:1:o;2551:180::-;2610:6;2663:2;2651:9;2642:7;2638:23;2634:32;2631:52;;;2679:1;2676;2669:12;2631:52;-1:-1:-1;2702:23:1;;2551:180;-1:-1:-1;2551:180:1:o;2736:764::-;2851:6;2859;2867;2875;2883;2891;2899;2952:3;2940:9;2931:7;2927:23;2923:33;2920:53;;;2969:1;2966;2959:12;2920:53;3009:9;2996:23;3042:18;3034:6;3031:30;3028:50;;;3074:1;3071;3064:12;3028:50;3113:58;3163:7;3154:6;3143:9;3139:22;3113:58;:::i;:::-;3190:8;;-1:-1:-1;3087:84:1;-1:-1:-1;;3272:2:1;3257:18;;3244:32;;-1:-1:-1;3323:2:1;3308:18;;3295:32;;-1:-1:-1;3374:2:1;3359:18;;3346:32;;-1:-1:-1;3397:39:1;3431:3;3416:19;;3397:39;:::i;:::-;3387:49;;3455:39;3489:3;3478:9;3474:19;3455:39;:::i;:::-;3445:49;;2736:764;;;;;;;;;;:::o;5668:597::-;5780:4;5809:2;5838;5827:9;5820:21;5870:6;5864:13;5913:6;5908:2;5897:9;5893:18;5886:34;5938:1;5948:140;5962:6;5959:1;5956:13;5948:140;;;6057:14;;;6053:23;;6047:30;6023:17;;;6042:2;6019:26;6012:66;5977:10;;5948:140;;;6106:6;6103:1;6100:13;6097:91;;;6176:1;6171:2;6162:6;6151:9;6147:22;6143:31;6136:42;6097:91;-1:-1:-1;6249:2:1;6228:15;-1:-1:-1;;6224:29:1;6209:45;;;;6256:2;6205:54;;5668:597;-1:-1:-1;;;5668:597:1:o;11754:356::-;11956:2;11938:21;;;11975:18;;;11968:30;12034:34;12029:2;12014:18;;12007:62;12101:2;12086:18;;11754:356::o;15276:128::-;15316:3;15347:1;15343:6;15340:1;15337:13;15334:39;;;15353:18;;:::i;:::-;-1:-1:-1;15389:9:1;;15276:128::o;15409:125::-;15449:4;15477:1;15474;15471:8;15468:34;;;15482:18;;:::i;:::-;-1:-1:-1;15519:9:1;;15409:125::o;15539:380::-;15618:1;15614:12;;;;15661;;;15682:61;;15736:4;15728:6;15724:17;15714:27;;15682:61;15789:2;15781:6;15778:14;15758:18;15755:38;15752:161;;;15835:10;15830:3;15826:20;15823:1;15816:31;15870:4;15867:1;15860:15;15898:4;15895:1;15888:15;15752:161;;15539:380;;;:::o;15924:127::-;15985:10;15980:3;15976:20;15973:1;15966:31;16016:4;16013:1;16006:15;16040:4;16037:1;16030:15

Swarm Source

ipfs://f672d472fee16b734b9136a1078b458e609f9e97be1c1a50cd98caf11f8df91a
Loading