ETH Price: $3,156.82 (+4.46%)
Gas: 10 Gwei

Contract

0x7ad4C1647aA947D1c05425a8d4d155eF811a5f9E
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

Transaction Hash
Method
Block
From
To
Value
0xe50d09f63c1b532d9b46f78df9ce0c6621846da9bf4d4738a510a53a97b2744cF Claim Token(pending)2024-04-14 22:40:215 mins ago1713134421IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x9dbd18945c995cb7603e0076d22a4e012b7b96eb5874985b642556b3a7ee4182F Claim Token(pending)2024-04-14 21:57:2348 mins ago1713131843IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xf4fcc800db66e403b813db1730b25549e39a379dbb91ec5dad2839f54facf83aF Claim Token(pending)2024-04-14 21:24:151 hr ago1713129855IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x3caf478b6ae5e1f020e21e67acd04dd8a4d2037b184e24fad5e8e1c721ce4516F Claim Token(pending)2024-04-14 20:30:312 hrs ago1713126631IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xb95e142491445c794b652d7b13bfc1331c9f1730925f36cd309e941e549701b2F Claim Token(pending)2024-04-14 20:10:552 hrs ago1713125455IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x2f1db54224cdecaf9df40d827345d5c761481c0350f7500932b3fd009640a9d0F Claim Token(pending)2024-04-13 9:41:2937 hrs ago1713001289IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xa1abe4bb5be81220cef2ea47c9f8ce94f018172bbfde898a8798c5a331f891cfF Claim Token(pending)2024-04-11 7:41:563 days ago1712821316IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x7cd59aacc8a6bd98f1a377ffd9d0706232df99a3e2df0858a723496d1f6891dcF Claim Token(pending)2024-04-11 7:12:343 days ago1712819554IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x199f2aed39b191ac5b40e961231e9f976773410f07b1a9415972b6c1130226d5F Claim Token(pending)2024-04-07 21:38:437 days ago1712525923IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xa6ed4ec70823fd13fcf583717e991be3f2d82ad1bb0a5837e3be82b1c39ccf68F Claim Token(pending)2024-04-07 21:15:317 days ago1712524531IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xf3aad7e8ab5fe4b3b0507fca281d0e1ce0f63add8b6ff1eb8acc034262250600F Claim Token(pending)2024-04-07 8:51:177 days ago1712479877IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xabff83aa82c22fdcf9cc7b66779adad41f247041583ebb31132ae1ae456d9039F Claim Token(pending)2024-04-07 7:49:047 days ago1712476144IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x5f26543694903dcd7bb7590d21c487b88c960c9ae34d27bc2b086c3308ca6911F Claim Token(pending)2024-04-07 7:14:547 days ago1712474094IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x205ff1b40d2e0dc6fefca2e825b5dcc5b995f7b8b672f0ba4abb34e6dffa4a95F Claim Token(pending)2024-04-07 4:25:417 days ago1712463941IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x2b70d7a8569c38d0611f331597e3df853d0994ea6dd1fef0ee1afc3954e8e1f3F Claim Token(pending)2024-04-07 4:18:087 days ago1712463488IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x6fb6c2ce6b8984447a28f51ecfef8420edef45bd18a61af000755d59643be33cF Claim Token(pending)2024-04-07 4:06:277 days ago1712462787IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xb79bcc3f65d9da0267b555e1922fb6cd332f907d3415d78fdd418dd2fc7d5ca0F Claim Token(pending)2024-04-07 2:05:587 days ago1712455558IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xc720eb9cd43aa49d740b22ed75a9f41e2d5874aff1fcda3991b183104537e3bfF Claim Token(pending)2024-04-07 2:04:247 days ago1712455464IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x556ce17a224fc87b30b6bf4817c88b74c0dbf06aab045673c3c370214279582aF Claim Token(pending)2024-04-07 1:56:167 days ago1712454976IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x2f87618aa233d36cb33d5b38abd5e9759d995b334a57b792a067ffd4ada10226F Claim Token(pending)2024-04-07 1:56:167 days ago1712454976IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xe209346c74c6cde5bbabc9d72f5de2b3b323208a42eb16e063849831d59c4475F Claim Token(pending)2024-04-07 1:52:337 days ago1712454753IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xa1d95b31e7ac4c458142569b387a38c7ff51c6ab6b6928ac30643fa8cc2266bfF Claim Token(pending)2024-04-07 1:52:337 days ago1712454753IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0xd48f33179a3b1408503b09467db5d091a01e2c32023d860257a876013be35d57F Claim Token(pending)2024-03-31 2:56:0814 days ago1711853768IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x5b8c2dd9de4ce95f66bac39a227bd1cdb6d9b9b9c9a89edefd2cf12e6b22fb06F Claim Token(pending)2024-03-31 2:47:5314 days ago1711853273IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
0x27ae2b726eac23f0f0e046897904caa5096d2574ce37dd6eb6750efbd6008281F Claim Token(pending)2024-03-31 2:10:2614 days ago1711851026IN
Heroes of Mavia: Airdrop
0 ETH(Pending)(Pending)
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Similar Match Source Code
This contract matches the deployed Bytecode of the Source Code for Contract 0x1A01b00B...8EE982379
The constructor portion of the code might be different and could alter the actual behaviour of the contract

Contract Name:
MaviaTokenAirdropFlat

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 200 runs

Other Settings:
istanbul EvmVersion
File 1 of 13 : MaviaTokenAirdropFlat.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.4;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts/access/AccessControl.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol";
import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";

contract MaviaTokenAirdropFlat is AccessControl, ReentrancyGuard, EIP712 {
  using SafeERC20 for IERC20;

  bytes32 internal constant _EDITOR_ROLE = keccak256("_EDITOR_ROLE");
  bytes32 internal constant _EMERGENCY_ROLE = keccak256("_EMERGENCY_ROLE");
  bytes32 internal constant _VALIDATOR_ROLE = keccak256("_VALIDATOR_ROLE");

  /// Blacklist map
  mapping(address => bool) public blacklistSenders;
  /// App nonces
  mapping(uint => bool) public appNonces;
  /// Validating window time
  uint256 public receiveWindow;

  /// Token address
  address public token;
  /// Token rewards
  uint256 public rewards;

  // Pause flag
  bool public isPaused;

  event ECollectTokens(address sender, address token, uint256 amount);
  event ESafeWithdrawRewards(address sender, uint256 amount);
  event EEmerWithdrawRewards(address sender, uint256 amount);
  event EClaimToken(address sender, uint256 amount, uint256 appNonce);

  constructor(address _pToken, string memory _pVersion) EIP712("MaviaTokenAirdrop", _pVersion) {
    address sender_ = _msgSender();
    _setupRole(DEFAULT_ADMIN_ROLE, sender_);
    _setupRole(_EDITOR_ROLE, sender_);

    token = _pToken;
    receiveWindow = 15 minutes;
  }

  /**
   * @dev Emergency withdraw rewards
   */
  function fEmerWithdraw(uint256 _pAmount) external onlyRole(_EMERGENCY_ROLE) {
    IERC20(token).safeTransfer(_msgSender(), _pAmount);
    emit EEmerWithdrawRewards(_msgSender(), _pAmount);
  }

  /**
   * @dev Safety withdraw rewards
   */
  function fCollectRewards(uint256 _pAmount) external onlyRole(_EMERGENCY_ROLE) {
    require(rewards >= _pAmount, "MTA:swr000");
    rewards -= _pAmount;
    IERC20(token).safeTransfer(_msgSender(), _pAmount);
    emit ESafeWithdrawRewards(_msgSender(), _pAmount);
  }

  /**
   * @dev Correct Token
   */
  function fCorrectToken(address _pToken) external onlyRole(_EDITOR_ROLE) {
    require(rewards == 0, "MTA:crt000");
    token = _pToken;
  }

  /**
   * @dev Correct rewards
   */
  function fCorrectRewards(uint256 _pRewards) external onlyRole(_EDITOR_ROLE) {
    rewards = _pRewards;
  }

  /**
   * @dev Deposit rewards
   */
  function fDepositRewards(uint256 _pAmount) external onlyRole(_EDITOR_ROLE) {
    IERC20(token).safeTransferFrom(_msgSender(), address(this), _pAmount);
    rewards += _pAmount;
  }

  /**
   * @dev Set pause flag
   */
  function fSetPause(bool _pIsPaused) external onlyRole(_EDITOR_ROLE) {
    isPaused = _pIsPaused;
  }

  /**
   * @dev Set receive window
   * @param _pReceiveWindow window to update
   */
  function fSetReceiveWindow(uint256 _pReceiveWindow) external onlyRole(_EDITOR_ROLE) {
    receiveWindow = _pReceiveWindow;
  }

  /**
   * @dev Set blacklist to the contract
   * @param _pAddress Address to set blacklist
   */
  function fSetBlacklist(address _pAddress, bool _pStatus) external onlyRole(_EDITOR_ROLE) {
    blacklistSenders[_pAddress] = _pStatus;
  }

  /**
   * @dev Set app nonces
   */
  function fSetAppNonces(uint256[] calldata _appNonces, bool _pStatus) external onlyRole(_EDITOR_ROLE) {
    for (uint256 i = 0; i < _appNonces.length; i++) {
      appNonces[_appNonces[i]] = _pStatus;
    }
  }

  /**
   * @dev Distribute Token
   */
  function fClaimToken(
    uint256 _pAmount,
    uint256 _pAppNonce,
    uint256 _pSigTime,
    bytes calldata _pSignature
  ) external nonReentrant {
    address sender_ = msg.sender;
    require(!isPaused, "MTA:clt000");
    require(rewards > 0, "MTA:clt001");
    require(_pAmount > 0, "MTA:clt002");
    require(!blacklistSenders[sender_], "MTA:clt003");
    require(!appNonces[_pAppNonce], "MTA:clt004");
    appNonces[_pAppNonce] = true;

    // Verify signature
    require(block.timestamp <= _pSigTime + receiveWindow, "MTA:clt010");
    require(_fVerify(_fHash(sender_, token, _pAmount, _pAppNonce, _pSigTime), _pSignature), "MTA:clt011");

    // Transfer token
    rewards -= _pAmount;
    IERC20(token).safeTransfer(sender_, _pAmount);

    emit EClaimToken(sender_, _pAmount, _pAppNonce);
  }

  /**
   * @dev Calculate hash
   */
  function _fHash(
    address _pSender,
    address _pToken,
    uint256 _pAmount,
    uint256 _pAppNonce,
    uint256 _pSigTime
  ) private view returns (bytes32) {
    return
      _hashTypedDataV4(
        keccak256(
          abi.encode(
            keccak256(
              "MaviaTokenAirdrop(address _pSender,address _pToken,uint256 _pAmount,uint256 _pAppNonce,uint256 _pSigTime)"
            ),
            _pSender,
            _pToken,
            _pAmount,
            _pAppNonce,
            _pSigTime
          )
        )
      );
  }

  /**
   * @dev Verify signature
   * @param _pDigest Bytes32 digest
   * @param _pSignature Bytes signature
   */
  function _fVerify(bytes32 _pDigest, bytes memory _pSignature) private view returns (bool) {
    return hasRole(_VALIDATOR_ROLE, ECDSA.recover(_pDigest, _pSignature));
  }
}

File 3 of 13 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 4 of 13 : ERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

File 5 of 13 : draft-EIP712.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ECDSA.sol";

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

    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);
        _TYPE_HASH = typeHash;
    }

    /**
     * @dev Returns the domain separator for the current chain.
     */
    function _domainSeparatorV4() internal view returns (bytes32) {
        if (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 6 of 13 : ECDSA.sol
// SPDX-License-Identifier: MIT

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
    }

    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");
        } else if (error == RecoverError.InvalidSignatureV) {
            revert("ECDSA: invalid signature 'v' 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) {
        // Check the signature length
        // - case 65: r,s,v signature (standard)
        // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._
        if (signature.length == 65) {
            bytes32 r;
            bytes32 s;
            uint8 v;
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use 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 if (signature.length == 64) {
            bytes32 r;
            bytes32 vs;
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            assembly {
                r := mload(add(signature, 0x20))
                vs := mload(add(signature, 0x40))
            }
            return tryRecover(hash, r, vs);
        } 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;
        uint8 v;
        assembly {
            s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff)
            v := add(shr(255, vs), 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 (v != 27 && v != 28) {
            return (address(0), RecoverError.InvalidSignatureV);
        }

        // 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 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 7 of 13 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

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

File 8 of 13 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

File 9 of 13 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 10 of 13 : SafeERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

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

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

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

File 11 of 13 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

File 12 of 13 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
abstract contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and make it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        // On the first call to nonReentrant, _notEntered will be true
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;

        _;

        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}

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

pragma solidity ^0.8.0;

/**
 * @dev External interface of AccessControl declared to support ERC165 detection.
 */
interface IAccessControl {
    /**
     * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
     *
     * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
     * {RoleAdminChanged} not being emitted signaling this.
     *
     * _Available since v3.1._
     */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);

    /**
     * @dev Emitted when `account` is granted `role`.
     *
     * `sender` is the account that originated the contract call, an admin role
     * bearer except when using {AccessControl-_setupRole}.
     */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Emitted when `account` is revoked `role`.
     *
     * `sender` is the account that originated the contract call:
     *   - if using `revokeRole`, it is the admin role bearer
     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)
     */
    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) external view returns (bool);

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {AccessControl-_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) external view returns (bytes32);

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) external;
}

File 14 of 13 : AccessControl.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";

/**
 * @dev Contract module that allows children to implement role-based access
 * control mechanisms. This is a lightweight version that doesn't allow enumerating role
 * members except through off-chain means by accessing the contract event logs. Some
 * applications may benefit from on-chain enumerability, for those cases see
 * {AccessControlEnumerable}.
 *
 * Roles are referred to by their `bytes32` identifier. These should be exposed
 * in the external API and be unique. The best way to achieve this is by
 * using `public constant` hash digests:
 *
 * ```
 * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
 * ```
 *
 * Roles can be used to represent a set of permissions. To restrict access to a
 * function call, use {hasRole}:
 *
 * ```
 * function foo() public {
 *     require(hasRole(MY_ROLE, msg.sender));
 *     ...
 * }
 * ```
 *
 * Roles can be granted and revoked dynamically via the {grantRole} and
 * {revokeRole} functions. Each role has an associated admin role, and only
 * accounts that have a role's admin role can call {grantRole} and {revokeRole}.
 *
 * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
 * that only accounts with this role will be able to grant or revoke other
 * roles. More complex role relationships can be created by using
 * {_setRoleAdmin}.
 *
 * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
 * grant and revoke this role. Extra precautions should be taken to secure
 * accounts that have been granted it.
 */
abstract contract AccessControl is Context, IAccessControl, ERC165 {
    struct RoleData {
        mapping(address => bool) members;
        bytes32 adminRole;
    }

    mapping(bytes32 => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @dev Modifier that checks that an account has a specific role. Reverts
     * with a standardized message including the required role.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     *
     * _Available since v4.1._
     */
    modifier onlyRole(bytes32 role) {
        _checkRole(role, _msgSender());
        _;
    }

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

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) public view override returns (bool) {
        return _roles[role].members[account];
    }

    /**
     * @dev Revert with a standard message if `account` is missing `role`.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     */
    function _checkRole(bytes32 role, address account) internal view {
        if (!hasRole(role, account)) {
            revert(
                string(
                    abi.encodePacked(
                        "AccessControl: account ",
                        Strings.toHexString(uint160(account), 20),
                        " is missing role ",
                        Strings.toHexString(uint256(role), 32)
                    )
                )
            );
        }
    }

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) public view override returns (bytes32) {
        return _roles[role].adminRole;
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _grantRole(role, account);
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _revokeRole(role, account);
    }

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) public virtual override {
        require(account == _msgSender(), "AccessControl: can only renounce roles for self");

        _revokeRole(role, account);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event. Note that unlike {grantRole}, this function doesn't perform any
     * checks on the calling account.
     *
     * [WARNING]
     * ====
     * This function should only be called from the constructor when setting
     * up the initial roles for the system.
     *
     * Using this function in any other way is effectively circumventing the admin
     * system imposed by {AccessControl}.
     * ====
     */
    function _setupRole(bytes32 role, address account) internal virtual {
        _grantRole(role, account);
    }

    /**
     * @dev Sets `adminRole` as ``role``'s admin role.
     *
     * Emits a {RoleAdminChanged} event.
     */
    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
        bytes32 previousAdminRole = getRoleAdmin(role);
        _roles[role].adminRole = adminRole;
        emit RoleAdminChanged(role, previousAdminRole, adminRole);
    }

    function _grantRole(bytes32 role, address account) private {
        if (!hasRole(role, account)) {
            _roles[role].members[account] = true;
            emit RoleGranted(role, account, _msgSender());
        }
    }

    function _revokeRole(bytes32 role, address account) private {
        if (hasRole(role, account)) {
            _roles[role].members[account] = false;
            emit RoleRevoked(role, account, _msgSender());
        }
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_pToken","type":"address"},{"internalType":"string","name":"_pVersion","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"appNonce","type":"uint256"}],"name":"EClaimToken","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ECollectTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EEmerWithdrawRewards","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"sender","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ESafeWithdrawRewards","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"appNonces","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"blacklistSenders","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pAmount","type":"uint256"},{"internalType":"uint256","name":"_pAppNonce","type":"uint256"},{"internalType":"uint256","name":"_pSigTime","type":"uint256"},{"internalType":"bytes","name":"_pSignature","type":"bytes"}],"name":"fClaimToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pAmount","type":"uint256"}],"name":"fCollectRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pRewards","type":"uint256"}],"name":"fCorrectRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_pToken","type":"address"}],"name":"fCorrectToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pAmount","type":"uint256"}],"name":"fDepositRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pAmount","type":"uint256"}],"name":"fEmerWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_appNonces","type":"uint256[]"},{"internalType":"bool","name":"_pStatus","type":"bool"}],"name":"fSetAppNonces","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_pAddress","type":"address"},{"internalType":"bool","name":"_pStatus","type":"bool"}],"name":"fSetBlacklist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_pIsPaused","type":"bool"}],"name":"fSetPause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pReceiveWindow","type":"uint256"}],"name":"fSetReceiveWindow","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"receiveWindow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061014d5760003560e01c80636851fdf1116100c3578063add0ca681161007c578063add0ca68146102cb578063b11fe7b6146102de578063b187bd26146102f1578063d547741f146102fe578063ddb3a2fb14610311578063fc0c546a1461032457600080fd5b80636851fdf11461025e57806391d148541461027157806393183cf9146102845780639ec5a89414610297578063a217fddf146102a0578063ad547783146102a857600080fd5b806336568abe1161011557806336568abe146101e65780634166a72d146101f9578063497de6621461020c5780635caaf7f41461021f578063661ab74214610228578063672bca101461024b57600080fd5b806301ffc9a714610152578063126f044b1461017a578063248a9ca31461018f5780632aa8f25f146101c05780632f2ff15d146101d3575b600080fd5b61016561016036600461182b565b61034f565b60405190151581526020015b60405180910390f35b61018d6101883660046117e8565b610386565b005b6101b261019d3660046117e8565b60009081526020819052604090206001015490565b604051908152602001610171565b61018d6101ce36600461172f565b6103a5565b61018d6101e1366004611800565b610434565b61018d6101f4366004611800565b61045f565b61018d6102073660046117e8565b6104e2565b61018d61021a366004611853565b610501565b6101b260045481565b6101656102363660046116df565b60026020526000908152604090205460ff1681565b61018d6102593660046117e8565b610832565b61018d61026c3660046116df565b6108bd565b61016561027f366004611800565b610936565b61018d6102923660046117e8565b61095f565b6101b260065481565b6101b2600081565b6101656102b63660046117e8565b60036020526000908152604090205460ff1681565b61018d6102d93660046116f9565b6109ab565b61018d6102ec3660046117b0565b6109f0565b6007546101659060ff1681565b61018d61030c366004611800565b610a1d565b61018d61031f3660046117e8565b610a43565b600554610337906001600160a01b031681565b6040516001600160a01b039091168152602001610171565b60006001600160e01b03198216637965db0b60e01b148061038057506301ffc9a760e01b6001600160e01b03198316145b92915050565b600080516020611a7083398151915261039f8133610af5565b50600655565b600080516020611a708339815191526103be8133610af5565b60005b8381101561042d5782600360008787858181106103ee57634e487b7160e01b600052603260045260246000fd5b90506020020135815260200190815260200160002060006101000a81548160ff021916908315150217905550808061042590611a30565b9150506103c1565b5050505050565b6000828152602081905260409020600101546104508133610af5565b61045a8383610b59565b505050565b6001600160a01b03811633146104d45760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b60648201526084015b60405180910390fd5b6104de8282610bdd565b5050565b600080516020611a708339815191526104fb8133610af5565b50600455565b600260015414156105545760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104cb565b6002600155600754339060ff161561059b5760405162461bcd60e51b815260206004820152600a60248201526904d54413a636c743030360b41b60448201526064016104cb565b6000600654116105da5760405162461bcd60e51b815260206004820152600a6024820152694d54413a636c7430303160b01b60448201526064016104cb565b600086116106175760405162461bcd60e51b815260206004820152600a60248201526926aa209d31b63a18181960b11b60448201526064016104cb565b6001600160a01b03811660009081526002602052604090205460ff161561066d5760405162461bcd60e51b815260206004820152600a6024820152694d54413a636c7430303360b01b60448201526064016104cb565b60008581526003602052604090205460ff16156106b95760405162461bcd60e51b815260206004820152600a6024820152691355104e98db1d0c0c0d60b21b60448201526064016104cb565b6000858152600360205260409020805460ff191660011790556004546106df908561199f565b42111561071b5760405162461bcd60e51b815260206004820152600a60248201526904d54413a636c743031360b41b60448201526064016104cb565b600554610775906107399083906001600160a01b0316898989610c42565b84848080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610cca92505050565b6107ae5760405162461bcd60e51b815260206004820152600a6024820152694d54413a636c7430313160b01b60448201526064016104cb565b85600660008282546107c091906119d6565b90915550506005546107dc906001600160a01b03168288610d01565b604080516001600160a01b0383168152602081018890529081018690527f4fa1519c58aad04a56d5f0a4527371d480af55875b04c7ae11cd89728217c9e09060600160405180910390a150506001805550505050565b7fb5a0ffc9809f97c825e7243be790ff035be8fe1a72461bc6e6ee1ca67a1f0c5a61085d8133610af5565b610875335b6005546001600160a01b03169084610d01565b7f16b400fb80f86b507edb97b6f95967e3760e12d6601befcb77320d1086098c66335b604080516001600160a01b039092168252602082018590520160405180910390a15050565b600080516020611a708339815191526108d68133610af5565b600654156109135760405162461bcd60e51b815260206004820152600a60248201526904d54413a6372743030360b41b60448201526064016104cb565b50600580546001600160a01b0319166001600160a01b0392909216919091179055565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b600080516020611a708339815191526109788133610af5565b610990336005546001600160a01b0316903085610d64565b81600660008282546109a2919061199f565b90915550505050565b600080516020611a708339815191526109c48133610af5565b506001600160a01b03919091166000908152600260205260409020805460ff1916911515919091179055565b600080516020611a70833981519152610a098133610af5565b506007805460ff1916911515919091179055565b600082815260208190526040902060010154610a398133610af5565b61045a8383610bdd565b7fb5a0ffc9809f97c825e7243be790ff035be8fe1a72461bc6e6ee1ca67a1f0c5a610a6e8133610af5565b816006541015610aad5760405162461bcd60e51b815260206004820152600a60248201526904d54413a7377723030360b41b60448201526064016104cb565b8160066000828254610abf91906119d6565b90915550610ace905033610862565b7fd2ca0b1e08b3716c9d41e7e4a729ae63f9d46887f653d05ae89a57fe90d7691a33610898565b610aff8282610936565b6104de57610b17816001600160a01b03166014610da2565b610b22836020610da2565b604051602001610b339291906118f7565b60408051601f198184030181529082905262461bcd60e51b82526104cb9160040161196c565b610b638282610936565b6104de576000828152602081815260408083206001600160a01b03851684529091529020805460ff19166001179055610b993390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b610be78282610936565b156104de576000828152602081815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b604080517f16baebe6b6c7678c23586c59a5a6c4b2cfdfb722e5522a50a83bd126dc7d95f060208201526001600160a01b038088169282019290925290851660608201526080810184905260a0810183905260c08101829052600090610cc09060e00160405160208183030381529060405280519060200120610f84565b9695505050505050565b6000610cfa7fd35fc04be7da19dc8f49bf900481f4b91b2b496caa7fb33fb940c5521e9fe8a161027f8585610fd2565b9392505050565b6040516001600160a01b03831660248201526044810182905261045a90849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610ff6565b6040516001600160a01b0380851660248301528316604482015260648101829052610d9c9085906323b872dd60e01b90608401610d2d565b50505050565b60606000610db18360026119b7565b610dbc90600261199f565b67ffffffffffffffff811115610de257634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015610e0c576020820181803683370190505b509050600360fc1b81600081518110610e3557634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350600f60fb1b81600181518110610e7257634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a9053506000610e968460026119b7565b610ea190600161199f565b90505b6001811115610f35576f181899199a1a9b1b9c1cb0b131b232b360811b85600f1660108110610ee357634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110610f0757634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a90535060049490941c93610f2e81611a19565b9050610ea4565b508315610cfa5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e7460448201526064016104cb565b6000610380610f916110c8565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b6000806000610fe185856111bb565b91509150610fee8161122b565b509392505050565b600061104b826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661142f9092919063ffffffff16565b80519091501561045a578080602001905181019061106991906117cc565b61045a5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016104cb565b60007f000000000000000000000000000000000000000000000000000000000000000146141561111757507f9f5ed01fb9a6af7d8e97d6cd5239b9021bca60c6f0b7815cb6776c53bb7f0a8c90565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527fe453231f87ce5694711e5b571f9c431cbdd34c4cdf386fa392e348d5d48ee13a828401527fae209a0b48f21c054280f2455d32cf309387644879d9acbd8ffc19916381188560608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6000808251604114156111f25760208301516040840151606085015160001a6111e687828585611446565b94509450505050611224565b82516040141561121c5760208301516040840151611211868383611533565b935093505050611224565b506000905060025b9250929050565b600081600481111561124d57634e487b7160e01b600052602160045260246000fd5b14156112565750565b600181600481111561127857634e487b7160e01b600052602160045260246000fd5b14156112c65760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e6174757265000000000000000060448201526064016104cb565b60028160048111156112e857634e487b7160e01b600052602160045260246000fd5b14156113365760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e6774680060448201526064016104cb565b600381600481111561135857634e487b7160e01b600052602160045260246000fd5b14156113b15760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b60648201526084016104cb565b60048160048111156113d357634e487b7160e01b600052602160045260246000fd5b141561142c5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c604482015261756560f01b60648201526084016104cb565b50565b606061143e8484600085611562565b949350505050565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561147d575060009050600361152a565b8460ff16601b1415801561149557508460ff16601c14155b156114a6575060009050600461152a565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156114fa573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166115235760006001925092505061152a565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b0161155487828885611446565b935093505050935093915050565b6060824710156115c35760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016104cb565b843b6116115760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016104cb565b600080866001600160a01b0316858760405161162d91906118db565b60006040518083038185875af1925050503d806000811461166a576040519150601f19603f3d011682016040523d82523d6000602084013e61166f565b606091505b509150915061167f82828661168a565b979650505050505050565b60608315611699575081610cfa565b8251156116a95782518084602001fd5b8160405162461bcd60e51b81526004016104cb919061196c565b80356001600160a01b03811681146116da57600080fd5b919050565b6000602082840312156116f0578081fd5b610cfa826116c3565b6000806040838503121561170b578081fd5b611714836116c3565b9150602083013561172481611a61565b809150509250929050565b600080600060408486031215611743578081fd5b833567ffffffffffffffff8082111561175a578283fd5b818601915086601f83011261176d578283fd5b81358181111561177b578384fd5b8760208260051b850101111561178f578384fd5b602092830195509350508401356117a581611a61565b809150509250925092565b6000602082840312156117c1578081fd5b8135610cfa81611a61565b6000602082840312156117dd578081fd5b8151610cfa81611a61565b6000602082840312156117f9578081fd5b5035919050565b60008060408385031215611812578182fd5b82359150611822602084016116c3565b90509250929050565b60006020828403121561183c578081fd5b81356001600160e01b031981168114610cfa578182fd5b60008060008060006080868803121561186a578081fd5b853594506020860135935060408601359250606086013567ffffffffffffffff80821115611896578283fd5b818801915088601f8301126118a9578283fd5b8135818111156118b7578384fd5b8960208285010111156118c8578384fd5b9699959850939650602001949392505050565b600082516118ed8184602087016119ed565b9190910192915050565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161192f8160178501602088016119ed565b7001034b99036b4b9b9b4b733903937b6329607d1b60179184019182015283516119608160288401602088016119ed565b01602801949350505050565b602081526000825180602084015261198b8160408501602087016119ed565b601f01601f19169190910160400192915050565b600082198211156119b2576119b2611a4b565b500190565b60008160001904831182151516156119d1576119d1611a4b565b500290565b6000828210156119e8576119e8611a4b565b500390565b60005b83811015611a085781810151838201526020016119f0565b83811115610d9c5750506000910152565b600081611a2857611a28611a4b565b506000190190565b6000600019821415611a4457611a44611a4b565b5060010190565b634e487b7160e01b600052601160045260246000fd5b801515811461142c57600080fdfe7ec4788949f801629c6bee526c56143f9a63e64429ff2842602f06a52f01e50aa264697066735822122073f152d5c47e663306a45b973aa768cc0609b88f0e1fa0506e4ef0f5d862cc9864736f6c63430008040033

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

OVERVIEW

Heroes of Mavia Airdrop Season 1

Validator Index Block Amount
View All Withdrawals

Txn Hash Block Value Eth2 PubKey Valid
View All Deposits
[ Download: CSV Export  ]

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