ETH Price: $3,357.82 (-2.80%)
Gas: 2 Gwei

Contract

0xb80FDc10c08b717DF6d7a47890a62c9088324B47
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Transaction Hash
Method
Block
From
To
Value
Swap Exact Token...202236742024-07-03 4:43:5940 mins ago1719981839IN
0xb80FDc10...088324B47
0 ETH0.000771563.63107059
Swap Exact Token...202233362024-07-03 3:35:591 hr ago1719977759IN
0xb80FDc10...088324B47
0 ETH0.000988924.43650453
Swap Exact Token...200658172024-06-11 3:11:1122 days ago1718075471IN
0xb80FDc10...088324B47
0 ETH0.001197018.38828756
Swap Exact Token...199445612024-05-25 4:40:2339 days ago1716612023IN
0xb80FDc10...088324B47
0 ETH0.000610523.57552053
Swap Exact Token...198478702024-05-11 16:06:1152 days ago1715443571IN
0xb80FDc10...088324B47
0 ETH0.001657336
Swap Exact ETH F...198284522024-05-08 22:56:2355 days ago1715208983IN
0xb80FDc10...088324B47
0.00178567 ETH0.000637044.02201582
Swap Exact Token...197887982024-05-03 9:48:5960 days ago1714729739IN
0xb80FDc10...088324B47
0.00000407 ETH0.00340046.65854472
Swap Exact Token...197454902024-04-27 8:30:2366 days ago1714206623IN
0xb80FDc10...088324B47
0 ETH0.00093995.50528243
Swap Exact Token...197143382024-04-22 23:53:1171 days ago1713829991IN
0xb80FDc10...088324B47
0 ETH0.001007745.44354615
Swap Exact Token...197088942024-04-22 5:36:4771 days ago1713764207IN
0xb80FDc10...088324B47
0 ETH0.001223677.28312308
Swap Exact Token...197088852024-04-22 5:34:4771 days ago1713764087IN
0xb80FDc10...088324B47
0 ETH0.001241856.70858555
Swap Exact Token...197013412024-04-21 4:17:4773 days ago1713673067IN
0xb80FDc10...088324B47
0 ETH0.001241916.70886809
Swap Exact Token...196492712024-04-13 21:19:1180 days ago1713043151IN
0xb80FDc10...088324B47
0 ETH0.03042274181.05868701
Swap Exact Token...196492372024-04-13 21:12:2380 days ago1713042743IN
0xb80FDc10...088324B47
0 ETH0.03814638206.02851603
Swap Exact Token...196249842024-04-10 11:39:1183 days ago1712749151IN
0xb80FDc10...088324B47
0 ETH0.0027300515.98852318
Swap Exact Token...196228262024-04-10 4:24:2384 days ago1712723063IN
0xb80FDc10...088324B47
0 ETH0.0025244315.02395461
Swap Exact Token...196228192024-04-10 4:22:5984 days ago1712722979IN
0xb80FDc10...088324B47
0 ETH0.0027502214.85590858
Swap Exact Token...196124232024-04-08 17:26:1185 days ago1712597171IN
0xb80FDc10...088324B47
0 ETH0.0125886242.96063262
Swap Exact Token...195861682024-04-05 1:08:1189 days ago1712279291IN
0xb80FDc10...088324B47
0.00011 ETH0.0005156612.27776367
Swap Exact Token...195716672024-04-03 0:27:1191 days ago1712104031IN
0xb80FDc10...088324B47
0 ETH0.0032414122.82833843
Swap Exact ETH F...195236752024-03-27 5:41:4797 days ago1711518107IN
0xb80FDc10...088324B47
0.10409553 ETH0.0028263219.53107569
Swap Exact ETH F...195235182024-03-27 5:09:4798 days ago1711516187IN
0xb80FDc10...088324B47
0.05022743 ETH0.0084418217.8625054
Swap Exact Token...194961792024-03-23 8:41:47101 days ago1711183307IN
0xb80FDc10...088324B47
0 ETH0.0048048817.56840292
Swap Exact ETH F...193987682024-03-09 16:34:47115 days ago1710002087IN
0xb80FDc10...088324B47
0.00145318 ETH0.0486056180.55703788
Swap Exact Token...193967442024-03-09 9:48:23115 days ago1709977703IN
0xb80FDc10...088324B47
0 ETH0.0090621848.95118021
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To Value
202236742024-07-03 4:43:5940 mins ago1719981839
0xb80FDc10...088324B47
0.06332206 ETH
202236742024-07-03 4:43:5940 mins ago1719981839
0xb80FDc10...088324B47
0.00019053 ETH
202236742024-07-03 4:43:5940 mins ago1719981839
0xb80FDc10...088324B47
0.06351259 ETH
202233362024-07-03 3:35:591 hr ago1719977759
0xb80FDc10...088324B47
0.02143724 ETH
202233362024-07-03 3:35:591 hr ago1719977759
0xb80FDc10...088324B47
0.0000645 ETH
202233362024-07-03 3:35:591 hr ago1719977759
0xb80FDc10...088324B47
0.02150175 ETH
200658172024-06-11 3:11:1122 days ago1718075471
0xb80FDc10...088324B47
0.01630724 ETH
200658172024-06-11 3:11:1122 days ago1718075471
0xb80FDc10...088324B47
0.00004906 ETH
200658172024-06-11 3:11:1122 days ago1718075471
0xb80FDc10...088324B47
0.0163563 ETH
198478702024-05-11 16:06:1152 days ago1715443571
0xb80FDc10...088324B47
0.00656824 ETH
198478702024-05-11 16:06:1152 days ago1715443571
0xb80FDc10...088324B47
0.00001976 ETH
198478702024-05-11 16:06:1152 days ago1715443571
0xb80FDc10...088324B47
0.006588 ETH
198284522024-05-08 22:56:2355 days ago1715208983
0xb80FDc10...088324B47
0.00178567 ETH
197887982024-05-03 9:48:5960 days ago1714729739
0xb80FDc10...088324B47
0.00000407 ETH
197466882024-04-27 12:32:5966 days ago1714221179
0xb80FDc10...088324B47
0.10261374 ETH
197466882024-04-27 12:32:5966 days ago1714221179
0xb80FDc10...088324B47
0.00030876 ETH
197466882024-04-27 12:32:5966 days ago1714221179
0xb80FDc10...088324B47
0.10292251 ETH
197024582024-04-21 8:02:1172 days ago1713686531
0xb80FDc10...088324B47
0.10866109 ETH
197024582024-04-21 8:02:1172 days ago1713686531
0xb80FDc10...088324B47
0.00032696 ETH
197024582024-04-21 8:02:1172 days ago1713686531
0xb80FDc10...088324B47
0.10898805 ETH
196995102024-04-20 22:08:4773 days ago1713650927
0xb80FDc10...088324B47
0.07888386 ETH
196995102024-04-20 22:08:4773 days ago1713650927
0xb80FDc10...088324B47
0.00023736 ETH
196995102024-04-20 22:08:4773 days ago1713650927
0xb80FDc10...088324B47
0.07912122 ETH
196978922024-04-20 16:43:4773 days ago1713631427
0xb80FDc10...088324B47
0.07839978 ETH
196978922024-04-20 16:43:4773 days ago1713631427
0xb80FDc10...088324B47
0.0002359 ETH
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
O3EthereumUniswapAggregator

Compiler Version
v0.8.15+commit.e14f2714

Optimization Enabled:
Yes with 999999 runs

Other Settings:
default evmVersion
File 1 of 14 : O3EthereumUniswapAggregator.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity ^0.8.0;

import "../../access/Ownable.sol";
import "../../swap/interfaces/IPool.sol";
import "../interfaces/IUniswapV2Pair.sol";
import "../../assets/interfaces/IWETH.sol";
import "./libs/EthereumUniswapV2Library.sol";
import "../interfaces/IUniswapV2Factory.sol";
import "../../crossChain/interfaces/IWrapper.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";

contract O3EthereumUniswapAggregator is Ownable {
    using SafeMath for uint256;
    using SafeERC20 for IERC20;

    event LOG_AGG_SWAP (
        uint256 amountOut,
        uint256 fee
    );

    address public WETH = 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2;
    address public factory = 0x5C69bEe701ef814a2B6a3EDD4B1652CB9cc5aA6f;
    address public O3Wrapper = 0xeCF2B548e5c21028B0b60363207700fA421B6EcB;
    address public feeCollector;

    uint256 public aggregatorFee = 3 * 10 ** 7;
    uint256 public constant FEE_DENOMINATOR = 10 ** 10;
    uint256 private constant MAX_AGGREGATOR_FEE = 5 * 10**8;

    modifier ensure(uint deadline) {
        require(deadline >= block.timestamp, 'O3Aggregator: EXPIRED');
        _;
    }

    constructor (address _feeCollector) {
        feeCollector = _feeCollector;
    }

    receive() external payable { }

    function setWETH(address _weth) external onlyOwner {
        WETH = _weth;
    }

    function setFactory(address _factory) external onlyOwner {
        factory = _factory;
    }

    function setO3Wrapper(address _wrapper) external onlyOwner {
        O3Wrapper = _wrapper;
    }

    function setFeeCollector(address _feeCollector) external onlyOwner {
        feeCollector = _feeCollector;
    }

    function setAggregatorFee(uint _fee) external onlyOwner {
        require(_fee < MAX_AGGREGATOR_FEE, "aggregator fee exceeds maximum");
        aggregatorFee = _fee;
    }

    function rescueFund(address tokenAddress) external onlyOwner {
        IERC20 token = IERC20(tokenAddress);
        if (tokenAddress == WETH && address(this).balance > 0) {
            (bool success,) = _msgSender().call{value: address(this).balance}(new bytes(0));
            require(success, 'ETH_TRANSFER_FAILED');
        }
        token.safeTransfer(_msgSender(), token.balanceOf(address(this)));
    }

    function swapExactPTokensForTokensSupportingFeeOnTransferTokens(
        uint256 amountIn,
        address poolAddress,
        uint poolAmountOutMin,
        address[] calldata path,
        address to,
        uint deadline,
        uint aggSwapAmountOutMin,
        bool unwrapETH
    ) external virtual ensure(deadline) {
        if (amountIn == 0) {
            amountIn = IERC20(path[0]).allowance(_msgSender(), address(this));
        }

        require(amountIn != 0, 'O3Aggregator: ZERO_AMOUNT_IN');
        IERC20(path[0]).safeTransferFrom(_msgSender(), address(this), amountIn);

        {
            IERC20(path[0]).safeApprove(poolAddress, amountIn);
            address underlyingToken = address(IPool(poolAddress).coins(0));

            uint256 balanceBefore = IERC20(underlyingToken).balanceOf(address(this));
            IPool(poolAddress).swap(1, 0, amountIn, poolAmountOutMin, deadline);
            amountIn = IERC20(underlyingToken).balanceOf(address(this)) - balanceBefore;

            require(address(underlyingToken) == path[1], "O3Aggregator: INVALID_PATH");
        }

        uint amountOut = _swapExactTokensForTokensSupportingFeeOnTransferTokens(false, amountIn, aggSwapAmountOutMin, path[1:]);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        if (unwrapETH) {
            require(path[path.length - 1] == WETH, "O3Aggregator: INVALID_PATH");
            IWETH(WETH).withdraw(amountOut);
            _sendETH(feeCollector, feeAmount);
            _sendETH(to, amountOut.sub(feeAmount));
        } else {
            IERC20(path[path.length-1]).safeTransfer(feeCollector, feeAmount);
            IERC20(path[path.length-1]).safeTransfer(to, amountOut.sub(feeAmount));
        }
    }

    function swapExactTokensForTokensSupportingFeeOnTransferTokens(
        uint amountIn,
        uint swapAmountOutMin,
        address[] calldata path,
        address to,
        uint deadline
    ) external virtual ensure(deadline) {
        uint amountOut = _swapExactTokensForTokensSupportingFeeOnTransferTokens(true, amountIn, swapAmountOutMin, path);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        IERC20(path[path.length-1]).safeTransfer(feeCollector, feeAmount);
        IERC20(path[path.length-1]).safeTransfer(to, amountOut.sub(feeAmount));
    }

    function swapExactTokensForTokensSupportingFeeOnTransferTokensCrossChain(
        uint amountIn, uint swapAmountOutMin, address[] calldata path,         // args for dex
        address poolAddress, address tokenTo, uint256 minDy, uint256 deadline, // args for swap
        uint64 toChainId, bytes memory toAddress, bytes memory callData        // args for wrapper
    ) external virtual payable ensure(deadline) returns (bool) {
        (uint swapperAmountIn, address tokenFrom) = _swapExactTokensForTokensSupportingFeeOnTransferTokensCrossChain(amountIn, swapAmountOutMin, path);

        IERC20(tokenFrom).safeApprove(O3Wrapper, swapperAmountIn);

        return IWrapper(O3Wrapper).swapAndBridgeOut{value: msg.value}(
            poolAddress, tokenFrom, tokenTo, swapperAmountIn, minDy, deadline,
            toChainId, toAddress, callData
        );
    }

    function _swapExactTokensForTokensSupportingFeeOnTransferTokensCrossChain(
        uint amountIn, uint swapAmountOutMin, address[] calldata path
    ) internal returns (uint256, address) {
        uint amountOut = _swapExactTokensForTokensSupportingFeeOnTransferTokens(true, amountIn, swapAmountOutMin, path);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        IERC20(path[path.length-1]).safeTransfer(feeCollector, feeAmount);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        return (amountOut.sub(feeAmount), path[path.length-1]);
    }

    function _swapExactTokensForTokensSupportingFeeOnTransferTokens(
        bool pull,
        uint amountIn,
        uint amountOutMin,
        address[] calldata path
    ) internal virtual returns (uint) {
        if (pull) {
            IERC20(path[0]).safeTransferFrom(
                msg.sender, EthereumUniswapV2Library.pairFor(factory, path[0], path[1]), amountIn
            );
        } else {
            IERC20(path[0]).safeTransfer(EthereumUniswapV2Library.pairFor(factory, path[0], path[1]), amountIn);
        }

        uint balanceBefore = IERC20(path[path.length - 1]).balanceOf(address(this));
        _swapSupportingFeeOnTransferTokens(path, address(this));
        uint amountOut = IERC20(path[path.length - 1]).balanceOf(address(this)).sub(balanceBefore);
        require(amountOut >= amountOutMin, 'O3Aggregator: INSUFFICIENT_OUTPUT_AMOUNT');
        return amountOut;
    }

    function swapExactETHForTokensSupportingFeeOnTransferTokens(
        uint swapAmountOutMin,
        address[] calldata path,
        address to,
        uint deadline
    ) external virtual payable ensure(deadline) {
        uint amountOut = _swapExactETHForTokensSupportingFeeOnTransferTokens(swapAmountOutMin, path, 0);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        IERC20(path[path.length-1]).safeTransfer(feeCollector, feeAmount);
        IERC20(path[path.length - 1]).safeTransfer(to, amountOut.sub(feeAmount));
    }

    function swapExactETHForTokensSupportingFeeOnTransferTokensCrossChain(
        uint swapAmountOutMin, address[] calldata path, uint fee,              // args for dex
        address poolAddress, address tokenTo, uint256 minDy, uint256 deadline, // args for swap
        uint64 toChainId, bytes memory toAddress, bytes memory callData        // args for wrapper
    ) external virtual payable ensure(deadline) returns (bool) {
        (uint swapperAmountIn, address tokenFrom) = _swapExactETHForTokensSupportingFeeOnTransferTokensCrossChain(swapAmountOutMin, path, fee);

        IERC20(tokenFrom).safeApprove(O3Wrapper, swapperAmountIn);

        return IWrapper(O3Wrapper).swapAndBridgeOut{value: fee}(
            poolAddress, tokenFrom, tokenTo, swapperAmountIn, minDy, deadline,
            toChainId, toAddress, callData
        );
    }

    function _swapExactETHForTokensSupportingFeeOnTransferTokensCrossChain(
        uint swapAmountOutMin, address[] calldata path, uint fee
    ) internal returns (uint, address) {
        uint amountOut = _swapExactETHForTokensSupportingFeeOnTransferTokens(swapAmountOutMin, path, fee);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        IERC20(path[path.length-1]).safeTransfer(feeCollector, feeAmount);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        return (amountOut.sub(feeAmount), path[path.length-1]);
    }

    function _swapExactETHForTokensSupportingFeeOnTransferTokens(
        uint swapAmountOutMin,
        address[] calldata path,
        uint fee
    ) internal virtual returns (uint) {
        require(path[0] == WETH, 'O3Aggregator: INVALID_PATH');
        uint amountIn = msg.value.sub(fee);
        require(amountIn > 0, 'O3Aggregator: INSUFFICIENT_INPUT_AMOUNT');
        IWETH(WETH).deposit{value: amountIn}();
        assert(IWETH(WETH).transfer(EthereumUniswapV2Library.pairFor(factory, path[0], path[1]), amountIn));
        uint balanceBefore = IERC20(path[path.length - 1]).balanceOf(address(this));
        _swapSupportingFeeOnTransferTokens(path, address(this));
        uint amountOut = IERC20(path[path.length - 1]).balanceOf(address(this)).sub(balanceBefore);
        require(amountOut >= swapAmountOutMin, 'O3Aggregator: INSUFFICIENT_OUTPUT_AMOUNT');
        return amountOut;
    }

    function swapExactTokensForETHSupportingFeeOnTransferTokens(
        uint amountIn,
        uint swapAmountOutMin,
        address[] calldata path,
        address to,
        uint deadline
    ) external virtual ensure(deadline) {
        uint amountOut = _swapExactTokensForETHSupportingFeeOnTransferTokens(amountIn, swapAmountOutMin, path);
        uint feeAmount = amountOut.mul(aggregatorFee).div(FEE_DENOMINATOR);
        emit LOG_AGG_SWAP(amountOut, feeAmount);

        IWETH(WETH).withdraw(amountOut);

        _sendETH(feeCollector, feeAmount);
        _sendETH(to, amountOut.sub(feeAmount));
    }

    function _swapExactTokensForETHSupportingFeeOnTransferTokens(
        uint amountIn,
        uint swapAmountOutMin,
        address[] calldata path
    ) internal virtual returns (uint) {
        require(path[path.length - 1] == WETH, 'O3Aggregator: INVALID_PATH');
        IERC20(path[0]).safeTransferFrom(
            msg.sender, EthereumUniswapV2Library.pairFor(factory, path[0], path[1]), amountIn
        );
        uint balanceBefore = IERC20(WETH).balanceOf(address(this));
        _swapSupportingFeeOnTransferTokens(path, address(this));
        uint amountOut = IERC20(WETH).balanceOf(address(this)).sub(balanceBefore);
        require(amountOut >= swapAmountOutMin, 'O3Aggregator: INSUFFICIENT_OUTPUT_AMOUNT');
        return amountOut;
    }

    function _sendETH(address to, uint256 amount) internal {
        (bool success,) = to.call{value:amount}(new bytes(0));
        require(success, 'O3Aggregator: ETH_TRANSFER_FAILED');
    }

    // **** SWAP (supporting fee-on-transfer tokens) ****
    // requires the initial amount to have already been sent to the first pair
    function _swapSupportingFeeOnTransferTokens(address[] memory path, address _to) internal virtual {
        for (uint i; i < path.length - 1; i++) {
            (address input, address output) = (path[i], path[i + 1]);
            (address token0,) = EthereumUniswapV2Library.sortTokens(input, output);
            require(IUniswapV2Factory(factory).getPair(input, output) != address(0), "O3Aggregator: PAIR_NOT_EXIST");
            IUniswapV2Pair pair = IUniswapV2Pair(EthereumUniswapV2Library.pairFor(factory, input, output));
            uint amountInput;
            uint amountOutput;
            { // scope to avoid stack too deep errors
                (uint reserve0, uint reserve1,) = pair.getReserves();
                (uint reserveInput, uint reserveOutput) = input == token0 ? (reserve0, reserve1) : (reserve1, reserve0);
                amountInput = IERC20(input).balanceOf(address(pair)).sub(reserveInput);
                amountOutput = EthereumUniswapV2Library.getAmountOut(amountInput, reserveInput, reserveOutput);
            }
            (uint amount0Out, uint amount1Out) = input == token0 ? (uint(0), amountOutput) : (amountOutput, uint(0));
            address to = i < path.length - 2 ? EthereumUniswapV2Library.pairFor(factory, output, path[i + 2]) : _to;
            pair.swap(amount0Out, amount1Out, to, new bytes(0));
        }
    }
}

File 2 of 14 : IPool.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";

interface IPool {
    function coins(uint256 index) external view returns(IERC20);
    function getA() external view returns (uint256);
    function getTokenIndex(address token) external view returns (uint8);

    function getVirtualPrice() external view returns (uint256);

    function calculateSwap(uint8 tokenIndexFrom, uint8 tokenIndexTo, uint256 dx) external view returns (uint256 dy);
    function calculateRemoveLiquidity(uint256 amount) external view returns (uint256[] memory);
    function calculateTokenAmount(uint256[] calldata amounts, bool deposit) external view returns (uint256);
    function calculateWithdrawOneToken(uint256 tokenAmount, uint8 tokenIndex) external view returns (uint256 amount);

    function swap(uint8 tokenIndexFrom, uint8 tokenIndexTo, uint256 dx, uint256 minDy, uint256 deadline) external returns (uint256);
    function addLiquidity(uint256[] memory amounts, uint256 minToMint, uint256 deadline) external returns (uint256);
    function removeLiquidity(uint256 amount, uint256[] calldata minAmounts, uint256 deadline) external returns (uint256[] memory);
    function removeLiquidityOneToken(uint256 tokenAmount, uint8 tokenIndex, uint256 minAmount, uint256 deadline) external returns (uint256);
    function removeLiquidityImbalance(uint256[] calldata amounts, uint256 maxBurnAmount, uint256 deadline) external returns (uint256);

    function applySwapFee(uint256 newSwapFee) external;
    function applyAdminFee(uint256 newAdminFee) external;
    function getAdminBalance(uint256 index) external view returns (uint256);
    function withdrawAdminFee(address receiver) external;
    function rampA(uint256 _futureA, uint256 _futureTime) external;
    function stopRampA() external;
}

File 3 of 14 : IWrapper.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity ^0.8.0;

interface IWrapper {
    function bridgeOut(
        address pTokenAddress,
        uint256 amount,
        uint64 toChainId,
        bytes memory toAddress,
        bytes memory callData
    ) external payable returns(bool);

    function swapAndBridgeOut(
        address poolAddress, address tokenFrom, address tokenTo, uint256 dx, uint256 minDy, uint256 deadline, // args for swap
        uint64 toChainId, bytes memory toAddress, bytes memory callData                                       // args for bridge
    ) external payable returns(bool);

    function swapAndBridgeOutNativeToken(
        address poolAddress, address tokenTo, uint256 dx, uint256 minDy, uint256 deadline, // args for swap
        uint64 toChainId, bytes memory toAddress, bytes memory callData                    // args for bridge
    ) external payable returns(bool);

    function depositAndBridgeOut(
        address originalToken,
        address pTokenAddress,
        uint256 amount,
        uint64 toChainId,
        bytes memory toAddress,
        bytes memory callData
    ) external payable returns(bool);

    function depositAndBridgeOutNativeToken(
        address pTokenAddress,
        uint256 amount,
        uint64 toChainId,
        bytes memory toAddress,
        bytes memory callData
    ) external payable returns(bool);

    function bridgeOutAndWithdraw(
        address pTokenAddress,
        uint64 toChainId,
        bytes memory toAddress,
        uint256 amount
    ) external payable returns(bool);
}

File 4 of 14 : IWETH.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity ^0.8.0;

interface IWETH {
    function deposit() external payable;
    function withdraw(uint wad) external;

    function transfer(address dst, uint wad) external returns (bool);
}

File 5 of 14 : IUniswapV2Pair.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity >=0.8.0;

interface IUniswapV2Pair {
    event Approval(address indexed owner, address indexed spender, uint value);
    event Transfer(address indexed from, address indexed to, uint value);

    function name() external pure returns (string memory);
    function symbol() external pure returns (string memory);
    function decimals() external pure returns (uint8);
    function totalSupply() external view returns (uint);
    function balanceOf(address owner) external view returns (uint);
    function allowance(address owner, address spender) external view returns (uint);

    function approve(address spender, uint value) external returns (bool);
    function transfer(address to, uint value) external returns (bool);
    function transferFrom(address from, address to, uint value) external returns (bool);

    function DOMAIN_SEPARATOR() external view returns (bytes32);
    function PERMIT_TYPEHASH() external pure returns (bytes32);
    function nonces(address owner) external view returns (uint);

    function permit(address owner, address spender, uint value, uint deadline, uint8 v, bytes32 r, bytes32 s) external;

    event Mint(address indexed sender, uint amount0, uint amount1);
    event Burn(address indexed sender, uint amount0, uint amount1, address indexed to);
    event Swap(
        address indexed sender,
        uint amount0In,
        uint amount1In,
        uint amount0Out,
        uint amount1Out,
        address indexed to
    );
    event Sync(uint112 reserve0, uint112 reserve1);

    function MINIMUM_LIQUIDITY() external pure returns (uint);
    function factory() external view returns (address);
    function token0() external view returns (address);
    function token1() external view returns (address);
    function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast);
    function price0CumulativeLast() external view returns (uint);
    function price1CumulativeLast() external view returns (uint);
    function kLast() external view returns (uint);

    function mint(address to) external returns (uint liquidity);
    function burn(address to) external returns (uint amount0, uint amount1);
    function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external;
    function skim(address to) external;
    function sync() external;

    function initialize(address, address) external;
}

File 6 of 14 : IUniswapV2Factory.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity >=0.8.0;

interface IUniswapV2Factory {
    event PairCreated(address indexed token0, address indexed token1, address pair, uint);

    function feeTo() external view returns (address);
    function feeToSetter() external view returns (address);

    function getPair(address tokenA, address tokenB) external view returns (address pair);
    function allPairs(uint) external view returns (address pair);
    function allPairsLength() external view returns (uint);

    function createPair(address tokenA, address tokenB) external returns (address pair);

    function setFeeTo(address) external;
    function setFeeToSetter(address) external;
}

File 7 of 14 : EthereumUniswapV2Library.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity >=0.8.0;

import '../../interfaces/IUniswapV2Pair.sol';
import "@openzeppelin/contracts/utils/math/SafeMath.sol";

library EthereumUniswapV2Library {
    using SafeMath for uint;

    // returns sorted token addresses, used to handle return values from pairs sorted in this order
    function sortTokens(address tokenA, address tokenB) internal pure returns (address token0, address token1) {
        require(tokenA != tokenB, 'UniswapV2Library: IDENTICAL_ADDRESSES');
        (token0, token1) = tokenA < tokenB ? (tokenA, tokenB) : (tokenB, tokenA);
        require(token0 != address(0), 'UniswapV2Library: ZERO_ADDRESS');
    }

    // calculates the CREATE2 address for a pair without making any external calls
    function pairFor(address factory, address tokenA, address tokenB) internal pure returns (address pair) {
        (address token0, address token1) = sortTokens(tokenA, tokenB);
        pair = address(uint160(uint(keccak256(abi.encodePacked(
                hex'ff',
                factory,
                keccak256(abi.encodePacked(token0, token1)),
                hex'96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f' // init code hash
            )))));
    }

    // fetches and sorts the reserves for a pair
    function getReserves(address factory, address tokenA, address tokenB) internal view returns (uint reserveA, uint reserveB) {
        (address token0,) = sortTokens(tokenA, tokenB);
        (uint reserve0, uint reserve1,) = IUniswapV2Pair(pairFor(factory, tokenA, tokenB)).getReserves();
        (reserveA, reserveB) = tokenA == token0 ? (reserve0, reserve1) : (reserve1, reserve0);
    }

    // given some amount of an asset and pair reserves, returns an equivalent amount of the other asset
    function quote(uint amountA, uint reserveA, uint reserveB) internal pure returns (uint amountB) {
        require(amountA > 0, 'UniswapV2Library: INSUFFICIENT_AMOUNT');
        require(reserveA > 0 && reserveB > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY');
        amountB = amountA.mul(reserveB) / reserveA;
    }

    // given an input amount of an asset and pair reserves, returns the maximum output amount of the other asset
    function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) internal pure returns (uint amountOut) {
        require(amountIn > 0, 'UniswapV2Library: INSUFFICIENT_INPUT_AMOUNT');
        require(reserveIn > 0 && reserveOut > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY');
        uint amountInWithFee = amountIn.mul(997);
        uint numerator = amountInWithFee.mul(reserveOut);
        uint denominator = reserveIn.mul(1000).add(amountInWithFee);
        amountOut = numerator / denominator;
    }

    // given an output amount of an asset and pair reserves, returns a required input amount of the other asset
    function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) internal pure returns (uint amountIn) {
        require(amountOut > 0, 'UniswapV2Library: INSUFFICIENT_OUTPUT_AMOUNT');
        require(reserveIn > 0 && reserveOut > 0, 'UniswapV2Library: INSUFFICIENT_LIQUIDITY');
        uint numerator = reserveIn.mul(amountOut).mul(1000);
        uint denominator = reserveOut.sub(amountOut).mul(997);
        amountIn = (numerator / denominator).add(1);
    }

    // performs chained getAmountOut calculations on any number of pairs
    function getAmountsOut(address factory, uint amountIn, address[] memory path) internal view returns (uint[] memory amounts) {
        require(path.length >= 2, 'UniswapV2Library: INVALID_PATH');
        amounts = new uint[](path.length);
        amounts[0] = amountIn;
        for (uint i; i < path.length - 1; i++) {
            (uint reserveIn, uint reserveOut) = getReserves(factory, path[i], path[i + 1]);
            amounts[i + 1] = getAmountOut(amounts[i], reserveIn, reserveOut);
        }
    }

    // performs chained getAmountIn calculations on any number of pairs
    function getAmountsIn(address factory, uint amountOut, address[] memory path) internal view returns (uint[] memory amounts) {
        require(path.length >= 2, 'UniswapV2Library: INVALID_PATH');
        amounts = new uint[](path.length);
        amounts[amounts.length - 1] = amountOut;
        for (uint i = path.length - 1; i > 0; i--) {
            (uint reserveIn, uint reserveOut) = getReserves(factory, path[i - 1], path[i]);
            amounts[i - 1] = getAmountIn(amounts[i], reserveIn, reserveOut);
        }
    }
}

File 8 of 14 : Ownable.sol
// SPDX-License-Identifier: AGPL-3.0

pragma solidity ^0.8.0;

import "@openzeppelin/contracts/utils/Context.sol";

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

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

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

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

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

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

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

File 9 of 14 : SafeMath.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol)

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // 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 (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @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) {
        return a + b;
    }

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

    /**
     * @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) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting 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 a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(
        uint256 a,
        uint256 b,
        string memory errorMessage
    ) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting 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) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * 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) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

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

pragma solidity ^0.8.0;

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

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

File 11 of 14 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 12 of 14 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.sol";
import "../../../utils/Address.sol";

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

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

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

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

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

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

    function safePermit(
        IERC20Permit token,
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal {
        uint256 nonceBefore = token.nonces(owner);
        token.permit(owner, spender, value, deadline, v, r, s);
        uint256 nonceAfter = token.nonces(owner);
        require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
    }

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

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

File 13 of 14 : draft-IERC20Permit.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
 * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
 *
 * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
 * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
 * need to send a transaction, and thus is not required to hold Ether at all.
 */
interface IERC20Permit {
    /**
     * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
     * given ``owner``'s signed approval.
     *
     * IMPORTANT: The same issues {IERC20-approve} has related to transaction
     * ordering also apply here.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `deadline` must be a timestamp in the future.
     * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
     * over the EIP712-formatted function arguments.
     * - the signature must use ``owner``'s current nonce (see {nonces}).
     *
     * For more information on the signature format, see the
     * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
     * section].
     */
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;

    /**
     * @dev Returns the current nonce for `owner`. This value must be
     * included whenever a signature is generated for {permit}.
     *
     * Every successful call to {permit} increases ``owner``'s nonce by one. This
     * prevents a signature from being used multiple times.
     */
    function nonces(address owner) external view returns (uint256);

    /**
     * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
     */
    // solhint-disable-next-line func-name-mixedcase
    function DOMAIN_SEPARATOR() external view returns (bytes32);
}

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

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

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

    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

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

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

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

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

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

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_feeCollector","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amountOut","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"LOG_AGG_SWAP","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"FEE_DENOMINATOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"O3Wrapper","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WETH","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"aggregatorFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"feeCollector","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"rescueFund","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"setAggregatorFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_factory","type":"address"}],"name":"setFactory","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeCollector","type":"address"}],"name":"setFeeCollector","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_wrapper","type":"address"}],"name":"setO3Wrapper","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_weth","type":"address"}],"name":"setWETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"swapAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"swapExactETHForTokensSupportingFeeOnTransferTokens","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"swapAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"uint256","name":"fee","type":"uint256"},{"internalType":"address","name":"poolAddress","type":"address"},{"internalType":"address","name":"tokenTo","type":"address"},{"internalType":"uint256","name":"minDy","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint64","name":"toChainId","type":"uint64"},{"internalType":"bytes","name":"toAddress","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"}],"name":"swapExactETHForTokensSupportingFeeOnTransferTokensCrossChain","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"address","name":"poolAddress","type":"address"},{"internalType":"uint256","name":"poolAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint256","name":"aggSwapAmountOutMin","type":"uint256"},{"internalType":"bool","name":"unwrapETH","type":"bool"}],"name":"swapExactPTokensForTokensSupportingFeeOnTransferTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"swapAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"swapExactTokensForETHSupportingFeeOnTransferTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"swapAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"deadline","type":"uint256"}],"name":"swapExactTokensForTokensSupportingFeeOnTransferTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amountIn","type":"uint256"},{"internalType":"uint256","name":"swapAmountOutMin","type":"uint256"},{"internalType":"address[]","name":"path","type":"address[]"},{"internalType":"address","name":"poolAddress","type":"address"},{"internalType":"address","name":"tokenTo","type":"address"},{"internalType":"uint256","name":"minDy","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint64","name":"toChainId","type":"uint64"},{"internalType":"bytes","name":"toAddress","type":"bytes"},{"internalType":"bytes","name":"callData","type":"bytes"}],"name":"swapExactTokensForTokensSupportingFeeOnTransferTokensCrossChain","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

6080604052600180546001600160a01b031990811673c02aaa39b223fe8d0a0e5c4f27ead9083c756cc217909155600280548216735c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f1790556003805490911673ecf2b548e5c21028b0b60363207700fa421b6ecb1790556301c9c3806005553480156200007f57600080fd5b506040516200407638038062004076833981016040819052620000a29162000123565b620000ad33620000d3565b600480546001600160a01b0319166001600160a01b039290921691909117905562000155565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000602082840312156200013657600080fd5b81516001600160a01b03811681146200014e57600080fd5b9392505050565b613f1180620001656000396000f3fe6080604052600436106101635760003560e01c8063a42dce80116100c0578063c45a015511610074578063d73792a911610059578063d73792a9146103d6578063e6a8400f146103ef578063f2fde38b1461041c57600080fd5b8063c45a015514610389578063c6cc8294146103b657600080fd5b8063b6f9de95116100a5578063b6f9de9514610329578063b8c6fd841461033c578063c415b95c1461035c57600080fd5b8063a42dce80146102dc578063ad5c4648146102fc57600080fd5b80635c11d79511610117578063791ac947116100fc578063791ac9471461024c5780638da5cb5b1461026c5780639ed5b4dd146102b857600080fd5b80635c11d7951461020c5780636ab0adea1461022c57600080fd5b8063431c31f411610148578063431c31f4146101b95780635b769f3c146101cc5780635bb47808146101ec57600080fd5b806302bd96031461016f578063355466c81461019757600080fd5b3661016a57005b600080fd5b61018261017d3660046137ff565b61043c565b60405190151581526020015b60405180910390f35b3480156101a357600080fd5b506101b76101b23660046138ee565b6105ab565b005b6101826101c7366004613907565b61069e565b3480156101d857600080fd5b506101b76101e736600461396f565b6107b2565b3480156101f857600080fd5b506101b761020736600461396f565b61087a565b34801561021857600080fd5b506101b761022736600461398c565b610942565b34801561023857600080fd5b506101b761024736600461396f565b610ab3565b34801561025857600080fd5b506101b761026736600461398c565b610b7b565b34801561027857600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b3480156102c457600080fd5b506102ce60055481565b60405190815260200161018e565b3480156102e857600080fd5b506101b76102f736600461396f565b610d0d565b34801561030857600080fd5b506001546102939073ffffffffffffffffffffffffffffffffffffffff1681565b6101b76103373660046139ff565b610dd5565b34801561034857600080fd5b506101b761035736600461396f565b610ef0565b34801561036857600080fd5b506004546102939073ffffffffffffffffffffffffffffffffffffffff1681565b34801561039557600080fd5b506002546102939073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103c257600080fd5b506101b76103d1366004613a74565b611126565b3480156103e257600080fd5b506102ce6402540be40081565b3480156103fb57600080fd5b506003546102939073ffffffffffffffffffffffffffffffffffffffff1681565b34801561042857600080fd5b506101b761043736600461396f565b6118fc565b600084428110156104ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064015b60405180910390fd5b6000806104bd8f8f8f8f611a2c565b60035491935091506104e99073ffffffffffffffffffffffffffffffffffffffff808416911684611b10565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166319ccecbe8d8d848e878f8f8f8f8f6040518b63ffffffff1660e01b815260040161055599989796959493929190613b8d565b60206040518083038185885af1158015610573573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906105989190613c16565b9f9e505050505050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461062c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b631dcd65008110610699576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61676772656761746f72206665652065786365656473206d6178696d756d000060448201526064016104a5565b600555565b6000844281101561070b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b60008061071a8f8f8f8f611d15565b60035491935091506107469073ffffffffffffffffffffffffffffffffffffffff808416911684611b10565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166319ccecbe348d848e878f8f8f8f8f6040518b63ffffffff1660e01b815260040161055599989796959493929190613b8d565b60005473ffffffffffffffffffffffffffffffffffffffff163314610833576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60005473ffffffffffffffffffffffffffffffffffffffff1633146108fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b80428110156109ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b60006109bd600189898989611dc8565b905060006109e56402540be4006109df6005548561213b90919063ffffffff16565b9061214e565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1600454610a8d9073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b818110610a5b57610a5b613c79565b9050602002016020810190610a70919061396f565b73ffffffffffffffffffffffffffffffffffffffff16919061215a565b610aa885610a9b84846121b0565b8989610a4c600182613c62565b505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b34576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8042811015610be6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b6000610bf4888888886121bc565b90506000610c166402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a16001546040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff90911690632e1a7d4d90602401600060405180830381600087803b158015610cbe57600080fd5b505af1158015610cd2573d6000803e3d6000fd5b5050600454610cfa925073ffffffffffffffffffffffffffffffffffffffff1690508261248b565b610aa885610d0884846121b0565b61248b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610d8e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8042811015610e40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b6000610e4f8787876000612595565b90506000610e716402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1600454610ed89073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b610ee685610a9b84846121b0565b5050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f71576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600154819073ffffffffffffffffffffffffffffffffffffffff8083169116148015610f9d5750600047115b15611072576040805160008082526020820190925233904790604051610fc39190613ca8565b60006040518083038185875af1925050503d8060008114611000576040519150601f19603f3d011682016040523d82523d6000602084013e611005565b606091505b5050905080611070576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4554485f5452414e534645525f4641494c45440000000000000000000000000060448201526064016104a5565b505b611122336040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff8416906370a0823190602401602060405180830381865afa1580156110e0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111049190613cc4565b73ffffffffffffffffffffffffffffffffffffffff8416919061215a565b5050565b8242811015611191576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b8960000361127357868660008181106111ac576111ac613c79565b90506020020160208101906111c1919061396f565b73ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e336040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152306024820152604401602060405180830381865afa15801561124c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112709190613cc4565b99505b896000036112dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4f3341676772656761746f723a205a45524f5f414d4f554e545f494e0000000060448201526064016104a5565b61132933308c8a8a60008181106112f6576112f6613c79565b905060200201602081019061130b919061396f565b73ffffffffffffffffffffffffffffffffffffffff16929190612a21565b611373898b8989600081811061134157611341613c79565b9050602002016020810190611356919061396f565b73ffffffffffffffffffffffffffffffffffffffff169190611b10565b6040517fc66106570000000000000000000000000000000000000000000000000000000081526000600482018190529073ffffffffffffffffffffffffffffffffffffffff8b169063c661065790602401602060405180830381865afa1580156113e1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114059190613cdd565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290915060009073ffffffffffffffffffffffffffffffffffffffff8316906370a0823190602401602060405180830381865afa158015611475573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114999190613cc4565b6040517f916955860000000000000000000000000000000000000000000000000000000081526001600482015260006024820152604481018e9052606481018c90526084810188905290915073ffffffffffffffffffffffffffffffffffffffff8c169063916955869060a4016020604051808303816000875af1158015611525573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115499190613cc4565b506040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152819073ffffffffffffffffffffffffffffffffffffffff8416906370a0823190602401602060405180830381865afa1580156115b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115da9190613cc4565b6115e49190613c62565b9b50888860018181106115f9576115f9613c79565b905060200201602081019061160e919061396f565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16146116a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b50600090506116bf818c866116ba8b6001818f613cfa565b611dc8565b905060006116e16402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a183156118a8576001805473ffffffffffffffffffffffffffffffffffffffff16908a908a9061174c9082613c62565b81811061175b5761175b613c79565b9050602002016020810190611770919061396f565b73ffffffffffffffffffffffffffffffffffffffff16146117ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b6001546040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff90911690632e1a7d4d90602401600060405180830381600087803b15801561185957600080fd5b505af115801561186d573d6000803e3d6000fd5b5050600454611895925073ffffffffffffffffffffffffffffffffffffffff1690508261248b565b6118a387610d0884846121b0565b6118ee565b6004546118d39073ffffffffffffffffffffffffffffffffffffffff16828b8b610a4c600182613c62565b6118ee876118e184846121b0565b8b8b610a4c600182613c62565b505050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461197d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b73ffffffffffffffffffffffffffffffffffffffff8116611a20576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016104a5565b611a2981612a85565b50565b6000806000611a3d87878787612595565b90506000611a5f6402540be4006109df6005548561213b90919063ffffffff16565b600454909150611a8d9073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b60408051838152602081018390527f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1611ad082826121b0565b8787611add600182613c62565b818110611aec57611aec613c79565b9050602002016020810190611b01919061396f565b93509350505094509492505050565b801580611bb057506040517fdd62ed3e00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff838116602483015284169063dd62ed3e90604401602060405180830381865afa158015611b8a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bae9190613cc4565b155b611c3c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60448201527f20746f206e6f6e2d7a65726f20616c6c6f77616e63650000000000000000000060648201526084016104a5565b60405173ffffffffffffffffffffffffffffffffffffffff8316602482015260448101829052611d109084907f095ea7b300000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152612afa565b505050565b6000806000611d28600188888888611dc8565b90506000611d4a6402540be4006109df6005548561213b90919063ffffffff16565b600454909150611d789073ffffffffffffffffffffffffffffffffffffffff16828888610a4c600182613c62565b60408051838152602081018390527f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1611dbb82826121b0565b8686611add600182613c62565b60008515611e5f57600254611e5a903390611e469073ffffffffffffffffffffffffffffffffffffffff168686600081611e0457611e04613c79565b9050602002016020810190611e19919061396f565b87876001818110611e2c57611e2c613c79565b9050602002016020810190611e41919061396f565b612c06565b87868660008181106112f6576112f6613c79565b611ecd565b600254611ecd90611eb99073ffffffffffffffffffffffffffffffffffffffff168585600081611e9157611e91613c79565b9050602002016020810190611ea6919061396f565b86866001818110611e2c57611e2c613c79565b8685856000818110610a5b57610a5b613c79565b60008383611edc600182613c62565b818110611eeb57611eeb613c79565b9050602002016020810190611f00919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a0823190602401602060405180830381865afa158015611f6c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f909190613cc4565b9050611fd0848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b600061209e828686611fe3600182613c62565b818110611ff257611ff2613c79565b9050602002016020810190612007919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a08231906024015b602060405180830381865afa158015612074573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120989190613cc4565b906121b0565b905085811015612130576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b979650505050505050565b60006121478284613d28565b9392505050565b60006121478284613d65565b60405173ffffffffffffffffffffffffffffffffffffffff8316602482015260448101829052611d109084907fa9059cbb0000000000000000000000000000000000000000000000000000000090606401611c8e565b60006121478284613c62565b6001805460009173ffffffffffffffffffffffffffffffffffffffff90911690849084906121ea9082613c62565b8181106121f9576121f9613c79565b905060200201602081019061220e919061396f565b73ffffffffffffffffffffffffffffffffffffffff161461228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b6002546122bf903390611e469073ffffffffffffffffffffffffffffffffffffffff168686600081611e0457611e04613c79565b6001546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561232e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123529190613cc4565b9050612392848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b6001546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916123ef91849173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401612057565b905085811015612481576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b9695505050505050565b6040805160008082526020820190925273ffffffffffffffffffffffffffffffffffffffff84169083906040516124c29190613ca8565b60006040518083038185875af1925050503d80600081146124ff576040519150601f19603f3d011682016040523d82523d6000602084013e612504565b606091505b5050905080611d10576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4f3341676772656761746f723a204554485f5452414e534645525f4641494c4560448201527f440000000000000000000000000000000000000000000000000000000000000060648201526084016104a5565b60015460009073ffffffffffffffffffffffffffffffffffffffff16848483816125c1576125c1613c79565b90506020020160208101906125d6919061396f565b73ffffffffffffffffffffffffffffffffffffffff1614612653576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b600061265f34846121b0565b9050600081116126f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f4f3341676772656761746f723a20494e53554646494349454e545f494e50555460448201527f5f414d4f554e540000000000000000000000000000000000000000000000000060648201526084016104a5565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561275b57600080fd5b505af115801561276f573d6000803e3d6000fd5b505060015460025473ffffffffffffffffffffffffffffffffffffffff918216945063a9059cbb93506127d792501688886000816127af576127af613c79565b90506020020160208101906127c4919061396f565b89896001818110611e2c57611e2c613c79565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af1158015612849573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061286d9190613c16565b61287957612879613da0565b60008585612888600182613c62565b81811061289757612897613c79565b90506020020160208101906128ac919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a0823190602401602060405180830381865afa158015612918573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061293c9190613cc4565b905061297c868680806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b600061298f828888611fe3600182613c62565b905087811015612130576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b60405173ffffffffffffffffffffffffffffffffffffffff80851660248301528316604482015260648101829052612a7f9085907f23b872dd0000000000000000000000000000000000000000000000000000000090608401611c8e565b50505050565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000612b5c826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166131a29092919063ffffffff16565b805190915015611d105780806020019051810190612b7a9190613c16565b611d10576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016104a5565b6000806000612c1585856131b9565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201529193509150869060480160405160208183030381529060405280519060200120604051602001612cfb9291907fff00000000000000000000000000000000000000000000000000000000000000815260609290921b7fffffffffffffffffffffffffffffffffffffffff00000000000000000000000016600183015260158201527f96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f603582015260550190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101209695505050505050565b60005b60018351612d4c9190613c62565b811015611d1057600080848381518110612d6857612d68613c79565b602002602001015185846001612d7e9190613dcf565b81518110612d8e57612d8e613c79565b6020026020010151915091506000612da683836131b9565b506002546040517fe6a4390500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015285811660248301529293506000929091169063e6a4390590604401602060405180830381865afa158015612e25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e499190613cdd565b73ffffffffffffffffffffffffffffffffffffffff1603612ec6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4f3341676772656761746f723a20504149525f4e4f545f45584953540000000060448201526064016104a5565b600254600090612eed9073ffffffffffffffffffffffffffffffffffffffff168585612c06565b90506000806000808473ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b8152600401606060405180830381865afa158015612f40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f649190613e05565b506dffffffffffffffffffffffffffff1691506dffffffffffffffffffffffffffff1691506000808773ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff1614612fc6578284612fc9565b83835b6040517f70a0823100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a8116600483015292945090925061302a918491908d16906370a0823190602401612057565b955061303786838361333d565b9450505050506000808573ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff161461307b5782600061307f565b6000835b91509150600060028c516130939190613c62565b8a1061309f578a6130ec565b600280546130ec9173ffffffffffffffffffffffffffffffffffffffff909116908a908f906130cf908f90613dcf565b815181106130df576130df613c79565b6020026020010151612c06565b604080516000815260208101918290527f022c0d9f0000000000000000000000000000000000000000000000000000000090915290915073ffffffffffffffffffffffffffffffffffffffff87169063022c0d9f906131549086908690869060248101613e55565b600060405180830381600087803b15801561316e57600080fd5b505af1158015613182573d6000803e3d6000fd5b50505050505050505050505050808061319a90613e90565b915050612d3e565b60606131b184846000856134ac565b949350505050565b6000808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1603613277576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f556e697377617056324c6962726172793a204944454e544943414c5f4144445260448201527f455353455300000000000000000000000000000000000000000000000000000060648201526084016104a5565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16106132b15782846132b4565b83835b909250905073ffffffffffffffffffffffffffffffffffffffff8216613336576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f556e697377617056324c6962726172793a205a45524f5f41444452455353000060448201526064016104a5565b9250929050565b60008084116133ce576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f556e697377617056324c6962726172793a20494e53554646494349454e545f4960448201527f4e5055545f414d4f554e5400000000000000000000000000000000000000000060648201526084016104a5565b6000831180156133de5750600082115b61346a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f556e697377617056324c6962726172793a20494e53554646494349454e545f4c60448201527f495155494449545900000000000000000000000000000000000000000000000060648201526084016104a5565b6000613478856103e561213b565b90506000613486828561213b565b905060006134a08361349a886103e861213b565b90613637565b90506121308183613d65565b60608247101561353e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016104a5565b73ffffffffffffffffffffffffffffffffffffffff85163b6135bc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016104a5565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516135e59190613ca8565b60006040518083038185875af1925050503d8060008114613622576040519150601f19603f3d011682016040523d82523d6000602084013e613627565b606091505b5091509150612130828286613643565b60006121478284613dcf565b60608315613652575081612147565b8251156136625782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104a59190613ec8565b60008083601f8401126136a857600080fd5b50813567ffffffffffffffff8111156136c057600080fd5b6020830191508360208260051b850101111561333657600080fd5b73ffffffffffffffffffffffffffffffffffffffff81168114611a2957600080fd5b8035613708816136db565b919050565b803567ffffffffffffffff8116811461370857600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f83011261376557600080fd5b813567ffffffffffffffff8082111561378057613780613725565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019082821181831017156137c6576137c6613725565b816040528381528660208588010111156137df57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008060008060008060008060008060006101408c8e03121561382157600080fd5b8b359a5067ffffffffffffffff8060208e0135111561383f57600080fd5b61384f8e60208f01358f01613696565b909b50995060408d0135985061386760608e016136fd565b975061387560808e016136fd565b965060a08d0135955060c08d0135945061389160e08e0161370d565b9350806101008e013511156138a557600080fd5b6138b68e6101008f01358f01613754565b9250806101208e013511156138ca57600080fd5b506138dc8d6101208e01358e01613754565b90509295989b509295989b9093969950565b60006020828403121561390057600080fd5b5035919050565b60008060008060008060008060008060006101408c8e03121561392957600080fd5b8b359a5060208c0135995067ffffffffffffffff8060408e0135111561394e57600080fd5b61395e8e60408f01358f01613696565b909a50985061386760608e016136fd565b60006020828403121561398157600080fd5b8135612147816136db565b60008060008060008060a087890312156139a557600080fd5b8635955060208701359450604087013567ffffffffffffffff8111156139ca57600080fd5b6139d689828a01613696565b90955093505060608701356139ea816136db565b80925050608087013590509295509295509295565b600080600080600060808688031215613a1757600080fd5b85359450602086013567ffffffffffffffff811115613a3557600080fd5b613a4188828901613696565b9095509350506040860135613a55816136db565b949793965091946060013592915050565b8015158114611a2957600080fd5b60008060008060008060008060006101008a8c031215613a9357600080fd5b8935985060208a0135613aa5816136db565b975060408a0135965060608a013567ffffffffffffffff811115613ac857600080fd5b613ad48c828d01613696565b90975095505060808a0135613ae8816136db565b935060a08a0135925060c08a0135915060e08a0135613b0681613a66565b809150509295985092959850929598565b60005b83811015613b32578181015183820152602001613b1a565b83811115612a7f5750506000910152565b60008151808452613b5b816020860160208601613b17565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600061012073ffffffffffffffffffffffffffffffffffffffff808d168452808c166020850152808b166040850152508860608401528760808401528660a084015267ffffffffffffffff861660c08401528060e0840152613bf181840186613b43565b9050828103610100840152613c068185613b43565b9c9b505050505050505050505050565b600060208284031215613c2857600080fd5b815161214781613a66565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015613c7457613c74613c33565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251613cba818460208701613b17565b9190910192915050565b600060208284031215613cd657600080fd5b5051919050565b600060208284031215613cef57600080fd5b8151612147816136db565b60008085851115613d0a57600080fd5b83861115613d1757600080fd5b5050600583901b0193919092039150565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613d6057613d60613c33565b500290565b600082613d9b577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b60008219821115613de257613de2613c33565b500190565b80516dffffffffffffffffffffffffffff8116811461370857600080fd5b600080600060608486031215613e1a57600080fd5b613e2384613de7565b9250613e3160208501613de7565b9150604084015163ffffffff81168114613e4a57600080fd5b809150509250925092565b84815283602082015273ffffffffffffffffffffffffffffffffffffffff831660408201526080606082015260006124816080830184613b43565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613ec157613ec1613c33565b5060010190565b6020815260006121476020830184613b4356fea2646970667358221220b98d6939a4f599e941752f329986fbd2dd5cd0252c539e91a4a2bde973111ab864736f6c634300080f0033000000000000000000000000462edbe0c6d505b96556b63fe3b593078f90e0fc

Deployed Bytecode

0x6080604052600436106101635760003560e01c8063a42dce80116100c0578063c45a015511610074578063d73792a911610059578063d73792a9146103d6578063e6a8400f146103ef578063f2fde38b1461041c57600080fd5b8063c45a015514610389578063c6cc8294146103b657600080fd5b8063b6f9de95116100a5578063b6f9de9514610329578063b8c6fd841461033c578063c415b95c1461035c57600080fd5b8063a42dce80146102dc578063ad5c4648146102fc57600080fd5b80635c11d79511610117578063791ac947116100fc578063791ac9471461024c5780638da5cb5b1461026c5780639ed5b4dd146102b857600080fd5b80635c11d7951461020c5780636ab0adea1461022c57600080fd5b8063431c31f411610148578063431c31f4146101b95780635b769f3c146101cc5780635bb47808146101ec57600080fd5b806302bd96031461016f578063355466c81461019757600080fd5b3661016a57005b600080fd5b61018261017d3660046137ff565b61043c565b60405190151581526020015b60405180910390f35b3480156101a357600080fd5b506101b76101b23660046138ee565b6105ab565b005b6101826101c7366004613907565b61069e565b3480156101d857600080fd5b506101b76101e736600461396f565b6107b2565b3480156101f857600080fd5b506101b761020736600461396f565b61087a565b34801561021857600080fd5b506101b761022736600461398c565b610942565b34801561023857600080fd5b506101b761024736600461396f565b610ab3565b34801561025857600080fd5b506101b761026736600461398c565b610b7b565b34801561027857600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b3480156102c457600080fd5b506102ce60055481565b60405190815260200161018e565b3480156102e857600080fd5b506101b76102f736600461396f565b610d0d565b34801561030857600080fd5b506001546102939073ffffffffffffffffffffffffffffffffffffffff1681565b6101b76103373660046139ff565b610dd5565b34801561034857600080fd5b506101b761035736600461396f565b610ef0565b34801561036857600080fd5b506004546102939073ffffffffffffffffffffffffffffffffffffffff1681565b34801561039557600080fd5b506002546102939073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103c257600080fd5b506101b76103d1366004613a74565b611126565b3480156103e257600080fd5b506102ce6402540be40081565b3480156103fb57600080fd5b506003546102939073ffffffffffffffffffffffffffffffffffffffff1681565b34801561042857600080fd5b506101b761043736600461396f565b6118fc565b600084428110156104ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064015b60405180910390fd5b6000806104bd8f8f8f8f611a2c565b60035491935091506104e99073ffffffffffffffffffffffffffffffffffffffff808416911684611b10565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166319ccecbe8d8d848e878f8f8f8f8f6040518b63ffffffff1660e01b815260040161055599989796959493929190613b8d565b60206040518083038185885af1158015610573573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906105989190613c16565b9f9e505050505050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461062c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b631dcd65008110610699576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61676772656761746f72206665652065786365656473206d6178696d756d000060448201526064016104a5565b600555565b6000844281101561070b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b60008061071a8f8f8f8f611d15565b60035491935091506107469073ffffffffffffffffffffffffffffffffffffffff808416911684611b10565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166319ccecbe348d848e878f8f8f8f8f6040518b63ffffffff1660e01b815260040161055599989796959493929190613b8d565b60005473ffffffffffffffffffffffffffffffffffffffff163314610833576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60005473ffffffffffffffffffffffffffffffffffffffff1633146108fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b80428110156109ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b60006109bd600189898989611dc8565b905060006109e56402540be4006109df6005548561213b90919063ffffffff16565b9061214e565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1600454610a8d9073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b818110610a5b57610a5b613c79565b9050602002016020810190610a70919061396f565b73ffffffffffffffffffffffffffffffffffffffff16919061215a565b610aa885610a9b84846121b0565b8989610a4c600182613c62565b505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b34576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8042811015610be6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b6000610bf4888888886121bc565b90506000610c166402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a16001546040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff90911690632e1a7d4d90602401600060405180830381600087803b158015610cbe57600080fd5b505af1158015610cd2573d6000803e3d6000fd5b5050600454610cfa925073ffffffffffffffffffffffffffffffffffffffff1690508261248b565b610aa885610d0884846121b0565b61248b565b60005473ffffffffffffffffffffffffffffffffffffffff163314610d8e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8042811015610e40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b6000610e4f8787876000612595565b90506000610e716402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1600454610ed89073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b610ee685610a9b84846121b0565b5050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f71576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b600154819073ffffffffffffffffffffffffffffffffffffffff8083169116148015610f9d5750600047115b15611072576040805160008082526020820190925233904790604051610fc39190613ca8565b60006040518083038185875af1925050503d8060008114611000576040519150601f19603f3d011682016040523d82523d6000602084013e611005565b606091505b5050905080611070576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4554485f5452414e534645525f4641494c45440000000000000000000000000060448201526064016104a5565b505b611122336040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff8416906370a0823190602401602060405180830381865afa1580156110e0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111049190613cc4565b73ffffffffffffffffffffffffffffffffffffffff8416919061215a565b5050565b8242811015611191576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4f3341676772656761746f723a2045585049524544000000000000000000000060448201526064016104a5565b8960000361127357868660008181106111ac576111ac613c79565b90506020020160208101906111c1919061396f565b73ffffffffffffffffffffffffffffffffffffffff1663dd62ed3e336040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152306024820152604401602060405180830381865afa15801561124c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112709190613cc4565b99505b896000036112dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4f3341676772656761746f723a205a45524f5f414d4f554e545f494e0000000060448201526064016104a5565b61132933308c8a8a60008181106112f6576112f6613c79565b905060200201602081019061130b919061396f565b73ffffffffffffffffffffffffffffffffffffffff16929190612a21565b611373898b8989600081811061134157611341613c79565b9050602002016020810190611356919061396f565b73ffffffffffffffffffffffffffffffffffffffff169190611b10565b6040517fc66106570000000000000000000000000000000000000000000000000000000081526000600482018190529073ffffffffffffffffffffffffffffffffffffffff8b169063c661065790602401602060405180830381865afa1580156113e1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114059190613cdd565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290915060009073ffffffffffffffffffffffffffffffffffffffff8316906370a0823190602401602060405180830381865afa158015611475573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114999190613cc4565b6040517f916955860000000000000000000000000000000000000000000000000000000081526001600482015260006024820152604481018e9052606481018c90526084810188905290915073ffffffffffffffffffffffffffffffffffffffff8c169063916955869060a4016020604051808303816000875af1158015611525573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115499190613cc4565b506040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152819073ffffffffffffffffffffffffffffffffffffffff8416906370a0823190602401602060405180830381865afa1580156115b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115da9190613cc4565b6115e49190613c62565b9b50888860018181106115f9576115f9613c79565b905060200201602081019061160e919061396f565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16146116a2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b50600090506116bf818c866116ba8b6001818f613cfa565b611dc8565b905060006116e16402540be4006109df6005548561213b90919063ffffffff16565b60408051848152602081018390529192507f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a183156118a8576001805473ffffffffffffffffffffffffffffffffffffffff16908a908a9061174c9082613c62565b81811061175b5761175b613c79565b9050602002016020810190611770919061396f565b73ffffffffffffffffffffffffffffffffffffffff16146117ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b6001546040517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff90911690632e1a7d4d90602401600060405180830381600087803b15801561185957600080fd5b505af115801561186d573d6000803e3d6000fd5b5050600454611895925073ffffffffffffffffffffffffffffffffffffffff1690508261248b565b6118a387610d0884846121b0565b6118ee565b6004546118d39073ffffffffffffffffffffffffffffffffffffffff16828b8b610a4c600182613c62565b6118ee876118e184846121b0565b8b8b610a4c600182613c62565b505050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461197d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104a5565b73ffffffffffffffffffffffffffffffffffffffff8116611a20576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016104a5565b611a2981612a85565b50565b6000806000611a3d87878787612595565b90506000611a5f6402540be4006109df6005548561213b90919063ffffffff16565b600454909150611a8d9073ffffffffffffffffffffffffffffffffffffffff16828989610a4c600182613c62565b60408051838152602081018390527f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1611ad082826121b0565b8787611add600182613c62565b818110611aec57611aec613c79565b9050602002016020810190611b01919061396f565b93509350505094509492505050565b801580611bb057506040517fdd62ed3e00000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff838116602483015284169063dd62ed3e90604401602060405180830381865afa158015611b8a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bae9190613cc4565b155b611c3c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60448201527f20746f206e6f6e2d7a65726f20616c6c6f77616e63650000000000000000000060648201526084016104a5565b60405173ffffffffffffffffffffffffffffffffffffffff8316602482015260448101829052611d109084907f095ea7b300000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152612afa565b505050565b6000806000611d28600188888888611dc8565b90506000611d4a6402540be4006109df6005548561213b90919063ffffffff16565b600454909150611d789073ffffffffffffffffffffffffffffffffffffffff16828888610a4c600182613c62565b60408051838152602081018390527f270e06e1460fe9df2e798064a58fdb072e3f3e1e39e7db96268c13849c025aed910160405180910390a1611dbb82826121b0565b8686611add600182613c62565b60008515611e5f57600254611e5a903390611e469073ffffffffffffffffffffffffffffffffffffffff168686600081611e0457611e04613c79565b9050602002016020810190611e19919061396f565b87876001818110611e2c57611e2c613c79565b9050602002016020810190611e41919061396f565b612c06565b87868660008181106112f6576112f6613c79565b611ecd565b600254611ecd90611eb99073ffffffffffffffffffffffffffffffffffffffff168585600081611e9157611e91613c79565b9050602002016020810190611ea6919061396f565b86866001818110611e2c57611e2c613c79565b8685856000818110610a5b57610a5b613c79565b60008383611edc600182613c62565b818110611eeb57611eeb613c79565b9050602002016020810190611f00919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a0823190602401602060405180830381865afa158015611f6c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f909190613cc4565b9050611fd0848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b600061209e828686611fe3600182613c62565b818110611ff257611ff2613c79565b9050602002016020810190612007919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a08231906024015b602060405180830381865afa158015612074573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120989190613cc4565b906121b0565b905085811015612130576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b979650505050505050565b60006121478284613d28565b9392505050565b60006121478284613d65565b60405173ffffffffffffffffffffffffffffffffffffffff8316602482015260448101829052611d109084907fa9059cbb0000000000000000000000000000000000000000000000000000000090606401611c8e565b60006121478284613c62565b6001805460009173ffffffffffffffffffffffffffffffffffffffff90911690849084906121ea9082613c62565b8181106121f9576121f9613c79565b905060200201602081019061220e919061396f565b73ffffffffffffffffffffffffffffffffffffffff161461228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b6002546122bf903390611e469073ffffffffffffffffffffffffffffffffffffffff168686600081611e0457611e04613c79565b6001546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561232e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123529190613cc4565b9050612392848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b6001546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916123ef91849173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401612057565b905085811015612481576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b9695505050505050565b6040805160008082526020820190925273ffffffffffffffffffffffffffffffffffffffff84169083906040516124c29190613ca8565b60006040518083038185875af1925050503d80600081146124ff576040519150601f19603f3d011682016040523d82523d6000602084013e612504565b606091505b5050905080611d10576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4f3341676772656761746f723a204554485f5452414e534645525f4641494c4560448201527f440000000000000000000000000000000000000000000000000000000000000060648201526084016104a5565b60015460009073ffffffffffffffffffffffffffffffffffffffff16848483816125c1576125c1613c79565b90506020020160208101906125d6919061396f565b73ffffffffffffffffffffffffffffffffffffffff1614612653576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f4f3341676772656761746f723a20494e56414c49445f5041544800000000000060448201526064016104a5565b600061265f34846121b0565b9050600081116126f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602760248201527f4f3341676772656761746f723a20494e53554646494349454e545f494e50555460448201527f5f414d4f554e540000000000000000000000000000000000000000000000000060648201526084016104a5565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d0e30db0826040518263ffffffff1660e01b81526004016000604051808303818588803b15801561275b57600080fd5b505af115801561276f573d6000803e3d6000fd5b505060015460025473ffffffffffffffffffffffffffffffffffffffff918216945063a9059cbb93506127d792501688886000816127af576127af613c79565b90506020020160208101906127c4919061396f565b89896001818110611e2c57611e2c613c79565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af1158015612849573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061286d9190613c16565b61287957612879613da0565b60008585612888600182613c62565b81811061289757612897613c79565b90506020020160208101906128ac919061396f565b6040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015273ffffffffffffffffffffffffffffffffffffffff91909116906370a0823190602401602060405180830381865afa158015612918573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061293c9190613cc4565b905061297c868680806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250309250612d3b915050565b600061298f828888611fe3600182613c62565b905087811015612130576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4f3341676772656761746f723a20494e53554646494349454e545f4f5554505560448201527f545f414d4f554e5400000000000000000000000000000000000000000000000060648201526084016104a5565b60405173ffffffffffffffffffffffffffffffffffffffff80851660248301528316604482015260648101829052612a7f9085907f23b872dd0000000000000000000000000000000000000000000000000000000090608401611c8e565b50505050565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000612b5c826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166131a29092919063ffffffff16565b805190915015611d105780806020019051810190612b7a9190613c16565b611d10576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016104a5565b6000806000612c1585856131b9565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201529193509150869060480160405160208183030381529060405280519060200120604051602001612cfb9291907fff00000000000000000000000000000000000000000000000000000000000000815260609290921b7fffffffffffffffffffffffffffffffffffffffff00000000000000000000000016600183015260158201527f96e8ac4277198ff8b6f785478aa9a39f403cb768dd02cbee326c3e7da348845f603582015260550190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101209695505050505050565b60005b60018351612d4c9190613c62565b811015611d1057600080848381518110612d6857612d68613c79565b602002602001015185846001612d7e9190613dcf565b81518110612d8e57612d8e613c79565b6020026020010151915091506000612da683836131b9565b506002546040517fe6a4390500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015285811660248301529293506000929091169063e6a4390590604401602060405180830381865afa158015612e25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e499190613cdd565b73ffffffffffffffffffffffffffffffffffffffff1603612ec6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f4f3341676772656761746f723a20504149525f4e4f545f45584953540000000060448201526064016104a5565b600254600090612eed9073ffffffffffffffffffffffffffffffffffffffff168585612c06565b90506000806000808473ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b8152600401606060405180830381865afa158015612f40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f649190613e05565b506dffffffffffffffffffffffffffff1691506dffffffffffffffffffffffffffff1691506000808773ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff1614612fc6578284612fc9565b83835b6040517f70a0823100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a8116600483015292945090925061302a918491908d16906370a0823190602401612057565b955061303786838361333d565b9450505050506000808573ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff161461307b5782600061307f565b6000835b91509150600060028c516130939190613c62565b8a1061309f578a6130ec565b600280546130ec9173ffffffffffffffffffffffffffffffffffffffff909116908a908f906130cf908f90613dcf565b815181106130df576130df613c79565b6020026020010151612c06565b604080516000815260208101918290527f022c0d9f0000000000000000000000000000000000000000000000000000000090915290915073ffffffffffffffffffffffffffffffffffffffff87169063022c0d9f906131549086908690869060248101613e55565b600060405180830381600087803b15801561316e57600080fd5b505af1158015613182573d6000803e3d6000fd5b50505050505050505050505050808061319a90613e90565b915050612d3e565b60606131b184846000856134ac565b949350505050565b6000808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1603613277576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f556e697377617056324c6962726172793a204944454e544943414c5f4144445260448201527f455353455300000000000000000000000000000000000000000000000000000060648201526084016104a5565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16106132b15782846132b4565b83835b909250905073ffffffffffffffffffffffffffffffffffffffff8216613336576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f556e697377617056324c6962726172793a205a45524f5f41444452455353000060448201526064016104a5565b9250929050565b60008084116133ce576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f556e697377617056324c6962726172793a20494e53554646494349454e545f4960448201527f4e5055545f414d4f554e5400000000000000000000000000000000000000000060648201526084016104a5565b6000831180156133de5750600082115b61346a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f556e697377617056324c6962726172793a20494e53554646494349454e545f4c60448201527f495155494449545900000000000000000000000000000000000000000000000060648201526084016104a5565b6000613478856103e561213b565b90506000613486828561213b565b905060006134a08361349a886103e861213b565b90613637565b90506121308183613d65565b60608247101561353e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016104a5565b73ffffffffffffffffffffffffffffffffffffffff85163b6135bc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016104a5565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516135e59190613ca8565b60006040518083038185875af1925050503d8060008114613622576040519150601f19603f3d011682016040523d82523d6000602084013e613627565b606091505b5091509150612130828286613643565b60006121478284613dcf565b60608315613652575081612147565b8251156136625782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104a59190613ec8565b60008083601f8401126136a857600080fd5b50813567ffffffffffffffff8111156136c057600080fd5b6020830191508360208260051b850101111561333657600080fd5b73ffffffffffffffffffffffffffffffffffffffff81168114611a2957600080fd5b8035613708816136db565b919050565b803567ffffffffffffffff8116811461370857600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f83011261376557600080fd5b813567ffffffffffffffff8082111561378057613780613725565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019082821181831017156137c6576137c6613725565b816040528381528660208588010111156137df57600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008060008060008060008060008060006101408c8e03121561382157600080fd5b8b359a5067ffffffffffffffff8060208e0135111561383f57600080fd5b61384f8e60208f01358f01613696565b909b50995060408d0135985061386760608e016136fd565b975061387560808e016136fd565b965060a08d0135955060c08d0135945061389160e08e0161370d565b9350806101008e013511156138a557600080fd5b6138b68e6101008f01358f01613754565b9250806101208e013511156138ca57600080fd5b506138dc8d6101208e01358e01613754565b90509295989b509295989b9093969950565b60006020828403121561390057600080fd5b5035919050565b60008060008060008060008060008060006101408c8e03121561392957600080fd5b8b359a5060208c0135995067ffffffffffffffff8060408e0135111561394e57600080fd5b61395e8e60408f01358f01613696565b909a50985061386760608e016136fd565b60006020828403121561398157600080fd5b8135612147816136db565b60008060008060008060a087890312156139a557600080fd5b8635955060208701359450604087013567ffffffffffffffff8111156139ca57600080fd5b6139d689828a01613696565b90955093505060608701356139ea816136db565b80925050608087013590509295509295509295565b600080600080600060808688031215613a1757600080fd5b85359450602086013567ffffffffffffffff811115613a3557600080fd5b613a4188828901613696565b9095509350506040860135613a55816136db565b949793965091946060013592915050565b8015158114611a2957600080fd5b60008060008060008060008060006101008a8c031215613a9357600080fd5b8935985060208a0135613aa5816136db565b975060408a0135965060608a013567ffffffffffffffff811115613ac857600080fd5b613ad48c828d01613696565b90975095505060808a0135613ae8816136db565b935060a08a0135925060c08a0135915060e08a0135613b0681613a66565b809150509295985092959850929598565b60005b83811015613b32578181015183820152602001613b1a565b83811115612a7f5750506000910152565b60008151808452613b5b816020860160208601613b17565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600061012073ffffffffffffffffffffffffffffffffffffffff808d168452808c166020850152808b166040850152508860608401528760808401528660a084015267ffffffffffffffff861660c08401528060e0840152613bf181840186613b43565b9050828103610100840152613c068185613b43565b9c9b505050505050505050505050565b600060208284031215613c2857600080fd5b815161214781613a66565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015613c7457613c74613c33565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251613cba818460208701613b17565b9190910192915050565b600060208284031215613cd657600080fd5b5051919050565b600060208284031215613cef57600080fd5b8151612147816136db565b60008085851115613d0a57600080fd5b83861115613d1757600080fd5b5050600583901b0193919092039150565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613d6057613d60613c33565b500290565b600082613d9b577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b60008219821115613de257613de2613c33565b500190565b80516dffffffffffffffffffffffffffff8116811461370857600080fd5b600080600060608486031215613e1a57600080fd5b613e2384613de7565b9250613e3160208501613de7565b9150604084015163ffffffff81168114613e4a57600080fd5b809150509250925092565b84815283602082015273ffffffffffffffffffffffffffffffffffffffff831660408201526080606082015260006124816080830184613b43565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613ec157613ec1613c33565b5060010190565b6020815260006121476020830184613b4356fea2646970667358221220b98d6939a4f599e941752f329986fbd2dd5cd0252c539e91a4a2bde973111ab864736f6c634300080f0033

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

000000000000000000000000462edbe0c6d505b96556b63fe3b593078f90e0fc

-----Decoded View---------------
Arg [0] : _feeCollector (address): 0x462eDBe0C6d505b96556B63fE3b593078f90E0Fc

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000462edbe0c6d505b96556b63fe3b593078f90e0fc


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

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