Contract 0x05a4330b285d496d778d341a2846d7a66c4f4feb 1

Contract Overview

Balance:
0 BNB

Token:
Txn Hash Method
Block
From
To
Value [Txn Fee]
0xe70ce286626d1e862f5a2c3da91633a15046562c2690fdcb7ba2cdfc337d5238Transfer To Othe...106779362021-07-17 19:06:1767 days 7 hrs ago0x0a0a2f75d0830024cbce9673974d3b73902aa1a2 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117266
0xaeb14c17c40680c14ba400cb14c68bf861a483a2def1d912337b22894cce0ecaTransfer To User...106779092021-07-17 19:04:5667 days 7 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063436
0x3ed2e581af8f274fab3e44e65546cf77517b7a98b3aad54f45cbf5eb33b24f8bTransfer To User...100118672021-06-24 11:09:0190 days 15 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063304
0xe21731f5182e3e5c5bd69438345a99290490e0eba342f764215f6d2b01f26c19Transfer To User...99842052021-06-23 12:05:5591 days 14 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063656
0x2715bed2768336340f4e2b01551873612e069d50a4a7eb76441d000da0744353Transfer To Othe...99533312021-06-22 10:22:1392 days 16 hrs ago0x371e43bc62e05c748aab3e874cb0fa6acb015af7 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0xd9de64144ef4c6031d3b0c0e24c4bd5f3f85831ef06a846cfdf7fc887322ac0cTransfer To Othe...99533302021-06-22 10:22:1092 days 16 hrs ago0x371e43bc62e05c748aab3e874cb0fa6acb015af7 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0x44b8347cda0e43415989754aa04a1be4ce69e4c941ce902ea5c5e6bff97d1312Transfer To Othe...99533122021-06-22 10:21:1692 days 16 hrs ago0x371e43bc62e05c748aab3e874cb0fa6acb015af7 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0x64f2b09cb5d875eba0ac3d2426e525e9e9ba1610ef46a316aef59eda5212d377Transfer To User...99529002021-06-22 10:00:4092 days 16 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063656
0x667c5b19556debd2a68d842d1fbff6ccf39c51d33758d22e0872db1db814c3f3Transfer To User...99360152021-06-21 19:56:2593 days 6 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063656
0x2515783d4049699a4b565105ec4e89d6d41e64e8c89595d3de44428ddc6967e3Transfer To User...99275302021-06-21 12:52:1093 days 13 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001140491
0x6456a59e19b08b99ac649d4f8048af8a68343c356f496bc4e12bcce393ecd280Transfer To User...99274902021-06-21 12:50:1093 days 13 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063656
0xf80d6f3dc7b872f0aadd6c8abbd544a59a2f33d0540d3bbb4177ad50ee8d2233Transfer To User...99273082021-06-21 12:41:0493 days 14 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001063656
0x5dd3cd63e3696ff12785838a6b0d05ec37887d05899ddd0a23e9b316e5111317Transfer To User...99266852021-06-21 12:09:5593 days 14 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001229008
0x81e05b60bdd0d33348bac81839471bb3363f6ceb59ab876a63ee60d67da05e29Transfer To User...96433952021-06-11 16:05:10103 days 10 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001140051
0xeebcdfd099fbab2995f6f3612c3b27f8d81db1220145c21d4abfc9b2cd184247Transfer To Othe...96433742021-06-11 16:04:07103 days 10 hrs ago0x0a0a2f75d0830024cbce9673974d3b73902aa1a2 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0x043c0ef9294f4cffbec344be3d18dec424006300ca48cc07ad9e74e91268b339Transfer To Othe...96433732021-06-11 16:04:04103 days 10 hrs ago0x0a0a2f75d0830024cbce9673974d3b73902aa1a2 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0x060a52a4a4125ba17d28f3455c65d736cf1784aad30bf76d55f6cfc0edd4b9c3Transfer To Othe...96433732021-06-11 16:04:04103 days 10 hrs ago0x0a0a2f75d0830024cbce9673974d3b73902aa1a2 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00117242
0x36435173c18627003fae9056e2717fdaea80149060f189b369276acba23e86cdTransfer To User...96433552021-06-11 16:03:10103 days 10 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001140051
0xcd43e333a83a089e9da05c936dc729ec1603b18fa85cfac1ab0af7380f9eda3fTransfer To User...96433262021-06-11 16:01:43103 days 10 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.001228392
0xd1a1077474d912de2331cdf3bb184b540a845a4ae2fa08c0b5b8160490693960Transfer To Othe...96426322021-06-11 15:27:01103 days 11 hrs ago0x0a0a2f75d0830024cbce9673974d3b73902aa1a2 IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00087242
0x4ae1f44d78400cba04df8f8b0b069b13520ee3ec6d5f217970a8738e31c4e6caTransfer To User...96426002021-06-11 15:25:25103 days 11 hrs ago0x87a7cbf2a8e5dfd38a47b7b2eeee8122ce359c8e IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00139326
0xe700c57932ae761968b70f4165f4ca822510999ffa61b3d318c57d8a954c9c5dGrant Role96417372021-06-11 14:42:16103 days 12 hrs ago0xa2537026e1f1db218c4a4dc3d87a378e730cf19b IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00089159
0xbd75bdc930a195175b4ee7b649e4bb3125e29dbf67cfa6fc151829e3e4487801Grant Role96417352021-06-11 14:42:10103 days 12 hrs ago0xa2537026e1f1db218c4a4dc3d87a378e730cf19b IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00089159
0x1bfaccf5b86f0db535f8a979b75a560b16e3101f4080add7c5f4eca2c5e5eb55Renounce Role96417302021-06-11 14:41:55103 days 12 hrs ago0xa2537026e1f1db218c4a4dc3d87a378e730cf19b IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00022859
0x5b33e2580cd7032e4dc67ea33e6738de53d3b7f3e6c3670a1e0e72b15952fb15Grant Role96415272021-06-11 14:31:46103 days 12 hrs ago0xa2537026e1f1db218c4a4dc3d87a378e730cf19b IN  0x05a4330b285d496d778d341a2846d7a66c4f4feb0 BNB0.00148318
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0xe70ce286626d1e862f5a2c3da91633a15046562c2690fdcb7ba2cdfc337d5238106779362021-07-17 19:06:1767 days 7 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xe70ce286626d1e862f5a2c3da91633a15046562c2690fdcb7ba2cdfc337d5238106779362021-07-17 19:06:1767 days 7 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xaeb14c17c40680c14ba400cb14c68bf861a483a2def1d912337b22894cce0eca106779092021-07-17 19:04:5667 days 7 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xaeb14c17c40680c14ba400cb14c68bf861a483a2def1d912337b22894cce0eca106779092021-07-17 19:04:5667 days 7 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x3ed2e581af8f274fab3e44e65546cf77517b7a98b3aad54f45cbf5eb33b24f8b100118672021-06-24 11:09:0190 days 15 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x3ed2e581af8f274fab3e44e65546cf77517b7a98b3aad54f45cbf5eb33b24f8b100118672021-06-24 11:09:0190 days 15 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xe21731f5182e3e5c5bd69438345a99290490e0eba342f764215f6d2b01f26c1999842052021-06-23 12:05:5591 days 14 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xe21731f5182e3e5c5bd69438345a99290490e0eba342f764215f6d2b01f26c1999842052021-06-23 12:05:5591 days 14 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x2715bed2768336340f4e2b01551873612e069d50a4a7eb76441d000da074435399533312021-06-22 10:22:1392 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x2715bed2768336340f4e2b01551873612e069d50a4a7eb76441d000da074435399533312021-06-22 10:22:1392 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xd9de64144ef4c6031d3b0c0e24c4bd5f3f85831ef06a846cfdf7fc887322ac0c99533302021-06-22 10:22:1092 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xd9de64144ef4c6031d3b0c0e24c4bd5f3f85831ef06a846cfdf7fc887322ac0c99533302021-06-22 10:22:1092 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x44b8347cda0e43415989754aa04a1be4ce69e4c941ce902ea5c5e6bff97d131299533122021-06-22 10:21:1692 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x44b8347cda0e43415989754aa04a1be4ce69e4c941ce902ea5c5e6bff97d131299533122021-06-22 10:21:1692 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x64f2b09cb5d875eba0ac3d2426e525e9e9ba1610ef46a316aef59eda5212d37799529002021-06-22 10:00:4092 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x64f2b09cb5d875eba0ac3d2426e525e9e9ba1610ef46a316aef59eda5212d37799529002021-06-22 10:00:4092 days 16 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x667c5b19556debd2a68d842d1fbff6ccf39c51d33758d22e0872db1db814c3f399360152021-06-21 19:56:2593 days 6 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x667c5b19556debd2a68d842d1fbff6ccf39c51d33758d22e0872db1db814c3f399360152021-06-21 19:56:2593 days 6 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x2515783d4049699a4b565105ec4e89d6d41e64e8c89595d3de44428ddc6967e399275302021-06-21 12:52:1093 days 13 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x2515783d4049699a4b565105ec4e89d6d41e64e8c89595d3de44428ddc6967e399275302021-06-21 12:52:1093 days 13 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x6456a59e19b08b99ac649d4f8048af8a68343c356f496bc4e12bcce393ecd28099274902021-06-21 12:50:1093 days 13 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x6456a59e19b08b99ac649d4f8048af8a68343c356f496bc4e12bcce393ecd28099274902021-06-21 12:50:1093 days 13 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xf80d6f3dc7b872f0aadd6c8abbd544a59a2f33d0540d3bbb4177ad50ee8d223399273082021-06-21 12:41:0493 days 14 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0xf80d6f3dc7b872f0aadd6c8abbd544a59a2f33d0540d3bbb4177ad50ee8d223399273082021-06-21 12:41:0493 days 14 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
0x5dd3cd63e3696ff12785838a6b0d05ec37887d05899ddd0a23e9b316e511131799266852021-06-21 12:09:5593 days 14 hrs ago 0x05a4330b285d496d778d341a2846d7a66c4f4feb 0xfca6d1b139749c659f31840fe99516ba2277a6540 BNB
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
swapContract

Compiler Version
v0.7.6+commit.7338295f

Optimization Enabled:
Yes with 999999 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 9 : ECDSAOffsetRecovery.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.7.0;

contract ECDSAOffsetRecovery 
{
    function getHashPacked(address user, uint256 amountWithFee, bytes32 originalTxHash) public pure returns (bytes32)
    {
        return keccak256(abi.encodePacked(user, amountWithFee, originalTxHash));
    }

    function toEthSignedMessageHash(bytes32 hash) public 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));
    }

    function ecOffsetRecover(bytes32 hash, bytes memory signature, uint256 offset)
        public
        pure
        returns (address)
    {
        bytes32 r;
        bytes32 s;
        uint8 v;

        // Divide the signature in r, s and v variables with inline assembly.
        assembly {
            r := mload(add(signature, add(offset, 0x20)))
            s := mload(add(signature, add(offset, 0x40)))
            v := byte(0, mload(add(signature, add(offset, 0x60))))
        }

        // Version of signature should be 27 or 28, but 0 and 1 are also possible versions
        if (v < 27) {
            v += 27;
        }

        // If the version is correct return the signer address
        if (v != 27 && v != 28) {
            return (address(0));
        }

        // bytes memory prefix = "\x19Ethereum Signed Message:\n32";
        // hash = keccak256(abi.encodePacked(prefix, hash));
        // solium-disable-next-line arg-overflow
        return ecrecover(toEthSignedMessageHash(hash), v, r, s);
    }
}

File 2 of 9 : swapContract.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.7.0;

import "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol";
//import "openzeppelin-solidity/contracts/access/Ownable.sol";
import "openzeppelin-solidity/contracts/access/AccessControl.sol";
import "openzeppelin-solidity/contracts/math/SafeMath.sol";
import "openzeppelin-solidity/contracts/utils/Pausable.sol";
import "./ECDSAOffsetRecovery.sol";


/// @title Swap contract for multisignature bridge
contract swapContract is AccessControl, Pausable, ECDSAOffsetRecovery
{
    using SafeMath for uint256;

    bytes32 public constant OWNER_ROLE = keccak256("OWNER_ROLE");
    bytes32 public constant MANAGER_ROLE = keccak256("MANAGER_ROLE");
    bytes32 public constant RELAYER_ROLE = keccak256("RELAYER_ROLE");
    bytes32 public constant VALIDATOR_ROLE = keccak256("VALIDATOR_ROLE");

    IERC20 public tokenAddress;
    address public feeAddress;

    uint128 public numOfThisBlockchain;
    mapping(uint128 => bool) public existingOtherBlockchain;
    mapping(uint128 => uint128) public feeAmountOfBlockchain;

    uint256 public constant SIGNATURE_LENGTH = 65;
    mapping(bytes32 => bytes32) public processedTransactions;
    uint256 public minConfirmationSignatures;

    uint256 public minTokenAmount;
    uint256 public maxGasPrice;
    uint256 public minConfirmationBlocks;

    event TransferFromOtherBlockchain(address user, uint256 amount, uint256 amountWithoutFee, bytes32 originalTxHash);
    event TransferToOtherBlockchain(uint128 blockchain, address user, uint256 amount, string newAddress);
    

    /** 
      * @dev throws if transaction sender is not in owner role
      */
    modifier onlyOwner() {
        require(
            hasRole(OWNER_ROLE, _msgSender()),
            "Caller is not in owner role"
        );
        _;
    }

    /** 
      * @dev throws if transaction sender is not in owner or manager role
      */
    modifier onlyOwnerAndManager() {
        require(
            hasRole(OWNER_ROLE, _msgSender()) || hasRole(MANAGER_ROLE, _msgSender()),
            "Caller is not in owner or manager role"
        );
        _;
    }

    /** 
      * @dev throws if transaction sender is not in relayer role
      */
    modifier onlyRelayer() {
        require(
            hasRole(RELAYER_ROLE, _msgSender()),
            "swapContract: Caller is not in relayer role"
        );
        _;
    }

    /** 
      * @dev Constructor of contract
      * @param _tokenAddress address Address of token contract
      * @param _feeAddress Address to receive deducted fees
      * @param _numOfThisBlockchain Number of blockchain where contract is deployed
      * @param _numsOfOtherBlockchains List of blockchain number that is supported by bridge
      * @param _minConfirmationSignatures Number of required signatures for token swap
      * @param _minTokenAmount Minimal amount of tokens required for token swap
      * @param _maxGasPrice Maximum gas price on which relayer nodes will operate
      * @param _minConfirmationBlocks Minimal amount of blocks for confirmation on validator nodes
      */
    constructor(
        IERC20 _tokenAddress,
        address _feeAddress,
        uint128 _numOfThisBlockchain,
        uint128 [] memory _numsOfOtherBlockchains,
        uint128 _minConfirmationSignatures,
        uint256 _minTokenAmount,
        uint256 _maxGasPrice,
        uint256 _minConfirmationBlocks
    )
    {
        tokenAddress = _tokenAddress;
        feeAddress = _feeAddress;
        for (uint i = 0; i < _numsOfOtherBlockchains.length; i++ ) {
            require(
                _numsOfOtherBlockchains[i] != _numOfThisBlockchain,
                "swapContract: Number of this blockchain is in array of other blockchains"
            );
            existingOtherBlockchain[_numsOfOtherBlockchains[i]] = true;
        }

        require(_maxGasPrice > 0, "swapContract: Gas price cannot be zero");
        
        numOfThisBlockchain = _numOfThisBlockchain;
        minConfirmationSignatures = _minConfirmationSignatures;
        minTokenAmount = _minTokenAmount;
        maxGasPrice = _maxGasPrice;
        minConfirmationBlocks = _minConfirmationBlocks;
        _setupRole(DEFAULT_ADMIN_ROLE, _msgSender());
        _setupRole(OWNER_ROLE, _msgSender());
    }

    /** 
      * @dev Returns true if blockchain of passed id is registered to swap
      * @param blockchain number of blockchain
      */
    function getOtherBlockchainAvailableByNum(uint128 blockchain) external view returns (bool)
    {
        return existingOtherBlockchain[blockchain];
    }

    /** 
      * @dev Transfers tokens from sender to the contract. 
      * User calls this function when he wants to transfer tokens to another blockchain.
      * @param blockchain Number of blockchain
      * @param amount Amount of tokens
      * @param newAddress Address in the blockchain to which the user wants to transfer
      */
    function transferToOtherBlockchain(uint128 blockchain, uint256 amount, string memory newAddress) external whenNotPaused
    {
        require(
            bytes(newAddress).length > 0,
            "swapContract: No destination address provided"
        );
        require(
            existingOtherBlockchain[blockchain] && blockchain != numOfThisBlockchain,
            "swapContract: Wrong choose of blockchain"
        );
        require(
            amount >= feeAmountOfBlockchain[blockchain],
            "swapContract: Not enough amount of tokens"
        );
        address sender = _msgSender();
        require(
            tokenAddress.balanceOf(sender) >= amount,
            "swapContract: Not enough balance"
        );
        tokenAddress.transferFrom(sender, address(this), amount);
        emit TransferToOtherBlockchain(blockchain, sender, amount, newAddress);
    }
    /** 
      * @dev Transfers tokens to end user in current blockchain 
      * @param user User address
      * @param amountWithFee Amount of tokens with included fees
      * @param originalTxHash Hash of transaction from other network, on which swap was called
      * @param concatSignatures Concatenated string of signature bytes for verification of transaction
      */
    function transferToUserWithFee(
        address user,
        uint256 amountWithFee,
        bytes32 originalTxHash,
        bytes memory concatSignatures
    ) 
        external
        onlyRelayer
        whenNotPaused
    {
        require(
            amountWithFee >= minTokenAmount,
            "swapContract: Amount must be greater than minimum"
        );
        require(
            user != address(0),
            "swapContract: Address cannot be zero address"   // TODO: check this requirement
        );
        require(
            concatSignatures.length.mod(SIGNATURE_LENGTH) == 0,
            "swapContract: Signatures lengths must be divisible by 65"
        );
        require(
            concatSignatures.length.div(SIGNATURE_LENGTH) >= minConfirmationSignatures,
            "swapContract: Not enough signatures passed"
        );

        bytes32 hashedParams = getHashPacked(user, amountWithFee, originalTxHash);
        (bool processed, bytes32 savedHash) = isProcessedTransaction(originalTxHash);
        require(!processed && savedHash != hashedParams, "swapContract: Transaction already processed");
        
        uint256 signaturesCount = concatSignatures.length.div(uint256(SIGNATURE_LENGTH));
        address[] memory validatorAddresses = new address[](signaturesCount);
        for (uint256 i = 0; i < signaturesCount; i++) {
            address validatorAddress = ecOffsetRecover(hashedParams, concatSignatures, i * SIGNATURE_LENGTH);
            require(isValidator(validatorAddress), "swapContract: Validator address not in whitelist");
            for (uint256 j = 0; j < i; j++) {
                require(validatorAddress != validatorAddresses[j], "swapContract: Validator address is duplicated");
            }
            validatorAddresses[i] = validatorAddress;
        }
        processedTransactions[originalTxHash] = hashedParams;

        uint256 fee = feeAmountOfBlockchain[numOfThisBlockchain];
        uint256 amountWithoutFee = amountWithFee.sub(fee);
        tokenAddress.transfer(user, amountWithoutFee);
        tokenAddress.transfer(feeAddress, fee);
        emit TransferFromOtherBlockchain(user, amountWithFee, amountWithoutFee, originalTxHash);
    }

    // OTHER BLOCKCHAIN MANAGEMENT
    /** 
      * @dev Registers another blockchain for availability to swap
      * @param numOfOtherBlockchain number of blockchain
      */
    function addOtherBlockchain(
        uint128 numOfOtherBlockchain
    )
        external
        onlyOwner
    {
        require(
            numOfOtherBlockchain != numOfThisBlockchain,
            "swapContract: Cannot add this blockchain to array of other blockchains"
        );
        require(
            !existingOtherBlockchain[numOfOtherBlockchain],
            "swapContract: This blockchain is already added"
        );
        existingOtherBlockchain[numOfOtherBlockchain] = true;
    }

    /** 
      * @dev Unregisters another blockchain for availability to swap
      * @param numOfOtherBlockchain number of blockchain
      */
    function removeOtherBlockchain(
        uint128 numOfOtherBlockchain
    )
        external
        onlyOwner
    {
        require(
            existingOtherBlockchain[numOfOtherBlockchain],
            "swapContract: This blockchain was not added"
        );
        existingOtherBlockchain[numOfOtherBlockchain] = false;
    }

    /** 
      * @dev Change existing blockchain id
      * @param oldNumOfOtherBlockchain number of existing blockchain
      * @param newNumOfOtherBlockchain number of new blockchain
      */
    function changeOtherBlockchain(
        uint128 oldNumOfOtherBlockchain,
        uint128 newNumOfOtherBlockchain
    )
        external
        onlyOwner
    {
        require(
            oldNumOfOtherBlockchain != newNumOfOtherBlockchain,
            "swapContract: Cannot change blockchains with same number"
        );
        require(
            newNumOfOtherBlockchain != numOfThisBlockchain,
            "swapContract: Cannot add this blockchain to array of other blockchains"
        );
        require(
            existingOtherBlockchain[oldNumOfOtherBlockchain],
            "swapContract: This blockchain was not added"
        );
        require(
            !existingOtherBlockchain[newNumOfOtherBlockchain],
            "swapContract: This blockchain is already added"
        );
        
        existingOtherBlockchain[oldNumOfOtherBlockchain] = false;
        existingOtherBlockchain[newNumOfOtherBlockchain] = true;
    }


    // FEE MANAGEMENT

    /** 
      * @dev Changes address which receives fees from transfers
      * @param newFeeAddress New address for fees
      */
    function changeFeeAddress(address newFeeAddress) external onlyOwnerAndManager
    {
        feeAddress = newFeeAddress;
    }

    /** 
      * @dev Changes fee values for blockchains in feeAmountOfBlockchain variables
      * @param blockchainNum Existing number of blockchain
      * @param feeAmount Fee amount to substruct from transfer amount
      */
    function setFeeAmountOfBlockchain(uint128 blockchainNum, uint128 feeAmount) external onlyOwnerAndManager
    {
        feeAmountOfBlockchain[blockchainNum] = feeAmount;
    }

    // VALIDATOR CONFIRMATIONS MANAGEMENT

    /** 
      * @dev Changes requirement for minimal amount of signatures to validate on transfer
      * @param _minConfirmationSignatures Number of signatures to verify
      */
    function setMinConfirmationSignatures(uint256 _minConfirmationSignatures) external onlyOwner {
        require(_minConfirmationSignatures > 0, "swapContract: At least 1 confirmation can be set");
        minConfirmationSignatures = _minConfirmationSignatures;
    }

    /** 
      * @dev Changes requirement for minimal token amount on transfers
      * @param _minTokenAmount Amount of tokens
      */
    function setMinTokenAmount(uint256 _minTokenAmount) external onlyOwnerAndManager {
        minTokenAmount = _minTokenAmount;
    }

    /** 
      * @dev Changes parameter of maximum gas price on which relayer nodes will operate
      * @param _maxGasPrice Price of gas in wei
      */
    function setMaxGasPrice(uint256 _maxGasPrice) external onlyOwnerAndManager {
        require(_maxGasPrice > 0, "swapContract: Gas price cannot be zero");
        maxGasPrice = _maxGasPrice;
    }

    /** 
      * @dev Changes requirement for minimal amount of block to consider tx confirmed on validator
      * @param _minConfirmationBlocks Amount of blocks
      */

    function setMinConfirmationBlocks(uint256 _minConfirmationBlocks) external onlyOwnerAndManager {
        minConfirmationBlocks = _minConfirmationBlocks;
    }

    /** 
      * @dev Transfers permissions of contract ownership. 
      * Will setup new owner and one manager on contract.
      * Main purpose of this function is to transfer ownership from deployer account ot real owner
      * @param newOwner Address of new owner
      * @param newManager Address of new manager
      */
    function transferOwnerAndSetManager(address newOwner, address newManager) external onlyOwner {
        require(newOwner != _msgSender(), "swapContract: New owner must be different than current");
        require(newOwner != address(0x0), "swapContract: Owner cannot be zero address");
        require(newManager != address(0x0), "swapContract: Owner cannot be zero address");
        _setupRole(DEFAULT_ADMIN_ROLE, newOwner);
        _setupRole(OWNER_ROLE, newOwner);
        _setupRole(MANAGER_ROLE, newManager);
        renounceRole(OWNER_ROLE, _msgSender());
        renounceRole(DEFAULT_ADMIN_ROLE, _msgSender());
    }

    /** 
      * @dev Pauses transfers of tokens on contract
      */
    function pauseExecution() external onlyOwner {
        _pause();
    }

    /** 
      * @dev Resumes transfers of tokens on contract
      */
    function continueExecution() external onlyOwner {
        _unpause();
    }

    /** 
      * @dev Function to check if address is belongs to owner role
      * @param account Address to check
      */
    function isOwner(address account) public view returns (bool) {
        return hasRole(OWNER_ROLE, account);
    }

    /** 
      * @dev Function to check if address is belongs to manager role
      * @param account Address to check
      */
    function isManager(address account) public view returns (bool) {
        return hasRole(MANAGER_ROLE, account);
    }

    /** 
      * @dev Function to check if address is belongs to relayer role
      * @param account Address to check
      */
    function isRelayer(address account) public view returns (bool) {
        return hasRole(RELAYER_ROLE, account);
    }

    /** 
      * @dev Function to check if address is belongs to validator role
      * @param account Address to check
      * 
      */
    function isValidator(address account) public view returns (bool) {
        return hasRole(VALIDATOR_ROLE, account);
    }

    /** 
      * @dev Function to check if transfer of tokens on previous
      * transaction from other blockchain was executed
      * @param originalTxHash Transaction hash to check
      */
    function isProcessedTransaction(bytes32 originalTxHash) public view returns (bool processed, bytes32 hashedParams) {
        hashedParams = processedTransactions[originalTxHash];
        processed = hashedParams != bytes32(0);
    }
}

File 3 of 9 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <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 GSN 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 payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

File 4 of 9 : AccessControl.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

import "../utils/EnumerableSet.sol";
import "../utils/Address.sol";
import "../GSN/Context.sol";

/**
 * @dev Contract module that allows children to implement role-based access
 * control mechanisms.
 *
 * 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 {
    using EnumerableSet for EnumerableSet.AddressSet;
    using Address for address;

    struct RoleData {
        EnumerableSet.AddressSet members;
        bytes32 adminRole;
    }

    mapping (bytes32 => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @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 {_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) public view returns (bool) {
        return _roles[role].members.contains(account);
    }

    /**
     * @dev Returns the number of accounts that have `role`. Can be used
     * together with {getRoleMember} to enumerate all bearers of a role.
     */
    function getRoleMemberCount(bytes32 role) public view returns (uint256) {
        return _roles[role].members.length();
    }

    /**
     * @dev Returns one of the accounts that have `role`. `index` must be a
     * value between 0 and {getRoleMemberCount}, non-inclusive.
     *
     * Role bearers are not sorted in any particular way, and their ordering may
     * change at any point.
     *
     * WARNING: When using {getRoleMember} and {getRoleMemberCount}, make sure
     * you perform all queries on the same block. See the following
     * https://forum.openzeppelin.com/t/iterating-over-elements-on-enumerableset-in-openzeppelin-contracts/2296[forum post]
     * for more information.
     */
    function getRoleMember(bytes32 role, uint256 index) public view returns (address) {
        return _roles[role].members.at(index);
    }

    /**
     * @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 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 {
        require(hasRole(_roles[role].adminRole, _msgSender()), "AccessControl: sender must be an admin to grant");

        _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 {
        require(hasRole(_roles[role].adminRole, _msgSender()), "AccessControl: sender must be an admin to revoke");

        _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 {
        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 {
        emit RoleAdminChanged(role, _roles[role].adminRole, adminRole);
        _roles[role].adminRole = adminRole;
    }

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

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

File 5 of 9 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

File 6 of 9 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <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 7 of 9 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.2 <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;
        // solhint-disable-next-line no-inline-assembly
        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");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private 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

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 8 of 9 : EnumerableSet.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;

        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping (bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) { // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            // When the value to delete is the last one, the swap operation is unnecessary. However, since this occurs
            // so rarely, we still do the swap anyway to avoid the gas cost of adding an 'if' statement.

            bytes32 lastvalue = set._values[lastIndex];

            // Move the last value to the index where the value to delete is
            set._values[toDeleteIndex] = lastvalue;
            // Update the index for the moved value
            set._indexes[lastvalue] = toDeleteIndex + 1; // All indexes are 1-based

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        require(set._values.length > index, "EnumerableSet: index out of bounds");
        return set._values[index];
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(value)));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(value)));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(value)));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint256(_at(set._inner, index)));
    }


    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

   /**
    * @dev Returns the value stored at position `index` in the set. O(1).
    *
    * Note that there are no guarantees on the ordering of values inside the
    * array, and it may change when more values are added or removed.
    *
    * Requirements:
    *
    * - `index` must be strictly less than {length}.
    */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }
}

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

pragma solidity >=0.6.0 <0.8.0;

import "../GSN/Context.sol";

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

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

    bool private _paused;

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

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

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

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

    /**
     * @dev Triggers stopped state.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    function _pause() internal virtual whenNotPaused {
        _paused = true;
        emit Paused(_msgSender());
    }

    /**
     * @dev Returns to normal state.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    function _unpause() internal virtual whenPaused {
        _paused = false;
        emit Unpaused(_msgSender());
    }
}

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

Contract ABI

[{"inputs":[{"internalType":"contract IERC20","name":"_tokenAddress","type":"address"},{"internalType":"address","name":"_feeAddress","type":"address"},{"internalType":"uint128","name":"_numOfThisBlockchain","type":"uint128"},{"internalType":"uint128[]","name":"_numsOfOtherBlockchains","type":"uint128[]"},{"internalType":"uint128","name":"_minConfirmationSignatures","type":"uint128"},{"internalType":"uint256","name":"_minTokenAmount","type":"uint256"},{"internalType":"uint256","name":"_maxGasPrice","type":"uint256"},{"internalType":"uint256","name":"_minConfirmationBlocks","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","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"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountWithoutFee","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"originalTxHash","type":"bytes32"}],"name":"TransferFromOtherBlockchain","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint128","name":"blockchain","type":"uint128"},{"indexed":false,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"string","name":"newAddress","type":"string"}],"name":"TransferToOtherBlockchain","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MANAGER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OWNER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RELAYER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SIGNATURE_LENGTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VALIDATOR_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint128","name":"numOfOtherBlockchain","type":"uint128"}],"name":"addOtherBlockchain","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newFeeAddress","type":"address"}],"name":"changeFeeAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint128","name":"oldNumOfOtherBlockchain","type":"uint128"},{"internalType":"uint128","name":"newNumOfOtherBlockchain","type":"uint128"}],"name":"changeOtherBlockchain","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"continueExecution","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"uint256","name":"offset","type":"uint256"}],"name":"ecOffsetRecover","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint128","name":"","type":"uint128"}],"name":"existingOtherBlockchain","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint128","name":"","type":"uint128"}],"name":"feeAmountOfBlockchain","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"amountWithFee","type":"uint256"},{"internalType":"bytes32","name":"originalTxHash","type":"bytes32"}],"name":"getHashPacked","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint128","name":"blockchain","type":"uint128"}],"name":"getOtherBlockchainAvailableByNum","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","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":"uint256","name":"index","type":"uint256"}],"name":"getRoleMember","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleMemberCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":[{"internalType":"address","name":"account","type":"address"}],"name":"isManager","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isOwner","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"originalTxHash","type":"bytes32"}],"name":"isProcessedTransaction","outputs":[{"internalType":"bool","name":"processed","type":"bool"},{"internalType":"bytes32","name":"hashedParams","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isRelayer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"isValidator","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxGasPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minConfirmationBlocks","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minConfirmationSignatures","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minTokenAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numOfThisBlockchain","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pauseExecution","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"processedTransactions","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint128","name":"numOfOtherBlockchain","type":"uint128"}],"name":"removeOtherBlockchain","outputs":[],"stateMutability":"nonpayable","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":[{"internalType":"uint128","name":"blockchainNum","type":"uint128"},{"internalType":"uint128","name":"feeAmount","type":"uint128"}],"name":"setFeeAmountOfBlockchain","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxGasPrice","type":"uint256"}],"name":"setMaxGasPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minConfirmationBlocks","type":"uint256"}],"name":"setMinConfirmationBlocks","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minConfirmationSignatures","type":"uint256"}],"name":"setMinConfirmationSignatures","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minTokenAmount","type":"uint256"}],"name":"setMinTokenAmount","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"hash","type":"bytes32"}],"name":"toEthSignedMessageHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"tokenAddress","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"},{"internalType":"address","name":"newManager","type":"address"}],"name":"transferOwnerAndSetManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint128","name":"blockchain","type":"uint128"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"string","name":"newAddress","type":"string"}],"name":"transferToOtherBlockchain","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"amountWithFee","type":"uint256"},{"internalType":"bytes32","name":"originalTxHash","type":"bytes32"},{"internalType":"bytes","name":"concatSignatures","type":"bytes"}],"name":"transferToUserWithFee","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040523480156200001157600080fd5b5060405162003c2b38038062003c2b83398181016040526101008110156200003857600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006c57600080fd5b9083019060208201858111156200008257600080fd5b8251866020820283011164010000000082111715620000a057600080fd5b82525081516020918201928201910280838360005b83811015620000cf578181015183820152602001620000b5565b505050509190910160409081526020830151908301516060840151608090940151600180546001600160a81b0319166101006001600160a01b038e81169190910291909117909155600280546001600160a01b031916918c169190911790559195509350905060005b8551811015620001f757866001600160801b03168682815181106200015957fe5b60200260200101516001600160801b03161415620001a95760405162461bcd60e51b815260040180806020018281038252604881526020018062003be36048913960600191505060405180910390fd5b600160046000888481518110620001bc57fe5b6020908102919091018101516001600160801b03168252810191909152604001600020805460ff191691151591909117905560010162000138565b5060008211620002395760405162461bcd60e51b815260040180806020018281038252602681526020018062003bbd6026913960400191505060405180910390fd5b600380546001600160801b0319166001600160801b0388811691909117909155841660075560088390556009829055600a8190556200028360006200027d620002c0565b620002c4565b620002b27fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e6200027d620002c0565b5050505050505050620003d4565b3390565b620002d08282620002d4565b5050565b600082815260208181526040909120620002f991839062002bde6200034d821b17901c565b15620002d05762000309620002c0565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b600062000364836001600160a01b0384166200036d565b90505b92915050565b60006200037b8383620003bc565b620003b35750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915562000367565b50600062000367565b60009081526001919091016020526040902054151590565b6137d980620003e46000396000f3fe608060405234801561001057600080fd5b50600436106103155760003560e01c80635fdb9ec9116101a7578063ac2e4936116100ee578063d547741f11610097578063ec87621c11610071578063ec87621c14610add578063f3ae241514610ae5578063facd743b14610b1857610315565b8063d547741f14610a65578063d86d1d1a14610a9e578063e58378bb14610ad557610315565b8063c5d4d1c2116100c8578063c5d4d1c2146109fc578063ca15c87314610a2b578063d2fa635e14610a4857610315565b8063ac2e4936146109aa578063bf9cfe05146109c7578063c49baebe146109f457610315565b806391d1485411610150578063960f5e891161012a578063960f5e891461096b5780639d76ea581461099a578063a217fddf146109a257610315565b806391d1485414610922578063926d7d7f1461095b5780639294a0301461096357610315565b80638ce74cd0116101815780638ce74cd0146108da5780639010d07c146108e2578063918a15cf1461090557610315565b80635fdb9ec91461088657806374832748146108a35780638124bb0f146108d257610315565b80632f54bf6e1161026b5780634127535811610214578063541d5548116101ee578063541d55481461077c57806358fdb101146107af5780635c975abb1461087e57610315565b806341275358146106945780634d832750146106c5578063540bc5ea1461077457610315565b80633db99b36116102455780633db99b36146105995780633de39c11146105c85780633f19f657146105d057610315565b80632f54bf6e146104e157806336568abe146105285780633771fc2f1461056157610315565b80631f041ec6116102cd578063285e1406116102a7578063285e14061461043e5780632a3221c6146104715780632f2ff15d146104a857610315565b80631f041ec6146103ea57806320b337c4146103f2578063248a9ca31461042157610315565b806312b57cea116102fe57806312b57cea146103a85780631641f1ba146103b05780631b7f05f8146103cd57610315565b8063051f66641461031a578063102a95af1461036b575b600080fd5b6103596004803603606081101561033057600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135169060208101359060400135610b4b565b60408051918252519081900360200190f35b6103a66004803603604081101561038157600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020013516610bad565b005b610359610e4e565b6103a6600480360360208110156103c657600080fd5b5035610e54565b6103a6600480360360208110156103e357600080fd5b5035610f0c565b6103a6611001565b6103a66004803603602081101561040857600080fd5b50356fffffffffffffffffffffffffffffffff166110a2565b6103596004803603602081101561043757600080fd5b50356111fb565b6103a66004803603602081101561045457600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16611210565b6103a66004803603604081101561048757600080fd5b506fffffffffffffffffffffffffffffffff8135811691602001351661130a565b6103a6600480360360408110156104be57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff166115e5565b610514600480360360208110156104f757600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16611662565b604080519115158252519081900360200190f35b6103a66004803603604081101561053e57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16611694565b61057e6004803603602081101561057757600080fd5b5035611729565b60408051921515835260208301919091528051918290030190f35b6103a6600480360360208110156105af57600080fd5b50356fffffffffffffffffffffffffffffffff1661173e565b61035961190b565b6103a6600480360360608110156105e657600080fd5b6fffffffffffffffffffffffffffffffff8235169160208101359181019060608101604082013564010000000081111561061f57600080fd5b82018360208201111561063157600080fd5b8035906020019184600183028401116401000000008311171561065357600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550611911945050505050565b61069c611dbe565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b61069c600480360360608110156106db57600080fd5b813591908101906040810160208201356401000000008111156106fd57600080fd5b82018360208201111561070f57600080fd5b8035906020019184600183028401116401000000008311171561073157600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505091359250611dda915050565b610359611ebf565b6105146004803603602081101561079257600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16611ec4565b6103a6600480360360808110156107c557600080fd5b73ffffffffffffffffffffffffffffffffffffffff823516916020810135916040820135919081019060808101606082013564010000000081111561080957600080fd5b82018360208201111561081b57600080fd5b8035906020019184600183028401116401000000008311171561083d57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550611ef0945050505050565b6105146125bc565b6103a66004803603602081101561089c57600080fd5b50356125c5565b610514600480360360208110156108b957600080fd5b50356fffffffffffffffffffffffffffffffff1661267d565b6103a66126a4565b610359612743565b61069c600480360360408110156108f857600080fd5b5080359060200135612749565b6103596004803603602081101561091b57600080fd5b5035612761565b6105146004803603604081101561093857600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff166127b2565b6103596127ca565b6103596127ee565b6105146004803603602081101561098157600080fd5b50356fffffffffffffffffffffffffffffffff166127f4565b61069c612809565b61035961282a565b610359600480360360208110156109c057600080fd5b503561282f565b6109cf612841565b604080516fffffffffffffffffffffffffffffffff9092168252519081900360200190f35b610359612859565b6109cf60048036036020811015610a1257600080fd5b50356fffffffffffffffffffffffffffffffff1661287d565b61035960048036036020811015610a4157600080fd5b50356128a1565b6103a660048036036020811015610a5e57600080fd5b50356128b8565b6103a660048036036040811015610a7b57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff166129c9565b6103a660048036036040811015610ab457600080fd5b506fffffffffffffffffffffffffffffffff81358116916020013516612a3c565b610359612b3e565b610359612b62565b61051460048036036020811015610afb57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16612b86565b61051460048036036020811015610b2e57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16612bb2565b604080517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606086901b1660208083019190915260348201859052605480830185905283518084039091018152607490920190925280519101205b9392505050565b610bde7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b6127b2565b610c4957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b610c51612c00565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cd5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806133f96036913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8216610d41576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061353b602a913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116610dad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061353b602a913960400191505060405180910390fd5b610db8600083611658565b610de27fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e83611658565b610e0c7f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b0882611658565b610e3d7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610e38612c00565b611694565b610e4a6000610e38612c00565b5050565b60075481565b610e807fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b80610eb25750610eb27f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08610bd9612c00565b610f07576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806135656026913960400191505060405180910390fd5b600855565b610f387fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b610fa357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b60008111610ffc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806136916030913960400191505060405180910390fd5b600755565b61102d7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b61109857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b6110a0612c04565b565b6110ce7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b61113957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b6fffffffffffffffffffffffffffffffff811660009081526004602052604090205460ff166111b3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b81526020018061360f602b913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff16600090815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60009081526020819052604090206002015490565b61123c7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b8061126e575061126e7f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08610bd9612c00565b6112c3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806135656026913960400191505060405180910390fd5b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6113367fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b6113a157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b806fffffffffffffffffffffffffffffffff16826fffffffffffffffffffffffffffffffff16141561141e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260388152602001806135036038913960400191505060405180910390fd5b6003546fffffffffffffffffffffffffffffffff8281169116141561148e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260468152602001806134bd6046913960600191505060405180910390fd5b6fffffffffffffffffffffffffffffffff821660009081526004602052604090205460ff16611508576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b81526020018061360f602b913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff811660009081526004602052604090205460ff1615611583576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806136f2602e913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff91821660009081526004602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff009081169091559290931681529190912080549091166001179055565b60008281526020819052604090206002015461160390610bd9612c00565b611658576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602f81526020018061339e602f913960400191505060405180910390fd5b610e4a8282612cf3565b600061168e7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e836127b2565b92915050565b61169c612c00565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161461171f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602f815260200180613775602f913960400191505060405180910390fd5b610e4a8282612d76565b60009081526006602052604090205480151591565b61176a7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b6117d557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b6003546fffffffffffffffffffffffffffffffff82811691161415611845576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260468152602001806134bd6046913960600191505060405180910390fd5b6fffffffffffffffffffffffffffffffff811660009081526004602052604090205460ff16156118c0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806136f2602e913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff16600090815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b60095481565b60015460ff161561198357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60008151116119dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602d81526020018061363a602d913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff831660009081526004602052604090205460ff168015611a2557506003546fffffffffffffffffffffffffffffffff848116911614155b611a7a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260288152602001806137206028913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff80841660009081526005602052604090205416821015611af6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602981526020018061358b6029913960400191505060405180910390fd5b6000611b00612c00565b90508260018054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611b8a57600080fd5b505afa158015611b9e573d6000803e3d6000fd5b505050506040513d6020811015611bb457600080fd5b50511015611c2357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f73776170436f6e74726163743a204e6f7420656e6f7567682062616c616e6365604482015290519081900360640190fd5b600154604080517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8481166004830152306024830152604482018790529151610100909304909116916323b872dd916064808201926020929091908290030181600087803b158015611cab57600080fd5b505af1158015611cbf573d6000803e3d6000fd5b505050506040513d6020811015611cd557600080fd5b5050604080516fffffffffffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff831660208281019190915291810185905260806060820181815285519183019190915284517f530414e7b01e4eb239740ce86981a020e12faaffca6a86bbb62113a4ffafbaf693889386938993899360a08401919085019080838360005b83811015611d7b578181015183820152602001611d63565b50505050905090810190601f168015611da85780820380516001836020036101000a031916815260200191505b509550505050505060405180910390a150505050565b60025473ffffffffffffffffffffffffffffffffffffffff1681565b8181016020810151604082015160609092015160009290831a601b811015611e0057601b015b8060ff16601b14158015611e1857508060ff16601c14155b15611e295760009350505050610ba6565b6001611e3488612761565b82858560405160008152602001604052604051808581526020018460ff1681526020018381526020018281526020019450505050506020604051602081039080840390855afa158015611e8b573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015198975050505050505050565b604181565b600061168e7fe2b7fb3b832174769106daebcfd6d1970523240dda11281102db9363b83b0dc4836127b2565b611f1c7fe2b7fb3b832174769106daebcfd6d1970523240dda11281102db9363b83b0dc4610bd9612c00565b611f71576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b8152602001806135b4602b913960400191505060405180910390fd5b60015460ff1615611fe357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60085483101561203e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806136c16031913960400191505060405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84166120aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602c8152602001806133cd602c913960400191505060405180910390fd5b80516120b7906041612df9565b1561210d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603881526020018061342f6038913960400191505060405180910390fd5b600754815161211d906041612e3b565b1015612174576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180613667602a913960400191505060405180910390fd5b6000612181858585610b4b565b905060008061218f85611729565b91509150811580156121a15750828114155b6121f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602b815260200180613373602b913960400191505060405180910390fd5b8351600090612206906041612e3b565b905060008167ffffffffffffffff8111801561222157600080fd5b5060405190808252806020026020018201604052801561224b578160200160208202803683370190505b50905060005b828110156123b0576000612269878960418502611dda565b905061227481612bb2565b6122c9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806134676030913960400191505060405180910390fd5b60005b82811015612374578381815181106122e057fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561236c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602d815260200180613748602d913960400191505060405180910390fd5b6001016122cc565b508083838151811061238257fe5b73ffffffffffffffffffffffffffffffffffffffff9092166020928302919091019091015250600101612251565b5060008781526006602090815260408083208890556003546fffffffffffffffffffffffffffffffff9081168452600590925282205416906123f28a83612e7d565b600154604080517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8f81166004830152602482018590529151939450610100909204169163a9059cbb916044808201926020929091908290030181600087803b15801561247557600080fd5b505af1158015612489573d6000803e3d6000fd5b505050506040513d602081101561249f57600080fd5b5050600154600254604080517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff92831660048201526024810186905290516101009093049091169163a9059cbb916044808201926020929091908290030181600087803b15801561252657600080fd5b505af115801561253a573d6000803e3d6000fd5b505050506040513d602081101561255057600080fd5b50506040805173ffffffffffffffffffffffffffffffffffffffff8d168152602081018c9052808201839052606081018b905290517f8157b9086cfdda00012a3010e96c58ca2bf54627629af408db9302736af9e0659181900360800190a15050505050505050505050565b60015460ff1690565b6125f17fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b8061262357506126237f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08610bd9612c00565b612678576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806135656026913960400191505060405180910390fd5b600a55565b6fffffffffffffffffffffffffffffffff1660009081526004602052604090205460ff1690565b6126d07fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b61273b57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f43616c6c6572206973206e6f7420696e206f776e657220726f6c650000000000604482015290519081900360640190fd5b6110a0612ebf565b600a5481565b6000828152602081905260408120610ba69083612f81565b604080517f19457468657265756d205369676e6564204d6573736167653a0a333200000000602080830191909152603c8083019490945282518083039094018452605c909101909152815191012090565b6000828152602081905260408120610ba69083612f8d565b7fe2b7fb3b832174769106daebcfd6d1970523240dda11281102db9363b83b0dc481565b60085481565b60046020526000908152604090205460ff1681565b600154610100900473ffffffffffffffffffffffffffffffffffffffff1681565b600081565b60066020526000908152604090205481565b6003546fffffffffffffffffffffffffffffffff1681565b7f21702c8af46127c7fa207f89d0b0a8441bb32959a0ac7df790e9ab1a25c9892681565b6005602052600090815260409020546fffffffffffffffffffffffffffffffff1681565b600081815260208190526040812061168e90612faf565b6128e47fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b8061291657506129167f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08610bd9612c00565b61296b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806135656026913960400191505060405180910390fd5b600081116129c4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806134976026913960400191505060405180910390fd5b600955565b6000828152602081905260409020600201546129e790610bd9612c00565b61171f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806135df6030913960400191505060405180910390fd5b612a687fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e610bd9612c00565b80612a9a5750612a9a7f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08610bd9612c00565b612aef576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806135656026913960400191505060405180910390fd5b6fffffffffffffffffffffffffffffffff918216600090815260056020526040902080547fffffffffffffffffffffffffffffffff000000000000000000000000000000001691909216179055565b7fb19546dff01e856fb3f010c267a7b1c60363cf8a4664e21cc89c26224620214e81565b7f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b0881565b600061168e7f241ecf16d79d0f8dbfb92cbc07fe17840425976cf0667f022fe9877caa831b08836127b2565b600061168e7f21702c8af46127c7fa207f89d0b0a8441bb32959a0ac7df790e9ab1a25c98926836127b2565b6000610ba68373ffffffffffffffffffffffffffffffffffffffff8416612fba565b3390565b60015460ff1615612c7657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b600180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016811790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258612cc9612c00565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190a1565b6000828152602081905260409020612d0b9082612bde565b15610e4a57612d18612c00565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b6000828152602081905260409020612d8e9082613004565b15610e4a57612d9b612c00565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b60405160405180910390a45050565b6000610ba683836040518060400160405280601881526020017f536166654d6174683a206d6f64756c6f206279207a65726f0000000000000000815250613026565b6000610ba683836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506130df565b6000610ba683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061315e565b60015460ff16612f3057604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015290519081900360640190fd5b600180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa612cc9612c00565b6000610ba683836131d2565b6000610ba68373ffffffffffffffffffffffffffffffffffffffff8416613250565b600061168e82613268565b6000612fc68383613250565b612ffc5750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561168e565b50600061168e565b6000610ba68373ffffffffffffffffffffffffffffffffffffffff841661326c565b600081836130cc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613091578181015183820152602001613079565b50505050905090810190601f1680156130be5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b508284816130d657fe5b06949350505050565b60008183613148576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201818152835160248401528351909283926044909101919085019080838360008315613091578181015183820152602001613079565b50600083858161315457fe5b0495945050505050565b600081848411156131ca576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201818152835160248401528351909283926044909101919085019080838360008315613091578181015183820152602001613079565b505050900390565b8154600090821061322e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806133516022913960400191505060405180910390fd5b82600001828154811061323d57fe5b9060005260206000200154905092915050565b60009081526001919091016020526040902054151590565b5490565b600081815260018301602052604081205480156133465783547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80830191908101906000908790839081106132bd57fe5b90600052602060002001549050808760000184815481106132da57fe5b60009182526020808320909101929092558281526001898101909252604090209084019055865487908061330a57fe5b6001900381819060005260206000200160009055905586600101600087815260200190815260200160002060009055600194505050505061168e565b600091505061168e56fe456e756d657261626c655365743a20696e646578206f7574206f6620626f756e647373776170436f6e74726163743a205472616e73616374696f6e20616c72656164792070726f636573736564416363657373436f6e74726f6c3a2073656e646572206d75737420626520616e2061646d696e20746f206772616e7473776170436f6e74726163743a20416464726573732063616e6e6f74206265207a65726f206164647265737373776170436f6e74726163743a204e6577206f776e6572206d75737420626520646966666572656e74207468616e2063757272656e7473776170436f6e74726163743a205369676e617475726573206c656e67746873206d75737420626520646976697369626c6520627920363573776170436f6e74726163743a2056616c696461746f722061646472657373206e6f7420696e2077686974656c69737473776170436f6e74726163743a204761732070726963652063616e6e6f74206265207a65726f73776170436f6e74726163743a2043616e6e6f7420616464207468697320626c6f636b636861696e20746f206172726179206f66206f7468657220626c6f636b636861696e7373776170436f6e74726163743a2043616e6e6f74206368616e676520626c6f636b636861696e7320776974682073616d65206e756d62657273776170436f6e74726163743a204f776e65722063616e6e6f74206265207a65726f206164647265737343616c6c6572206973206e6f7420696e206f776e6572206f72206d616e6167657220726f6c6573776170436f6e74726163743a204e6f7420656e6f75676820616d6f756e74206f6620746f6b656e7373776170436f6e74726163743a2043616c6c6572206973206e6f7420696e2072656c6179657220726f6c65416363657373436f6e74726f6c3a2073656e646572206d75737420626520616e2061646d696e20746f207265766f6b6573776170436f6e74726163743a205468697320626c6f636b636861696e20776173206e6f7420616464656473776170436f6e74726163743a204e6f2064657374696e6174696f6e20616464726573732070726f766964656473776170436f6e74726163743a204e6f7420656e6f756768207369676e6174757265732070617373656473776170436f6e74726163743a204174206c65617374203120636f6e6669726d6174696f6e2063616e2062652073657473776170436f6e74726163743a20416d6f756e74206d7573742062652067726561746572207468616e206d696e696d756d73776170436f6e74726163743a205468697320626c6f636b636861696e20697320616c726561647920616464656473776170436f6e74726163743a2057726f6e672063686f6f7365206f6620626c6f636b636861696e73776170436f6e74726163743a2056616c696461746f722061646472657373206973206475706c696361746564416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636520726f6c657320666f722073656c66a26469706673582212200389627428807780443b18b364dae2382db3502f4639be4e7235625d0ce30bd264736f6c6343000706003373776170436f6e74726163743a204761732070726963652063616e6e6f74206265207a65726f73776170436f6e74726163743a204e756d626572206f66207468697320626c6f636b636861696e20697320696e206172726179206f66206f7468657220626c6f636b636861696e73000000000000000000000000fca6d1b139749c659f31840fe99516ba2277a654000000000000000000000000d220532e5188da2f6aef22c3477691a6edbfbb810000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000de0b6b3a764000000000000000000000000000000000000000000000000000000000022ecb25c00000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000002

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

000000000000000000000000fca6d1b139749c659f31840fe99516ba2277a654000000000000000000000000d220532e5188da2f6aef22c3477691a6edbfbb810000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000de0b6b3a764000000000000000000000000000000000000000000000000000000000022ecb25c00000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000002
-----Encoded View---------------
10 Constructor Arguments found :
Arg [0] : 000000000000000000000000fca6d1b139749c659f31840fe99516ba2277a654
Arg [1] : 000000000000000000000000d220532e5188da2f6aef22c3477691a6edbfbb81
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000100
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [5] : 0000000000000000000000000000000000000000000000000de0b6b3a7640000
Arg [6] : 00000000000000000000000000000000000000000000000000000022ecb25c00
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000001
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000002


Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading