ETH Price: $3,449.41 (+0.82%)
Gas: 7 Gwei

Contract

0x4512C81c2A88eA83539b535988Cbe2F454d373b5
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00
Transaction Hash
Method
Block
From
To
Deposit198756532024-05-15 13:22:4762 days ago1715779367IN
0x4512C81c...454d373b5
0 ETH0.005494189.01891177
Deposit198756002024-05-15 13:12:1162 days ago1715778731IN
0x4512C81c...454d373b5
0 ETH0.0067240410.13974318
Deposit194541112024-03-17 10:56:11122 days ago1710672971IN
0x4512C81c...454d373b5
0 ETH0.0210715924.93273281
Deposit194068012024-03-10 19:31:35128 days ago1710099095IN
0x4512C81c...454d373b5
0 ETH0.0349464152.36140033
Deposit190548772024-01-21 11:16:11178 days ago1705835771IN
0x4512C81c...454d373b5
0 ETH0.0070848610.50331861
Deposit190541672024-01-21 8:52:59178 days ago1705827179IN
0x4512C81c...454d373b5
0 ETH0.006490219.56295301
Deposit189579742024-01-07 21:48:59191 days ago1704664139IN
0x4512C81c...454d373b5
0 ETH0.0216645432.05084802
Deposit189120062024-01-01 10:30:35198 days ago1704105035IN
0x4512C81c...454d373b5
0 ETH0.005892539.74540333
Deposit188865242023-12-28 20:37:11201 days ago1703795831IN
0x4512C81c...454d373b5
0.1 ETH0.0149264620.48594096
Deposit186759282023-11-29 7:58:35231 days ago1701244715IN
0x4512C81c...454d373b5
0 ETH0.0209615731.01086624
Deposit186486632023-11-25 12:18:35234 days ago1700914715IN
0x4512C81c...454d373b5
0 ETH0.0152694122.49511538
Deposit186462772023-11-25 4:18:11235 days ago1700885891IN
0x4512C81c...454d373b5
0 ETH0.0131996318.85995775
Deposit184751412023-11-01 5:22:23259 days ago1698816143IN
0x4512C81c...454d373b5
0 ETH0.0091985813.51422879
Deposit184588612023-10-29 22:38:11261 days ago1698619091IN
0x4512C81c...454d373b5
0 ETH0.0117363717.36297205
Deposit184060752023-10-22 13:15:47268 days ago1697980547IN
0x4512C81c...454d373b5
0.3 ETH0.005616458.41229045
Deposit184045362023-10-22 8:05:59269 days ago1697961959IN
0x4512C81c...454d373b5
0 ETH0.004607757.4092278
Deposit183916612023-10-20 12:53:47270 days ago1697806427IN
0x4512C81c...454d373b5
1.12 ETH0.0089618713.53716683
Deposit183861792023-10-19 18:30:35271 days ago1697740235IN
0x4512C81c...454d373b5
0.01 ETH0.0055538611.69768704
Deposit183859062023-10-19 17:35:59271 days ago1697736959IN
0x4512C81c...454d373b5
0 ETH0.005643839.11720146
Deposit183782492023-10-18 15:52:23272 days ago1697644343IN
0x4512C81c...454d373b5
0 ETH0.0093695213.92167247
Deposit183574512023-10-15 18:05:23275 days ago1697393123IN
0x4512C81c...454d373b5
0 ETH0.004182396.91746785
Deposit183569642023-10-15 16:27:11275 days ago1697387231IN
0x4512C81c...454d373b5
0.0203604 ETH0.003917955.65038427
Deposit183340402023-10-12 11:28:59279 days ago1697110139IN
0x4512C81c...454d373b5
0 ETH0.003951996.1984431
Deposit183294962023-10-11 20:12:47279 days ago1697055167IN
0x4512C81c...454d373b5
0 ETH0.005077147.96302854
Deposit183277292023-10-11 14:13:59279 days ago1697033639IN
0x4512C81c...454d373b5
0 ETH0.0071683911.87996314
View all transactions

Latest 20 internal transactions

Advanced mode:
Parent Transaction Hash Block From To
188865242023-12-28 20:37:11201 days ago1703795831
0x4512C81c...454d373b5
0.1 ETH
184060752023-10-22 13:15:47268 days ago1697980547
0x4512C81c...454d373b5
0.3 ETH
183916612023-10-20 12:53:47270 days ago1697806427
0x4512C81c...454d373b5
1.12 ETH
183861792023-10-19 18:30:35271 days ago1697740235
0x4512C81c...454d373b5
0.01 ETH
183569642023-10-15 16:27:11275 days ago1697387231
0x4512C81c...454d373b5
0.0203604 ETH
183235392023-10-11 0:09:59280 days ago1696982999
0x4512C81c...454d373b5
0.011 ETH
183007992023-10-07 19:48:47283 days ago1696708127
0x4512C81c...454d373b5
0.6 ETH
182876362023-10-05 23:38:35285 days ago1696549115
0x4512C81c...454d373b5
0.75 ETH
182662272023-10-02 23:46:59288 days ago1696290419
0x4512C81c...454d373b5
1 ETH
182477922023-09-30 10:01:23291 days ago1696068083
0x4512C81c...454d373b5
1 ETH
182200812023-09-26 12:54:35294 days ago1695732875
0x4512C81c...454d373b5
0.4 ETH
181999392023-09-23 17:15:11297 days ago1695489311
0x4512C81c...454d373b5
0.815 ETH
181804032023-09-20 23:32:23300 days ago1695252743
0x4512C81c...454d373b5
1 ETH
181723972023-09-19 20:39:47301 days ago1695155987
0x4512C81c...454d373b5
1.5 ETH
181698852023-09-19 12:13:59301 days ago1695125639
0x4512C81c...454d373b5
1.5 ETH
181018692023-09-09 22:40:11311 days ago1694299211
0x4512C81c...454d373b5
0.75 ETH
180765612023-09-06 9:37:11315 days ago1693993031
0x4512C81c...454d373b5
2.47 ETH
180755922023-09-06 6:20:23315 days ago1693981223
0x4512C81c...454d373b5
0.6696369 ETH
180704052023-09-05 12:53:47315 days ago1693918427
0x4512C81c...454d373b5
0.01 ETH
180438252023-09-01 19:36:47319 days ago1693597007
0x4512C81c...454d373b5
0.1 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
LitDepositorHelper

Compiler Version
v0.8.11+commit.d7f03943

Optimization Enabled:
Yes with 1000 runs

Other Settings:
default evmVersion
File 1 of 9 : LitDepositorHelper.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

import { IERC20 } from "@openzeppelin/contracts-0.8/token/ERC20/IERC20.sol";
import { SafeERC20 } from "@openzeppelin/contracts-0.8/token/ERC20/utils/SafeERC20.sol";
import { ReentrancyGuard } from "@openzeppelin/contracts-0.8/security/ReentrancyGuard.sol";
import { IBalancerVault } from "../interfaces/balancer/IBalancerCore.sol";
import { ILitDepositorHelper } from "../interfaces/ILitDepositorHelper.sol";
import { ICrvDepositor } from "../interfaces/ICrvDepositor.sol";
import { BalInvestor } from "./BalInvestor.sol";

interface IWETH {
    function deposit() external payable;
}

/**
 * @title   LitDepositorHelper
 * @notice  Converts LIT -> balBPT and then wraps to liqLIT via the crvDepositor
 */
contract LitDepositorHelper is ILitDepositorHelper, BalInvestor, ReentrancyGuard {
    using SafeERC20 for IERC20;

    address internal constant ETH = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;

    address public immutable crvDeposit;

    constructor(
        address _crvDeposit,
        IBalancerVault _balancerVault,
        address _lit,
        address _weth,
        bytes32 _balETHPoolId
    ) BalInvestor(_balancerVault, _lit, _weth, _balETHPoolId) {
        crvDeposit = _crvDeposit;
    }

    function setApprovals() external {
        _setApprovals();
        require(IERC20(BALANCER_POOL_TOKEN).approve(crvDeposit, type(uint256).max), "!approval");
    }

    /**
     * @dev Gets minimum output based on BPT oracle price
     * @param _amount Units of LIT to deposit
     * @param _outputBps Multiplier where 100% == 10000, 99.5% == 9950 and 98% == 9800
     * @param _asset Address of the asset to query minOut
     * @return minOut Units of BPT to expect as output
     */
    function getMinOut(
        uint256 _amount,
        uint256 _outputBps,
        address _asset
    ) external view returns (uint256) {
        require(_asset == LIT || _asset == ETH || _asset == WETH, "!asset");
        return (_asset == LIT) ? _getMinOut(_amount, _outputBps, 1) : _getMinOut(_amount, _outputBps, 0);
    }

    function deposit(
        uint256 _amount,
        uint256 _minOut,
        bool _lock,
        address _stakeAddress,
        address _asset
    ) external payable nonReentrant returns (uint256 bptOut) {
        bptOut = _depositFor(msg.sender, _amount, _minOut, _lock, _stakeAddress, _asset);
    }

    function depositFor(
        address _for,
        uint256 _amount,
        uint256 _minOut,
        bool _lock,
        address _stakeAddress,
        address _asset
    ) external payable nonReentrant returns (uint256 bptOut) {
        bptOut = _depositFor(_for, _amount, _minOut, _lock, _stakeAddress, _asset);
    }

    function _depositFor(
        address _for,
        uint256 _amount,
        uint256 _minOut,
        bool _lock,
        address _stakeAddress,
        address _asset
    ) internal returns (uint256 bptOut) {
        require(_asset == LIT || _asset == ETH || _asset == WETH, "!asset");

        if (_asset == LIT) {
            IERC20(LIT).safeTransferFrom(msg.sender, address(this), _amount);
            _investSingleToPool(_amount, _minOut, 1);
        } else if (_asset == ETH) {
            IWETH(WETH).deposit{ value: _amount }();
            _investSingleToPool(_amount, _minOut, 0);
        } else {
            IERC20(WETH).safeTransferFrom(msg.sender, address(this), _amount);
            _investSingleToPool(_amount, _minOut, 0);
        }

        bptOut = IERC20(BALANCER_POOL_TOKEN).balanceOf(address(this));
        ICrvDepositor(crvDeposit).depositFor(_for, bptOut, _lock, _stakeAddress);
    }

    /**
     * @dev Converts LIT to LIT/WETH and sends BPT to user
     * @param _amount Units of LIT to deposit
     * @param _minOut Units of BPT to expect as output
     */
    function convertLitToBpt(uint256 _amount, uint256 _minOut) external returns (uint256 bptOut) {
        IERC20(LIT).safeTransferFrom(msg.sender, address(this), _amount);
        _investSingleToPool(_amount, _minOut, 1);

        bptOut = IERC20(BALANCER_POOL_TOKEN).balanceOf(address(this));
        if (bptOut > 0) {
            IERC20(BALANCER_POOL_TOKEN).safeTransfer(msg.sender, bptOut);
        }
    }

    /**
     * @dev Converts WETH to LIT/WETH and sends BPT to user
     * @param _amount Units of WETH to deposit
     * @param _minOut Units of BPT to expect as output
     */
    function convertWethToBpt(uint256 _amount, uint256 _minOut) external returns (uint256 bptOut) {
        IERC20(WETH).safeTransferFrom(msg.sender, address(this), _amount);
        _investSingleToPool(_amount, _minOut, 0);

        bptOut = IERC20(BALANCER_POOL_TOKEN).balanceOf(address(this));
        if (bptOut > 0) {
            IERC20(BALANCER_POOL_TOKEN).safeTransfer(msg.sender, bptOut);
        }
    }

    /**
     * @dev Converts ETH to LIT/WETH and sends BPT to user
     * @param _minOut Units of BPT to expect as output
     */
    function convertEthToBpt(uint256 _minOut) external payable nonReentrant returns (uint256 bptOut) {
        IWETH(WETH).deposit{ value: msg.value }();
        _investSingleToPool(msg.value, _minOut, 0);

        bptOut = IERC20(BALANCER_POOL_TOKEN).balanceOf(address(this));
        if (bptOut > 0) {
            IERC20(BALANCER_POOL_TOKEN).safeTransfer(msg.sender, bptOut);
        }
    }
}

File 2 of 9 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

File 3 of 9 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

File 4 of 9 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol)

pragma solidity ^0.8.0;

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

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

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and making 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 5 of 9 : IBalancerCore.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

import { IERC20 } from "@openzeppelin/contracts-0.8/token/ERC20/IERC20.sol";

interface IPriceOracle {
    struct OracleAverageQuery {
        Variable variable;
        uint256 secs;
        uint256 ago;
    }
    enum Variable {
        PAIR_PRICE,
        BPT_PRICE,
        INVARIANT
    }

    function getTimeWeightedAverage(OracleAverageQuery[] memory queries)
        external
        view
        returns (uint256[] memory results);
}

interface IBalancerVault {
    enum PoolSpecialization {
        GENERAL,
        MINIMAL_SWAP_INFO,
        TWO_TOKEN
    }
    enum JoinKind {
        INIT,
        EXACT_TOKENS_IN_FOR_BPT_OUT,
        TOKEN_IN_FOR_EXACT_BPT_OUT,
        ALL_TOKENS_IN_FOR_EXACT_BPT_OUT
    }

    enum SwapKind {
        GIVEN_IN,
        GIVEN_OUT
    }

    struct BatchSwapStep {
        bytes32 poolId;
        uint256 assetInIndex;
        uint256 assetOutIndex;
        uint256 amount;
        bytes userData;
    }

    function batchSwap(
        SwapKind kind,
        BatchSwapStep[] memory swaps,
        IAsset[] memory assets,
        FundManagement memory funds,
        int256[] memory limits,
        uint256 deadline
    ) external payable returns (int256[] memory);

    struct SingleSwap {
        bytes32 poolId;
        SwapKind kind;
        IAsset assetIn;
        IAsset assetOut;
        uint256 amount;
        bytes userData;
    }

    struct FundManagement {
        address sender;
        bool fromInternalBalance;
        address payable recipient;
        bool toInternalBalance;
    }

    struct JoinPoolRequest {
        IAsset[] assets;
        uint256[] maxAmountsIn;
        bytes userData;
        bool fromInternalBalance;
    }

    function getPool(bytes32 poolId) external view returns (address, PoolSpecialization);

    function getPoolTokens(bytes32 poolId)
        external
        view
        returns (
            address[] memory tokens,
            uint256[] memory balances,
            uint256 lastChangeBlock
        );

    function joinPool(
        bytes32 poolId,
        address sender,
        address recipient,
        JoinPoolRequest memory request
    ) external payable;

    function swap(
        SingleSwap memory singleSwap,
        FundManagement memory funds,
        uint256 limit,
        uint256 deadline
    ) external returns (uint256 amountCalculated);

    function exitPool(
        bytes32 poolId,
        address sender,
        address payable recipient,
        ExitPoolRequest memory request
    ) external;

    function getInternalBalance(address user, address[] memory tokens) external view returns (uint256[] memory);

    function queryBatchSwap(
        SwapKind kind,
        BatchSwapStep[] memory swaps,
        IAsset[] memory assets,
        FundManagement memory funds
    ) external returns (int256[] memory assetDeltas);

    struct ExitPoolRequest {
        IAsset[] assets;
        uint256[] minAmountsOut;
        bytes userData;
        bool toInternalBalance;
    }
    enum ExitKind {
        EXACT_BPT_IN_FOR_ONE_TOKEN_OUT,
        EXACT_BPT_IN_FOR_TOKENS_OUT,
        BPT_IN_FOR_EXACT_TOKENS_OUT,
        MANAGEMENT_FEE_TOKENS_OUT // for ManagedPool
    }
}

interface IAsset {
    // solhint-disable-previous-line no-empty-blocks
}

interface IBalancerPool {
    function getPoolId() external view returns (bytes32);

    function getNormalizedWeights() external view returns (uint256[] memory);

    function getSwapEnabled() external view returns (bool);

    function getOwner() external view returns (address);

    function totalSupply() external view returns (uint256);

    function balanceOf(address account) external view returns (uint256);
}

interface ILBPFactory {
    function create(
        string memory name,
        string memory symbol,
        IERC20[] memory tokens,
        uint256[] memory weights,
        uint256 swapFeePercentage,
        address owner,
        bool swapEnabledOnStart
    ) external returns (address);
}

interface ILBP {
    function setSwapEnabled(bool swapEnabled) external;

    function updateWeightsGradually(
        uint256 startTime,
        uint256 endTime,
        uint256[] memory endWeights
    ) external;

    function getGradualWeightUpdateParams()
        external
        view
        returns (
            uint256 startTime,
            uint256 endTime,
            uint256[] memory endWeights
        );
}

interface IStablePoolFactory {
    function create(
        string memory name,
        string memory symbol,
        IERC20[] memory tokens,
        uint256 amplificationParameter,
        uint256 swapFeePercentage,
        address owner
    ) external returns (address);
}

interface IWeightedPool2TokensFactory {
    function create(
        string memory name,
        string memory symbol,
        IERC20[] memory tokens,
        uint256[] memory weights,
        uint256 swapFeePercentage,
        bool oracleEnabled,
        address owner
    ) external returns (address);
}

interface IRateProvider {
    function getRate() external view returns (uint256);
}

interface IWeightedPoolFactory {
    /**
     * @dev Deploys a new `WeightedPool`.
     */
    function create(
        string memory name,
        string memory symbol,
        IERC20[] memory tokens,
        uint256[] memory normalizedWeights,
        IRateProvider[] memory rateProviders,
        uint256 swapFeePercentage,
        address owner
    ) external returns (address);
}

File 6 of 9 : ILitDepositorHelper.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

interface ILitDepositorHelper {
    function deposit(
        uint256 _amount,
        uint256 _minOut,
        bool _lock,
        address _stakeAddress,
        address _asset
    ) external payable returns (uint256 bptOut);

    function depositFor(
        address _for,
        uint256 _amount,
        uint256 _minOut,
        bool _lock,
        address _stakeAddress,
        address _asset
    ) external payable returns (uint256 bptOut);

    function convertLitToBpt(uint256 _amount, uint256 _minOut) external returns (uint256 bptOut);

    function convertWethToBpt(uint256 _amount, uint256 _minOut) external returns (uint256 bptOut);

    function convertEthToBpt(uint256 _minOut) external payable returns (uint256 bptOut);
}

File 7 of 9 : ICrvDepositor.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

interface ICrvDepositor {
    function depositFor(
        address to,
        uint256 _amount,
        bool _lock,
        address _stakeAddress
    ) external;
}

File 8 of 9 : BalInvestor.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;
pragma abicoder v2;

import { IERC20 } from "@openzeppelin/contracts-0.8/token/ERC20/IERC20.sol";
import { SafeERC20 } from "@openzeppelin/contracts-0.8/token/ERC20/utils/SafeERC20.sol";
import { IBalancerVault, IPriceOracle, IAsset } from "../interfaces/balancer/IBalancerCore.sol";

/**
 * @title   BalInvestor
 * @notice  Deposits LIT or WETH into a LIT/WETH BPT. Hooks into TWAP to determine minOut.
 * @dev     Abstract contract for depositing LIT -> balBPT -> auraBAL via crvDepositor
 */
abstract contract BalInvestor {
    using SafeERC20 for IERC20;

    IBalancerVault public immutable BALANCER_VAULT;
    address public immutable LIT;
    address public immutable WETH;
    address public immutable BALANCER_POOL_TOKEN;
    bytes32 public immutable BAL_ETH_POOL_ID;

    constructor(
        IBalancerVault _balancerVault,
        address _lit,
        address _weth,
        bytes32 _balETHPoolId
    ) {
        (
            address poolAddress, /* */

        ) = _balancerVault.getPool(_balETHPoolId);
        require(poolAddress != address(0), "!poolAddress");

        BALANCER_VAULT = _balancerVault;
        LIT = _lit;
        WETH = _weth;
        BALANCER_POOL_TOKEN = poolAddress;
        BAL_ETH_POOL_ID = _balETHPoolId;
    }

    function _setApprovals() internal {
        IERC20(WETH).safeApprove(address(BALANCER_VAULT), type(uint256).max);
        IERC20(LIT).safeApprove(address(BALANCER_VAULT), type(uint256).max);
    }

    function _getBptPrice() internal view returns (uint256) {
        IPriceOracle.OracleAverageQuery[] memory queries = new IPriceOracle.OracleAverageQuery[](1);

        queries[0].variable = IPriceOracle.Variable.BPT_PRICE;
        queries[0].secs = 3600; // last hour
        queries[0].ago = 0; // now

        // Gets the balancer time weighted average price denominated in LIT
        return IPriceOracle(BALANCER_POOL_TOKEN).getTimeWeightedAverage(queries)[0];
    }

    function _getPairPrice() internal view returns (uint256) {
        IPriceOracle.OracleAverageQuery[] memory queries = new IPriceOracle.OracleAverageQuery[](1);

        queries[0].variable = IPriceOracle.Variable.PAIR_PRICE;
        queries[0].secs = 3600; // last hour
        queries[0].ago = 0; // now

        // Gets the balancer time weighted average price for LIT in ETH
        // e.g LIT price is 0.10$ and ETH price is 1800$ -> return 0.56e14
        return IPriceOracle(BALANCER_POOL_TOKEN).getTimeWeightedAverage(queries)[0];
    }

    function _getMinOut(
        uint256 amount,
        uint256 minOutBps,
        uint256 asset
    ) internal view returns (uint256) {
        require(asset == 0 || asset == 1, "!asset");

        // Gets the balancer time weighted average price denominated in WETH
        // e.g.  if 1 WETH == 0.4 BPT, bptOraclePrice == 2.5
        uint256 bptOraclePrice = _getBptPrice(); // e.g bptOraclePrice = 3.52e14

        if (asset == 1) {
            // get min out for LIT in
            uint256 pairOraclePrice = _getPairPrice(); // e.g pairOraclePrice = 0.56e14
            bptOraclePrice = (bptOraclePrice * 1e18) / pairOraclePrice; // e.g bptOraclePriceInLit = 6.28e18
        }

        // e.g. minOut = (((100e18 * 1e18) / 2.5e18) * 9980) / 10000;
        // e.g. minout = 39.92e18
        uint256 minOut = (((amount * 1e18) / bptOraclePrice) * minOutBps) / 10000;
        return minOut;
    }

    // invest either WETH or LIT in BAL-20WETH-80LIT pool
    function _investSingleToPool(
        uint256 amount,
        uint256 minOut,
        uint256 asset
    ) internal {
        IAsset[] memory assets = new IAsset[](2);
        assets[0] = IAsset(WETH);
        assets[1] = IAsset(LIT);
        uint256[] memory maxAmountsIn = new uint256[](2);

        // asset == 0: invest WETH, asset == 1: invest LIT
        if (asset == 0) {
            maxAmountsIn[0] = amount;
            maxAmountsIn[1] = 0;
        } else {
            maxAmountsIn[0] = 0;
            maxAmountsIn[1] = amount;
        }

        BALANCER_VAULT.joinPool(
            BAL_ETH_POOL_ID,
            address(this),
            address(this),
            IBalancerVault.JoinPoolRequest(
                assets,
                maxAmountsIn,
                abi.encode(IBalancerVault.JoinKind.EXACT_TOKENS_IN_FOR_BPT_OUT, maxAmountsIn, minOut),
                false // Don't use internal balances
            )
        );
    }
}

File 9 of 9 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Address.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 1000
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "metadata": {
    "useLiteralContent": true
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_crvDeposit","type":"address"},{"internalType":"contract IBalancerVault","name":"_balancerVault","type":"address"},{"internalType":"address","name":"_lit","type":"address"},{"internalType":"address","name":"_weth","type":"address"},{"internalType":"bytes32","name":"_balETHPoolId","type":"bytes32"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"BALANCER_POOL_TOKEN","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BALANCER_VAULT","outputs":[{"internalType":"contract IBalancerVault","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BAL_ETH_POOL_ID","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LIT","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WETH","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minOut","type":"uint256"}],"name":"convertEthToBpt","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"}],"name":"convertLitToBpt","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"}],"name":"convertWethToBpt","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"crvDeposit","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"bool","name":"_lock","type":"bool"},{"internalType":"address","name":"_stakeAddress","type":"address"},{"internalType":"address","name":"_asset","type":"address"}],"name":"deposit","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_for","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_minOut","type":"uint256"},{"internalType":"bool","name":"_lock","type":"bool"},{"internalType":"address","name":"_stakeAddress","type":"address"},{"internalType":"address","name":"_asset","type":"address"}],"name":"depositFor","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"uint256","name":"_outputBps","type":"uint256"},{"internalType":"address","name":"_asset","type":"address"}],"name":"getMinOut","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"setApprovals","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101406040523480156200001257600080fd5b5060405162001f2138038062001f2183398101604081905262000035916200014f565b838383836000846001600160a01b031663f6c00927836040518263ffffffff1660e01b81526004016200006a91815260200190565b6040805180830381865afa15801562000087573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620000ad9190620001c3565b5090506001600160a01b038116620000fa5760405162461bcd60e51b815260206004820152600c60248201526b21706f6f6c4164647265737360a01b604482015260640160405180910390fd5b6001600160a01b0394851660805292841660a05290831660c05290821660e0526101005260016000559490941661012052506200020592505050565b6001600160a01b03811681146200014c57600080fd5b50565b600080600080600060a086880312156200016857600080fd5b8551620001758162000136565b6020870151909550620001888162000136565b60408701519094506200019b8162000136565b6060870151909350620001ae8162000136565b80925050608086015190509295509295909350565b60008060408385031215620001d757600080fd5b8251620001e48162000136565b602084015190925060038110620001fa57600080fd5b809150509250929050565b60805160a05160c05160e0516101005161012051611c01620003206000396000818161025b0152818161054a01526110fc0152600081816101d30152610b6b01526000818161018801528181610342015281816103ca0152818161057a01528181610859015281816108e1015281816110370152611333015260008181610227015281816102f90152818161045d015281816107c6015281816109ec01528181610d4e01528181610e5301528181610f630152610fee01526000818161011c015281816103fb015281816104cd0152818161064401528181610a4001528181610da401528181610df101528181610ebe0152610f0301526000818161028f01528181610b3c01528181610d700152610dc60152611c016000f3fe6080604052600436106100d25760003560e01c80639759fdf31161007f578063bc16384611610059578063bc1638461461027d578063c33820a8146102b1578063cacad160146102c4578063ea322028146102d757600080fd5b80639759fdf3146101f5578063ad5c464814610215578063b026e2271461024957600080fd5b8063804cca0a116100b0578063804cca0a146101765780638757b15b146101aa5780638f1483f3146101c157600080fd5b8063339a9bd5146100d7578063635409ae1461010a57806376d6a5ad14610156575b600080fd5b3480156100e357600080fd5b506100f76100f236600461168b565b6102ea565b6040519081526020015b60405180910390f35b34801561011657600080fd5b5061013e7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b039091168152602001610101565b34801561016257600080fd5b506100f76101713660046116c9565b6103f7565b34801561018257600080fd5b5061013e7f000000000000000000000000000000000000000000000000000000000000000081565b3480156101b657600080fd5b506101bf61052b565b005b3480156101cd57600080fd5b506100f77f000000000000000000000000000000000000000000000000000000000000000081565b34801561020157600080fd5b506100f761021036600461168b565b610635565b34801561022157600080fd5b5061013e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561025557600080fd5b5061013e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561028957600080fd5b5061013e7f000000000000000000000000000000000000000000000000000000000000000081565b6100f76102bf36600461170f565b610678565b6100f76102d2366004611768565b6106ef565b6100f76102e53660046117d0565b610767565b60006103216001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016333086610912565b61032d838360006109c9565b6040516370a0823160e01b81523060048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a0823190602401602060405180830381865afa158015610391573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103b591906117e9565b905080156103f1576103f16001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163383610c2c565b92915050565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316148061045557506001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee145b8061049157507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316145b6104cb5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064015b60405180910390fd5b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316146105155761051084846000610c7a565b610521565b61052184846001610c7a565b90505b9392505050565b610533610d41565b60405163095ea7b360e01b81526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116600483015260001960248301527f0000000000000000000000000000000000000000000000000000000000000000169063095ea7b3906044016020604051808303816000875af11580156105c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e79190611802565b6106335760405162461bcd60e51b815260206004820152600960248201527f21617070726f76616c000000000000000000000000000000000000000000000060448201526064016104c2565b565b600061066c6001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016333086610912565b61032d838360016109c9565b6000600260005414156106cd5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b60026000556106e0338787878787610ded565b60016000559695505050505050565b6000600260005414156107445760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b6002600055610757878787878787610ded565b6001600055979650505050505050565b6000600260005414156107bc5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b60026000819055507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561081f57600080fd5b505af1158015610833573d6000803e3d6000fd5b5050505050610844348360006109c9565b6040516370a0823160e01b81523060048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a0823190602401602060405180830381865afa1580156108a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108cc91906117e9565b90508015610908576109086001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163383610c2c565b6001600055919050565b6040516001600160a01b03808516602483015283166044820152606481018290526109c39085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611164565b50505050565b6040805160028082526060820183526000926020830190803683370190505090507f000000000000000000000000000000000000000000000000000000000000000081600081518110610a1e57610a1e611835565b60200260200101906001600160a01b031690816001600160a01b0316815250507f000000000000000000000000000000000000000000000000000000000000000081600181518110610a7257610a72611835565b6001600160a01b0392909216602092830291909101820152604080516002808252606082018352600093919290918301908036833701905050905082610af8578481600081518110610ac657610ac6611835565b602002602001018181525050600081600181518110610ae757610ae7611835565b602002602001018181525050610b3a565b600081600081518110610b0d57610b0d611835565b6020026020010181815250508481600181518110610b2d57610b2d611835565b6020026020010181815250505b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663b95cac287f0000000000000000000000000000000000000000000000000000000000000000303060405180608001604052808881526020018781526020016001888c604051602001610bb993929190611861565b6040516020818303038152906040528152602001600015158152506040518563ffffffff1660e01b8152600401610bf3949392919061195b565b600060405180830381600087803b158015610c0d57600080fd5b505af1158015610c21573d6000803e3d6000fd5b505050505050505050565b6040516001600160a01b038316602482015260448101829052610c759084907fa9059cbb000000000000000000000000000000000000000000000000000000009060640161095f565b505050565b6000811580610c895750816001145b610cbe5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064016104c2565b6000610cc8611249565b90508260011415610d00576000610cdd6113e2565b905080610cf283670de0b6b3a7640000611a26565b610cfc9190611a53565b9150505b60006127108583610d1989670de0b6b3a7640000611a26565b610d239190611a53565b610d2d9190611a26565b610d379190611a53565b9695505050505050565b610d976001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000167f000000000000000000000000000000000000000000000000000000000000000060001961144b565b6106336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000167f000000000000000000000000000000000000000000000000000000000000000060001961144b565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b03161480610e4b57506001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee145b80610e8757507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b0316145b610ebc5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064016104c2565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316826001600160a01b03161415610f3c57610f2b6001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016333089610912565b610f37868660016109c9565b611022565b6001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee1415610fe1577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663d0e30db0876040518263ffffffff1660e01b81526004016000604051808303818588803b158015610fbc57600080fd5b505af1158015610fd0573d6000803e3d6000fd5b5050505050610f37868660006109c9565b6110166001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016333089610912565b611022868660006109c9565b6040516370a0823160e01b81523060048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a0823190602401602060405180830381865afa158015611086573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110aa91906117e9565b6040517f1e97b6e90000000000000000000000000000000000000000000000000000000081526001600160a01b03898116600483015260248201839052861515604483015285811660648301529192507f000000000000000000000000000000000000000000000000000000000000000090911690631e97b6e990608401600060405180830381600087803b15801561114257600080fd5b505af1158015611156573d6000803e3d6000fd5b505050509695505050505050565b60006111b9826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166115809092919063ffffffff16565b805190915015610c7557808060200190518101906111d79190611802565b610c755760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016104c2565b604080516001808252818301909252600091829190816020015b6112886040805160608101909152806000815260200160008152602001600081525090565b8152602001906001900390816112635790505090506001816000815181106112b2576112b2611835565b60200260200101516000019060028111156112cf576112cf61184b565b908160028111156112e2576112e261184b565b81525050610e10816000815181106112fc576112fc611835565b6020026020010151602001818152505060008160008151811061132157611321611835565b602002602001015160400181815250507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316631dccd830826040518263ffffffff1660e01b815260040161137d9190611a75565b600060405180830381865afa15801561139a573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526113c29190810190611ade565b6000815181106113d4576113d4611835565b602002602001015191505090565b604080516001808252818301909252600091829190816020015b6114216040805160608101909152806000815260200160008152602001600081525090565b8152602001906001900390816113fc5790505090506000816000815181106112b2576112b2611835565b8015806114de57506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03838116602483015284169063dd62ed3e90604401602060405180830381865afa1580156114b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114dc91906117e9565b155b6115505760405162461bcd60e51b815260206004820152603660248201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60448201527f20746f206e6f6e2d7a65726f20616c6c6f77616e63650000000000000000000060648201526084016104c2565b6040516001600160a01b038316602482015260448101829052610c7590849063095ea7b360e01b9060640161095f565b6060610521848460008585843b6115d95760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016104c2565b600080866001600160a01b031685876040516115f59190611b9c565b60006040518083038185875af1925050503d8060008114611632576040519150601f19603f3d011682016040523d82523d6000602084013e611637565b606091505b5091509150611647828286611652565b979650505050505050565b60608315611661575081610524565b8251156116715782518084602001fd5b8160405162461bcd60e51b81526004016104c29190611bb8565b6000806040838503121561169e57600080fd5b50508035926020909101359150565b80356001600160a01b03811681146116c457600080fd5b919050565b6000806000606084860312156116de57600080fd5b83359250602084013591506116f5604085016116ad565b90509250925092565b801515811461170c57600080fd5b50565b600080600080600060a0868803121561172757600080fd5b85359450602086013593506040860135611740816116fe565b925061174e606087016116ad565b915061175c608087016116ad565b90509295509295909350565b60008060008060008060c0878903121561178157600080fd5b61178a876116ad565b9550602087013594506040870135935060608701356117a8816116fe565b92506117b6608088016116ad565b91506117c460a088016116ad565b90509295509295509295565b6000602082840312156117e257600080fd5b5035919050565b6000602082840312156117fb57600080fd5b5051919050565b60006020828403121561181457600080fd5b8151610524816116fe565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b600060608201600486106118775761187761184b565b8583526020606081850152818651808452608086019150828801935060005b818110156118b257845183529383019391830191600101611896565b5050809350505050826040830152949350505050565b600081518084526020808501945080840160005b838110156118f8578151875295820195908201906001016118dc565b509495945050505050565b60005b8381101561191e578181015183820152602001611906565b838111156109c35750506000910152565b60008151808452611947816020860160208601611903565b601f01601f19169290920160200192915050565b848152600060206001600160a01b038087168285015280861660408501526080606085015261010084018551608080870152818151808452610120880191508583019350600092505b808310156119c6578351851682529285019260019290920191908501906119a4565b50848801519450607f199350838782030160a08801526119e681866118c8565b94505050506040850151818584030160c0860152611a04838261192f565b925050506060840151611a1b60e085018215159052565b509695505050505050565b6000816000190483118215151615611a4e57634e487b7160e01b600052601160045260246000fd5b500290565b600082611a7057634e487b7160e01b600052601260045260246000fd5b500490565b602080825282518282018190526000919060409081850190868401855b82811015611ad1578151805160038110611aae57611aae61184b565b855280870151878601528501518585015260609093019290850190600101611a92565b5091979650505050505050565b60006020808385031215611af157600080fd5b825167ffffffffffffffff80821115611b0957600080fd5b818501915085601f830112611b1d57600080fd5b815181811115611b2f57611b2f61181f565b8060051b604051601f19603f83011681018181108582111715611b5457611b5461181f565b604052918252848201925083810185019188831115611b7257600080fd5b938501935b82851015611b9057845184529385019392850192611b77565b98975050505050505050565b60008251611bae818460208701611903565b9190910192915050565b602081526000610524602083018461192f56fea264697066735822122004c1f5aacfad1e699f43a0d739c116f1b5b81b3db93d251b8546ab9f67aa856564736f6c634300080b0033000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c8000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c341000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc29232a548dd9e81bac65500b5e0d918f8ba93675c000200000000000000000423

Deployed Bytecode

0x6080604052600436106100d25760003560e01c80639759fdf31161007f578063bc16384611610059578063bc1638461461027d578063c33820a8146102b1578063cacad160146102c4578063ea322028146102d757600080fd5b80639759fdf3146101f5578063ad5c464814610215578063b026e2271461024957600080fd5b8063804cca0a116100b0578063804cca0a146101765780638757b15b146101aa5780638f1483f3146101c157600080fd5b8063339a9bd5146100d7578063635409ae1461010a57806376d6a5ad14610156575b600080fd5b3480156100e357600080fd5b506100f76100f236600461168b565b6102ea565b6040519081526020015b60405180910390f35b34801561011657600080fd5b5061013e7f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c34181565b6040516001600160a01b039091168152602001610101565b34801561016257600080fd5b506100f76101713660046116c9565b6103f7565b34801561018257600080fd5b5061013e7f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c81565b3480156101b657600080fd5b506101bf61052b565b005b3480156101cd57600080fd5b506100f77f9232a548dd9e81bac65500b5e0d918f8ba93675c00020000000000000000042381565b34801561020157600080fd5b506100f761021036600461168b565b610635565b34801561022157600080fd5b5061013e7f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc281565b34801561025557600080fd5b5061013e7f000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a81565b34801561028957600080fd5b5061013e7f000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c881565b6100f76102bf36600461170f565b610678565b6100f76102d2366004611768565b6106ef565b6100f76102e53660046117d0565b610767565b60006103216001600160a01b037f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc216333086610912565b61032d838360006109c9565b6040516370a0823160e01b81523060048201527f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c6001600160a01b0316906370a0823190602401602060405180830381865afa158015610391573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103b591906117e9565b905080156103f1576103f16001600160a01b037f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c163383610c2c565b92915050565b60007f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c3416001600160a01b0316826001600160a01b0316148061045557506001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee145b8061049157507f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b0316826001600160a01b0316145b6104cb5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064015b60405180910390fd5b7f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c3416001600160a01b0316826001600160a01b0316146105155761051084846000610c7a565b610521565b61052184846001610c7a565b90505b9392505050565b610533610d41565b60405163095ea7b360e01b81526001600160a01b037f000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a8116600483015260001960248301527f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c169063095ea7b3906044016020604051808303816000875af11580156105c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e79190611802565b6106335760405162461bcd60e51b815260206004820152600960248201527f21617070726f76616c000000000000000000000000000000000000000000000060448201526064016104c2565b565b600061066c6001600160a01b037f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c34116333086610912565b61032d838360016109c9565b6000600260005414156106cd5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b60026000556106e0338787878787610ded565b60016000559695505050505050565b6000600260005414156107445760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b6002600055610757878787878787610ded565b6001600055979650505050505050565b6000600260005414156107bc5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016104c2565b60026000819055507f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b15801561081f57600080fd5b505af1158015610833573d6000803e3d6000fd5b5050505050610844348360006109c9565b6040516370a0823160e01b81523060048201527f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c6001600160a01b0316906370a0823190602401602060405180830381865afa1580156108a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108cc91906117e9565b90508015610908576109086001600160a01b037f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c163383610c2c565b6001600055919050565b6040516001600160a01b03808516602483015283166044820152606481018290526109c39085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611164565b50505050565b6040805160028082526060820183526000926020830190803683370190505090507f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc281600081518110610a1e57610a1e611835565b60200260200101906001600160a01b031690816001600160a01b0316815250507f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c34181600181518110610a7257610a72611835565b6001600160a01b0392909216602092830291909101820152604080516002808252606082018352600093919290918301908036833701905050905082610af8578481600081518110610ac657610ac6611835565b602002602001018181525050600081600181518110610ae757610ae7611835565b602002602001018181525050610b3a565b600081600081518110610b0d57610b0d611835565b6020026020010181815250508481600181518110610b2d57610b2d611835565b6020026020010181815250505b7f000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c86001600160a01b031663b95cac287f9232a548dd9e81bac65500b5e0d918f8ba93675c000200000000000000000423303060405180608001604052808881526020018781526020016001888c604051602001610bb993929190611861565b6040516020818303038152906040528152602001600015158152506040518563ffffffff1660e01b8152600401610bf3949392919061195b565b600060405180830381600087803b158015610c0d57600080fd5b505af1158015610c21573d6000803e3d6000fd5b505050505050505050565b6040516001600160a01b038316602482015260448101829052610c759084907fa9059cbb000000000000000000000000000000000000000000000000000000009060640161095f565b505050565b6000811580610c895750816001145b610cbe5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064016104c2565b6000610cc8611249565b90508260011415610d00576000610cdd6113e2565b905080610cf283670de0b6b3a7640000611a26565b610cfc9190611a53565b9150505b60006127108583610d1989670de0b6b3a7640000611a26565b610d239190611a53565b610d2d9190611a26565b610d379190611a53565b9695505050505050565b610d976001600160a01b037f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2167f000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c860001961144b565b6106336001600160a01b037f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c341167f000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c860001961144b565b60007f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c3416001600160a01b0316826001600160a01b03161480610e4b57506001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee145b80610e8757507f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b0316826001600160a01b0316145b610ebc5760405162461bcd60e51b815260206004820152600660248201526508585cdcd95d60d21b60448201526064016104c2565b7f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c3416001600160a01b0316826001600160a01b03161415610f3c57610f2b6001600160a01b037f000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c34116333089610912565b610f37868660016109c9565b611022565b6001600160a01b03821673eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee1415610fe1577f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc26001600160a01b031663d0e30db0876040518263ffffffff1660e01b81526004016000604051808303818588803b158015610fbc57600080fd5b505af1158015610fd0573d6000803e3d6000fd5b5050505050610f37868660006109c9565b6110166001600160a01b037f000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc216333089610912565b611022868660006109c9565b6040516370a0823160e01b81523060048201527f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c6001600160a01b0316906370a0823190602401602060405180830381865afa158015611086573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110aa91906117e9565b6040517f1e97b6e90000000000000000000000000000000000000000000000000000000081526001600160a01b03898116600483015260248201839052861515604483015285811660648301529192507f000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a90911690631e97b6e990608401600060405180830381600087803b15801561114257600080fd5b505af1158015611156573d6000803e3d6000fd5b505050509695505050505050565b60006111b9826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166115809092919063ffffffff16565b805190915015610c7557808060200190518101906111d79190611802565b610c755760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016104c2565b604080516001808252818301909252600091829190816020015b6112886040805160608101909152806000815260200160008152602001600081525090565b8152602001906001900390816112635790505090506001816000815181106112b2576112b2611835565b60200260200101516000019060028111156112cf576112cf61184b565b908160028111156112e2576112e261184b565b81525050610e10816000815181106112fc576112fc611835565b6020026020010151602001818152505060008160008151811061132157611321611835565b602002602001015160400181815250507f0000000000000000000000009232a548dd9e81bac65500b5e0d918f8ba93675c6001600160a01b0316631dccd830826040518263ffffffff1660e01b815260040161137d9190611a75565b600060405180830381865afa15801561139a573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526113c29190810190611ade565b6000815181106113d4576113d4611835565b602002602001015191505090565b604080516001808252818301909252600091829190816020015b6114216040805160608101909152806000815260200160008152602001600081525090565b8152602001906001900390816113fc5790505090506000816000815181106112b2576112b2611835565b8015806114de57506040517fdd62ed3e0000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b03838116602483015284169063dd62ed3e90604401602060405180830381865afa1580156114b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114dc91906117e9565b155b6115505760405162461bcd60e51b815260206004820152603660248201527f5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f60448201527f20746f206e6f6e2d7a65726f20616c6c6f77616e63650000000000000000000060648201526084016104c2565b6040516001600160a01b038316602482015260448101829052610c7590849063095ea7b360e01b9060640161095f565b6060610521848460008585843b6115d95760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016104c2565b600080866001600160a01b031685876040516115f59190611b9c565b60006040518083038185875af1925050503d8060008114611632576040519150601f19603f3d011682016040523d82523d6000602084013e611637565b606091505b5091509150611647828286611652565b979650505050505050565b60608315611661575081610524565b8251156116715782518084602001fd5b8160405162461bcd60e51b81526004016104c29190611bb8565b6000806040838503121561169e57600080fd5b50508035926020909101359150565b80356001600160a01b03811681146116c457600080fd5b919050565b6000806000606084860312156116de57600080fd5b83359250602084013591506116f5604085016116ad565b90509250925092565b801515811461170c57600080fd5b50565b600080600080600060a0868803121561172757600080fd5b85359450602086013593506040860135611740816116fe565b925061174e606087016116ad565b915061175c608087016116ad565b90509295509295909350565b60008060008060008060c0878903121561178157600080fd5b61178a876116ad565b9550602087013594506040870135935060608701356117a8816116fe565b92506117b6608088016116ad565b91506117c460a088016116ad565b90509295509295509295565b6000602082840312156117e257600080fd5b5035919050565b6000602082840312156117fb57600080fd5b5051919050565b60006020828403121561181457600080fd5b8151610524816116fe565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b600060608201600486106118775761187761184b565b8583526020606081850152818651808452608086019150828801935060005b818110156118b257845183529383019391830191600101611896565b5050809350505050826040830152949350505050565b600081518084526020808501945080840160005b838110156118f8578151875295820195908201906001016118dc565b509495945050505050565b60005b8381101561191e578181015183820152602001611906565b838111156109c35750506000910152565b60008151808452611947816020860160208601611903565b601f01601f19169290920160200192915050565b848152600060206001600160a01b038087168285015280861660408501526080606085015261010084018551608080870152818151808452610120880191508583019350600092505b808310156119c6578351851682529285019260019290920191908501906119a4565b50848801519450607f199350838782030160a08801526119e681866118c8565b94505050506040850151818584030160c0860152611a04838261192f565b925050506060840151611a1b60e085018215159052565b509695505050505050565b6000816000190483118215151615611a4e57634e487b7160e01b600052601160045260246000fd5b500290565b600082611a7057634e487b7160e01b600052601260045260246000fd5b500490565b602080825282518282018190526000919060409081850190868401855b82811015611ad1578151805160038110611aae57611aae61184b565b855280870151878601528501518585015260609093019290850190600101611a92565b5091979650505050505050565b60006020808385031215611af157600080fd5b825167ffffffffffffffff80821115611b0957600080fd5b818501915085601f830112611b1d57600080fd5b815181811115611b2f57611b2f61181f565b8060051b604051601f19603f83011681018181108582111715611b5457611b5461181f565b604052918252848201925083810185019188831115611b7257600080fd5b938501935b82851015611b9057845184529385019392850192611b77565b98975050505050505050565b60008251611bae818460208701611903565b9190910192915050565b602081526000610524602083018461192f56fea264697066735822122004c1f5aacfad1e699f43a0d739c116f1b5b81b3db93d251b8546ab9f67aa856564736f6c634300080b0033

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

000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c8000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c341000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc29232a548dd9e81bac65500b5e0d918f8ba93675c000200000000000000000423

-----Decoded View---------------
Arg [0] : _crvDeposit (address): 0xB96Bce10480d2a8eb2995Ee4f04a70d48997856a
Arg [1] : _balancerVault (address): 0xBA12222222228d8Ba445958a75a0704d566BF2C8
Arg [2] : _lit (address): 0xfd0205066521550D7d7AB19DA8F72bb004b4C341
Arg [3] : _weth (address): 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2
Arg [4] : _balETHPoolId (bytes32): 0x9232a548dd9e81bac65500b5e0d918f8ba93675c000200000000000000000423

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 000000000000000000000000b96bce10480d2a8eb2995ee4f04a70d48997856a
Arg [1] : 000000000000000000000000ba12222222228d8ba445958a75a0704d566bf2c8
Arg [2] : 000000000000000000000000fd0205066521550d7d7ab19da8f72bb004b4c341
Arg [3] : 000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Arg [4] : 9232a548dd9e81bac65500b5e0d918f8ba93675c000200000000000000000423


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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