ETH Price: $3,384.62 (+3.88%)

Contract

0x2bfC90b20Bad69cb3a8b1E95144Ad8295be0B6f3
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Set Approval For...195281002024-03-27 21:05:59271 days ago1711573559IN
0x2bfC90b2...95be0B6f3
0 ETH0.0011043545.34427698
Set Approval For...171845712023-05-04 3:15:47599 days ago1683170147IN
0x2bfC90b2...95be0B6f3
0 ETH0.0028675962.09204716
Set Approval For...165919692023-02-09 15:03:59683 days ago1675955039IN
0x2bfC90b2...95be0B6f3
0 ETH0.0019019241.18229293
Set Approval For...164069482023-01-14 18:50:35709 days ago1673722235IN
0x2bfC90b2...95be0B6f3
0 ETH0.0008048817.42808164
Set Approval For...157881062022-10-20 8:26:23795 days ago1666254383IN
0x2bfC90b2...95be0B6f3
0 ETH0.0009406720.36848165
Set Approval For...155511712022-09-17 5:17:47828 days ago1663391867IN
0x2bfC90b2...95be0B6f3
0 ETH0.000207894.50162854
Set Approval For...154169192022-08-26 18:28:20850 days ago1661538500IN
0x2bfC90b2...95be0B6f3
0 ETH0.0010869123.53503403
Set Approval For...154137872022-08-26 6:26:13850 days ago1661495173IN
0x2bfC90b2...95be0B6f3
0 ETH0.000131855.41381785
Set Approval For...154110632022-08-25 20:06:51851 days ago1661458011IN
0x2bfC90b2...95be0B6f3
0 ETH0.0010078321.82262543
Set Approval For...153357002022-08-13 21:06:50863 days ago1660424810IN
0x2bfC90b2...95be0B6f3
0 ETH0.0005321911.50263094
Set Approval For...151555502022-07-16 19:19:33891 days ago1657999173IN
0x2bfC90b2...95be0B6f3
0 ETH0.0009388820.32965512
Set Approval For...151432632022-07-14 21:35:31893 days ago1657834531IN
0x2bfC90b2...95be0B6f3
0 ETH0.001016641.74113314
Set Approval For...151038102022-07-08 19:22:20899 days ago1657308140IN
0x2bfC90b2...95be0B6f3
0 ETH0.0006887728.28051476
Set Approval For...150739102022-07-04 4:34:43903 days ago1656909283IN
0x2bfC90b2...95be0B6f3
0 ETH0.0005135521.15934805
Set Approval For...150490492022-06-30 6:36:21907 days ago1656570981IN
0x2bfC90b2...95be0B6f3
0 ETH0.0021382546.2995437
Set Approval For...150315432022-06-27 0:00:19911 days ago1656288019IN
0x2bfC90b2...95be0B6f3
0 ETH0.0012482427.02825131
Set Approval For...150056352022-06-22 3:33:12915 days ago1655868792IN
0x2bfC90b2...95be0B6f3
0 ETH0.0011940725.8553377
Set Approval For...149960512022-06-20 10:27:30917 days ago1655720850IN
0x2bfC90b2...95be0B6f3
0 ETH0.000694915.04672703
Set Approval For...149880802022-06-19 1:10:44919 days ago1655601044IN
0x2bfC90b2...95be0B6f3
0 ETH0.0006596527.0850288
Set Approval For...149848812022-06-18 12:08:35919 days ago1655554115IN
0x2bfC90b2...95be0B6f3
0 ETH0.0009719421.0454933
Set Approval For...149705652022-06-16 1:10:11922 days ago1655341811IN
0x2bfC90b2...95be0B6f3
0 ETH0.0016972136.74983992
Safe Transfer Fr...149006472022-06-04 2:08:36933 days ago1654308516IN
0x2bfC90b2...95be0B6f3
0 ETH0.0019506837.58833403
Safe Transfer Fr...148866062022-06-01 19:29:33936 days ago1654111773IN
0x2bfC90b2...95be0B6f3
0 ETH0.003321363.99927759
Release148823382022-06-01 2:28:17936 days ago1654050497IN
0x2bfC90b2...95be0B6f3
0 ETH0.0036444266.9070896
Safe Transfer Fr...148635982022-05-29 1:13:32940 days ago1653786812IN
0x2bfC90b2...95be0B6f3
0 ETH0.0006976913.44098514
View all transactions

Latest 18 internal transactions

Advanced mode:
Parent Transaction Hash Block
From
To
148823382022-06-01 2:28:17936 days ago1654050497
0x2bfC90b2...95be0B6f3
0.449 ETH
147758122022-05-14 20:53:44954 days ago1652561624
0x2bfC90b2...95be0B6f3
0.374 ETH
147003252022-05-02 20:11:11966 days ago1651522271
0x2bfC90b2...95be0B6f3
0.45 ETH
146742852022-04-28 17:55:23970 days ago1651168523
0x2bfC90b2...95be0B6f3
1.006 ETH
146700722022-04-28 1:56:27970 days ago1651110987
0x2bfC90b2...95be0B6f3
0.134 ETH
146609282022-04-26 15:30:30972 days ago1650987030
0x2bfC90b2...95be0B6f3
0.17 ETH
146242222022-04-20 21:01:57978 days ago1650488517
0x2bfC90b2...95be0B6f3
0.17 ETH
144651612022-03-27 0:58:241003 days ago1648342704
0x2bfC90b2...95be0B6f3
0.65 ETH
144300842022-03-21 13:56:011008 days ago1647870961
0x2bfC90b2...95be0B6f3
0.055 ETH
144067682022-03-17 22:50:471012 days ago1647557447
0x2bfC90b2...95be0B6f3
0.578 ETH
143852882022-03-14 14:31:411015 days ago1647268301
0x2bfC90b2...95be0B6f3
0.448 ETH
143851482022-03-14 14:01:231015 days ago1647266483
0x2bfC90b2...95be0B6f3
0.108 ETH
143545782022-03-09 19:54:091020 days ago1646855649
0x2bfC90b2...95be0B6f3
0.59 ETH
143406092022-03-07 15:48:161022 days ago1646668096
0x2bfC90b2...95be0B6f3
0.474 ETH
143402202022-03-07 14:24:071022 days ago1646663047
0x2bfC90b2...95be0B6f3
0.948 ETH
143224052022-03-04 19:30:141025 days ago1646422214
0x2bfC90b2...95be0B6f3
0.894 ETH
143109402022-03-03 1:00:351027 days ago1646269235
0x2bfC90b2...95be0B6f3
0.892 ETH
142983742022-03-01 2:16:211028 days ago1646100981
0x2bfC90b2...95be0B6f3
0.84 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
WildfireBears

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
Yes with 10000 runs

Other Settings:
default evmVersion
File 1 of 15 : WildfireBears-Revised.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/finance/PaymentSplitter.sol";
import "@openzeppelin/contracts/utils/Counters.sol";
import "@openzeppelin/contracts/utils/Strings.sol";

/// @author no-op.eth (nftlab: https://discord.gg/kH7Gvnr2qp)
/// @title Wildfire Bears
contract WildfireBears is ERC1155, Ownable, PaymentSplitter {
  /** Maximum number of tokens per tx */
  uint256 public constant MAX_TX = 10;
  /** Maximum amount of tokens in collection */
  uint256 public constant MAX_SUPPLY = 5555;
  /** Price per token */
  uint256 public constant COST = 0.01 ether;
  /** Name of collection */
  string public constant name = "Wildfire Bears";
  /** Symbol of collection */
  string public constant symbol = "WB";
  /** URI for the contract metadata */
  string public contractURI;
  
  /** Public sale state */
  bool public saleActive = false;

  /** Total supply */
  Counters.Counter private _supply;

  /** Notify on sale state change */
  event SaleStateChanged(bool val);
  /** Notify on presale state change */
  event PresaleStateChanged(bool val);
  /** Notify on total supply change */
  event TotalSupplyChanged(uint256 val);

  /** For URI conversions */
  using Strings for uint256;
  /** For supply count */
  using Counters for Counters.Counter;

  constructor(
    string memory _uri, 
    address[] memory shareholders, 
    uint256[] memory shares
  ) ERC1155(_uri) PaymentSplitter(shareholders, shares) {}

  /// @notice Sets public sale state
  /// @param val The new value
  function setSaleState(bool val) external onlyOwner {
    saleActive = val;
    emit SaleStateChanged(val);
  }

  /// @notice Sets the base metadata URI
  /// @param val The new URI
  function setBaseURI(string memory val) external onlyOwner {
    _setURI(val);
  }

  /// @notice Sets the contract metadata URI
  /// @param val The new URI
  function setContractURI(string memory val) external onlyOwner {
    contractURI = val;
  }

  /// @notice Returns the amount of tokens sold
  /// @return supply The number of tokens sold
  function totalSupply() public view returns (uint256) {
    return _supply.current();
  }

  /// @notice Returns the URI for a given token ID
  /// @param id The ID to return URI for
  /// @return Token URI
  function uri(uint256 id) public view override returns (string memory) {
    return string(abi.encodePacked(super.uri(id), id.toString()));
  }

  /// @notice Reserves a set of NFTs for collection owner (giveaways, etc)
  /// @param amt The amount to reserve
  function reserve(uint256 amt) external onlyOwner {
    uint256 _currentSupply = _supply.current();
    for (uint256 i = 0; i < amt; i++) {
      _supply.increment();
      _mint(msg.sender, _currentSupply + i, 1, "0x0000");
    }

    emit TotalSupplyChanged(totalSupply());
  }

  /// @notice Mints a new token in public sale
  /// @param amt The number of tokens to mint
  /// @dev Must send COST * amt in ETH
  function mint(uint256 amt) external payable {
    uint256 _currentSupply = _supply.current();
    require(saleActive, "Sale is not yet active.");
    require(amt <= MAX_TX, "Amount of tokens exceeds transaction limit.");
    require(_currentSupply + amt <= MAX_SUPPLY, "Amount exceeds supply.");
    require(COST * amt <= msg.value, "ETH sent is below cost.");

    for (uint256 i = 0; i < amt; i++) {
      _supply.increment();
      _mint(msg.sender, _currentSupply + i, 1, "0x0000");
    }

    emit TotalSupplyChanged(totalSupply());
  }
}

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

pragma solidity ^0.8.0;

/**
 * @title Counters
 * @author Matt Condon (@shrugs)
 * @dev Provides counters that can only be incremented, decremented or reset. 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;`
 */
library Counters {
    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 {
        unchecked {
            counter._value += 1;
        }
    }

    function decrement(Counter storage counter) internal {
        uint256 value = counter._value;
        require(value > 0, "Counter: decrement overflow");
        unchecked {
            counter._value = value - 1;
        }
    }

    function reset(Counter storage counter) internal {
        counter._value = 0;
    }
}

File 4 of 15 : PaymentSplitter.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (finance/PaymentSplitter.sol)

pragma solidity ^0.8.0;

import "../token/ERC20/utils/SafeERC20.sol";
import "../utils/Address.sol";
import "../utils/Context.sol";

/**
 * @title PaymentSplitter
 * @dev This contract allows to split Ether payments among a group of accounts. The sender does not need to be aware
 * that the Ether will be split in this way, since it is handled transparently by the contract.
 *
 * The split can be in equal parts or in any other arbitrary proportion. The way this is specified is by assigning each
 * account to a number of shares. Of all the Ether that this contract receives, each account will then be able to claim
 * an amount proportional to the percentage of total shares they were assigned.
 *
 * `PaymentSplitter` follows a _pull payment_ model. This means that payments are not automatically forwarded to the
 * accounts but kept in this contract, and the actual transfer is triggered as a separate step by calling the {release}
 * function.
 *
 * NOTE: This contract assumes that ERC20 tokens will behave similarly to native tokens (Ether). Rebasing tokens, and
 * tokens that apply fees during transfers, are likely to not be supported as expected. If in doubt, we encourage you
 * to run tests before sending real value to this contract.
 */
contract PaymentSplitter is Context {
    event PayeeAdded(address account, uint256 shares);
    event PaymentReleased(address to, uint256 amount);
    event ERC20PaymentReleased(IERC20 indexed token, address to, uint256 amount);
    event PaymentReceived(address from, uint256 amount);

    uint256 private _totalShares;
    uint256 private _totalReleased;

    mapping(address => uint256) private _shares;
    mapping(address => uint256) private _released;
    address[] private _payees;

    mapping(IERC20 => uint256) private _erc20TotalReleased;
    mapping(IERC20 => mapping(address => uint256)) private _erc20Released;

    /**
     * @dev Creates an instance of `PaymentSplitter` where each account in `payees` is assigned the number of shares at
     * the matching position in the `shares` array.
     *
     * All addresses in `payees` must be non-zero. Both arrays must have the same non-zero length, and there must be no
     * duplicates in `payees`.
     */
    constructor(address[] memory payees, uint256[] memory shares_) payable {
        require(payees.length == shares_.length, "PaymentSplitter: payees and shares length mismatch");
        require(payees.length > 0, "PaymentSplitter: no payees");

        for (uint256 i = 0; i < payees.length; i++) {
            _addPayee(payees[i], shares_[i]);
        }
    }

    /**
     * @dev The Ether received will be logged with {PaymentReceived} events. Note that these events are not fully
     * reliable: it's possible for a contract to receive Ether without triggering this function. This only affects the
     * reliability of the events, and not the actual splitting of Ether.
     *
     * To learn more about this see the Solidity documentation for
     * https://solidity.readthedocs.io/en/latest/contracts.html#fallback-function[fallback
     * functions].
     */
    receive() external payable virtual {
        emit PaymentReceived(_msgSender(), msg.value);
    }

    /**
     * @dev Getter for the total shares held by payees.
     */
    function totalShares() public view returns (uint256) {
        return _totalShares;
    }

    /**
     * @dev Getter for the total amount of Ether already released.
     */
    function totalReleased() public view returns (uint256) {
        return _totalReleased;
    }

    /**
     * @dev Getter for the total amount of `token` already released. `token` should be the address of an IERC20
     * contract.
     */
    function totalReleased(IERC20 token) public view returns (uint256) {
        return _erc20TotalReleased[token];
    }

    /**
     * @dev Getter for the amount of shares held by an account.
     */
    function shares(address account) public view returns (uint256) {
        return _shares[account];
    }

    /**
     * @dev Getter for the amount of Ether already released to a payee.
     */
    function released(address account) public view returns (uint256) {
        return _released[account];
    }

    /**
     * @dev Getter for the amount of `token` tokens already released to a payee. `token` should be the address of an
     * IERC20 contract.
     */
    function released(IERC20 token, address account) public view returns (uint256) {
        return _erc20Released[token][account];
    }

    /**
     * @dev Getter for the address of the payee number `index`.
     */
    function payee(uint256 index) public view returns (address) {
        return _payees[index];
    }

    /**
     * @dev Triggers a transfer to `account` of the amount of Ether they are owed, according to their percentage of the
     * total shares and their previous withdrawals.
     */
    function release(address payable account) public virtual {
        require(_shares[account] > 0, "PaymentSplitter: account has no shares");

        uint256 totalReceived = address(this).balance + totalReleased();
        uint256 payment = _pendingPayment(account, totalReceived, released(account));

        require(payment != 0, "PaymentSplitter: account is not due payment");

        _released[account] += payment;
        _totalReleased += payment;

        Address.sendValue(account, payment);
        emit PaymentReleased(account, payment);
    }

    /**
     * @dev Triggers a transfer to `account` of the amount of `token` tokens they are owed, according to their
     * percentage of the total shares and their previous withdrawals. `token` must be the address of an IERC20
     * contract.
     */
    function release(IERC20 token, address account) public virtual {
        require(_shares[account] > 0, "PaymentSplitter: account has no shares");

        uint256 totalReceived = token.balanceOf(address(this)) + totalReleased(token);
        uint256 payment = _pendingPayment(account, totalReceived, released(token, account));

        require(payment != 0, "PaymentSplitter: account is not due payment");

        _erc20Released[token][account] += payment;
        _erc20TotalReleased[token] += payment;

        SafeERC20.safeTransfer(token, account, payment);
        emit ERC20PaymentReleased(token, account, payment);
    }

    /**
     * @dev internal logic for computing the pending payment of an `account` given the token historical balances and
     * already released amounts.
     */
    function _pendingPayment(
        address account,
        uint256 totalReceived,
        uint256 alreadyReleased
    ) private view returns (uint256) {
        return (totalReceived * _shares[account]) / _totalShares - alreadyReleased;
    }

    /**
     * @dev Add a new payee to the contract.
     * @param account The address of the payee to add.
     * @param shares_ The number of shares owned by the payee.
     */
    function _addPayee(address account, uint256 shares_) private {
        require(account != address(0), "PaymentSplitter: account is the zero address");
        require(shares_ > 0, "PaymentSplitter: shares are 0");
        require(_shares[account] == 0, "PaymentSplitter: account already has shares");

        _payees.push(account);
        _shares[account] = shares_;
        _totalShares = _totalShares + shares_;
        emit PayeeAdded(account, shares_);
    }
}

File 5 of 15 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

File 6 of 15 : ERC1155.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/ERC1155.sol)

pragma solidity ^0.8.0;

import "./IERC1155.sol";
import "./IERC1155Receiver.sol";
import "./extensions/IERC1155MetadataURI.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of the basic standard multi-token.
 * See https://eips.ethereum.org/EIPS/eip-1155
 * Originally based on code by Enjin: https://github.com/enjin/erc-1155
 *
 * _Available since v3.1._
 */
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI {
    using Address for address;

    // Mapping from token ID to account balances
    mapping(uint256 => mapping(address => uint256)) private _balances;

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

    // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json
    string private _uri;

    /**
     * @dev See {_setURI}.
     */
    constructor(string memory uri_) {
        _setURI(uri_);
    }

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

    /**
     * @dev See {IERC1155MetadataURI-uri}.
     *
     * This implementation returns the same URI for *all* token types. It relies
     * on the token type ID substitution mechanism
     * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP].
     *
     * Clients calling this function must replace the `\{id\}` substring with the
     * actual token type ID.
     */
    function uri(uint256) public view virtual override returns (string memory) {
        return _uri;
    }

    /**
     * @dev See {IERC1155-balanceOf}.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function balanceOf(address account, uint256 id) public view virtual override returns (uint256) {
        require(account != address(0), "ERC1155: balance query for the zero address");
        return _balances[id][account];
    }

    /**
     * @dev See {IERC1155-balanceOfBatch}.
     *
     * Requirements:
     *
     * - `accounts` and `ids` must have the same length.
     */
    function balanceOfBatch(address[] memory accounts, uint256[] memory ids)
        public
        view
        virtual
        override
        returns (uint256[] memory)
    {
        require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch");

        uint256[] memory batchBalances = new uint256[](accounts.length);

        for (uint256 i = 0; i < accounts.length; ++i) {
            batchBalances[i] = balanceOf(accounts[i], ids[i]);
        }

        return batchBalances;
    }

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

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

    /**
     * @dev See {IERC1155-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) public virtual override {
        require(
            from == _msgSender() || isApprovedForAll(from, _msgSender()),
            "ERC1155: caller is not owner nor approved"
        );
        _safeTransferFrom(from, to, id, amount, data);
    }

    /**
     * @dev See {IERC1155-safeBatchTransferFrom}.
     */
    function safeBatchTransferFrom(
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) public virtual override {
        require(
            from == _msgSender() || isApprovedForAll(from, _msgSender()),
            "ERC1155: transfer caller is not owner nor approved"
        );
        _safeBatchTransferFrom(from, to, ids, amounts, data);
    }

    /**
     * @dev Transfers `amount` tokens of token type `id` from `from` to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `from` must have a balance of tokens of type `id` of at least `amount`.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function _safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: transfer to the zero address");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, to, _asSingletonArray(id), _asSingletonArray(amount), data);

        uint256 fromBalance = _balances[id][from];
        require(fromBalance >= amount, "ERC1155: insufficient balance for transfer");
        unchecked {
            _balances[id][from] = fromBalance - amount;
        }
        _balances[id][to] += amount;

        emit TransferSingle(operator, from, to, id, amount);

        _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data);
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function _safeBatchTransferFrom(
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");
        require(to != address(0), "ERC1155: transfer to the zero address");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, to, ids, amounts, data);

        for (uint256 i = 0; i < ids.length; ++i) {
            uint256 id = ids[i];
            uint256 amount = amounts[i];

            uint256 fromBalance = _balances[id][from];
            require(fromBalance >= amount, "ERC1155: insufficient balance for transfer");
            unchecked {
                _balances[id][from] = fromBalance - amount;
            }
            _balances[id][to] += amount;
        }

        emit TransferBatch(operator, from, to, ids, amounts);

        _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data);
    }

    /**
     * @dev Sets a new URI for all token types, by relying on the token type ID
     * substitution mechanism
     * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP].
     *
     * By this mechanism, any occurrence of the `\{id\}` substring in either the
     * URI or any of the amounts in the JSON file at said URI will be replaced by
     * clients with the token type ID.
     *
     * For example, the `https://token-cdn-domain/\{id\}.json` URI would be
     * interpreted by clients as
     * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json`
     * for token type ID 0x4cce0.
     *
     * See {uri}.
     *
     * Because these URIs cannot be meaningfully represented by the {URI} event,
     * this function emits no events.
     */
    function _setURI(string memory newuri) internal virtual {
        _uri = newuri;
    }

    /**
     * @dev Creates `amount` tokens of token type `id`, and assigns them to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function _mint(
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: mint to the zero address");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, address(0), to, _asSingletonArray(id), _asSingletonArray(amount), data);

        _balances[id][to] += amount;
        emit TransferSingle(operator, address(0), to, id, amount);

        _doSafeTransferAcceptanceCheck(operator, address(0), to, id, amount, data);
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function _mintBatch(
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: mint to the zero address");
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, address(0), to, ids, amounts, data);

        for (uint256 i = 0; i < ids.length; i++) {
            _balances[ids[i]][to] += amounts[i];
        }

        emit TransferBatch(operator, address(0), to, ids, amounts);

        _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data);
    }

    /**
     * @dev Destroys `amount` tokens of token type `id` from `from`
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `from` must have at least `amount` tokens of token type `id`.
     */
    function _burn(
        address from,
        uint256 id,
        uint256 amount
    ) internal virtual {
        require(from != address(0), "ERC1155: burn from the zero address");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, address(0), _asSingletonArray(id), _asSingletonArray(amount), "");

        uint256 fromBalance = _balances[id][from];
        require(fromBalance >= amount, "ERC1155: burn amount exceeds balance");
        unchecked {
            _balances[id][from] = fromBalance - amount;
        }

        emit TransferSingle(operator, from, address(0), id, amount);
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     */
    function _burnBatch(
        address from,
        uint256[] memory ids,
        uint256[] memory amounts
    ) internal virtual {
        require(from != address(0), "ERC1155: burn from the zero address");
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, address(0), ids, amounts, "");

        for (uint256 i = 0; i < ids.length; i++) {
            uint256 id = ids[i];
            uint256 amount = amounts[i];

            uint256 fromBalance = _balances[id][from];
            require(fromBalance >= amount, "ERC1155: burn amount exceeds balance");
            unchecked {
                _balances[id][from] = fromBalance - amount;
            }
        }

        emit TransferBatch(operator, from, address(0), ids, amounts);
    }

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

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning, as well as batched variants.
     *
     * The same hook is called on both single and batched variants. For single
     * transfers, the length of the `id` and `amount` arrays will be 1.
     *
     * Calling conditions (for each `id` and `amount` pair):
     *
     * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * of token type `id` will be  transferred to `to`.
     * - When `from` is zero, `amount` tokens of token type `id` will be minted
     * for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens of token type `id`
     * will be burned.
     * - `from` and `to` are never both zero.
     * - `ids` and `amounts` have the same, non-zero length.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address operator,
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {}

    function _doSafeTransferAcceptanceCheck(
        address operator,
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) private {
        if (to.isContract()) {
            try IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) {
                if (response != IERC1155Receiver.onERC1155Received.selector) {
                    revert("ERC1155: ERC1155Receiver rejected tokens");
                }
            } catch Error(string memory reason) {
                revert(reason);
            } catch {
                revert("ERC1155: transfer to non ERC1155Receiver implementer");
            }
        }
    }

    function _doSafeBatchTransferAcceptanceCheck(
        address operator,
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) private {
        if (to.isContract()) {
            try IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns (
                bytes4 response
            ) {
                if (response != IERC1155Receiver.onERC1155BatchReceived.selector) {
                    revert("ERC1155: ERC1155Receiver rejected tokens");
                }
            } catch Error(string memory reason) {
                revert(reason);
            } catch {
                revert("ERC1155: transfer to non ERC1155Receiver implementer");
            }
        }
    }

    function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) {
        uint256[] memory array = new uint256[](1);
        array[0] = element;

        return array;
    }
}

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

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

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

pragma solidity ^0.8.0;

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

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

File 9 of 15 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 10 of 15 : IERC1155MetadataURI.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/IERC1155MetadataURI.sol)

pragma solidity ^0.8.0;

import "../IERC1155.sol";

/**
 * @dev Interface of the optional ERC1155MetadataExtension interface, as defined
 * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP].
 *
 * _Available since v3.1._
 */
interface IERC1155MetadataURI is IERC1155 {
    /**
     * @dev Returns the URI for token type `id`.
     *
     * If the `\{id\}` substring is present in the URI, it must be replaced by
     * clients with the actual token type ID.
     */
    function uri(uint256 id) external view returns (string memory);
}

File 11 of 15 : IERC1155Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev _Available since v3.1._
 */
interface IERC1155Receiver is IERC165 {
    /**
     * @dev Handles the receipt of a single ERC1155 token type. This function is
     * called at the end of a `safeTransferFrom` after the balance has been updated.
     *
     * NOTE: To accept the transfer, this must return
     * `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))`
     * (i.e. 0xf23a6e61, or its own function selector).
     *
     * @param operator The address which initiated the transfer (i.e. msg.sender)
     * @param from The address which previously owned the token
     * @param id The ID of the token being transferred
     * @param value The amount of tokens being transferred
     * @param data Additional data with no specified format
     * @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed
     */
    function onERC1155Received(
        address operator,
        address from,
        uint256 id,
        uint256 value,
        bytes calldata data
    ) external returns (bytes4);

    /**
     * @dev Handles the receipt of a multiple ERC1155 token types. This function
     * is called at the end of a `safeBatchTransferFrom` after the balances have
     * been updated.
     *
     * NOTE: To accept the transfer(s), this must return
     * `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))`
     * (i.e. 0xbc197c81, or its own function selector).
     *
     * @param operator The address which initiated the batch transfer (i.e. msg.sender)
     * @param from The address which previously owned the token
     * @param ids An array containing ids of each token being transferred (order and length must match values array)
     * @param values An array containing amounts of each token being transferred (order and length must match ids array)
     * @param data Additional data with no specified format
     * @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed
     */
    function onERC1155BatchReceived(
        address operator,
        address from,
        uint256[] calldata ids,
        uint256[] calldata values,
        bytes calldata data
    ) external returns (bytes4);
}

File 12 of 15 : IERC1155.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/IERC1155.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev Required interface of an ERC1155 compliant contract, as defined in the
 * https://eips.ethereum.org/EIPS/eip-1155[EIP].
 *
 * _Available since v3.1._
 */
interface IERC1155 is IERC165 {
    /**
     * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`.
     */
    event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value);

    /**
     * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all
     * transfers.
     */
    event TransferBatch(
        address indexed operator,
        address indexed from,
        address indexed to,
        uint256[] ids,
        uint256[] values
    );

    /**
     * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to
     * `approved`.
     */
    event ApprovalForAll(address indexed account, address indexed operator, bool approved);

    /**
     * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI.
     *
     * If an {URI} event was emitted for `id`, the standard
     * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value
     * returned by {IERC1155MetadataURI-uri}.
     */
    event URI(string value, uint256 indexed id);

    /**
     * @dev Returns the amount of tokens of token type `id` owned by `account`.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function balanceOf(address account, uint256 id) external view returns (uint256);

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}.
     *
     * Requirements:
     *
     * - `accounts` and `ids` must have the same length.
     */
    function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids)
        external
        view
        returns (uint256[] memory);

    /**
     * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`,
     *
     * Emits an {ApprovalForAll} event.
     *
     * Requirements:
     *
     * - `operator` cannot be the caller.
     */
    function setApprovalForAll(address operator, bool approved) external;

    /**
     * @dev Returns true if `operator` is approved to transfer ``account``'s tokens.
     *
     * See {setApprovalForAll}.
     */
    function isApprovedForAll(address account, address operator) external view returns (bool);

    /**
     * @dev Transfers `amount` tokens of token type `id` from `from` to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - If the caller is not `from`, it must be have been approved to spend ``from``'s tokens via {setApprovalForAll}.
     * - `from` must have a balance of tokens of type `id` of at least `amount`.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes calldata data
    ) external;

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function safeBatchTransferFrom(
        address from,
        address to,
        uint256[] calldata ids,
        uint256[] calldata amounts,
        bytes calldata data
    ) external;
}

File 13 of 15 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

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

/**
 * @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 IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    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));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    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'
        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) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - 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. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

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

pragma solidity ^0.8.0;

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

File 15 of 15 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

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

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

    /**
     * @dev Moves `amount` tokens from the caller's account to `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, 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 `from` to `to` 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 from,
        address to,
        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);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"string","name":"_uri","type":"string"},{"internalType":"address[]","name":"shareholders","type":"address[]"},{"internalType":"uint256[]","name":"shares","type":"uint256[]"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","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":"contract IERC20","name":"token","type":"address"},{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ERC20PaymentReleased","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"},{"indexed":false,"internalType":"uint256","name":"shares","type":"uint256"}],"name":"PayeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PaymentReleased","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"val","type":"bool"}],"name":"PresaleStateChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"val","type":"bool"}],"name":"SaleStateChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"val","type":"uint256"}],"name":"TotalSupplyChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[],"name":"COST","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amt","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"payee","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address payable","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"account","type":"address"}],"name":"release","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"},{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"released","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amt","type":"uint256"}],"name":"reserve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"saleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"val","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"val","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"val","type":"bool"}],"name":"setSaleState","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"shares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalReleased","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]

6080604052600c805460ff191690553480156200001b57600080fd5b50604051620039f4380380620039f48339810160408190526200003e9162000599565b8181846200004c8162000195565b506200005833620001ae565b8051825114620000ca5760405162461bcd60e51b815260206004820152603260248201527f5061796d656e7453706c69747465723a2070617965657320616e6420736861726044820152710cae640d8cadccee8d040dad2e6dac2e8c6d60731b60648201526084015b60405180910390fd5b60008251116200011d5760405162461bcd60e51b815260206004820152601a60248201527f5061796d656e7453706c69747465723a206e6f207061796565730000000000006044820152606401620000c1565b60005b82518110156200018957620001748382815181106200014357620001436200078a565b60200260200101518383815181106200016057620001606200078a565b60200260200101516200020060201b60201c565b80620001808162000756565b91505062000120565b505050505050620007b6565b8051620001aa906002906020840190620003ee565b5050565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0382166200026d5760405162461bcd60e51b815260206004820152602c60248201527f5061796d656e7453706c69747465723a206163636f756e74206973207468652060448201526b7a65726f206164647265737360a01b6064820152608401620000c1565b60008111620002bf5760405162461bcd60e51b815260206004820152601d60248201527f5061796d656e7453706c69747465723a207368617265732061726520300000006044820152606401620000c1565b6001600160a01b038216600090815260066020526040902054156200033b5760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e7420616c726561647960448201526a206861732073686172657360a81b6064820152608401620000c1565b60088054600181019091557ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30180546001600160a01b0319166001600160a01b0384169081179091556000908152600660205260409020819055600454620003a5908290620006fe565b600455604080516001600160a01b0384168152602081018390527f40c340f65e17194d14ddddb073d3c9f888e3cb52b5aae0c6c7706b4fbc905fac910160405180910390a15050565b828054620003fc9062000719565b90600052602060002090601f0160209004810192826200042057600085556200046b565b82601f106200043b57805160ff19168380011785556200046b565b828001600101855582156200046b579182015b828111156200046b5782518255916020019190600101906200044e565b50620004799291506200047d565b5090565b5b808211156200047957600081556001016200047e565b600082601f830112620004a657600080fd5b81516020620004bf620004b983620006d8565b620006a5565b80838252828201915082860187848660051b8901011115620004e057600080fd5b6000805b86811015620005175782516001600160a01b038116811462000504578283fd5b85529385019391850191600101620004e4565b509198975050505050505050565b600082601f8301126200053757600080fd5b815160206200054a620004b983620006d8565b80838252828201915082860187848660051b89010111156200056b57600080fd5b60005b858110156200058c578151845292840192908401906001016200056e565b5090979650505050505050565b600080600060608486031215620005af57600080fd5b83516001600160401b0380821115620005c757600080fd5b818601915086601f830112620005dc57600080fd5b815181811115620005f157620005f1620007a0565b602062000607601f8301601f19168201620006a5565b82815289828487010111156200061c57600080fd5b60005b838110156200063c5785810183015182820184015282016200061f565b838111156200064e5760008385840101525b5090880151909650925050808211156200066757600080fd5b620006758783880162000494565b935060408601519150808211156200068c57600080fd5b506200069b8682870162000525565b9150509250925092565b604051601f8201601f191681016001600160401b0381118282101715620006d057620006d0620007a0565b604052919050565b60006001600160401b03821115620006f457620006f4620007a0565b5060051b60200190565b6000821982111562000714576200071462000774565b500190565b600181811c908216806200072e57607f821691505b602082108114156200075057634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156200076d576200076d62000774565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b61322e80620007c66000396000f3fe6080604052600436106102015760003560e01c80638b83209b1161011d578063c4e37095116100b0578063e8a3d4851161007f578063f242432a11610064578063f242432a146106ee578063f2fde38b1461070e578063f3b2db3f1461072e57600080fd5b8063e8a3d48514610690578063e985e9c5146106a557600080fd5b8063c4e37095146105ef578063ce7c2ac21461060f578063d79779b214610645578063e33b7de31461067b57600080fd5b80639852595c116100ec5780639852595c1461056b578063a0712d68146105a1578063a22cb465146105b4578063bf8fbbd2146105d457600080fd5b80638b83209b146104ac5780638da5cb5b146104e4578063938e3d7b1461050257806395d89b411461052257600080fd5b80633a98ef391161019557806355f804b31161016457806355f804b31461043d57806368428a1b1461045d578063715018a614610477578063819b25ba1461048c57600080fd5b80633a98ef3914610395578063406072a9146103aa57806348b75044146103f05780634e1273f41461041057600080fd5b806318160ddd116101d157806318160ddd14610328578063191655871461033d5780632eb2c2d61461035f57806332cb6b0c1461037f57600080fd5b8062fdd58e1461024f57806301ffc9a71461028257806306fdde03146102b25780630e89341c1461030857600080fd5b3661024a577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be77033604080516001600160a01b0390921682523460208301520160405180910390a1005b600080fd5b34801561025b57600080fd5b5061026f61026a366004612abf565b610743565b6040519081526020015b60405180910390f35b34801561028e57600080fd5b506102a261029d366004612bf8565b6107ec565b6040519015158152602001610279565b3480156102be57600080fd5b506102fb6040518060400160405280600e81526020017f57696c646669726520426561727300000000000000000000000000000000000081525081565b6040516102799190612e54565b34801561031457600080fd5b506102fb610323366004612c7b565b6108d1565b34801561033457600080fd5b5061026f61090c565b34801561034957600080fd5b5061035d610358366004612924565b61091c565b005b34801561036b57600080fd5b5061035d61037a36600461297a565b610af6565b34801561038b57600080fd5b5061026f6115b381565b3480156103a157600080fd5b5060045461026f565b3480156103b657600080fd5b5061026f6103c5366004612941565b6001600160a01b039182166000908152600a6020908152604080832093909416825291909152205490565b3480156103fc57600080fd5b5061035d61040b366004612941565b610b98565b34801561041c57600080fd5b5061043061042b366004612aeb565b610e45565b6040516102799190612e13565b34801561044957600080fd5b5061035d610458366004612c32565b610f83565b34801561046957600080fd5b50600c546102a29060ff1681565b34801561048357600080fd5b5061035d610fe9565b34801561049857600080fd5b5061035d6104a7366004612c7b565b61104f565b3480156104b857600080fd5b506104cc6104c7366004612c7b565b61116b565b6040516001600160a01b039091168152602001610279565b3480156104f057600080fd5b506003546001600160a01b03166104cc565b34801561050e57600080fd5b5061035d61051d366004612c32565b61119b565b34801561052e57600080fd5b506102fb6040518060400160405280600281526020017f574200000000000000000000000000000000000000000000000000000000000081525081565b34801561057757600080fd5b5061026f610586366004612924565b6001600160a01b031660009081526007602052604090205490565b61035d6105af366004612c7b565b61120c565b3480156105c057600080fd5b5061035d6105cf366004612a91565b6113d7565b3480156105e057600080fd5b5061026f662386f26fc1000081565b3480156105fb57600080fd5b5061035d61060a366004612bbe565b6113e2565b34801561061b57600080fd5b5061026f61062a366004612924565b6001600160a01b031660009081526006602052604090205490565b34801561065157600080fd5b5061026f610660366004612924565b6001600160a01b031660009081526009602052604090205490565b34801561068757600080fd5b5060055461026f565b34801561069c57600080fd5b506102fb6114a1565b3480156106b157600080fd5b506102a26106c0366004612941565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b3480156106fa57600080fd5b5061035d610709366004612a28565b61152f565b34801561071a57600080fd5b5061035d610729366004612924565b6115ca565b34801561073a57600080fd5b5061026f600a81565b60006001600160a01b0383166107c65760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201527f65726f206164647265737300000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fd9b67a2600000000000000000000000000000000000000000000000000000000148061087f57507fffffffff0000000000000000000000000000000000000000000000000000000082167f0e89341c00000000000000000000000000000000000000000000000000000000145b806108cb57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60606108dc826116a9565b6108e58361173d565b6040516020016108f6929190612d4e565b6040516020818303038152906040529050919050565b6000610917600d5490565b905090565b6001600160a01b0381166000908152600660205260409020546109a75760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f736861726573000000000000000000000000000000000000000000000000000060648201526084016107bd565b60006109b260055490565b6109bc9047612e8b565b905060006109e983836109e4866001600160a01b031660009081526007602052604090205490565b611877565b905080610a5e5760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e7400000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b03831660009081526007602052604081208054839290610a86908490612e8b565b925050819055508060056000828254610a9f9190612e8b565b90915550610aaf905083826118bf565b604080516001600160a01b0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b6001600160a01b038516331480610b125750610b1285336106c0565b610b845760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f742060448201527f6f776e6572206e6f7220617070726f766564000000000000000000000000000060648201526084016107bd565b610b9185858585856119dd565b5050505050565b6001600160a01b038116600090815260066020526040902054610c235760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f736861726573000000000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b0382166000908152600960205260408120546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038516906370a082319060240160206040518083038186803b158015610c9457600080fd5b505afa158015610ca8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ccc9190612c94565b610cd69190612e8b565b90506000610d0f83836109e487876001600160a01b039182166000908152600a6020908152604080832093909416825291909152205490565b905080610d845760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e7400000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b038085166000908152600a6020908152604080832093871683529290529081208054839290610dbb908490612e8b565b90915550506001600160a01b03841660009081526009602052604081208054839290610de8908490612e8b565b90915550610df99050848483611c7b565b604080516001600160a01b038581168252602082018490528616917f3be5b7a71e84ed12875d241991c70855ac5817d847039e17a9d895c1ceb0f18a910160405180910390a250505050565b60608151835114610ebe5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e67746860448201527f206d69736d61746368000000000000000000000000000000000000000000000060648201526084016107bd565b6000835167ffffffffffffffff811115610eda57610eda6130b4565b604051908082528060200260200182016040528015610f03578160200160208202803683370190505b50905060005b8451811015610f7b57610f4e858281518110610f2757610f27613085565b6020026020010151858381518110610f4157610f41613085565b6020026020010151610743565b828281518110610f6057610f60613085565b6020908102919091010152610f7481612fda565b9050610f09565b509392505050565b6003546001600160a01b03163314610fdd5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b610fe681611cfb565b50565b6003546001600160a01b031633146110435760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b61104d6000611d0e565b565b6003546001600160a01b031633146110a95760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b60006110b4600d5490565b905060005b8281101561112c576110cf600d80546001019055565b61111a336110dd8385612e8b565b60016040518060400160405280600681526020017f3078303030300000000000000000000000000000000000000000000000000000815250611d78565b8061112481612fda565b9150506110b9565b507fc8b17f75f53401f272e9ee7fa431e81ba33779363238896180425a422420c8f761115661090c565b60405190815260200160405180910390a15050565b60006008828154811061118057611180613085565b6000918252602090912001546001600160a01b031692915050565b6003546001600160a01b031633146111f55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b805161120890600b906020840190612778565b5050565b6000611217600d5490565b600c5490915060ff1661126c5760405162461bcd60e51b815260206004820152601760248201527f53616c65206973206e6f7420796574206163746976652e00000000000000000060448201526064016107bd565b600a8211156112e35760405162461bcd60e51b815260206004820152602b60248201527f416d6f756e74206f6620746f6b656e732065786365656473207472616e73616360448201527f74696f6e206c696d69742e00000000000000000000000000000000000000000060648201526084016107bd565b6115b36112f08383612e8b565b111561133e5760405162461bcd60e51b815260206004820152601660248201527f416d6f756e74206578636565647320737570706c792e0000000000000000000060448201526064016107bd565b3461135083662386f26fc10000612eb7565b111561139e5760405162461bcd60e51b815260206004820152601760248201527f4554482073656e742069732062656c6f7720636f73742e00000000000000000060448201526064016107bd565b60005b8281101561112c576113b7600d80546001019055565b6113c5336110dd8385612e8b565b806113cf81612fda565b9150506113a1565b611208338383611e9e565b6003546001600160a01b0316331461143c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b600c80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00168215159081179091556040519081527fe333f8a36ee86e754548af2d6f50c73ff0d501e22e6c784662123dbbe493c6029060200160405180910390a150565b600b80546114ae90612f3b565b80601f01602080910402602001604051908101604052809291908181526020018280546114da90612f3b565b80156115275780601f106114fc57610100808354040283529160200191611527565b820191906000526020600020905b81548152906001019060200180831161150a57829003601f168201915b505050505081565b6001600160a01b03851633148061154b575061154b85336106c0565b6115bd5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201527f20617070726f766564000000000000000000000000000000000000000000000060648201526084016107bd565b610b918585858585611fb1565b6003546001600160a01b031633146116245760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b6001600160a01b0381166116a05760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016107bd565b610fe681611d0e565b6060600280546116b890612f3b565b80601f01602080910402602001604051908101604052809291908181526020018280546116e490612f3b565b80156117315780601f1061170657610100808354040283529160200191611731565b820191906000526020600020905b81548152906001019060200180831161171457829003601f168201915b50505050509050919050565b60608161177d57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156117a7578061179181612fda565b91506117a09050600a83612ea3565b9150611781565b60008167ffffffffffffffff8111156117c2576117c26130b4565b6040519080825280601f01601f1916602001820160405280156117ec576020820181803683370190505b5090505b841561186f57611801600183612ef4565b915061180e600a86613013565b611819906030612e8b565b60f81b81838151811061182e5761182e613085565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611868600a86612ea3565b94506117f0565b949350505050565b6004546001600160a01b038416600090815260066020526040812054909183916118a19086612eb7565b6118ab9190612ea3565b6118b59190612ef4565b90505b9392505050565b8047101561190f5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016107bd565b6000826001600160a01b03168260405160006040518083038185875af1925050503d806000811461195c576040519150601f19603f3d011682016040523d82523d6000602084013e611961565b606091505b50509050806119d85760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016107bd565b505050565b8151835114611a545760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682060448201527f6d69736d6174636800000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b038416611ad05760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016107bd565b3360005b8451811015611c0d576000858281518110611af157611af1613085565b602002602001015190506000858381518110611b0f57611b0f613085565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015611bb55760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201527f72207472616e736665720000000000000000000000000000000000000000000060648201526084016107bd565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290611bf2908490612e8b565b9250508190555050505080611c0690612fda565b9050611ad4565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611c5d929190612e26565b60405180910390a4611c7381878787878761217a565b505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526119d89084906123ac565b8051611208906002906020840190612778565b600380546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b038416611df45760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016107bd565b33611e0e81600087611e0588612491565b610b9188612491565b6000848152602081815260408083206001600160a01b038916845290915281208054859290611e3e908490612e8b565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610b91816000878787876124dc565b816001600160a01b0316836001600160a01b03161415611f265760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c2073746174757360448201527f20666f722073656c66000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661202d5760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016107bd565b3361203d818787611e0588612491565b6000848152602081815260408083206001600160a01b038a168452909152902054838110156120d45760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201527f72207472616e736665720000000000000000000000000000000000000000000060648201526084016107bd565b6000858152602081815260408083206001600160a01b038b8116855292528083208785039055908816825281208054869290612111908490612e8b565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46121718288888888886124dc565b50505050505050565b6001600160a01b0384163b15611c73576040517fbc197c810000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063bc197c81906121d79089908990889088908890600401612d7d565b602060405180830381600087803b1580156121f157600080fd5b505af192505050801561223f575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261223c91810190612c15565b60015b6122f55761224b6130e3565b806308c379a0141561228557506122606130ff565b8061226b5750612287565b8060405162461bcd60e51b81526004016107bd9190612e54565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e204552433131353560448201527f526563656976657220696d706c656d656e74657200000000000000000000000060648201526084016107bd565b7fffffffff0000000000000000000000000000000000000000000000000000000081167fbc197c8100000000000000000000000000000000000000000000000000000000146121715760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a6563746560448201527f6420746f6b656e7300000000000000000000000000000000000000000000000060648201526084016107bd565b6000612401826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166126649092919063ffffffff16565b8051909150156119d8578080602001905181019061241f9190612bdb565b6119d85760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107bd565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106124cb576124cb613085565b602090810291909101015292915050565b6001600160a01b0384163b15611c73576040517ff23a6e610000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063f23a6e61906125399089908990889088908890600401612ddb565b602060405180830381600087803b15801561255357600080fd5b505af19250505080156125a1575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261259e91810190612c15565b60015b6125ad5761224b6130e3565b7fffffffff0000000000000000000000000000000000000000000000000000000081167ff23a6e6100000000000000000000000000000000000000000000000000000000146121715760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a6563746560448201527f6420746f6b656e7300000000000000000000000000000000000000000000000060648201526084016107bd565b60606118b58484600085856001600160a01b0385163b6126c65760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107bd565b600080866001600160a01b031685876040516126e29190612d32565b60006040518083038185875af1925050503d806000811461271f576040519150601f19603f3d011682016040523d82523d6000602084013e612724565b606091505b509150915061273482828661273f565b979650505050505050565b6060831561274e5750816118b8565b82511561275e5782518084602001fd5b8160405162461bcd60e51b81526004016107bd9190612e54565b82805461278490612f3b565b90600052602060002090601f0160209004810192826127a657600085556127ec565b82601f106127bf57805160ff19168380011785556127ec565b828001600101855582156127ec579182015b828111156127ec5782518255916020019190600101906127d1565b506127f89291506127fc565b5090565b5b808211156127f857600081556001016127fd565b600067ffffffffffffffff83111561282b5761282b6130b4565b60405161286060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8701160182612f8f565b80915083815284848401111561287557600080fd5b83836020830137600060208583010152509392505050565b600082601f83011261289e57600080fd5b813560206128ab82612e67565b6040516128b88282612f8f565b8381528281019150858301600585901b870184018810156128d857600080fd5b60005b858110156128f7578135845292840192908401906001016128db565b5090979650505050505050565b600082601f83011261291557600080fd5b6118b883833560208501612811565b60006020828403121561293657600080fd5b81356118b8816131a7565b6000806040838503121561295457600080fd5b823561295f816131a7565b9150602083013561296f816131a7565b809150509250929050565b600080600080600060a0868803121561299257600080fd5b853561299d816131a7565b945060208601356129ad816131a7565b9350604086013567ffffffffffffffff808211156129ca57600080fd5b6129d689838a0161288d565b945060608801359150808211156129ec57600080fd5b6129f889838a0161288d565b93506080880135915080821115612a0e57600080fd5b50612a1b88828901612904565b9150509295509295909350565b600080600080600060a08688031215612a4057600080fd5b8535612a4b816131a7565b94506020860135612a5b816131a7565b93506040860135925060608601359150608086013567ffffffffffffffff811115612a8557600080fd5b612a1b88828901612904565b60008060408385031215612aa457600080fd5b8235612aaf816131a7565b9150602083013561296f816131bc565b60008060408385031215612ad257600080fd5b8235612add816131a7565b946020939093013593505050565b60008060408385031215612afe57600080fd5b823567ffffffffffffffff80821115612b1657600080fd5b818501915085601f830112612b2a57600080fd5b81356020612b3782612e67565b604051612b448282612f8f565b8381528281019150858301600585901b870184018b1015612b6457600080fd5b600096505b84871015612b90578035612b7c816131a7565b835260019690960195918301918301612b69565b5096505086013592505080821115612ba757600080fd5b50612bb48582860161288d565b9150509250929050565b600060208284031215612bd057600080fd5b81356118b8816131bc565b600060208284031215612bed57600080fd5b81516118b8816131bc565b600060208284031215612c0a57600080fd5b81356118b8816131ca565b600060208284031215612c2757600080fd5b81516118b8816131ca565b600060208284031215612c4457600080fd5b813567ffffffffffffffff811115612c5b57600080fd5b8201601f81018413612c6c57600080fd5b61186f84823560208401612811565b600060208284031215612c8d57600080fd5b5035919050565b600060208284031215612ca657600080fd5b5051919050565b600081518084526020808501945080840160005b83811015612cdd57815187529582019590820190600101612cc1565b509495945050505050565b60008151808452612d00816020860160208601612f0b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251612d44818460208701612f0b565b9190910192915050565b60008351612d60818460208801612f0b565b835190830190612d74818360208801612f0b565b01949350505050565b60006001600160a01b03808816835280871660208401525060a06040830152612da960a0830186612cad565b8281036060840152612dbb8186612cad565b90508281036080840152612dcf8185612ce8565b98975050505050505050565b60006001600160a01b03808816835280871660208401525084604083015283606083015260a0608083015261273460a0830184612ce8565b6020815260006118b86020830184612cad565b604081526000612e396040830185612cad565b8281036020840152612e4b8185612cad565b95945050505050565b6020815260006118b86020830184612ce8565b600067ffffffffffffffff821115612e8157612e816130b4565b5060051b60200190565b60008219821115612e9e57612e9e613027565b500190565b600082612eb257612eb2613056565b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612eef57612eef613027565b500290565b600082821015612f0657612f06613027565b500390565b60005b83811015612f26578181015183820152602001612f0e565b83811115612f35576000848401525b50505050565b600181811c90821680612f4f57607f821691505b60208210811415612f89577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116810181811067ffffffffffffffff82111715612fd357612fd36130b4565b6040525050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561300c5761300c613027565b5060010190565b60008261302257613022613056565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060033d11156130fc5760046000803e5060005160e01c5b90565b600060443d101561310d5790565b6040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc803d016004833e81513d67ffffffffffffffff816024840111818411171561315b57505050505090565b82850191508151818111156131735750505050505090565b843d870101602082850101111561318d5750505050505090565b61319c60208286010187612f8f565b509095945050505050565b6001600160a01b0381168114610fe657600080fd5b8015158114610fe657600080fd5b7fffffffff0000000000000000000000000000000000000000000000000000000081168114610fe657600080fdfea2646970667358221220c90f943f5dfc7cf70e16e0753bea2aa7d7ffeb5271d0c87e91fc871aabd108ce64736f6c63430008070033000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000036697066733a2f2f516d626d34343632614579444e4e736365784764646a384d326d773450747a714238374644704a726263713373442f0000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000000000000000000006b99d2b10f3cc0ce6b871a9f5f94e1ecd6222f470000000000000000000000001e4767178a080adad8731a2f6ec717dbc749b70b000000000000000000000000520796a72f9dff8946b37df55f6652e196360a09000000000000000000000000021a32988aa016abc2f2a90c4be2b8e9415398410000000000000000000000006e628cbfca3aeaffe64ca9361316c914dd911ecb00000000000000000000000084645b7e66c4a51c7f163d8c295ae45a3b47e7b600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000a

Deployed Bytecode

0x6080604052600436106102015760003560e01c80638b83209b1161011d578063c4e37095116100b0578063e8a3d4851161007f578063f242432a11610064578063f242432a146106ee578063f2fde38b1461070e578063f3b2db3f1461072e57600080fd5b8063e8a3d48514610690578063e985e9c5146106a557600080fd5b8063c4e37095146105ef578063ce7c2ac21461060f578063d79779b214610645578063e33b7de31461067b57600080fd5b80639852595c116100ec5780639852595c1461056b578063a0712d68146105a1578063a22cb465146105b4578063bf8fbbd2146105d457600080fd5b80638b83209b146104ac5780638da5cb5b146104e4578063938e3d7b1461050257806395d89b411461052257600080fd5b80633a98ef391161019557806355f804b31161016457806355f804b31461043d57806368428a1b1461045d578063715018a614610477578063819b25ba1461048c57600080fd5b80633a98ef3914610395578063406072a9146103aa57806348b75044146103f05780634e1273f41461041057600080fd5b806318160ddd116101d157806318160ddd14610328578063191655871461033d5780632eb2c2d61461035f57806332cb6b0c1461037f57600080fd5b8062fdd58e1461024f57806301ffc9a71461028257806306fdde03146102b25780630e89341c1461030857600080fd5b3661024a577f6ef95f06320e7a25a04a175ca677b7052bdd97131872c2192525a629f51be77033604080516001600160a01b0390921682523460208301520160405180910390a1005b600080fd5b34801561025b57600080fd5b5061026f61026a366004612abf565b610743565b6040519081526020015b60405180910390f35b34801561028e57600080fd5b506102a261029d366004612bf8565b6107ec565b6040519015158152602001610279565b3480156102be57600080fd5b506102fb6040518060400160405280600e81526020017f57696c646669726520426561727300000000000000000000000000000000000081525081565b6040516102799190612e54565b34801561031457600080fd5b506102fb610323366004612c7b565b6108d1565b34801561033457600080fd5b5061026f61090c565b34801561034957600080fd5b5061035d610358366004612924565b61091c565b005b34801561036b57600080fd5b5061035d61037a36600461297a565b610af6565b34801561038b57600080fd5b5061026f6115b381565b3480156103a157600080fd5b5060045461026f565b3480156103b657600080fd5b5061026f6103c5366004612941565b6001600160a01b039182166000908152600a6020908152604080832093909416825291909152205490565b3480156103fc57600080fd5b5061035d61040b366004612941565b610b98565b34801561041c57600080fd5b5061043061042b366004612aeb565b610e45565b6040516102799190612e13565b34801561044957600080fd5b5061035d610458366004612c32565b610f83565b34801561046957600080fd5b50600c546102a29060ff1681565b34801561048357600080fd5b5061035d610fe9565b34801561049857600080fd5b5061035d6104a7366004612c7b565b61104f565b3480156104b857600080fd5b506104cc6104c7366004612c7b565b61116b565b6040516001600160a01b039091168152602001610279565b3480156104f057600080fd5b506003546001600160a01b03166104cc565b34801561050e57600080fd5b5061035d61051d366004612c32565b61119b565b34801561052e57600080fd5b506102fb6040518060400160405280600281526020017f574200000000000000000000000000000000000000000000000000000000000081525081565b34801561057757600080fd5b5061026f610586366004612924565b6001600160a01b031660009081526007602052604090205490565b61035d6105af366004612c7b565b61120c565b3480156105c057600080fd5b5061035d6105cf366004612a91565b6113d7565b3480156105e057600080fd5b5061026f662386f26fc1000081565b3480156105fb57600080fd5b5061035d61060a366004612bbe565b6113e2565b34801561061b57600080fd5b5061026f61062a366004612924565b6001600160a01b031660009081526006602052604090205490565b34801561065157600080fd5b5061026f610660366004612924565b6001600160a01b031660009081526009602052604090205490565b34801561068757600080fd5b5060055461026f565b34801561069c57600080fd5b506102fb6114a1565b3480156106b157600080fd5b506102a26106c0366004612941565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b3480156106fa57600080fd5b5061035d610709366004612a28565b61152f565b34801561071a57600080fd5b5061035d610729366004612924565b6115ca565b34801561073a57600080fd5b5061026f600a81565b60006001600160a01b0383166107c65760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201527f65726f206164647265737300000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167fd9b67a2600000000000000000000000000000000000000000000000000000000148061087f57507fffffffff0000000000000000000000000000000000000000000000000000000082167f0e89341c00000000000000000000000000000000000000000000000000000000145b806108cb57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b60606108dc826116a9565b6108e58361173d565b6040516020016108f6929190612d4e565b6040516020818303038152906040529050919050565b6000610917600d5490565b905090565b6001600160a01b0381166000908152600660205260409020546109a75760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f736861726573000000000000000000000000000000000000000000000000000060648201526084016107bd565b60006109b260055490565b6109bc9047612e8b565b905060006109e983836109e4866001600160a01b031660009081526007602052604090205490565b611877565b905080610a5e5760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e7400000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b03831660009081526007602052604081208054839290610a86908490612e8b565b925050819055508060056000828254610a9f9190612e8b565b90915550610aaf905083826118bf565b604080516001600160a01b0385168152602081018390527fdf20fd1e76bc69d672e4814fafb2c449bba3a5369d8359adf9e05e6fde87b056910160405180910390a1505050565b6001600160a01b038516331480610b125750610b1285336106c0565b610b845760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f742060448201527f6f776e6572206e6f7220617070726f766564000000000000000000000000000060648201526084016107bd565b610b9185858585856119dd565b5050505050565b6001600160a01b038116600090815260066020526040902054610c235760405162461bcd60e51b815260206004820152602660248201527f5061796d656e7453706c69747465723a206163636f756e7420686173206e6f2060448201527f736861726573000000000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b0382166000908152600960205260408120546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038516906370a082319060240160206040518083038186803b158015610c9457600080fd5b505afa158015610ca8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ccc9190612c94565b610cd69190612e8b565b90506000610d0f83836109e487876001600160a01b039182166000908152600a6020908152604080832093909416825291909152205490565b905080610d845760405162461bcd60e51b815260206004820152602b60248201527f5061796d656e7453706c69747465723a206163636f756e74206973206e6f742060448201527f647565207061796d656e7400000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b038085166000908152600a6020908152604080832093871683529290529081208054839290610dbb908490612e8b565b90915550506001600160a01b03841660009081526009602052604081208054839290610de8908490612e8b565b90915550610df99050848483611c7b565b604080516001600160a01b038581168252602082018490528616917f3be5b7a71e84ed12875d241991c70855ac5817d847039e17a9d895c1ceb0f18a910160405180910390a250505050565b60608151835114610ebe5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e67746860448201527f206d69736d61746368000000000000000000000000000000000000000000000060648201526084016107bd565b6000835167ffffffffffffffff811115610eda57610eda6130b4565b604051908082528060200260200182016040528015610f03578160200160208202803683370190505b50905060005b8451811015610f7b57610f4e858281518110610f2757610f27613085565b6020026020010151858381518110610f4157610f41613085565b6020026020010151610743565b828281518110610f6057610f60613085565b6020908102919091010152610f7481612fda565b9050610f09565b509392505050565b6003546001600160a01b03163314610fdd5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b610fe681611cfb565b50565b6003546001600160a01b031633146110435760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b61104d6000611d0e565b565b6003546001600160a01b031633146110a95760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b60006110b4600d5490565b905060005b8281101561112c576110cf600d80546001019055565b61111a336110dd8385612e8b565b60016040518060400160405280600681526020017f3078303030300000000000000000000000000000000000000000000000000000815250611d78565b8061112481612fda565b9150506110b9565b507fc8b17f75f53401f272e9ee7fa431e81ba33779363238896180425a422420c8f761115661090c565b60405190815260200160405180910390a15050565b60006008828154811061118057611180613085565b6000918252602090912001546001600160a01b031692915050565b6003546001600160a01b031633146111f55760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b805161120890600b906020840190612778565b5050565b6000611217600d5490565b600c5490915060ff1661126c5760405162461bcd60e51b815260206004820152601760248201527f53616c65206973206e6f7420796574206163746976652e00000000000000000060448201526064016107bd565b600a8211156112e35760405162461bcd60e51b815260206004820152602b60248201527f416d6f756e74206f6620746f6b656e732065786365656473207472616e73616360448201527f74696f6e206c696d69742e00000000000000000000000000000000000000000060648201526084016107bd565b6115b36112f08383612e8b565b111561133e5760405162461bcd60e51b815260206004820152601660248201527f416d6f756e74206578636565647320737570706c792e0000000000000000000060448201526064016107bd565b3461135083662386f26fc10000612eb7565b111561139e5760405162461bcd60e51b815260206004820152601760248201527f4554482073656e742069732062656c6f7720636f73742e00000000000000000060448201526064016107bd565b60005b8281101561112c576113b7600d80546001019055565b6113c5336110dd8385612e8b565b806113cf81612fda565b9150506113a1565b611208338383611e9e565b6003546001600160a01b0316331461143c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b600c80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00168215159081179091556040519081527fe333f8a36ee86e754548af2d6f50c73ff0d501e22e6c784662123dbbe493c6029060200160405180910390a150565b600b80546114ae90612f3b565b80601f01602080910402602001604051908101604052809291908181526020018280546114da90612f3b565b80156115275780601f106114fc57610100808354040283529160200191611527565b820191906000526020600020905b81548152906001019060200180831161150a57829003601f168201915b505050505081565b6001600160a01b03851633148061154b575061154b85336106c0565b6115bd5760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201527f20617070726f766564000000000000000000000000000000000000000000000060648201526084016107bd565b610b918585858585611fb1565b6003546001600160a01b031633146116245760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016107bd565b6001600160a01b0381166116a05760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016107bd565b610fe681611d0e565b6060600280546116b890612f3b565b80601f01602080910402602001604051908101604052809291908181526020018280546116e490612f3b565b80156117315780601f1061170657610100808354040283529160200191611731565b820191906000526020600020905b81548152906001019060200180831161171457829003601f168201915b50505050509050919050565b60608161177d57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156117a7578061179181612fda565b91506117a09050600a83612ea3565b9150611781565b60008167ffffffffffffffff8111156117c2576117c26130b4565b6040519080825280601f01601f1916602001820160405280156117ec576020820181803683370190505b5090505b841561186f57611801600183612ef4565b915061180e600a86613013565b611819906030612e8b565b60f81b81838151811061182e5761182e613085565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611868600a86612ea3565b94506117f0565b949350505050565b6004546001600160a01b038416600090815260066020526040812054909183916118a19086612eb7565b6118ab9190612ea3565b6118b59190612ef4565b90505b9392505050565b8047101561190f5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016107bd565b6000826001600160a01b03168260405160006040518083038185875af1925050503d806000811461195c576040519150601f19603f3d011682016040523d82523d6000602084013e611961565b606091505b50509050806119d85760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016107bd565b505050565b8151835114611a545760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e6774682060448201527f6d69736d6174636800000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b038416611ad05760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016107bd565b3360005b8451811015611c0d576000858281518110611af157611af1613085565b602002602001015190506000858381518110611b0f57611b0f613085565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015611bb55760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201527f72207472616e736665720000000000000000000000000000000000000000000060648201526084016107bd565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290611bf2908490612e8b565b9250508190555050505080611c0690612fda565b9050611ad4565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611c5d929190612e26565b60405180910390a4611c7381878787878761217a565b505050505050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526119d89084906123ac565b8051611208906002906020840190612778565b600380546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b038416611df45760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016107bd565b33611e0e81600087611e0588612491565b610b9188612491565b6000848152602081815260408083206001600160a01b038916845290915281208054859290611e3e908490612e8b565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610b91816000878787876124dc565b816001600160a01b0316836001600160a01b03161415611f265760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c2073746174757360448201527f20666f722073656c66000000000000000000000000000000000000000000000060648201526084016107bd565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b03841661202d5760405162461bcd60e51b815260206004820152602560248201527f455243313135353a207472616e7366657220746f20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016107bd565b3361203d818787611e0588612491565b6000848152602081815260408083206001600160a01b038a168452909152902054838110156120d45760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60448201527f72207472616e736665720000000000000000000000000000000000000000000060648201526084016107bd565b6000858152602081815260408083206001600160a01b038b8116855292528083208785039055908816825281208054869290612111908490612e8b565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46121718288888888886124dc565b50505050505050565b6001600160a01b0384163b15611c73576040517fbc197c810000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063bc197c81906121d79089908990889088908890600401612d7d565b602060405180830381600087803b1580156121f157600080fd5b505af192505050801561223f575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261223c91810190612c15565b60015b6122f55761224b6130e3565b806308c379a0141561228557506122606130ff565b8061226b5750612287565b8060405162461bcd60e51b81526004016107bd9190612e54565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e204552433131353560448201527f526563656976657220696d706c656d656e74657200000000000000000000000060648201526084016107bd565b7fffffffff0000000000000000000000000000000000000000000000000000000081167fbc197c8100000000000000000000000000000000000000000000000000000000146121715760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a6563746560448201527f6420746f6b656e7300000000000000000000000000000000000000000000000060648201526084016107bd565b6000612401826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166126649092919063ffffffff16565b8051909150156119d8578080602001905181019061241f9190612bdb565b6119d85760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107bd565b604080516001808252818301909252606091600091906020808301908036833701905050905082816000815181106124cb576124cb613085565b602090810291909101015292915050565b6001600160a01b0384163b15611c73576040517ff23a6e610000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063f23a6e61906125399089908990889088908890600401612ddb565b602060405180830381600087803b15801561255357600080fd5b505af19250505080156125a1575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820190925261259e91810190612c15565b60015b6125ad5761224b6130e3565b7fffffffff0000000000000000000000000000000000000000000000000000000081167ff23a6e6100000000000000000000000000000000000000000000000000000000146121715760405162461bcd60e51b815260206004820152602860248201527f455243313135353a204552433131353552656365697665722072656a6563746560448201527f6420746f6b656e7300000000000000000000000000000000000000000000000060648201526084016107bd565b60606118b58484600085856001600160a01b0385163b6126c65760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107bd565b600080866001600160a01b031685876040516126e29190612d32565b60006040518083038185875af1925050503d806000811461271f576040519150601f19603f3d011682016040523d82523d6000602084013e612724565b606091505b509150915061273482828661273f565b979650505050505050565b6060831561274e5750816118b8565b82511561275e5782518084602001fd5b8160405162461bcd60e51b81526004016107bd9190612e54565b82805461278490612f3b565b90600052602060002090601f0160209004810192826127a657600085556127ec565b82601f106127bf57805160ff19168380011785556127ec565b828001600101855582156127ec579182015b828111156127ec5782518255916020019190600101906127d1565b506127f89291506127fc565b5090565b5b808211156127f857600081556001016127fd565b600067ffffffffffffffff83111561282b5761282b6130b4565b60405161286060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8701160182612f8f565b80915083815284848401111561287557600080fd5b83836020830137600060208583010152509392505050565b600082601f83011261289e57600080fd5b813560206128ab82612e67565b6040516128b88282612f8f565b8381528281019150858301600585901b870184018810156128d857600080fd5b60005b858110156128f7578135845292840192908401906001016128db565b5090979650505050505050565b600082601f83011261291557600080fd5b6118b883833560208501612811565b60006020828403121561293657600080fd5b81356118b8816131a7565b6000806040838503121561295457600080fd5b823561295f816131a7565b9150602083013561296f816131a7565b809150509250929050565b600080600080600060a0868803121561299257600080fd5b853561299d816131a7565b945060208601356129ad816131a7565b9350604086013567ffffffffffffffff808211156129ca57600080fd5b6129d689838a0161288d565b945060608801359150808211156129ec57600080fd5b6129f889838a0161288d565b93506080880135915080821115612a0e57600080fd5b50612a1b88828901612904565b9150509295509295909350565b600080600080600060a08688031215612a4057600080fd5b8535612a4b816131a7565b94506020860135612a5b816131a7565b93506040860135925060608601359150608086013567ffffffffffffffff811115612a8557600080fd5b612a1b88828901612904565b60008060408385031215612aa457600080fd5b8235612aaf816131a7565b9150602083013561296f816131bc565b60008060408385031215612ad257600080fd5b8235612add816131a7565b946020939093013593505050565b60008060408385031215612afe57600080fd5b823567ffffffffffffffff80821115612b1657600080fd5b818501915085601f830112612b2a57600080fd5b81356020612b3782612e67565b604051612b448282612f8f565b8381528281019150858301600585901b870184018b1015612b6457600080fd5b600096505b84871015612b90578035612b7c816131a7565b835260019690960195918301918301612b69565b5096505086013592505080821115612ba757600080fd5b50612bb48582860161288d565b9150509250929050565b600060208284031215612bd057600080fd5b81356118b8816131bc565b600060208284031215612bed57600080fd5b81516118b8816131bc565b600060208284031215612c0a57600080fd5b81356118b8816131ca565b600060208284031215612c2757600080fd5b81516118b8816131ca565b600060208284031215612c4457600080fd5b813567ffffffffffffffff811115612c5b57600080fd5b8201601f81018413612c6c57600080fd5b61186f84823560208401612811565b600060208284031215612c8d57600080fd5b5035919050565b600060208284031215612ca657600080fd5b5051919050565b600081518084526020808501945080840160005b83811015612cdd57815187529582019590820190600101612cc1565b509495945050505050565b60008151808452612d00816020860160208601612f0b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60008251612d44818460208701612f0b565b9190910192915050565b60008351612d60818460208801612f0b565b835190830190612d74818360208801612f0b565b01949350505050565b60006001600160a01b03808816835280871660208401525060a06040830152612da960a0830186612cad565b8281036060840152612dbb8186612cad565b90508281036080840152612dcf8185612ce8565b98975050505050505050565b60006001600160a01b03808816835280871660208401525084604083015283606083015260a0608083015261273460a0830184612ce8565b6020815260006118b86020830184612cad565b604081526000612e396040830185612cad565b8281036020840152612e4b8185612cad565b95945050505050565b6020815260006118b86020830184612ce8565b600067ffffffffffffffff821115612e8157612e816130b4565b5060051b60200190565b60008219821115612e9e57612e9e613027565b500190565b600082612eb257612eb2613056565b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615612eef57612eef613027565b500290565b600082821015612f0657612f06613027565b500390565b60005b83811015612f26578181015183820152602001612f0e565b83811115612f35576000848401525b50505050565b600181811c90821680612f4f57607f821691505b60208210811415612f89577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116810181811067ffffffffffffffff82111715612fd357612fd36130b4565b6040525050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561300c5761300c613027565b5060010190565b60008261302257613022613056565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060033d11156130fc5760046000803e5060005160e01c5b90565b600060443d101561310d5790565b6040517ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc803d016004833e81513d67ffffffffffffffff816024840111818411171561315b57505050505090565b82850191508151818111156131735750505050505090565b843d870101602082850101111561318d5750505050505090565b61319c60208286010187612f8f565b509095945050505050565b6001600160a01b0381168114610fe657600080fd5b8015158114610fe657600080fd5b7fffffffff0000000000000000000000000000000000000000000000000000000081168114610fe657600080fdfea2646970667358221220c90f943f5dfc7cf70e16e0753bea2aa7d7ffeb5271d0c87e91fc871aabd108ce64736f6c63430008070033

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

000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000036697066733a2f2f516d626d34343632614579444e4e736365784764646a384d326d773450747a714238374644704a726263713373442f0000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000000000000000000006b99d2b10f3cc0ce6b871a9f5f94e1ecd6222f470000000000000000000000001e4767178a080adad8731a2f6ec717dbc749b70b000000000000000000000000520796a72f9dff8946b37df55f6652e196360a09000000000000000000000000021a32988aa016abc2f2a90c4be2b8e9415398410000000000000000000000006e628cbfca3aeaffe64ca9361316c914dd911ecb00000000000000000000000084645b7e66c4a51c7f163d8c295ae45a3b47e7b600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000a

-----Decoded View---------------
Arg [0] : _uri (string): ipfs://Qmbm4462aEyDNNscexGddj8M2mw4PtzqB87FDpJrbcq3sD/
Arg [1] : shareholders (address[]): 0x6B99D2B10f3Cc0CE6b871A9F5f94e1ECD6222f47,0x1e4767178A080ADad8731A2f6Ec717Dbc749b70B,0x520796A72F9DFf8946B37dF55f6652e196360a09,0x021A32988Aa016Abc2f2a90c4BE2B8e941539841,0x6E628cBFCA3AEaFfe64cA9361316c914dD911ecb,0x84645b7e66c4a51c7f163d8c295aE45a3B47e7b6
Arg [2] : shares (uint256[]): 20,10,20,20,20,10

-----Encoded View---------------
20 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000c0
Arg [2] : 00000000000000000000000000000000000000000000000000000000000001a0
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000036
Arg [4] : 697066733a2f2f516d626d34343632614579444e4e736365784764646a384d32
Arg [5] : 6d773450747a714238374644704a726263713373442f00000000000000000000
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [7] : 0000000000000000000000006b99d2b10f3cc0ce6b871a9f5f94e1ecd6222f47
Arg [8] : 0000000000000000000000001e4767178a080adad8731a2f6ec717dbc749b70b
Arg [9] : 000000000000000000000000520796a72f9dff8946b37df55f6652e196360a09
Arg [10] : 000000000000000000000000021a32988aa016abc2f2a90c4be2b8e941539841
Arg [11] : 0000000000000000000000006e628cbfca3aeaffe64ca9361316c914dd911ecb
Arg [12] : 00000000000000000000000084645b7e66c4a51c7f163d8c295ae45a3b47e7b6
Arg [13] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [15] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [16] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [17] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [18] : 0000000000000000000000000000000000000000000000000000000000000014
Arg [19] : 000000000000000000000000000000000000000000000000000000000000000a


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]
[ 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.