MATIC Price: $0.99 (-3.06%)
Gas: 103 GWei
 

Overview

MATIC Balance

Polygon PoS Chain LogoPolygon PoS Chain LogoPolygon PoS Chain Logo0 MATIC

MATIC Value

$0.00

Sponsored

Transaction Hash
Method
Block
From
To
Value
0x60806040183306892021-08-24 3:59:32948 days ago1629777572IN
 Create: SwitchFarm
0 MATIC0.005059321

Parent Txn Hash Block From To Value
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
SwitchFarm

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 1000000 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 10 : SwitchFarm.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.12;

import "./interfaces/IERC20.sol";
import './interfaces/ISwitchTicketFactory.sol';
import './interfaces/ISwitchAcross.sol';
import './interfaces/IRewardToken.sol';
import './libraries/SafeMath.sol';
import './modules/Configable.sol';
import "./modules/ReentrancyGuard.sol";
import './modules/Pausable.sol';
import './modules/Initializable.sol';


// Have fun reading it. Hopefully it's bug-free. God bless.
contract SwitchFarm is Pausable, Configable, ReentrancyGuard, Initializable {
    using SafeMath for uint;

    // Info of each user.
    struct UserInfo {
        uint amount;         // How many tokens the user has provided.
        uint rewardDebt;     // Reward debt. See explanation below.
        uint earnDebt;     // Earn debt. See explanation below.
        //
        // We do some fancy math here. Basically, any point in time, the amount of RewardTokens
        // entitled to a user but is pending to be distributed is:
        //
        //   pending reward = (user.amount * pool.accRewardPerShare) - user.rewardDebt
        //
        // Whenever a user deposits or withdraws tokens to a pool. Here's what happens:
        //   1. The pool's `accRewardPerShare` (and `lastBlock`) gets updated.
        //   2. User receives the pending reward sent to his/her address.
        //   3. User's `amount` gets updated.
        //   4. User's `rewardDebt` gets updated.
    }

    // Info of each pool.
    struct PoolInfo {
        address depositToken;           // Address of LP token contract.
        address earnToken;
        uint allocPoint;       // How many allocation points assigned to this pool. RewardTokens to distribute per block.
        uint lastBlock;  // Last block number that RewardTokens distribution occurs.
        uint accRewardPerShare;   // Accumulated RewardTokens per share, times 1e18. See below.
        uint accEarnPerShare;   // Accumulated EarnTokens per share, times 1e18. See below.
        uint depositTokenSupply;
        uint16 depositFeeBP;      // Deposit fee in basis points
        bool paused;
    }

    uint public constant version = 1;
    address public ticketFactory;
    address public across;

    // The reward TOKEN!
    address public rewardToken;
    mapping(address => uint) public earnTokensTotal;
    uint public teamRewardRate;
    uint public teamEarnRate;
    
    // Dev address.
    address public team;
    // reward tokens created per block.
    uint public mintPerBlock;
    // Bonus muliplier for early rewardToken makers.
    uint public constant BONUS_MULTIPLIER = 1;
    // Deposit Fee address
    address public feeAddress;

    // Info of each pool.
    PoolInfo[] public poolInfo;
    // Info of each user that stakes tokens.
    mapping(uint => mapping(address => UserInfo)) public userInfo;
    // Total allocation points. Must be the sum of all allocation points in all pools.
    uint public totalAllocPoint;
    // The block number when reward token mining starts.
    uint public startBlock;

    event Deposit(address indexed user, address indexed to, uint indexed pid, uint amount, uint fee);
    event Withdraw(address indexed user, address indexed to, uint indexed pid, uint amount);
    event EmergencyWithdraw(address indexed user, address indexed to, uint indexed pid, uint amount);
    event SetFeeAddress(address indexed user, address indexed newAddress);
    event SetDevAddress(address indexed user, address indexed newAddress);
    event UpdateEmissionRate(address indexed user, uint mintPerBlock);
    event SetTeamRate(address indexed user, uint teamRewardRate, uint teamEarnRate);

    function initialize(
        address _ticketFactory,
        address _across,
        address _rewardToken,
        address _team,
        address _feeAddress,
        uint _mintPerBlock,
        uint _startBlock
    ) external initializer {
        require(_ticketFactory != address(0), 'zero address');
        owner = msg.sender;
        ticketFactory = _ticketFactory;
        across = _across;
        rewardToken = _rewardToken;
        team = _team;
        feeAddress = _feeAddress;
        mintPerBlock = _mintPerBlock;
        startBlock = _startBlock;
    }


    function configure(address _ticketFactory, address _across) external onlyDev {
        require(_ticketFactory != address(0), 'zero address');
        ticketFactory = _ticketFactory;
        across = _across;
    }

    function poolLength() external view returns (uint) {
        return poolInfo.length;
    }

    mapping(address => bool) public poolExistence;
    
    modifier nonDuplicated(address _depositToken) {
        require(poolExistence[_depositToken] == false, "nonDuplicated: duplicated");
        _;
    }

    modifier validatePoolByPid(uint _pid) {
        require (_pid < poolInfo.length , "Pool does not exist");
        _;
    }

    function pause() public onlyManager whenNotPaused {
        _pause();
    }

    function unpause() public onlyManager whenPaused {
        _unpause();
    }

    // Add a new lp to the pool. Can only be called by the owner.
    function add(bool _withUpdate, uint _allocPoint, address _depositToken, uint16 _depositFeeBP) public onlyDev nonDuplicated(_depositToken) {
        require(_depositFeeBP <= 10000, "add: invalid deposit fee basis points");
        address earnToken = ISwitchTicketFactory(ticketFactory).getTokenMap(_depositToken);
        if(_depositToken != rewardToken) {
            require(earnToken != address(0), "add: invalid deposit token");
        }
        if (_withUpdate) {
            massUpdatePools();
        }

        uint lastBlock = block.number > startBlock ? block.number : startBlock;
        totalAllocPoint = totalAllocPoint.add(_allocPoint);
        poolExistence[_depositToken] = true;
        poolInfo.push(PoolInfo({
            depositToken : _depositToken,
            earnToken: earnToken,
            allocPoint : _allocPoint,
            lastBlock : lastBlock,
            accRewardPerShare : 0,
            accEarnPerShare: 0,
            depositTokenSupply: 0,
            depositFeeBP : _depositFeeBP,
            paused: false
        }));
    }

    function batchAdd(bool _withUpdate, uint[] memory _allocPoints, address[] memory _depositTokens, uint16[] memory _depositFeeBPs) external onlyDev {
        require(_allocPoints.length == _depositTokens.length && _depositTokens.length == _depositFeeBPs.length, 'invalid params');
        if (_withUpdate) {
            massUpdatePools();
        }
        for(uint i; i<_allocPoints.length; i++) {
            add(false, _allocPoints[i], _depositTokens[i], _depositFeeBPs[i]);
        }
    }

    function set(bool _withUpdate, uint _pid, uint _allocPoint, uint16 _depositFeeBP, bool _paused) external validatePoolByPid(_pid) onlyManager {
        require(_depositFeeBP <= 10000, "depositFeeBP should be <=10000!");
        if (_withUpdate) {
            massUpdatePools();
        }
        totalAllocPoint = totalAllocPoint.sub(poolInfo[_pid].allocPoint).add(_allocPoint);
        poolInfo[_pid].allocPoint = _allocPoint;
        poolInfo[_pid].depositFeeBP = _depositFeeBP;
        poolInfo[_pid].paused = _paused;
    }

    function batchSetAllocPoint(uint[] memory _pids, uint[] memory _allocPoints) external onlyManager {
        require(_pids.length == _allocPoints.length, 'invalid params');
        massUpdatePools();
        for (uint i; i<_pids.length; i++) {
            totalAllocPoint = totalAllocPoint.sub(poolInfo[_pids[i]].allocPoint).add(_allocPoints[i]);
            poolInfo[_pids[i]].allocPoint = _allocPoints[i];
        }
    }

    function batchSetDepositFeeBP(uint[] memory _pids, uint16[] memory _depositFeeBPs) external onlyManager {
        require(_pids.length == _depositFeeBPs.length, 'invalid params');
        for (uint i; i<_pids.length; i++) {
            require(_depositFeeBPs[i] <= 10000, 'depositFeeBP should be <=10000!');
            poolInfo[_pids[i]].depositFeeBP = _depositFeeBPs[i];
        }
    }

    function batchSetPaused(uint[] memory _pids, bool[] memory _pauseds) external onlyManager {
        require(_pids.length == _pauseds.length, 'invalid params');
        for (uint i; i<_pids.length; i++) {
            poolInfo[_pids[i]].paused = _pauseds[i];
        }
    }

    // Return reward multiplier over the given _from to _to block.
    function getMultiplier(uint _from, uint _to) public view returns (uint) {
        return _to.sub(_from).mul(BONUS_MULTIPLIER);
    }

    function getToBlock() public view returns (uint) {
        return block.number;
    }

    function pendingRewardInfo(uint _pid) public view validatePoolByPid(_pid) returns (uint, uint, uint) {
        PoolInfo storage pool = poolInfo[_pid];
        if (rewardToken != address(0) && getToBlock() > pool.lastBlock && totalAllocPoint > 0) {
            uint multiplier = getMultiplier(pool.lastBlock, getToBlock());
            uint reward = multiplier.mul(mintPerBlock).mul(pool.allocPoint).div(totalAllocPoint);
            return (reward, 0, block.number);
        }
        return (0, 0, block.number);
    }

    function pendingEarnInfo(uint _pid) public view validatePoolByPid(_pid) returns (uint, uint, uint) {
        PoolInfo memory pool = poolInfo[_pid];
        if(across != address(0) && ISwitchAcross(across).feeWallet() == address(this)) {
            uint earn = ISwitchAcross(across).totalSlideOfToken(pool.earnToken);
            uint teamValue;
            if(teamEarnRate > 0) {
                teamValue = earn.div(teamEarnRate);
                earn = earn.sub(teamValue);
            }
            return (earn, teamValue, block.number);
        }
        return (0, 0, block.number);
    }

    // View function to see pending RewardTokens on frontend.
    function pendingReward(uint _pid, address _user) external view validatePoolByPid(_pid) returns (uint) {
        PoolInfo memory pool = poolInfo[_pid];
        UserInfo memory user = userInfo[_pid][_user];
        uint accRewardPerShare = pool.accRewardPerShare;
        if (block.number > pool.lastBlock && pool.depositTokenSupply != 0) {
            uint multiplier = getMultiplier(pool.lastBlock, block.number);
            uint reward = multiplier.mul(mintPerBlock).mul(pool.allocPoint).div(totalAllocPoint);
            accRewardPerShare = accRewardPerShare.add(reward.mul(1e18).div(pool.depositTokenSupply));
        }
        return user.amount.mul(accRewardPerShare).div(1e18).sub(user.rewardDebt);
    }

    function pendingEarn(uint _pid, address _user) external view validatePoolByPid(_pid) returns (uint) {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][_user];
        uint accEarnPerShare = pool.accEarnPerShare;
        if (pool.depositTokenSupply != 0 && across != address(0)) {
            (uint earn, ,) = pendingEarnInfo(_pid);
            accEarnPerShare = accEarnPerShare.add(earn.mul(1e18).div(pool.depositTokenSupply));
        }
        uint result = user.amount.mul(accEarnPerShare).div(1e18).sub(user.earnDebt);
        return result;
    }
    
    function _mintRewardToken(uint _pid) internal view returns (uint, uint, uint) {
        if(rewardToken == address(0)) {
            return (0, 0, block.number);
        }
        (uint reward, uint teamReward,) = pendingRewardInfo(_pid);
        return (reward, teamReward, block.number);
    }

    function _mintEarnToken(uint _pid) internal returns (uint, uint, uint) {
        if(across == address(0)) {
            return (0, 0, block.number);
        }
        (uint earn, uint teamValue,) = pendingEarnInfo(_pid);
        if(earn.add(teamValue) == 0) {
            return (0, 0, block.number);
        }

        PoolInfo memory pool = poolInfo[_pid];
        earn = ISwitchAcross(across).collectSlide(pool.earnToken);
        earnTokensTotal[pool.earnToken] = earnTokensTotal[pool.earnToken].add(earn);
        teamValue = 0;
        if(teamEarnRate > 0) {
            teamValue = earn.div(teamEarnRate);
            safeTokenTransfer(address(pool.earnToken), team, teamValue);
            earn = earn.sub(teamValue);
        }
        return (earn, teamValue, block.number);
    }

    // Update reward variables for all pools. Be careful of gas spending!
    function massUpdatePools() public {
        uint length = poolInfo.length;
        for (uint pid = 0; pid < length; ++pid) {
            updatePool(pid);
        }
    }

    // Update reward variables of the given pool to be up-to-date.
    function updatePool(uint _pid) internal {
        PoolInfo storage pool = poolInfo[_pid];
        uint toBlock = getToBlock();
        if (toBlock <= pool.lastBlock) {
            return;
        }
        if (pool.depositTokenSupply == 0 || pool.allocPoint == 0) {
            pool.lastBlock = toBlock;
            return;
        }
        
        (uint reward, ,) = _mintRewardToken(_pid);
        pool.accRewardPerShare = pool.accRewardPerShare.add(reward.mul(1e18).div(pool.depositTokenSupply));

        (uint earn, ,) = _mintEarnToken(_pid);
        pool.accEarnPerShare = pool.accEarnPerShare.add(earn.mul(1e18).div(pool.depositTokenSupply));

        pool.lastBlock = toBlock;
    }

    // Deposit tokens to SwitchFarm for reward allocation.
    function deposit(uint _pid, uint _amount, address _to) external validatePoolByPid(_pid) whenNotPaused nonReentrant returns(uint, uint) {
        PoolInfo storage pool = poolInfo[_pid];
        require(pool.paused == false, "pool is paused");
        UserInfo storage user = userInfo[_pid][_to];
        updatePool(_pid);
        uint depositFee;

        if (_amount > 0) {
            IERC20(pool.depositToken).transferFrom(address(msg.sender), address(this), _amount);
            
            if (pool.depositFeeBP > 0) {
                depositFee = _amount.mul(pool.depositFeeBP).div(10000);
                safeTransfer(pool.depositToken, feeAddress, depositFee);
                _amount = _amount.sub(depositFee);
                user.amount = user.amount.add(_amount);
            } else {
                user.amount = user.amount.add(_amount);
            }
        }
        pool.depositTokenSupply  = pool.depositTokenSupply.add(_amount);
        user.rewardDebt = user.amount.mul(pool.accRewardPerShare).div(1e18);
        user.earnDebt = user.amount.mul(pool.accEarnPerShare).div(1e18);
        emit Deposit(msg.sender, _to, _pid, _amount, depositFee);
        return (_amount, depositFee);
    }

    // Withdraw tokens from SwitchFarm.
    function withdraw(uint _pid, uint _amount, address _to) external validatePoolByPid(_pid) whenNotPaused nonReentrant returns(uint) {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        require(pool.paused == false, "pool is paused");
        require(user.amount >= _amount, "withdraw: not good");
        updatePool(_pid);
        _harvestRewardToken(_pid, _to);
        _harvestEarnToken(_pid, _to);
       
        if (_amount > 0) {
            user.amount = user.amount.sub(_amount);
            pool.depositTokenSupply = pool.depositTokenSupply.sub(_amount);
            safeTransfer(pool.depositToken, _to, _amount);
        }
        user.rewardDebt = user.amount.mul(pool.accRewardPerShare).div(1e18);
        user.earnDebt = user.amount.mul(pool.accEarnPerShare).div(1e18);
        emit Withdraw(msg.sender, _to, _pid, _amount);
        return _amount;
    }

    function _harvestRewardToken(uint _pid, address _to) internal returns(uint amount) {
        if(rewardToken == address(0)) {
            return 0;
        }
        PoolInfo memory pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        amount = user.amount.mul(pool.accRewardPerShare).div(1e18).sub(user.rewardDebt);
        uint take = IRewardToken(rewardToken).take();
        if(amount > take) {
            amount = take;
        }
        IRewardToken(rewardToken).mint(_to, amount);
        user.rewardDebt = user.amount.mul(pool.accRewardPerShare).div(1e18);
        return amount;
    }

    function _harvestEarnToken(uint _pid, address _to) internal returns(uint amount) {
        if(across == address(0)) {
            return 0;
        }
        PoolInfo memory pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        uint pending = user.amount.mul(pool.accEarnPerShare).div(1e18).sub(user.earnDebt);
        amount = safeTokenTransfer(pool.earnToken, _to, pending);
        user.earnDebt = user.amount.mul(pool.accEarnPerShare).div(1e18);
        return amount;
    }


    function harvestRewardToken(uint _pid, address _to) external validatePoolByPid(_pid) whenNotPaused nonReentrant returns(uint amount) {
        PoolInfo memory pool = poolInfo[_pid];
        require(pool.paused == false, "pool is paused");
        updatePool(_pid);
        return _harvestRewardToken(_pid, _to);
    }

    function harvestEarnToken(uint _pid, address _to) external validatePoolByPid(_pid) whenNotPaused nonReentrant returns(uint amount) {
        PoolInfo memory pool = poolInfo[_pid];
        require(pool.paused == false, "pool is paused");
        updatePool(_pid);
        return _harvestEarnToken(_pid, _to);
    }

    function harvest(uint _pid, address _to) external validatePoolByPid(_pid) whenNotPaused nonReentrant  returns (uint reward, uint earn) {
        PoolInfo memory pool = poolInfo[_pid];
        require(pool.paused == false, "pool is paused");
        updatePool(_pid);
        reward = _harvestRewardToken(_pid, _to);
        earn = _harvestEarnToken(_pid, _to);
    }

    // Withdraw without caring about rewards. EMERGENCY ONLY.
    function emergencyWithdraw(uint _pid, address _to) external validatePoolByPid(_pid) nonReentrant returns(uint) {
        PoolInfo storage pool = poolInfo[_pid];
        UserInfo storage user = userInfo[_pid][msg.sender];
        uint amount = user.amount;
        require(amount > 0, 'no balance');
        user.amount = 0;
        user.rewardDebt = 0;
        user.earnDebt = 0;
        pool.depositTokenSupply = pool.depositTokenSupply.sub(amount);
        safeTransfer(pool.depositToken, _to, amount);
        emit EmergencyWithdraw(msg.sender, _to, _pid, amount);
        return amount;
    }

    // Safe Token transfer function, just in case if rounding error causes pool to not have enough tokens.
    function safeTokenTransfer(address _token, address _to, uint _amount) internal returns(uint) {
        uint tokenBal = IERC20(_token).balanceOf(address(this));
        if(_amount >0) {
            if(tokenBal == 0) {
                return 0;
            }
            if (_amount > tokenBal) {
                _amount = tokenBal;
            }
            safeTransfer(_token, _to, _amount);
        }
        return _amount;
    }

    function safeTransfer(address _token, address _to, uint _amount) internal returns(uint) {
        (bool success, bytes memory data) = _token.call(abi.encodeWithSelector(0xa9059cbb, _to, _amount));
        require(success && (data.length == 0 || abi.decode(data, (bool))), 'safeTransfer: TRANSFER_FAILED');
        return _amount;
    }

    function setTeamAddress(address _team) external onlyDev {
        require(_team != address(0), 'zero address');
        team = _team;
        emit SetDevAddress(msg.sender, _team);
    }

    function setFeeAddress(address _feeAddress) external onlyDev {
        feeAddress = _feeAddress;
        emit SetFeeAddress(msg.sender, _feeAddress);
    }

    function setTeamRate(uint _teamRewardRate, uint _teamEarnRate) external onlyDev {
        require(_teamRewardRate >=0 && _teamEarnRate >=0, 'invalid param');
        teamRewardRate = _teamRewardRate;
        teamEarnRate = _teamEarnRate;
        emit SetTeamRate(msg.sender, _teamRewardRate, _teamEarnRate);
    }

    //reward has to add hidden dummy pools inorder to alter the emission, here we make it simple and transparent to all.
    function updateEmissionRate(uint _mintPerBlock) external onlyDev {
        massUpdatePools();
        mintPerBlock = _mintPerBlock;
        emit UpdateEmissionRate(msg.sender, _mintPerBlock);
    }
}

File 2 of 10 : IERC20.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.5.0;

interface IERC20 {
    function name() external view returns (string memory);
    function symbol() external view returns (string memory);
    function decimals() external view 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);
}

File 3 of 10 : ISwitchTicketFactory.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.12;

interface ISwitchTicketFactory {
    function treasury() external view returns (address);
    function getTokenMap(address _token) external view returns (address);
    function isTicket(address _ticket) external view returns (bool);
    function deposit(address _token, uint _value, address _to) external payable returns (address);
    function queryWithdrawInfo(address _user, address _ticket) external view returns (uint balance, uint amount);
    function queryWithdraw(address _user, address _ticket) external view returns (uint);
    function withdraw(bool isETH, address _to, address _ticket, uint _value) external returns (bool);
}

File 4 of 10 : ISwitchAcross.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.12;

interface ISwitchAcross {
    function feeWallet() external view returns (address);
    function totalSlideOfToken(address _token) external view returns (uint);
    function collectSlide(address _token) external returns (uint amount);
    function inSn() external view returns (uint);
    function outSn() external view returns (uint);
    function transferIn(address _to, address[] memory _tokens, uint[] memory _values) external payable;
    function transferOut(address _from, address[] memory _tokens, uint[] memory _values, bytes memory _signature) external;
    function queryWithdraw(address _token, uint _value) external view returns (uint);
}

File 5 of 10 : IRewardToken.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.12;

interface IRewardToken {
    function balanceOf(address owner) external view returns (uint);
    function take() external view returns (uint);
    function funds(address user) external view returns (uint);
    function mint(address to, uint value) external returns (bool);
}

File 6 of 10 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0;

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

        return c;
    }

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

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

File 7 of 10 : Configable.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.6;

interface IConfig {
    function dev() external view returns (address);
    function admin() external view returns (address);
}

contract Configable {
    address public config;
    address public owner;

    event ConfigChanged(address indexed _user, address indexed _old, address indexed _new);
    event OwnerChanged(address indexed _user, address indexed _old, address indexed _new);
 
    function setupConfig(address _config) external onlyOwner {
        emit ConfigChanged(msg.sender, config, _config);
        config = _config;
    }

    modifier onlyOwner() {
        require(msg.sender == owner, 'OWNER FORBIDDEN');
        _;
    }

    function admin() public view returns(address) {
        if(config != address(0)) {
            return IConfig(config).admin();
        }
        return owner;
    }

    function dev() public view returns(address) {
        if(config != address(0)) {
            return IConfig(config).dev();
        }
        return owner;
    }

    function changeOwner(address _user) external onlyOwner {
        require(owner != _user, 'Owner: NO CHANGE');
        emit OwnerChanged(msg.sender, owner, _user);
        owner = _user;
    }
    
    modifier onlyDev() {
        require(msg.sender == dev() || msg.sender == owner, 'dev FORBIDDEN');
        _;
    }
    
    modifier onlyAdmin() {
        require(msg.sender == admin(), 'admin FORBIDDEN');
        _;
    }
  
    modifier onlyManager() {
        require(msg.sender == dev() || msg.sender == admin() || msg.sender == owner, 'manager FORBIDDEN');
        _;
    }
}

File 8 of 10 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

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

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

    uint256 private _status;

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

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

        _;

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

File 9 of 10 : Pausable.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.0;

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

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

    bool private _paused;

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

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

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

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

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

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

pragma solidity >=0.6.0;


/**
 * @title Initializable
 *
 * @dev Helper contract to support initializer functions. To use it, replace
 * the constructor with a function that has the `initializer` modifier.
 * WARNING: Unlike constructors, initializer functions must be manually
 * invoked. This applies both to deploying an Initializable contract, as well
 * as extending an Initializable contract via inheritance.
 * WARNING: When used with inheritance, manual care must be taken to not invoke
 * a parent initializer twice, or ensure that all initializers are idempotent,
 * because this is not dealt with automatically as with constructors.
 */
contract Initializable {

  /**
   * @dev Indicates that the contract has been initialized.
   */
  bool private initialized;

  /**
   * @dev Indicates that the contract is in the process of being initialized.
   */
  bool private initializing;

  /**
   * @dev Modifier to use in the initializer function of a contract.
   */
  modifier initializer() {
    require(initializing || isConstructor() || !initialized, "Contract instance has already been initialized");

    bool isTopLevelCall = !initializing;
    if (isTopLevelCall) {
      initializing = true;
      initialized = true;
    }

    _;

    if (isTopLevelCall) {
      initializing = false;
    }
  }

  /// @dev Returns true if and only if the function is running in the constructor
  function isConstructor() private view returns (bool) {
    // extcodesize checks the size of the code stored in an address, and
    // address returns the current address. Since the code is still not
    // deployed when running a constructor, any checks on its code size will
    // yield zero, making it an effective way to detect if a contract is
    // under construction or not.
    address self = address(this);
    uint256 cs;
    assembly { cs := extcodesize(self) }
    return cs == 0;
  }

  // Reserved storage space to allow for layout changes in the future.
  uint256[50] private ______gap;
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 1000000
  },
  "metadata": {
    "bytecodeHash": "none"
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_user","type":"address"},{"indexed":true,"internalType":"address","name":"_old","type":"address"},{"indexed":true,"internalType":"address","name":"_new","type":"address"}],"name":"ConfigChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_user","type":"address"},{"indexed":true,"internalType":"address","name":"_old","type":"address"},{"indexed":true,"internalType":"address","name":"_new","type":"address"}],"name":"OwnerChanged","type":"event"},{"anonymous":false,"inputs":[],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"newAddress","type":"address"}],"name":"SetDevAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"newAddress","type":"address"}],"name":"SetFeeAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"teamRewardRate","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"teamEarnRate","type":"uint256"}],"name":"SetTeamRate","type":"event"},{"anonymous":false,"inputs":[],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"mintPerBlock","type":"uint256"}],"name":"UpdateEmissionRate","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"BONUS_MULTIPLIER","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"across","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_withUpdate","type":"bool"},{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"address","name":"_depositToken","type":"address"},{"internalType":"uint16","name":"_depositFeeBP","type":"uint16"}],"name":"add","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_withUpdate","type":"bool"},{"internalType":"uint256[]","name":"_allocPoints","type":"uint256[]"},{"internalType":"address[]","name":"_depositTokens","type":"address[]"},{"internalType":"uint16[]","name":"_depositFeeBPs","type":"uint16[]"}],"name":"batchAdd","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_pids","type":"uint256[]"},{"internalType":"uint256[]","name":"_allocPoints","type":"uint256[]"}],"name":"batchSetAllocPoint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_pids","type":"uint256[]"},{"internalType":"uint16[]","name":"_depositFeeBPs","type":"uint16[]"}],"name":"batchSetDepositFeeBP","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_pids","type":"uint256[]"},{"internalType":"bool[]","name":"_pauseds","type":"bool[]"}],"name":"batchSetPaused","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"changeOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"config","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_ticketFactory","type":"address"},{"internalType":"address","name":"_across","type":"address"}],"name":"configure","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"deposit","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"dev","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"earnTokensTotal","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"emergencyWithdraw","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"feeAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_from","type":"uint256"},{"internalType":"uint256","name":"_to","type":"uint256"}],"name":"getMultiplier","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getToBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"harvest","outputs":[{"internalType":"uint256","name":"reward","type":"uint256"},{"internalType":"uint256","name":"earn","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"harvestEarnToken","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"harvestRewardToken","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_ticketFactory","type":"address"},{"internalType":"address","name":"_across","type":"address"},{"internalType":"address","name":"_rewardToken","type":"address"},{"internalType":"address","name":"_team","type":"address"},{"internalType":"address","name":"_feeAddress","type":"address"},{"internalType":"uint256","name":"_mintPerBlock","type":"uint256"},{"internalType":"uint256","name":"_startBlock","type":"uint256"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"massUpdatePools","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintPerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_user","type":"address"}],"name":"pendingEarn","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"pendingEarnInfo","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_user","type":"address"}],"name":"pendingReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"pendingRewardInfo","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"poolExistence","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"poolInfo","outputs":[{"internalType":"address","name":"depositToken","type":"address"},{"internalType":"address","name":"earnToken","type":"address"},{"internalType":"uint256","name":"allocPoint","type":"uint256"},{"internalType":"uint256","name":"lastBlock","type":"uint256"},{"internalType":"uint256","name":"accRewardPerShare","type":"uint256"},{"internalType":"uint256","name":"accEarnPerShare","type":"uint256"},{"internalType":"uint256","name":"depositTokenSupply","type":"uint256"},{"internalType":"uint16","name":"depositFeeBP","type":"uint16"},{"internalType":"bool","name":"paused","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"poolLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_withUpdate","type":"bool"},{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"uint16","name":"_depositFeeBP","type":"uint16"},{"internalType":"bool","name":"_paused","type":"bool"}],"name":"set","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeAddress","type":"address"}],"name":"setFeeAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_team","type":"address"}],"name":"setTeamAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_teamRewardRate","type":"uint256"},{"internalType":"uint256","name":"_teamEarnRate","type":"uint256"}],"name":"setTeamRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_config","type":"address"}],"name":"setupConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"team","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"teamEarnRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"teamRewardRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ticketFactory","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalAllocPoint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintPerBlock","type":"uint256"}],"name":"updateEmissionRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"}],"name":"userInfo","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"},{"internalType":"uint256","name":"earnDebt","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"_to","type":"address"}],"name":"withdraw","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50615b3080620000216000396000f3fe608060405234801561001057600080fd5b50600436106103415760003560e01c80638da5cb5b116101bd578063b0b26b44116100f9578063d39fad50116100a2578063e470d5cf1161007c578063e470d5cf14610ecd578063ee9b32c514610f08578063f7c618c114610f10578063f851a44014610f1857610341565b8063d39fad5014610d36578063d4ea504514610e5d578063d5d0afe714610e9a57610341565b8063ba69690b116100d3578063ba69690b14610bd4578063c046d18814610bdc578063cbd258b514610d0357610341565b8063b0b26b4414610b1f578063b33f952714610b58578063b8bc83ee14610bb757610341565b806394f9c61211610166578063a6f9dae111610140578063a6f9dae114610913578063a7e03dcb14610946578063ab323b391461094e578063af304cfd14610b0257610341565b806394f9c6121461077a57806398969e82146108a1578063a390516e146108da57610341565b80638e10ef0b116101975780638e10ef0b1461071357806391cca3db1461071b57806393f1a40b1461072357610341565b80638da5cb5b146106a95780638dbb1e3a146106b15780638dbdbe6d146106d457610341565b80633f4ba83a1161028c578063630b5ba1116102355780638456cb591161020f5780638456cb591461066657806385f2aef21461066e5780638705fcd4146106765780638aa28550146105ff57610341565b8063630b5ba1146106235780636690864e1461062b57806379502c551461065e57610341565b80634d644679116102665780634d644679146105dc57806354fd4d50146105ff5780635c975abb1461060757610341565b80633f4ba83a146105c457806341275358146105cc57806348cd4cb1146105d457610341565b806317caf6f1116102ee5780632f940c70116102c85780632f940c701461051f5780633d50f2e0146105585780633f33b71e1461058b57610341565b806317caf6f1146104bd57806318fccc76146104c5578063292c1d921461051757610341565b80630ba84cd21161031f5780630ba84cd2146103d0578063150d6ced146103ef5780631526fe271461043a57610341565b8063068f46ce14610346578063081e3eda146103775780630ad58d2f14610391575b600080fd5b61034e610f20565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b61037f610f3c565b60408051918252519081900360200190f35b61037f600480360360608110156103a757600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610f43565b6103ed600480360360208110156103e657600080fd5b50356112e0565b005b6103ed6004803603608081101561040557600080fd5b508035151590602081013590604081013573ffffffffffffffffffffffffffffffffffffffff16906060013561ffff166113e9565b6104576004803603602081101561045057600080fd5b50356119a0565b6040805173ffffffffffffffffffffffffffffffffffffffff9a8b168152989099166020890152878901969096526060870194909452608086019290925260a085015260c084015261ffff1660e083015215156101008201529051908190036101200190f35b61037f611a1c565b6104fe600480360360408110156104db57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16611a22565b6040805192835260208301919091528051918290030190f35b61034e611cd3565b61037f6004803603604081101561053557600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16611cef565b6103ed6004803603602081101561056e57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16611f2a565b61037f600480360360408110156105a157600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff1661204a565b6103ed6121c1565b61034e61233e565b61037f61235a565b6103ed600480360360408110156105f257600080fd5b5080359060200135612360565b61037f61246b565b61060f612470565b604080519115158252519081900360200190f35b6103ed612479565b6103ed6004803603602081101561064157600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661249c565b61034e612652565b6103ed612673565b61034e6127ef565b6103ed6004803603602081101561068c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661280b565b61034e61293f565b61037f600480360360408110156106c757600080fd5b508035906020013561295b565b6104fe600480360360608110156106ea57600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff1661297b565b61037f612dad565b61034e612db3565b61075c6004803603604081101561073957600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16612e8f565b60408051938452602084019290925282820152519081900360600190f35b6103ed6004803603604081101561079057600080fd5b8101906020810181356401000000008111156107ab57600080fd5b8201836020820111156107bd57600080fd5b803590602001918460208302840111640100000000831117156107df57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929594936020810193503591505064010000000081111561082f57600080fd5b82018360208201111561084157600080fd5b8035906020019184602083028401116401000000008311171561086357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550612eb8945050505050565b61037f600480360360408110156108b757600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613141565b61037f600480360360408110156108f057600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613387565b6103ed6004803603602081101561092957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16613626565b61037f6137c6565b6103ed6004803603608081101561096457600080fd5b81351515919081019060408101602082013564010000000081111561098857600080fd5b82018360208201111561099a57600080fd5b803590602001918460208302840111640100000000831117156109bc57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610a0c57600080fd5b820183602082011115610a1e57600080fd5b80359060200191846020830284011164010000000083111715610a4057600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610a9057600080fd5b820183602082011115610aa257600080fd5b80359060200191846020830284011164010000000083111715610ac457600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295506137cc945050505050565b61075c60048036036020811015610b1857600080fd5b503561397b565b61037f60048036036040811015610b3557600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613abd565b6103ed600480360360e0811015610b6e57600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020810135821691604082013581169160608101358216916080820135169060a08101359060c00135613d4e565b61075c60048036036020811015610bcd57600080fd5b5035613f78565b61037f614242565b6103ed60048036036040811015610bf257600080fd5b810190602081018135640100000000811115610c0d57600080fd5b820183602082011115610c1f57600080fd5b80359060200191846020830284011164010000000083111715610c4157600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610c9157600080fd5b820183602082011115610ca357600080fd5b80359060200191846020830284011164010000000083111715610cc557600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550614248945050505050565b61060f60048036036020811015610d1957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16614484565b6103ed60048036036040811015610d4c57600080fd5b810190602081018135640100000000811115610d6757600080fd5b820183602082011115610d7957600080fd5b80359060200191846020830284011164010000000083111715610d9b57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610deb57600080fd5b820183602082011115610dfd57600080fd5b80359060200191846020830284011164010000000083111715610e1f57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550614499945050505050565b6103ed600480360360a0811015610e7357600080fd5b50803515159060208101359060408101359061ffff60608201351690608001351515614698565b61037f60048036036020811015610eb057600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16614941565b6103ed60048036036040811015610ee357600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020013516614953565b61037f614aeb565b61034e614aef565b61034e614b0b565b60365473ffffffffffffffffffffffffffffffffffffffff1681565b603f545b90565b603f5460009084908110610fb857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b610fc0612470565b1561102c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b6001600254141561109e57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f86815481106110b557fe5b6000918252602080832089845260408083528085203386529092529220600891909102909101600781015490925062010000900460ff161561115857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b80548611156111c857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f77697468647261773a206e6f7420676f6f640000000000000000000000000000604482015290519081900360640190fd5b6111d187614b97565b6111db8786614c8d565b506111e68786614f1e565b5085156112345780546111f9908761507b565b8155600682015461120a908761507b565b600683015581546112329073ffffffffffffffffffffffffffffffffffffffff1686886150bd565b505b6004820154815461125891670de0b6b3a764000091611252916152a2565b90615315565b60018201556005820154815461127b91670de0b6b3a764000091611252916152a2565b6002820155604080518781529051889173ffffffffffffffffffffffffffffffffffffffff88169133917ff341246adaac6f497bc2a656f546ab9e182111d630394f0c57c710a59a2cb567919081900360200190a45050600060025550919392505050565b6112e8612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611338575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6113a357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b6113ab612479565b603d81905560408051828152905133917fe2492e003bbe8afa53088b406f0c1cb5d9e280370fc72a74cf116ffd343c4053919081900360200190a250565b6113f1612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611441575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ac57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8216600090815260436020526040902054829060ff161561154357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f6e6f6e4475706c6963617465643a206475706c69636174656400000000000000604482015290519081900360640190fd5b6127108261ffff1611156115a2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180615ab06025913960400191505060405180910390fd5b603654604080517f95090cb500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8681166004830152915160009392909216916395090cb591602480820192602092909190829003018186803b15801561161957600080fd5b505afa15801561162d573d6000803e3d6000fd5b505050506040513d602081101561164357600080fd5b505160385490915073ffffffffffffffffffffffffffffffffffffffff8581169116146116ec5773ffffffffffffffffffffffffffffffffffffffff81166116ec57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6164643a20696e76616c6964206465706f73697420746f6b656e000000000000604482015290519081900360640190fd5b85156116fa576116fa612479565b6000604254431161170d5760425461170f565b435b60415490915061171f9087615357565b60415573ffffffffffffffffffffffffffffffffffffffff948516600081815260436020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558151610120810183529485529589169184019182528301988952606083019384526080830182815260a0840183815260c0850184815261ffff998a1660e087019081526101008701868152603f80549a8b018155909652955160089098027fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58fd81018054998d167fffffffffffffffffffffffff00000000000000000000000000000000000000009a8b1617905593517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58fe8501805491909c1698169790971790995598517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58ff82015592517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590084015596517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590183015594517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590282015590517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590382015592517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590490930180549451151562010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff949093167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941792909216179091555050565b603f81815481106119ad57fe5b60009182526020909120600890910201805460018201546002830154600384015460048501546005860154600687015460079097015473ffffffffffffffffffffffffffffffffffffffff968716985094909516959294919390929061ffff81169060ff620100009091041689565b60415481565b60008083603f805490508110611a9957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b611aa1612470565b15611b0d57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415611b7f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001600255611b8c615a10565b603f8681548110611b9957fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff6201000090910416158015610100830152909150611ca257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b611cab86614b97565b611cb58686614c8d565b9350611cc18686614f1e565b60006002559396939550929350505050565b60375473ffffffffffffffffffffffffffffffffffffffff1681565b603f5460009083908110611d6457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b60016002541415611dd657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f8581548110611ded57fe5b600091825260208083208884526040808352808520338652909252922080546008909202909201925080611e8257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f2062616c616e636500000000000000000000000000000000000000000000604482015290519081900360640190fd5b60008083556001830181905560028301556006830154611ea2908261507b565b60068401558254611eca9073ffffffffffffffffffffffffffffffffffffffff1687836150bd565b50604080518281529051889173ffffffffffffffffffffffffffffffffffffffff89169133917f1401b6ff3b281e84fd77353369caed48ba7e787dd3821db05cc0064373608201919081900360200190a460006002559695505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611fb057604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f4f574e455220464f5242494444454e0000000000000000000000000000000000604482015290519081900360640190fd5b6000805460405173ffffffffffffffffffffffffffffffffffffffff80851693610100909304169133917f1c9f92ac4e71628bcbcaa06d364d40e010aef535184545a709e14cced8ac2d3c9190a46000805473ffffffffffffffffffffffffffffffffffffffff909216610100027fffffffffffffffffffffff0000000000000000000000000000000000000000ff909216919091179055565b603f54600090839081106120bf57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6000603f85815481106120ce57fe5b60009182526020808320888452604080835280852073ffffffffffffffffffffffffffffffffffffffff8a168652909252922060056008909202909201908101546006820154919350901580159061213d575060375473ffffffffffffffffffffffffffffffffffffffff1615155b1561218257600061214d88613f78565b5050905061217e6121778560060154611252670de0b6b3a7640000856152a290919063ffffffff16565b8390615357565b9150505b60006121b583600201546121af670de0b6b3a76400006112528688600001546152a290919063ffffffff16565b9061507b565b98975050505050505050565b6121c9612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806122345750612205614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612256575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6122c157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b6122c9612470565b61233457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015290519081900360640190fd5b61233c6153cb565b565b603e5473ffffffffffffffffffffffffffffffffffffffff1681565b60425481565b612368612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806123b8575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61242357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b603a829055603b8190556040805183815260208101839052815133927f1a232b300cda32d1b9219f0326c4e1b26f3e134f8ec60f9a51ba04132609f91c928290030190a25050565b600181565b60005460ff1690565b603f5460005b818110156124985761249081614b97565b60010161247f565b5050565b6124a4612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806124f4575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61255f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166125e157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b603c80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff831690811790915560405133907f618c54559e94f1499a808aad71ee8729f8e74e8c48e979616328ce493a1a52e790600090a350565b600054610100900473ffffffffffffffffffffffffffffffffffffffff1681565b61267b612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806126e657506126b7614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612708575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61277357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b61277b612470565b156127e757604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b61233c61548f565b603c5473ffffffffffffffffffffffffffffffffffffffff1681565b612813612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480612863575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6128ce57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b603e80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff831690811790915560405133907fd44190acf9d04bdb5d3a1aafff7e6dee8b40b93dfb8c5d3f0eea4b9f4539c3f790600090a350565b60015473ffffffffffffffffffffffffffffffffffffffff1681565b6000612972600161296c848661507b565b906152a2565b90505b92915050565b60008084603f8054905081106129f257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6129fa612470565b15612a6657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415612ad857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f8781548110612aef57fe5b60009182526020909120600890910201600781015490915062010000900460ff1615612b7c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b60008781526040602081815281832073ffffffffffffffffffffffffffffffffffffffff8916845290529020612bb188614b97565b60008715612cea578254604080517f23b872dd000000000000000000000000000000000000000000000000000000008152336004820152306024820152604481018b9052905173ffffffffffffffffffffffffffffffffffffffff909216916323b872dd916064808201926020929091908290030181600087803b158015612c3857600080fd5b505af1158015612c4c573d6000803e3d6000fd5b505050506040513d6020811015612c6257600080fd5b5050600783015461ffff1615612cdb576007830154612c8e9061271090611252908b9061ffff166152a2565b8354603e54919250612cba9173ffffffffffffffffffffffffffffffffffffffff9182169116836150bd565b50612cc5888261507b565b8254909850612cd49089615357565b8255612cea565b8154612ce79089615357565b82555b6006830154612cf99089615357565b600684015560048301548254612d1c91670de0b6b3a764000091611252916152a2565b600183015560058301548254612d3f91670de0b6b3a764000091611252916152a2565b6002830155604080518981526020810183905281518b9273ffffffffffffffffffffffffffffffffffffffff8b169233927f4e2ca0515ed1aef1395f66b5303bb5d6f1bf9d61a353fa53f73f8ac9973fa9f6929181900390910190a460006002559698969750505050505050565b603a5481565b60008054610100900473ffffffffffffffffffffffffffffffffffffffff1615612e7257600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166391cca3db6040518163ffffffff1660e01b815260040160206040518083038186803b158015612e3f57600080fd5b505afa158015612e53573d6000803e3d6000fd5b505050506040513d6020811015612e6957600080fd5b50519050610f40565b5060015473ffffffffffffffffffffffffffffffffffffffff1690565b604060208181526000938452818420905290825290208054600182015460029092015490919083565b612ec0612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480612f2b5750612efc614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612f4d575060015473ffffffffffffffffffffffffffffffffffffffff1633145b612fb857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b805182511461302857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b60005b825181101561313c5761271082828151811061304357fe5b602002602001015161ffff1611156130bc57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f6465706f73697446656542502073686f756c64206265203c3d31303030302100604482015290519081900360640190fd5b8181815181106130c857fe5b6020026020010151603f8483815181106130de57fe5b6020026020010151815481106130f057fe5b6000918252602090912060089091020160070180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9290921691909117905560010161302b565b505050565b603f54600090839081106131b657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6131be615a10565b603f85815481106131cb57fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff62010000909104161515610100820152905061326f615a8e565b5060008581526040602081815281832073ffffffffffffffffffffffffffffffffffffffff881684528152918190208151606080820184528254825260018301549482019490945260029091015491810191909152608083015191830151909190431180156132e1575060c083015115155b156133515760006132f684606001514361295b565b9050600061331d604154611252876040015161296c603d54876152a290919063ffffffff16565b905061334c6133458660c00151611252670de0b6b3a7640000856152a290919063ffffffff16565b8490615357565b925050505b61337c82602001516121af670de0b6b3a76400006112528587600001516152a290919063ffffffff16565b979650505050505050565b603f54600090839081106133fc57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613404612470565b1561347057604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b600160025414156134e257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002556134ef615a10565b603f85815481106134fc57fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff620100009091041615801561010083015290915061360557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b61360e85614b97565b6136188585614c8d565b600060025595945050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146136ac57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f4f574e455220464f5242494444454e0000000000000000000000000000000000604482015290519081900360640190fd5b60015473ffffffffffffffffffffffffffffffffffffffff8281169116141561373657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4f776e65723a204e4f204348414e474500000000000000000000000000000000604482015290519081900360640190fd5b60015460405173ffffffffffffffffffffffffffffffffffffffff80841692169033907f381c0d11398486654573703c51ee8210ce9461764d133f9f0e53b6a53970533190600090a4600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b603d5481565b6137d4612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480613824575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61388f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b815183511480156138a1575080518251145b61390c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b831561391a5761391a612479565b60005b83518110156139745761396c600085838151811061393757fe5b602002602001015185848151811061394b57fe5b602002602001015185858151811061395f57fe5b60200260200101516113e9565b60010161391d565b5050505050565b600080600083603f8054905081106139f457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6000603f8681548110613a0357fe5b60009182526020909120603854600890920201915073ffffffffffffffffffffffffffffffffffffffff1615801590613a4657508060030154613a44614aeb565b115b8015613a5457506000604154115b15613aa9576000613a708260030154613a6b614aeb565b61295b565b90506000613a97604154611252856002015461296c603d54876152a290919063ffffffff16565b965060009550439450613ab592505050565b60008043945094509450505b509193909250565b603f5460009083908110613b3257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613b3a612470565b15613ba657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415613c1857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001600255613c25615a10565b603f8581548110613c3257fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff6201000090910416158015610100830152909150613d3b57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b613d4485614b97565b6136188585614f1e565b600354610100900460ff1680613d675750613d67615557565b80613d75575060035460ff16155b613dca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e815260200180615af6602e913960400191505060405180910390fd5b600354610100900460ff16158015613e3057600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909116610100171660011790555b73ffffffffffffffffffffffffffffffffffffffff8816613eb257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b60018054337fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915560368054821673ffffffffffffffffffffffffffffffffffffffff8b8116919091179091556037805483168a8316179055603880548316898316179055603c80548316888316179055603e8054909216908616179055603d83905560428290558015613f6e57600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b5050505050505050565b600080600083603f805490508110613ff157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613ff9615a10565b603f868154811061400657fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff908116845260018201548116948401949094526002810154918301919091526003810154606083015260048101546080830152600581015460a0830152600681015460c08301526007015461ffff811660e083015260ff6201000090910416151561010082015260375490925016158015906141605750603754604080517ff25f4b560000000000000000000000000000000000000000000000000000000081529051309273ffffffffffffffffffffffffffffffffffffffff169163f25f4b56916004808301926020929190829003018186803b15801561411c57600080fd5b505afa158015614130573d6000803e3d6000fd5b505050506040513d602081101561414657600080fd5b505173ffffffffffffffffffffffffffffffffffffffff16145b15613aa957603754602080830151604080517f8d5db68400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015290516000949290921692638d5db68492602480840193829003018186803b1580156141dc57600080fd5b505afa1580156141f0573d6000803e3d6000fd5b505050506040513d602081101561420657600080fd5b5051603b549091506000901561423357603b54614224908390615315565b9050614230828261507b565b91505b9095509350439250613ab59050565b603b5481565b614250612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806142bb575061428c614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b806142dd575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61434857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b80518251146143b857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b6143c0612479565b60005b825181101561313c5761442f8282815181106143db57fe5b6020026020010151614429603f8685815181106143f457fe5b60200260200101518154811061440657fe5b90600052602060002090600802016002015460415461507b90919063ffffffff16565b90615357565b604155815182908290811061444057fe5b6020026020010151603f84838151811061445657fe5b60200260200101518154811061446857fe5b60009182526020909120600260089092020101556001016143c3565b60436020526000908152604090205460ff1681565b6144a1612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061450c57506144dd614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b8061452e575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61459957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b805182511461460957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b60005b825181101561313c5781818151811061462157fe5b6020026020010151603f84838151811061463757fe5b60200260200101518154811061464957fe5b60009182526020909120600760089092020101805491151562010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff90921691909117905560010161460c565b603f548490811061470a57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b614712612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061477d575061474e614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b8061479f575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61480a57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b6127108361ffff16111561487f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f6465706f73697446656542502073686f756c64206265203c3d31303030302100604482015290519081900360640190fd5b851561488d5761488d612479565b6148a184614429603f888154811061440657fe5b60418190555083603f86815481106148b557fe5b90600052602060002090600802016002018190555082603f86815481106148d857fe5b906000526020600020906008020160070160006101000a81548161ffff021916908361ffff16021790555081603f868154811061491157fe5b906000526020600020906008020160070160026101000a81548160ff021916908315150217905550505050505050565b60396020526000908152604090205481565b61495b612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806149ab575060015473ffffffffffffffffffffffffffffffffffffffff1633145b614a1657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8216614a9857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b6036805473ffffffffffffffffffffffffffffffffffffffff9384167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915560378054929093169116179055565b4390565b60385473ffffffffffffffffffffffffffffffffffffffff1681565b60008054610100900473ffffffffffffffffffffffffffffffffffffffff1615612e7257600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f851a4406040518163ffffffff1660e01b815260040160206040518083038186803b158015612e3f57600080fd5b6000603f8281548110614ba657fe5b906000526020600020906008020190506000614bc0614aeb565b905081600301548111614bd4575050614c8a565b60068201541580614be757506002820154155b15614bf757600390910155614c8a565b6000614c028461555d565b50509050614c37614c2c8460060154611252670de0b6b3a7640000856152a290919063ffffffff16565b600485015490615357565b60048401556000614c47856155ae565b50509050614c7c614c718560060154611252670de0b6b3a7640000856152a290919063ffffffff16565b600586015490615357565b600585015550506003909101555b50565b60385460009073ffffffffffffffffffffffffffffffffffffffff16614cb557506000612975565b614cbd615a10565b603f8481548110614cca57fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff90811685526001808301549091168585015260028201548584015260038201546060860152600482015460808601908152600583015460a0870152600683015460c087015260079092015461ffff811660e087015260ff62010000909104161515610100860152898652828452828620338752909352932090810154925181549294509092614da19290916121af91670de0b6b3a76400009161125291906152a2565b92506000603860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663159090bd6040518163ffffffff1660e01b815260040160206040518083038186803b158015614e0d57600080fd5b505afa158015614e21573d6000803e3d6000fd5b505050506040513d6020811015614e3757600080fd5b5051905080841115614e47578093505b603854604080517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff888116600483015260248201889052915191909216916340c10f199160448083019260209291908290030181600087803b158015614ec357600080fd5b505af1158015614ed7573d6000803e3d6000fd5b505050506040513d6020811015614eed57600080fd5b505060808301518254614f0d91670de0b6b3a764000091611252916152a2565b826001018190555050505092915050565b60375460009073ffffffffffffffffffffffffffffffffffffffff16614f4657506000612975565b614f4e615a10565b603f8481548110614f5b57fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff908116855260018201541684840152600280820154858401526003820154606086015260048201546080860152600582015460a08601908152600683015460c087015260079092015461ffff811660e087015260ff620100009091041615156101008601528986528284528286203387529093529084209182015490518254939550919392615030926121af91670de0b6b3a76400009161125291906152a2565b905061504183602001518683615811565b935061506a670de0b6b3a76400006112528560a0015185600001546152a290919063ffffffff16565b826002018190555050505092915050565b600061297283836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506158e0565b6040805173ffffffffffffffffffffffffffffffffffffffff8481166024830152604480830185905283518084039091018152606490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001781529251825160009485946060948a16939092909182918083835b6020831061519557805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe09092019160209182019101615158565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146151f7576040519150601f19603f3d011682016040523d82523d6000602084013e6151fc565b606091505b509150915081801561522a57508051158061522a575080806020019051602081101561522757600080fd5b50515b61529557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f736166655472616e736665723a205452414e534645525f4641494c4544000000604482015290519081900360640190fd5b83925050505b9392505050565b6000826152b157506000612975565b828202828482816152be57fe5b0414612972576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180615ad56021913960400191505060405180910390fd5b600061297283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250615991565b60008282018381101561297257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6153d3612470565b61543e57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001681556040517fa45f47fdea8a1efdd9029a5691c7f759c32b7c698632b563573e155625d169339190a1565b615497612470565b1561550357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011781556040517f9e87fac88ff661f02d44f95383c817fece4bce600a3dab7a54406878b965e7529190a1565b303b1590565b6038546000908190819073ffffffffffffffffffffffffffffffffffffffff1661558f575060009150819050436155a7565b60008061559b8661397b565b50909550935043925050505b9193909250565b6037546000908190819073ffffffffffffffffffffffffffffffffffffffff166155e0575060009150819050436155a7565b6000806155ec86613f78565b5090925090506155fc8282615357565b615611576000804394509450945050506155a7565b615619615a10565b603f878154811061562657fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff908116855260018201548116858501819052600283015486850152600383015460608701526004808401546080880152600584015460a0880152600684015460c088015260079093015461ffff811660e088015260ff6201000090910416151561010087015260375484517f305854bb000000000000000000000000000000000000000000000000000000008152938401919091529251949650919091169363305854bb93602480840194939192918390030190829087803b15801561571f57600080fd5b505af1158015615733573d6000803e3d6000fd5b505050506040513d602081101561574957600080fd5b505160208281015173ffffffffffffffffffffffffffffffffffffffff166000908152603990915260409020549093506157839084615357565b60208083015173ffffffffffffffffffffffffffffffffffffffff16600090815260399091526040812091909155603b549092501561580357603b546157ca908490615315565b6020820151603c549193506157f59173ffffffffffffffffffffffffffffffffffffffff1684615811565b50615800838361507b565b92505b509095909450439350915050565b6000808473ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561587b57600080fd5b505afa15801561588f573d6000803e3d6000fd5b505050506040513d60208110156158a557600080fd5b5051905082156158d757806158be57600091505061529b565b808311156158ca578092505b6158d58585856150bd565b505b50909392505050565b60008184841115615989576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561594e578181015183820152602001615936565b50505050905090810190601f16801561597b5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600081836159fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181815283516024840152835190928392604490910191908501908083836000831561594e578181015183820152602001615936565b506000838581615a0657fe5b0495945050505050565b604051806101200160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681526020016000815260200160008152602001600081526020016000815260200160008152602001600061ffff1681526020016000151581525090565b6040518060600160405280600081526020016000815260200160008152509056fe6164643a20696e76616c6964206465706f7369742066656520626173697320706f696e7473536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a6564a164736f6c634300060c000a

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106103415760003560e01c80638da5cb5b116101bd578063b0b26b44116100f9578063d39fad50116100a2578063e470d5cf1161007c578063e470d5cf14610ecd578063ee9b32c514610f08578063f7c618c114610f10578063f851a44014610f1857610341565b8063d39fad5014610d36578063d4ea504514610e5d578063d5d0afe714610e9a57610341565b8063ba69690b116100d3578063ba69690b14610bd4578063c046d18814610bdc578063cbd258b514610d0357610341565b8063b0b26b4414610b1f578063b33f952714610b58578063b8bc83ee14610bb757610341565b806394f9c61211610166578063a6f9dae111610140578063a6f9dae114610913578063a7e03dcb14610946578063ab323b391461094e578063af304cfd14610b0257610341565b806394f9c6121461077a57806398969e82146108a1578063a390516e146108da57610341565b80638e10ef0b116101975780638e10ef0b1461071357806391cca3db1461071b57806393f1a40b1461072357610341565b80638da5cb5b146106a95780638dbb1e3a146106b15780638dbdbe6d146106d457610341565b80633f4ba83a1161028c578063630b5ba1116102355780638456cb591161020f5780638456cb591461066657806385f2aef21461066e5780638705fcd4146106765780638aa28550146105ff57610341565b8063630b5ba1146106235780636690864e1461062b57806379502c551461065e57610341565b80634d644679116102665780634d644679146105dc57806354fd4d50146105ff5780635c975abb1461060757610341565b80633f4ba83a146105c457806341275358146105cc57806348cd4cb1146105d457610341565b806317caf6f1116102ee5780632f940c70116102c85780632f940c701461051f5780633d50f2e0146105585780633f33b71e1461058b57610341565b806317caf6f1146104bd57806318fccc76146104c5578063292c1d921461051757610341565b80630ba84cd21161031f5780630ba84cd2146103d0578063150d6ced146103ef5780631526fe271461043a57610341565b8063068f46ce14610346578063081e3eda146103775780630ad58d2f14610391575b600080fd5b61034e610f20565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b61037f610f3c565b60408051918252519081900360200190f35b61037f600480360360608110156103a757600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610f43565b6103ed600480360360208110156103e657600080fd5b50356112e0565b005b6103ed6004803603608081101561040557600080fd5b508035151590602081013590604081013573ffffffffffffffffffffffffffffffffffffffff16906060013561ffff166113e9565b6104576004803603602081101561045057600080fd5b50356119a0565b6040805173ffffffffffffffffffffffffffffffffffffffff9a8b168152989099166020890152878901969096526060870194909452608086019290925260a085015260c084015261ffff1660e083015215156101008201529051908190036101200190f35b61037f611a1c565b6104fe600480360360408110156104db57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16611a22565b6040805192835260208301919091528051918290030190f35b61034e611cd3565b61037f6004803603604081101561053557600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16611cef565b6103ed6004803603602081101561056e57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16611f2a565b61037f600480360360408110156105a157600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff1661204a565b6103ed6121c1565b61034e61233e565b61037f61235a565b6103ed600480360360408110156105f257600080fd5b5080359060200135612360565b61037f61246b565b61060f612470565b604080519115158252519081900360200190f35b6103ed612479565b6103ed6004803603602081101561064157600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661249c565b61034e612652565b6103ed612673565b61034e6127ef565b6103ed6004803603602081101561068c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661280b565b61034e61293f565b61037f600480360360408110156106c757600080fd5b508035906020013561295b565b6104fe600480360360608110156106ea57600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff1661297b565b61037f612dad565b61034e612db3565b61075c6004803603604081101561073957600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16612e8f565b60408051938452602084019290925282820152519081900360600190f35b6103ed6004803603604081101561079057600080fd5b8101906020810181356401000000008111156107ab57600080fd5b8201836020820111156107bd57600080fd5b803590602001918460208302840111640100000000831117156107df57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929594936020810193503591505064010000000081111561082f57600080fd5b82018360208201111561084157600080fd5b8035906020019184602083028401116401000000008311171561086357600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550612eb8945050505050565b61037f600480360360408110156108b757600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613141565b61037f600480360360408110156108f057600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613387565b6103ed6004803603602081101561092957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16613626565b61037f6137c6565b6103ed6004803603608081101561096457600080fd5b81351515919081019060408101602082013564010000000081111561098857600080fd5b82018360208201111561099a57600080fd5b803590602001918460208302840111640100000000831117156109bc57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610a0c57600080fd5b820183602082011115610a1e57600080fd5b80359060200191846020830284011164010000000083111715610a4057600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610a9057600080fd5b820183602082011115610aa257600080fd5b80359060200191846020830284011164010000000083111715610ac457600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295506137cc945050505050565b61075c60048036036020811015610b1857600080fd5b503561397b565b61037f60048036036040811015610b3557600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff16613abd565b6103ed600480360360e0811015610b6e57600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020810135821691604082013581169160608101358216916080820135169060a08101359060c00135613d4e565b61075c60048036036020811015610bcd57600080fd5b5035613f78565b61037f614242565b6103ed60048036036040811015610bf257600080fd5b810190602081018135640100000000811115610c0d57600080fd5b820183602082011115610c1f57600080fd5b80359060200191846020830284011164010000000083111715610c4157600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610c9157600080fd5b820183602082011115610ca357600080fd5b80359060200191846020830284011164010000000083111715610cc557600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550614248945050505050565b61060f60048036036020811015610d1957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16614484565b6103ed60048036036040811015610d4c57600080fd5b810190602081018135640100000000811115610d6757600080fd5b820183602082011115610d7957600080fd5b80359060200191846020830284011164010000000083111715610d9b57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295949360208101935035915050640100000000811115610deb57600080fd5b820183602082011115610dfd57600080fd5b80359060200191846020830284011164010000000083111715610e1f57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550614499945050505050565b6103ed600480360360a0811015610e7357600080fd5b50803515159060208101359060408101359061ffff60608201351690608001351515614698565b61037f60048036036020811015610eb057600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16614941565b6103ed60048036036040811015610ee357600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020013516614953565b61037f614aeb565b61034e614aef565b61034e614b0b565b60365473ffffffffffffffffffffffffffffffffffffffff1681565b603f545b90565b603f5460009084908110610fb857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b610fc0612470565b1561102c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b6001600254141561109e57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f86815481106110b557fe5b6000918252602080832089845260408083528085203386529092529220600891909102909101600781015490925062010000900460ff161561115857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b80548611156111c857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f77697468647261773a206e6f7420676f6f640000000000000000000000000000604482015290519081900360640190fd5b6111d187614b97565b6111db8786614c8d565b506111e68786614f1e565b5085156112345780546111f9908761507b565b8155600682015461120a908761507b565b600683015581546112329073ffffffffffffffffffffffffffffffffffffffff1686886150bd565b505b6004820154815461125891670de0b6b3a764000091611252916152a2565b90615315565b60018201556005820154815461127b91670de0b6b3a764000091611252916152a2565b6002820155604080518781529051889173ffffffffffffffffffffffffffffffffffffffff88169133917ff341246adaac6f497bc2a656f546ab9e182111d630394f0c57c710a59a2cb567919081900360200190a45050600060025550919392505050565b6112e8612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611338575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6113a357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b6113ab612479565b603d81905560408051828152905133917fe2492e003bbe8afa53088b406f0c1cb5d9e280370fc72a74cf116ffd343c4053919081900360200190a250565b6113f1612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480611441575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ac57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8216600090815260436020526040902054829060ff161561154357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f6e6f6e4475706c6963617465643a206475706c69636174656400000000000000604482015290519081900360640190fd5b6127108261ffff1611156115a2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180615ab06025913960400191505060405180910390fd5b603654604080517f95090cb500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8681166004830152915160009392909216916395090cb591602480820192602092909190829003018186803b15801561161957600080fd5b505afa15801561162d573d6000803e3d6000fd5b505050506040513d602081101561164357600080fd5b505160385490915073ffffffffffffffffffffffffffffffffffffffff8581169116146116ec5773ffffffffffffffffffffffffffffffffffffffff81166116ec57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f6164643a20696e76616c6964206465706f73697420746f6b656e000000000000604482015290519081900360640190fd5b85156116fa576116fa612479565b6000604254431161170d5760425461170f565b435b60415490915061171f9087615357565b60415573ffffffffffffffffffffffffffffffffffffffff948516600081815260436020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558151610120810183529485529589169184019182528301988952606083019384526080830182815260a0840183815260c0850184815261ffff998a1660e087019081526101008701868152603f80549a8b018155909652955160089098027fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58fd81018054998d167fffffffffffffffffffffffff00000000000000000000000000000000000000009a8b1617905593517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58fe8501805491909c1698169790971790995598517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b58ff82015592517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590084015596517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590183015594517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590282015590517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590382015592517fc03004e3ce0784bf68186394306849f9b7b1200073105cd9aeb554a1802b590490930180549451151562010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff949093167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941792909216179091555050565b603f81815481106119ad57fe5b60009182526020909120600890910201805460018201546002830154600384015460048501546005860154600687015460079097015473ffffffffffffffffffffffffffffffffffffffff968716985094909516959294919390929061ffff81169060ff620100009091041689565b60415481565b60008083603f805490508110611a9957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b611aa1612470565b15611b0d57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415611b7f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001600255611b8c615a10565b603f8681548110611b9957fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff6201000090910416158015610100830152909150611ca257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b611cab86614b97565b611cb58686614c8d565b9350611cc18686614f1e565b60006002559396939550929350505050565b60375473ffffffffffffffffffffffffffffffffffffffff1681565b603f5460009083908110611d6457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b60016002541415611dd657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f8581548110611ded57fe5b600091825260208083208884526040808352808520338652909252922080546008909202909201925080611e8257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600a60248201527f6e6f2062616c616e636500000000000000000000000000000000000000000000604482015290519081900360640190fd5b60008083556001830181905560028301556006830154611ea2908261507b565b60068401558254611eca9073ffffffffffffffffffffffffffffffffffffffff1687836150bd565b50604080518281529051889173ffffffffffffffffffffffffffffffffffffffff89169133917f1401b6ff3b281e84fd77353369caed48ba7e787dd3821db05cc0064373608201919081900360200190a460006002559695505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611fb057604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f4f574e455220464f5242494444454e0000000000000000000000000000000000604482015290519081900360640190fd5b6000805460405173ffffffffffffffffffffffffffffffffffffffff80851693610100909304169133917f1c9f92ac4e71628bcbcaa06d364d40e010aef535184545a709e14cced8ac2d3c9190a46000805473ffffffffffffffffffffffffffffffffffffffff909216610100027fffffffffffffffffffffff0000000000000000000000000000000000000000ff909216919091179055565b603f54600090839081106120bf57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6000603f85815481106120ce57fe5b60009182526020808320888452604080835280852073ffffffffffffffffffffffffffffffffffffffff8a168652909252922060056008909202909201908101546006820154919350901580159061213d575060375473ffffffffffffffffffffffffffffffffffffffff1615155b1561218257600061214d88613f78565b5050905061217e6121778560060154611252670de0b6b3a7640000856152a290919063ffffffff16565b8390615357565b9150505b60006121b583600201546121af670de0b6b3a76400006112528688600001546152a290919063ffffffff16565b9061507b565b98975050505050505050565b6121c9612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806122345750612205614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612256575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6122c157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b6122c9612470565b61233457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015290519081900360640190fd5b61233c6153cb565b565b603e5473ffffffffffffffffffffffffffffffffffffffff1681565b60425481565b612368612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806123b8575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61242357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b603a829055603b8190556040805183815260208101839052815133927f1a232b300cda32d1b9219f0326c4e1b26f3e134f8ec60f9a51ba04132609f91c928290030190a25050565b600181565b60005460ff1690565b603f5460005b818110156124985761249081614b97565b60010161247f565b5050565b6124a4612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806124f4575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61255f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166125e157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b603c80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff831690811790915560405133907f618c54559e94f1499a808aad71ee8729f8e74e8c48e979616328ce493a1a52e790600090a350565b600054610100900473ffffffffffffffffffffffffffffffffffffffff1681565b61267b612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806126e657506126b7614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612708575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61277357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b61277b612470565b156127e757604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b61233c61548f565b603c5473ffffffffffffffffffffffffffffffffffffffff1681565b612813612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480612863575060015473ffffffffffffffffffffffffffffffffffffffff1633145b6128ce57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b603e80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff831690811790915560405133907fd44190acf9d04bdb5d3a1aafff7e6dee8b40b93dfb8c5d3f0eea4b9f4539c3f790600090a350565b60015473ffffffffffffffffffffffffffffffffffffffff1681565b6000612972600161296c848661507b565b906152a2565b90505b92915050565b60008084603f8054905081106129f257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6129fa612470565b15612a6657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415612ad857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002819055506000603f8781548110612aef57fe5b60009182526020909120600890910201600781015490915062010000900460ff1615612b7c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b60008781526040602081815281832073ffffffffffffffffffffffffffffffffffffffff8916845290529020612bb188614b97565b60008715612cea578254604080517f23b872dd000000000000000000000000000000000000000000000000000000008152336004820152306024820152604481018b9052905173ffffffffffffffffffffffffffffffffffffffff909216916323b872dd916064808201926020929091908290030181600087803b158015612c3857600080fd5b505af1158015612c4c573d6000803e3d6000fd5b505050506040513d6020811015612c6257600080fd5b5050600783015461ffff1615612cdb576007830154612c8e9061271090611252908b9061ffff166152a2565b8354603e54919250612cba9173ffffffffffffffffffffffffffffffffffffffff9182169116836150bd565b50612cc5888261507b565b8254909850612cd49089615357565b8255612cea565b8154612ce79089615357565b82555b6006830154612cf99089615357565b600684015560048301548254612d1c91670de0b6b3a764000091611252916152a2565b600183015560058301548254612d3f91670de0b6b3a764000091611252916152a2565b6002830155604080518981526020810183905281518b9273ffffffffffffffffffffffffffffffffffffffff8b169233927f4e2ca0515ed1aef1395f66b5303bb5d6f1bf9d61a353fa53f73f8ac9973fa9f6929181900390910190a460006002559698969750505050505050565b603a5481565b60008054610100900473ffffffffffffffffffffffffffffffffffffffff1615612e7257600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166391cca3db6040518163ffffffff1660e01b815260040160206040518083038186803b158015612e3f57600080fd5b505afa158015612e53573d6000803e3d6000fd5b505050506040513d6020811015612e6957600080fd5b50519050610f40565b5060015473ffffffffffffffffffffffffffffffffffffffff1690565b604060208181526000938452818420905290825290208054600182015460029092015490919083565b612ec0612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480612f2b5750612efc614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b80612f4d575060015473ffffffffffffffffffffffffffffffffffffffff1633145b612fb857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b805182511461302857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b60005b825181101561313c5761271082828151811061304357fe5b602002602001015161ffff1611156130bc57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f6465706f73697446656542502073686f756c64206265203c3d31303030302100604482015290519081900360640190fd5b8181815181106130c857fe5b6020026020010151603f8483815181106130de57fe5b6020026020010151815481106130f057fe5b6000918252602090912060089091020160070180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9290921691909117905560010161302b565b505050565b603f54600090839081106131b657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6131be615a10565b603f85815481106131cb57fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff62010000909104161515610100820152905061326f615a8e565b5060008581526040602081815281832073ffffffffffffffffffffffffffffffffffffffff881684528152918190208151606080820184528254825260018301549482019490945260029091015491810191909152608083015191830151909190431180156132e1575060c083015115155b156133515760006132f684606001514361295b565b9050600061331d604154611252876040015161296c603d54876152a290919063ffffffff16565b905061334c6133458660c00151611252670de0b6b3a7640000856152a290919063ffffffff16565b8490615357565b925050505b61337c82602001516121af670de0b6b3a76400006112528587600001516152a290919063ffffffff16565b979650505050505050565b603f54600090839081106133fc57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613404612470565b1561347057604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b600160025414156134e257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b60016002556134ef615a10565b603f85815481106134fc57fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff620100009091041615801561010083015290915061360557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b61360e85614b97565b6136188585614c8d565b600060025595945050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146136ac57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600f60248201527f4f574e455220464f5242494444454e0000000000000000000000000000000000604482015290519081900360640190fd5b60015473ffffffffffffffffffffffffffffffffffffffff8281169116141561373657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4f776e65723a204e4f204348414e474500000000000000000000000000000000604482015290519081900360640190fd5b60015460405173ffffffffffffffffffffffffffffffffffffffff80841692169033907f381c0d11398486654573703c51ee8210ce9461764d133f9f0e53b6a53970533190600090a4600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b603d5481565b6137d4612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480613824575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61388f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b815183511480156138a1575080518251145b61390c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b831561391a5761391a612479565b60005b83518110156139745761396c600085838151811061393757fe5b602002602001015185848151811061394b57fe5b602002602001015185858151811061395f57fe5b60200260200101516113e9565b60010161391d565b5050505050565b600080600083603f8054905081106139f457604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b6000603f8681548110613a0357fe5b60009182526020909120603854600890920201915073ffffffffffffffffffffffffffffffffffffffff1615801590613a4657508060030154613a44614aeb565b115b8015613a5457506000604154115b15613aa9576000613a708260030154613a6b614aeb565b61295b565b90506000613a97604154611252856002015461296c603d54876152a290919063ffffffff16565b965060009550439450613ab592505050565b60008043945094509450505b509193909250565b603f5460009083908110613b3257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613b3a612470565b15613ba657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b60016002541415613c1857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604482015290519081900360640190fd5b6001600255613c25615a10565b603f8581548110613c3257fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff9081168452600182015416938301939093526002830154908201526003820154606082015260048201546080820152600582015460a0820152600682015460c082015260079091015461ffff811660e083015260ff6201000090910416158015610100830152909150613d3b57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f706f6f6c20697320706175736564000000000000000000000000000000000000604482015290519081900360640190fd5b613d4485614b97565b6136188585614f1e565b600354610100900460ff1680613d675750613d67615557565b80613d75575060035460ff16155b613dca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e815260200180615af6602e913960400191505060405180910390fd5b600354610100900460ff16158015613e3057600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909116610100171660011790555b73ffffffffffffffffffffffffffffffffffffffff8816613eb257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b60018054337fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915560368054821673ffffffffffffffffffffffffffffffffffffffff8b8116919091179091556037805483168a8316179055603880548316898316179055603c80548316888316179055603e8054909216908616179055603d83905560428290558015613f6e57600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b5050505050505050565b600080600083603f805490508110613ff157604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b613ff9615a10565b603f868154811061400657fe5b600091825260209182902060408051610120810182526008909302909101805473ffffffffffffffffffffffffffffffffffffffff908116845260018201548116948401949094526002810154918301919091526003810154606083015260048101546080830152600581015460a0830152600681015460c08301526007015461ffff811660e083015260ff6201000090910416151561010082015260375490925016158015906141605750603754604080517ff25f4b560000000000000000000000000000000000000000000000000000000081529051309273ffffffffffffffffffffffffffffffffffffffff169163f25f4b56916004808301926020929190829003018186803b15801561411c57600080fd5b505afa158015614130573d6000803e3d6000fd5b505050506040513d602081101561414657600080fd5b505173ffffffffffffffffffffffffffffffffffffffff16145b15613aa957603754602080830151604080517f8d5db68400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015290516000949290921692638d5db68492602480840193829003018186803b1580156141dc57600080fd5b505afa1580156141f0573d6000803e3d6000fd5b505050506040513d602081101561420657600080fd5b5051603b549091506000901561423357603b54614224908390615315565b9050614230828261507b565b91505b9095509350439250613ab59050565b603b5481565b614250612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806142bb575061428c614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b806142dd575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61434857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b80518251146143b857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b6143c0612479565b60005b825181101561313c5761442f8282815181106143db57fe5b6020026020010151614429603f8685815181106143f457fe5b60200260200101518154811061440657fe5b90600052602060002090600802016002015460415461507b90919063ffffffff16565b90615357565b604155815182908290811061444057fe5b6020026020010151603f84838151811061445657fe5b60200260200101518154811061446857fe5b60009182526020909120600260089092020101556001016143c3565b60436020526000908152604090205460ff1681565b6144a1612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061450c57506144dd614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b8061452e575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61459957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b805182511461460957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f696e76616c696420706172616d73000000000000000000000000000000000000604482015290519081900360640190fd5b60005b825181101561313c5781818151811061462157fe5b6020026020010151603f84838151811061463757fe5b60200260200101518154811061464957fe5b60009182526020909120600760089092020101805491151562010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff90921691909117905560010161460c565b603f548490811061470a57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f506f6f6c20646f6573206e6f7420657869737400000000000000000000000000604482015290519081900360640190fd5b614712612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061477d575061474e614b0b565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b8061479f575060015473ffffffffffffffffffffffffffffffffffffffff1633145b61480a57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6d616e6167657220464f5242494444454e000000000000000000000000000000604482015290519081900360640190fd5b6127108361ffff16111561487f57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f6465706f73697446656542502073686f756c64206265203c3d31303030302100604482015290519081900360640190fd5b851561488d5761488d612479565b6148a184614429603f888154811061440657fe5b60418190555083603f86815481106148b557fe5b90600052602060002090600802016002018190555082603f86815481106148d857fe5b906000526020600020906008020160070160006101000a81548161ffff021916908361ffff16021790555081603f868154811061491157fe5b906000526020600020906008020160070160026101000a81548160ff021916908315150217905550505050505050565b60396020526000908152604090205481565b61495b612db3565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806149ab575060015473ffffffffffffffffffffffffffffffffffffffff1633145b614a1657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f64657620464f5242494444454e00000000000000000000000000000000000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8216614a9857604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f7a65726f20616464726573730000000000000000000000000000000000000000604482015290519081900360640190fd5b6036805473ffffffffffffffffffffffffffffffffffffffff9384167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915560378054929093169116179055565b4390565b60385473ffffffffffffffffffffffffffffffffffffffff1681565b60008054610100900473ffffffffffffffffffffffffffffffffffffffff1615612e7257600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f851a4406040518163ffffffff1660e01b815260040160206040518083038186803b158015612e3f57600080fd5b6000603f8281548110614ba657fe5b906000526020600020906008020190506000614bc0614aeb565b905081600301548111614bd4575050614c8a565b60068201541580614be757506002820154155b15614bf757600390910155614c8a565b6000614c028461555d565b50509050614c37614c2c8460060154611252670de0b6b3a7640000856152a290919063ffffffff16565b600485015490615357565b60048401556000614c47856155ae565b50509050614c7c614c718560060154611252670de0b6b3a7640000856152a290919063ffffffff16565b600586015490615357565b600585015550506003909101555b50565b60385460009073ffffffffffffffffffffffffffffffffffffffff16614cb557506000612975565b614cbd615a10565b603f8481548110614cca57fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff90811685526001808301549091168585015260028201548584015260038201546060860152600482015460808601908152600583015460a0870152600683015460c087015260079092015461ffff811660e087015260ff62010000909104161515610100860152898652828452828620338752909352932090810154925181549294509092614da19290916121af91670de0b6b3a76400009161125291906152a2565b92506000603860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663159090bd6040518163ffffffff1660e01b815260040160206040518083038186803b158015614e0d57600080fd5b505afa158015614e21573d6000803e3d6000fd5b505050506040513d6020811015614e3757600080fd5b5051905080841115614e47578093505b603854604080517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff888116600483015260248201889052915191909216916340c10f199160448083019260209291908290030181600087803b158015614ec357600080fd5b505af1158015614ed7573d6000803e3d6000fd5b505050506040513d6020811015614eed57600080fd5b505060808301518254614f0d91670de0b6b3a764000091611252916152a2565b826001018190555050505092915050565b60375460009073ffffffffffffffffffffffffffffffffffffffff16614f4657506000612975565b614f4e615a10565b603f8481548110614f5b57fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff908116855260018201541684840152600280820154858401526003820154606086015260048201546080860152600582015460a08601908152600683015460c087015260079092015461ffff811660e087015260ff620100009091041615156101008601528986528284528286203387529093529084209182015490518254939550919392615030926121af91670de0b6b3a76400009161125291906152a2565b905061504183602001518683615811565b935061506a670de0b6b3a76400006112528560a0015185600001546152a290919063ffffffff16565b826002018190555050505092915050565b600061297283836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506158e0565b6040805173ffffffffffffffffffffffffffffffffffffffff8481166024830152604480830185905283518084039091018152606490920183526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001781529251825160009485946060948a16939092909182918083835b6020831061519557805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe09092019160209182019101615158565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d80600081146151f7576040519150601f19603f3d011682016040523d82523d6000602084013e6151fc565b606091505b509150915081801561522a57508051158061522a575080806020019051602081101561522757600080fd5b50515b61529557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f736166655472616e736665723a205452414e534645525f4641494c4544000000604482015290519081900360640190fd5b83925050505b9392505050565b6000826152b157506000612975565b828202828482816152be57fe5b0414612972576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180615ad56021913960400191505060405180910390fd5b600061297283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250615991565b60008282018381101561297257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6153d3612470565b61543e57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001681556040517fa45f47fdea8a1efdd9029a5691c7f759c32b7c698632b563573e155625d169339190a1565b615497612470565b1561550357604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011781556040517f9e87fac88ff661f02d44f95383c817fece4bce600a3dab7a54406878b965e7529190a1565b303b1590565b6038546000908190819073ffffffffffffffffffffffffffffffffffffffff1661558f575060009150819050436155a7565b60008061559b8661397b565b50909550935043925050505b9193909250565b6037546000908190819073ffffffffffffffffffffffffffffffffffffffff166155e0575060009150819050436155a7565b6000806155ec86613f78565b5090925090506155fc8282615357565b615611576000804394509450945050506155a7565b615619615a10565b603f878154811061562657fe5b6000918252602080832060408051610120810182526008909402909101805473ffffffffffffffffffffffffffffffffffffffff908116855260018201548116858501819052600283015486850152600383015460608701526004808401546080880152600584015460a0880152600684015460c088015260079093015461ffff811660e088015260ff6201000090910416151561010087015260375484517f305854bb000000000000000000000000000000000000000000000000000000008152938401919091529251949650919091169363305854bb93602480840194939192918390030190829087803b15801561571f57600080fd5b505af1158015615733573d6000803e3d6000fd5b505050506040513d602081101561574957600080fd5b505160208281015173ffffffffffffffffffffffffffffffffffffffff166000908152603990915260409020549093506157839084615357565b60208083015173ffffffffffffffffffffffffffffffffffffffff16600090815260399091526040812091909155603b549092501561580357603b546157ca908490615315565b6020820151603c549193506157f59173ffffffffffffffffffffffffffffffffffffffff1684615811565b50615800838361507b565b92505b509095909450439350915050565b6000808473ffffffffffffffffffffffffffffffffffffffff166370a08231306040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561587b57600080fd5b505afa15801561588f573d6000803e3d6000fd5b505050506040513d60208110156158a557600080fd5b5051905082156158d757806158be57600091505061529b565b808311156158ca578092505b6158d58585856150bd565b505b50909392505050565b60008184841115615989576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561594e578181015183820152602001615936565b50505050905090810190601f16801561597b5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600081836159fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181815283516024840152835190928392604490910191908501908083836000831561594e578181015183820152602001615936565b506000838581615a0657fe5b0495945050505050565b604051806101200160405280600073ffffffffffffffffffffffffffffffffffffffff168152602001600073ffffffffffffffffffffffffffffffffffffffff1681526020016000815260200160008152602001600081526020016000815260200160008152602001600061ffff1681526020016000151581525090565b6040518060600160405280600081526020016000815260200160008152509056fe6164643a20696e76616c6964206465706f7369742066656520626173697320706f696e7473536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77436f6e747261637420696e7374616e63652068617320616c7265616479206265656e20696e697469616c697a6564a164736f6c634300060c000a

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

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

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