POL Price: $0.624406 (-1.60%)
 

Overview

POL Balance

Polygon PoS Chain LogoPolygon PoS Chain LogoPolygon PoS Chain Logo0 POL

POL Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To

There are no matching entries

Please try again later

Parent Transaction Hash Block From To
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
SushiAdapter

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 12 : SushiAdapter.sol
// SPDX-License-Identifier: GPL-3.0

pragma solidity 0.6.12;
pragma experimental ABIEncoderV2;

import "@enzyme/release/extensions/integration-manager/integrations/utils/AdapterBase.sol";

/**
 * SushiSwap adapter for Enzyme vaults.
 *
 * - Based on "GenericAdapter" example of Enzyme Protocol
 *
 * - Uses server-side prepared signatures to trade on Sushi
 *
 */
contract SushiAdapter is AdapterBase {

    // Tell enzyme what is our selector when we call this adapter
    bytes4 public constant EXECUTE_CALLS_SELECTOR = bytes4(
        keccak256("executeCalls(address,bytes,bytes)")
    );

    constructor(address _integrationManager) public AdapterBase(_integrationManager) {}

    // EXTERNAL FUNCTIONS

    /// @notice Executes a sequence of calls
    /// @param _vaultProxy The VaultProxy of the calling fund
    /// @param _actionData Data specific to this action
    function executeCalls(
        address _vaultProxy,
        bytes calldata _actionData,
        bytes calldata
    )
        external
        onlyIntegrationManager
        postActionIncomingAssetsTransferHandler(_vaultProxy, _actionData)
        postActionSpendAssetsTransferHandler(_vaultProxy, _actionData)
    {
        (, , , , bytes memory externalCallsData) = __decodeCallArgs(_actionData);

        (address[] memory contracts, bytes[] memory callsData) = __decodeExternalCallsData(
            externalCallsData
        );

        for (uint256 i; i < contracts.length; i++) {
            address contractAddress = contracts[i];
            bytes memory callData = callsData[i];
            (bool success, bytes memory returnData) = contractAddress.call(callData);
            require(success, string(returnData));
        }
    }

    /// @notice Parses the expected assets in a particular action
    /// @param _selector The function selector for the callOnIntegration
    /// @param _actionData Data specific to this action
    /// @return spendAssetsHandleType_ A type that dictates how to handle granting
    /// the adapter access to spend assets (hardcoded to `Transfer`)
    /// @return spendAssets_ The assets to spend in the call
    /// @return spendAssetAmounts_ The max asset amounts to spend in the call
    /// @return incomingAssets_ The assets to receive in the call
    /// @return minIncomingAssetAmounts_ The min asset amounts to receive in the call
    function parseAssetsForAction(
        address,
        bytes4 _selector,
        bytes calldata _actionData
    )
        external
        view
        override
        returns (
            IIntegrationManager.SpendAssetsHandleType spendAssetsHandleType_,
            address[] memory spendAssets_,
            uint256[] memory spendAssetAmounts_,
            address[] memory incomingAssets_,
            uint256[] memory minIncomingAssetAmounts_
        )
    {
        require(_selector == EXECUTE_CALLS_SELECTOR, "parseAssetsForAction: _selector invalid");

        (
            incomingAssets_,
            minIncomingAssetAmounts_,
            spendAssets_,
            spendAssetAmounts_,

        ) = __decodeCallArgs(_actionData);

        return (
            IIntegrationManager.SpendAssetsHandleType.Transfer,
            spendAssets_,
            spendAssetAmounts_,
            incomingAssets_,
            minIncomingAssetAmounts_
        );
    }

    /// @dev Helper to decode the encoded callOnIntegration call arguments
    function __decodeCallArgs(bytes calldata _actionData)
        private
        pure
        returns (
            address[] memory incomingAssets_,
            uint256[] memory minIncomingAssetsAmounts_,
            address[] memory spendAssets_,
            uint256[] memory spendAssetAmounts_,
            bytes memory externalCallsData_
        )
    {
        return abi.decode(_actionData, (address[], uint256[], address[], uint256[], bytes));
    }

    /// @dev Helper to decode the stack of external contract calls
    function __decodeExternalCallsData(bytes memory _externalCallsData)
        private
        pure
        returns (address[] memory contracts_, bytes[] memory callsData_)
    {
        (contracts_, callsData_) = abi.decode(_externalCallsData, (address[], bytes[]));
        require(contracts_.length == callsData_.length, "Unequal external calls arrays lengths");
        return (contracts_, callsData_);
    }
}

File 2 of 12 : IIntegrationManager.sol
// SPDX-License-Identifier: GPL-3.0

/*
    This file is part of the Enzyme Protocol.

    (c) Enzyme Council <[email protected]>

    For the full license information, please view the LICENSE
    file that was distributed with this source code.
*/

pragma solidity 0.6.12;

/// @title IIntegrationManager interface
/// @author Enzyme Council <[email protected]>
/// @notice Interface for the IntegrationManager
interface IIntegrationManager {
    enum SpendAssetsHandleType {
        None,
        Approve,
        Transfer
    }
}

File 3 of 12 : IIntegrationAdapter.sol
// SPDX-License-Identifier: GPL-3.0

/*
    This file is part of the Enzyme Protocol.

    (c) Enzyme Council <[email protected]>

    For the full license information, please view the LICENSE
    file that was distributed with this source code.
*/

pragma solidity 0.6.12;

import "../IIntegrationManager.sol";

/// @title Integration Adapter interface
/// @author Enzyme Council <[email protected]>
/// @notice Interface for all integration adapters
interface IIntegrationAdapter {
    function parseAssetsForAction(
        address _vaultProxy,
        bytes4 _selector,
        bytes calldata _encodedCallArgs
    )
        external
        view
        returns (
            IIntegrationManager.SpendAssetsHandleType spendAssetsHandleType_,
            address[] memory spendAssets_,
            uint256[] memory spendAssetAmounts_,
            address[] memory incomingAssets_,
            uint256[] memory minIncomingAssetAmounts_
        );
}

File 4 of 12 : AdapterBase.sol
// SPDX-License-Identifier: GPL-3.0

/*
    This file is part of the Enzyme Protocol.

    (c) Enzyme Council <[email protected]>

    For the full license information, please view the LICENSE
    file that was distributed with this source code.
*/

pragma solidity 0.6.12;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";
import "../../../../utils/AssetHelpers.sol";
import "../IIntegrationAdapter.sol";
import "./IntegrationSelectors.sol";

/// @title AdapterBase Contract
/// @author Enzyme Council <[email protected]>
/// @notice A base contract for integration adapters
abstract contract AdapterBase is IIntegrationAdapter, IntegrationSelectors, AssetHelpers {
    using SafeERC20 for ERC20;

    address internal immutable INTEGRATION_MANAGER;

    /// @dev Provides a standard implementation for transferring incoming assets
    /// from an adapter to a VaultProxy at the end of an adapter action
    modifier postActionIncomingAssetsTransferHandler(
        address _vaultProxy,
        bytes memory _assetData
    ) {
        _;

        (, , address[] memory incomingAssets) = __decodeAssetData(_assetData);

        __pushFullAssetBalances(_vaultProxy, incomingAssets);
    }

    /// @dev Provides a standard implementation for transferring unspent spend assets
    /// from an adapter to a VaultProxy at the end of an adapter action
    modifier postActionSpendAssetsTransferHandler(address _vaultProxy, bytes memory _assetData) {
        _;

        (address[] memory spendAssets, , ) = __decodeAssetData(_assetData);

        __pushFullAssetBalances(_vaultProxy, spendAssets);
    }

    modifier onlyIntegrationManager() {
        require(
            msg.sender == INTEGRATION_MANAGER,
            "Only the IntegrationManager can call this function"
        );
        _;
    }

    constructor(address _integrationManager) public {
        INTEGRATION_MANAGER = _integrationManager;
    }

    // INTERNAL FUNCTIONS

    /// @dev Helper to decode the _assetData param passed to adapter call
    function __decodeAssetData(bytes memory _assetData)
        internal
        pure
        returns (
            address[] memory spendAssets_,
            uint256[] memory spendAssetAmounts_,
            address[] memory incomingAssets_
        )
    {
        return abi.decode(_assetData, (address[], uint256[], address[]));
    }

    ///////////////////
    // STATE GETTERS //
    ///////////////////

    /// @notice Gets the `INTEGRATION_MANAGER` variable
    /// @return integrationManager_ The `INTEGRATION_MANAGER` variable value
    function getIntegrationManager() external view returns (address integrationManager_) {
        return INTEGRATION_MANAGER;
    }
}

File 5 of 12 : IntegrationSelectors.sol
// SPDX-License-Identifier: GPL-3.0

/*
    This file is part of the Enzyme Protocol.

    (c) Enzyme Council <[email protected]>

    For the full license information, please view the LICENSE
    file that was distributed with this source code.
*/

pragma solidity 0.6.12;

/// @title IntegrationSelectors Contract
/// @author Enzyme Council <[email protected]>
/// @notice Selectors for integration actions
/// @dev Selectors are created from their signatures rather than hardcoded for easy verification
abstract contract IntegrationSelectors {
    // Trading
    bytes4 public constant TAKE_MULTIPLE_ORDERS_SELECTOR =
        bytes4(keccak256("takeMultipleOrders(address,bytes,bytes)"));
    bytes4 public constant TAKE_ORDER_SELECTOR =
        bytes4(keccak256("takeOrder(address,bytes,bytes)"));

    // Lending
    bytes4 public constant LEND_SELECTOR = bytes4(keccak256("lend(address,bytes,bytes)"));
    bytes4 public constant REDEEM_SELECTOR = bytes4(keccak256("redeem(address,bytes,bytes)"));

    // Staking
    bytes4 public constant STAKE_SELECTOR = bytes4(keccak256("stake(address,bytes,bytes)"));
    bytes4 public constant UNSTAKE_SELECTOR = bytes4(keccak256("unstake(address,bytes,bytes)"));

    // Rewards
    bytes4 public constant CLAIM_REWARDS_SELECTOR =
        bytes4(keccak256("claimRewards(address,bytes,bytes)"));

    // Combined
    bytes4 public constant LEND_AND_STAKE_SELECTOR =
        bytes4(keccak256("lendAndStake(address,bytes,bytes)"));
    bytes4 public constant UNSTAKE_AND_REDEEM_SELECTOR =
        bytes4(keccak256("unstakeAndRedeem(address,bytes,bytes)"));
}

File 6 of 12 : AssetHelpers.sol
// SPDX-License-Identifier: GPL-3.0

/*
    This file is part of the Enzyme Protocol.

    (c) Enzyme Council <[email protected]>

    For the full license information, please view the LICENSE
    file that was distributed with this source code.
*/

pragma solidity 0.6.12;

import "@openzeppelin/contracts/math/SafeMath.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";

/// @title AssetHelpers Contract
/// @author Enzyme Council <[email protected]>
/// @notice A util contract for common token actions
abstract contract AssetHelpers {
    using SafeERC20 for ERC20;
    using SafeMath for uint256;

    /// @dev Helper to aggregate amounts of the same assets
    function __aggregateAssetAmounts(address[] memory _rawAssets, uint256[] memory _rawAmounts)
        internal
        pure
        returns (address[] memory aggregatedAssets_, uint256[] memory aggregatedAmounts_)
    {
        if (_rawAssets.length == 0) {
            return (aggregatedAssets_, aggregatedAmounts_);
        }

        uint256 aggregatedAssetCount = 1;
        for (uint256 i = 1; i < _rawAssets.length; i++) {
            bool contains;
            for (uint256 j; j < i; j++) {
                if (_rawAssets[i] == _rawAssets[j]) {
                    contains = true;
                    break;
                }
            }
            if (!contains) {
                aggregatedAssetCount++;
            }
        }

        aggregatedAssets_ = new address[](aggregatedAssetCount);
        aggregatedAmounts_ = new uint256[](aggregatedAssetCount);
        uint256 aggregatedAssetIndex;
        for (uint256 i; i < _rawAssets.length; i++) {
            bool contains;
            for (uint256 j; j < aggregatedAssetIndex; j++) {
                if (_rawAssets[i] == aggregatedAssets_[j]) {
                    contains = true;

                    aggregatedAmounts_[j] += _rawAmounts[i];

                    break;
                }
            }
            if (!contains) {
                aggregatedAssets_[aggregatedAssetIndex] = _rawAssets[i];
                aggregatedAmounts_[aggregatedAssetIndex] = _rawAmounts[i];
                aggregatedAssetIndex++;
            }
        }

        return (aggregatedAssets_, aggregatedAmounts_);
    }

    /// @dev Helper to approve a target account with the max amount of an asset.
    /// This is helpful for fully trusted contracts, such as adapters that
    /// interact with external protocol like Uniswap, Compound, etc.
    function __approveAssetMaxAsNeeded(
        address _asset,
        address _target,
        uint256 _neededAmount
    ) internal {
        uint256 allowance = ERC20(_asset).allowance(address(this), _target);
        if (allowance < _neededAmount) {
            if (allowance > 0) {
                ERC20(_asset).safeApprove(_target, 0);
            }
            ERC20(_asset).safeApprove(_target, type(uint256).max);
        }
    }

    /// @dev Helper to transfer full asset balance from the current contract to a target
    function __pushFullAssetBalance(address _target, address _asset)
        internal
        returns (uint256 amountTransferred_)
    {
        amountTransferred_ = ERC20(_asset).balanceOf(address(this));
        if (amountTransferred_ > 0) {
            ERC20(_asset).safeTransfer(_target, amountTransferred_);
        }

        return amountTransferred_;
    }

    /// @dev Helper to transfer full asset balances from the current contract to a target
    function __pushFullAssetBalances(address _target, address[] memory _assets)
        internal
        returns (uint256[] memory amountsTransferred_)
    {
        amountsTransferred_ = new uint256[](_assets.length);
        for (uint256 i; i < _assets.length; i++) {
            ERC20 assetContract = ERC20(_assets[i]);
            amountsTransferred_[i] = assetContract.balanceOf(address(this));
            if (amountsTransferred_[i] > 0) {
                assetContract.safeTransfer(_target, amountsTransferred_[i]);
            }
        }

        return amountsTransferred_;
    }
}

File 7 of 12 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        uint256 c = a + b;
        if (c < a) return (false, 0);
        return (true, c);
    }

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

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) return (true, 0);
        uint256 c = a * b;
        if (c / a != b) return (false, 0);
        return (true, c);
    }

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

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

    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        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) {
        require(b <= a, "SafeMath: subtraction overflow");
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        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, reverting 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) {
        require(b > 0, "SafeMath: division by zero");
        return a / b;
    }

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

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

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryDiv}.
     *
     * 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);
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b > 0, errorMessage);
        return a % b;
    }
}

File 8 of 12 : ERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.0 <0.8.0;

import "../../utils/Context.sol";
import "./IERC20.sol";
import "../../math/SafeMath.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20 {
    using SafeMath for uint256;

    mapping (address => uint256) private _balances;

    mapping (address => mapping (address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;
    uint8 private _decimals;

    /**
     * @dev Sets the values for {name} and {symbol}, initializes {decimals} with
     * a default value of 18.
     *
     * To select a different value for {decimals}, use {_setupDecimals}.
     *
     * All three of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name_, string memory symbol_) public {
        _name = name_;
        _symbol = symbol_;
        _decimals = 18;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view virtual returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5,05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless {_setupDecimals} is
     * called.
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual returns (uint8) {
        return _decimals;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20}.
     *
     * Requirements:
     *
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        _balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
        _balances[recipient] = _balances[recipient].add(amount);
        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply = _totalSupply.add(amount);
        _balances[account] = _balances[account].add(amount);
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
        _totalSupply = _totalSupply.sub(amount);
        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Sets {decimals} to a value other than the default one of 18.
     *
     * WARNING: This function should only be called from the constructor. Most
     * applications that interact with token contracts will not expect
     * {decimals} to ever change, and may work incorrectly if it does.
     */
    function _setupDecimals(uint8 decimals_) internal virtual {
        _decimals = decimals_;
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
}

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

pragma solidity >=0.6.0 <0.8.0;

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

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

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

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

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

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

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

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

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

pragma solidity >=0.6.0 <0.8.0;

import "./IERC20.sol";
import "../../math/SafeMath.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 SafeMath for uint256;
    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'
        // solhint-disable-next-line max-line-length
        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).add(value);
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero");
        _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
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

File 11 of 12 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity >=0.6.2 <0.8.0;

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

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        assembly { size := extcodesize(account) }
        return size > 0;
    }

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

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

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

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

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

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

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

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

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

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

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

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

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

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

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

pragma solidity >=0.6.0 <0.8.0;

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

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

Settings
{
  "remappings": [
    "@enzyme/=lib/@enzyme/contracts/",
    "@openzeppelin-solc-0.7/=lib/@enzyme/node_modules/@openzeppelin-solc-0.7/",
    "@openzeppelin/=lib/@openzeppelin/",
    "@uniswap/=lib/@enzyme/node_modules/@uniswap/",
    "ds-test/=lib/forge-std/lib/ds-test/src/",
    "forge-std/=lib/forge-std/src/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "metadata": {
    "bytecodeHash": "ipfs"
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "evmVersion": "istanbul",
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_integrationManager","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"CLAIM_REWARDS_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EXECUTE_CALLS_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LEND_AND_STAKE_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LEND_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"REDEEM_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"STAKE_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"TAKE_MULTIPLE_ORDERS_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"TAKE_ORDER_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UNSTAKE_AND_REDEEM_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"UNSTAKE_SELECTOR","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_vaultProxy","type":"address"},{"internalType":"bytes","name":"_actionData","type":"bytes"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"executeCalls","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getIntegrationManager","outputs":[{"internalType":"address","name":"integrationManager_","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"bytes4","name":"_selector","type":"bytes4"},{"internalType":"bytes","name":"_actionData","type":"bytes"}],"name":"parseAssetsForAction","outputs":[{"internalType":"enum IIntegrationManager.SpendAssetsHandleType","name":"spendAssetsHandleType_","type":"uint8"},{"internalType":"address[]","name":"spendAssets_","type":"address[]"},{"internalType":"uint256[]","name":"spendAssetAmounts_","type":"uint256[]"},{"internalType":"address[]","name":"incomingAssets_","type":"address[]"},{"internalType":"uint256[]","name":"minIncomingAssetAmounts_","type":"uint256[]"}],"stateMutability":"view","type":"function"}]

60a060405234801561001057600080fd5b5060405161136538038061136583398101604081905261002f91610044565b60601b6001600160601b031916608052610072565b600060208284031215610055578081fd5b81516001600160a01b038116811461006b578182fd5b9392505050565b60805160601c6112d1610094600039806102b3528061051d52506112d16000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063863e5ad01161008c578063c32990a211610066578063c32990a21461013f578063c54efee514610147578063e7c456901461016b578063f7d882b514610180576100cf565b8063863e5ad01461011a578063b23228cf14610122578063b7fe1a111461012a576100cf565b8063080456c1146100d457806312d9c1f6146100f2578063131461c0146100fa578063257cb1a3146101025780633ffc15911461010a57806340da225d14610112575b600080fd5b6100dc610188565b6040516100e99190610f92565b60405180910390f35b6100dc6101ac565b6100dc6101d0565b6100dc6101f4565b6100dc610218565b6100dc61023c565b6100dc610260565b6100dc610284565b61013d610138366004610b90565b6102a8565b005b6100dc6104a0565b61015a610155366004610b21565b6104c4565b6040516100e9959493929190610fa7565b61017361051b565b6040516100e99190610f65565b6100dc61053f565b7f8334eb99be0145865eba9889fca2ee920288090caefff4cc776038e20ad9259a81565b7fb7fe1a117cff974e3f19d303d9f97ada44b7ecad880df21ddfdc69ba0493b79681565b7f29fa046e79524c3c5ac4c01df692c35e217802b2b13b21121b76cf0ef02b138c81565b7f099f75155f0e997bf83a7993a71d5e7e7540bd386fe1e84643a09ce6b412521981565b7ffa7dd04da627f433da73c4355ead9c75682a67a8fc84d3f6170ef0922f402d2481565b7fb9dfbaccbe5cd2a84fdcf1d15f23ef25d23086f5afbaa99516065ed4a5bbc7a381565b7f03e38a2bd7063d45c897edeafc330e71657502dd86434d3c37a489caf116af6981565b7f68e30677f607df46e87da13e15b637784cfa62374b653f35ab43d10361a2f83081565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146102f95760405162461bcd60e51b81526004016102f0906110ce565b60405180910390fd5b8484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050604080516020601f8a018190048102820181019092528881528a9350915088908890819084018382808284376000920191909152506060925061037591508a905089610563565b94505050505060608061038783610588565b9150915060005b825181101561045b5760008382815181106103a557fe5b6020026020010151905060608383815181106103bd57fe5b6020026020010151905060006060836001600160a01b0316836040516103e39190610f49565b6000604051808303816000865af19150503d8060008114610420576040519150601f19603f3d011682016040523d82523d6000602084013e610425565b606091505b509150915081819061044a5760405162461bcd60e51b81526004016102f09190611010565b50506001909301925061038e915050565b50505050606061046a826105cb565b5050905061047883826105f1565b505050506060610487826105cb565b9250505061049583826105f1565b505050505050505050565b7f0e7f692dad5b88fdee426250d6eae91207e56a2e8112b7364579bed1790e5bf481565b600060608080806001600160e01b0319881663b7fe1a1160e01b146104fb5760405162461bcd60e51b81526004016102f0906111a1565b6105058787610563565b5060029d919c509a509198509650945050505050565b7f000000000000000000000000000000000000000000000000000000000000000090565b7fc29fa9dde84204c2908778afd0613d802d31cf046179b88f6d2b4a4e507ea2d581565b60608080808061057586880188610dd3565b939b929a50909850965090945092505050565b6060808280602001905181019061059f9190610c10565b80518251929450909250146105c65760405162461bcd60e51b81526004016102f090611043565b915091565b6060806060838060200190518101906105e49190610cf9565b9250925092509193909250565b6060815167ffffffffffffffff8111801561060b57600080fd5b50604051908082528060200260200182016040528015610635578160200160208202803683370190505b50905060005b825181101561074657600083828151811061065257fe5b60200260200101519050806001600160a01b03166370a08231306040518263ffffffff1660e01b81526004016106889190610f65565b60206040518083038186803b1580156106a057600080fd5b505afa1580156106b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106d89190610ebf565b8383815181106106e457fe5b60200260200101818152505060008383815181106106fe57fe5b6020026020010151111561073d5761073d8584848151811061071c57fe5b6020026020010151836001600160a01b031661074d9092919063ffffffff16565b5060010161063b565b5092915050565b6107a38363a9059cbb60e01b848460405160240161076c929190610f79565b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526107a8565b505050565b60606107fd826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166108379092919063ffffffff16565b8051909150156107a3578080602001905181019061081b9190610e9f565b6107a35760405162461bcd60e51b81526004016102f090611157565b60606108468484600085610850565b90505b9392505050565b6060824710156108725760405162461bcd60e51b81526004016102f090611088565b61087b85610911565b6108975760405162461bcd60e51b81526004016102f090611120565b60006060866001600160a01b031685876040516108b49190610f49565b60006040518083038185875af1925050503d80600081146108f1576040519150601f19603f3d011682016040523d82523d6000602084013e6108f6565b606091505b5091509150610906828286610917565b979650505050505050565b3b151590565b60608315610926575081610849565b8251156109365782518084602001fd5b8160405162461bcd60e51b81526004016102f09190611010565b600082601f830112610960578081fd5b813561097361096e8261120f565b6111e8565b81815291506020808301908481018184028601820187101561099457600080fd5b60005b848110156109bc5781356109aa81611283565b84529282019290820190600101610997565b505050505092915050565b600082601f8301126109d7578081fd5b81516109e561096e8261120f565b818152915060208083019084810181840286018201871015610a0657600080fd5b60005b848110156109bc578151610a1c81611283565b84529282019290820190600101610a09565b600082601f830112610a3e578081fd5b8135610a4c61096e8261120f565b818152915060208083019084810181840286018201871015610a6d57600080fd5b60005b848110156109bc57813584529282019290820190600101610a70565b60008083601f840112610a9d578182fd5b50813567ffffffffffffffff811115610ab4578182fd5b602083019150836020828501011115610acc57600080fd5b9250929050565b600082601f830112610ae3578081fd5b8135610af161096e8261122f565b9150808252836020828501011115610b0857600080fd5b8060208401602084013760009082016020015292915050565b60008060008060608587031215610b36578384fd5b8435610b4181611283565b935060208501356001600160e01b031981168114610b5d578384fd5b9250604085013567ffffffffffffffff811115610b78578283fd5b610b8487828801610a8c565b95989497509550505050565b600080600080600060608688031215610ba7578081fd5b8535610bb281611283565b9450602086013567ffffffffffffffff80821115610bce578283fd5b610bda89838a01610a8c565b90965094506040880135915080821115610bf2578283fd5b50610bff88828901610a8c565b969995985093965092949392505050565b6000806040808486031215610c23578283fd5b835167ffffffffffffffff80821115610c3a578485fd5b610c46878388016109c7565b9450602091508186015181811115610c5c578485fd5b86019050601f81018713610c6e578384fd5b8051610c7c61096e8261120f565b81815283810190838501875b84811015610ce857815186018c603f820112610ca257898afd5b87810151610cb261096e8261122f565b8181528e8b838501011115610cc5578b8cfd5b610cd4828b83018d8601611253565b865250509286019290860190600101610c88565b50979a909950975050505050505050565b600080600060608486031215610d0d578283fd5b835167ffffffffffffffff80821115610d24578485fd5b610d30878388016109c7565b9450602091508186015181811115610d46578485fd5b8601601f81018813610d56578485fd5b8051610d6461096e8261120f565b81815284810190838601868402850187018c1015610d80578889fd5b8894505b83851015610da2578051835260019490940193918601918601610d84565b5060408a0151909750945050505080821115610dbc578283fd5b50610dc9868287016109c7565b9150509250925092565b600080600080600060a08688031215610dea578081fd5b853567ffffffffffffffff80821115610e01578283fd5b610e0d89838a01610950565b96506020880135915080821115610e22578283fd5b610e2e89838a01610a2e565b95506040880135915080821115610e43578283fd5b610e4f89838a01610950565b94506060880135915080821115610e64578283fd5b610e7089838a01610a2e565b93506080880135915080821115610e85578283fd5b50610e9288828901610ad3565b9150509295509295909350565b600060208284031215610eb0578081fd5b81518015158114610849578182fd5b600060208284031215610ed0578081fd5b5051919050565b6000815180845260208085019450808401835b83811015610f0f5781516001600160a01b031687529582019590820190600101610eea565b509495945050505050565b6000815180845260208085019450808401835b83811015610f0f57815187529582019590820190600101610f2d565b60008251610f5b818460208701611253565b9190910192915050565b6001600160a01b0391909116815260200190565b6001600160a01b03929092168252602082015260400190565b6001600160e01b031991909116815260200190565b600060038710610fb357fe5b86825260a06020830152610fca60a0830187610ed7565b8281036040840152610fdc8187610f1a565b90508281036060840152610ff08186610ed7565b905082810360808401526110048185610f1a565b98975050505050505050565b600060208252825180602084015261102f816040850160208701611253565b601f01601f19169190910160400192915050565b60208082526025908201527f556e657175616c2065787465726e616c2063616c6c7320617272617973206c656040820152646e6774687360d81b606082015260800190565b60208082526026908201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6040820152651c8818d85b1b60d21b606082015260800190565b60208082526032908201527f4f6e6c792074686520496e746567726174696f6e4d616e616765722063616e2060408201527131b0b636103a3434b990333ab731ba34b7b760711b606082015260800190565b6020808252601d908201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6040820152691bdd081cdd58d8d9595960b21b606082015260800190565b60208082526027908201527f7061727365417373657473466f72416374696f6e3a205f73656c6563746f72206040820152661a5b9d985b1a5960ca1b606082015260800190565b60405181810167ffffffffffffffff8111828210171561120757600080fd5b604052919050565b600067ffffffffffffffff821115611225578081fd5b5060209081020190565b600067ffffffffffffffff821115611245578081fd5b50601f01601f191660200190565b60005b8381101561126e578181015183820152602001611256565b8381111561127d576000848401525b50505050565b6001600160a01b038116811461129857600080fd5b5056fea2646970667358221220b7fc1f39636e3fa5106a42288300b1a98943178ba6fed3614432aff80870123564736f6c634300060c003300000000000000000000000092fcde09790671cf085864182b9670c77da0884b

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c8063863e5ad01161008c578063c32990a211610066578063c32990a21461013f578063c54efee514610147578063e7c456901461016b578063f7d882b514610180576100cf565b8063863e5ad01461011a578063b23228cf14610122578063b7fe1a111461012a576100cf565b8063080456c1146100d457806312d9c1f6146100f2578063131461c0146100fa578063257cb1a3146101025780633ffc15911461010a57806340da225d14610112575b600080fd5b6100dc610188565b6040516100e99190610f92565b60405180910390f35b6100dc6101ac565b6100dc6101d0565b6100dc6101f4565b6100dc610218565b6100dc61023c565b6100dc610260565b6100dc610284565b61013d610138366004610b90565b6102a8565b005b6100dc6104a0565b61015a610155366004610b21565b6104c4565b6040516100e9959493929190610fa7565b61017361051b565b6040516100e99190610f65565b6100dc61053f565b7f8334eb99be0145865eba9889fca2ee920288090caefff4cc776038e20ad9259a81565b7fb7fe1a117cff974e3f19d303d9f97ada44b7ecad880df21ddfdc69ba0493b79681565b7f29fa046e79524c3c5ac4c01df692c35e217802b2b13b21121b76cf0ef02b138c81565b7f099f75155f0e997bf83a7993a71d5e7e7540bd386fe1e84643a09ce6b412521981565b7ffa7dd04da627f433da73c4355ead9c75682a67a8fc84d3f6170ef0922f402d2481565b7fb9dfbaccbe5cd2a84fdcf1d15f23ef25d23086f5afbaa99516065ed4a5bbc7a381565b7f03e38a2bd7063d45c897edeafc330e71657502dd86434d3c37a489caf116af6981565b7f68e30677f607df46e87da13e15b637784cfa62374b653f35ab43d10361a2f83081565b336001600160a01b037f00000000000000000000000092fcde09790671cf085864182b9670c77da0884b16146102f95760405162461bcd60e51b81526004016102f0906110ce565b60405180910390fd5b8484848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050604080516020601f8a018190048102820181019092528881528a9350915088908890819084018382808284376000920191909152506060925061037591508a905089610563565b94505050505060608061038783610588565b9150915060005b825181101561045b5760008382815181106103a557fe5b6020026020010151905060608383815181106103bd57fe5b6020026020010151905060006060836001600160a01b0316836040516103e39190610f49565b6000604051808303816000865af19150503d8060008114610420576040519150601f19603f3d011682016040523d82523d6000602084013e610425565b606091505b509150915081819061044a5760405162461bcd60e51b81526004016102f09190611010565b50506001909301925061038e915050565b50505050606061046a826105cb565b5050905061047883826105f1565b505050506060610487826105cb565b9250505061049583826105f1565b505050505050505050565b7f0e7f692dad5b88fdee426250d6eae91207e56a2e8112b7364579bed1790e5bf481565b600060608080806001600160e01b0319881663b7fe1a1160e01b146104fb5760405162461bcd60e51b81526004016102f0906111a1565b6105058787610563565b5060029d919c509a509198509650945050505050565b7f00000000000000000000000092fcde09790671cf085864182b9670c77da0884b90565b7fc29fa9dde84204c2908778afd0613d802d31cf046179b88f6d2b4a4e507ea2d581565b60608080808061057586880188610dd3565b939b929a50909850965090945092505050565b6060808280602001905181019061059f9190610c10565b80518251929450909250146105c65760405162461bcd60e51b81526004016102f090611043565b915091565b6060806060838060200190518101906105e49190610cf9565b9250925092509193909250565b6060815167ffffffffffffffff8111801561060b57600080fd5b50604051908082528060200260200182016040528015610635578160200160208202803683370190505b50905060005b825181101561074657600083828151811061065257fe5b60200260200101519050806001600160a01b03166370a08231306040518263ffffffff1660e01b81526004016106889190610f65565b60206040518083038186803b1580156106a057600080fd5b505afa1580156106b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106d89190610ebf565b8383815181106106e457fe5b60200260200101818152505060008383815181106106fe57fe5b6020026020010151111561073d5761073d8584848151811061071c57fe5b6020026020010151836001600160a01b031661074d9092919063ffffffff16565b5060010161063b565b5092915050565b6107a38363a9059cbb60e01b848460405160240161076c929190610f79565b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526107a8565b505050565b60606107fd826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166108379092919063ffffffff16565b8051909150156107a3578080602001905181019061081b9190610e9f565b6107a35760405162461bcd60e51b81526004016102f090611157565b60606108468484600085610850565b90505b9392505050565b6060824710156108725760405162461bcd60e51b81526004016102f090611088565b61087b85610911565b6108975760405162461bcd60e51b81526004016102f090611120565b60006060866001600160a01b031685876040516108b49190610f49565b60006040518083038185875af1925050503d80600081146108f1576040519150601f19603f3d011682016040523d82523d6000602084013e6108f6565b606091505b5091509150610906828286610917565b979650505050505050565b3b151590565b60608315610926575081610849565b8251156109365782518084602001fd5b8160405162461bcd60e51b81526004016102f09190611010565b600082601f830112610960578081fd5b813561097361096e8261120f565b6111e8565b81815291506020808301908481018184028601820187101561099457600080fd5b60005b848110156109bc5781356109aa81611283565b84529282019290820190600101610997565b505050505092915050565b600082601f8301126109d7578081fd5b81516109e561096e8261120f565b818152915060208083019084810181840286018201871015610a0657600080fd5b60005b848110156109bc578151610a1c81611283565b84529282019290820190600101610a09565b600082601f830112610a3e578081fd5b8135610a4c61096e8261120f565b818152915060208083019084810181840286018201871015610a6d57600080fd5b60005b848110156109bc57813584529282019290820190600101610a70565b60008083601f840112610a9d578182fd5b50813567ffffffffffffffff811115610ab4578182fd5b602083019150836020828501011115610acc57600080fd5b9250929050565b600082601f830112610ae3578081fd5b8135610af161096e8261122f565b9150808252836020828501011115610b0857600080fd5b8060208401602084013760009082016020015292915050565b60008060008060608587031215610b36578384fd5b8435610b4181611283565b935060208501356001600160e01b031981168114610b5d578384fd5b9250604085013567ffffffffffffffff811115610b78578283fd5b610b8487828801610a8c565b95989497509550505050565b600080600080600060608688031215610ba7578081fd5b8535610bb281611283565b9450602086013567ffffffffffffffff80821115610bce578283fd5b610bda89838a01610a8c565b90965094506040880135915080821115610bf2578283fd5b50610bff88828901610a8c565b969995985093965092949392505050565b6000806040808486031215610c23578283fd5b835167ffffffffffffffff80821115610c3a578485fd5b610c46878388016109c7565b9450602091508186015181811115610c5c578485fd5b86019050601f81018713610c6e578384fd5b8051610c7c61096e8261120f565b81815283810190838501875b84811015610ce857815186018c603f820112610ca257898afd5b87810151610cb261096e8261122f565b8181528e8b838501011115610cc5578b8cfd5b610cd4828b83018d8601611253565b865250509286019290860190600101610c88565b50979a909950975050505050505050565b600080600060608486031215610d0d578283fd5b835167ffffffffffffffff80821115610d24578485fd5b610d30878388016109c7565b9450602091508186015181811115610d46578485fd5b8601601f81018813610d56578485fd5b8051610d6461096e8261120f565b81815284810190838601868402850187018c1015610d80578889fd5b8894505b83851015610da2578051835260019490940193918601918601610d84565b5060408a0151909750945050505080821115610dbc578283fd5b50610dc9868287016109c7565b9150509250925092565b600080600080600060a08688031215610dea578081fd5b853567ffffffffffffffff80821115610e01578283fd5b610e0d89838a01610950565b96506020880135915080821115610e22578283fd5b610e2e89838a01610a2e565b95506040880135915080821115610e43578283fd5b610e4f89838a01610950565b94506060880135915080821115610e64578283fd5b610e7089838a01610a2e565b93506080880135915080821115610e85578283fd5b50610e9288828901610ad3565b9150509295509295909350565b600060208284031215610eb0578081fd5b81518015158114610849578182fd5b600060208284031215610ed0578081fd5b5051919050565b6000815180845260208085019450808401835b83811015610f0f5781516001600160a01b031687529582019590820190600101610eea565b509495945050505050565b6000815180845260208085019450808401835b83811015610f0f57815187529582019590820190600101610f2d565b60008251610f5b818460208701611253565b9190910192915050565b6001600160a01b0391909116815260200190565b6001600160a01b03929092168252602082015260400190565b6001600160e01b031991909116815260200190565b600060038710610fb357fe5b86825260a06020830152610fca60a0830187610ed7565b8281036040840152610fdc8187610f1a565b90508281036060840152610ff08186610ed7565b905082810360808401526110048185610f1a565b98975050505050505050565b600060208252825180602084015261102f816040850160208701611253565b601f01601f19169190910160400192915050565b60208082526025908201527f556e657175616c2065787465726e616c2063616c6c7320617272617973206c656040820152646e6774687360d81b606082015260800190565b60208082526026908201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6040820152651c8818d85b1b60d21b606082015260800190565b60208082526032908201527f4f6e6c792074686520496e746567726174696f6e4d616e616765722063616e2060408201527131b0b636103a3434b990333ab731ba34b7b760711b606082015260800190565b6020808252601d908201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604082015260600190565b6020808252602a908201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6040820152691bdd081cdd58d8d9595960b21b606082015260800190565b60208082526027908201527f7061727365417373657473466f72416374696f6e3a205f73656c6563746f72206040820152661a5b9d985b1a5960ca1b606082015260800190565b60405181810167ffffffffffffffff8111828210171561120757600080fd5b604052919050565b600067ffffffffffffffff821115611225578081fd5b5060209081020190565b600067ffffffffffffffff821115611245578081fd5b50601f01601f191660200190565b60005b8381101561126e578181015183820152602001611256565b8381111561127d576000848401525b50505050565b6001600160a01b038116811461129857600080fd5b5056fea2646970667358221220b7fc1f39636e3fa5106a42288300b1a98943178ba6fed3614432aff80870123564736f6c634300060c0033

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

00000000000000000000000092fcde09790671cf085864182b9670c77da0884b

-----Decoded View---------------
Arg [0] : _integrationManager (address): 0x92fCdE09790671cf085864182B9670c77da0884B

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000092fcde09790671cf085864182b9670c77da0884b


Block Transaction 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

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.