ETH Price: $2,167.85 (+0.62%)

Contract

0xedd190d250c752BAf6c96D77E2A678b1b0C2B42E
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

More Info

Private Name Tags

TokenTracker

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Complete Order131191722021-08-29 7:59:131669 days ago1630223953IN
0xedd190d2...1b0C2B42E
0 ETH0.0215723343.06963951
Issue And Create...131190072021-08-29 7:22:551669 days ago1630221775IN
0xedd190d2...1b0C2B42E
0 ETH0.1610265457.72336568
Create Land Bund...130742742021-08-22 9:29:561675 days ago1629624596IN
0xedd190d2...1b0C2B42E
0 ETH0.0006333615
Complete Order129202462021-07-29 10:34:281699 days ago1627554868IN
0xedd190d2...1b0C2B42E
0 ETH0.0097497420
Refund129200842021-07-29 9:59:021699 days ago1627552742IN
0xedd190d2...1b0C2B42E
0 ETH0.0008846118
Create Land Bund...129065322021-07-27 6:18:121702 days ago1627366692IN
0xedd190d2...1b0C2B42E
0 ETH0.0005911314
Create Land Bund...129065212021-07-27 6:16:351702 days ago1627366595IN
0xedd190d2...1b0C2B42E
0 ETH0.0005911314
Issue And Create...129063862021-07-27 5:51:171702 days ago1627365077IN
0xedd190d2...1b0C2B42E
0 ETH0.0374534114
Complete Order128312842021-07-15 11:27:261713 days ago1626348446IN
0xedd190d2...1b0C2B42E
0 ETH0.0114692225
Issue And Create...128308422021-07-15 9:54:121713 days ago1626342852IN
0xedd190d2...1b0C2B42E
0 ETH0.0702845729
Complete Order126753392021-06-21 3:41:231738 days ago1624246883IN
0xedd190d2...1b0C2B42E
0 ETH0.0066101414.00000145
Issue And Create...125524652021-06-02 2:57:101757 days ago1622602630IN
0xedd190d2...1b0C2B42E
0 ETH0.0530456820.9
Complete Order119823972021-03-06 3:23:121845 days ago1615000992IN
0xedd190d2...1b0C2B42E
0 ETH0.0374066266.00000145
Create Land Bund...119823082021-03-06 3:06:461845 days ago1615000006IN
0xedd190d2...1b0C2B42E
0 ETH0.0660287274
Complete Order119762662021-03-05 4:59:111846 days ago1614920351IN
0xedd190d2...1b0C2B42E
0 ETH0.0187818775.00000146
Update Order119761102021-03-05 4:28:471846 days ago1614918527IN
0xedd190d2...1b0C2B42E
0 ETH0.00682766115
Complete Order119689932021-03-04 2:09:231847 days ago1614823763IN
0xedd190d2...1b0C2B42E
0 ETH0.09348267126.00000156
Issue And Create...119688332021-03-04 1:32:071847 days ago1614821527IN
0xedd190d2...1b0C2B42E
0 ETH0.3218114595
Issue And Create...119640392021-03-03 7:54:031848 days ago1614758043IN
0xedd190d2...1b0C2B42E
0 ETH0.0675125894
Cancel Order118713272021-02-17 1:32:391862 days ago1613525559IN
0xedd190d2...1b0C2B42E
0 ETH0.00865695132
Complete Order118011462021-02-06 6:26:461873 days ago1612592806IN
0xedd190d2...1b0C2B42E
0 ETH0.0474456120
Issue And Create...118011252021-02-06 6:22:381873 days ago1612592558IN
0xedd190d2...1b0C2B42E
0 ETH0.17939859122.85
Create Single La...117629652021-01-31 9:30:481878 days ago1612085448IN
0xedd190d2...1b0C2B42E
0 ETH0.0193180470.00000134
Complete Order117094502021-01-23 3:48:561887 days ago1611373736IN
0xedd190d2...1b0C2B42E
0 ETH0.0231785173.50000067
Issue And Create...117094312021-01-23 3:44:471887 days ago1611373487IN
0xedd190d2...1b0C2B42E
0 ETH0.0865998978
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading
Loading...
Loading
Cross-Chain Transactions

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
GenesisKingdomToken

Compiler Version
v0.5.17+commit.d19bba13

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
/**
 *Submitted for verification at Etherscan.io on 2020-09-08
*/

pragma solidity 0.5.17;


/**
 * @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.
 *
 * 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.
 */
contract Ownable {
    address private _owner;

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() internal {
        address msgSender = msg.sender;
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

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

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

    /**
     * @dev Returns true if the caller is the current owner.
     */
    function isOwner() public view returns (bool) {
        return msg.sender == _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 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 onlyOwner {
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     */
    function _transferOwnership(address newOwner) internal {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

/**
 * @title Roles
 * @dev Library for managing addresses assigned to a Role.
 */
library Roles {
    struct Role {
        mapping(address => bool) bearer;
    }

    /**
     * @dev Give an account access to this role.
     */
    function add(Role storage _role, address _account) internal {
        require(!has(_role, _account), "Roles: account already has role");
        _role.bearer[_account] = true;
    }

    /**
     * @dev Remove an account's access to this role.
     */
    function remove(Role storage _role, address _account) internal {
        require(has(_role, _account), "Roles: account does not have role");
        _role.bearer[_account] = false;
    }

    /**
     * @dev Check if an account has this role.
     * @return bool
     */
    function has(Role storage _role, address _account) internal view returns (bool) {
        require(_account != address(0), "Roles: account is the zero address");
        return _role.bearer[_account];
    }
}

contract Operator is Ownable {
    using Roles for Roles.Role;

    Roles.Role private _operators;

    event OperatorAdded(address indexed account);
    event OperatorRemoved(address indexed account);

    function isOperator(address _account) public view returns (bool) {
        return _operators.has(_account);
    }

    function addOperator(address _account) external onlyOwner {
        _addOperator(_account);
    }

    function removeOperator(address _account) external onlyOwner {
        _removeOperator(_account);
    }

    function renounceOperator() external {
        _removeOperator(msg.sender);
    }

    function _addOperator(address _account) internal {
        _operators.add(_account);
        emit OperatorAdded(_account);
    }

    function _removeOperator(address _account) internal {
        _operators.remove(_account);
        emit OperatorRemoved(_account);
    }
}

/**
 * @dev Contract module which allows children to implement an emergency stop
 * mechanism that can be triggered by an authorized account.
 *
 * This module is used through inheritance. It will make available the
 * modifiers `whenNotPaused` and `whenPaused`, which can be applied to
 * the functions of your contract. Note that they will not be pausable by
 * simply including this module, only once the modifiers are put in place.
 */
contract Pausable is Ownable {
    /**
     * @dev Emitted when the pause is triggered by a pauser (`account`).
     */
    event Paused(address account);

    /**
     * @dev Emitted when the pause is lifted by a pauser (`account`).
     */
    event Unpaused(address account);

    bool private _paused;

    /**
     * @dev Initializes the contract in unpaused state. Assigns the Pauser role
     * to the deployer.
     */
    constructor() internal {
        _paused = false;
    }

    /**
     * @dev Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view returns (bool) {
        return _paused;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is not paused.
     */
    modifier whenNotPaused() {
        require(!_paused, "Pausable: paused");
        _;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     */
    modifier whenPaused() {
        require(_paused, "Pausable: not paused");
        _;
    }

    /**
     * @dev Called by a pauser to pause, triggers stopped state.
     */
    function pause() external onlyOwner whenNotPaused {
        _paused = true;
        emit Paused(msg.sender);
    }

    /**
     * @dev Called by a pauser to unpause, returns to normal state.
     */
    function unpause() external onlyOwner whenPaused {
        _paused = false;
        emit Unpaused(msg.sender);
    }
}

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

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
contract IERC721 is IERC165 {
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

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

    /**
     * @dev Returns the owner of the NFT specified by `tokenId`.
     */
    function ownerOf(uint256 tokenId) public view returns (address owner);

    /**
     * @dev Transfers a specific NFT (`tokenId`) from one account (`from`) to
     * another (`to`).
     *
     *
     *
     * Requirements:
     * - `from`, `to` cannot be zero.
     * - `tokenId` must be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this
     * NFT by either {approve} or {setApprovalForAll}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public;

    /**
     * @dev Transfers a specific NFT (`tokenId`) from one account (`from`) to
     * another (`to`).
     *
     * Requirements:
     * - If the caller is not `from`, it must be approved to move this NFT by
     * either {approve} or {setApprovalForAll}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public;

    function approve(address to, uint256 tokenId) public;

    function getApproved(uint256 tokenId) public view returns (address operator);

    function setApprovalForAll(address operator, bool _approved) public;

    function isApprovedForAll(address owner, address operator) public view returns (bool);

    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public;
}

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
contract IERC721Receiver {
    /**
     * @notice Handle the receipt of an NFT
     * @dev The ERC721 smart contract calls this function on the recipient
     * after a {IERC721-safeTransferFrom}. This function MUST return the function selector,
     * otherwise the caller will revert the transaction. The selector to be
     * returned can be obtained as `this.onERC721Received.selector`. This
     * function MAY throw to revert and reject the transfer.
     * Note: the ERC721 contract address is always the message sender.
     * @param operator The address which called `safeTransferFrom` function
     * @param from The address which previously owned the token
     * @param tokenId The NFT identifier which is being transferred
     * @param data Additional data with no specified format
     * @return bytes4 `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes memory data
    ) public returns (bytes4);
}

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

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

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     * - Subtraction cannot overflow.
     *
     * _Available since v2.4.0._
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

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

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     *
     * _Available since v2.4.0._
     */
    function div(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

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

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     * - The divisor cannot be zero.
     *
     * _Available since v2.4.0._
     */
    function mod(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}

/**
 * @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) {
        // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
        // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
        // for accounts without code, i.e. `keccak256('')`
        bytes32 codehash;
        bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
        // solhint-disable-next-line no-inline-assembly
        assembly {
            codehash := extcodehash(account)
        }
        return (codehash != accountHash && codehash != 0x0);
    }

    /**
     * @dev Converts an `address` into `address payable`. Note that this is
     * simply a type cast: the actual underlying value is not changed.
     *
     * _Available since v2.4.0._
     */
    function toPayable(address account) internal pure returns (address payable) {
        return address(uint160(account));
    }

    /**
     * @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].
     *
     * _Available since v2.4.0._
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-call-value
        (bool success, ) = recipient.call.value(amount)("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }
}

/**
 * @title Counters
 * @author Matt Condon (@shrugs)
 * @dev Provides counters that can only be incremented or decremented by one. This can be used e.g. to track the number
 * of elements in a mapping, issuing ERC721 ids, or counting request ids.
 *
 * Include with `using Counters for Counters.Counter;`
 * Since it is not possible to overflow a 256 bit integer with increments of one, `increment` can skip the {SafeMath}
 * overflow check, thereby saving gas. This does assume however correct usage, in that the underlying `_value` is never
 * directly accessed.
 */
library Counters {
    using SafeMath for uint256;

    struct Counter {
        // This variable should never be directly accessed by users of the library: interactions must be restricted to
        // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
        // this feature: see https://github.com/ethereum/solidity/issues/4637
        uint256 _value; // default: 0
    }

    function current(Counter storage counter) internal view returns (uint256) {
        return counter._value;
    }

    function increment(Counter storage counter) internal {
        // The {SafeMath} overflow check can be skipped here, see the comment at the top
        counter._value += 1;
    }

    function decrement(Counter storage counter) internal {
        counter._value = counter._value.sub(1);
    }
}

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts may inherit from this and call {_registerInterface} to declare
 * their support of an interface.
 */
contract ERC165 is IERC165 {
    /*
     * bytes4(keccak256('supportsInterface(bytes4)')) == 0x01ffc9a7
     */
    bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7;

    /**
     * @dev Mapping of interface ids to whether or not it's supported.
     */
    mapping(bytes4 => bool) private _supportedInterfaces;

    constructor() internal {
        // Derived contracts need only register support for their own interfaces,
        // we register support for ERC165 itself here
        _registerInterface(_INTERFACE_ID_ERC165);
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     *
     * Time complexity O(1), guaranteed to always use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool) {
        return _supportedInterfaces[interfaceId];
    }

    /**
     * @dev Registers the contract as an implementer of the interface defined by
     * `interfaceId`. Support of the actual ERC165 interface is automatic and
     * registering its interface id is not required.
     *
     * See {IERC165-supportsInterface}.
     *
     * Requirements:
     *
     * - `interfaceId` cannot be the ERC165 invalid interface (`0xffffffff`).
     */
    function _registerInterface(bytes4 interfaceId) internal {
        require(interfaceId != 0xffffffff, "ERC165: invalid interface id");
        _supportedInterfaces[interfaceId] = true;
    }
}

/**
 * @title ERC721 Non-Fungible Token Standard basic implementation
 * @dev see https://eips.ethereum.org/EIPS/eip-721
 */
contract ERC721 is ERC165, IERC721 {
    using SafeMath for uint256;
    using Address for address;
    using Counters for Counters.Counter;

    // Equals to `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`
    // which can be also obtained as `IERC721Receiver(0).onERC721Received.selector`
    bytes4 private constant _ERC721_RECEIVED = 0x150b7a02;

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

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

    // Mapping from owner to number of owned token
    mapping(address => Counters.Counter) private _ownedTokensCount;

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

    /*
     *     bytes4(keccak256('balanceOf(address)')) == 0x70a08231
     *     bytes4(keccak256('ownerOf(uint256)')) == 0x6352211e
     *     bytes4(keccak256('approve(address,uint256)')) == 0x095ea7b3
     *     bytes4(keccak256('getApproved(uint256)')) == 0x081812fc
     *     bytes4(keccak256('setApprovalForAll(address,bool)')) == 0xa22cb465
     *     bytes4(keccak256('isApprovedForAll(address,address)')) == 0xe985e9c5
     *     bytes4(keccak256('transferFrom(address,address,uint256)')) == 0x23b872dd
     *     bytes4(keccak256('safeTransferFrom(address,address,uint256)')) == 0x42842e0e
     *     bytes4(keccak256('safeTransferFrom(address,address,uint256,bytes)')) == 0xb88d4fde
     *
     *     => 0x70a08231 ^ 0x6352211e ^ 0x095ea7b3 ^ 0x081812fc ^
     *        0xa22cb465 ^ 0xe985e9c ^ 0x23b872dd ^ 0x42842e0e ^ 0xb88d4fde == 0x80ac58cd
     */
    bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd;

    constructor() public {
        // register the supported interfaces to conform to ERC721 via ERC165
        _registerInterface(_INTERFACE_ID_ERC721);
    }

    /**
     * @dev Gets the balance of the specified address.
     * @param owner address to query the balance of
     * @return uint256 representing the amount owned by the passed address
     */
    function balanceOf(address owner) public view returns (uint256) {
        require(owner != address(0), "ERC721: balance query for the zero address");

        return _ownedTokensCount[owner].current();
    }

    /**
     * @dev Gets the owner of the specified token ID.
     * @param tokenId uint256 ID of the token to query the owner of
     * @return address currently marked as the owner of the given token ID
     */
    function ownerOf(uint256 tokenId) public view returns (address) {
        address owner = _tokenOwner[tokenId];
        require(owner != address(0), "ERC721: owner query for nonexistent token");

        return owner;
    }

    /**
     * @dev Approves another address to transfer the given token ID
     * The zero address indicates there is no approved address.
     * There can only be one approved address per token at a given time.
     * Can only be called by the token owner or an approved operator.
     * @param to address to be approved for the given token ID
     * @param tokenId uint256 ID of the token to be approved
     */
    function approve(address to, uint256 tokenId) public {
        address owner = ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

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

        _tokenApprovals[tokenId] = to;
        emit Approval(owner, to, tokenId);
    }

    /**
     * @dev Gets the approved address for a token ID, or zero if no address set
     * Reverts if the token ID does not exist.
     * @param tokenId uint256 ID of the token to query the approval of
     * @return address currently approved for the given token ID
     */
    function getApproved(uint256 tokenId) public view returns (address) {
        require(_exists(tokenId), "ERC721: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev Sets or unsets the approval of a given operator
     * An operator is allowed to transfer all tokens of the sender on their behalf.
     * @param to operator address to set the approval
     * @param approved representing the status of the approval to be set
     */
    function setApprovalForAll(address to, bool approved) public {
        require(to != msg.sender, "ERC721: approve to caller");

        _operatorApprovals[msg.sender][to] = approved;
        emit ApprovalForAll(msg.sender, to, approved);
    }

    /**
     * @dev Tells whether an operator is approved by a given owner.
     * @param owner owner address which you want to query the approval of
     * @param operator operator address which you want to query the approval of
     * @return bool whether the given operator is approved by the given owner
     */
    function isApprovedForAll(address owner, address operator) public view returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev Transfers the ownership of a given token ID to another address.
     * Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     * Requires the msg.sender to be the owner, approved, or operator.
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(msg.sender, tokenId), "ERC721: transfer caller is not owner nor approved");

        _transferFrom(from, to, tokenId);
    }

    /**
     * @dev Safely transfers the ownership of a given token ID to another address
     * If the target address is a contract, it must implement {IERC721Receiver-onERC721Received},
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev Safely transfers the ownership of a given token ID to another address
     * If the target address is a contract, it must implement {IERC721Receiver-onERC721Received},
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes data to send along with a safe transfer check
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public {
        require(_isApprovedOrOwner(msg.sender, tokenId), "ERC721: transfer caller is not owner nor approved");
        _safeTransferFrom(from, to, tokenId, _data);
    }

    /**
     * @dev Safely transfers the ownership of a given token ID to another address
     * If the target address is a contract, it must implement `onERC721Received`,
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes data to send along with a safe transfer check
     */
    function _safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal {
        _transferFrom(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns whether the specified token exists.
     * @param tokenId uint256 ID of the token to query the existence of
     * @return bool whether the token exists
     */
    function _exists(uint256 tokenId) internal view returns (bool) {
        address owner = _tokenOwner[tokenId];
        return owner != address(0);
    }

    /**
     * @dev Returns whether the given spender can transfer a given token ID.
     * @param spender address of the spender to query
     * @param tokenId uint256 ID of the token to be transferred
     * @return bool whether the msg.sender is approved for the given token ID,
     * is an operator of the owner, or is the owner of the token
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view returns (bool) {
        require(_exists(tokenId), "ERC721: operator query for nonexistent token");
        address owner = ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Internal function to safely mint a new token.
     * Reverts if the given token ID already exists.
     * If the target address is a contract, it must implement `onERC721Received`,
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * @param to The address that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     */
    function _safeMint(address to, uint256 tokenId) internal {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Internal function to safely mint a new token.
     * Reverts if the given token ID already exists.
     * If the target address is a contract, it must implement `onERC721Received`,
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * @param to The address that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     * @param _data bytes data to send along with a safe transfer check
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal {
        _mint(to, tokenId);
        require(_checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Internal function to mint a new token.
     * Reverts if the given token ID already exists.
     * @param to The address that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     */
    function _mint(address to, uint256 tokenId) internal {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _tokenOwner[tokenId] = to;
        _ownedTokensCount[to].increment();

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

    /**
     * @dev Internal function to burn a specific token.
     * Reverts if the token does not exist.
     * Deprecated, use {_burn} instead.
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(address owner, uint256 tokenId) internal {
        require(ownerOf(tokenId) == owner, "ERC721: burn of token that is not own");

        _clearApproval(tokenId);

        _ownedTokensCount[owner].decrement();
        _tokenOwner[tokenId] = address(0);

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

    /**
     * @dev Internal function to burn a specific token.
     * Reverts if the token does not exist.
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(uint256 tokenId) internal {
        _burn(ownerOf(tokenId), tokenId);
    }

    /**
     * @dev Internal function to transfer ownership of a given token ID to another address.
     * As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function _transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) internal {
        require(ownerOf(tokenId) == from, "ERC721: transfer of token that is not own");
        require(to != address(0), "ERC721: transfer to the zero address");

        _clearApproval(tokenId);

        _ownedTokensCount[from].decrement();
        _ownedTokensCount[to].increment();

        _tokenOwner[tokenId] = to;

        emit Transfer(from, to, tokenId);
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a contract.
     *
     * This is an internal detail of the `ERC721` contract and its use is deprecated.
     * @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
    ) internal returns (bool) {
        if (!to.isContract()) {
            return true;
        }
        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = to.call(
            abi.encodeWithSelector(IERC721Receiver(to).onERC721Received.selector, msg.sender, from, tokenId, _data)
        );
        if (!success) {
            if (returndata.length > 0) {
                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert("ERC721: transfer to non ERC721Receiver implementer");
            }
        } else {
            bytes4 retval = abi.decode(returndata, (bytes4));
            return (retval == _ERC721_RECEIVED);
        }
    }

    /**
     * @dev Private function to clear current approval of a given token ID.
     * @param tokenId uint256 ID of the token to be transferred
     */
    function _clearApproval(uint256 tokenId) private {
        if (_tokenApprovals[tokenId] != address(0)) {
            _tokenApprovals[tokenId] = address(0);
        }
    }
}

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
contract IERC721Enumerable is IERC721 {
    function totalSupply() public view returns (uint256);
}

/**
 * @title ERC-721 Non-Fungible Token with optional enumeration extension logic
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
contract ERC721Enumerable is ERC165, ERC721, IERC721Enumerable {
    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    /*
     *     bytes4(keccak256('totalSupply()')) == 0x18160ddd
     *     bytes4(keccak256('tokenOfOwnerByIndex(address,uint256)')) == 0x2f745c59
     *     bytes4(keccak256('tokenByIndex(uint256)')) == 0x4f6ccce7
     *
     *     => 0x18160ddd ^ 0x2f745c59 ^ 0x4f6ccce7 == 0x780e9d63
     */
    bytes4 private constant _INTERFACE_ID_ERC721_ENUMERABLE = 0x780e9d63;

    /**
     * @dev Constructor function.
     */
    constructor() public {
        // register the supported interface to conform to ERC721Enumerable via ERC165
        _registerInterface(_INTERFACE_ID_ERC721_ENUMERABLE);
    }

    /**
     * @dev Gets the total amount of tokens stored by the contract.
     * @return uint256 representing the total amount of tokens
     */
    function totalSupply() public view returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev Internal function to mint a new token.
     * Reverts if the given token ID already exists.
     * @param to address the beneficiary that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     */
    function _mint(address to, uint256 tokenId) internal {
        super._mint(to, tokenId);

        _addTokenToAllTokensEnumeration(tokenId);
    }

    /**
     * @dev Internal function to burn a specific token.
     * Reverts if the token does not exist.
     * Deprecated, use {ERC721-_burn} instead.
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(address owner, uint256 tokenId) internal {
        super._burn(owner, tokenId);

        _removeTokenFromAllTokensEnumeration(tokenId);
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length.sub(1);
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        _allTokens.length--;
        _allTokensIndex[tokenId] = 0;
    }
}

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

    function symbol() external view returns (string memory);

    function tokenURI(uint256 tokenId) external view returns (string memory);
}

contract ERC721Metadata is ERC165, ERC721, IERC721Metadata {
    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Base URI
    string private _baseURI;

    // Optional mapping for token URIs
    mapping(uint256 => string) private _tokenURIs;

    /*
     *     bytes4(keccak256('name()')) == 0x06fdde03
     *     bytes4(keccak256('symbol()')) == 0x95d89b41
     *     bytes4(keccak256('tokenURI(uint256)')) == 0xc87b56dd
     *
     *     => 0x06fdde03 ^ 0x95d89b41 ^ 0xc87b56dd == 0x5b5e139f
     */
    bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f;

    /**
     * @dev Constructor function
     */
    constructor(string memory name, string memory symbol) public {
        _name = name;
        _symbol = symbol;

        // register the supported interfaces to conform to ERC721 via ERC165
        _registerInterface(_INTERFACE_ID_ERC721_METADATA);
    }

    /**
     * @dev Gets the token name.
     * @return string representing the token name
     */
    function name() external view returns (string memory) {
        return _name;
    }

    /**
     * @dev Gets the token symbol.
     * @return string representing the token symbol
     */
    function symbol() external view returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the URI for a given token ID. May return an empty string.
     *
     * If the token's URI is non-empty and a base URI was set (via
     * {_setBaseURI}), it will be added to the token ID's URI as a prefix.
     *
     * Reverts if the token ID does not exist.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");

        string memory _tokenURI = _tokenURIs[tokenId];

        // Even if there is a base URI, it is only appended to non-empty token-specific URIs
        if (bytes(_tokenURI).length == 0) {
            return "";
        } else {
            // abi.encodePacked is being used to concatenate strings
            return string(abi.encodePacked(_baseURI, _tokenURI));
        }
    }

    /**
     * @dev Internal function to set the token URI for a given token.
     *
     * Reverts if the token ID does not exist.
     *
     * TIP: if all token IDs share a prefix (e.g. if your URIs look like
     * `http://api.myproject.com/token/<id>`), use {_setBaseURI} to store
     * it and save gas.
     */
    function _setTokenURI(uint256 tokenId, string memory _tokenURI) internal {
        require(_exists(tokenId), "ERC721Metadata: URI set of nonexistent token");
        _tokenURIs[tokenId] = _tokenURI;
    }

    /**
     * @dev Internal function to set the base URI for all token IDs. It is
     * automatically added as a prefix to the value returned in {tokenURI}.
     *
     * _Available since v2.5.0._
     */
    function _setBaseURI(string memory baseURI) internal {
        _baseURI = baseURI;
    }

    /**
     * @dev Returns the base URI set via {_setBaseURI}. This will be
     * automatically added as a preffix in {tokenURI} to each token's URI, when
     * they are non-empty.
     *
     * _Available since v2.5.0._
     */
    function baseURI() external view returns (string memory) {
        return _baseURI;
    }

    /**
     * @dev Internal function to burn a specific token.
     * Reverts if the token does not exist.
     * Deprecated, use _burn(uint256) instead.
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned by the msg.sender
     */
    function _burn(address owner, uint256 tokenId) internal {
        super._burn(owner, tokenId);

        // Clear metadata (if any)
        if (bytes(_tokenURIs[tokenId]).length != 0) {
            delete _tokenURIs[tokenId];
        }
    }
}

/**
 * @title ERC721 Non-Fungible Pausable token
 * @dev ERC721 modified with pausable transfers.
 */
contract ERC721Pausable is ERC721, Pausable {
    function approve(address to, uint256 tokenId) public whenNotPaused {
        super.approve(to, tokenId);
    }

    function setApprovalForAll(address to, bool approved) public whenNotPaused {
        super.setApprovalForAll(to, approved);
    }

    function _transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) internal whenNotPaused {
        super._transferFrom(from, to, tokenId);
    }
}

contract Whitelist is Ownable {
    using Roles for Roles.Role;

    Roles.Role private _whitelists;

    event WhitelistAdded(address indexed account);
    event WhitelistRemoved(address indexed account);

    function isWhitelist(address _account) public view returns (bool) {
        return _whitelists.has(_account);
    }

    function addWhitelist(address _account) external onlyOwner {
        _addWhitelist(_account);
    }

    function removeWhitelist(address _account) external onlyOwner {
        _removeWhitelist(_account);
    }

    function renounceWhitelist() external {
        _removeWhitelist(msg.sender);
    }

    function _addWhitelist(address _account) internal {
        _whitelists.add(_account);
        emit WhitelistAdded(_account);
    }

    function _removeWhitelist(address _account) internal {
        _whitelists.remove(_account);
        emit WhitelistRemoved(_account);
    }
}

contract ERC721Whitelist is ERC721, Whitelist {
    function _transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) internal {
        require(isWhitelist(from) || isWhitelist(to), "ERC721Whitelist: sender or recipient is not whitelist");
        super._transferFrom(from, to, tokenId);
    }
}

/**
 * @title Full ERC721 Token
 * @dev This implementation includes all the required and some optional functionality of the ERC721 standard
 * Moreover, it includes approve all functionality using operator terminology.
 *
 * See https://eips.ethereum.org/EIPS/eip-721
 */
contract ERC721Full is ERC721Enumerable, ERC721Metadata, ERC721Pausable, ERC721Whitelist {
    constructor(string memory name, string memory symbol) public ERC721Metadata(name, symbol) {
        // solhint-disable-previous-line no-empty-blocks
    }
}

/**
 * @dev Interface of the ERC20 standard as defined in the EIP. Does not include
 * the optional functions; to access them see {ERC20Detailed}.
 */
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);
}

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using SafeMath for uint256;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        // solhint-disable-next-line max-line-length
        require((value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance");
        callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender).add(value);
        callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value);
        callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves.

        // A Solidity high level call has three parts:
        //  1. The target address is checked to verify it contains contract code
        //  2. The call itself is made, and success asserted
        //  3. The return value is decoded, which in turn checks the size of the returned data.
        // solhint-disable-next-line max-line-length
        // TODO: implement later
        // require(address(token).isContract(), "SafeERC20: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = address(token).call(data);
        require(success, "SafeERC20: low-level call failed");

        if (returndata.length > 0) {
            // Return data is optional
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

contract GenesisKingdomToken is Operator, ERC721Full {
    using SafeERC20 for IERC20;

    uint256 public constant SYSTEM_FEE_COEFF = 10000; // 10x percent, 10000 = 100%

    struct Order {
        // Order ID - in uuid format
        uint128 id;
        // List of land IDs will be exchanged in this order
        uint128[] landIds;
        // The order maker (in this app it's always seller)
        address maker;
        // The order taker (in this app it's always buyer)
        address taker;
        // The seller's desired currencies. This is actually ERC20 contract address
        // For Ethereum as currency, will use special address 0x0
        address[] offeredCurrencies;
        // The seller's desired amount for each currency respestively
        uint256[] offeredAmounts;
        // The currency that buyer uses to fulfill the order
        address fulfilledCurrency;
        // The amount that buyer uses to fulfill the order
        uint256 fulfilledAmount;
        // The type of order
        OrderType otype;
        // The selling method
        OrderSellingMethod sellingMethod;
        // The status of order
        OrderStatus status;
    }

    struct SystemFee {
        uint128 id;
        // % genesis fee per transaction
        uint256 genesisFee;
        // % inviter reward per transaction
        uint256 inviterReward;
        // % buyer reward per transaction
        uint256 buyerReward;
    }

    enum OrderType { OrderIndividual, OrderBundle }

    enum OrderSellingMethod { Acreage, Freely }

    enum OrderStatus { OPEN, HOLDING, FULFILLED, CANCELLED }

    // storage land name
    mapping(uint128 => bytes32) private _nameOfLands;
    // storage land bundle id
    mapping(uint128 => uint128) private _bundleOfLands;
    // storage orders
    mapping(uint128 => Order) private _orders;
    // storage land id or land bundle id in order
    mapping(uint128 => uint128) private _goodIdOfOrders;
    // storage the order holder
    mapping(uint128 => address) private _orderHolders;
    // storage the processed txid
    mapping(string => bool) private _processedTxids;
    // storage the system fees
    mapping(uint128 => SystemFee) private _systemFees;
    // storage the order system fee
    mapping(uint128 => uint128) private _orderFees;

    // fire when receive token
    event Received(address operator, address from, uint256 tokenId, bytes data, uint256 gas);
    // fire when a new order is created
    event OrderCreate(address operator, uint128 indexed orderId);
    // fire when seller want to update order price, selling method, fee
    event OrderUpdate(address operator, uint128 indexed orderId);
    // fire when seller cancel order
    event OrderCancelled(address operator, uint128 indexed orderId);
    // fire when buyer want to buy order by ether
    event OrderHolding(address holder, uint128 indexed orderId);
    // fire when the operator compelte order
    event OrderFulfilled(address operator, uint128 indexed orderId);
    // fire when a new system fee is created
    event SystemFeeCreate(address operator, uint128 feeId);
    // fire when the owner want to withdrawal ETH or ERC20
    event Withdrawal(address operator, address recepient, address currency, uint256 amount);
    // fire when the operator want to refund ETH or ERC20 to buyer
    event Refund(address receiver, uint128 orderId, address currency, uint256 amount);

    constructor(string memory _name, string memory _symbol) public ERC721Full(_name, _symbol) {
        _addWhitelist(address(this));
    }

    /**
     * ========================================================================================
     * [GET] Land
     */
    /**
     * @dev returns the land detail
     * @param id the land id
     * @return land detail
     */
    function getLandDetail(uint128 id)
        external
        view
        returns (
            uint128 landId,
            uint128 landBundleId,
            bytes32 lname,
            address owner
        )
    {
        landId = id;
        lname = _nameOfLands[landId];
        landBundleId = _bundleOfLands[landId];
        owner = ownerOf(landId);
    }

    /**
     * @dev check the token id has already exists
     * @param id the token id
     * @return bool whether the call correctly returned the expected magic value
     */
    function hasExistentToken(uint128 id) external view returns (bool) {
        return _exists(id);
    }

    /**
     * ========================================================================================
     * [SET] Land
     */
    /**
     * @dev the internal method to issue new land
     * @param _owner the owner of the land
     * @param _id the land id
     * @param _name the land name
     * @param _bundleId the land bundle id
     */
    function _issueNewLand(
        address _owner,
        uint128 _id,
        bytes32 _name,
        uint128 _bundleId
    ) internal {
        require(_bundleId != 0, "GK: invalid bundleId");
        require(_name.length != 0, "GK: invalid landName");

        _nameOfLands[_id] = _name;
        _bundleOfLands[_id] = _bundleId;

        _mint(_owner, _id);
    }

    /**
     * @dev issue all lands of the specific bundle
     * @param _owner the owner of the land
     * @param _ids the array of land id
     * @param _names the array of land name
     * @param _bundleId the land bundle id
     */
    function issueNewLandBundle(
        address _owner,
        uint128[] calldata _ids,
        bytes32[] calldata _names,
        uint128 _bundleId
    ) external onlyOwner whenNotPaused {
        require(_ids.length == _names.length, "GK: invalid array length");
        for (uint256 i = 0; i != _ids.length; i++) {
            _issueNewLand(_owner, _ids[i], _names[i], _bundleId);
        }
    }

    /**
     * ========================================================================================
     * [GET] Order
     */
    /**
     * @dev returns the order detail
     * @param _orderId the order id
     * @return the land detail
     */
    function getOrderDetails(uint128 _orderId)
        external
        view
        returns (
            uint128 id,
            uint128[] memory landIds,
            address maker,
            address taker,
            address[] memory offeredCurrencies,
            uint256[] memory offeredAmounts,
            address fulfilledCurrency,
            uint256 fulfilledAmount,
            OrderType otype,
            OrderSellingMethod sellingMethod,
            OrderStatus status
        )
    {
        Order memory order = _orders[_orderId];
        id = order.id;
        landIds = order.landIds;
        maker = order.maker;
        taker = order.taker;
        offeredCurrencies = order.offeredCurrencies;
        offeredAmounts = order.offeredAmounts;
        fulfilledCurrency = order.fulfilledCurrency;
        fulfilledAmount = order.fulfilledAmount;
        otype = order.otype;
        sellingMethod = order.sellingMethod;
        status = order.status;
    }

    /**
     * @dev returns the land id or bundle id in the order
     * @param _orderId the order id
     * @return can be the land id or bundle id
     */
    function getOrderGoodId(uint128 _orderId) external view returns (uint128) {
        return _goodIdOfOrders[_orderId];
    }

    /**
     * @dev returns the system fee in the order
     * @param _orderId the order id
     * @return the system fee id
     */
    function getOrderGenesisFeeId(uint128 _orderId) external view returns (uint128 feeId) {
        return _orderFees[_orderId];
    }

    /**
     * @dev check order id has already exists
     * @param _orderId the order id
     * @return bool whether the call correctly returned the expected magic value
     */
    function hasExistentOrder(uint128 _orderId) external view returns (bool) {
        return _orders[_orderId].id != 0;
    }

    /**
     * ========================================================================================
     * [SET] Order
     */
    function _preValidateOrder(
        uint128 _orderId,
        uint128 _goodId,
        address[] memory _offeredCurrencies,
        uint256[] memory _offeredAmounts,
        uint128 _feeId
    ) internal view {
        require(_orderId != 0, "GK: invalid orderId");
        require(_orders[_orderId].id == 0, "GK: order has already exists");
        require(_goodId != 0, "GK: invalid goodId");
        require(_offeredCurrencies.length == _offeredAmounts.length, "GK: invalid array length");
        require(_systemFees[_feeId].id != 0, "GK: invalid system fee");
    }

    /**
     * @dev the internal method to create new order
     * @param _orderId the order id
     * @param _goodId the land id or bundle id
     * @param _landIds the array of the land id
     * @param _offeredCurrencies the array of the offered currency
     * @param _offeredAmounts the array of the offered amount
     * @param _type the order type
     * @param _sellingMethod the order selling method
     * @param _feeId the system fee id
     */
    function _createOrder(
        uint128 _orderId,
        uint128 _goodId,
        uint128[] memory _landIds,
        address[] memory _offeredCurrencies,
        uint256[] memory _offeredAmounts,
        OrderType _type,
        OrderSellingMethod _sellingMethod,
        uint128 _feeId
    ) internal {
        _orders[_orderId] = Order(
            _orderId,
            _landIds,
            msg.sender,
            address(0),
            _offeredCurrencies,
            _offeredAmounts,
            address(0),
            0,
            _type,
            _sellingMethod,
            OrderStatus.OPEN
        );
        _orderFees[_orderId] = _feeId;
        _goodIdOfOrders[_orderId] = _goodId;

        emit OrderCreate(msg.sender, _orderId);
    }

    /**
     * @dev using for issue and create land bundle order
     * @param _orderId the order id
     * @param _bundleId the land bundle id
     * @param _ids the array of the land id
     * @param _names the array of the land name
     * @param _offeredCurrencies the array of the offered currency
     * @param _offeredAmounts the array of the offered amount
     * @param _sellingMethod the order selling method
     * @param _feeId the system fee id
     */
    function issueAndCreateLandBundleOrder(
        uint128 _orderId,
        uint128 _bundleId,
        uint128[] calldata _ids,
        bytes32[] calldata _names,
        address[] calldata _offeredCurrencies,
        uint256[] calldata _offeredAmounts,
        OrderSellingMethod _sellingMethod,
        uint128 _feeId
    ) external onlyOwner whenNotPaused {
        for (uint256 i = 0; i != _ids.length; i++) {
            _issueNewLand(address(this), _ids[i], _names[i], _bundleId);
        }

        _preValidateOrder(_orderId, _bundleId, _offeredCurrencies, _offeredAmounts, _feeId);

        _createOrder(_orderId, _bundleId, _ids, _offeredCurrencies, _offeredAmounts, OrderType.OrderBundle, _sellingMethod, _feeId);
    }

    /**
     * @dev using for create a new order to sell single land
     * @param _orderId the order id
     * @param _landId the land id
     * @param _offeredCurrencies the array of the offered currency
     * @param _offeredAmounts the array of the offered amount
     * @param _sellingMethod the order selling method
     * @param _feeId the system fee id
     */
    function createSingleLandOrder(
        uint128 _orderId,
        uint128 _landId,
        address[] calldata _offeredCurrencies,
        uint256[] calldata _offeredAmounts,
        OrderSellingMethod _sellingMethod,
        uint128 _feeId
    ) external whenNotPaused {
        uint128[] memory _landIds = new uint128[](1);
        _landIds[0] = _landId;

        _preValidateOrder(_orderId, _landId, _offeredCurrencies, _offeredAmounts, _feeId);

        transferFrom(msg.sender, address(this), _landId);

        _createOrder(_orderId, _landId, _landIds, _offeredCurrencies, _offeredAmounts, OrderType.OrderIndividual, _sellingMethod, _feeId);
    }

    /**
     * @dev using for create a new order to sell land bundle
     * @param _orderId the order id
     * @param _bundleId the land bundle id
     * @param _offeredCurrencies the array of the offered currency
     * @param _offeredAmounts the array of the offered amount
     * @param _sellingMethod the order selling method
     * @param _feeId the system fee id
     */
    function createLandBundleOrder(
        uint128 _orderId,
        uint128 _bundleId,
        uint128[] calldata _landIds,
        address[] calldata _offeredCurrencies,
        uint256[] calldata _offeredAmounts,
        OrderSellingMethod _sellingMethod,
        uint128 _feeId
    ) external whenNotPaused {
        _preValidateOrder(_orderId, _bundleId, _offeredCurrencies, _offeredAmounts, _feeId);

        _batchSafeTransferFrom(address(0), msg.sender, address(this), _landIds);

        _createOrder(_orderId, _bundleId, _landIds, _offeredCurrencies, _offeredAmounts, OrderType.OrderBundle, _sellingMethod, _feeId);
    }

    /**
     * @dev using for update order price, selling method, fee
     * @param _orderId the order id
     * @param _offeredCurrencies the array of the offered currency
     * @param _offeredAmounts the array of the offered amount
     * @param _sellingMethod the order selling method
     * @param _feeId the system fee id
     */
    function updateOrder(
        uint128 _orderId,
        address[] calldata _offeredCurrencies,
        uint256[] calldata _offeredAmounts,
        OrderSellingMethod _sellingMethod,
        uint128 _feeId
    ) external whenNotPaused {
        Order storage order = _orders[_orderId];
        require(order.id != 0, "GK: caller query nonexistent order");
        require(msg.sender == order.maker, "GK: only maker can update order");
        require(order.status == OrderStatus.OPEN, "GK: order not allow to update");
        require(_systemFees[_feeId].id != 0, "GK: invalid system fee");
        require(_offeredCurrencies.length == _offeredAmounts.length, "GK: invalid array length");

        order.offeredCurrencies = _offeredCurrencies;
        order.offeredAmounts = _offeredAmounts;
        order.sellingMethod = _sellingMethod;
        _orderFees[_orderId] = _feeId;

        emit OrderUpdate(msg.sender, order.id);
    }

    /**
     * @dev using for cancel order
     * @param _orderId the order id
     */
    function cancelOrder(uint128 _orderId) external whenNotPaused {
        Order storage order = _orders[_orderId];
        require(order.id != 0, "GK: caller query nonexistent order");
        require(msg.sender == order.maker, "GK: only maker can cancel order");
        require(order.status == OrderStatus.OPEN, "GK: order not allow to cancel");

        if (order.otype == OrderType.OrderIndividual) {
            IERC721(address(this)).safeTransferFrom(address(this), order.maker, order.landIds[0]);
        } else if (order.otype == OrderType.OrderBundle) {
            _batchSafeTransferFrom(address(this), address(this), order.maker, order.landIds);
        }
        order.status = OrderStatus.CANCELLED;

        emit OrderCancelled(msg.sender, order.id);
    }

    /**
     * @dev buyer can take order by staking ether
     * @param _orderId the order id
     */
    function takeOrderByEther(uint128 _orderId) external payable whenNotPaused {
        Order storage order = _orders[_orderId];
        require(order.id != 0, "GK: caller query nonexistent order");
        require(order.maker != msg.sender, "GK: you are owner");
        if (order.status == OrderStatus.OPEN) {
            uint256 _amount = 0;
            for (uint256 i = 0; i != order.offeredCurrencies.length; i++) {
                if (order.offeredCurrencies[i] == address(0)) {
                    _amount = order.offeredAmounts[i];
                    break;
                }
            }
            require(_amount != 0 && msg.value == _amount, "GK: invalid amount");

            order.status = OrderStatus.HOLDING;
            _orderHolders[_orderId] = msg.sender;

            emit OrderHolding(msg.sender, order.id);
        } else {
            // refund ether to buyer
            msg.sender.transfer(msg.value);
            emit Refund(msg.sender, _orderId, address(0), msg.value);
        }
    }

    /**
     * @dev using for complete the order by the system operator
     * @param _orderId the order id
     * @param _taker the buyer address
     * @param _currency the payable currency
     * @param _amount the payable amount
     * @param _txid the taken txid
     */
    function completeOrder(
        uint128 _orderId,
        address _taker,
        address _currency,
        uint256 _amount,
        string calldata _txid
    ) external whenNotPaused {
        require(isOperator(msg.sender), "GK: caller is not operator");
        require(_taker != address(0), "GK: invalid address");
        if (_orderHolders[_orderId] != address(0)) {
            require(_taker == _orderHolders[_orderId], "GK: invalid taker");
        }
        Order storage order = _orders[_orderId];
        require(order.id != 0, "GK: caller query nonexistent order");
        require(order.maker != _taker, "GK: you are owner");
        require(order.status == OrderStatus.OPEN || order.status == OrderStatus.HOLDING, "GK: cannot complete this order");
        require(!_processedTxids[_txid], "GK: txid has processed");

        uint256 amount = 0;
        for (uint256 i = 0; i != order.offeredCurrencies.length; i++) {
            if (_currency == order.offeredCurrencies[i]) {
                amount = order.offeredAmounts[i];
                break;
            }
        }
        require(amount != 0 && amount == _amount, "GK: invalid amount");

        uint256 fee = 0;
        if (order.maker != owner()) {
            SystemFee memory sFee = _systemFees[_orderFees[_orderId]];
            fee = _amount.mul(sFee.genesisFee).div(SYSTEM_FEE_COEFF);
        }

        // The transfer amount equals the offer amount sub the genesis fee
        if (_currency == address(0)) {
            // Transfer ether to the seller
            order.maker.toPayable().transfer(amount.sub(fee));
        } else {
            // Transfer erc20 token to the seller
            IERC20(_currency).safeTransfer(order.maker, amount.sub(fee));
        }

        // Transfer the land to buyer
        if (order.otype == OrderType.OrderIndividual) {
            IERC721(address(this)).safeTransferFrom(address(this), _taker, order.landIds[0]);
        } else if (order.otype == OrderType.OrderBundle) {
            _batchSafeTransferFrom(address(this), address(this), _taker, order.landIds);
        }

        order.taker = _taker;
        order.fulfilledCurrency = _currency;
        order.fulfilledAmount = amount;
        order.status = OrderStatus.FULFILLED;

        _orderHolders[_orderId] = _taker;
        _processedTxids[_txid] = true;

        emit OrderFulfilled(msg.sender, order.id);
    }

    /**
     * ========================================================================================
     * [GET] System Fee
     */
    /**
     * @dev returns the system fee
     * @param _feeId the system fee id
     * @return the system fee detail
     */
    function getSystemFee(uint128 _feeId)
        external
        view
        returns (
            uint128 feeId,
            uint256 genesisFee,
            uint256 inviterReward,
            uint256 buyerReward
        )
    {
        feeId = _systemFees[_feeId].id;
        genesisFee = _systemFees[_feeId].genesisFee;
        inviterReward = _systemFees[_feeId].inviterReward;
        buyerReward = _systemFees[_feeId].buyerReward;
    }

    /**
     * ========================================================================================
     * [SET] System Fee
     */
    /**
     * @dev using for set a new system fee
     * @param _feeId the system fee id
     * @param _genesisFee the genesis fee percentage
     * @param _inviterReward the inviter reward percentage
     * @param _buyerReward the buyer reward percentage
     */
    function setNewSystemFee(
        uint128 _feeId,
        uint256 _genesisFee,
        uint256 _inviterReward,
        uint256 _buyerReward
    ) external onlyOwner whenNotPaused {
        require(_feeId != 0, "GK: invalid feeId");
        require(_systemFees[_feeId].id == 0, "GK: fee has already exists");

        _systemFees[_feeId] = SystemFee(_feeId, _genesisFee, _inviterReward, _buyerReward);
        emit SystemFeeCreate(msg.sender, _feeId);
    }

    /**
     * ========================================================================================
     * [SET] Withdrawal & Refund
     */
    /**
     * @dev the internal method used to withdrawal ETH or ERC20
     * @param _recepient the receiver address
     * @param _currency the withdrawal currency (can be ETH or ERC20)
     * @param _amount the withdrawl amount
     */
    function _withdrawal(
        address _recepient,
        address _currency,
        uint256 _amount
    ) internal {
        require(_recepient != address(0), "GK: invalid address");
        require(_amount != 0, "GK: invalid amount");
        if (_currency == address(0)) {
            require(address(this).balance >= _amount, "GK: balance not enough");
            _recepient.toPayable().transfer(_amount);
        } else {
            uint256 balance = IERC20(_currency).balanceOf(address(this));
            require(balance >= _amount, "GK: balance not enough");
            IERC20(_currency).safeTransfer(_recepient, _amount);
        }
    }

    /**
     * @dev the owner can use to withdrawal ETH or ERC20
     * @param _recepient the receiver address
     * @param _currency the withdrawal currency (can be ETH or ERC20)
     * @param _amount the withdrawal amount
     */
    function withdrawal(
        address _recepient,
        address _currency,
        uint256 _amount
    ) external onlyOwner {
        _withdrawal(_recepient, _currency, _amount);
        emit Withdrawal(msg.sender, _recepient, _currency, _amount);
    }

    /**
     * @dev the operator can use to refund ETH or ERC20 to buyer
     * @param _orderId the refund order id
     * @param _recepient the receiver address
     * @param _currency the refund currency (can be ETH or ERC20)
     * @param _amount the refund amount
     */
    function refund(
        uint128 _orderId,
        address _recepient,
        address _currency,
        uint256 _amount
    ) external whenNotPaused {
        require(isOperator(msg.sender), "GK: caller is not operator");
        require(_orders[_orderId].id != 0, "GK: caller query nonexistent order");
        _withdrawal(_recepient, _currency, _amount);
        emit Refund(_recepient, _orderId, _currency, _amount);
    }

    /**
     * ========================================================================================
     * [SET] Override ERC721Metadata
     */
    function setTokenURI(uint256 tokenId, string calldata _tokenURI) external onlyOwner {
        super._setTokenURI(tokenId, _tokenURI);
    }

    function setBaseURI(string calldata baseURI) external onlyOwner {
        super._setBaseURI(baseURI);
    }

    /**
     * ========================================================================================
     * [SET] Others
     */
    /**
     * @dev the internal method to transfer multiple tokens
     * @param _token the ERC721 token address
     * @param _from the token holder address
     * @param _recepient the receiver address
     * @param _tokenIds the array of the token
     */
    function _batchSafeTransferFrom(
        address _token,
        address _from,
        address _recepient,
        uint128[] memory _tokenIds
    ) internal {
        for (uint256 i = 0; i != _tokenIds.length; i++) {
            if (_token != address(0)) {
                IERC721(_token).safeTransferFrom(_from, _recepient, _tokenIds[i]);
            } else {
                safeTransferFrom(_from, _recepient, _tokenIds[i]);
            }
        }
    }

    /**
     * ========================================================================================
     * [GET] Callback
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes memory data
    ) public returns (bytes4) {
        emit Received(operator, from, tokenId, data, gasleft());
        return 0x150b7a02;
    }
}

Contract Security Audit

Contract ABI

API
[{"inputs":[{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"}],"payable":false,"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":"account","type":"address"}],"name":"OperatorAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"OperatorRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"uint128","name":"orderId","type":"uint128"}],"name":"OrderCancelled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"uint128","name":"orderId","type":"uint128"}],"name":"OrderCreate","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"uint128","name":"orderId","type":"uint128"}],"name":"OrderFulfilled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"holder","type":"address"},{"indexed":true,"internalType":"uint128","name":"orderId","type":"uint128"}],"name":"OrderHolding","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"uint128","name":"orderId","type":"uint128"}],"name":"OrderUpdate","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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"data","type":"bytes"},{"indexed":false,"internalType":"uint256","name":"gas","type":"uint256"}],"name":"Received","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"receiver","type":"address"},{"indexed":false,"internalType":"uint128","name":"orderId","type":"uint128"},{"indexed":false,"internalType":"address","name":"currency","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Refund","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"uint128","name":"feeId","type":"uint128"}],"name":"SystemFeeCreate","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"WhitelistAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"}],"name":"WhitelistRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"address","name":"recepient","type":"address"},{"indexed":false,"internalType":"address","name":"currency","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdrawal","type":"event"},{"constant":true,"inputs":[],"name":"SYSTEM_FEE_COEFF","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"addOperator","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"addWhitelist","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"cancelOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"address","name":"_taker","type":"address"},{"internalType":"address","name":"_currency","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"string","name":"_txid","type":"string"}],"name":"completeOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"uint128","name":"_bundleId","type":"uint128"},{"internalType":"uint128[]","name":"_landIds","type":"uint128[]"},{"internalType":"address[]","name":"_offeredCurrencies","type":"address[]"},{"internalType":"uint256[]","name":"_offeredAmounts","type":"uint256[]"},{"internalType":"enum GenesisKingdomToken.OrderSellingMethod","name":"_sellingMethod","type":"uint8"},{"internalType":"uint128","name":"_feeId","type":"uint128"}],"name":"createLandBundleOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"uint128","name":"_landId","type":"uint128"},{"internalType":"address[]","name":"_offeredCurrencies","type":"address[]"},{"internalType":"uint256[]","name":"_offeredAmounts","type":"uint256[]"},{"internalType":"enum GenesisKingdomToken.OrderSellingMethod","name":"_sellingMethod","type":"uint8"},{"internalType":"uint128","name":"_feeId","type":"uint128"}],"name":"createSingleLandOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"id","type":"uint128"}],"name":"getLandDetail","outputs":[{"internalType":"uint128","name":"landId","type":"uint128"},{"internalType":"uint128","name":"landBundleId","type":"uint128"},{"internalType":"bytes32","name":"lname","type":"bytes32"},{"internalType":"address","name":"owner","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"getOrderDetails","outputs":[{"internalType":"uint128","name":"id","type":"uint128"},{"internalType":"uint128[]","name":"landIds","type":"uint128[]"},{"internalType":"address","name":"maker","type":"address"},{"internalType":"address","name":"taker","type":"address"},{"internalType":"address[]","name":"offeredCurrencies","type":"address[]"},{"internalType":"uint256[]","name":"offeredAmounts","type":"uint256[]"},{"internalType":"address","name":"fulfilledCurrency","type":"address"},{"internalType":"uint256","name":"fulfilledAmount","type":"uint256"},{"internalType":"enum GenesisKingdomToken.OrderType","name":"otype","type":"uint8"},{"internalType":"enum GenesisKingdomToken.OrderSellingMethod","name":"sellingMethod","type":"uint8"},{"internalType":"enum GenesisKingdomToken.OrderStatus","name":"status","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"getOrderGenesisFeeId","outputs":[{"internalType":"uint128","name":"feeId","type":"uint128"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"getOrderGoodId","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"_feeId","type":"uint128"}],"name":"getSystemFee","outputs":[{"internalType":"uint128","name":"feeId","type":"uint128"},{"internalType":"uint256","name":"genesisFee","type":"uint256"},{"internalType":"uint256","name":"inviterReward","type":"uint256"},{"internalType":"uint256","name":"buyerReward","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"hasExistentOrder","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint128","name":"id","type":"uint128"}],"name":"hasExistentToken","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isOperator","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"isWhitelist","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"uint128","name":"_bundleId","type":"uint128"},{"internalType":"uint128[]","name":"_ids","type":"uint128[]"},{"internalType":"bytes32[]","name":"_names","type":"bytes32[]"},{"internalType":"address[]","name":"_offeredCurrencies","type":"address[]"},{"internalType":"uint256[]","name":"_offeredAmounts","type":"uint256[]"},{"internalType":"enum GenesisKingdomToken.OrderSellingMethod","name":"_sellingMethod","type":"uint8"},{"internalType":"uint128","name":"_feeId","type":"uint128"}],"name":"issueAndCreateLandBundleOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"uint128[]","name":"_ids","type":"uint128[]"},{"internalType":"bytes32[]","name":"_names","type":"bytes32[]"},{"internalType":"uint128","name":"_bundleId","type":"uint128"}],"name":"issueNewLandBundle","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onERC721Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"pause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"address","name":"_recepient","type":"address"},{"internalType":"address","name":"_currency","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"refund","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"removeOperator","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"removeWhitelist","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceOperator","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceWhitelist","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"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":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"string","name":"baseURI","type":"string"}],"name":"setBaseURI","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_feeId","type":"uint128"},{"internalType":"uint256","name":"_genesisFee","type":"uint256"},{"internalType":"uint256","name":"_inviterReward","type":"uint256"},{"internalType":"uint256","name":"_buyerReward","type":"uint256"}],"name":"setNewSystemFee","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"_tokenURI","type":"string"}],"name":"setTokenURI","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"}],"name":"takeOrderByEther","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"unpause","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"uint128","name":"_orderId","type":"uint128"},{"internalType":"address[]","name":"_offeredCurrencies","type":"address[]"},{"internalType":"uint256[]","name":"_offeredAmounts","type":"uint256[]"},{"internalType":"enum GenesisKingdomToken.OrderSellingMethod","name":"_sellingMethod","type":"uint8"},{"internalType":"uint128","name":"_feeId","type":"uint128"}],"name":"updateOrder","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"_recepient","type":"address"},{"internalType":"address","name":"_currency","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdrawal","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"}]

60806040523480156200001157600080fd5b506040516200652038038062006520833981810160405260408110156200003757600080fd5b81019080805160405193929190846401000000008211156200005857600080fd5b9083019060208201858111156200006e57600080fd5b82516401000000008111828201881017156200008957600080fd5b82525081516020918201929091019080838360005b83811015620000b85781810151838201526020016200009e565b50505050905090810190601f168015620000e65780820380516001836020036101000a031916815260200191505b50604052602001805160405193929190846401000000008211156200010a57600080fd5b9083019060208201858111156200012057600080fd5b82516401000000008111828201881017156200013b57600080fd5b82525081516020918201929091019080838360005b838110156200016a57818101518382015260200162000150565b50505050905090810190601f168015620001985780820380516001836020036101000a031916815260200191505b50604052508391508290508181620001c06301ffc9a760e01b6001600160e01b03620002aa16565b620001db6380ac58cd60e01b6001600160e01b03620002aa16565b620001f663780e9d6360e01b6001600160e01b03620002aa16565b81516200020b90600790602085019062000477565b5080516200022190600890602084019062000477565b506200023d635b5e139f60e01b6001600160e01b03620002aa16565b5050600b80546001600160a01b0319163390811790915560405181906000907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35050600d805460ff1916905550620002a2306001600160e01b036200032f16565b50506200051c565b6001600160e01b031980821614156200030a576040805162461bcd60e51b815260206004820152601c60248201527f4552433136353a20696e76616c696420696e7465726661636520696400000000604482015290519081900360640190fd5b6001600160e01b0319166000908152602081905260409020805460ff19166001179055565b6200034a81600e6200038160201b620050b21790919060201c565b6040516001600160a01b038216907f4790a4adb426ca2345bb5108f6e454eae852a7bf687544cd66a7270dff3a41d690600090a250565b6200039682826001600160e01b036200040e16565b15620003e9576040805162461bcd60e51b815260206004820152601f60248201527f526f6c65733a206163636f756e7420616c72656164792068617320726f6c6500604482015290519081900360640190fd5b6001600160a01b0316600090815260209190915260409020805460ff19166001179055565b60006001600160a01b038216620004575760405162461bcd60e51b8152600401808060200182810382526022815260200180620064fe6022913960400191505060405180910390fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620004ba57805160ff1916838001178555620004ea565b82800160010185558215620004ea579182015b82811115620004ea578251825591602001919060010190620004cd565b50620004f8929150620004fc565b5090565b6200051991905b80821115620004f8576000815560010162000503565b90565b615fd2806200052c6000396000f3fe6080604052600436106102fe5760003560e01c80637de6a11211610190578063b7f16965116100dc578063da9403cb11610095578063e81398431161006f578063e8139843146114fc578063e985e9c51461152f578063f2fde38b1461156a578063f80f5dd51461159d576102fe565b8063da9403cb146113bd578063dbc9139614611466578063dc332cbd14611499576102fe565b8063b7f1696514611114578063b88d4fde14611166578063c593c5c914611237578063c683630d1461132d578063c87b56dd14611360578063d28bc1501461138a576102fe565b806395d89b4111610149578063a22cb46511610123578063a22cb4651461106b578063ac19f00b146110a6578063ac8a584a146110cc578063b371c17f146110ff576102fe565b806395d89b4114610ff05780639870d7fe14611005578063a0e2718a14611038576102fe565b80637de6a11214610be75780638456cb5914610d2d5780638da5cb5b14610d425780638f32d59b14610d5757806391095ed714610d6c5780639370be1a14610f03576102fe565b806339137f8b1161024f5780636b8136751161020857806370a08231116101e257806370a0823114610b1d578063715018a614610b5057806378c8cda714610b65578063790e2ee614610b98576102fe565b80636b813675146109465780636c0360eb14610ad55780636d70f7ae14610aea576102fe565b806339137f8b1461081f5780633f4ba83a1461083457806342842e0e1461084957806355f804b31461088c5780635c975abb146109075780636352211e1461091c576102fe565b8063162094c4116102bc578063213ea55c11610296578063213ea55c1461067557806323b872dd1461075957806329c5c0ae1461079c5780632ab6f8db1461080a576102fe565b8063162094c41461058757806317d4095f1461060957806318160ddd1461064e576102fe565b806229c0b41461030357806301ffc9a71461034857806306fdde0314610390578063081812fc1461041a578063095ea7b314610460578063150b7a0214610499575b600080fd5b34801561030f57600080fd5b506103466004803603606081101561032657600080fd5b506001600160a01b038135811691602081013590911690604001356115d0565b005b34801561035457600080fd5b5061037c6004803603602081101561036b57600080fd5b50356001600160e01b031916611677565b604080519115158252519081900360200190f35b34801561039c57600080fd5b506103a561169a565b6040805160208082528351818301528351919283929083019185019080838360005b838110156103df5781810151838201526020016103c7565b50505050905090810190601f16801561040c5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561042657600080fd5b506104446004803603602081101561043d57600080fd5b5035611731565b604080516001600160a01b039092168252519081900360200190f35b34801561046c57600080fd5b506103466004803603604081101561048357600080fd5b506001600160a01b038135169060200135611793565b3480156104a557600080fd5b5061056a600480360360808110156104bc57600080fd5b6001600160a01b03823581169260208101359091169160408201359190810190608081016060820135600160201b8111156104f657600080fd5b82018360208201111561050857600080fd5b803590602001918460018302840111600160201b8311171561052957600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506117ec945050505050565b604080516001600160e01b03199092168252519081900360200190f35b34801561059357600080fd5b50610346600480360360408110156105aa57600080fd5b81359190810190604081016020820135600160201b8111156105cb57600080fd5b8201836020820111156105dd57600080fd5b803590602001918460018302840111600160201b831117156105fe57600080fd5b5090925090506118dd565b34801561061557600080fd5b506103466004803603608081101561062c57600080fd5b506001600160801b038135169060208101359060408101359060600135611969565b34801561065a57600080fd5b50610663611b5d565b60408051918252519081900360200190f35b34801561068157600080fd5b506103466004803603608081101561069857600080fd5b6001600160a01b038235169190810190604081016020820135600160201b8111156106c257600080fd5b8201836020820111156106d457600080fd5b803590602001918460208302840111600160201b831117156106f557600080fd5b919390929091602081019035600160201b81111561071257600080fd5b82018360208201111561072457600080fd5b803590602001918460208302840111600160201b8311171561074557600080fd5b9193509150356001600160801b0316611b63565b34801561076557600080fd5b506103466004803603606081101561077c57600080fd5b506001600160a01b03813581169160208101359091169060400135611c98565b3480156107a857600080fd5b506107cf600480360360208110156107bf57600080fd5b50356001600160801b0316611ce8565b604080516001600160801b039586168152939094166020840152828401919091526001600160a01b0316606082015290519081900360800190f35b34801561081657600080fd5b50610346611d26565b34801561082b57600080fd5b50610346611d31565b34801561084057600080fd5b50610346611d3a565b34801561085557600080fd5b506103466004803603606081101561086c57600080fd5b506001600160a01b03813581169160208101359091169060400135611e0e565b34801561089857600080fd5b50610346600480360360208110156108af57600080fd5b810190602081018135600160201b8111156108c957600080fd5b8201836020820111156108db57600080fd5b803590602001918460018302840111600160201b831117156108fc57600080fd5b509092509050611e29565b34801561091357600080fd5b5061037c611eaf565b34801561092857600080fd5b506104446004803603602081101561093f57600080fd5b5035611eb8565b34801561095257600080fd5b506109796004803603602081101561096957600080fd5b50356001600160801b0316611f12565b604080516001600160801b038d1681526001600160a01b03808c1692820192909252898216606082015290861660c082015260e08101859052602081016080820160a0830161010084018760018111156109cf57fe5b60ff1681526020018660018111156109e357fe5b60ff1681526020018560038111156109f757fe5b60ff16815260200184810384528e818151815260200191508051906020019060200280838360005b83811015610a37578181015183820152602001610a1f565b5050505090500184810383528b818151815260200191508051906020019060200280838360005b83811015610a76578181015183820152602001610a5e565b5050505090500184810382528a818151815260200191508051906020019060200280838360005b83811015610ab5578181015183820152602001610a9d565b505050509050019e50505050505050505050505050505060405180910390f35b348015610ae157600080fd5b506103a56121c4565b348015610af657600080fd5b5061037c60048036036020811015610b0d57600080fd5b50356001600160a01b0316612225565b348015610b2957600080fd5b5061066360048036036020811015610b4057600080fd5b50356001600160a01b0316612238565b348015610b5c57600080fd5b506103466122a0565b348015610b7157600080fd5b5061034660048036036020811015610b8857600080fd5b50356001600160a01b0316612331565b348015610ba457600080fd5b50610bcb60048036036020811015610bbb57600080fd5b50356001600160801b0316612384565b604080516001600160801b039092168252519081900360200190f35b348015610bf357600080fd5b50610346600480360360e0811015610c0a57600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b811115610c3d57600080fd5b820183602082011115610c4f57600080fd5b803590602001918460208302840111600160201b83111715610c7057600080fd5b919390929091602081019035600160201b811115610c8d57600080fd5b820183602082011115610c9f57600080fd5b803590602001918460208302840111600160201b83111715610cc057600080fd5b919390929091602081019035600160201b811115610cdd57600080fd5b820183602082011115610cef57600080fd5b803590602001918460208302840111600160201b83111715610d1057600080fd5b9193509150803560ff1690602001356001600160801b03166123a2565b348015610d3957600080fd5b50610346612550565b348015610d4e57600080fd5b50610444612624565b348015610d6357600080fd5b5061037c612633565b348015610d7857600080fd5b506103466004803603610100811015610d9057600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b811115610dc357600080fd5b820183602082011115610dd557600080fd5b803590602001918460208302840111600160201b83111715610df657600080fd5b919390929091602081019035600160201b811115610e1357600080fd5b820183602082011115610e2557600080fd5b803590602001918460208302840111600160201b83111715610e4657600080fd5b919390929091602081019035600160201b811115610e6357600080fd5b820183602082011115610e7557600080fd5b803590602001918460208302840111600160201b83111715610e9657600080fd5b919390929091602081019035600160201b811115610eb357600080fd5b820183602082011115610ec557600080fd5b803590602001918460208302840111600160201b83111715610ee657600080fd5b9193509150803560ff1690602001356001600160801b0316612644565b348015610f0f57600080fd5b50610346600480360360a0811015610f2657600080fd5b6001600160801b038235169190810190604081016020820135600160201b811115610f5057600080fd5b820183602082011115610f6257600080fd5b803590602001918460208302840111600160201b83111715610f8357600080fd5b919390929091602081019035600160201b811115610fa057600080fd5b820183602082011115610fb257600080fd5b803590602001918460208302840111600160201b83111715610fd357600080fd5b9193509150803560ff1690602001356001600160801b0316612847565b348015610ffc57600080fd5b506103a5612b1b565b34801561101157600080fd5b506103466004803603602081101561102857600080fd5b50356001600160a01b0316612b7c565b34801561104457600080fd5b50610bcb6004803603602081101561105b57600080fd5b50356001600160801b0316612bcc565b34801561107757600080fd5b506103466004803603604081101561108e57600080fd5b506001600160a01b0381351690602001351515612bea565b610346600480360360208110156110bc57600080fd5b50356001600160801b0316612c3f565b3480156110d857600080fd5b50610346600480360360208110156110ef57600080fd5b50356001600160a01b0316612f1d565b34801561110b57600080fd5b50610663612f6d565b34801561112057600080fd5b506103466004803603608081101561113757600080fd5b506001600160801b03813516906001600160a01b03602082013581169160408101359091169060600135612f73565b34801561117257600080fd5b506103466004803603608081101561118957600080fd5b6001600160a01b03823581169260208101359091169160408201359190810190608081016060820135600160201b8111156111c357600080fd5b8201836020820111156111d557600080fd5b803590602001918460018302840111600160201b831117156111f657600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506130d8945050505050565b34801561124357600080fd5b50610346600480360360c081101561125a57600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b81111561128d57600080fd5b82018360208201111561129f57600080fd5b803590602001918460208302840111600160201b831117156112c057600080fd5b919390929091602081019035600160201b8111156112dd57600080fd5b8201836020820111156112ef57600080fd5b803590602001918460208302840111600160201b8311171561131057600080fd5b9193509150803560ff1690602001356001600160801b031661312f565b34801561133957600080fd5b5061037c6004803603602081101561135057600080fd5b50356001600160a01b03166132cd565b34801561136c57600080fd5b506103a56004803603602081101561138357600080fd5b50356132e0565b34801561139657600080fd5b5061037c600480360360208110156113ad57600080fd5b50356001600160801b03166134ac565b3480156113c957600080fd5b50610346600480360360a08110156113e057600080fd5b6001600160801b03823516916001600160a01b03602082013581169260408301359091169160608101359181019060a081016080820135600160201b81111561142857600080fd5b82018360208201111561143a57600080fd5b803590602001918460018302840111600160201b8311171561145b57600080fd5b5090925090506134c0565b34801561147257600080fd5b506103466004803603602081101561148957600080fd5b50356001600160801b0316613c82565b3480156114a557600080fd5b506114cc600480360360208110156114bc57600080fd5b50356001600160801b0316613fb6565b604080516001600160801b0390951685526020850193909352838301919091526060830152519081900360800190f35b34801561150857600080fd5b5061037c6004803603602081101561151f57600080fd5b50356001600160801b0316613fe8565b34801561153b57600080fd5b5061037c6004803603604081101561155257600080fd5b506001600160a01b0381358116916020013516614008565b34801561157657600080fd5b506103466004803603602081101561158d57600080fd5b50356001600160a01b0316614036565b3480156115a957600080fd5b50610346600480360360208110156115c057600080fd5b50356001600160a01b0316614086565b6115d8612633565b611617576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6116228383836140d6565b604080513381526001600160a01b0380861660208301528416818301526060810183905290517f342e7ff505a8a0364cd0dc2ff195c315e43bce86b204846ecd36913e117b109e9181900360800190a1505050565b6001600160e01b0319811660009081526020819052604090205460ff165b919050565b60078054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b820191906000526020600020905b81548152906001019060200180831161170957829003601f168201915b505050505090505b90565b600061173c826142fa565b6117775760405162461bcd60e51b815260040180806020018281038252602c815260200180615e30602c913960400191505060405180910390fd5b506000908152600260205260409020546001600160a01b031690565b600d5460ff16156117de576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6117e88282614317565b5050565b60007f28fa6e16458f9c24aa59ddd4085264573006dbe30304837873c7deafc702b038858585855a60405180866001600160a01b03166001600160a01b03168152602001856001600160a01b03166001600160a01b0316815260200184815260200180602001838152602001828103825284818151815260200191508051906020019080838360005b8381101561188d578181015183820152602001611875565b50505050905090810190601f1680156118ba5780820380516001836020036101000a031916815260200191505b50965050505050505060405180910390a150630a85bd0160e11b5b949350505050565b6118e5612633565b611924576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6119648383838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061442892505050565b505050565b611971612633565b6119b0576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156119fb576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b038416611a4a576040805162461bcd60e51b815260206004820152601160248201527011d2ce881a5b9d985b1a59081999595259607a1b604482015290519081900360640190fd5b6001600160801b038085166000908152601560205260409020541615611ab7576040805162461bcd60e51b815260206004820152601a60248201527f474b3a206665652068617320616c726561647920657869737473000000000000604482015290519081900360640190fd5b604080516080810182526001600160801b03868116808352602080840188815284860188815260608601888152600085815260158552889020965187546001600160801b031916961695909517865590516001860155516002850155915160039093019290925582513381529081019190915281517fcd49970a695c99672c8fb6cec56406d50640033eeacf8d6cadfd2fc31d2633ed929181900390910190a150505050565b60055490565b611b6b612633565b611baa576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff1615611bf5576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b838214611c44576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b60005b808514611c8f57611c8787878784818110611c5e57fe5b905060200201356001600160801b0316868685818110611c7a57fe5b905060200201358561448b565b600101611c47565b50505050505050565b611ca23382614524565b611cdd5760405162461bcd60e51b8152600401808060200182810382526031815260200180615f436031913960400191505060405180910390fd5b6119648383836145c0565b6001600160801b038082166000818152600f6020908152604080832054601090925282205485941692909190611d1d90611eb8565b90509193509193565b611d2f3361461e565b565b611d2f33614666565b611d42612633565b611d81576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16611dcf576040805162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604482015290519081900360640190fd5b600d805460ff191690556040805133815290517f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa9181900360200190a1565b611964838383604051806020016040528060008152506130d8565b611e31612633565b611e70576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6117e882828080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506146ae92505050565b600d5460ff1690565b6000818152600160205260408120546001600160a01b031680611f0c5760405162461bcd60e51b8152600401808060200182810382526029815260200180615dc56029913960400191505060405180910390fd5b92915050565b600060606000806060806000806000806000611f2c6158ed565b6001600160801b03808e1660009081526011602090815260409182902082516101608101845281549094168452600181018054845181850281018501909552808552919385840193909290830182828015611fd857602002820191906000526020600020906000905b82829054906101000a90046001600160801b03166001600160801b031681526020019060100190602082600f01049283019260010382029150808411611f955790505b505050918352505060028201546001600160a01b039081166020808401919091526003840154909116604080840191909152600484018054825181850281018501909352808352606090940193919290919083018282801561206357602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612045575b50505050508152602001600582018054806020026020016040519081016040528092919081815260200182805480156120bb57602002820191906000526020600020905b8154815260200190600101908083116120a7575b505050918352505060068201546001600160a01b0316602082015260078201546040820152600882015460609091019060ff1660018111156120f957fe5b600181111561210457fe5b81526020016008820160019054906101000a900460ff16600181111561212657fe5b600181111561213157fe5b81526020016008820160029054906101000a900460ff16600381111561215357fe5b600381111561215e57fe5b81525050905080600001519b5080602001519a508060400151995080606001519850806080015197508060a0015196508060c0015195508060e0015194508061010001519350806101200151925080610140015191505091939597999b90929496989a50565b60098054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b6000611f0c600c8363ffffffff6146c116565b60006001600160a01b03821661227f5760405162461bcd60e51b815260040180806020018281038252602a815260200180615d9b602a913960400191505060405180910390fd5b6001600160a01b0382166000908152600360205260409020611f0c90614728565b6122a8612633565b6122e7576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600b546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600b80546001600160a01b0319169055565b612339612633565b612378576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614666565b50565b6001600160801b039081166000908152601260205260409020541690565b600d5460ff16156123ed576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b61245e8a8a88888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808c0282810182019093528b82529093508b92508a91829185019084908082843760009201919091525088925061472c915050565b61249e600033308b8b808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152506148f792505050565b6125448a8a8a8a8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c91829185019084908082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b918291850190849080828437600092019190915250600192508a91508990506149f3565b50505050505050505050565b612558612633565b612597576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156125e2576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b600d805460ff191660011790556040805133815290517f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589181900360200190a1565b600b546001600160a01b031690565b600b546001600160a01b0316331490565b61264c612633565b61268b576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156126d6576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b60005b808a1461272157612719308c8c848181106126f057fe5b905060200201356001600160801b03168b8b8581811061270c57fe5b905060200201358f61448b565b6001016126d9565b506127938c8c88888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808c0282810182019093528b82529093508b92508a91829185019084908082843760009201919091525088925061472c915050565b6128398c8c8c8c8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c91829185019084908082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b918291850190849080828437600092019190915250600192508a91508990506149f3565b505050505050505050505050565b600d5460ff1615612892576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b03808816600090815260116020526040902080549091166128eb5760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b0316331461294c576040805162461bcd60e51b815260206004820152601f60248201527f474b3a206f6e6c79206d616b65722063616e20757064617465206f7264657200604482015290519081900360640190fd5b6000600882015462010000900460ff16600381111561296757fe5b146129b9576040805162461bcd60e51b815260206004820152601d60248201527f474b3a206f72646572206e6f7420616c6c6f7720746f20757064617465000000604482015290519081900360640190fd5b6001600160801b0380831660009081526015602052604090205416612a1e576040805162461bcd60e51b8152602060048201526016602482015275474b3a20696e76616c69642073797374656d2066656560501b604482015290519081900360640190fd5b858414612a6d576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b612a7b600482018888615975565b50612a8a6005820186866159d8565b5060088101805484919061ff001916610100836001811115612aa857fe5b02179055506001600160801b0388811660009081526016602090815260409182902080546001600160801b0319168685161790558354825133815292519316927e27f86415dbd02c5f89206dec635d49c61cdbf13344995f073614a5c78e3a169281900390910190a25050505050505050565b60088054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b612b84612633565b612bc3576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614c5d565b6001600160801b039081166000908152601660205260409020541690565b600d5460ff1615612c35576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6117e88282614ca5565b600d5460ff1615612c8a576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b0380821660009081526011602052604090208054909116612ce35760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b0316331415612d39576040805162461bcd60e51b815260206004820152601160248201527023a59d103cb7ba9030b9329037bbb732b960791b604482015290519081900360640190fd5b6000600882015462010000900460ff166003811115612d5457fe5b1415612e9e576000805b60048301548114612dc75760006001600160a01b0316836004018281548110612d8357fe5b6000918252602090912001546001600160a01b03161415612dbf57826005018181548110612dad57fe5b90600052602060002001549150612dc7565b600101612d5e565b508015801590612dd657508034145b612e1c576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b60088201805462ff00001916620100001790556001600160801b0383811660009081526013602090815260409182902080546001600160a01b0319163390811790915585548351918252925192909316927f4faf04ff0869dac3e6711c831d577dbf7a602a34324f3dcdc78be06264ccbf29929081900390910190a2506117e8565b60405133903480156108fc02916000818181858888f19350505050158015612eca573d6000803e3d6000fd5b50604080513381526001600160801b038416602082015260008183015234606082015290517fbbeb4d5c68897a7991d8dc575495aad0a241f5ac656ac904586d3ab4bf9e58929181900360800190a15050565b612f25612633565b612f64576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6123818161461e565b61271081565b600d5460ff1615612fbe576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b612fc733612225565b613018576040805162461bcd60e51b815260206004820152601a60248201527f474b3a2063616c6c6572206973206e6f74206f70657261746f72000000000000604482015290519081900360640190fd5b6001600160801b038085166000908152601160205260409020541661306e5760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b6130798383836140d6565b604080516001600160a01b0380861682526001600160801b03871660208301528416818301526060810183905290517fbbeb4d5c68897a7991d8dc575495aad0a241f5ac656ac904586d3ab4bf9e58929181900360800190a150505050565b6130e23383614524565b61311d5760405162461bcd60e51b8152600401808060200182810382526031815260200180615f436031913960400191505060405180910390fd5b61312984848484614d71565b50505050565b600d5460ff161561317a576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6040805160018082528183019092526060916020808301908038833901905050905087816000815181106131aa57fe5b60200260200101906001600160801b031690816001600160801b03168152505061323b898989898080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b91829185019084908082843760009201919091525089925061472c915050565b61324f33308a6001600160801b0316611c98565b6132c28989838a8a8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c918291850190849080828437600092018290525092508b91508a90506149f3565b505050505050505050565b6000611f0c600e8363ffffffff6146c116565b60606132eb826142fa565b6133265760405162461bcd60e51b815260040180806020018281038252602f815260200180615ef3602f913960400191505060405180910390fd5b6000828152600a602090815260409182902080548351601f60026000196101006001861615020190931692909204918201849004840281018401909452808452606093928301828280156133bb5780601f10613390576101008083540402835291602001916133bb565b820191906000526020600020905b81548152906001019060200180831161339e57829003601f168201915b505050505090508051600014156133e2575050604080516020810190915260008152611695565b60098160405160200180838054600181600116156101000203166002900480156134435780601f10613421576101008083540402835291820191613443565b820191906000526020600020905b81548152906001019060200180831161342f575b5050825160208401908083835b6020831061346f5780518252601f199092019160209182019101613450565b6001836020036101000a03801982511681845116808217855250505050505090500192505050604051602081830303815290604052915050611695565b6000611f0c826001600160801b03166142fa565b600d5460ff161561350b576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b61351433612225565b613565576040805162461bcd60e51b815260206004820152601a60248201527f474b3a2063616c6c6572206973206e6f74206f70657261746f72000000000000604482015290519081900360640190fd5b6001600160a01b0385166135b6576040805162461bcd60e51b8152602060048201526013602482015272474b3a20696e76616c6964206164647265737360681b604482015290519081900360640190fd5b6001600160801b0386166000908152601360205260409020546001600160a01b031615613649576001600160801b0386166000908152601360205260409020546001600160a01b03868116911614613649576040805162461bcd60e51b815260206004820152601160248201527023a59d1034b73b30b634b2103a30b5b2b960791b604482015290519081900360640190fd5b6001600160801b03808716600090815260116020526040902080549091166136a25760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b03878116911614156136fb576040805162461bcd60e51b815260206004820152601160248201527023a59d103cb7ba9030b9329037bbb732b960791b604482015290519081900360640190fd5b6000600882015462010000900460ff16600381111561371657fe5b148061373a57506001600882015462010000900460ff16600381111561373857fe5b145b61378b576040805162461bcd60e51b815260206004820152601e60248201527f474b3a2063616e6e6f7420636f6d706c6574652074686973206f726465720000604482015290519081900360640190fd5b6014838360405180838380828437919091019485525050604051928390036020019092205460ff161591506138029050576040805162461bcd60e51b815260206004820152601660248201527511d2ce881d1e1a59081a185cc81c1c9bd8d95cdcd95960521b604482015290519081900360640190fd5b6000805b600483015481146138685782600401818154811061382057fe5b6000918252602090912001546001600160a01b03888116911614156138605782600501818154811061384e57fe5b90600052602060002001549150613868565b600101613806565b50801580159061387757508481145b6138bd576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b60006138c7612624565b60028401546001600160a01b0390811691161461396a576138e6615a1f565b506001600160801b03808a1660009081526016602090815260408083205484168352601582529182902082516080810184528154909416845260018101549184018290526002810154928401929092526003909101546060830152613966906127109061395a908a9063ffffffff614dc316565b9063ffffffff614e2316565b9150505b6001600160a01b0387166139d957600283015461398f906001600160a01b031661172e565b6001600160a01b03166108fc6139ab848463ffffffff614e6516565b6040518115909202916000818181858888f193505050501580156139d3573d6000803e3d6000fd5b50613a12565b6002830154613a12906001600160a01b03166139fb848463ffffffff614e6516565b6001600160a01b038a16919063ffffffff614ea716565b6000600884015460ff166001811115613a2757fe5b1415613ae257306001600160a01b03166342842e0e308a86600101600081548110613a4e57fe5b6000918252602082206002820401546040805160e088901b6001600160e01b03191681526001600160a01b03968716600482015294909516602485015260019091166010026101000a90046001600160801b0316604483015291516064808301939282900301818387803b158015613ac557600080fd5b505af1158015613ad9573d6000803e3d6000fd5b50505050613b8d565b6001600884015460ff166001811115613af757fe5b1415613b8d57613b8d30308a86600101805480602002602001604051908101604052809291908181526020018280548015613b8357602002820191906000526020600020906000905b82829054906101000a90046001600160801b03166001600160801b031681526020019060100190602082600f01049283019260010382029150808411613b405790505b50505050506148f7565b6003830180546001600160a01b038a81166001600160a01b03199283168117909355600686018054918b169183169190911790556007850184905560088501805462ff00001916620200001790556001600160801b038b1660009081526013602052604090819020805490921690921790555160019060149087908790808383808284379190910194855250506040805160209481900385018120805460ff191696151596909617909555875433865290516001600160801b03909116947f1f4e72df2e60034b20c1427f5dd8e6b0eedad4a9916a4d54bdaffae76d00fbcf94908290030192509050a2505050505050505050565b600d5460ff1615613ccd576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b0380821660009081526011602052604090208054909116613d265760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b03163314613d87576040805162461bcd60e51b815260206004820152601f60248201527f474b3a206f6e6c79206d616b65722063616e2063616e63656c206f7264657200604482015290519081900360640190fd5b6000600882015462010000900460ff166003811115613da257fe5b14613df4576040805162461bcd60e51b815260206004820152601d60248201527f474b3a206f72646572206e6f7420616c6c6f7720746f2063616e63656c000000604482015290519081900360640190fd5b6000600882015460ff166001811115613e0957fe5b1415613ecd57600281015460018201805430926342842e0e9284926001600160a01b0390921691600090613e3957fe5b6000918252602082206002820401546040805160e088901b6001600160e01b03191681526001600160a01b03968716600482015294909516602485015260019091166010026101000a90046001600160801b0316604483015291516064808301939282900301818387803b158015613eb057600080fd5b505af1158015613ec4573d6000803e3d6000fd5b50505050613f5e565b6001600882015460ff166001811115613ee257fe5b1415613f5e57600281015460018201805460408051602080840282018101909252828152613f5e94309485946001600160a01b0390921693909190830182828015613b8357600091825260209182902080546001600160801b03168452908202830192909160109101808411613b4057905050505050506148f7565b60088101805462ff000019166203000017905580546040805133815290516001600160801b03909216917ffe6747b0a4132e956dc8b80d8e2bd4b541821f8e747bd173093d52afdd3ce8499181900360200190a25050565b6001600160801b0390811660009081526015602052604090208054600182015460028301546003909301549190931693565b6001600160801b0390811660009081526011602052604090205416151590565b6001600160a01b03918216600090815260046020908152604080832093909416825291909152205460ff1690565b61403e612633565b61407d576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614ef9565b61408e612633565b6140cd576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614f9a565b6001600160a01b038316614127576040805162461bcd60e51b8152602060048201526013602482015272474b3a20696e76616c6964206164647265737360681b604482015290519081900360640190fd5b8061416e576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b6001600160a01b03821661421a57804710156141ca576040805162461bcd60e51b815260206004820152601660248201527508e967440c4c2d8c2dcc6ca40dcdee840cadcdeeaced60531b604482015290519081900360640190fd5b6141dc836001600160a01b031661172e565b6001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015614214573d6000803e3d6000fd5b50611964565b604080516370a0823160e01b815230600482015290516000916001600160a01b038516916370a0823191602480820192602092909190829003018186803b15801561426457600080fd5b505afa158015614278573d6000803e3d6000fd5b505050506040513d602081101561428e57600080fd5b50519050818110156142e0576040805162461bcd60e51b815260206004820152601660248201527508e967440c4c2d8c2dcc6ca40dcdee840cadcdeeaced60531b604482015290519081900360640190fd5b6131296001600160a01b038416858463ffffffff614ea716565b6000908152600160205260409020546001600160a01b0316151590565b600061432282611eb8565b9050806001600160a01b0316836001600160a01b031614156143755760405162461bcd60e51b8152600401808060200182810382526021815260200180615f226021913960400191505060405180910390fd5b336001600160a01b038216148061439157506143918133614008565b6143cc5760405162461bcd60e51b8152600401808060200182810382526038815260200180615d636038913960400191505060405180910390fd5b60008281526002602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b614431826142fa565b61446c5760405162461bcd60e51b815260040180806020018281038252602c815260200180615e5c602c913960400191505060405180910390fd5b6000828152600a60209081526040909120825161196492840190615a50565b6001600160801b0381166144dd576040805162461bcd60e51b815260206004820152601460248201527311d2ce881a5b9d985b1a5908189d5b991b19525960621b604482015290519081900360640190fd5b6001600160801b038381166000818152600f602090815260408083208790556010909152902080546001600160801b03191692841692909217909155613129908590614fe2565b600061452f826142fa565b61456a5760405162461bcd60e51b815260040180806020018281038252602c815260200180615d15602c913960400191505060405180910390fd5b600061457583611eb8565b9050806001600160a01b0316846001600160a01b031614806145b05750836001600160a01b03166145a584611731565b6001600160a01b0316145b806118d557506118d58185614008565b6145c9836132cd565b806145d857506145d8826132cd565b6146135760405162461bcd60e51b8152600401808060200182810382526035815260200180615cbc6035913960400191505060405180910390fd5b611964838383614ff5565b61462f600c8263ffffffff61504b16565b6040516001600160a01b038216907f80c0b871b97b595b16a7741c1b06fed0c6f6f558639f18ccbce50724325dc40d90600090a250565b614677600e8263ffffffff61504b16565b6040516001600160a01b038216907fde8cf212af7ce38b2840785a2768d97ff2dbf3c21b516961cec0061e134c2a1e90600090a250565b80516117e8906009906020840190615a50565b60006001600160a01b0382166147085760405162461bcd60e51b8152600401808060200182810382526022815260200180615ea86022913960400191505060405180910390fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b5490565b6001600160801b03851661477d576040805162461bcd60e51b815260206004820152601360248201527211d2ce881a5b9d985b1a59081bdc99195c9259606a1b604482015290519081900360640190fd5b6001600160801b0380861660009081526011602052604090205416156147ea576040805162461bcd60e51b815260206004820152601c60248201527f474b3a206f726465722068617320616c72656164792065786973747300000000604482015290519081900360640190fd5b6001600160801b03841661483a576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a590819dbdbd9125960721b604482015290519081900360640190fd5b815183511461488b576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b6001600160801b03808216600090815260156020526040902054166148f0576040805162461bcd60e51b8152602060048201526016602482015275474b3a20696e76616c69642073797374656d2066656560501b604482015290519081900360640190fd5b5050505050565b60005b815181146148f0576001600160a01b038516156149c457846001600160a01b03166342842e0e858585858151811061492e57fe5b60200260200101516040518463ffffffff1660e01b815260040180846001600160a01b03166001600160a01b03168152602001836001600160a01b03166001600160a01b03168152602001826001600160801b031681526020019350505050600060405180830381600087803b1580156149a757600080fd5b505af11580156149bb573d6000803e3d6000fd5b505050506149eb565b6149eb84848484815181106149d557fe5b60200260200101516001600160801b0316611e0e565b6001016148fa565b604051806101600160405280896001600160801b03168152602001878152602001336001600160a01b0316815260200160006001600160a01b0316815260200186815260200185815260200160006001600160a01b0316815260200160008152602001846001811115614a6257fe5b8152602001836001811115614a7357fe5b8152602001600090526001600160801b038981166000908152601160209081526040909120835181546001600160801b0319169316929092178255828101518051614ac49260018501920190615abe565b5060408201516002820180546001600160a01b039283166001600160a01b031991821617909155606084015160038401805491909316911617905560808201518051614b1a916004840191602090910190615b72565b5060a08201518051614b36916005840191602090910190615bc7565b5060c08201516006820180546001600160a01b0319166001600160a01b0390921691909117905560e0820151600782015561010082015160088201805460ff191660018381811115614b8457fe5b021790555061012082015160088201805461ff001916610100836001811115614ba957fe5b021790555061014082015160088201805462ff0000191662010000836003811115614bd057fe5b021790555050506001600160801b03888116600081815260166020908152604080832080546001600160801b03199081168888161790915560128352928190208054909316948c16949094179091558251338152925191927fb1a25994da8bb64efd778ed0dda424120106ae005c1d9dd60161455a1963d638929081900390910190a25050505050505050565b614c6e600c8263ffffffff6150b216565b6040516001600160a01b038216907fac6fa858e9350a46cec16539926e0fde25b7629f84b5a72bffaae4df888ae86d90600090a250565b6001600160a01b038216331415614d03576040805162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c657200000000000000604482015290519081900360640190fd5b3360008181526004602090815260408083206001600160a01b03871680855290835292819020805460ff1916861515908117909155815190815290519293927f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31929181900390910190a35050565b614d7c8484846145c0565b614d8884848484615133565b6131295760405162461bcd60e51b8152600401808060200182810382526032815260200180615c646032913960400191505060405180910390fd5b600082614dd257506000611f0c565b82820282848281614ddf57fe5b0414614e1c5760405162461bcd60e51b8152600401808060200182810382526021815260200180615e0f6021913960400191505060405180910390fd5b9392505050565b6000614e1c83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061534f565b6000614e1c83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506153f1565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261196490849061544b565b6001600160a01b038116614f3e5760405162461bcd60e51b8152600401808060200182810382526026815260200180615c966026913960400191505060405180910390fd5b600b546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600b80546001600160a01b0319166001600160a01b0392909216919091179055565b614fab600e8263ffffffff6150b216565b6040516001600160a01b038216907f4790a4adb426ca2345bb5108f6e454eae852a7bf687544cd66a7270dff3a41d690600090a250565b614fec82826155a0565b6117e8816156d1565b600d5460ff1615615040576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b611964838383615715565b61505582826146c1565b6150905760405162461bcd60e51b8152600401808060200182810382526021815260200180615dee6021913960400191505060405180910390fd5b6001600160a01b0316600090815260209190915260409020805460ff19169055565b6150bc82826146c1565b1561510e576040805162461bcd60e51b815260206004820152601f60248201527f526f6c65733a206163636f756e7420616c72656164792068617320726f6c6500604482015290519081900360640190fd5b6001600160a01b0316600090815260209190915260409020805460ff19166001179055565b6000615147846001600160a01b0316615859565b615153575060016118d5565b60405133602482018181526001600160a01b03888116604485015260648401879052608060848501908152865160a48601528651600095606095938b1694630a85bd0160e11b94938d938c938c93929160c49091019060208501908083838f5b838110156151cb5781810151838201526020016151b3565b50505050905090810190601f1680156151f85780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909a16999099178952518151919890975087965094509250829150849050835b602083106152605780518252601f199092019160209182019101615241565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146152c2576040519150601f19603f3d011682016040523d82523d6000602084013e6152c7565b606091505b509150915081615318578051156152e15780518082602001fd5b60405162461bcd60e51b8152600401808060200182810382526032815260200180615c646032913960400191505060405180910390fd5b600081806020019051602081101561532f57600080fd5b50516001600160e01b031916630a85bd0160e11b1493506118d592505050565b600081836153db5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156153a0578181015183820152602001615388565b50505050905090810190601f1680156153cd5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816153e757fe5b0495945050505050565b600081848411156154435760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156153a0578181015183820152602001615388565b505050900390565b60006060836001600160a01b0316836040518082805190602001908083835b602083106154895780518252601f19909201916020918201910161546a565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146154eb576040519150601f19603f3d011682016040523d82523d6000602084013e6154f0565b606091505b509150915081615547576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b8051156131295780806020019051602081101561556357600080fd5b50516131295760405162461bcd60e51b815260040180806020018281038252602a815260200180615f74602a913960400191505060405180910390fd5b6001600160a01b0382166155fb576040805162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f2061646472657373604482015290519081900360640190fd5b615604816142fa565b15615656576040805162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604482015290519081900360640190fd5b600081815260016020908152604080832080546001600160a01b0319166001600160a01b03871690811790915583526003909152902061569590615892565b60405181906001600160a01b038416906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b600580546000838152600660205260408120829055600182018355919091527f036b6384b5eca791c62761152d0c79bb0604c104a5fb6f4eb0703f3154bb3db00155565b826001600160a01b031661572882611eb8565b6001600160a01b03161461576d5760405162461bcd60e51b8152600401808060200182810382526029815260200180615eca6029913960400191505060405180910390fd5b6001600160a01b0382166157b25760405162461bcd60e51b8152600401808060200182810382526024815260200180615cf16024913960400191505060405180910390fd5b6157bb8161589b565b6001600160a01b03831660009081526003602052604090206157dc906158d6565b6001600160a01b03821660009081526003602052604090206157fd90615892565b60008181526001602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708181148015906118d5575050151592915050565b80546001019055565b6000818152600260205260409020546001600160a01b03161561238157600090815260026020526040902080546001600160a01b0319169055565b80546158e990600163ffffffff614e6516565b9055565b60405180610160016040528060006001600160801b031681526020016060815260200160006001600160a01b0316815260200160006001600160a01b03168152602001606081526020016060815260200160006001600160a01b03168152602001600081526020016000600181111561596257fe5b8152602001600081526020016000905290565b8280548282559060005260206000209081019282156159c8579160200282015b828111156159c85781546001600160a01b0319166001600160a01b03843516178255602090920191600190910190615995565b506159d4929150615c01565b5090565b828054828255906000526020600020908101928215615a13579160200282015b82811115615a135782358255916020019190600101906159f8565b506159d4929150615c25565b604051806080016040528060006001600160801b031681526020016000815260200160008152602001600081525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10615a9157805160ff1916838001178555615a13565b82800160010185558215615a13579182015b82811115615a13578251825591602001919060010190615aa3565b82805482825590600052602060002090600101600290048101928215615b665791602002820160005b83821115615b3157835183826101000a8154816001600160801b0302191690836001600160801b031602179055509260200192601001602081600f01049283019260010302615ae7565b8015615b645782816101000a8154906001600160801b030219169055601001602081600f01049283019260010302615b31565b505b506159d4929150615c3f565b8280548282559060005260206000209081019282156159c8579160200282015b828111156159c857825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615b92565b828054828255906000526020600020908101928215615a135791602002820182811115615a13578251825591602001919060010190615aa3565b61172e91905b808211156159d45780546001600160a01b0319168155600101615c07565b61172e91905b808211156159d45760008155600101615c2b565b61172e91905b808211156159d45780546001600160801b0319168155600101615c4556fe4552433732313a207472616e7366657220746f206e6f6e20455243373231526563656976657220696d706c656d656e7465724f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524337323157686974656c6973743a2073656e646572206f7220726563697069656e74206973206e6f742077686974656c6973744552433732313a207472616e7366657220746f20746865207a65726f20616464726573734552433732313a206f70657261746f7220717565727920666f72206e6f6e6578697374656e7420746f6b656e474b3a2063616c6c6572207175657279206e6f6e6578697374656e74206f726465724552433732313a20617070726f76652063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656420666f7220616c6c4552433732313a2062616c616e636520717565727920666f7220746865207a65726f20616464726573734552433732313a206f776e657220717565727920666f72206e6f6e6578697374656e7420746f6b656e526f6c65733a206163636f756e7420646f6573206e6f74206861766520726f6c65536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774552433732313a20617070726f76656420717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732314d657461646174613a2055524920736574206f66206e6f6e6578697374656e7420746f6b656e4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572526f6c65733a206163636f756e7420697320746865207a65726f20616464726573734552433732313a207472616e73666572206f6620746f6b656e2074686174206973206e6f74206f776e4552433732314d657461646174613a2055524920717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a20617070726f76616c20746f2063757272656e74206f776e65724552433732313a207472616e736665722063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f7665645361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a265627a7a723158208a36597eeba52fb7fbd5f5fb1459b9fef83535cbc3100a79a5c953ad07edbb5264736f6c63430005110032526f6c65733a206163636f756e7420697320746865207a65726f206164647265737300000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000f47656e65736973204b696e67646f6d00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002474b000000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x6080604052600436106102fe5760003560e01c80637de6a11211610190578063b7f16965116100dc578063da9403cb11610095578063e81398431161006f578063e8139843146114fc578063e985e9c51461152f578063f2fde38b1461156a578063f80f5dd51461159d576102fe565b8063da9403cb146113bd578063dbc9139614611466578063dc332cbd14611499576102fe565b8063b7f1696514611114578063b88d4fde14611166578063c593c5c914611237578063c683630d1461132d578063c87b56dd14611360578063d28bc1501461138a576102fe565b806395d89b4111610149578063a22cb46511610123578063a22cb4651461106b578063ac19f00b146110a6578063ac8a584a146110cc578063b371c17f146110ff576102fe565b806395d89b4114610ff05780639870d7fe14611005578063a0e2718a14611038576102fe565b80637de6a11214610be75780638456cb5914610d2d5780638da5cb5b14610d425780638f32d59b14610d5757806391095ed714610d6c5780639370be1a14610f03576102fe565b806339137f8b1161024f5780636b8136751161020857806370a08231116101e257806370a0823114610b1d578063715018a614610b5057806378c8cda714610b65578063790e2ee614610b98576102fe565b80636b813675146109465780636c0360eb14610ad55780636d70f7ae14610aea576102fe565b806339137f8b1461081f5780633f4ba83a1461083457806342842e0e1461084957806355f804b31461088c5780635c975abb146109075780636352211e1461091c576102fe565b8063162094c4116102bc578063213ea55c11610296578063213ea55c1461067557806323b872dd1461075957806329c5c0ae1461079c5780632ab6f8db1461080a576102fe565b8063162094c41461058757806317d4095f1461060957806318160ddd1461064e576102fe565b806229c0b41461030357806301ffc9a71461034857806306fdde0314610390578063081812fc1461041a578063095ea7b314610460578063150b7a0214610499575b600080fd5b34801561030f57600080fd5b506103466004803603606081101561032657600080fd5b506001600160a01b038135811691602081013590911690604001356115d0565b005b34801561035457600080fd5b5061037c6004803603602081101561036b57600080fd5b50356001600160e01b031916611677565b604080519115158252519081900360200190f35b34801561039c57600080fd5b506103a561169a565b6040805160208082528351818301528351919283929083019185019080838360005b838110156103df5781810151838201526020016103c7565b50505050905090810190601f16801561040c5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561042657600080fd5b506104446004803603602081101561043d57600080fd5b5035611731565b604080516001600160a01b039092168252519081900360200190f35b34801561046c57600080fd5b506103466004803603604081101561048357600080fd5b506001600160a01b038135169060200135611793565b3480156104a557600080fd5b5061056a600480360360808110156104bc57600080fd5b6001600160a01b03823581169260208101359091169160408201359190810190608081016060820135600160201b8111156104f657600080fd5b82018360208201111561050857600080fd5b803590602001918460018302840111600160201b8311171561052957600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506117ec945050505050565b604080516001600160e01b03199092168252519081900360200190f35b34801561059357600080fd5b50610346600480360360408110156105aa57600080fd5b81359190810190604081016020820135600160201b8111156105cb57600080fd5b8201836020820111156105dd57600080fd5b803590602001918460018302840111600160201b831117156105fe57600080fd5b5090925090506118dd565b34801561061557600080fd5b506103466004803603608081101561062c57600080fd5b506001600160801b038135169060208101359060408101359060600135611969565b34801561065a57600080fd5b50610663611b5d565b60408051918252519081900360200190f35b34801561068157600080fd5b506103466004803603608081101561069857600080fd5b6001600160a01b038235169190810190604081016020820135600160201b8111156106c257600080fd5b8201836020820111156106d457600080fd5b803590602001918460208302840111600160201b831117156106f557600080fd5b919390929091602081019035600160201b81111561071257600080fd5b82018360208201111561072457600080fd5b803590602001918460208302840111600160201b8311171561074557600080fd5b9193509150356001600160801b0316611b63565b34801561076557600080fd5b506103466004803603606081101561077c57600080fd5b506001600160a01b03813581169160208101359091169060400135611c98565b3480156107a857600080fd5b506107cf600480360360208110156107bf57600080fd5b50356001600160801b0316611ce8565b604080516001600160801b039586168152939094166020840152828401919091526001600160a01b0316606082015290519081900360800190f35b34801561081657600080fd5b50610346611d26565b34801561082b57600080fd5b50610346611d31565b34801561084057600080fd5b50610346611d3a565b34801561085557600080fd5b506103466004803603606081101561086c57600080fd5b506001600160a01b03813581169160208101359091169060400135611e0e565b34801561089857600080fd5b50610346600480360360208110156108af57600080fd5b810190602081018135600160201b8111156108c957600080fd5b8201836020820111156108db57600080fd5b803590602001918460018302840111600160201b831117156108fc57600080fd5b509092509050611e29565b34801561091357600080fd5b5061037c611eaf565b34801561092857600080fd5b506104446004803603602081101561093f57600080fd5b5035611eb8565b34801561095257600080fd5b506109796004803603602081101561096957600080fd5b50356001600160801b0316611f12565b604080516001600160801b038d1681526001600160a01b03808c1692820192909252898216606082015290861660c082015260e08101859052602081016080820160a0830161010084018760018111156109cf57fe5b60ff1681526020018660018111156109e357fe5b60ff1681526020018560038111156109f757fe5b60ff16815260200184810384528e818151815260200191508051906020019060200280838360005b83811015610a37578181015183820152602001610a1f565b5050505090500184810383528b818151815260200191508051906020019060200280838360005b83811015610a76578181015183820152602001610a5e565b5050505090500184810382528a818151815260200191508051906020019060200280838360005b83811015610ab5578181015183820152602001610a9d565b505050509050019e50505050505050505050505050505060405180910390f35b348015610ae157600080fd5b506103a56121c4565b348015610af657600080fd5b5061037c60048036036020811015610b0d57600080fd5b50356001600160a01b0316612225565b348015610b2957600080fd5b5061066360048036036020811015610b4057600080fd5b50356001600160a01b0316612238565b348015610b5c57600080fd5b506103466122a0565b348015610b7157600080fd5b5061034660048036036020811015610b8857600080fd5b50356001600160a01b0316612331565b348015610ba457600080fd5b50610bcb60048036036020811015610bbb57600080fd5b50356001600160801b0316612384565b604080516001600160801b039092168252519081900360200190f35b348015610bf357600080fd5b50610346600480360360e0811015610c0a57600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b811115610c3d57600080fd5b820183602082011115610c4f57600080fd5b803590602001918460208302840111600160201b83111715610c7057600080fd5b919390929091602081019035600160201b811115610c8d57600080fd5b820183602082011115610c9f57600080fd5b803590602001918460208302840111600160201b83111715610cc057600080fd5b919390929091602081019035600160201b811115610cdd57600080fd5b820183602082011115610cef57600080fd5b803590602001918460208302840111600160201b83111715610d1057600080fd5b9193509150803560ff1690602001356001600160801b03166123a2565b348015610d3957600080fd5b50610346612550565b348015610d4e57600080fd5b50610444612624565b348015610d6357600080fd5b5061037c612633565b348015610d7857600080fd5b506103466004803603610100811015610d9057600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b811115610dc357600080fd5b820183602082011115610dd557600080fd5b803590602001918460208302840111600160201b83111715610df657600080fd5b919390929091602081019035600160201b811115610e1357600080fd5b820183602082011115610e2557600080fd5b803590602001918460208302840111600160201b83111715610e4657600080fd5b919390929091602081019035600160201b811115610e6357600080fd5b820183602082011115610e7557600080fd5b803590602001918460208302840111600160201b83111715610e9657600080fd5b919390929091602081019035600160201b811115610eb357600080fd5b820183602082011115610ec557600080fd5b803590602001918460208302840111600160201b83111715610ee657600080fd5b9193509150803560ff1690602001356001600160801b0316612644565b348015610f0f57600080fd5b50610346600480360360a0811015610f2657600080fd5b6001600160801b038235169190810190604081016020820135600160201b811115610f5057600080fd5b820183602082011115610f6257600080fd5b803590602001918460208302840111600160201b83111715610f8357600080fd5b919390929091602081019035600160201b811115610fa057600080fd5b820183602082011115610fb257600080fd5b803590602001918460208302840111600160201b83111715610fd357600080fd5b9193509150803560ff1690602001356001600160801b0316612847565b348015610ffc57600080fd5b506103a5612b1b565b34801561101157600080fd5b506103466004803603602081101561102857600080fd5b50356001600160a01b0316612b7c565b34801561104457600080fd5b50610bcb6004803603602081101561105b57600080fd5b50356001600160801b0316612bcc565b34801561107757600080fd5b506103466004803603604081101561108e57600080fd5b506001600160a01b0381351690602001351515612bea565b610346600480360360208110156110bc57600080fd5b50356001600160801b0316612c3f565b3480156110d857600080fd5b50610346600480360360208110156110ef57600080fd5b50356001600160a01b0316612f1d565b34801561110b57600080fd5b50610663612f6d565b34801561112057600080fd5b506103466004803603608081101561113757600080fd5b506001600160801b03813516906001600160a01b03602082013581169160408101359091169060600135612f73565b34801561117257600080fd5b506103466004803603608081101561118957600080fd5b6001600160a01b03823581169260208101359091169160408201359190810190608081016060820135600160201b8111156111c357600080fd5b8201836020820111156111d557600080fd5b803590602001918460018302840111600160201b831117156111f657600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506130d8945050505050565b34801561124357600080fd5b50610346600480360360c081101561125a57600080fd5b6001600160801b038235811692602081013590911691810190606081016040820135600160201b81111561128d57600080fd5b82018360208201111561129f57600080fd5b803590602001918460208302840111600160201b831117156112c057600080fd5b919390929091602081019035600160201b8111156112dd57600080fd5b8201836020820111156112ef57600080fd5b803590602001918460208302840111600160201b8311171561131057600080fd5b9193509150803560ff1690602001356001600160801b031661312f565b34801561133957600080fd5b5061037c6004803603602081101561135057600080fd5b50356001600160a01b03166132cd565b34801561136c57600080fd5b506103a56004803603602081101561138357600080fd5b50356132e0565b34801561139657600080fd5b5061037c600480360360208110156113ad57600080fd5b50356001600160801b03166134ac565b3480156113c957600080fd5b50610346600480360360a08110156113e057600080fd5b6001600160801b03823516916001600160a01b03602082013581169260408301359091169160608101359181019060a081016080820135600160201b81111561142857600080fd5b82018360208201111561143a57600080fd5b803590602001918460018302840111600160201b8311171561145b57600080fd5b5090925090506134c0565b34801561147257600080fd5b506103466004803603602081101561148957600080fd5b50356001600160801b0316613c82565b3480156114a557600080fd5b506114cc600480360360208110156114bc57600080fd5b50356001600160801b0316613fb6565b604080516001600160801b0390951685526020850193909352838301919091526060830152519081900360800190f35b34801561150857600080fd5b5061037c6004803603602081101561151f57600080fd5b50356001600160801b0316613fe8565b34801561153b57600080fd5b5061037c6004803603604081101561155257600080fd5b506001600160a01b0381358116916020013516614008565b34801561157657600080fd5b506103466004803603602081101561158d57600080fd5b50356001600160a01b0316614036565b3480156115a957600080fd5b50610346600480360360208110156115c057600080fd5b50356001600160a01b0316614086565b6115d8612633565b611617576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6116228383836140d6565b604080513381526001600160a01b0380861660208301528416818301526060810183905290517f342e7ff505a8a0364cd0dc2ff195c315e43bce86b204846ecd36913e117b109e9181900360800190a1505050565b6001600160e01b0319811660009081526020819052604090205460ff165b919050565b60078054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b820191906000526020600020905b81548152906001019060200180831161170957829003601f168201915b505050505090505b90565b600061173c826142fa565b6117775760405162461bcd60e51b815260040180806020018281038252602c815260200180615e30602c913960400191505060405180910390fd5b506000908152600260205260409020546001600160a01b031690565b600d5460ff16156117de576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6117e88282614317565b5050565b60007f28fa6e16458f9c24aa59ddd4085264573006dbe30304837873c7deafc702b038858585855a60405180866001600160a01b03166001600160a01b03168152602001856001600160a01b03166001600160a01b0316815260200184815260200180602001838152602001828103825284818151815260200191508051906020019080838360005b8381101561188d578181015183820152602001611875565b50505050905090810190601f1680156118ba5780820380516001836020036101000a031916815260200191505b50965050505050505060405180910390a150630a85bd0160e11b5b949350505050565b6118e5612633565b611924576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6119648383838080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061442892505050565b505050565b611971612633565b6119b0576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156119fb576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b038416611a4a576040805162461bcd60e51b815260206004820152601160248201527011d2ce881a5b9d985b1a59081999595259607a1b604482015290519081900360640190fd5b6001600160801b038085166000908152601560205260409020541615611ab7576040805162461bcd60e51b815260206004820152601a60248201527f474b3a206665652068617320616c726561647920657869737473000000000000604482015290519081900360640190fd5b604080516080810182526001600160801b03868116808352602080840188815284860188815260608601888152600085815260158552889020965187546001600160801b031916961695909517865590516001860155516002850155915160039093019290925582513381529081019190915281517fcd49970a695c99672c8fb6cec56406d50640033eeacf8d6cadfd2fc31d2633ed929181900390910190a150505050565b60055490565b611b6b612633565b611baa576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff1615611bf5576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b838214611c44576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b60005b808514611c8f57611c8787878784818110611c5e57fe5b905060200201356001600160801b0316868685818110611c7a57fe5b905060200201358561448b565b600101611c47565b50505050505050565b611ca23382614524565b611cdd5760405162461bcd60e51b8152600401808060200182810382526031815260200180615f436031913960400191505060405180910390fd5b6119648383836145c0565b6001600160801b038082166000818152600f6020908152604080832054601090925282205485941692909190611d1d90611eb8565b90509193509193565b611d2f3361461e565b565b611d2f33614666565b611d42612633565b611d81576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16611dcf576040805162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604482015290519081900360640190fd5b600d805460ff191690556040805133815290517f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa9181900360200190a1565b611964838383604051806020016040528060008152506130d8565b611e31612633565b611e70576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6117e882828080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506146ae92505050565b600d5460ff1690565b6000818152600160205260408120546001600160a01b031680611f0c5760405162461bcd60e51b8152600401808060200182810382526029815260200180615dc56029913960400191505060405180910390fd5b92915050565b600060606000806060806000806000806000611f2c6158ed565b6001600160801b03808e1660009081526011602090815260409182902082516101608101845281549094168452600181018054845181850281018501909552808552919385840193909290830182828015611fd857602002820191906000526020600020906000905b82829054906101000a90046001600160801b03166001600160801b031681526020019060100190602082600f01049283019260010382029150808411611f955790505b505050918352505060028201546001600160a01b039081166020808401919091526003840154909116604080840191909152600484018054825181850281018501909352808352606090940193919290919083018282801561206357602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612045575b50505050508152602001600582018054806020026020016040519081016040528092919081815260200182805480156120bb57602002820191906000526020600020905b8154815260200190600101908083116120a7575b505050918352505060068201546001600160a01b0316602082015260078201546040820152600882015460609091019060ff1660018111156120f957fe5b600181111561210457fe5b81526020016008820160019054906101000a900460ff16600181111561212657fe5b600181111561213157fe5b81526020016008820160029054906101000a900460ff16600381111561215357fe5b600381111561215e57fe5b81525050905080600001519b5080602001519a508060400151995080606001519850806080015197508060a0015196508060c0015195508060e0015194508061010001519350806101200151925080610140015191505091939597999b90929496989a50565b60098054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b6000611f0c600c8363ffffffff6146c116565b60006001600160a01b03821661227f5760405162461bcd60e51b815260040180806020018281038252602a815260200180615d9b602a913960400191505060405180910390fd5b6001600160a01b0382166000908152600360205260409020611f0c90614728565b6122a8612633565b6122e7576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600b546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600b80546001600160a01b0319169055565b612339612633565b612378576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614666565b50565b6001600160801b039081166000908152601260205260409020541690565b600d5460ff16156123ed576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b61245e8a8a88888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808c0282810182019093528b82529093508b92508a91829185019084908082843760009201919091525088925061472c915050565b61249e600033308b8b808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152506148f792505050565b6125448a8a8a8a8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c91829185019084908082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b918291850190849080828437600092019190915250600192508a91508990506149f3565b50505050505050505050565b612558612633565b612597576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156125e2576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b600d805460ff191660011790556040805133815290517f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589181900360200190a1565b600b546001600160a01b031690565b600b546001600160a01b0316331490565b61264c612633565b61268b576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b600d5460ff16156126d6576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b60005b808a1461272157612719308c8c848181106126f057fe5b905060200201356001600160801b03168b8b8581811061270c57fe5b905060200201358f61448b565b6001016126d9565b506127938c8c88888080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808c0282810182019093528b82529093508b92508a91829185019084908082843760009201919091525088925061472c915050565b6128398c8c8c8c8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c91829185019084908082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b918291850190849080828437600092019190915250600192508a91508990506149f3565b505050505050505050505050565b600d5460ff1615612892576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b03808816600090815260116020526040902080549091166128eb5760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b0316331461294c576040805162461bcd60e51b815260206004820152601f60248201527f474b3a206f6e6c79206d616b65722063616e20757064617465206f7264657200604482015290519081900360640190fd5b6000600882015462010000900460ff16600381111561296757fe5b146129b9576040805162461bcd60e51b815260206004820152601d60248201527f474b3a206f72646572206e6f7420616c6c6f7720746f20757064617465000000604482015290519081900360640190fd5b6001600160801b0380831660009081526015602052604090205416612a1e576040805162461bcd60e51b8152602060048201526016602482015275474b3a20696e76616c69642073797374656d2066656560501b604482015290519081900360640190fd5b858414612a6d576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b612a7b600482018888615975565b50612a8a6005820186866159d8565b5060088101805484919061ff001916610100836001811115612aa857fe5b02179055506001600160801b0388811660009081526016602090815260409182902080546001600160801b0319168685161790558354825133815292519316927e27f86415dbd02c5f89206dec635d49c61cdbf13344995f073614a5c78e3a169281900390910190a25050505050505050565b60088054604080516020601f60026000196101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156117265780601f106116fb57610100808354040283529160200191611726565b612b84612633565b612bc3576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614c5d565b6001600160801b039081166000908152601660205260409020541690565b600d5460ff1615612c35576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6117e88282614ca5565b600d5460ff1615612c8a576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b0380821660009081526011602052604090208054909116612ce35760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b0316331415612d39576040805162461bcd60e51b815260206004820152601160248201527023a59d103cb7ba9030b9329037bbb732b960791b604482015290519081900360640190fd5b6000600882015462010000900460ff166003811115612d5457fe5b1415612e9e576000805b60048301548114612dc75760006001600160a01b0316836004018281548110612d8357fe5b6000918252602090912001546001600160a01b03161415612dbf57826005018181548110612dad57fe5b90600052602060002001549150612dc7565b600101612d5e565b508015801590612dd657508034145b612e1c576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b60088201805462ff00001916620100001790556001600160801b0383811660009081526013602090815260409182902080546001600160a01b0319163390811790915585548351918252925192909316927f4faf04ff0869dac3e6711c831d577dbf7a602a34324f3dcdc78be06264ccbf29929081900390910190a2506117e8565b60405133903480156108fc02916000818181858888f19350505050158015612eca573d6000803e3d6000fd5b50604080513381526001600160801b038416602082015260008183015234606082015290517fbbeb4d5c68897a7991d8dc575495aad0a241f5ac656ac904586d3ab4bf9e58929181900360800190a15050565b612f25612633565b612f64576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b6123818161461e565b61271081565b600d5460ff1615612fbe576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b612fc733612225565b613018576040805162461bcd60e51b815260206004820152601a60248201527f474b3a2063616c6c6572206973206e6f74206f70657261746f72000000000000604482015290519081900360640190fd5b6001600160801b038085166000908152601160205260409020541661306e5760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b6130798383836140d6565b604080516001600160a01b0380861682526001600160801b03871660208301528416818301526060810183905290517fbbeb4d5c68897a7991d8dc575495aad0a241f5ac656ac904586d3ab4bf9e58929181900360800190a150505050565b6130e23383614524565b61311d5760405162461bcd60e51b8152600401808060200182810382526031815260200180615f436031913960400191505060405180910390fd5b61312984848484614d71565b50505050565b600d5460ff161561317a576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6040805160018082528183019092526060916020808301908038833901905050905087816000815181106131aa57fe5b60200260200101906001600160801b031690816001600160801b03168152505061323b898989898080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808d0282810182019093528c82529093508c92508b91829185019084908082843760009201919091525089925061472c915050565b61324f33308a6001600160801b0316611c98565b6132c28989838a8a8080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525050604080516020808e0282810182019093528d82529093508d92508c918291850190849080828437600092018290525092508b91508a90506149f3565b505050505050505050565b6000611f0c600e8363ffffffff6146c116565b60606132eb826142fa565b6133265760405162461bcd60e51b815260040180806020018281038252602f815260200180615ef3602f913960400191505060405180910390fd5b6000828152600a602090815260409182902080548351601f60026000196101006001861615020190931692909204918201849004840281018401909452808452606093928301828280156133bb5780601f10613390576101008083540402835291602001916133bb565b820191906000526020600020905b81548152906001019060200180831161339e57829003601f168201915b505050505090508051600014156133e2575050604080516020810190915260008152611695565b60098160405160200180838054600181600116156101000203166002900480156134435780601f10613421576101008083540402835291820191613443565b820191906000526020600020905b81548152906001019060200180831161342f575b5050825160208401908083835b6020831061346f5780518252601f199092019160209182019101613450565b6001836020036101000a03801982511681845116808217855250505050505090500192505050604051602081830303815290604052915050611695565b6000611f0c826001600160801b03166142fa565b600d5460ff161561350b576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b61351433612225565b613565576040805162461bcd60e51b815260206004820152601a60248201527f474b3a2063616c6c6572206973206e6f74206f70657261746f72000000000000604482015290519081900360640190fd5b6001600160a01b0385166135b6576040805162461bcd60e51b8152602060048201526013602482015272474b3a20696e76616c6964206164647265737360681b604482015290519081900360640190fd5b6001600160801b0386166000908152601360205260409020546001600160a01b031615613649576001600160801b0386166000908152601360205260409020546001600160a01b03868116911614613649576040805162461bcd60e51b815260206004820152601160248201527023a59d1034b73b30b634b2103a30b5b2b960791b604482015290519081900360640190fd5b6001600160801b03808716600090815260116020526040902080549091166136a25760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b03878116911614156136fb576040805162461bcd60e51b815260206004820152601160248201527023a59d103cb7ba9030b9329037bbb732b960791b604482015290519081900360640190fd5b6000600882015462010000900460ff16600381111561371657fe5b148061373a57506001600882015462010000900460ff16600381111561373857fe5b145b61378b576040805162461bcd60e51b815260206004820152601e60248201527f474b3a2063616e6e6f7420636f6d706c6574652074686973206f726465720000604482015290519081900360640190fd5b6014838360405180838380828437919091019485525050604051928390036020019092205460ff161591506138029050576040805162461bcd60e51b815260206004820152601660248201527511d2ce881d1e1a59081a185cc81c1c9bd8d95cdcd95960521b604482015290519081900360640190fd5b6000805b600483015481146138685782600401818154811061382057fe5b6000918252602090912001546001600160a01b03888116911614156138605782600501818154811061384e57fe5b90600052602060002001549150613868565b600101613806565b50801580159061387757508481145b6138bd576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b60006138c7612624565b60028401546001600160a01b0390811691161461396a576138e6615a1f565b506001600160801b03808a1660009081526016602090815260408083205484168352601582529182902082516080810184528154909416845260018101549184018290526002810154928401929092526003909101546060830152613966906127109061395a908a9063ffffffff614dc316565b9063ffffffff614e2316565b9150505b6001600160a01b0387166139d957600283015461398f906001600160a01b031661172e565b6001600160a01b03166108fc6139ab848463ffffffff614e6516565b6040518115909202916000818181858888f193505050501580156139d3573d6000803e3d6000fd5b50613a12565b6002830154613a12906001600160a01b03166139fb848463ffffffff614e6516565b6001600160a01b038a16919063ffffffff614ea716565b6000600884015460ff166001811115613a2757fe5b1415613ae257306001600160a01b03166342842e0e308a86600101600081548110613a4e57fe5b6000918252602082206002820401546040805160e088901b6001600160e01b03191681526001600160a01b03968716600482015294909516602485015260019091166010026101000a90046001600160801b0316604483015291516064808301939282900301818387803b158015613ac557600080fd5b505af1158015613ad9573d6000803e3d6000fd5b50505050613b8d565b6001600884015460ff166001811115613af757fe5b1415613b8d57613b8d30308a86600101805480602002602001604051908101604052809291908181526020018280548015613b8357602002820191906000526020600020906000905b82829054906101000a90046001600160801b03166001600160801b031681526020019060100190602082600f01049283019260010382029150808411613b405790505b50505050506148f7565b6003830180546001600160a01b038a81166001600160a01b03199283168117909355600686018054918b169183169190911790556007850184905560088501805462ff00001916620200001790556001600160801b038b1660009081526013602052604090819020805490921690921790555160019060149087908790808383808284379190910194855250506040805160209481900385018120805460ff191696151596909617909555875433865290516001600160801b03909116947f1f4e72df2e60034b20c1427f5dd8e6b0eedad4a9916a4d54bdaffae76d00fbcf94908290030192509050a2505050505050505050565b600d5460ff1615613ccd576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b6001600160801b0380821660009081526011602052604090208054909116613d265760405162461bcd60e51b8152600401808060200182810382526022815260200180615d416022913960400191505060405180910390fd5b60028101546001600160a01b03163314613d87576040805162461bcd60e51b815260206004820152601f60248201527f474b3a206f6e6c79206d616b65722063616e2063616e63656c206f7264657200604482015290519081900360640190fd5b6000600882015462010000900460ff166003811115613da257fe5b14613df4576040805162461bcd60e51b815260206004820152601d60248201527f474b3a206f72646572206e6f7420616c6c6f7720746f2063616e63656c000000604482015290519081900360640190fd5b6000600882015460ff166001811115613e0957fe5b1415613ecd57600281015460018201805430926342842e0e9284926001600160a01b0390921691600090613e3957fe5b6000918252602082206002820401546040805160e088901b6001600160e01b03191681526001600160a01b03968716600482015294909516602485015260019091166010026101000a90046001600160801b0316604483015291516064808301939282900301818387803b158015613eb057600080fd5b505af1158015613ec4573d6000803e3d6000fd5b50505050613f5e565b6001600882015460ff166001811115613ee257fe5b1415613f5e57600281015460018201805460408051602080840282018101909252828152613f5e94309485946001600160a01b0390921693909190830182828015613b8357600091825260209182902080546001600160801b03168452908202830192909160109101808411613b4057905050505050506148f7565b60088101805462ff000019166203000017905580546040805133815290516001600160801b03909216917ffe6747b0a4132e956dc8b80d8e2bd4b541821f8e747bd173093d52afdd3ce8499181900360200190a25050565b6001600160801b0390811660009081526015602052604090208054600182015460028301546003909301549190931693565b6001600160801b0390811660009081526011602052604090205416151590565b6001600160a01b03918216600090815260046020908152604080832093909416825291909152205460ff1690565b61403e612633565b61407d576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614ef9565b61408e612633565b6140cd576040805162461bcd60e51b81526020600482018190526024820152600080516020615e88833981519152604482015290519081900360640190fd5b61238181614f9a565b6001600160a01b038316614127576040805162461bcd60e51b8152602060048201526013602482015272474b3a20696e76616c6964206164647265737360681b604482015290519081900360640190fd5b8061416e576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a5908185b5bdd5b9d60721b604482015290519081900360640190fd5b6001600160a01b03821661421a57804710156141ca576040805162461bcd60e51b815260206004820152601660248201527508e967440c4c2d8c2dcc6ca40dcdee840cadcdeeaced60531b604482015290519081900360640190fd5b6141dc836001600160a01b031661172e565b6001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015614214573d6000803e3d6000fd5b50611964565b604080516370a0823160e01b815230600482015290516000916001600160a01b038516916370a0823191602480820192602092909190829003018186803b15801561426457600080fd5b505afa158015614278573d6000803e3d6000fd5b505050506040513d602081101561428e57600080fd5b50519050818110156142e0576040805162461bcd60e51b815260206004820152601660248201527508e967440c4c2d8c2dcc6ca40dcdee840cadcdeeaced60531b604482015290519081900360640190fd5b6131296001600160a01b038416858463ffffffff614ea716565b6000908152600160205260409020546001600160a01b0316151590565b600061432282611eb8565b9050806001600160a01b0316836001600160a01b031614156143755760405162461bcd60e51b8152600401808060200182810382526021815260200180615f226021913960400191505060405180910390fd5b336001600160a01b038216148061439157506143918133614008565b6143cc5760405162461bcd60e51b8152600401808060200182810382526038815260200180615d636038913960400191505060405180910390fd5b60008281526002602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b614431826142fa565b61446c5760405162461bcd60e51b815260040180806020018281038252602c815260200180615e5c602c913960400191505060405180910390fd5b6000828152600a60209081526040909120825161196492840190615a50565b6001600160801b0381166144dd576040805162461bcd60e51b815260206004820152601460248201527311d2ce881a5b9d985b1a5908189d5b991b19525960621b604482015290519081900360640190fd5b6001600160801b038381166000818152600f602090815260408083208790556010909152902080546001600160801b03191692841692909217909155613129908590614fe2565b600061452f826142fa565b61456a5760405162461bcd60e51b815260040180806020018281038252602c815260200180615d15602c913960400191505060405180910390fd5b600061457583611eb8565b9050806001600160a01b0316846001600160a01b031614806145b05750836001600160a01b03166145a584611731565b6001600160a01b0316145b806118d557506118d58185614008565b6145c9836132cd565b806145d857506145d8826132cd565b6146135760405162461bcd60e51b8152600401808060200182810382526035815260200180615cbc6035913960400191505060405180910390fd5b611964838383614ff5565b61462f600c8263ffffffff61504b16565b6040516001600160a01b038216907f80c0b871b97b595b16a7741c1b06fed0c6f6f558639f18ccbce50724325dc40d90600090a250565b614677600e8263ffffffff61504b16565b6040516001600160a01b038216907fde8cf212af7ce38b2840785a2768d97ff2dbf3c21b516961cec0061e134c2a1e90600090a250565b80516117e8906009906020840190615a50565b60006001600160a01b0382166147085760405162461bcd60e51b8152600401808060200182810382526022815260200180615ea86022913960400191505060405180910390fd5b506001600160a01b03166000908152602091909152604090205460ff1690565b5490565b6001600160801b03851661477d576040805162461bcd60e51b815260206004820152601360248201527211d2ce881a5b9d985b1a59081bdc99195c9259606a1b604482015290519081900360640190fd5b6001600160801b0380861660009081526011602052604090205416156147ea576040805162461bcd60e51b815260206004820152601c60248201527f474b3a206f726465722068617320616c72656164792065786973747300000000604482015290519081900360640190fd5b6001600160801b03841661483a576040805162461bcd60e51b815260206004820152601260248201527111d2ce881a5b9d985b1a590819dbdbd9125960721b604482015290519081900360640190fd5b815183511461488b576040805162461bcd60e51b815260206004820152601860248201527708e967440d2dcecc2d8d2c840c2e4e4c2f240d8cadccee8d60431b604482015290519081900360640190fd5b6001600160801b03808216600090815260156020526040902054166148f0576040805162461bcd60e51b8152602060048201526016602482015275474b3a20696e76616c69642073797374656d2066656560501b604482015290519081900360640190fd5b5050505050565b60005b815181146148f0576001600160a01b038516156149c457846001600160a01b03166342842e0e858585858151811061492e57fe5b60200260200101516040518463ffffffff1660e01b815260040180846001600160a01b03166001600160a01b03168152602001836001600160a01b03166001600160a01b03168152602001826001600160801b031681526020019350505050600060405180830381600087803b1580156149a757600080fd5b505af11580156149bb573d6000803e3d6000fd5b505050506149eb565b6149eb84848484815181106149d557fe5b60200260200101516001600160801b0316611e0e565b6001016148fa565b604051806101600160405280896001600160801b03168152602001878152602001336001600160a01b0316815260200160006001600160a01b0316815260200186815260200185815260200160006001600160a01b0316815260200160008152602001846001811115614a6257fe5b8152602001836001811115614a7357fe5b8152602001600090526001600160801b038981166000908152601160209081526040909120835181546001600160801b0319169316929092178255828101518051614ac49260018501920190615abe565b5060408201516002820180546001600160a01b039283166001600160a01b031991821617909155606084015160038401805491909316911617905560808201518051614b1a916004840191602090910190615b72565b5060a08201518051614b36916005840191602090910190615bc7565b5060c08201516006820180546001600160a01b0319166001600160a01b0390921691909117905560e0820151600782015561010082015160088201805460ff191660018381811115614b8457fe5b021790555061012082015160088201805461ff001916610100836001811115614ba957fe5b021790555061014082015160088201805462ff0000191662010000836003811115614bd057fe5b021790555050506001600160801b03888116600081815260166020908152604080832080546001600160801b03199081168888161790915560128352928190208054909316948c16949094179091558251338152925191927fb1a25994da8bb64efd778ed0dda424120106ae005c1d9dd60161455a1963d638929081900390910190a25050505050505050565b614c6e600c8263ffffffff6150b216565b6040516001600160a01b038216907fac6fa858e9350a46cec16539926e0fde25b7629f84b5a72bffaae4df888ae86d90600090a250565b6001600160a01b038216331415614d03576040805162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c657200000000000000604482015290519081900360640190fd5b3360008181526004602090815260408083206001600160a01b03871680855290835292819020805460ff1916861515908117909155815190815290519293927f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31929181900390910190a35050565b614d7c8484846145c0565b614d8884848484615133565b6131295760405162461bcd60e51b8152600401808060200182810382526032815260200180615c646032913960400191505060405180910390fd5b600082614dd257506000611f0c565b82820282848281614ddf57fe5b0414614e1c5760405162461bcd60e51b8152600401808060200182810382526021815260200180615e0f6021913960400191505060405180910390fd5b9392505050565b6000614e1c83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061534f565b6000614e1c83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506153f1565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261196490849061544b565b6001600160a01b038116614f3e5760405162461bcd60e51b8152600401808060200182810382526026815260200180615c966026913960400191505060405180910390fd5b600b546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600b80546001600160a01b0319166001600160a01b0392909216919091179055565b614fab600e8263ffffffff6150b216565b6040516001600160a01b038216907f4790a4adb426ca2345bb5108f6e454eae852a7bf687544cd66a7270dff3a41d690600090a250565b614fec82826155a0565b6117e8816156d1565b600d5460ff1615615040576040805162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015290519081900360640190fd5b611964838383615715565b61505582826146c1565b6150905760405162461bcd60e51b8152600401808060200182810382526021815260200180615dee6021913960400191505060405180910390fd5b6001600160a01b0316600090815260209190915260409020805460ff19169055565b6150bc82826146c1565b1561510e576040805162461bcd60e51b815260206004820152601f60248201527f526f6c65733a206163636f756e7420616c72656164792068617320726f6c6500604482015290519081900360640190fd5b6001600160a01b0316600090815260209190915260409020805460ff19166001179055565b6000615147846001600160a01b0316615859565b615153575060016118d5565b60405133602482018181526001600160a01b03888116604485015260648401879052608060848501908152865160a48601528651600095606095938b1694630a85bd0160e11b94938d938c938c93929160c49091019060208501908083838f5b838110156151cb5781810151838201526020016151b3565b50505050905090810190601f1680156151f85780820380516001836020036101000a031916815260200191505b5060408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909a16999099178952518151919890975087965094509250829150849050835b602083106152605780518252601f199092019160209182019101615241565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146152c2576040519150601f19603f3d011682016040523d82523d6000602084013e6152c7565b606091505b509150915081615318578051156152e15780518082602001fd5b60405162461bcd60e51b8152600401808060200182810382526032815260200180615c646032913960400191505060405180910390fd5b600081806020019051602081101561532f57600080fd5b50516001600160e01b031916630a85bd0160e11b1493506118d592505050565b600081836153db5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156153a0578181015183820152602001615388565b50505050905090810190601f1680156153cd5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816153e757fe5b0495945050505050565b600081848411156154435760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156153a0578181015183820152602001615388565b505050900390565b60006060836001600160a01b0316836040518082805190602001908083835b602083106154895780518252601f19909201916020918201910161546a565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146154eb576040519150601f19603f3d011682016040523d82523d6000602084013e6154f0565b606091505b509150915081615547576040805162461bcd60e51b815260206004820181905260248201527f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564604482015290519081900360640190fd5b8051156131295780806020019051602081101561556357600080fd5b50516131295760405162461bcd60e51b815260040180806020018281038252602a815260200180615f74602a913960400191505060405180910390fd5b6001600160a01b0382166155fb576040805162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f2061646472657373604482015290519081900360640190fd5b615604816142fa565b15615656576040805162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604482015290519081900360640190fd5b600081815260016020908152604080832080546001600160a01b0319166001600160a01b03871690811790915583526003909152902061569590615892565b60405181906001600160a01b038416906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b600580546000838152600660205260408120829055600182018355919091527f036b6384b5eca791c62761152d0c79bb0604c104a5fb6f4eb0703f3154bb3db00155565b826001600160a01b031661572882611eb8565b6001600160a01b03161461576d5760405162461bcd60e51b8152600401808060200182810382526029815260200180615eca6029913960400191505060405180910390fd5b6001600160a01b0382166157b25760405162461bcd60e51b8152600401808060200182810382526024815260200180615cf16024913960400191505060405180910390fd5b6157bb8161589b565b6001600160a01b03831660009081526003602052604090206157dc906158d6565b6001600160a01b03821660009081526003602052604090206157fd90615892565b60008181526001602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a4708181148015906118d5575050151592915050565b80546001019055565b6000818152600260205260409020546001600160a01b03161561238157600090815260026020526040902080546001600160a01b0319169055565b80546158e990600163ffffffff614e6516565b9055565b60405180610160016040528060006001600160801b031681526020016060815260200160006001600160a01b0316815260200160006001600160a01b03168152602001606081526020016060815260200160006001600160a01b03168152602001600081526020016000600181111561596257fe5b8152602001600081526020016000905290565b8280548282559060005260206000209081019282156159c8579160200282015b828111156159c85781546001600160a01b0319166001600160a01b03843516178255602090920191600190910190615995565b506159d4929150615c01565b5090565b828054828255906000526020600020908101928215615a13579160200282015b82811115615a135782358255916020019190600101906159f8565b506159d4929150615c25565b604051806080016040528060006001600160801b031681526020016000815260200160008152602001600081525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10615a9157805160ff1916838001178555615a13565b82800160010185558215615a13579182015b82811115615a13578251825591602001919060010190615aa3565b82805482825590600052602060002090600101600290048101928215615b665791602002820160005b83821115615b3157835183826101000a8154816001600160801b0302191690836001600160801b031602179055509260200192601001602081600f01049283019260010302615ae7565b8015615b645782816101000a8154906001600160801b030219169055601001602081600f01049283019260010302615b31565b505b506159d4929150615c3f565b8280548282559060005260206000209081019282156159c8579160200282015b828111156159c857825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615b92565b828054828255906000526020600020908101928215615a135791602002820182811115615a13578251825591602001919060010190615aa3565b61172e91905b808211156159d45780546001600160a01b0319168155600101615c07565b61172e91905b808211156159d45760008155600101615c2b565b61172e91905b808211156159d45780546001600160801b0319168155600101615c4556fe4552433732313a207472616e7366657220746f206e6f6e20455243373231526563656976657220696d706c656d656e7465724f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524337323157686974656c6973743a2073656e646572206f7220726563697069656e74206973206e6f742077686974656c6973744552433732313a207472616e7366657220746f20746865207a65726f20616464726573734552433732313a206f70657261746f7220717565727920666f72206e6f6e6578697374656e7420746f6b656e474b3a2063616c6c6572207175657279206e6f6e6578697374656e74206f726465724552433732313a20617070726f76652063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f76656420666f7220616c6c4552433732313a2062616c616e636520717565727920666f7220746865207a65726f20616464726573734552433732313a206f776e657220717565727920666f72206e6f6e6578697374656e7420746f6b656e526f6c65733a206163636f756e7420646f6573206e6f74206861766520726f6c65536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774552433732313a20617070726f76656420717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732314d657461646174613a2055524920736574206f66206e6f6e6578697374656e7420746f6b656e4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572526f6c65733a206163636f756e7420697320746865207a65726f20616464726573734552433732313a207472616e73666572206f6620746f6b656e2074686174206973206e6f74206f776e4552433732314d657461646174613a2055524920717565727920666f72206e6f6e6578697374656e7420746f6b656e4552433732313a20617070726f76616c20746f2063757272656e74206f776e65724552433732313a207472616e736665722063616c6c6572206973206e6f74206f776e6572206e6f7220617070726f7665645361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a265627a7a723158208a36597eeba52fb7fbd5f5fb1459b9fef83535cbc3100a79a5c953ad07edbb5264736f6c63430005110032

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

00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000f47656e65736973204b696e67646f6d00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002474b000000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _name (string): Genesis Kingdom
Arg [1] : _symbol (string): GK

-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000080
Arg [2] : 000000000000000000000000000000000000000000000000000000000000000f
Arg [3] : 47656e65736973204b696e67646f6d0000000000000000000000000000000000
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [5] : 474b000000000000000000000000000000000000000000000000000000000000


Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.