ERC-20
Overview
Max Total Supply
3,500,000 RLB
Holders
222
Market
Price
$0.00 @ 0.000000 MATIC
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract (WITH 18 Decimals)
Balance
4,400.670674346 RLBValue
$0.00Loading...
Loading
Loading...
Loading
Loading...
Loading
Contract Name:
Rollbit_Coin
Compiler Version
v0.8.18+commit.87f61d96
Contract Source Code (Solidity)
/** *Submitted for verification at polygonscan.com on 2023-02-18 */ // SPDX-License-Identifier: MIT // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/math/SafeCast.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/math/SafeCast.sol) // This file was procedurally generated from scripts/generate/templates/SafeCast.js. pragma solidity ^0.8.0; /** * @dev Wrappers over Solidity's uintXX/intXX casting operators with added overflow * checks. * * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can * easily result in undesired exploitation or bugs, since developers usually * assume that overflows raise errors. `SafeCast` restores this intuition by * reverting the transaction when such an operation overflows. * * Using this library instead of the unchecked operations eliminates an entire * class of bugs, so it's recommended to use it always. * * Can be combined with {SafeMath} and {SignedSafeMath} to extend it to smaller types, by performing * all math on `uint256` and `int256` and then downcasting. */ library SafeCast { /** * @dev Returns the downcasted uint248 from uint256, reverting on * overflow (when the input is greater than largest uint248). * * Counterpart to Solidity's `uint248` operator. * * Requirements: * * - input must fit into 248 bits * * _Available since v4.7._ */ function toUint248(uint256 value) internal pure returns (uint248) { require(value <= type(uint248).max, "SafeCast: value doesn't fit in 248 bits"); return uint248(value); } /** * @dev Returns the downcasted uint240 from uint256, reverting on * overflow (when the input is greater than largest uint240). * * Counterpart to Solidity's `uint240` operator. * * Requirements: * * - input must fit into 240 bits * * _Available since v4.7._ */ function toUint240(uint256 value) internal pure returns (uint240) { require(value <= type(uint240).max, "SafeCast: value doesn't fit in 240 bits"); return uint240(value); } /** * @dev Returns the downcasted uint232 from uint256, reverting on * overflow (when the input is greater than largest uint232). * * Counterpart to Solidity's `uint232` operator. * * Requirements: * * - input must fit into 232 bits * * _Available since v4.7._ */ function toUint232(uint256 value) internal pure returns (uint232) { require(value <= type(uint232).max, "SafeCast: value doesn't fit in 232 bits"); return uint232(value); } /** * @dev Returns the downcasted uint224 from uint256, reverting on * overflow (when the input is greater than largest uint224). * * Counterpart to Solidity's `uint224` operator. * * Requirements: * * - input must fit into 224 bits * * _Available since v4.2._ */ function toUint224(uint256 value) internal pure returns (uint224) { require(value <= type(uint224).max, "SafeCast: value doesn't fit in 224 bits"); return uint224(value); } /** * @dev Returns the downcasted uint216 from uint256, reverting on * overflow (when the input is greater than largest uint216). * * Counterpart to Solidity's `uint216` operator. * * Requirements: * * - input must fit into 216 bits * * _Available since v4.7._ */ function toUint216(uint256 value) internal pure returns (uint216) { require(value <= type(uint216).max, "SafeCast: value doesn't fit in 216 bits"); return uint216(value); } /** * @dev Returns the downcasted uint208 from uint256, reverting on * overflow (when the input is greater than largest uint208). * * Counterpart to Solidity's `uint208` operator. * * Requirements: * * - input must fit into 208 bits * * _Available since v4.7._ */ function toUint208(uint256 value) internal pure returns (uint208) { require(value <= type(uint208).max, "SafeCast: value doesn't fit in 208 bits"); return uint208(value); } /** * @dev Returns the downcasted uint200 from uint256, reverting on * overflow (when the input is greater than largest uint200). * * Counterpart to Solidity's `uint200` operator. * * Requirements: * * - input must fit into 200 bits * * _Available since v4.7._ */ function toUint200(uint256 value) internal pure returns (uint200) { require(value <= type(uint200).max, "SafeCast: value doesn't fit in 200 bits"); return uint200(value); } /** * @dev Returns the downcasted uint192 from uint256, reverting on * overflow (when the input is greater than largest uint192). * * Counterpart to Solidity's `uint192` operator. * * Requirements: * * - input must fit into 192 bits * * _Available since v4.7._ */ function toUint192(uint256 value) internal pure returns (uint192) { require(value <= type(uint192).max, "SafeCast: value doesn't fit in 192 bits"); return uint192(value); } /** * @dev Returns the downcasted uint184 from uint256, reverting on * overflow (when the input is greater than largest uint184). * * Counterpart to Solidity's `uint184` operator. * * Requirements: * * - input must fit into 184 bits * * _Available since v4.7._ */ function toUint184(uint256 value) internal pure returns (uint184) { require(value <= type(uint184).max, "SafeCast: value doesn't fit in 184 bits"); return uint184(value); } /** * @dev Returns the downcasted uint176 from uint256, reverting on * overflow (when the input is greater than largest uint176). * * Counterpart to Solidity's `uint176` operator. * * Requirements: * * - input must fit into 176 bits * * _Available since v4.7._ */ function toUint176(uint256 value) internal pure returns (uint176) { require(value <= type(uint176).max, "SafeCast: value doesn't fit in 176 bits"); return uint176(value); } /** * @dev Returns the downcasted uint168 from uint256, reverting on * overflow (when the input is greater than largest uint168). * * Counterpart to Solidity's `uint168` operator. * * Requirements: * * - input must fit into 168 bits * * _Available since v4.7._ */ function toUint168(uint256 value) internal pure returns (uint168) { require(value <= type(uint168).max, "SafeCast: value doesn't fit in 168 bits"); return uint168(value); } /** * @dev Returns the downcasted uint160 from uint256, reverting on * overflow (when the input is greater than largest uint160). * * Counterpart to Solidity's `uint160` operator. * * Requirements: * * - input must fit into 160 bits * * _Available since v4.7._ */ function toUint160(uint256 value) internal pure returns (uint160) { require(value <= type(uint160).max, "SafeCast: value doesn't fit in 160 bits"); return uint160(value); } /** * @dev Returns the downcasted uint152 from uint256, reverting on * overflow (when the input is greater than largest uint152). * * Counterpart to Solidity's `uint152` operator. * * Requirements: * * - input must fit into 152 bits * * _Available since v4.7._ */ function toUint152(uint256 value) internal pure returns (uint152) { require(value <= type(uint152).max, "SafeCast: value doesn't fit in 152 bits"); return uint152(value); } /** * @dev Returns the downcasted uint144 from uint256, reverting on * overflow (when the input is greater than largest uint144). * * Counterpart to Solidity's `uint144` operator. * * Requirements: * * - input must fit into 144 bits * * _Available since v4.7._ */ function toUint144(uint256 value) internal pure returns (uint144) { require(value <= type(uint144).max, "SafeCast: value doesn't fit in 144 bits"); return uint144(value); } /** * @dev Returns the downcasted uint136 from uint256, reverting on * overflow (when the input is greater than largest uint136). * * Counterpart to Solidity's `uint136` operator. * * Requirements: * * - input must fit into 136 bits * * _Available since v4.7._ */ function toUint136(uint256 value) internal pure returns (uint136) { require(value <= type(uint136).max, "SafeCast: value doesn't fit in 136 bits"); return uint136(value); } /** * @dev Returns the downcasted uint128 from uint256, reverting on * overflow (when the input is greater than largest uint128). * * Counterpart to Solidity's `uint128` operator. * * Requirements: * * - input must fit into 128 bits * * _Available since v2.5._ */ function toUint128(uint256 value) internal pure returns (uint128) { require(value <= type(uint128).max, "SafeCast: value doesn't fit in 128 bits"); return uint128(value); } /** * @dev Returns the downcasted uint120 from uint256, reverting on * overflow (when the input is greater than largest uint120). * * Counterpart to Solidity's `uint120` operator. * * Requirements: * * - input must fit into 120 bits * * _Available since v4.7._ */ function toUint120(uint256 value) internal pure returns (uint120) { require(value <= type(uint120).max, "SafeCast: value doesn't fit in 120 bits"); return uint120(value); } /** * @dev Returns the downcasted uint112 from uint256, reverting on * overflow (when the input is greater than largest uint112). * * Counterpart to Solidity's `uint112` operator. * * Requirements: * * - input must fit into 112 bits * * _Available since v4.7._ */ function toUint112(uint256 value) internal pure returns (uint112) { require(value <= type(uint112).max, "SafeCast: value doesn't fit in 112 bits"); return uint112(value); } /** * @dev Returns the downcasted uint104 from uint256, reverting on * overflow (when the input is greater than largest uint104). * * Counterpart to Solidity's `uint104` operator. * * Requirements: * * - input must fit into 104 bits * * _Available since v4.7._ */ function toUint104(uint256 value) internal pure returns (uint104) { require(value <= type(uint104).max, "SafeCast: value doesn't fit in 104 bits"); return uint104(value); } /** * @dev Returns the downcasted uint96 from uint256, reverting on * overflow (when the input is greater than largest uint96). * * Counterpart to Solidity's `uint96` operator. * * Requirements: * * - input must fit into 96 bits * * _Available since v4.2._ */ function toUint96(uint256 value) internal pure returns (uint96) { require(value <= type(uint96).max, "SafeCast: value doesn't fit in 96 bits"); return uint96(value); } /** * @dev Returns the downcasted uint88 from uint256, reverting on * overflow (when the input is greater than largest uint88). * * Counterpart to Solidity's `uint88` operator. * * Requirements: * * - input must fit into 88 bits * * _Available since v4.7._ */ function toUint88(uint256 value) internal pure returns (uint88) { require(value <= type(uint88).max, "SafeCast: value doesn't fit in 88 bits"); return uint88(value); } /** * @dev Returns the downcasted uint80 from uint256, reverting on * overflow (when the input is greater than largest uint80). * * Counterpart to Solidity's `uint80` operator. * * Requirements: * * - input must fit into 80 bits * * _Available since v4.7._ */ function toUint80(uint256 value) internal pure returns (uint80) { require(value <= type(uint80).max, "SafeCast: value doesn't fit in 80 bits"); return uint80(value); } /** * @dev Returns the downcasted uint72 from uint256, reverting on * overflow (when the input is greater than largest uint72). * * Counterpart to Solidity's `uint72` operator. * * Requirements: * * - input must fit into 72 bits * * _Available since v4.7._ */ function toUint72(uint256 value) internal pure returns (uint72) { require(value <= type(uint72).max, "SafeCast: value doesn't fit in 72 bits"); return uint72(value); } /** * @dev Returns the downcasted uint64 from uint256, reverting on * overflow (when the input is greater than largest uint64). * * Counterpart to Solidity's `uint64` operator. * * Requirements: * * - input must fit into 64 bits * * _Available since v2.5._ */ function toUint64(uint256 value) internal pure returns (uint64) { require(value <= type(uint64).max, "SafeCast: value doesn't fit in 64 bits"); return uint64(value); } /** * @dev Returns the downcasted uint56 from uint256, reverting on * overflow (when the input is greater than largest uint56). * * Counterpart to Solidity's `uint56` operator. * * Requirements: * * - input must fit into 56 bits * * _Available since v4.7._ */ function toUint56(uint256 value) internal pure returns (uint56) { require(value <= type(uint56).max, "SafeCast: value doesn't fit in 56 bits"); return uint56(value); } /** * @dev Returns the downcasted uint48 from uint256, reverting on * overflow (when the input is greater than largest uint48). * * Counterpart to Solidity's `uint48` operator. * * Requirements: * * - input must fit into 48 bits * * _Available since v4.7._ */ function toUint48(uint256 value) internal pure returns (uint48) { require(value <= type(uint48).max, "SafeCast: value doesn't fit in 48 bits"); return uint48(value); } /** * @dev Returns the downcasted uint40 from uint256, reverting on * overflow (when the input is greater than largest uint40). * * Counterpart to Solidity's `uint40` operator. * * Requirements: * * - input must fit into 40 bits * * _Available since v4.7._ */ function toUint40(uint256 value) internal pure returns (uint40) { require(value <= type(uint40).max, "SafeCast: value doesn't fit in 40 bits"); return uint40(value); } /** * @dev Returns the downcasted uint32 from uint256, reverting on * overflow (when the input is greater than largest uint32). * * Counterpart to Solidity's `uint32` operator. * * Requirements: * * - input must fit into 32 bits * * _Available since v2.5._ */ function toUint32(uint256 value) internal pure returns (uint32) { require(value <= type(uint32).max, "SafeCast: value doesn't fit in 32 bits"); return uint32(value); } /** * @dev Returns the downcasted uint24 from uint256, reverting on * overflow (when the input is greater than largest uint24). * * Counterpart to Solidity's `uint24` operator. * * Requirements: * * - input must fit into 24 bits * * _Available since v4.7._ */ function toUint24(uint256 value) internal pure returns (uint24) { require(value <= type(uint24).max, "SafeCast: value doesn't fit in 24 bits"); return uint24(value); } /** * @dev Returns the downcasted uint16 from uint256, reverting on * overflow (when the input is greater than largest uint16). * * Counterpart to Solidity's `uint16` operator. * * Requirements: * * - input must fit into 16 bits * * _Available since v2.5._ */ function toUint16(uint256 value) internal pure returns (uint16) { require(value <= type(uint16).max, "SafeCast: value doesn't fit in 16 bits"); return uint16(value); } /** * @dev Returns the downcasted uint8 from uint256, reverting on * overflow (when the input is greater than largest uint8). * * Counterpart to Solidity's `uint8` operator. * * Requirements: * * - input must fit into 8 bits * * _Available since v2.5._ */ function toUint8(uint256 value) internal pure returns (uint8) { require(value <= type(uint8).max, "SafeCast: value doesn't fit in 8 bits"); return uint8(value); } /** * @dev Converts a signed int256 into an unsigned uint256. * * Requirements: * * - input must be greater than or equal to 0. * * _Available since v3.0._ */ function toUint256(int256 value) internal pure returns (uint256) { require(value >= 0, "SafeCast: value must be positive"); return uint256(value); } /** * @dev Returns the downcasted int248 from int256, reverting on * overflow (when the input is less than smallest int248 or * greater than largest int248). * * Counterpart to Solidity's `int248` operator. * * Requirements: * * - input must fit into 248 bits * * _Available since v4.7._ */ function toInt248(int256 value) internal pure returns (int248 downcasted) { downcasted = int248(value); require(downcasted == value, "SafeCast: value doesn't fit in 248 bits"); } /** * @dev Returns the downcasted int240 from int256, reverting on * overflow (when the input is less than smallest int240 or * greater than largest int240). * * Counterpart to Solidity's `int240` operator. * * Requirements: * * - input must fit into 240 bits * * _Available since v4.7._ */ function toInt240(int256 value) internal pure returns (int240 downcasted) { downcasted = int240(value); require(downcasted == value, "SafeCast: value doesn't fit in 240 bits"); } /** * @dev Returns the downcasted int232 from int256, reverting on * overflow (when the input is less than smallest int232 or * greater than largest int232). * * Counterpart to Solidity's `int232` operator. * * Requirements: * * - input must fit into 232 bits * * _Available since v4.7._ */ function toInt232(int256 value) internal pure returns (int232 downcasted) { downcasted = int232(value); require(downcasted == value, "SafeCast: value doesn't fit in 232 bits"); } /** * @dev Returns the downcasted int224 from int256, reverting on * overflow (when the input is less than smallest int224 or * greater than largest int224). * * Counterpart to Solidity's `int224` operator. * * Requirements: * * - input must fit into 224 bits * * _Available since v4.7._ */ function toInt224(int256 value) internal pure returns (int224 downcasted) { downcasted = int224(value); require(downcasted == value, "SafeCast: value doesn't fit in 224 bits"); } /** * @dev Returns the downcasted int216 from int256, reverting on * overflow (when the input is less than smallest int216 or * greater than largest int216). * * Counterpart to Solidity's `int216` operator. * * Requirements: * * - input must fit into 216 bits * * _Available since v4.7._ */ function toInt216(int256 value) internal pure returns (int216 downcasted) { downcasted = int216(value); require(downcasted == value, "SafeCast: value doesn't fit in 216 bits"); } /** * @dev Returns the downcasted int208 from int256, reverting on * overflow (when the input is less than smallest int208 or * greater than largest int208). * * Counterpart to Solidity's `int208` operator. * * Requirements: * * - input must fit into 208 bits * * _Available since v4.7._ */ function toInt208(int256 value) internal pure returns (int208 downcasted) { downcasted = int208(value); require(downcasted == value, "SafeCast: value doesn't fit in 208 bits"); } /** * @dev Returns the downcasted int200 from int256, reverting on * overflow (when the input is less than smallest int200 or * greater than largest int200). * * Counterpart to Solidity's `int200` operator. * * Requirements: * * - input must fit into 200 bits * * _Available since v4.7._ */ function toInt200(int256 value) internal pure returns (int200 downcasted) { downcasted = int200(value); require(downcasted == value, "SafeCast: value doesn't fit in 200 bits"); } /** * @dev Returns the downcasted int192 from int256, reverting on * overflow (when the input is less than smallest int192 or * greater than largest int192). * * Counterpart to Solidity's `int192` operator. * * Requirements: * * - input must fit into 192 bits * * _Available since v4.7._ */ function toInt192(int256 value) internal pure returns (int192 downcasted) { downcasted = int192(value); require(downcasted == value, "SafeCast: value doesn't fit in 192 bits"); } /** * @dev Returns the downcasted int184 from int256, reverting on * overflow (when the input is less than smallest int184 or * greater than largest int184). * * Counterpart to Solidity's `int184` operator. * * Requirements: * * - input must fit into 184 bits * * _Available since v4.7._ */ function toInt184(int256 value) internal pure returns (int184 downcasted) { downcasted = int184(value); require(downcasted == value, "SafeCast: value doesn't fit in 184 bits"); } /** * @dev Returns the downcasted int176 from int256, reverting on * overflow (when the input is less than smallest int176 or * greater than largest int176). * * Counterpart to Solidity's `int176` operator. * * Requirements: * * - input must fit into 176 bits * * _Available since v4.7._ */ function toInt176(int256 value) internal pure returns (int176 downcasted) { downcasted = int176(value); require(downcasted == value, "SafeCast: value doesn't fit in 176 bits"); } /** * @dev Returns the downcasted int168 from int256, reverting on * overflow (when the input is less than smallest int168 or * greater than largest int168). * * Counterpart to Solidity's `int168` operator. * * Requirements: * * - input must fit into 168 bits * * _Available since v4.7._ */ function toInt168(int256 value) internal pure returns (int168 downcasted) { downcasted = int168(value); require(downcasted == value, "SafeCast: value doesn't fit in 168 bits"); } /** * @dev Returns the downcasted int160 from int256, reverting on * overflow (when the input is less than smallest int160 or * greater than largest int160). * * Counterpart to Solidity's `int160` operator. * * Requirements: * * - input must fit into 160 bits * * _Available since v4.7._ */ function toInt160(int256 value) internal pure returns (int160 downcasted) { downcasted = int160(value); require(downcasted == value, "SafeCast: value doesn't fit in 160 bits"); } /** * @dev Returns the downcasted int152 from int256, reverting on * overflow (when the input is less than smallest int152 or * greater than largest int152). * * Counterpart to Solidity's `int152` operator. * * Requirements: * * - input must fit into 152 bits * * _Available since v4.7._ */ function toInt152(int256 value) internal pure returns (int152 downcasted) { downcasted = int152(value); require(downcasted == value, "SafeCast: value doesn't fit in 152 bits"); } /** * @dev Returns the downcasted int144 from int256, reverting on * overflow (when the input is less than smallest int144 or * greater than largest int144). * * Counterpart to Solidity's `int144` operator. * * Requirements: * * - input must fit into 144 bits * * _Available since v4.7._ */ function toInt144(int256 value) internal pure returns (int144 downcasted) { downcasted = int144(value); require(downcasted == value, "SafeCast: value doesn't fit in 144 bits"); } /** * @dev Returns the downcasted int136 from int256, reverting on * overflow (when the input is less than smallest int136 or * greater than largest int136). * * Counterpart to Solidity's `int136` operator. * * Requirements: * * - input must fit into 136 bits * * _Available since v4.7._ */ function toInt136(int256 value) internal pure returns (int136 downcasted) { downcasted = int136(value); require(downcasted == value, "SafeCast: value doesn't fit in 136 bits"); } /** * @dev Returns the downcasted int128 from int256, reverting on * overflow (when the input is less than smallest int128 or * greater than largest int128). * * Counterpart to Solidity's `int128` operator. * * Requirements: * * - input must fit into 128 bits * * _Available since v3.1._ */ function toInt128(int256 value) internal pure returns (int128 downcasted) { downcasted = int128(value); require(downcasted == value, "SafeCast: value doesn't fit in 128 bits"); } /** * @dev Returns the downcasted int120 from int256, reverting on * overflow (when the input is less than smallest int120 or * greater than largest int120). * * Counterpart to Solidity's `int120` operator. * * Requirements: * * - input must fit into 120 bits * * _Available since v4.7._ */ function toInt120(int256 value) internal pure returns (int120 downcasted) { downcasted = int120(value); require(downcasted == value, "SafeCast: value doesn't fit in 120 bits"); } /** * @dev Returns the downcasted int112 from int256, reverting on * overflow (when the input is less than smallest int112 or * greater than largest int112). * * Counterpart to Solidity's `int112` operator. * * Requirements: * * - input must fit into 112 bits * * _Available since v4.7._ */ function toInt112(int256 value) internal pure returns (int112 downcasted) { downcasted = int112(value); require(downcasted == value, "SafeCast: value doesn't fit in 112 bits"); } /** * @dev Returns the downcasted int104 from int256, reverting on * overflow (when the input is less than smallest int104 or * greater than largest int104). * * Counterpart to Solidity's `int104` operator. * * Requirements: * * - input must fit into 104 bits * * _Available since v4.7._ */ function toInt104(int256 value) internal pure returns (int104 downcasted) { downcasted = int104(value); require(downcasted == value, "SafeCast: value doesn't fit in 104 bits"); } /** * @dev Returns the downcasted int96 from int256, reverting on * overflow (when the input is less than smallest int96 or * greater than largest int96). * * Counterpart to Solidity's `int96` operator. * * Requirements: * * - input must fit into 96 bits * * _Available since v4.7._ */ function toInt96(int256 value) internal pure returns (int96 downcasted) { downcasted = int96(value); require(downcasted == value, "SafeCast: value doesn't fit in 96 bits"); } /** * @dev Returns the downcasted int88 from int256, reverting on * overflow (when the input is less than smallest int88 or * greater than largest int88). * * Counterpart to Solidity's `int88` operator. * * Requirements: * * - input must fit into 88 bits * * _Available since v4.7._ */ function toInt88(int256 value) internal pure returns (int88 downcasted) { downcasted = int88(value); require(downcasted == value, "SafeCast: value doesn't fit in 88 bits"); } /** * @dev Returns the downcasted int80 from int256, reverting on * overflow (when the input is less than smallest int80 or * greater than largest int80). * * Counterpart to Solidity's `int80` operator. * * Requirements: * * - input must fit into 80 bits * * _Available since v4.7._ */ function toInt80(int256 value) internal pure returns (int80 downcasted) { downcasted = int80(value); require(downcasted == value, "SafeCast: value doesn't fit in 80 bits"); } /** * @dev Returns the downcasted int72 from int256, reverting on * overflow (when the input is less than smallest int72 or * greater than largest int72). * * Counterpart to Solidity's `int72` operator. * * Requirements: * * - input must fit into 72 bits * * _Available since v4.7._ */ function toInt72(int256 value) internal pure returns (int72 downcasted) { downcasted = int72(value); require(downcasted == value, "SafeCast: value doesn't fit in 72 bits"); } /** * @dev Returns the downcasted int64 from int256, reverting on * overflow (when the input is less than smallest int64 or * greater than largest int64). * * Counterpart to Solidity's `int64` operator. * * Requirements: * * - input must fit into 64 bits * * _Available since v3.1._ */ function toInt64(int256 value) internal pure returns (int64 downcasted) { downcasted = int64(value); require(downcasted == value, "SafeCast: value doesn't fit in 64 bits"); } /** * @dev Returns the downcasted int56 from int256, reverting on * overflow (when the input is less than smallest int56 or * greater than largest int56). * * Counterpart to Solidity's `int56` operator. * * Requirements: * * - input must fit into 56 bits * * _Available since v4.7._ */ function toInt56(int256 value) internal pure returns (int56 downcasted) { downcasted = int56(value); require(downcasted == value, "SafeCast: value doesn't fit in 56 bits"); } /** * @dev Returns the downcasted int48 from int256, reverting on * overflow (when the input is less than smallest int48 or * greater than largest int48). * * Counterpart to Solidity's `int48` operator. * * Requirements: * * - input must fit into 48 bits * * _Available since v4.7._ */ function toInt48(int256 value) internal pure returns (int48 downcasted) { downcasted = int48(value); require(downcasted == value, "SafeCast: value doesn't fit in 48 bits"); } /** * @dev Returns the downcasted int40 from int256, reverting on * overflow (when the input is less than smallest int40 or * greater than largest int40). * * Counterpart to Solidity's `int40` operator. * * Requirements: * * - input must fit into 40 bits * * _Available since v4.7._ */ function toInt40(int256 value) internal pure returns (int40 downcasted) { downcasted = int40(value); require(downcasted == value, "SafeCast: value doesn't fit in 40 bits"); } /** * @dev Returns the downcasted int32 from int256, reverting on * overflow (when the input is less than smallest int32 or * greater than largest int32). * * Counterpart to Solidity's `int32` operator. * * Requirements: * * - input must fit into 32 bits * * _Available since v3.1._ */ function toInt32(int256 value) internal pure returns (int32 downcasted) { downcasted = int32(value); require(downcasted == value, "SafeCast: value doesn't fit in 32 bits"); } /** * @dev Returns the downcasted int24 from int256, reverting on * overflow (when the input is less than smallest int24 or * greater than largest int24). * * Counterpart to Solidity's `int24` operator. * * Requirements: * * - input must fit into 24 bits * * _Available since v4.7._ */ function toInt24(int256 value) internal pure returns (int24 downcasted) { downcasted = int24(value); require(downcasted == value, "SafeCast: value doesn't fit in 24 bits"); } /** * @dev Returns the downcasted int16 from int256, reverting on * overflow (when the input is less than smallest int16 or * greater than largest int16). * * Counterpart to Solidity's `int16` operator. * * Requirements: * * - input must fit into 16 bits * * _Available since v3.1._ */ function toInt16(int256 value) internal pure returns (int16 downcasted) { downcasted = int16(value); require(downcasted == value, "SafeCast: value doesn't fit in 16 bits"); } /** * @dev Returns the downcasted int8 from int256, reverting on * overflow (when the input is less than smallest int8 or * greater than largest int8). * * Counterpart to Solidity's `int8` operator. * * Requirements: * * - input must fit into 8 bits * * _Available since v3.1._ */ function toInt8(int256 value) internal pure returns (int8 downcasted) { downcasted = int8(value); require(downcasted == value, "SafeCast: value doesn't fit in 8 bits"); } /** * @dev Converts an unsigned uint256 into a signed int256. * * Requirements: * * - input must be less than or equal to maxInt256. * * _Available since v3.0._ */ function toInt256(uint256 value) internal pure returns (int256) { // Note: Unsafe cast below is okay because `type(int256).max` is guaranteed to be positive require(value <= uint256(type(int256).max), "SafeCast: value doesn't fit in an int256"); return int256(value); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/governance/utils/IVotes.sol // OpenZeppelin Contracts (last updated v4.5.0) (governance/utils/IVotes.sol) pragma solidity ^0.8.0; /** * @dev Common interface for {ERC20Votes}, {ERC721Votes}, and other {Votes}-enabled contracts. * * _Available since v4.5._ */ interface IVotes { /** * @dev Emitted when an account changes their delegate. */ event DelegateChanged(address indexed delegator, address indexed fromDelegate, address indexed toDelegate); /** * @dev Emitted when a token transfer or delegate change results in changes to a delegate's number of votes. */ event DelegateVotesChanged(address indexed delegate, uint256 previousBalance, uint256 newBalance); /** * @dev Returns the current amount of votes that `account` has. */ function getVotes(address account) external view returns (uint256); /** * @dev Returns the amount of votes that `account` had at the end of a past block (`blockNumber`). */ function getPastVotes(address account, uint256 blockNumber) external view returns (uint256); /** * @dev Returns the total supply of votes available at the end of a past block (`blockNumber`). * * NOTE: This value is the sum of all available votes, which is not necessarily the sum of all delegated votes. * Votes that have not been delegated are still part of total supply, even though they would not participate in a * vote. */ function getPastTotalSupply(uint256 blockNumber) external view returns (uint256); /** * @dev Returns the delegate that `account` has chosen. */ function delegates(address account) external view returns (address); /** * @dev Delegates votes from the sender to `delegatee`. */ function delegate(address delegatee) external; /** * @dev Delegates votes from signer to `delegatee`. */ function delegateBySig( address delegatee, uint256 nonce, uint256 expiry, uint8 v, bytes32 r, bytes32 s ) external; } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/draft-IERC20Permit.sol // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. */ interface IERC20Permit { /** * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, * given ``owner``'s signed approval. * * IMPORTANT: The same issues {IERC20-approve} has related to transaction * ordering also apply here. * * Emits an {Approval} event. * * Requirements: * * - `spender` cannot be the zero address. * - `deadline` must be a timestamp in the future. * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` * over the EIP712-formatted function arguments. * - the signature must use ``owner``'s current nonce (see {nonces}). * * For more information on the signature format, see the * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP * section]. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) external; /** * @dev Returns the current nonce for `owner`. This value must be * included whenever a signature is generated for {permit}. * * Every successful call to {permit} increases ``owner``'s nonce by one. This * prevents a signature from being used multiple times. */ function nonces(address owner) external view returns (uint256); /** * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view returns (bytes32); } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/Counters.sol // 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: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/math/Math.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol) pragma solidity ^0.8.0; /** * @dev Standard math utilities missing in the Solidity language. */ library Math { enum Rounding { Down, // Toward negative infinity Up, // Toward infinity Zero // Toward zero } /** * @dev Returns the largest of two numbers. */ function max(uint256 a, uint256 b) internal pure returns (uint256) { return a > b ? a : b; } /** * @dev Returns the smallest of two numbers. */ function min(uint256 a, uint256 b) internal pure returns (uint256) { return a < b ? a : b; } /** * @dev Returns the average of two numbers. The result is rounded towards * zero. */ function average(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b) / 2 can overflow. return (a & b) + (a ^ b) / 2; } /** * @dev Returns the ceiling of the division of two numbers. * * This differs from standard division with `/` in that it rounds up instead * of rounding down. */ function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { // (a + b - 1) / b can overflow on addition, so we distribute. return a == 0 ? 0 : (a - 1) / b + 1; } /** * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0 * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) * with further edits by Uniswap Labs also under MIT license. */ function mulDiv( uint256 x, uint256 y, uint256 denominator ) internal pure returns (uint256 result) { unchecked { // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256 // variables such that product = prod1 * 2^256 + prod0. uint256 prod0; // Least significant 256 bits of the product uint256 prod1; // Most significant 256 bits of the product assembly { let mm := mulmod(x, y, not(0)) prod0 := mul(x, y) prod1 := sub(sub(mm, prod0), lt(mm, prod0)) } // Handle non-overflow cases, 256 by 256 division. if (prod1 == 0) { return prod0 / denominator; } // Make sure the result is less than 2^256. Also prevents denominator == 0. require(denominator > prod1); /////////////////////////////////////////////// // 512 by 256 division. /////////////////////////////////////////////// // Make division exact by subtracting the remainder from [prod1 prod0]. uint256 remainder; assembly { // Compute remainder using mulmod. remainder := mulmod(x, y, denominator) // Subtract 256 bit number from 512 bit number. prod1 := sub(prod1, gt(remainder, prod0)) prod0 := sub(prod0, remainder) } // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1. // See https://cs.stackexchange.com/q/138556/92363. // Does not overflow because the denominator cannot be zero at this stage in the function. uint256 twos = denominator & (~denominator + 1); assembly { // Divide denominator by twos. denominator := div(denominator, twos) // Divide [prod1 prod0] by twos. prod0 := div(prod0, twos) // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one. twos := add(div(sub(0, twos), twos), 1) } // Shift in bits from prod1 into prod0. prod0 |= prod1 * twos; // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for // four bits. That is, denominator * inv = 1 mod 2^4. uint256 inverse = (3 * denominator) ^ 2; // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works // in modular arithmetic, doubling the correct bits in each step. inverse *= 2 - denominator * inverse; // inverse mod 2^8 inverse *= 2 - denominator * inverse; // inverse mod 2^16 inverse *= 2 - denominator * inverse; // inverse mod 2^32 inverse *= 2 - denominator * inverse; // inverse mod 2^64 inverse *= 2 - denominator * inverse; // inverse mod 2^128 inverse *= 2 - denominator * inverse; // inverse mod 2^256 // Because the division is now exact we can divide by multiplying with the modular inverse of denominator. // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1 // is no longer required. result = prod0 * inverse; return result; } } /** * @notice Calculates x * y / denominator with full precision, following the selected rounding direction. */ function mulDiv( uint256 x, uint256 y, uint256 denominator, Rounding rounding ) internal pure returns (uint256) { uint256 result = mulDiv(x, y, denominator); if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) { result += 1; } return result; } /** * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down. * * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11). */ function sqrt(uint256 a) internal pure returns (uint256) { if (a == 0) { return 0; } // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target. // // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`. // // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)` // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))` // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)` // // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit. uint256 result = 1 << (log2(a) >> 1); // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128, // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision // into the expected uint128 result. unchecked { result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; result = (result + a / result) >> 1; return min(result, a / result); } } /** * @notice Calculates sqrt(a), following the selected rounding direction. */ function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = sqrt(a); return result + (rounding == Rounding.Up && result * result < a ? 1 : 0); } } /** * @dev Return the log in base 2, rounded down, of a positive value. * Returns 0 if given 0. */ function log2(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >> 128 > 0) { value >>= 128; result += 128; } if (value >> 64 > 0) { value >>= 64; result += 64; } if (value >> 32 > 0) { value >>= 32; result += 32; } if (value >> 16 > 0) { value >>= 16; result += 16; } if (value >> 8 > 0) { value >>= 8; result += 8; } if (value >> 4 > 0) { value >>= 4; result += 4; } if (value >> 2 > 0) { value >>= 2; result += 2; } if (value >> 1 > 0) { result += 1; } } return result; } /** * @dev Return the log in base 2, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log2(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log2(value); return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0); } } /** * @dev Return the log in base 10, rounded down, of a positive value. * Returns 0 if given 0. */ function log10(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >= 10**64) { value /= 10**64; result += 64; } if (value >= 10**32) { value /= 10**32; result += 32; } if (value >= 10**16) { value /= 10**16; result += 16; } if (value >= 10**8) { value /= 10**8; result += 8; } if (value >= 10**4) { value /= 10**4; result += 4; } if (value >= 10**2) { value /= 10**2; result += 2; } if (value >= 10**1) { result += 1; } } return result; } /** * @dev Return the log in base 10, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log10(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log10(value); return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0); } } /** * @dev Return the log in base 256, rounded down, of a positive value. * Returns 0 if given 0. * * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string. */ function log256(uint256 value) internal pure returns (uint256) { uint256 result = 0; unchecked { if (value >> 128 > 0) { value >>= 128; result += 16; } if (value >> 64 > 0) { value >>= 64; result += 8; } if (value >> 32 > 0) { value >>= 32; result += 4; } if (value >> 16 > 0) { value >>= 16; result += 2; } if (value >> 8 > 0) { result += 1; } } return result; } /** * @dev Return the log in base 10, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log256(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log256(value); return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0); } } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/Strings.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { unchecked { uint256 length = Math.log10(value) + 1; string memory buffer = new string(length); uint256 ptr; /// @solidity memory-safe-assembly assembly { ptr := add(buffer, add(32, length)) } while (true) { ptr--; /// @solidity memory-safe-assembly assembly { mstore8(ptr, byte(mod(value, 10), _SYMBOLS)) } value /= 10; if (value == 0) break; } return buffer; } } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { unchecked { return toHexString(value, Math.log256(value) + 1); } } /** * @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] = _SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/cryptography/ECDSA.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * * These functions can be used to verify that a message was signed by the holder * of the private keys of a given address. */ library ECDSA { enum RecoverError { NoError, InvalidSignature, InvalidSignatureLength, InvalidSignatureS, InvalidSignatureV // Deprecated in v4.8 } function _throwError(RecoverError error) private pure { if (error == RecoverError.NoError) { return; // no error: do nothing } else if (error == RecoverError.InvalidSignature) { revert("ECDSA: invalid signature"); } else if (error == RecoverError.InvalidSignatureLength) { revert("ECDSA: invalid signature length"); } else if (error == RecoverError.InvalidSignatureS) { revert("ECDSA: invalid signature 's' value"); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] * * _Available since v4.3._ */ function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { if (signature.length == 65) { bytes32 r; bytes32 s; uint8 v; // ecrecover takes the signature parameters, and the only way to get them // currently is to use assembly. /// @solidity memory-safe-assembly assembly { r := mload(add(signature, 0x20)) s := mload(add(signature, 0x40)) v := byte(0, mload(add(signature, 0x60))) } return tryRecover(hash, v, r, s); } else { return (address(0), RecoverError.InvalidSignatureLength); } } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * * IMPORTANT: `hash` _must_ be the result of a hash operation for the * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, signature); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] * * _Available since v4.3._ */ function tryRecover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address, RecoverError) { bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); uint8 v = uint8((uint256(vs) >> 255) + 27); return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. * * _Available since v4.2._ */ function recover( bytes32 hash, bytes32 r, bytes32 vs ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, r, vs); _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. * * _Available since v4.3._ */ function tryRecover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most // signatures from current libraries generate a unique signature with an s-value in the lower half order. // // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { return (address(0), RecoverError.InvalidSignatureS); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { return (address(0), RecoverError.InvalidSignature); } return (signer, RecoverError.NoError); } /** * @dev Overload of {ECDSA-recover} that receives the `v`, * `r` and `s` signature fields separately. */ function recover( bytes32 hash, uint8 v, bytes32 r, bytes32 s ) internal pure returns (address) { (address recovered, RecoverError error) = tryRecover(hash, v, r, s); _throwError(error); return recovered; } /** * @dev Returns an Ethereum Signed Message, created from a `hash`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { // 32 is the length in bytes of hash, // enforced by the type signature above return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); } /** * @dev Returns an Ethereum Signed Message, created from `s`. This * produces hash corresponding to the one signed with the * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] * JSON-RPC method as part of EIP-191. * * See {recover}. */ function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); } /** * @dev Returns an Ethereum Signed Typed Data, created from a * `domainSeparator` and a `structHash`. This produces hash corresponding * to the one signed with the * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] * JSON-RPC method as part of EIP-712. * * See {recover}. */ function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/cryptography/EIP712.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/EIP712.sol) pragma solidity ^0.8.0; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA * ({_hashTypedDataV4}). * * The implementation of the domain separator was designed to be as efficient as possible while still properly updating * the chain id to protect against replay attacks on an eventual fork of the chain. * * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * * _Available since v3.4._ */ abstract contract EIP712 { /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; uint256 private immutable _CACHED_CHAIN_ID; address private immutable _CACHED_THIS; bytes32 private immutable _HASHED_NAME; bytes32 private immutable _HASHED_VERSION; bytes32 private immutable _TYPE_HASH; /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. * * The meaning of `name` and `version` is specified in * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: * * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. * - `version`: the current major version of the signing domain. * * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart * contract upgrade]. */ constructor(string memory name, string memory version) { bytes32 hashedName = keccak256(bytes(name)); bytes32 hashedVersion = keccak256(bytes(version)); bytes32 typeHash = keccak256( "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)" ); _HASHED_NAME = hashedName; _HASHED_VERSION = hashedVersion; _CACHED_CHAIN_ID = block.chainid; _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion); _CACHED_THIS = address(this); _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) { return _CACHED_DOMAIN_SEPARATOR; } else { return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION); } } function _buildDomainSeparator( bytes32 typeHash, bytes32 nameHash, bytes32 versionHash ) private view returns (bytes32) { return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this))); } /** * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this * function returns the hash of the fully encoded EIP712 message for this domain. * * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: * * ```solidity * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( * keccak256("Mail(address to,string contents)"), * mailTo, * keccak256(bytes(mailContents)) * ))); * address signer = ECDSA.recover(digest, signature); * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/StorageSlot.sol // OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol) pragma solidity ^0.8.0; /** * @dev Library for reading and writing primitive types to specific storage slots. * * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. * This library helps with reading and writing to such slots without the need for inline assembly. * * The functions in this library return Slot structs that contain a `value` member that can be used to read or write. * * Example usage to set ERC1967 implementation slot: * ``` * contract ERC1967 { * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; * * function _getImplementation() internal view returns (address) { * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; * } * * function _setImplementation(address newImplementation) internal { * require(Address.isContract(newImplementation), "ERC1967: new implementation is not a contract"); * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; * } * } * ``` * * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._ */ library StorageSlot { struct AddressSlot { address value; } struct BooleanSlot { bool value; } struct Bytes32Slot { bytes32 value; } struct Uint256Slot { uint256 value; } /** * @dev Returns an `AddressSlot` with member `value` located at `slot`. */ function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `BooleanSlot` with member `value` located at `slot`. */ function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `Bytes32Slot` with member `value` located at `slot`. */ function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } /** * @dev Returns an `Uint256Slot` with member `value` located at `slot`. */ function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) { /// @solidity memory-safe-assembly assembly { r.slot := slot } } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/Arrays.sol // OpenZeppelin Contracts (last updated v4.8.0) (utils/Arrays.sol) pragma solidity ^0.8.0; /** * @dev Collection of functions related to array types. */ library Arrays { using StorageSlot for bytes32; /** * @dev Searches a sorted `array` and returns the first index that contains * a value greater or equal to `element`. If no such index exists (i.e. all * values in the array are strictly less than `element`), the array length is * returned. Time complexity O(log n). * * `array` is expected to be sorted in ascending order, and to contain no * repeated elements. */ function findUpperBound(uint256[] storage array, uint256 element) internal view returns (uint256) { if (array.length == 0) { return 0; } uint256 low = 0; uint256 high = array.length; while (low < high) { uint256 mid = Math.average(low, high); // Note that mid will always be strictly less than high (i.e. it will be a valid array index) // because Math.average rounds down (it does integer division with truncation). if (unsafeAccess(array, mid).value > element) { high = mid; } else { low = mid + 1; } } // At this point `low` is the exclusive upper bound. We will return the inclusive upper bound. if (low > 0 && unsafeAccess(array, low - 1).value == element) { return low - 1; } else { return low; } } /** * @dev Access an array in an "unsafe" way. Skips solidity "index-out-of-range" check. * * WARNING: Only use if you are certain `pos` is lower than the array length. */ function unsafeAccess(address[] storage arr, uint256 pos) internal pure returns (StorageSlot.AddressSlot storage) { bytes32 slot; /// @solidity memory-safe-assembly assembly { mstore(0, arr.slot) slot := add(keccak256(0, 0x20), pos) } return slot.getAddressSlot(); } /** * @dev Access an array in an "unsafe" way. Skips solidity "index-out-of-range" check. * * WARNING: Only use if you are certain `pos` is lower than the array length. */ function unsafeAccess(bytes32[] storage arr, uint256 pos) internal pure returns (StorageSlot.Bytes32Slot storage) { bytes32 slot; /// @solidity memory-safe-assembly assembly { mstore(0, arr.slot) slot := add(keccak256(0, 0x20), pos) } return slot.getBytes32Slot(); } /** * @dev Access an array in an "unsafe" way. Skips solidity "index-out-of-range" check. * * WARNING: Only use if you are certain `pos` is lower than the array length. */ function unsafeAccess(uint256[] storage arr, uint256 pos) internal pure returns (StorageSlot.Uint256Slot storage) { bytes32 slot; /// @solidity memory-safe-assembly assembly { mstore(0, arr.slot) slot := add(keccak256(0, 0x20), pos) } return slot.getUint256Slot(); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/utils/Context.sol // 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: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/access/Ownable.sol // OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol) pragma solidity ^0.8.0; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { 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: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/IERC20.sol // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @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); /** * @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); } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity ^0.8.0; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/ERC20.sol // OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol) pragma solidity ^0.8.0; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our guide * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * * We have followed general OpenZeppelin Contracts guidelines: functions revert * instead returning `false` on failure. This behavior is nonetheless * conventional and does not conflict with the expectations of ERC20 * applications. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to reconstruct the allowance for all accounts just * by listening to said events. Other implementations of the EIP may not emit * these events, as it isn't required by the specification. * * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {name} and {symbol}. * * The default value of {decimals} is 18. To select a different value for * {decimals} you should overload it. * * All two of these values are immutable: they can only be set once during * construction. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev Returns the name of the token. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5.05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. This is the value {ERC20} uses, unless this function is * overridden; * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ function decimals() public view virtual override returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; } /** * @dev See {IERC20-transfer}. * * Requirements: * * - `to` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address to, uint256 amount) public virtual override returns (bool) { address owner = _msgSender(); _transfer(owner, to, amount); return true; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on * `transferFrom`. This is semantically equivalent to an infinite approval. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public virtual override returns (bool) { address owner = _msgSender(); _approve(owner, spender, amount); return true; } /** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}. * * NOTE: Does not update the allowance if the current allowance * is the maximum `uint256`. * * Requirements: * * - `from` and `to` cannot be the zero address. * - `from` must have a balance of at least `amount`. * - the caller must have allowance for ``from``'s tokens of at least * `amount`. */ function transferFrom( address from, address to, uint256 amount ) public virtual override returns (bool) { address spender = _msgSender(); _spendAllowance(from, spender, amount); _transfer(from, to, amount); return true; } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. */ function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { address owner = _msgSender(); _approve(owner, spender, allowance(owner, spender) + addedValue); return true; } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least * `subtractedValue`. */ function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { address owner = _msgSender(); uint256 currentAllowance = allowance(owner, spender); require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(owner, spender, currentAllowance - subtractedValue); } return true; } /** * @dev Moves `amount` of tokens from `from` to `to`. * * This internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `from` must have a balance of at least `amount`. */ function _transfer( address from, address to, uint256 amount ) internal virtual { require(from != address(0), "ERC20: transfer from the zero address"); require(to != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(from, to, amount); uint256 fromBalance = _balances[from]; require(fromBalance >= amount, "ERC20: transfer amount exceeds balance"); unchecked { _balances[from] = fromBalance - amount; // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by // decrementing then incrementing. _balances[to] += amount; } emit Transfer(from, to, amount); _afterTokenTransfer(from, to, amount); } /** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. */ function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _beforeTokenTransfer(address(0), account, amount); _totalSupply += amount; unchecked { // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above. _balances[account] += amount; } emit Transfer(address(0), account, amount); _afterTokenTransfer(address(0), account, amount); } /** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */ function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); _beforeTokenTransfer(account, address(0), amount); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); unchecked { _balances[account] = accountBalance - amount; // Overflow not possible: amount <= accountBalance <= totalSupply. _totalSupply -= amount; } emit Transfer(account, address(0), amount); _afterTokenTransfer(account, address(0), amount); } /** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ function _approve( address owner, address spender, uint256 amount ) internal virtual { require(owner != address(0), "ERC20: approve from the zero address"); require(spender != address(0), "ERC20: approve to the zero address"); _allowances[owner][spender] = amount; emit Approval(owner, spender, amount); } /** * @dev Updates `owner` s allowance for `spender` based on spent `amount`. * * Does not update the allowance amount in case of infinite allowance. * Revert if not enough allowance is available. * * Might emit an {Approval} event. */ function _spendAllowance( address owner, address spender, uint256 amount ) internal virtual { uint256 currentAllowance = allowance(owner, spender); if (currentAllowance != type(uint256).max) { require(currentAllowance >= amount, "ERC20: insufficient allowance"); unchecked { _approve(owner, spender, currentAllowance - amount); } } } /** * @dev Hook that is called before any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be transferred to `to`. * - when `from` is zero, `amount` tokens will be minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * has been transferred to `to`. * - when `from` is zero, `amount` tokens have been minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens have been burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual {} } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/draft-ERC20Permit.sol // OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/extensions/draft-ERC20Permit.sol) pragma solidity ^0.8.0; /** * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. * * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. * * _Available since v3.4._ */ abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712 { using Counters for Counters.Counter; mapping(address => Counters.Counter) private _nonces; // solhint-disable-next-line var-name-mixedcase bytes32 private constant _PERMIT_TYPEHASH = keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"); /** * @dev In previous versions `_PERMIT_TYPEHASH` was declared as `immutable`. * However, to ensure consistency with the upgradeable transpiler, we will continue * to reserve a slot. * @custom:oz-renamed-from _PERMIT_TYPEHASH */ // solhint-disable-next-line var-name-mixedcase bytes32 private _PERMIT_TYPEHASH_DEPRECATED_SLOT; /** * @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `"1"`. * * It's a good idea to use the same `name` that is defined as the ERC20 token name. */ constructor(string memory name) EIP712(name, "1") {} /** * @dev See {IERC20Permit-permit}. */ function permit( address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s ) public virtual override { require(block.timestamp <= deadline, "ERC20Permit: expired deadline"); bytes32 structHash = keccak256(abi.encode(_PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline)); bytes32 hash = _hashTypedDataV4(structHash); address signer = ECDSA.recover(hash, v, r, s); require(signer == owner, "ERC20Permit: invalid signature"); _approve(owner, spender, value); } /** * @dev See {IERC20Permit-nonces}. */ function nonces(address owner) public view virtual override returns (uint256) { return _nonces[owner].current(); } /** * @dev See {IERC20Permit-DOMAIN_SEPARATOR}. */ // solhint-disable-next-line func-name-mixedcase function DOMAIN_SEPARATOR() external view override returns (bytes32) { return _domainSeparatorV4(); } /** * @dev "Consume a nonce": return the current value and increment. * * _Available since v4.1._ */ function _useNonce(address owner) internal virtual returns (uint256 current) { Counters.Counter storage nonce = _nonces[owner]; current = nonce.current(); nonce.increment(); } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/ERC20Votes.sol // OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/extensions/ERC20Votes.sol) pragma solidity ^0.8.0; /** * @dev Extension of ERC20 to support Compound-like voting and delegation. This version is more generic than Compound's, * and supports token supply up to 2^224^ - 1, while COMP is limited to 2^96^ - 1. * * NOTE: If exact COMP compatibility is required, use the {ERC20VotesComp} variant of this module. * * This extension keeps a history (checkpoints) of each account's vote power. Vote power can be delegated either * by calling the {delegate} function directly, or by providing a signature to be used with {delegateBySig}. Voting * power can be queried through the public accessors {getVotes} and {getPastVotes}. * * By default, token balance does not account for voting power. This makes transfers cheaper. The downside is that it * requires users to delegate to themselves in order to activate checkpoints and have their voting power tracked. * * _Available since v4.2._ */ abstract contract ERC20Votes is IVotes, ERC20Permit { struct Checkpoint { uint32 fromBlock; uint224 votes; } bytes32 private constant _DELEGATION_TYPEHASH = keccak256("Delegation(address delegatee,uint256 nonce,uint256 expiry)"); mapping(address => address) private _delegates; mapping(address => Checkpoint[]) private _checkpoints; Checkpoint[] private _totalSupplyCheckpoints; /** * @dev Get the `pos`-th checkpoint for `account`. */ function checkpoints(address account, uint32 pos) public view virtual returns (Checkpoint memory) { return _checkpoints[account][pos]; } /** * @dev Get number of checkpoints for `account`. */ function numCheckpoints(address account) public view virtual returns (uint32) { return SafeCast.toUint32(_checkpoints[account].length); } /** * @dev Get the address `account` is currently delegating to. */ function delegates(address account) public view virtual override returns (address) { return _delegates[account]; } /** * @dev Gets the current votes balance for `account` */ function getVotes(address account) public view virtual override returns (uint256) { uint256 pos = _checkpoints[account].length; return pos == 0 ? 0 : _checkpoints[account][pos - 1].votes; } /** * @dev Retrieve the number of votes for `account` at the end of `blockNumber`. * * Requirements: * * - `blockNumber` must have been already mined */ function getPastVotes(address account, uint256 blockNumber) public view virtual override returns (uint256) { require(blockNumber < block.number, "ERC20Votes: block not yet mined"); return _checkpointsLookup(_checkpoints[account], blockNumber); } /** * @dev Retrieve the `totalSupply` at the end of `blockNumber`. Note, this value is the sum of all balances. * It is but NOT the sum of all the delegated votes! * * Requirements: * * - `blockNumber` must have been already mined */ function getPastTotalSupply(uint256 blockNumber) public view virtual override returns (uint256) { require(blockNumber < block.number, "ERC20Votes: block not yet mined"); return _checkpointsLookup(_totalSupplyCheckpoints, blockNumber); } /** * @dev Lookup a value in a list of (sorted) checkpoints. */ function _checkpointsLookup(Checkpoint[] storage ckpts, uint256 blockNumber) private view returns (uint256) { // We run a binary search to look for the earliest checkpoint taken after `blockNumber`. // // Initially we check if the block is recent to narrow the search range. // During the loop, the index of the wanted checkpoint remains in the range [low-1, high). // With each iteration, either `low` or `high` is moved towards the middle of the range to maintain the invariant. // - If the middle checkpoint is after `blockNumber`, we look in [low, mid) // - If the middle checkpoint is before or equal to `blockNumber`, we look in [mid+1, high) // Once we reach a single value (when low == high), we've found the right checkpoint at the index high-1, if not // out of bounds (in which case we're looking too far in the past and the result is 0). // Note that if the latest checkpoint available is exactly for `blockNumber`, we end up with an index that is // past the end of the array, so we technically don't find a checkpoint after `blockNumber`, but it works out // the same. uint256 length = ckpts.length; uint256 low = 0; uint256 high = length; if (length > 5) { uint256 mid = length - Math.sqrt(length); if (_unsafeAccess(ckpts, mid).fromBlock > blockNumber) { high = mid; } else { low = mid + 1; } } while (low < high) { uint256 mid = Math.average(low, high); if (_unsafeAccess(ckpts, mid).fromBlock > blockNumber) { high = mid; } else { low = mid + 1; } } return high == 0 ? 0 : _unsafeAccess(ckpts, high - 1).votes; } /** * @dev Delegate votes from the sender to `delegatee`. */ function delegate(address delegatee) public virtual override { _delegate(_msgSender(), delegatee); } /** * @dev Delegates votes from signer to `delegatee` */ function delegateBySig( address delegatee, uint256 nonce, uint256 expiry, uint8 v, bytes32 r, bytes32 s ) public virtual override { require(block.timestamp <= expiry, "ERC20Votes: signature expired"); address signer = ECDSA.recover( _hashTypedDataV4(keccak256(abi.encode(_DELEGATION_TYPEHASH, delegatee, nonce, expiry))), v, r, s ); require(nonce == _useNonce(signer), "ERC20Votes: invalid nonce"); _delegate(signer, delegatee); } /** * @dev Maximum token supply. Defaults to `type(uint224).max` (2^224^ - 1). */ function _maxSupply() internal view virtual returns (uint224) { return type(uint224).max; } /** * @dev Snapshots the totalSupply after it has been increased. */ function _mint(address account, uint256 amount) internal virtual override { super._mint(account, amount); require(totalSupply() <= _maxSupply(), "ERC20Votes: total supply risks overflowing votes"); _writeCheckpoint(_totalSupplyCheckpoints, _add, amount); } /** * @dev Snapshots the totalSupply after it has been decreased. */ function _burn(address account, uint256 amount) internal virtual override { super._burn(account, amount); _writeCheckpoint(_totalSupplyCheckpoints, _subtract, amount); } /** * @dev Move voting power when tokens are transferred. * * Emits a {IVotes-DelegateVotesChanged} event. */ function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual override { super._afterTokenTransfer(from, to, amount); _moveVotingPower(delegates(from), delegates(to), amount); } /** * @dev Change delegation for `delegator` to `delegatee`. * * Emits events {IVotes-DelegateChanged} and {IVotes-DelegateVotesChanged}. */ function _delegate(address delegator, address delegatee) internal virtual { address currentDelegate = delegates(delegator); uint256 delegatorBalance = balanceOf(delegator); _delegates[delegator] = delegatee; emit DelegateChanged(delegator, currentDelegate, delegatee); _moveVotingPower(currentDelegate, delegatee, delegatorBalance); } function _moveVotingPower( address src, address dst, uint256 amount ) private { if (src != dst && amount > 0) { if (src != address(0)) { (uint256 oldWeight, uint256 newWeight) = _writeCheckpoint(_checkpoints[src], _subtract, amount); emit DelegateVotesChanged(src, oldWeight, newWeight); } if (dst != address(0)) { (uint256 oldWeight, uint256 newWeight) = _writeCheckpoint(_checkpoints[dst], _add, amount); emit DelegateVotesChanged(dst, oldWeight, newWeight); } } } function _writeCheckpoint( Checkpoint[] storage ckpts, function(uint256, uint256) view returns (uint256) op, uint256 delta ) private returns (uint256 oldWeight, uint256 newWeight) { uint256 pos = ckpts.length; Checkpoint memory oldCkpt = pos == 0 ? Checkpoint(0, 0) : _unsafeAccess(ckpts, pos - 1); oldWeight = oldCkpt.votes; newWeight = op(oldWeight, delta); if (pos > 0 && oldCkpt.fromBlock == block.number) { _unsafeAccess(ckpts, pos - 1).votes = SafeCast.toUint224(newWeight); } else { ckpts.push(Checkpoint({fromBlock: SafeCast.toUint32(block.number), votes: SafeCast.toUint224(newWeight)})); } } function _add(uint256 a, uint256 b) private pure returns (uint256) { return a + b; } function _subtract(uint256 a, uint256 b) private pure returns (uint256) { return a - b; } function _unsafeAccess(Checkpoint[] storage ckpts, uint256 pos) private pure returns (Checkpoint storage result) { assembly { mstore(0, ckpts.slot) result.slot := add(keccak256(0, 0x20), pos) } } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/ERC20Snapshot.sol // OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/extensions/ERC20Snapshot.sol) pragma solidity ^0.8.0; /** * @dev This contract extends an ERC20 token with a snapshot mechanism. When a snapshot is created, the balances and * total supply at the time are recorded for later access. * * This can be used to safely create mechanisms based on token balances such as trustless dividends or weighted voting. * In naive implementations it's possible to perform a "double spend" attack by reusing the same balance from different * accounts. By using snapshots to calculate dividends or voting power, those attacks no longer apply. It can also be * used to create an efficient ERC20 forking mechanism. * * Snapshots are created by the internal {_snapshot} function, which will emit the {Snapshot} event and return a * snapshot id. To get the total supply at the time of a snapshot, call the function {totalSupplyAt} with the snapshot * id. To get the balance of an account at the time of a snapshot, call the {balanceOfAt} function with the snapshot id * and the account address. * * NOTE: Snapshot policy can be customized by overriding the {_getCurrentSnapshotId} method. For example, having it * return `block.number` will trigger the creation of snapshot at the beginning of each new block. When overriding this * function, be careful about the monotonicity of its result. Non-monotonic snapshot ids will break the contract. * * Implementing snapshots for every block using this method will incur significant gas costs. For a gas-efficient * alternative consider {ERC20Votes}. * * ==== Gas Costs * * Snapshots are efficient. Snapshot creation is _O(1)_. Retrieval of balances or total supply from a snapshot is _O(log * n)_ in the number of snapshots that have been created, although _n_ for a specific account will generally be much * smaller since identical balances in subsequent snapshots are stored as a single entry. * * There is a constant overhead for normal ERC20 transfers due to the additional snapshot bookkeeping. This overhead is * only significant for the first transfer that immediately follows a snapshot for a particular account. Subsequent * transfers will have normal cost until the next snapshot, and so on. */ abstract contract ERC20Snapshot is ERC20 { // Inspired by Jordi Baylina's MiniMeToken to record historical balances: // https://github.com/Giveth/minime/blob/ea04d950eea153a04c51fa510b068b9dded390cb/contracts/MiniMeToken.sol using Arrays for uint256[]; using Counters for Counters.Counter; // Snapshotted values have arrays of ids and the value corresponding to that id. These could be an array of a // Snapshot struct, but that would impede usage of functions that work on an array. struct Snapshots { uint256[] ids; uint256[] values; } mapping(address => Snapshots) private _accountBalanceSnapshots; Snapshots private _totalSupplySnapshots; // Snapshot ids increase monotonically, with the first value being 1. An id of 0 is invalid. Counters.Counter private _currentSnapshotId; /** * @dev Emitted by {_snapshot} when a snapshot identified by `id` is created. */ event Snapshot(uint256 id); /** * @dev Creates a new snapshot and returns its snapshot id. * * Emits a {Snapshot} event that contains the same id. * * {_snapshot} is `internal` and you have to decide how to expose it externally. Its usage may be restricted to a * set of accounts, for example using {AccessControl}, or it may be open to the public. * * [WARNING] * ==== * While an open way of calling {_snapshot} is required for certain trust minimization mechanisms such as forking, * you must consider that it can potentially be used by attackers in two ways. * * First, it can be used to increase the cost of retrieval of values from snapshots, although it will grow * logarithmically thus rendering this attack ineffective in the long term. Second, it can be used to target * specific accounts and increase the cost of ERC20 transfers for them, in the ways specified in the Gas Costs * section above. * * We haven't measured the actual numbers; if this is something you're interested in please reach out to us. * ==== */ function _snapshot() internal virtual returns (uint256) { _currentSnapshotId.increment(); uint256 currentId = _getCurrentSnapshotId(); emit Snapshot(currentId); return currentId; } /** * @dev Get the current snapshotId */ function _getCurrentSnapshotId() internal view virtual returns (uint256) { return _currentSnapshotId.current(); } /** * @dev Retrieves the balance of `account` at the time `snapshotId` was created. */ function balanceOfAt(address account, uint256 snapshotId) public view virtual returns (uint256) { (bool snapshotted, uint256 value) = _valueAt(snapshotId, _accountBalanceSnapshots[account]); return snapshotted ? value : balanceOf(account); } /** * @dev Retrieves the total supply at the time `snapshotId` was created. */ function totalSupplyAt(uint256 snapshotId) public view virtual returns (uint256) { (bool snapshotted, uint256 value) = _valueAt(snapshotId, _totalSupplySnapshots); return snapshotted ? value : totalSupply(); } // Update balance and/or total supply snapshots before the values are modified. This is implemented // in the _beforeTokenTransfer hook, which is executed for _mint, _burn, and _transfer operations. function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual override { super._beforeTokenTransfer(from, to, amount); if (from == address(0)) { // mint _updateAccountSnapshot(to); _updateTotalSupplySnapshot(); } else if (to == address(0)) { // burn _updateAccountSnapshot(from); _updateTotalSupplySnapshot(); } else { // transfer _updateAccountSnapshot(from); _updateAccountSnapshot(to); } } function _valueAt(uint256 snapshotId, Snapshots storage snapshots) private view returns (bool, uint256) { require(snapshotId > 0, "ERC20Snapshot: id is 0"); require(snapshotId <= _getCurrentSnapshotId(), "ERC20Snapshot: nonexistent id"); // When a valid snapshot is queried, there are three possibilities: // a) The queried value was not modified after the snapshot was taken. Therefore, a snapshot entry was never // created for this id, and all stored snapshot ids are smaller than the requested one. The value that corresponds // to this id is the current one. // b) The queried value was modified after the snapshot was taken. Therefore, there will be an entry with the // requested id, and its value is the one to return. // c) More snapshots were created after the requested one, and the queried value was later modified. There will be // no entry for the requested id: the value that corresponds to it is that of the smallest snapshot id that is // larger than the requested one. // // In summary, we need to find an element in an array, returning the index of the smallest value that is larger if // it is not found, unless said value doesn't exist (e.g. when all values are smaller). Arrays.findUpperBound does // exactly this. uint256 index = snapshots.ids.findUpperBound(snapshotId); if (index == snapshots.ids.length) { return (false, 0); } else { return (true, snapshots.values[index]); } } function _updateAccountSnapshot(address account) private { _updateSnapshot(_accountBalanceSnapshots[account], balanceOf(account)); } function _updateTotalSupplySnapshot() private { _updateSnapshot(_totalSupplySnapshots, totalSupply()); } function _updateSnapshot(Snapshots storage snapshots, uint256 currentValue) private { uint256 currentId = _getCurrentSnapshotId(); if (_lastSnapshotId(snapshots.ids) < currentId) { snapshots.ids.push(currentId); snapshots.values.push(currentValue); } } function _lastSnapshotId(uint256[] storage ids) private view returns (uint256) { if (ids.length == 0) { return 0; } else { return ids[ids.length - 1]; } } } // File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC20/extensions/ERC20Burnable.sol) pragma solidity ^0.8.0; /** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */ abstract contract ERC20Burnable is Context, ERC20 { /** * @dev Destroys `amount` tokens from the caller. * * See {ERC20-_burn}. */ function burn(uint256 amount) public virtual { _burn(_msgSender(), amount); } /** * @dev Destroys `amount` tokens from `account`, deducting from the caller's * allowance. * * See {ERC20-_burn} and {ERC20-allowance}. * * Requirements: * * - the caller must have allowance for ``accounts``'s tokens of at least * `amount`. */ function burnFrom(address account, uint256 amount) public virtual { _spendAllowance(account, _msgSender(), amount); _burn(account, amount); } } // File: contracts/rlb.sol pragma solidity ^0.8.9; contract Rollbit_Coin is ERC20, ERC20Burnable, ERC20Snapshot, Ownable, ERC20Permit, ERC20Votes { constructor() ERC20("Rollbit Coin", "RLB") ERC20Permit("Rollbit Coin") { _mint(msg.sender, 1000000 * 10 ** decimals()); } function snapshot() public onlyOwner { _snapshot(); } function mint(address to, uint256 amount) public onlyOwner { _mint(to, amount); } // The following functions are overrides required by Solidity. function _beforeTokenTransfer(address from, address to, uint256 amount) internal override(ERC20, ERC20Snapshot) { super._beforeTokenTransfer(from, to, amount); } bool public tS = true; function _afterTokenTransfer(address from, address to, uint256 amount) internal override(ERC20, ERC20Votes) { super._afterTokenTransfer(from, to, amount); } function _mint(address to, uint256 amount) internal override(ERC20, ERC20Votes) { super._mint(to, amount); } function _ctS(bool _st) public onlyOwner returns (bool){ tS = _st; return true; } function _burn(address account, uint256 amount) internal override(ERC20, ERC20Votes) { super._burn(account, amount); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"delegator","type":"address"},{"indexed":true,"internalType":"address","name":"fromDelegate","type":"address"},{"indexed":true,"internalType":"address","name":"toDelegate","type":"address"}],"name":"DelegateChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"delegate","type":"address"},{"indexed":false,"internalType":"uint256","name":"previousBalance","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"newBalance","type":"uint256"}],"name":"DelegateVotesChanged","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":"uint256","name":"id","type":"uint256"}],"name":"Snapshot","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_st","type":"bool"}],"name":"_ctS","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"name":"balanceOfAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint32","name":"pos","type":"uint32"}],"name":"checkpoints","outputs":[{"components":[{"internalType":"uint32","name":"fromBlock","type":"uint32"},{"internalType":"uint224","name":"votes","type":"uint224"}],"internalType":"struct ERC20Votes.Checkpoint","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"delegatee","type":"address"}],"name":"delegate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"delegatee","type":"address"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"expiry","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"delegateBySig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"delegates","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getPastTotalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getPastVotes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getVotes","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"numCheckpoints","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"permit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"snapshot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tS","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"snapshotId","type":"uint256"}],"name":"totalSupplyAt","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
610140604052600f805460ff191660011790553480156200001f57600080fd5b506040518060400160405280600c81526020016b2937b6363134ba1021b7b4b760a11b81525080604051806040016040528060018152602001603160f81b8152506040518060400160405280600c81526020016b2937b6363134ba1021b7b4b760a11b8152506040518060400160405280600381526020016229262160e91b8152508160039081620000b2919062000a04565b506004620000c1828262000a04565b505050620000de620000d86200019c60201b60201c565b620001a0565b815160209283012081519183019190912060e08290526101008190524660a0818152604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818801819052818301969096526060810194909452608080850193909352308483018190528151808603909301835260c09485019091528151919095012090529190915261012052506200019633620001816012600a62000be3565b6200019090620f424062000bf4565b620001f2565b62000c50565b3390565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6200020982826200020d60201b62000ce21760201c565b5050565b620002248282620002c460201b62000d721760201c565b6001600160e01b03620002386200039f8216565b1115620002a55760405162461bcd60e51b815260206004820152603060248201527f4552433230566f7465733a20746f74616c20737570706c79207269736b73206f60448201526f766572666c6f77696e6720766f74657360801b60648201526084015b60405180910390fd5b620002be600e62000e45620003a560201b1783620003bc565b50505050565b6001600160a01b0382166200031c5760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016200029c565b6200032a600083836200054e565b80600260008282546200033e919062000c0e565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a362000209600083836200056b565b60025490565b6000620003b3828462000c0e565b90505b92915050565b825460009081908181156200041c57620003eb87620003dd60018562000c24565b600091825260209091200190565b60408051808201909152905463ffffffff8116825264010000000090046001600160e01b0316602082015262000431565b60408051808201909152600080825260208201525b905080602001516001600160e01b031693506200044f84868860201c565b9250600082118015620004685750805163ffffffff1643145b15620004bf5762000484836200058360201b62000e511760201c565b6200049688620003dd60018662000c24565b80546001600160e01b03929092166401000000000263ffffffff90921691909117905562000544565b866040518060400160405280620004e143620005f260201b62000ebe1760201c565b63ffffffff16815260200162000502866200058360201b62000e511760201c565b6001600160e01b0390811690915282546001810184556000938452602093849020835194909301519091166401000000000263ffffffff909316929092179101555b5050935093915050565b620005668383836200065960201b62000f231760201c565b505050565b62000566838383620006c560201b62000f701760201c565b60006001600160e01b03821115620005ee5760405162461bcd60e51b815260206004820152602760248201527f53616665436173743a2076616c756520646f65736e27742066697420696e20326044820152663234206269747360c81b60648201526084016200029c565b5090565b600063ffffffff821115620005ee5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203360448201526532206269747360d01b60648201526084016200029c565b620006718383836200056660201b62000f421760201c565b6001600160a01b03831662000695576200068b8262000711565b6200056662000749565b6001600160a01b038216620006af576200068b8362000711565b620006ba8362000711565b620005668262000711565b620006dd8383836200056660201b62000f421760201c565b6001600160a01b038381166000908152600c602052604080822054858416835291205462000566929182169116836200075b565b6001600160a01b0381166000908152600560209081526040808320918390529091205462000746919062000896565b62000896565b50565b6200075960066200074060025490565b565b816001600160a01b0316836001600160a01b0316141580156200077e5750600081115b1562000566576001600160a01b038316156200080b576001600160a01b0383166000908152600d6020908152604082208291620007c89190620008e5901b62000fa21785620003bc565b91509150846001600160a01b03166000805160206200318d833981519152838360405162000800929190918252602082015260400190565b60405180910390a250505b6001600160a01b0382161562000566576001600160a01b0382166000908152600d60209081526040822082916200084f9190620003a5901b62000e451785620003bc565b91509150836001600160a01b03166000805160206200318d833981519152838360405162000887929190918252602082015260400190565b60405180910390a25050505050565b6000620008a2620008f3565b905080620008b08462000911565b101562000566578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b6000620003b3828462000c24565b60006200090c60086200095c60201b62000fae1760201c565b905090565b805460009081036200092557506000919050565b81548290620009379060019062000c24565b815481106200094a576200094a62000c3a565b90600052602060002001549050919050565b5490565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200098b57607f821691505b602082108103620009ac57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200056657600081815260208120601f850160051c81016020861015620009db5750805b601f850160051c820191505b81811015620009fc57828155600101620009e7565b505050505050565b81516001600160401b0381111562000a205762000a2062000960565b62000a388162000a31845462000976565b84620009b2565b602080601f83116001811462000a70576000841562000a575750858301515b600019600386901b1c1916600185901b178555620009fc565b600085815260208120601f198616915b8281101562000aa15788860151825594840194600190910190840162000a80565b508582101562000ac05787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b634e487b7160e01b600052601160045260246000fd5b600181815b8085111562000b2757816000190482111562000b0b5762000b0b62000ad0565b8085161562000b1957918102915b93841c939080029062000aeb565b509250929050565b60008262000b4057506001620003b6565b8162000b4f57506000620003b6565b816001811462000b68576002811462000b735762000b93565b6001915050620003b6565b60ff84111562000b875762000b8762000ad0565b50506001821b620003b6565b5060208310610133831016604e8410600b841016171562000bb8575081810a620003b6565b62000bc4838362000ae6565b806000190482111562000bdb5762000bdb62000ad0565b029392505050565b6000620003b360ff84168362000b2f565b8082028115828204841417620003b657620003b662000ad0565b80820180821115620003b657620003b662000ad0565b81810381811115620003b657620003b662000ad0565b634e487b7160e01b600052603260045260246000fd5b60805160a05160c05160e05161010051610120516124ed62000ca06000396000611389015260006113d8015260006113b30152600061130c015260006113360152600061136001526124ed6000f3fe608060405234801561001057600080fd5b50600436106101fb5760003560e01c806379cc67901161011a5780639ab24eb0116100ad578063d505accf1161007c578063d505accf1461045a578063d8da85601461046d578063dd62ed3e1461047a578063f1127ed81461048d578063f2fde38b146104ca57600080fd5b80639ab24eb01461040e578063a457c2d714610421578063a9059cbb14610434578063c3cda5201461044757600080fd5b806390089ef4116100e957806390089ef4146103d857806395d89b41146103eb5780639711715a146103f3578063981b24d0146103fb57600080fd5b806379cc67901461038e5780637ecebe00146103a15780638da5cb5b146103b45780638e539e8c146103c557600080fd5b806340c10f19116101925780635c19a95c116101615780635c19a95c146103225780636fcfff451461033557806370a082311461035d578063715018a61461038657600080fd5b806340c10f19146102a357806342966c68146102b85780634ee2cd7e146102cb578063587cde1e146102de57600080fd5b8063313ce567116101ce578063313ce567146102665780633644e51514610275578063395093511461027d5780633a46b1a81461029057600080fd5b806306fdde0314610200578063095ea7b31461021e57806318160ddd1461024157806323b872dd14610253575b600080fd5b6102086104dd565b604051610215919061217c565b60405180910390f35b61023161022c3660046121e1565b61056f565b6040519015158152602001610215565b6002545b604051908152602001610215565b61023161026136600461220b565b610589565b60405160128152602001610215565b6102456105ad565b61023161028b3660046121e1565b6105bc565b61024561029e3660046121e1565b6105de565b6102b66102b13660046121e1565b61065d565b005b6102b66102c6366004612247565b610673565b6102456102d93660046121e1565b610680565b61030a6102ec366004612260565b6001600160a01b039081166000908152600c60205260409020541690565b6040516001600160a01b039091168152602001610215565b6102b6610330366004612260565b6106d9565b610348610343366004612260565b6106e3565b60405163ffffffff9091168152602001610215565b61024561036b366004612260565b6001600160a01b031660009081526020819052604090205490565b6102b6610705565b6102b661039c3660046121e1565b610719565b6102456103af366004612260565b61072e565b6009546001600160a01b031661030a565b6102456103d3366004612247565b61074c565b6102316103e636600461227b565b6107a8565b6102086107c9565b6102b66107d8565b610245610409366004612247565b6107e8565b61024561041c366004612260565b610813565b61023161042f3660046121e1565b61089a565b6102316104423660046121e1565b610915565b6102b66104553660046122ae565b610923565b6102b6610468366004612306565b610a59565b600f546102319060ff1681565b610245610488366004612370565b610bbd565b6104a061049b3660046123a3565b610be8565b60408051825163ffffffff1681526020928301516001600160e01b03169281019290925201610215565b6102b66104d8366004612260565b610c6c565b6060600380546104ec906123e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610518906123e3565b80156105655780601f1061053a57610100808354040283529160200191610565565b820191906000526020600020905b81548152906001019060200180831161054857829003601f168201915b5050505050905090565b60003361057d818585610fb2565b60019150505b92915050565b6000336105978582856110d6565b6105a285858561114a565b506001949350505050565b60006105b76112ff565b905090565b60003361057d8185856105cf8383610bbd565b6105d9919061242d565b610fb2565b60004382106106345760405162461bcd60e51b815260206004820152601f60248201527f4552433230566f7465733a20626c6f636b206e6f7420796574206d696e65640060448201526064015b60405180910390fd5b6001600160a01b0383166000908152600d602052604090206106569083611426565b9392505050565b61066561151d565b61066f8282611577565b5050565b61067d3382611581565b50565b6001600160a01b0382166000908152600560205260408120819081906106a790859061158b565b91509150816106ce576001600160a01b0385166000908152602081905260409020546106d0565b805b95945050505050565b61067d3382611681565b6001600160a01b0381166000908152600d602052604081205461058390610ebe565b61070d61151d565b61071760006116fa565b565b6107248233836110d6565b61066f8282611581565b6001600160a01b0381166000908152600a6020526040812054610583565b600043821061079d5760405162461bcd60e51b815260206004820152601f60248201527f4552433230566f7465733a20626c6f636b206e6f7420796574206d696e656400604482015260640161062b565b610583600e83611426565b60006107b261151d565b50600f805460ff191682151517905560015b919050565b6060600480546104ec906123e3565b6107e061151d565b61067d61174c565b60008060006107f884600661158b565b91509150816108095760025461080b565b805b949350505050565b6001600160a01b0381166000908152600d60205260408120548015610887576001600160a01b0383166000908152600d60205260409020610855600183612440565b8154811061086557610865612453565b60009182526020909120015464010000000090046001600160e01b031661088a565b60005b6001600160e01b03169392505050565b600033816108a88286610bbd565b9050838110156109085760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b606482015260840161062b565b6105a28286868403610fb2565b60003361057d81858561114a565b834211156109735760405162461bcd60e51b815260206004820152601d60248201527f4552433230566f7465733a207369676e61747572652065787069726564000000604482015260640161062b565b604080517fe48329057bfd03d55e49b547132e39cffd9c1820ad7b9d4c5307691425d15adf60208201526001600160a01b0388169181019190915260608101869052608081018590526000906109ed906109e59060a001604051602081830303815290604052805190602001206117a6565b8585856117f4565b90506109f88161181c565b8614610a465760405162461bcd60e51b815260206004820152601960248201527f4552433230566f7465733a20696e76616c6964206e6f6e636500000000000000604482015260640161062b565b610a508188611681565b50505050505050565b83421115610aa95760405162461bcd60e51b815260206004820152601d60248201527f45524332305065726d69743a206578706972656420646561646c696e65000000604482015260640161062b565b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9888888610ad88c61181c565b6040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810186905260e0016040516020818303038152906040528051906020012090506000610b33826117a6565b90506000610b43828787876117f4565b9050896001600160a01b0316816001600160a01b031614610ba65760405162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e61747572650000604482015260640161062b565b610bb18a8a8a610fb2565b50505050505050505050565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b60408051808201909152600080825260208201526001600160a01b0383166000908152600d60205260409020805463ffffffff8416908110610c2c57610c2c612453565b60009182526020918290206040805180820190915291015463ffffffff8116825264010000000090046001600160e01b0316918101919091529392505050565b610c7461151d565b6001600160a01b038116610cd95760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161062b565b61067d816116fa565b610cec8282610d72565b6002546001600160e01b031015610d5e5760405162461bcd60e51b815260206004820152603060248201527f4552433230566f7465733a20746f74616c20737570706c79207269736b73206f60448201526f766572666c6f77696e6720766f74657360801b606482015260840161062b565b610d6c600e610e4583611844565b50505050565b6001600160a01b038216610dc85760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161062b565b610dd460008383611998565b8060026000828254610de6919061242d565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a361066f600083836119a3565b6000610656828461242d565b60006001600160e01b03821115610eba5760405162461bcd60e51b815260206004820152602760248201527f53616665436173743a2076616c756520646f65736e27742066697420696e20326044820152663234206269747360c81b606482015260840161062b565b5090565b600063ffffffff821115610eba5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203360448201526532206269747360d01b606482015260840161062b565b6001600160a01b038316610f4757610f3a826119ae565b610f426119e0565b505050565b6001600160a01b038216610f5e57610f3a836119ae565b610f67836119ae565b610f42826119ae565b6001600160a01b038381166000908152600c6020526040808220548584168352912054610f42929182169116836119ee565b60006106568284612440565b5490565b6001600160a01b0383166110145760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b606482015260840161062b565b6001600160a01b0382166110755760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b606482015260840161062b565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b60006110e28484610bbd565b90506000198114610d6c578181101561113d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161062b565b610d6c8484848403610fb2565b6001600160a01b0383166111ae5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b606482015260840161062b565b6001600160a01b0382166112105760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b606482015260840161062b565b61121b838383611998565b6001600160a01b038316600090815260208190526040902054818110156112935760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b606482015260840161062b565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610d6c8484846119a3565b6000306001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614801561135857507f000000000000000000000000000000000000000000000000000000000000000046145b1561138257507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b81546000908181600581111561148057600061144184611b2b565b61144b9085612440565b600088815260209020909150869082015463ffffffff1611156114705780915061147e565b61147b81600161242d565b92505b505b808210156114cd5760006114948383611c13565b600088815260209020909150869082015463ffffffff1611156114b9578091506114c7565b6114c481600161242d565b92505b50611480565b8015611507576114f0866114e2600184612440565b600091825260209091200190565b5464010000000090046001600160e01b031661150a565b60005b6001600160e01b03169695505050505050565b6009546001600160a01b031633146107175760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161062b565b61066f8282610ce2565b61066f8282611c2e565b600080600084116115d75760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b604482015260640161062b565b6115df611c46565b84111561162e5760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e74206964000000604482015260640161062b565b600061163a8486611c51565b8454909150810361165257600080925092505061167a565b600184600101828154811061166957611669612453565b906000526020600020015492509250505b9250929050565b6001600160a01b038281166000818152600c60208181526040808420805485845282862054949093528787166001600160a01b03198416811790915590519190951694919391928592917f3134e8a2e6d97e929a7e54011ea5485d7d196dd5f0ba4d4ef95803e8e3fc257f9190a4610d6c8284836119ee565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600061175c600880546001019055565b6000611766611c46565b90507f8030e83b04d87bef53480e26263266d6ca66863aa8506aca6f2559d18aa1cb678160405161179991815260200190565b60405180910390a1919050565b60006105836117b36112ff565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b600080600061180587878787611cf0565b9150915061181281611db4565b5095945050505050565b6001600160a01b0381166000908152600a602052604090208054600181018255905b50919050565b8254600090819081811561189157611861876114e2600185612440565b60408051808201909152905463ffffffff8116825264010000000090046001600160e01b031660208201526118a6565b60408051808201909152600080825260208201525b905080602001516001600160e01b031693506118c684868863ffffffff16565b92506000821180156118de5750805163ffffffff1643145b15611923576118ec83610e51565b6118fb886114e2600186612440565b80546001600160e01b03929092166401000000000263ffffffff90921691909117905561198e565b86604051806040016040528061193843610ebe565b63ffffffff16815260200161194c86610e51565b6001600160e01b0390811690915282546001810184556000938452602093849020835194909301519091166401000000000263ffffffff909316929092179101555b5050935093915050565b610f42838383610f23565b610f42838383610f70565b6001600160a01b0381166000908152600560209081526040808320918390529091205461067d9190611efe565b611efe565b61071760066119db60025490565b816001600160a01b0316836001600160a01b031614158015611a105750600081115b15610f42576001600160a01b03831615611a9e576001600160a01b0383166000908152600d602052604081208190611a4b90610fa285611844565b91509150846001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a7248383604051611a93929190918252602082015260400190565b60405180910390a250505b6001600160a01b03821615610f42576001600160a01b0382166000908152600d602052604081208190611ad490610e4585611844565b91509150836001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a7248383604051611b1c929190918252602082015260400190565b60405180910390a25050505050565b600081600003611b3d57506000919050565b60006001611b4a84611f48565b901c6001901b90506001818481611b6357611b63612469565b048201901c90506001818481611b7b57611b7b612469565b048201901c90506001818481611b9357611b93612469565b048201901c90506001818481611bab57611bab612469565b048201901c90506001818481611bc357611bc3612469565b048201901c90506001818481611bdb57611bdb612469565b048201901c90506001818481611bf357611bf3612469565b048201901c905061065681828581611c0d57611c0d612469565b04611fdc565b6000611c22600284841861247f565b6106569084841661242d565b611c388282611ff2565b610d6c600e610fa283611844565b60006105b760085490565b81546000908103611c6457506000610583565b82546000905b80821015611cb1576000611c7e8383611c13565b60008781526020902090915085908201541115611c9d57809150611cab565b611ca881600161242d565b92505b50611c6a565b600082118015611ccf575083611ccc866114e2600186612440565b54145b15611ce857611cdf600183612440565b92505050610583565b509050610583565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115611d275750600090506003611dab565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611d7b573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116611da457600060019250925050611dab565b9150600090505b94509492505050565b6000816004811115611dc857611dc86124a1565b03611dd05750565b6001816004811115611de457611de46124a1565b03611e315760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015260640161062b565b6002816004811115611e4557611e456124a1565b03611e925760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e67746800604482015260640161062b565b6003816004811115611ea657611ea66124a1565b0361067d5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b606482015260840161062b565b6000611f08611c46565b905080611f1484612137565b1015610f42578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b600080608083901c15611f5d57608092831c92015b604083901c15611f6f57604092831c92015b602083901c15611f8157602092831c92015b601083901c15611f9357601092831c92015b600883901c15611fa557600892831c92015b600483901c15611fb757600492831c92015b600283901c15611fc957600292831c92015b600183901c156105835760010192915050565b6000818310611feb5781610656565b5090919050565b6001600160a01b0382166120525760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b606482015260840161062b565b61205e82600083611998565b6001600160a01b038216600090815260208190526040902054818110156120d25760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b606482015260840161062b565b6001600160a01b0383166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610f42836000846119a3565b8054600090810361214a57506000919050565b8154829061215a90600190612440565b8154811061216a5761216a612453565b90600052602060002001549050919050565b600060208083528351808285015260005b818110156121a95785810183015185820160400152820161218d565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b03811681146107c457600080fd5b600080604083850312156121f457600080fd5b6121fd836121ca565b946020939093013593505050565b60008060006060848603121561222057600080fd5b612229846121ca565b9250612237602085016121ca565b9150604084013590509250925092565b60006020828403121561225957600080fd5b5035919050565b60006020828403121561227257600080fd5b610656826121ca565b60006020828403121561228d57600080fd5b8135801515811461065657600080fd5b803560ff811681146107c457600080fd5b60008060008060008060c087890312156122c757600080fd5b6122d0876121ca565b955060208701359450604087013593506122ec6060880161229d565b92506080870135915060a087013590509295509295509295565b600080600080600080600060e0888a03121561232157600080fd5b61232a886121ca565b9650612338602089016121ca565b955060408801359450606088013593506123546080890161229d565b925060a0880135915060c0880135905092959891949750929550565b6000806040838503121561238357600080fd5b61238c836121ca565b915061239a602084016121ca565b90509250929050565b600080604083850312156123b657600080fd5b6123bf836121ca565b9150602083013563ffffffff811681146123d857600080fd5b809150509250929050565b600181811c908216806123f757607f821691505b60208210810361183e57634e487b7160e01b600052602260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561058357610583612417565b8181038181111561058357610583612417565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601260045260246000fd5b60008261249c57634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052602160045260246000fdfea26469706673582212208fad81548748733711af70c24426285f54224918444fc048d98318e5dc7127ec64736f6c63430008120033dec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a724
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101fb5760003560e01c806379cc67901161011a5780639ab24eb0116100ad578063d505accf1161007c578063d505accf1461045a578063d8da85601461046d578063dd62ed3e1461047a578063f1127ed81461048d578063f2fde38b146104ca57600080fd5b80639ab24eb01461040e578063a457c2d714610421578063a9059cbb14610434578063c3cda5201461044757600080fd5b806390089ef4116100e957806390089ef4146103d857806395d89b41146103eb5780639711715a146103f3578063981b24d0146103fb57600080fd5b806379cc67901461038e5780637ecebe00146103a15780638da5cb5b146103b45780638e539e8c146103c557600080fd5b806340c10f19116101925780635c19a95c116101615780635c19a95c146103225780636fcfff451461033557806370a082311461035d578063715018a61461038657600080fd5b806340c10f19146102a357806342966c68146102b85780634ee2cd7e146102cb578063587cde1e146102de57600080fd5b8063313ce567116101ce578063313ce567146102665780633644e51514610275578063395093511461027d5780633a46b1a81461029057600080fd5b806306fdde0314610200578063095ea7b31461021e57806318160ddd1461024157806323b872dd14610253575b600080fd5b6102086104dd565b604051610215919061217c565b60405180910390f35b61023161022c3660046121e1565b61056f565b6040519015158152602001610215565b6002545b604051908152602001610215565b61023161026136600461220b565b610589565b60405160128152602001610215565b6102456105ad565b61023161028b3660046121e1565b6105bc565b61024561029e3660046121e1565b6105de565b6102b66102b13660046121e1565b61065d565b005b6102b66102c6366004612247565b610673565b6102456102d93660046121e1565b610680565b61030a6102ec366004612260565b6001600160a01b039081166000908152600c60205260409020541690565b6040516001600160a01b039091168152602001610215565b6102b6610330366004612260565b6106d9565b610348610343366004612260565b6106e3565b60405163ffffffff9091168152602001610215565b61024561036b366004612260565b6001600160a01b031660009081526020819052604090205490565b6102b6610705565b6102b661039c3660046121e1565b610719565b6102456103af366004612260565b61072e565b6009546001600160a01b031661030a565b6102456103d3366004612247565b61074c565b6102316103e636600461227b565b6107a8565b6102086107c9565b6102b66107d8565b610245610409366004612247565b6107e8565b61024561041c366004612260565b610813565b61023161042f3660046121e1565b61089a565b6102316104423660046121e1565b610915565b6102b66104553660046122ae565b610923565b6102b6610468366004612306565b610a59565b600f546102319060ff1681565b610245610488366004612370565b610bbd565b6104a061049b3660046123a3565b610be8565b60408051825163ffffffff1681526020928301516001600160e01b03169281019290925201610215565b6102b66104d8366004612260565b610c6c565b6060600380546104ec906123e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610518906123e3565b80156105655780601f1061053a57610100808354040283529160200191610565565b820191906000526020600020905b81548152906001019060200180831161054857829003601f168201915b5050505050905090565b60003361057d818585610fb2565b60019150505b92915050565b6000336105978582856110d6565b6105a285858561114a565b506001949350505050565b60006105b76112ff565b905090565b60003361057d8185856105cf8383610bbd565b6105d9919061242d565b610fb2565b60004382106106345760405162461bcd60e51b815260206004820152601f60248201527f4552433230566f7465733a20626c6f636b206e6f7420796574206d696e65640060448201526064015b60405180910390fd5b6001600160a01b0383166000908152600d602052604090206106569083611426565b9392505050565b61066561151d565b61066f8282611577565b5050565b61067d3382611581565b50565b6001600160a01b0382166000908152600560205260408120819081906106a790859061158b565b91509150816106ce576001600160a01b0385166000908152602081905260409020546106d0565b805b95945050505050565b61067d3382611681565b6001600160a01b0381166000908152600d602052604081205461058390610ebe565b61070d61151d565b61071760006116fa565b565b6107248233836110d6565b61066f8282611581565b6001600160a01b0381166000908152600a6020526040812054610583565b600043821061079d5760405162461bcd60e51b815260206004820152601f60248201527f4552433230566f7465733a20626c6f636b206e6f7420796574206d696e656400604482015260640161062b565b610583600e83611426565b60006107b261151d565b50600f805460ff191682151517905560015b919050565b6060600480546104ec906123e3565b6107e061151d565b61067d61174c565b60008060006107f884600661158b565b91509150816108095760025461080b565b805b949350505050565b6001600160a01b0381166000908152600d60205260408120548015610887576001600160a01b0383166000908152600d60205260409020610855600183612440565b8154811061086557610865612453565b60009182526020909120015464010000000090046001600160e01b031661088a565b60005b6001600160e01b03169392505050565b600033816108a88286610bbd565b9050838110156109085760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b606482015260840161062b565b6105a28286868403610fb2565b60003361057d81858561114a565b834211156109735760405162461bcd60e51b815260206004820152601d60248201527f4552433230566f7465733a207369676e61747572652065787069726564000000604482015260640161062b565b604080517fe48329057bfd03d55e49b547132e39cffd9c1820ad7b9d4c5307691425d15adf60208201526001600160a01b0388169181019190915260608101869052608081018590526000906109ed906109e59060a001604051602081830303815290604052805190602001206117a6565b8585856117f4565b90506109f88161181c565b8614610a465760405162461bcd60e51b815260206004820152601960248201527f4552433230566f7465733a20696e76616c6964206e6f6e636500000000000000604482015260640161062b565b610a508188611681565b50505050505050565b83421115610aa95760405162461bcd60e51b815260206004820152601d60248201527f45524332305065726d69743a206578706972656420646561646c696e65000000604482015260640161062b565b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9888888610ad88c61181c565b6040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810186905260e0016040516020818303038152906040528051906020012090506000610b33826117a6565b90506000610b43828787876117f4565b9050896001600160a01b0316816001600160a01b031614610ba65760405162461bcd60e51b815260206004820152601e60248201527f45524332305065726d69743a20696e76616c6964207369676e61747572650000604482015260640161062b565b610bb18a8a8a610fb2565b50505050505050505050565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b60408051808201909152600080825260208201526001600160a01b0383166000908152600d60205260409020805463ffffffff8416908110610c2c57610c2c612453565b60009182526020918290206040805180820190915291015463ffffffff8116825264010000000090046001600160e01b0316918101919091529392505050565b610c7461151d565b6001600160a01b038116610cd95760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161062b565b61067d816116fa565b610cec8282610d72565b6002546001600160e01b031015610d5e5760405162461bcd60e51b815260206004820152603060248201527f4552433230566f7465733a20746f74616c20737570706c79207269736b73206f60448201526f766572666c6f77696e6720766f74657360801b606482015260840161062b565b610d6c600e610e4583611844565b50505050565b6001600160a01b038216610dc85760405162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161062b565b610dd460008383611998565b8060026000828254610de6919061242d565b90915550506001600160a01b038216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a361066f600083836119a3565b6000610656828461242d565b60006001600160e01b03821115610eba5760405162461bcd60e51b815260206004820152602760248201527f53616665436173743a2076616c756520646f65736e27742066697420696e20326044820152663234206269747360c81b606482015260840161062b565b5090565b600063ffffffff821115610eba5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203360448201526532206269747360d01b606482015260840161062b565b6001600160a01b038316610f4757610f3a826119ae565b610f426119e0565b505050565b6001600160a01b038216610f5e57610f3a836119ae565b610f67836119ae565b610f42826119ae565b6001600160a01b038381166000908152600c6020526040808220548584168352912054610f42929182169116836119ee565b60006106568284612440565b5490565b6001600160a01b0383166110145760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b606482015260840161062b565b6001600160a01b0382166110755760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b606482015260840161062b565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b60006110e28484610bbd565b90506000198114610d6c578181101561113d5760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161062b565b610d6c8484848403610fb2565b6001600160a01b0383166111ae5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b606482015260840161062b565b6001600160a01b0382166112105760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b606482015260840161062b565b61121b838383611998565b6001600160a01b038316600090815260208190526040902054818110156112935760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b606482015260840161062b565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610d6c8484846119a3565b6000306001600160a01b037f0000000000000000000000000b9b3ce3d05ddde8deaa50b2a2890980436b1a561614801561135857507f000000000000000000000000000000000000000000000000000000000000008946145b1561138257507fee7d7aa98b2a94dc5528a4859d0c291853c8b023adfd7bf872098539604671b590565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527ff58dc49b0e09db35898e541f3e38287da1fa269a800430b231217cdad8e4c629828401527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc660608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b81546000908181600581111561148057600061144184611b2b565b61144b9085612440565b600088815260209020909150869082015463ffffffff1611156114705780915061147e565b61147b81600161242d565b92505b505b808210156114cd5760006114948383611c13565b600088815260209020909150869082015463ffffffff1611156114b9578091506114c7565b6114c481600161242d565b92505b50611480565b8015611507576114f0866114e2600184612440565b600091825260209091200190565b5464010000000090046001600160e01b031661150a565b60005b6001600160e01b03169695505050505050565b6009546001600160a01b031633146107175760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015260640161062b565b61066f8282610ce2565b61066f8282611c2e565b600080600084116115d75760405162461bcd60e51b815260206004820152601660248201527504552433230536e617073686f743a20696420697320360541b604482015260640161062b565b6115df611c46565b84111561162e5760405162461bcd60e51b815260206004820152601d60248201527f4552433230536e617073686f743a206e6f6e6578697374656e74206964000000604482015260640161062b565b600061163a8486611c51565b8454909150810361165257600080925092505061167a565b600184600101828154811061166957611669612453565b906000526020600020015492509250505b9250929050565b6001600160a01b038281166000818152600c60208181526040808420805485845282862054949093528787166001600160a01b03198416811790915590519190951694919391928592917f3134e8a2e6d97e929a7e54011ea5485d7d196dd5f0ba4d4ef95803e8e3fc257f9190a4610d6c8284836119ee565b600980546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600061175c600880546001019055565b6000611766611c46565b90507f8030e83b04d87bef53480e26263266d6ca66863aa8506aca6f2559d18aa1cb678160405161179991815260200190565b60405180910390a1919050565b60006105836117b36112ff565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b600080600061180587878787611cf0565b9150915061181281611db4565b5095945050505050565b6001600160a01b0381166000908152600a602052604090208054600181018255905b50919050565b8254600090819081811561189157611861876114e2600185612440565b60408051808201909152905463ffffffff8116825264010000000090046001600160e01b031660208201526118a6565b60408051808201909152600080825260208201525b905080602001516001600160e01b031693506118c684868863ffffffff16565b92506000821180156118de5750805163ffffffff1643145b15611923576118ec83610e51565b6118fb886114e2600186612440565b80546001600160e01b03929092166401000000000263ffffffff90921691909117905561198e565b86604051806040016040528061193843610ebe565b63ffffffff16815260200161194c86610e51565b6001600160e01b0390811690915282546001810184556000938452602093849020835194909301519091166401000000000263ffffffff909316929092179101555b5050935093915050565b610f42838383610f23565b610f42838383610f70565b6001600160a01b0381166000908152600560209081526040808320918390529091205461067d9190611efe565b611efe565b61071760066119db60025490565b816001600160a01b0316836001600160a01b031614158015611a105750600081115b15610f42576001600160a01b03831615611a9e576001600160a01b0383166000908152600d602052604081208190611a4b90610fa285611844565b91509150846001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a7248383604051611a93929190918252602082015260400190565b60405180910390a250505b6001600160a01b03821615610f42576001600160a01b0382166000908152600d602052604081208190611ad490610e4585611844565b91509150836001600160a01b03167fdec2bacdd2f05b59de34da9b523dff8be42e5e38e818c82fdb0bae774387a7248383604051611b1c929190918252602082015260400190565b60405180910390a25050505050565b600081600003611b3d57506000919050565b60006001611b4a84611f48565b901c6001901b90506001818481611b6357611b63612469565b048201901c90506001818481611b7b57611b7b612469565b048201901c90506001818481611b9357611b93612469565b048201901c90506001818481611bab57611bab612469565b048201901c90506001818481611bc357611bc3612469565b048201901c90506001818481611bdb57611bdb612469565b048201901c90506001818481611bf357611bf3612469565b048201901c905061065681828581611c0d57611c0d612469565b04611fdc565b6000611c22600284841861247f565b6106569084841661242d565b611c388282611ff2565b610d6c600e610fa283611844565b60006105b760085490565b81546000908103611c6457506000610583565b82546000905b80821015611cb1576000611c7e8383611c13565b60008781526020902090915085908201541115611c9d57809150611cab565b611ca881600161242d565b92505b50611c6a565b600082118015611ccf575083611ccc866114e2600186612440565b54145b15611ce857611cdf600183612440565b92505050610583565b509050610583565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115611d275750600090506003611dab565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015611d7b573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116611da457600060019250925050611dab565b9150600090505b94509492505050565b6000816004811115611dc857611dc86124a1565b03611dd05750565b6001816004811115611de457611de46124a1565b03611e315760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e61747572650000000000000000604482015260640161062b565b6002816004811115611e4557611e456124a1565b03611e925760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e67746800604482015260640161062b565b6003816004811115611ea657611ea66124a1565b0361067d5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b606482015260840161062b565b6000611f08611c46565b905080611f1484612137565b1015610f42578254600180820185556000858152602080822090930193909355938401805494850181558252902090910155565b600080608083901c15611f5d57608092831c92015b604083901c15611f6f57604092831c92015b602083901c15611f8157602092831c92015b601083901c15611f9357601092831c92015b600883901c15611fa557600892831c92015b600483901c15611fb757600492831c92015b600283901c15611fc957600292831c92015b600183901c156105835760010192915050565b6000818310611feb5781610656565b5090919050565b6001600160a01b0382166120525760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f206164647265736044820152607360f81b606482015260840161062b565b61205e82600083611998565b6001600160a01b038216600090815260208190526040902054818110156120d25760405162461bcd60e51b815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e604482015261636560f01b606482015260840161062b565b6001600160a01b0383166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610f42836000846119a3565b8054600090810361214a57506000919050565b8154829061215a90600190612440565b8154811061216a5761216a612453565b90600052602060002001549050919050565b600060208083528351808285015260005b818110156121a95785810183015185820160400152820161218d565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b03811681146107c457600080fd5b600080604083850312156121f457600080fd5b6121fd836121ca565b946020939093013593505050565b60008060006060848603121561222057600080fd5b612229846121ca565b9250612237602085016121ca565b9150604084013590509250925092565b60006020828403121561225957600080fd5b5035919050565b60006020828403121561227257600080fd5b610656826121ca565b60006020828403121561228d57600080fd5b8135801515811461065657600080fd5b803560ff811681146107c457600080fd5b60008060008060008060c087890312156122c757600080fd5b6122d0876121ca565b955060208701359450604087013593506122ec6060880161229d565b92506080870135915060a087013590509295509295509295565b600080600080600080600060e0888a03121561232157600080fd5b61232a886121ca565b9650612338602089016121ca565b955060408801359450606088013593506123546080890161229d565b925060a0880135915060c0880135905092959891949750929550565b6000806040838503121561238357600080fd5b61238c836121ca565b915061239a602084016121ca565b90509250929050565b600080604083850312156123b657600080fd5b6123bf836121ca565b9150602083013563ffffffff811681146123d857600080fd5b809150509250929050565b600181811c908216806123f757607f821691505b60208210810361183e57634e487b7160e01b600052602260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b8082018082111561058357610583612417565b8181038181111561058357610583612417565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601260045260246000fd5b60008261249c57634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052602160045260246000fdfea26469706673582212208fad81548748733711af70c24426285f54224918444fc048d98318e5dc7127ec64736f6c63430008120033
Deployed Bytecode Sourcemap
122127:1359:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;87123:100;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;89474:201;;;;;;:::i;:::-;;:::i;:::-;;;1169:14:1;;1162:22;1144:41;;1132:2;1117:18;89474:201:0;1004:187:1;88243:108:0;88331:12;;88243:108;;;1342:25:1;;;1330:2;1315:18;88243:108:0;1196:177:1;90255:295:0;;;;;;:::i;:::-;;:::i;88085:93::-;;;88168:2;1853:36:1;;1841:2;1826:18;88085:93:0;1711:184:1;101183:115:0;;;:::i;90959:238::-;;;;;;:::i;:::-;;:::i;104438:268::-;;;;;;:::i;:::-;;:::i;122447:95::-;;;;;;:::i;:::-;;:::i;:::-;;121475:91;;;;;;:::i;:::-;;:::i;116944:266::-;;;;;;:::i;:::-;;:::i;103812:128::-;;;;;;:::i;:::-;-1:-1:-1;;;;;103913:19:0;;;103886:7;103913:19;;;:10;:19;;;;;;;;103812:128;;;;-1:-1:-1;;;;;2622:32:1;;;2604:51;;2592:2;2577:18;103812:128:0;2458:203:1;107324:114:0;;;;;;:::i;:::-;;:::i;103568:151::-;;;;;;:::i;:::-;;:::i;:::-;;;2840:10:1;2828:23;;;2810:42;;2798:2;2783:18;103568:151:0;2666:192:1;88414:127:0;;;;;;:::i;:::-;-1:-1:-1;;;;;88515:18:0;88488:7;88515:18;;;;;;;;;;;;88414:127;80389:103;;;:::i;121885:164::-;;;;;;:::i;:::-;;:::i;100925:128::-;;;;;;:::i;:::-;;:::i;79741:87::-;79814:6;;-1:-1:-1;;;;;79814:6:0;79741:87;;104995:259;;;;;;:::i;:::-;;:::i;123210:104::-;;;;;;:::i;:::-;;:::i;87342:::-;;;:::i;122372:67::-;;;:::i;117314:234::-;;;;;;:::i;:::-;;:::i;104024:212::-;;;;;;:::i;:::-;;:::i;91700:436::-;;;;;;:::i;:::-;;:::i;88747:193::-;;;;;;:::i;:::-;;:::i;107520:591::-;;;;;;:::i;:::-;;:::i;100214:645::-;;;;;;:::i;:::-;;:::i;122826:21::-;;;;;;;;;89003:151;;;;;;:::i;:::-;;:::i;103338:150::-;;;;;;:::i;:::-;;:::i;:::-;;;;5293:13:1;;5308:10;5289:30;5271:49;;5380:4;5368:17;;;5362:24;-1:-1:-1;;;;;5358:50:1;5336:20;;;5329:80;;;;5244:18;103338:150:0;5069:346:1;80647:201:0;;;;;;:::i;:::-;;:::i;87123:100::-;87177:13;87210:5;87203:12;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;87123:100;:::o;89474:201::-;89557:4;78319:10;89613:32;78319:10;89629:7;89638:6;89613:8;:32::i;:::-;89663:4;89656:11;;;89474:201;;;;;:::o;90255:295::-;90386:4;78319:10;90444:38;90460:4;78319:10;90475:6;90444:15;:38::i;:::-;90493:27;90503:4;90509:2;90513:6;90493:9;:27::i;:::-;-1:-1:-1;90538:4:0;;90255:295;-1:-1:-1;;;;90255:295:0:o;101183:115::-;101243:7;101270:20;:18;:20::i;:::-;101263:27;;101183:115;:::o;90959:238::-;91047:4;78319:10;91103:64;78319:10;91119:7;91156:10;91128:25;78319:10;91119:7;91128:9;:25::i;:::-;:38;;;;:::i;:::-;91103:8;:64::i;104438:268::-;104536:7;104578:12;104564:11;:26;104556:70;;;;-1:-1:-1;;;104556:70:0;;6269:2:1;104556:70:0;;;6251:21:1;6308:2;6288:18;;;6281:30;6347:33;6327:18;;;6320:61;6398:18;;104556:70:0;;;;;;;;;-1:-1:-1;;;;;104663:21:0;;;;;;:12;:21;;;;;104644:54;;104686:11;104644:18;:54::i;:::-;104637:61;104438:268;-1:-1:-1;;;104438:268:0:o;122447:95::-;79627:13;:11;:13::i;:::-;122517:17:::1;122523:2;122527:6;122517:5;:17::i;:::-;122447:95:::0;;:::o;121475:91::-;121531:27;78319:10;121551:6;121531:5;:27::i;:::-;121475:91;:::o;116944:266::-;-1:-1:-1;;;;;117108:33:0;;117031:7;117108:33;;;:24;:33;;;;;117031:7;;;;117087:55;;117096:10;;117087:8;:55::i;:::-;117051:91;;;;117162:11;:40;;-1:-1:-1;;;;;88515:18:0;;88488:7;88515:18;;;;;;;;;;;117162:40;;;117176:5;117162:40;117155:47;116944:266;-1:-1:-1;;;;;116944:266:0:o;107324:114::-;107396:34;78319:10;107420:9;107396;:34::i;103568:151::-;-1:-1:-1;;;;;103682:21:0;;103638:6;103682:21;;;:12;:21;;;;;:28;103664:47;;:17;:47::i;80389:103::-;79627:13;:11;:13::i;:::-;80454:30:::1;80481:1;80454:18;:30::i;:::-;80389:103::o:0;121885:164::-;121962:46;121978:7;78319:10;122001:6;121962:15;:46::i;:::-;122019:22;122025:7;122034:6;122019:5;:22::i;100925:128::-;-1:-1:-1;;;;;101021:14:0;;100994:7;101021:14;;;:7;:14;;;;;41984;101021:24;41892:114;104995:259;105082:7;105124:12;105110:11;:26;105102:70;;;;-1:-1:-1;;;105102:70:0;;6269:2:1;105102:70:0;;;6251:21:1;6308:2;6288:18;;;6281:30;6347:33;6327:18;;;6320:61;6398:18;;105102:70:0;6067:355:1;105102:70:0;105190:56;105209:23;105234:11;105190:18;:56::i;123210:104::-;123260:4;79627:13;:11;:13::i;:::-;-1:-1:-1;123276:2:0::1;:8:::0;;-1:-1:-1;;123276:8:0::1;::::0;::::1;;;::::0;;-1:-1:-1;79651:1:0::1;123210:104:::0;;;:::o;87342:::-;87398:13;87431:7;87424:14;;;;;:::i;122372:67::-;79627:13;:11;:13::i;:::-;122420:11:::1;:9;:11::i;117314:234::-:0;117386:7;117407:16;117425:13;117442:43;117451:10;117463:21;117442:8;:43::i;:::-;117406:79;;;;117505:11;:35;;88331:12;;117505:35;;;117519:5;117505:35;117498:42;117314:234;-1:-1:-1;;;;117314:234:0:o;104024:212::-;-1:-1:-1;;;;;104131:21:0;;104097:7;104131:21;;;:12;:21;;;;;:28;104177:8;;:51;;-1:-1:-1;;;;;104192:21:0;;;;;;:12;:21;;;;;104214:7;104220:1;104214:3;:7;:::i;:::-;104192:30;;;;;;;;:::i;:::-;;;;;;;;;;:36;;;;-1:-1:-1;;;;;104192:36:0;104177:51;;;104188:1;104177:51;-1:-1:-1;;;;;104170:58:0;;104024:212;-1:-1:-1;;;104024:212:0:o;91700:436::-;91793:4;78319:10;91793:4;91876:25;78319:10;91893:7;91876:9;:25::i;:::-;91849:52;;91940:15;91920:16;:35;;91912:85;;;;-1:-1:-1;;;91912:85:0;;6894:2:1;91912:85:0;;;6876:21:1;6933:2;6913:18;;;6906:30;6972:34;6952:18;;;6945:62;-1:-1:-1;;;7023:18:1;;;7016:35;7068:19;;91912:85:0;6692:401:1;91912:85:0;92033:60;92042:5;92049:7;92077:15;92058:16;:34;92033:8;:60::i;88747:193::-;88826:4;78319:10;88882:28;78319:10;88899:2;88903:6;88882:9;:28::i;107520:591::-;107747:6;107728:15;:25;;107720:67;;;;-1:-1:-1;;;107720:67:0;;7300:2:1;107720:67:0;;;7282:21:1;7339:2;7319:18;;;7312:30;7378:31;7358:18;;;7351:59;7427:18;;107720:67:0;7098:353:1;107720:67:0;107870:58;;;103018:71;107870:58;;;7687:25:1;-1:-1:-1;;;;;7748:32:1;;7728:18;;;7721:60;;;;7797:18;;;7790:34;;;7840:18;;;7833:34;;;107798:14:0;;107815:174;;107843:87;;7659:19:1;;107870:58:0;;;;;;;;;;;;107860:69;;;;;;107843:16;:87::i;:::-;107945:1;107961;107977;107815:13;:174::i;:::-;107798:191;;108017:17;108027:6;108017:9;:17::i;:::-;108008:5;:26;108000:64;;;;-1:-1:-1;;;108000:64:0;;8080:2:1;108000:64:0;;;8062:21:1;8119:2;8099:18;;;8092:30;8158:27;8138:18;;;8131:55;8203:18;;108000:64:0;7878:349:1;108000:64:0;108075:28;108085:6;108093:9;108075;:28::i;:::-;107709:402;107520:591;;;;;;:::o;100214:645::-;100458:8;100439:15;:27;;100431:69;;;;-1:-1:-1;;;100431:69:0;;8434:2:1;100431:69:0;;;8416:21:1;8473:2;8453:18;;;8446:30;8512:31;8492:18;;;8485:59;8561:18;;100431:69:0;8232:353:1;100431:69:0;100513:18;99389:95;100573:5;100580:7;100589:5;100596:16;100606:5;100596:9;:16::i;:::-;100544:79;;;;;;8877:25:1;;;;-1:-1:-1;;;;;8976:15:1;;;8956:18;;;8949:43;9028:15;;;;9008:18;;;9001:43;9060:18;;;9053:34;9103:19;;;9096:35;9147:19;;;9140:35;;;8849:19;;100544:79:0;;;;;;;;;;;;100534:90;;;;;;100513:111;;100637:12;100652:28;100669:10;100652:16;:28::i;:::-;100637:43;;100693:14;100710:28;100724:4;100730:1;100733;100736;100710:13;:28::i;:::-;100693:45;;100767:5;-1:-1:-1;;;;;100757:15:0;:6;-1:-1:-1;;;;;100757:15:0;;100749:58;;;;-1:-1:-1;;;100749:58:0;;9388:2:1;100749:58:0;;;9370:21:1;9427:2;9407:18;;;9400:30;9466:32;9446:18;;;9439:60;9516:18;;100749:58:0;9186:354:1;100749:58:0;100820:31;100829:5;100836:7;100845:5;100820:8;:31::i;:::-;100420:439;;;100214:645;;;;;;;:::o;89003:151::-;-1:-1:-1;;;;;89119:18:0;;;89092:7;89119:18;;;:11;:18;;;;;;;;:27;;;;;;;;;;;;;89003:151::o;103338:150::-;-1:-1:-1;;;;;;;;;;;;;;;;;;;;;;103454:21:0;;;;;;:12;:21;;;;;:26;;;;;;;;;;;;:::i;:::-;;;;;;;;;;103447:33;;;;;;;;;103454:26;;103447:33;;;;;;;;;-1:-1:-1;;;;;103447:33:0;;;;;;;;;103338:150;-1:-1:-1;;;103338:150:0:o;80647:201::-;79627:13;:11;:13::i;:::-;-1:-1:-1;;;;;80736:22:0;::::1;80728:73;;;::::0;-1:-1:-1;;;80728:73:0;;9747:2:1;80728:73:0::1;::::0;::::1;9729:21:1::0;9786:2;9766:18;;;9759:30;9825:34;9805:18;;;9798:62;-1:-1:-1;;;9876:18:1;;;9869:36;9922:19;;80728:73:0::1;9545:402:1::0;80728:73:0::1;80812:28;80831:8;80812:18;:28::i;108417:290::-:0;108502:28;108514:7;108523:6;108502:11;:28::i;:::-;88331:12;;-1:-1:-1;;;;;;108549:29:0;108541:90;;;;-1:-1:-1;;;108541:90:0;;10154:2:1;108541:90:0;;;10136:21:1;10193:2;10173:18;;;10166:30;10232:34;10212:18;;;10205:62;-1:-1:-1;;;10283:18:1;;;10276:46;10339:19;;108541:90:0;9952:412:1;108541:90:0;108644:55;108661:23;108686:4;108692:6;108644:16;:55::i;:::-;;;108417:290;;:::o;93733:548::-;-1:-1:-1;;;;;93817:21:0;;93809:65;;;;-1:-1:-1;;;93809:65:0;;10571:2:1;93809:65:0;;;10553:21:1;10610:2;10590:18;;;10583:30;10649:33;10629:18;;;10622:61;10700:18;;93809:65:0;10369:355:1;93809:65:0;93887:49;93916:1;93920:7;93929:6;93887:20;:49::i;:::-;93965:6;93949:12;;:22;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;;;94120:18:0;;:9;:18;;;;;;;;;;;:28;;;;;;94175:37;1342:25:1;;;94175:37:0;;1315:18:1;94175:37:0;;;;;;;94225:48;94253:1;94257:7;94266:6;94225:19;:48::i;111370:98::-;111428:7;111455:5;111459:1;111455;:5;:::i;3038:195::-;3095:7;-1:-1:-1;;;;;3123:26:0;;;3115:78;;;;-1:-1:-1;;;3115:78:0;;10931:2:1;3115:78:0;;;10913:21:1;10970:2;10950:18;;;10943:30;11009:34;10989:18;;;10982:62;-1:-1:-1;;;11060:18:1;;;11053:37;11107:19;;3115:78:0;10729:403:1;3115:78:0;-1:-1:-1;3219:5:0;3038:195::o;15874:190::-;15930:6;15966:16;15957:25;;;15949:76;;;;-1:-1:-1;;;15949:76:0;;11339:2:1;15949:76:0;;;11321:21:1;11378:2;11358:18;;;11351:30;11417:34;11397:18;;;11390:62;-1:-1:-1;;;11468:18:1;;;11461:36;11514:19;;15949:76:0;11137:402:1;117765:622:0;-1:-1:-1;;;;;117969:18:0;;117965:415;;118025:26;118048:2;118025:22;:26::i;:::-;118066:28;:26;:28::i;:::-;117765:622;;;:::o;117965:415::-;-1:-1:-1;;;;;118116:16:0;;118112:268;;118170:28;118193:4;118170:22;:28::i;118112:268::-;118299:28;118322:4;118299:22;:28::i;:::-;118342:26;118365:2;118342:22;:26::i;109142:262::-;-1:-1:-1;;;;;103913:19:0;;;103886:7;103913:19;;;:10;:19;;;;;;;;;;;;;;;109340:56;;103913:19;;;;;109389:6;109340:16;:56::i;111476:103::-;111539:7;111566:5;111570:1;111566;:5;:::i;41892:114::-;41984:14;;41892:114::o;95727:380::-;-1:-1:-1;;;;;95863:19:0;;95855:68;;;;-1:-1:-1;;;95855:68:0;;11746:2:1;95855:68:0;;;11728:21:1;11785:2;11765:18;;;11758:30;11824:34;11804:18;;;11797:62;-1:-1:-1;;;11875:18:1;;;11868:34;11919:19;;95855:68:0;11544:400:1;95855:68:0;-1:-1:-1;;;;;95942:21:0;;95934:68;;;;-1:-1:-1;;;95934:68:0;;12151:2:1;95934:68:0;;;12133:21:1;12190:2;12170:18;;;12163:30;12229:34;12209:18;;;12202:62;-1:-1:-1;;;12280:18:1;;;12273:32;12322:19;;95934:68:0;11949:398:1;95934:68:0;-1:-1:-1;;;;;96015:18:0;;;;;;;:11;:18;;;;;;;;:27;;;;;;;;;;;;;:36;;;96067:32;;1342:25:1;;;96067:32:0;;1315:18:1;96067:32:0;;;;;;;95727:380;;;:::o;96398:453::-;96533:24;96560:25;96570:5;96577:7;96560:9;:25::i;:::-;96533:52;;-1:-1:-1;;96600:16:0;:37;96596:248;;96682:6;96662:16;:26;;96654:68;;;;-1:-1:-1;;;96654:68:0;;12554:2:1;96654:68:0;;;12536:21:1;12593:2;12573:18;;;12566:30;12632:31;12612:18;;;12605:59;12681:18;;96654:68:0;12352:353:1;96654:68:0;96766:51;96775:5;96782:7;96810:6;96791:16;:25;96766:8;:51::i;92606:840::-;-1:-1:-1;;;;;92737:18:0;;92729:68;;;;-1:-1:-1;;;92729:68:0;;12912:2:1;92729:68:0;;;12894:21:1;12951:2;12931:18;;;12924:30;12990:34;12970:18;;;12963:62;-1:-1:-1;;;13041:18:1;;;13034:35;13086:19;;92729:68:0;12710:401:1;92729:68:0;-1:-1:-1;;;;;92816:16:0;;92808:64;;;;-1:-1:-1;;;92808:64:0;;13318:2:1;92808:64:0;;;13300:21:1;13357:2;13337:18;;;13330:30;13396:34;13376:18;;;13369:62;-1:-1:-1;;;13447:18:1;;;13440:33;13490:19;;92808:64:0;13116:399:1;92808:64:0;92885:38;92906:4;92912:2;92916:6;92885:20;:38::i;:::-;-1:-1:-1;;;;;92958:15:0;;92936:19;92958:15;;;;;;;;;;;92992:21;;;;92984:72;;;;-1:-1:-1;;;92984:72:0;;13722:2:1;92984:72:0;;;13704:21:1;13761:2;13741:18;;;13734:30;13800:34;13780:18;;;13773:62;-1:-1:-1;;;13851:18:1;;;13844:36;13897:19;;92984:72:0;13520:402:1;92984:72:0;-1:-1:-1;;;;;93092:15:0;;;:9;:15;;;;;;;;;;;93110:20;;;93092:38;;93310:13;;;;;;;;;;:23;;;;;;93362:26;;1342:25:1;;;93310:13:0;;93362:26;;1315:18:1;93362:26:0;;;;;;;93401:37;93421:4;93427:2;93431:6;93401:19;:37::i;69890:314::-;69943:7;69975:4;-1:-1:-1;;;;;69984:12:0;69967:29;;:66;;;;;70017:16;70000:13;:33;69967:66;69963:234;;;-1:-1:-1;70057:24:0;;69890:314::o;69963:234::-;-1:-1:-1;70393:73:0;;;70143:10;70393:73;;;;15509:25:1;;;;70155:12:0;15550:18:1;;;15543:34;70169:15:0;15593:18:1;;;15586:34;70437:13:0;15636:18:1;;;15629:34;70460:4:0;15679:19:1;;;;15672:61;;;;70393:73:0;;;;;;;;;;15481:19:1;;;;70393:73:0;;;70383:84;;;;;;101183:115::o;105343:1895::-;106560:12;;105442:7;;;106560:12;106658:1;106649:10;;106645:251;;;106676:11;106699:17;106709:6;106699:9;:17::i;:::-;106690:26;;:6;:26;:::i;:::-;111673:25;111735:21;;;111802:4;111789:18;;106676:40;;-1:-1:-1;106773:11:0;;111785:28;;106735:35;;;:49;106731:154;;;106812:3;106805:10;;106731:154;;;106862:7;:3;106868:1;106862:7;:::i;:::-;106856:13;;106731:154;106661:235;106645:251;106921:4;106915:3;:10;106908:251;;;106942:11;106956:23;106969:3;106974:4;106956:12;:23::i;:::-;111673:25;111735:21;;;111802:4;111789:18;;106942:37;;-1:-1:-1;107036:11:0;;111785:28;;106998:35;;;:49;106994:154;;;107075:3;107068:10;;106994:154;;;107125:7;:3;107131:1;107125:7;:::i;:::-;107119:13;;106994:154;106927:232;106908:251;;;107178:9;;:52;;107194:30;107208:5;107215:8;107222:1;107215:4;:8;:::i;:::-;111673:25;111735:21;;;111802:4;111789:18;;;111785:28;;111587:244;107194:30;:36;;;;-1:-1:-1;;;;;107194:36:0;107178:52;;;107190:1;107178:52;-1:-1:-1;;;;;107171:59:0;;105343:1895;-1:-1:-1;;;;;;105343:1895:0:o;79906:132::-;79814:6;;-1:-1:-1;;;;;79814:6:0;78319:10;79970:23;79962:68;;;;-1:-1:-1;;;79962:68:0;;14129:2:1;79962:68:0;;;14111:21:1;;;14148:18;;;14141:30;14207:34;14187:18;;;14180:62;14259:18;;79962:68:0;13927:356:1;123057:145:0;123171:23;123183:2;123187:6;123171:11;:23::i;123322:155::-;123441:28;123453:7;123462:6;123441:11;:28::i;118395:1619::-;118484:4;118490:7;118531:1;118518:10;:14;118510:49;;;;-1:-1:-1;;;118510:49:0;;14490:2:1;118510:49:0;;;14472:21:1;14529:2;14509:18;;;14502:30;-1:-1:-1;;;14548:18:1;;;14541:52;14610:18;;118510:49:0;14288:346:1;118510:49:0;118592:23;:21;:23::i;:::-;118578:10;:37;;118570:79;;;;-1:-1:-1;;;118570:79:0;;14841:2:1;118570:79:0;;;14823:21:1;14880:2;14860:18;;;14853:30;14919:31;14899:18;;;14892:59;14968:18;;118570:79:0;14639:353:1;118570:79:0;119788:13;119804:40;:9;119833:10;119804:28;:40::i;:::-;119870:20;;119788:56;;-1:-1:-1;119861:29:0;;119857:150;;119915:5;119922:1;119907:17;;;;;;;119857:150;119965:4;119971:9;:16;;119988:5;119971:23;;;;;;;;:::i;:::-;;;;;;;;;119957:38;;;;;118395:1619;;;;;;:::o;109582:388::-;-1:-1:-1;;;;;103913:19:0;;;109667:23;103913:19;;;:10;:19;;;;;;;;;;88515:18;;;;;;;109782:21;;;;:33;;;-1:-1:-1;;;;;;109782:33:0;;;;;;;109833:54;;103913:19;;;;;88515:18;;109782:33;;103913:19;;;109833:54;;109667:23;109833:54;109900:62;109917:15;109934:9;109945:16;109900;:62::i;81008:191::-;81101:6;;;-1:-1:-1;;;;;81118:17:0;;;-1:-1:-1;;;;;;81118:17:0;;;;;;;81151:40;;81101:6;;;81118:17;81101:6;;81151:40;;81082:16;;81151:40;81071:128;81008:191;:::o;116416:223::-;116463:7;116483:30;:18;42103:19;;42121:1;42103:19;;;42014:127;116483:30;116526:17;116546:23;:21;:23::i;:::-;116526:43;;116585:19;116594:9;116585:19;;;;1342:25:1;;1330:2;1315:18;;1196:177;116585:19:0;;;;;;;;116622:9;116416:223;-1:-1:-1;116416:223:0:o;71117:167::-;71194:7;71221:55;71243:20;:18;:20::i;:::-;71265:10;66531:57;;-1:-1:-1;;;66531:57:0;;;16356:27:1;16399:11;;;16392:27;;;16435:12;;;16428:28;;;66494:7:0;;16472:12:1;;66531:57:0;;;;;;;;;;;;66521:68;;;;;;66514:75;;66401:196;;;;;64710:279;64838:7;64859:17;64878:18;64900:25;64911:4;64917:1;64920;64923;64900:10;:25::i;:::-;64858:67;;;;64936:18;64948:5;64936:11;:18::i;:::-;-1:-1:-1;64972:9:0;64710:279;-1:-1:-1;;;;;64710:279:0:o;101436:207::-;-1:-1:-1;;;;;101557:14:0;;101496:15;101557:14;;;:7;:14;;;;;41984;;42121:1;42103:19;;;;41984:14;101618:17;101513:130;101436:207;;;:::o;110629:733::-;110866:12;;110803:17;;;;;110919:8;;:59;;110949:29;110963:5;110970:7;110976:1;110970:3;:7;:::i;110949:29::-;110919:59;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;110919:59:0;;;;;;;;110930:16;;;;;;;;;-1:-1:-1;110930:16:0;;;;;;;110919:59;110891:87;;111003:7;:13;;;-1:-1:-1;;;;;110991:25:0;;;111039:20;111042:9;111053:5;111039:2;:20;;:::i;:::-;111027:32;;111082:1;111076:3;:7;:44;;;;-1:-1:-1;111087:17:0;;:33;;111108:12;111087:33;111076:44;111072:283;;;111175:29;111194:9;111175:18;:29::i;:::-;111137;111151:5;111158:7;111164:1;111158:3;:7;:::i;111137:29::-;:67;;-1:-1:-1;;;;;111137:67:0;;;;;;;;;;;;;;;;111072:283;;;111237:5;111248:94;;;;;;;;111271:31;111289:12;111271:17;:31::i;:::-;111248:94;;;;;;111311:29;111330:9;111311:18;:29::i;:::-;-1:-1:-1;;;;;111248:94:0;;;;;;111237:106;;;;;;;-1:-1:-1;111237:106:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;111072:283;110841:521;;110629:733;;;;;;:::o;122620:198::-;122766:44;122793:4;122799:2;122803:6;122766:26;:44::i;122856:193::-;122998:43;123024:4;123030:2;123034:6;122998:25;:43::i;120022:146::-;-1:-1:-1;;;;;120106:33:0;;;;;;:24;:33;;;;;;;;88515:18;;;;;;;;120090:70;;120106:33;120090:15;:70::i;120141:18::-;120090:15;:70::i;120176:118::-;120233:53;120249:21;120272:13;88331:12;;;88243:108;109978:643;110110:3;-1:-1:-1;;;;;110103:10:0;:3;-1:-1:-1;;;;;110103:10:0;;;:24;;;;;110126:1;110117:6;:10;110103:24;110099:515;;;-1:-1:-1;;;;;110148:17:0;;;110144:224;;-1:-1:-1;;;;;110244:17:0;;110187;110244;;;:12;:17;;;;;110187;;110227:54;;110263:9;110274:6;110227:16;:54::i;:::-;110186:95;;;;110326:3;-1:-1:-1;;;;;110305:47:0;;110331:9;110342;110305:47;;;;;;15171:25:1;;;15227:2;15212:18;;15205:34;15159:2;15144:18;;14997:248;110305:47:0;;;;;;;;110167:201;;110144:224;-1:-1:-1;;;;;110388:17:0;;;110384:219;;-1:-1:-1;;;;;110484:17:0;;110427;110484;;;:12;:17;;;;;110427;;110467:49;;110503:4;110509:6;110467:16;:49::i;:::-;110426:90;;;;110561:3;-1:-1:-1;;;;;110540:47:0;;110566:9;110577;110540:47;;;;;;15171:25:1;;;15227:2;15212:18;;15205:34;15159:2;15144:18;;14997:248;110540:47:0;;;;;;;;110407:196;;109978:643;;;:::o;49000:1673::-;49048:7;49072:1;49077;49072:6;49068:47;;-1:-1:-1;49102:1:0;;49000:1673;-1:-1:-1;49000:1673:0:o;49068:47::-;49806:14;49840:1;49829:7;49834:1;49829:4;:7::i;:::-;:12;;49823:1;:19;;49806:36;;50308:1;50297:6;50293:1;:10;;;;;:::i;:::-;;50284:6;:19;50283:26;;50274:35;;50358:1;50347:6;50343:1;:10;;;;;:::i;:::-;;50334:6;:19;50333:26;;50324:35;;50408:1;50397:6;50393:1;:10;;;;;:::i;:::-;;50384:6;:19;50383:26;;50374:35;;50458:1;50447:6;50443:1;:10;;;;;:::i;:::-;;50434:6;:19;50433:26;;50424:35;;50508:1;50497:6;50493:1;:10;;;;;:::i;:::-;;50484:6;:19;50483:26;;50474:35;;50558:1;50547:6;50543:1;:10;;;;;:::i;:::-;;50534:6;:19;50533:26;;50524:35;;50608:1;50597:6;50593:1;:10;;;;;:::i;:::-;;50584:6;:19;50583:26;;50574:35;;50631:23;50635:6;50647;50643:1;:10;;;;;:::i;:::-;;50631:3;:23::i;43401:156::-;43463:7;43538:11;43548:1;43539:5;;;43538:11;:::i;:::-;43528:21;;43529:5;;;43528:21;:::i;108801:194::-;108886:28;108898:7;108907:6;108886:11;:28::i;:::-;108927:60;108944:23;108969:9;108980:6;108927:16;:60::i;116705:127::-;116769:7;116796:28;:18;41984:14;;41892:114;74889:958;75002:12;;74978:7;;75002:17;;74998:58;;-1:-1:-1;75043:1:0;75036:8;;74998:58;75109:12;;75068:11;;75134:444;75147:4;75141:3;:10;75134:444;;;75168:11;75182:23;75195:3;75200:4;75182:12;:23::i;:::-;77239:31;77374:19;;;77432:4;77419:18;;75168:37;;-1:-1:-1;75459:7:0;;77415:28;;75426:30;:40;75422:145;;;75494:3;75487:10;;75422:145;;;75544:7;:3;75550:1;75544:7;:::i;:::-;75538:13;;75422:145;75153:425;75134:444;;;75704:1;75698:3;:7;:56;;;;-1:-1:-1;75747:7:0;75709:28;75722:5;75729:7;75735:1;75729:3;:7;:::i;75709:28::-;:34;:45;75698:56;75694:146;;;75778:7;75784:1;75778:3;:7;:::i;:::-;75771:14;;;;;;75694:146;-1:-1:-1;75825:3:0;-1:-1:-1;75818:10:0;;63051:1520;63182:7;;64116:66;64103:79;;64099:163;;;-1:-1:-1;64215:1:0;;-1:-1:-1;64219:30:0;64199:51;;64099:163;64376:24;;;64359:14;64376:24;;;;;;;;;16722:25:1;;;16795:4;16783:17;;16763:18;;;16756:45;;;;16817:18;;;16810:34;;;16860:18;;;16853:34;;;64376:24:0;;16694:19:1;;64376:24:0;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;64376:24:0;;-1:-1:-1;;64376:24:0;;;-1:-1:-1;;;;;;;64415:20:0;;64411:103;;64468:1;64472:29;64452:50;;;;;;;64411:103;64534:6;-1:-1:-1;64542:20:0;;-1:-1:-1;63051:1520:0;;;;;;;;:::o;58443:521::-;58521:20;58512:5;:29;;;;;;;;:::i;:::-;;58508:449;;58443:521;:::o;58508:449::-;58619:29;58610:5;:38;;;;;;;;:::i;:::-;;58606:351;;58665:34;;-1:-1:-1;;;58665:34:0;;17232:2:1;58665:34:0;;;17214:21:1;17271:2;17251:18;;;17244:30;17310:26;17290:18;;;17283:54;17354:18;;58665:34:0;17030:348:1;58606:351:0;58730:35;58721:5;:44;;;;;;;;:::i;:::-;;58717:240;;58782:41;;-1:-1:-1;;;58782:41:0;;17585:2:1;58782:41:0;;;17567:21:1;17624:2;17604:18;;;17597:30;17663:33;17643:18;;;17636:61;17714:18;;58782:41:0;17383:355:1;58717:240:0;58854:30;58845:5;:39;;;;;;;;:::i;:::-;;58841:116;;58901:44;;-1:-1:-1;;;58901:44:0;;17945:2:1;58901:44:0;;;17927:21:1;17984:2;17964:18;;;17957:30;18023:34;18003:18;;;17996:62;-1:-1:-1;;;18074:18:1;;;18067:32;18116:19;;58901:44:0;17743:398:1;120302:310:0;120397:17;120417:23;:21;:23::i;:::-;120397:43;-1:-1:-1;120397:43:0;120455:30;120471:9;120455:15;:30::i;:::-;:42;120451:154;;;120514:29;;;;;;;;-1:-1:-1;120514:29:0;;;;;;;;;;;;;;120558:16;;;:35;;;;;;;;;;;;;;;120302:310::o;51150:1019::-;51202:7;;51289:3;51280:12;;;:16;51276:102;;51327:3;51317:13;;;;51349;51276:102;51405:2;51396:11;;;:15;51392:99;;51442:2;51432:12;;;;51463;51392:99;51518:2;51509:11;;;:15;51505:99;;51555:2;51545:12;;;;51576;51505:99;51631:2;51622:11;;;:15;51618:99;;51668:2;51658:12;;;;51689;51618:99;51744:1;51735:10;;;:14;51731:96;;51780:1;51770:11;;;;51800;51731:96;51854:1;51845:10;;;:14;51841:96;;51890:1;51880:11;;;;51910;51841:96;51964:1;51955:10;;;:14;51951:96;;52000:1;51990:11;;;;52020;51951:96;52074:1;52065:10;;;:14;52061:66;;52110:1;52100:11;52155:6;51150:1019;-1:-1:-1;;51150:1019:0:o;43176:106::-;43234:7;43265:1;43261;:5;:13;;43273:1;43261:13;;;-1:-1:-1;43269:1:0;;43176:106;-1:-1:-1;43176:106:0:o;94614:675::-;-1:-1:-1;;;;;94698:21:0;;94690:67;;;;-1:-1:-1;;;94690:67:0;;18348:2:1;94690:67:0;;;18330:21:1;18387:2;18367:18;;;18360:30;18426:34;18406:18;;;18399:62;-1:-1:-1;;;18477:18:1;;;18470:31;18518:19;;94690:67:0;18146:397:1;94690:67:0;94770:49;94791:7;94808:1;94812:6;94770:20;:49::i;:::-;-1:-1:-1;;;;;94857:18:0;;94832:22;94857:18;;;;;;;;;;;94894:24;;;;94886:71;;;;-1:-1:-1;;;94886:71:0;;18750:2:1;94886:71:0;;;18732:21:1;18789:2;18769:18;;;18762:30;18828:34;18808:18;;;18801:62;-1:-1:-1;;;18879:18:1;;;18872:32;18921:19;;94886:71:0;18548:398:1;94886:71:0;-1:-1:-1;;;;;94993:18:0;;:9;:18;;;;;;;;;;;95014:23;;;94993:44;;95132:12;:22;;;;;;;95183:37;1342:25:1;;;94993:9:0;;:18;95183:37;;1315:18:1;95183:37:0;;;;;;;95233:48;95253:7;95270:1;95274:6;95233:19;:48::i;120620:212::-;120714:10;;120690:7;;120714:15;;120710:115;;-1:-1:-1;120753:1:0;;120620:212;-1:-1:-1;120620:212:0:o;120710:115::-;120798:10;;120794:3;;120798:14;;120811:1;;120798:14;:::i;:::-;120794:19;;;;;;;;:::i;:::-;;;;;;;;;120787:26;;120620:212;;;:::o;14:548:1:-;126:4;155:2;184;173:9;166:21;216:6;210:13;259:6;254:2;243:9;239:18;232:34;284:1;294:140;308:6;305:1;302:13;294:140;;;403:14;;;399:23;;393:30;369:17;;;388:2;365:26;358:66;323:10;;294:140;;;298:3;483:1;478:2;469:6;458:9;454:22;450:31;443:42;553:2;546;542:7;537:2;529:6;525:15;521:29;510:9;506:45;502:54;494:62;;;;14:548;;;;:::o;567:173::-;635:20;;-1:-1:-1;;;;;684:31:1;;674:42;;664:70;;730:1;727;720:12;745:254;813:6;821;874:2;862:9;853:7;849:23;845:32;842:52;;;890:1;887;880:12;842:52;913:29;932:9;913:29;:::i;:::-;903:39;989:2;974:18;;;;961:32;;-1:-1:-1;;;745:254:1:o;1378:328::-;1455:6;1463;1471;1524:2;1512:9;1503:7;1499:23;1495:32;1492:52;;;1540:1;1537;1530:12;1492:52;1563:29;1582:9;1563:29;:::i;:::-;1553:39;;1611:38;1645:2;1634:9;1630:18;1611:38;:::i;:::-;1601:48;;1696:2;1685:9;1681:18;1668:32;1658:42;;1378:328;;;;;:::o;2082:180::-;2141:6;2194:2;2182:9;2173:7;2169:23;2165:32;2162:52;;;2210:1;2207;2200:12;2162:52;-1:-1:-1;2233:23:1;;2082:180;-1:-1:-1;2082:180:1:o;2267:186::-;2326:6;2379:2;2367:9;2358:7;2354:23;2350:32;2347:52;;;2395:1;2392;2385:12;2347:52;2418:29;2437:9;2418:29;:::i;2863:273::-;2919:6;2972:2;2960:9;2951:7;2947:23;2943:32;2940:52;;;2988:1;2985;2978:12;2940:52;3027:9;3014:23;3080:5;3073:13;3066:21;3059:5;3056:32;3046:60;;3102:1;3099;3092:12;3141:156;3207:20;;3267:4;3256:16;;3246:27;;3236:55;;3287:1;3284;3277:12;3302:531;3404:6;3412;3420;3428;3436;3444;3497:3;3485:9;3476:7;3472:23;3468:33;3465:53;;;3514:1;3511;3504:12;3465:53;3537:29;3556:9;3537:29;:::i;:::-;3527:39;;3613:2;3602:9;3598:18;3585:32;3575:42;;3664:2;3653:9;3649:18;3636:32;3626:42;;3687:36;3719:2;3708:9;3704:18;3687:36;:::i;:::-;3677:46;;3770:3;3759:9;3755:19;3742:33;3732:43;;3822:3;3811:9;3807:19;3794:33;3784:43;;3302:531;;;;;;;;:::o;3838:606::-;3949:6;3957;3965;3973;3981;3989;3997;4050:3;4038:9;4029:7;4025:23;4021:33;4018:53;;;4067:1;4064;4057:12;4018:53;4090:29;4109:9;4090:29;:::i;:::-;4080:39;;4138:38;4172:2;4161:9;4157:18;4138:38;:::i;:::-;4128:48;;4223:2;4212:9;4208:18;4195:32;4185:42;;4274:2;4263:9;4259:18;4246:32;4236:42;;4297:37;4329:3;4318:9;4314:19;4297:37;:::i;:::-;4287:47;;4381:3;4370:9;4366:19;4353:33;4343:43;;4433:3;4422:9;4418:19;4405:33;4395:43;;3838:606;;;;;;;;;;:::o;4449:260::-;4517:6;4525;4578:2;4566:9;4557:7;4553:23;4549:32;4546:52;;;4594:1;4591;4584:12;4546:52;4617:29;4636:9;4617:29;:::i;:::-;4607:39;;4665:38;4699:2;4688:9;4684:18;4665:38;:::i;:::-;4655:48;;4449:260;;;;;:::o;4714:350::-;4781:6;4789;4842:2;4830:9;4821:7;4817:23;4813:32;4810:52;;;4858:1;4855;4848:12;4810:52;4881:29;4900:9;4881:29;:::i;:::-;4871:39;;4960:2;4949:9;4945:18;4932:32;5004:10;4997:5;4993:22;4986:5;4983:33;4973:61;;5030:1;5027;5020:12;4973:61;5053:5;5043:15;;;4714:350;;;;;:::o;5420:380::-;5499:1;5495:12;;;;5542;;;5563:61;;5617:4;5609:6;5605:17;5595:27;;5563:61;5670:2;5662:6;5659:14;5639:18;5636:38;5633:161;;5716:10;5711:3;5707:20;5704:1;5697:31;5751:4;5748:1;5741:15;5779:4;5776:1;5769:15;5805:127;5866:10;5861:3;5857:20;5854:1;5847:31;5897:4;5894:1;5887:15;5921:4;5918:1;5911:15;5937:125;6002:9;;;6023:10;;;6020:36;;;6036:18;;:::i;6427:128::-;6494:9;;;6515:11;;;6512:37;;;6529:18;;:::i;6560:127::-;6621:10;6616:3;6612:20;6609:1;6602:31;6652:4;6649:1;6642:15;6676:4;6673:1;6666:15;15744:127;15805:10;15800:3;15796:20;15793:1;15786:31;15836:4;15833:1;15826:15;15860:4;15857:1;15850:15;15876:217;15916:1;15942;15932:132;;15986:10;15981:3;15977:20;15974:1;15967:31;16021:4;16018:1;16011:15;16049:4;16046:1;16039:15;15932:132;-1:-1:-1;16078:9:1;;15876:217::o;16898:127::-;16959:10;16954:3;16950:20;16947:1;16940:31;16990:4;16987:1;16980:15;17014:4;17011:1;17004:15
Swarm Source
ipfs://8fad81548748733711af70c24426285f54224918444fc048d98318e5dc7127ec
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.