S Price: $0.402156 (+1.73%)
    /

    Contract

    0x0CDaC437Ce63A1e1b1Cab10aB4DF032234Bb39A3

    Overview

    S Balance

    Sonic LogoSonic LogoSonic Logo0 S

    S Value

    $0.00

    Multichain Info

    No addresses found
    Transaction Hash
    Method
    Block
    Age
    From
    To
    Amount

    There are no matching entries

    1 Internal Transaction found.

    Latest 1 internal transaction

    Parent Transaction Hash Block Age From To Amount
    162947652025-03-27 8:41:1012 days ago1743064870
     Contract Creation
    0 S
    Loading...
    Loading

    Similar Match Source Code
    This contract matches the deployed Bytecode of the Source Code for Contract 0xc6CFB9d9...c556dFdE5
    The constructor portion of the code might be different and could alter the actual behaviour of the contract

    Contract Name:
    ManagedPool

    Compiler Version
    v0.7.1+commit.f4a555be

    Optimization Enabled:
    Yes with 140 runs

    Other Settings:
    default evmVersion
    File 1 of 64 : ManagedPool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/IVersion.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-utils/IRecoveryModeHelper.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-weighted/IExternalWeightedMath.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-weighted/WeightedPoolUserData.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/InputHelpers.sol";
    import "@balancer-labs/v2-pool-utils/contracts/lib/BasePoolMath.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 2 of 64 : BasePoolUserData.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    library BasePoolUserData {
    // Special ExitKind for all pools, used in Recovery Mode. Use the max 8-bit value to prevent conflicts
    // with future additions to the ExitKind enums (or any front-end code that maps to existing values)
    uint8 public constant RECOVERY_MODE_EXIT_KIND = 255;
    // Return true if this is the special exit kind.
    function isRecoveryModeExitKind(bytes memory self) internal pure returns (bool) {
    // Check for the "no data" case, or abi.decode would revert
    return self.length > 0 && abi.decode(self, (uint8)) == RECOVERY_MODE_EXIT_KIND;
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 3 of 64 : IManagedPool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "../solidity-utils/openzeppelin/IERC20.sol";
    import "../vault/IBasePool.sol";
    interface IManagedPool is IBasePool {
    event GradualSwapFeeUpdateScheduled(
    uint256 startTime,
    uint256 endTime,
    uint256 startSwapFeePercentage,
    uint256 endSwapFeePercentage
    );
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 4 of 64 : IProtocolFeeCache.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    interface IProtocolFeeCache {
    /**
    * @notice Updates the cache to the latest value set by governance.
    * @dev Can be called by anyone to update the cached fee percentages.
    *
    * Correct behavior depends on the token balances from the Vault, which may be out of sync with the state of
    * the pool during execution of a Vault hook. This is protected by a call to `ensureNotInVaultContext` in
    * VaultReentrancyLib where overridden in `ProtocolFeeCache`, and so is safe to call on ManagedPool.
    *
    * See https://forum.balancer.fi/t/reentrancy-vulnerability-scope-expanded/4345 for reference.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 5 of 64 : IRecoveryMode.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @dev Interface for the RecoveryMode module.
    */
    interface IRecoveryMode {
    /**
    * @dev Emitted when the Recovery Mode status changes.
    */
    event RecoveryModeStateChanged(bool enabled);
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 6 of 64 : IRecoveryModeHelper.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "../vault/IVault.sol";
    /**
    * Interface for an auxiliary contract that computes Recovery Mode exits, removing logic from the core Pool contract
    * that would otherwise take up a lot of bytecode size at the cost of some slight gas overhead. Since Recovery Mode
    * exits are expected to be highly infrequent (and ideally never occur), this tradeoff makes sense.
    */
    interface IRecoveryModeHelper {
    /**
    * @notice Returns the Balancer Vault
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 7 of 64 : IExternalWeightedMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @notice Interface for ExternalWeightedMath, a contract-wrapper for Weighted Math, Joins and Exits.
    */
    interface IExternalWeightedMath {
    /**
    * @dev See `WeightedMath._calculateInvariant`.
    */
    function calculateInvariant(uint256[] memory normalizedWeights, uint256[] memory balances)
    external
    pure
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 8 of 64 : WeightedPoolUserData.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "../solidity-utils/openzeppelin/IERC20.sol";
    library WeightedPoolUserData {
    // In order to preserve backwards compatibility, make sure new join and exit kinds are added at the end of the enum.
    enum JoinKind { INIT, EXACT_TOKENS_IN_FOR_BPT_OUT, TOKEN_IN_FOR_EXACT_BPT_OUT, ALL_TOKENS_IN_FOR_EXACT_BPT_OUT }
    enum ExitKind { EXACT_BPT_IN_FOR_ONE_TOKEN_OUT, EXACT_BPT_IN_FOR_TOKENS_OUT, BPT_IN_FOR_EXACT_TOKENS_OUT }
    function joinKind(bytes memory self) internal pure returns (JoinKind) {
    return abi.decode(self, (JoinKind));
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 9 of 64 : BalancerErrors.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.1 <0.9.0;
    // solhint-disable
    /**
    * @dev Reverts if `condition` is false, with a revert reason containing `errorCode`. Only codes up to 999 are
    * supported.
    * Uses the default 'BAL' prefix for the error code
    */
    function _require(bool condition, uint256 errorCode) pure {
    if (!condition) _revert(errorCode);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 10 of 64 : IAuthentication.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    interface IAuthentication {
    /**
    * @dev Returns the action identifier associated with the external function described by `selector`.
    */
    function getActionId(bytes4 selector) external view returns (bytes32);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 11 of 64 : ISignaturesValidator.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @dev Interface for the SignatureValidator helper, used to support meta-transactions.
    */
    interface ISignaturesValidator {
    /**
    * @dev Returns the EIP712 domain separator.
    */
    function getDomainSeparator() external view returns (bytes32);
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 12 of 64 : ITemporarilyPausable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @dev Interface for the TemporarilyPausable helper.
    */
    interface ITemporarilyPausable {
    /**
    * @dev Emitted every time the pause state changes by `_setPaused`.
    */
    event PausedStateChanged(bool paused);
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 13 of 64 : IVersion.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @notice Simple interface to retrieve the version of a deployed contract.
    */
    interface IVersion {
    /**
    * @dev Returns a JSON representation of the contract version containing name, version number and task ID.
    */
    function version() external view returns (string memory);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 14 of 64 : IWETH.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "../openzeppelin/IERC20.sol";
    /**
    * @dev Interface for WETH9.
    * See https://github.com/gnosis/canonical-weth/blob/0dd1ea3e295eef916d0c6223ec63141137d22d67/contracts/WETH9.sol
    */
    interface IWETH is IERC20 {
    function deposit() external payable;
    function withdraw(uint256 amount) external;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 15 of 64 : IERC20.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity >=0.7.0 <0.9.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);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 16 of 64 : IERC20Permit.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
    * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
    *
    * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
    * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't
    * need to send a transaction, and thus is not required to hold Ether at all.
    */
    interface IERC20Permit {
    /**
    * @dev Sets `value` as the allowance of `spender` over `owner`'s tokens,
    * given `owner`'s signed approval.
    *
    * IMPORTANT: The same issues {IERC20-approve} has related to transaction
    * ordering also apply here.
    *
    * Emits an {Approval} event.
    *
    * Requirements:
    *
    * - `spender` cannot be the zero address.
    * - `deadline` must be a timestamp in the future.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 17 of 64 : IProtocolFeePercentagesProvider.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    /**
    * @dev Source of truth for all Protocol Fee percentages, that is, how much the protocol charges certain actions. Some
    * of these values may also be retrievable from other places (such as the swap fee percentage), but this is the
    * preferred source nonetheless.
    */
    interface IProtocolFeePercentagesProvider {
    // All fee percentages are 18-decimal fixed point numbers, so e.g. 1e18 = 100% and 1e16 = 1%.
    // Emitted when a new fee type is registered.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 18 of 64 : IAsset.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    /**
    * @dev This is an empty interface used to represent either ERC20-conforming token contracts or ETH (using the zero
    * address sentinel value). We're just relying on the fact that `interface` can be used to declare new address-like
    * types.
    *
    * This concept is unrelated to a Pool's Asset Managers.
    */
    interface IAsset {
    // solhint-disable-previous-line no-empty-blocks
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 19 of 64 : IAuthorizer.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    interface IAuthorizer {
    /**
    * @dev Returns true if `account` can perform the action described by `actionId` in the contract `where`.
    */
    function canPerform(
    bytes32 actionId,
    address account,
    address where
    ) external view returns (bool);
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 20 of 64 : IBasePool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    import "./IVault.sol";
    import "./IPoolSwapStructs.sol";
    /**
    * @dev Interface for adding and removing liquidity that all Pool contracts should implement. Note that this is not
    * the complete Pool contract interface, as it is missing the swap hooks. Pool contracts should also inherit from
    * either IGeneralPool or IMinimalSwapInfoPool
    */
    interface IBasePool is IPoolSwapStructs {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 21 of 64 : IFlashLoanRecipient.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    // Inspired by Aave Protocol's IFlashLoanReceiver.
    import "../solidity-utils/openzeppelin/IERC20.sol";
    interface IFlashLoanRecipient {
    /**
    * @dev When `flashLoan` is called on the Vault, it invokes the `receiveFlashLoan` hook on the recipient.
    *
    * At the time of the call, the Vault will have transferred `amounts` for `tokens` to the recipient. Before this
    * call returns, the recipient must have transferred `amounts` plus `feeAmounts` for each token back to the
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 22 of 64 : IGeneralPool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    import "./IBasePool.sol";
    /**
    * @dev IPools with the General specialization setting should implement this interface.
    *
    * This is called by the Vault when a user calls `IVault.swap` or `IVault.batchSwap` to swap with this Pool.
    * Returns the number of tokens the Pool will grant to the user in a 'given in' swap, or that the user will
    * grant to the pool in a 'given out' swap.
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 23 of 64 : IMinimalSwapInfoPool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    import "./IBasePool.sol";
    /**
    * @dev Pool contracts with the MinimalSwapInfo or TwoToken specialization settings should implement this interface.
    *
    * This is called by the Vault when a user calls `IVault.swap` or `IVault.batchSwap` to swap with this Pool.
    * Returns the number of tokens the Pool will grant to the user in a 'given in' swap, or that the user will grant
    * to the pool in a 'given out' swap.
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 24 of 64 : IPoolSwapStructs.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    import "../solidity-utils/openzeppelin/IERC20.sol";
    import "./IVault.sol";
    interface IPoolSwapStructs {
    // This is not really an interface - it just defines common structs used by other interfaces: IGeneralPool and
    // IMinimalSwapInfoPool.
    //
    // This data structure represents a request for a token swap, where `kind` indicates the swap type ('given in' or
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 25 of 64 : IProtocolFeesCollector.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    pragma experimental ABIEncoderV2;
    import "../solidity-utils/openzeppelin/IERC20.sol";
    import "./IVault.sol";
    import "./IAuthorizer.sol";
    interface IProtocolFeesCollector {
    event SwapFeePercentageChanged(uint256 newSwapFeePercentage);
    event FlashLoanFeePercentageChanged(uint256 newFlashLoanFeePercentage);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 26 of 64 : IVault.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma experimental ABIEncoderV2;
    import "../solidity-utils/openzeppelin/IERC20.sol";
    import "../solidity-utils/helpers/IAuthentication.sol";
    import "../solidity-utils/helpers/ISignaturesValidator.sol";
    import "../solidity-utils/helpers/ITemporarilyPausable.sol";
    import "../solidity-utils/misc/IWETH.sol";
    import "./IAsset.sol";
    import "./IAuthorizer.sol";
    import "./IFlashLoanRecipient.sol";
    import "./IProtocolFeesCollector.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 27 of 64 : BalancerPoolToken.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/vault/IVault.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/openzeppelin/ERC20Permit.sol";
    /**
    * @title Highly opinionated token implementation
    * @author Balancer Labs
    * @dev
    * - Includes functions to increase and decrease allowance as a workaround
    * for the well-known issue with `approve`:
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 28 of 64 : BasePoolAuthorization.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/vault/IAuthorizer.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/Authentication.sol";
    /**
    * @dev Base authorization layer implementation for Pools.
    *
    * The owner account can call some of the permissioned functions - access control of the rest is delegated to the
    * Authorizer. Note that this owner is immutable: more sophisticated permission schemes, such as multiple ownership,
    * granular roles, etc., could be built on top of this by making the owner a smart contract.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 29 of 64 : ExternalAUMFees.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    import "./ExternalFees.sol";
    library ExternalAUMFees {
    /**
    * @notice Calculates the amount of BPT to mint to pay AUM fees accrued since the last collection.
    * @dev This calculation assumes that the Pool's total supply is constant over the fee period.
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 30 of 64 : ExternalFees.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    library ExternalFees {
    using FixedPoint for uint256;
    /**
    * @dev Calculates the amount of BPT necessary to give ownership of a given percentage of the Pool to an external
    * third party. In the case of protocol fees, this is the DAO, but could also be a pool manager, etc.
    * Note that this function reverts if `poolPercentage` >= 100%, it's expected that the caller will enforce this.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 31 of 64 : InvariantGrowthProtocolSwapFees.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    import "./ExternalFees.sol";
    library InvariantGrowthProtocolSwapFees {
    using FixedPoint for uint256;
    function getProtocolOwnershipPercentage(
    uint256 invariantGrowthRatio,
    uint256 supplyGrowthRatio,
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 32 of 64 : ProtocolFeeCache.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-interfaces/contracts/pool-utils/IProtocolFeeCache.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/standalone-utils/IProtocolFeePercentagesProvider.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/openzeppelin/SafeCast.sol";
    import "../lib/VaultReentrancyLib.sol";
    import "../RecoveryMode.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 33 of 64 : BasePoolMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    library BasePoolMath {
    using FixedPoint for uint256;
    function computeProportionalAmountsIn(
    uint256[] memory balances,
    uint256 bptTotalSupply,
    uint256 bptAmountOut
    ) internal pure returns (uint256[] memory amountsIn) {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 34 of 64 : ComposablePoolLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    // solhint-disable no-inline-assembly
    library ComposablePoolLib {
    using FixedPoint for uint256;
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 35 of 64 : PoolRegistrationLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IVault.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/InputHelpers.sol";
    library PoolRegistrationLib {
    function registerPool(
    IVault vault,
    IVault.PoolSpecialization specialization,
    IERC20[] memory tokens
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 36 of 64 : VaultReentrancyLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity >=0.7.0 <0.9.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IVault.sol";
    library VaultReentrancyLib {
    /**
    * @dev Ensure we are not in a Vault context when this function is called, by attempting a no-op internal
    * balance operation. If we are already in a Vault transaction (e.g., a swap, join, or exit), the Vault's
    * reentrancy protection will cause this function to revert.
    *
    * The exact function call doesn't really matter: we're just trying to trigger the Vault reentrancy check
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 37 of 64 : NewBasePool.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-interfaces/contracts/vault/IVault.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IBasePool.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IGeneralPool.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IMinimalSwapInfoPool.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/TemporarilyPausable.sol";
    import "./BalancerPoolToken.sol";
    import "./BasePoolAuthorization.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 38 of 64 : RecoveryMode.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-utils/BasePoolUserData.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-utils/IRecoveryMode.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IVault.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "./BasePoolAuthorization.sol";
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 39 of 64 : Authentication.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/IAuthentication.sol";
    /**
    * @dev Building block for performing access control on external functions.
    *
    * This contract is used via the `authenticate` modifier (or the `_authenticateCaller` function), which can be applied
    * to external functions to only make them callable by authorized accounts.
    *
    * Derived contracts must implement the `_canPerform` function, which holds the actual access control logic.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 40 of 64 : EOASignaturesValidator.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/ISignaturesValidator.sol";
    import "../openzeppelin/EIP712.sol";
    /**
    * @dev Utility for signing Solidity function calls.
    */
    abstract contract EOASignaturesValidator is ISignaturesValidator, EIP712 {
    // Replay attack prevention for each account.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 41 of 64 : ERC20Helpers.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-interfaces/contracts/vault/IAsset.sol";
    // solhint-disable
    function _asIAsset(IERC20[] memory tokens) pure returns (IAsset[] memory assets) {
    // solhint-disable-next-line no-inline-assembly
    assembly {
    assets := tokens
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 42 of 64 : InputHelpers.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    library InputHelpers {
    function ensureInputLengthMatch(uint256 a, uint256 b) internal pure {
    _require(a == b, Errors.INPUT_LENGTH_MISMATCH);
    }
    function ensureInputLengthMatch(
    uint256 a,
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 43 of 64 : ScalingHelpers.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "../math/FixedPoint.sol";
    import "../math/Math.sol";
    import "../openzeppelin/ERC20.sol";
    import "./InputHelpers.sol";
    // solhint-disable
    // To simplify Pool logic, all token balances and amounts are normalized to behave as if the token had 18 decimals.
    // e.g. When comparing DAI (18 decimals) and USDC (6 decimals), 1 USDC and 1 DAI would both be represented as 1e18,
    // whereas without scaling 1 USDC would be represented as 1e6.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 44 of 64 : TemporarilyPausable.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/ITemporarilyPausable.sol";
    /**
    * @dev Allows for a contract to be paused during an initial period after deployment, disabling functionality. Can be
    * used as an emergency switch in case a security vulnerability or threat is identified.
    *
    * The contract can only be paused during the Pause Window, a period that starts at deployment. It can also be
    * unpaused and repaused any number of times during this period. This is intended to serve as a safety measure: it lets
    * system managers react quickly to potentially dangerous situations, knowing that this action is reversible if careful
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 45 of 64 : WordCodec.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "../math/Math.sol";
    /**
    * @dev Library for encoding and decoding values stored inside a 256 bit word. Typically used to pack multiple values in
    * a single storage slot, saving gas by performing less storage accesses.
    *
    * Each value is defined by its size and the least significant bit in the word, also known as offset. For example, two
    * 128 bit values may be encoded in a word by assigning one an offset of 0, and the other an offset of 128.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 46 of 64 : FixedPoint.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "./LogExpMath.sol";
    /* solhint-disable private-vars-leading-underscore */
    library FixedPoint {
    // solhint-disable no-inline-assembly
    uint256 internal constant ONE = 1e18; // 18 decimal places
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 47 of 64 : LogExpMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    // Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
    // documentation files (the “Software”), to deal in the Software without restriction, including without limitation the
    // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
    // permit persons to whom the Software is furnished to do so, subject to the following conditions:
    // The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
    // Software.
    // THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
    // WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
    // COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
    // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    /* solhint-disable */
    /**
    * @dev Exponentiation and logarithm functions for 18 decimal fixed point numbers (both base and exponent/argument).
    *
    * Exponentiation and logarithm with arbitrary bases (x^y and log_x(y)) are implemented by conversion to natural
    * exponentiation and logarithm (where the base is Euler's number).
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 48 of 64 : Math.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    /**
    * @dev Wrappers over Solidity's arithmetic operations with added overflow checks.
    * Adapted from OpenZeppelin's SafeMath library.
    */
    library Math {
    // solhint-disable no-inline-assembly
    /**
    * @dev Returns the absolute value of a signed integer.
    */
    function abs(int256 a) internal pure returns (uint256 result) {
    // Equivalent to:
    // result = a > 0 ? uint256(a) : uint256(-a)
    assembly {
    let s := sar(255, a)
    result := sub(xor(a, s), s)
    }
    }
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 49 of 64 : EIP712.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    /**
    * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
    *
    * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,
    * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding
    * they need in their contracts using a combination of `abi.encode` and `keccak256`.
    *
    * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
    * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
    * ({_hashTypedDataV4}).
    *
    * The implementation of the domain separator was designed to be as efficient as possible while still properly updating
    * the chain id to protect against replay attacks on an eventual fork of the chain.
    *
    * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
    * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
    *
    * _Available since v3.4._
    */
    abstract contract EIP712 {
    /* solhint-disable var-name-mixedcase */
    bytes32 private immutable _HASHED_NAME;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 50 of 64 : ERC20.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "./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
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 51 of 64 : ERC20Permit.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20Permit.sol";
    import "./ERC20.sol";
    import "../helpers/EOASignaturesValidator.sol";
    /**
    * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
    * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
    *
    * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
    * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't
    * need to send a transaction, and thus is not required to hold Ether at all.
    *
    * _Available since v3.4._
    */
    abstract contract ERC20Permit is ERC20, IERC20Permit, EOASignaturesValidator {
    // solhint-disable-next-line var-name-mixedcase
    bytes32 private constant _PERMIT_TYPEHASH = keccak256(
    "Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"
    );
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 52 of 64 : SafeCast.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    /**
    * @dev Wrappers over Solidity's uintXX/intXX casting operators with added overflow
    * checks.
    *
    * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can
    * easily result in undesired exploitation or bugs, since developers usually
    * assume that overflows raise errors. `SafeCast` restores this intuition by
    * reverting the transaction when such 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.
    *
    * Can be combined with {SafeMath} and {SignedSafeMath} to extend it to smaller types, by performing
    * all math on `uint256` and `int256` and then downcasting.
    */
    library SafeCast {
    /**
    * @dev Converts an unsigned uint256 into a signed int256.
    *
    * Requirements:
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 53 of 64 : SafeMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: MIT
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    /**
    * @dev Wrappers over Solidity's arithmetic operations with added overflow
    * checks.
    *
    * Arithmetic operations in Solidity wrap on overflow. This can easily result
    * in bugs, because programmers usually assume that an overflow raises an
    * error, which is the standard behavior in high level programming languages.
    * `SafeMath` restores this intuition by reverting the transaction when an
    * operation overflows.
    *
    * Using this library instead of the unchecked operations eliminates an entire
    * class of bugs, so it's recommended to use it always.
    */
    library SafeMath {
    /**
    * @dev Returns the addition of two unsigned integers, reverting on
    * overflow.
    *
    * Counterpart to Solidity's `+` operator.
    *
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 54 of 64 : CircuitBreakerLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    /**
    * @title Circuit Breaker Library
    * @notice Library for logic and functions related to circuit breakers.
    */
    library CircuitBreakerLib {
    using FixedPoint for uint256;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 55 of 64 : GradualValueChange.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    pragma solidity ^0.7.0;
    // solhint-disable not-rely-on-time
    library GradualValueChange {
    using FixedPoint for uint256;
    function getInterpolatedValue(
    uint256 startValue,
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 56 of 64 : ValueCompression.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    /**
    * @dev Library for compressing and decompressing numbers by using smaller types.
    * All values are 18 decimal fixed-point numbers, so heavier compression (fewer bits)
    * results in fewer decimals.
    */
    library ValueCompression {
    /**
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 57 of 64 : CircuitBreakerStorageLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    import "../lib/ValueCompression.sol";
    import "../lib/CircuitBreakerLib.sol";
    /**
    * @title Circuit Breaker Storage Library
    * @notice Library for storing and manipulating state related to circuit breakers.
    * @dev The intent of circuit breakers is to halt trading of a given token if its value changes drastically -
    * in either direction - with respect to other tokens in the pool. For instance, a stablecoin might de-peg
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 58 of 64 : ManagedPoolAddRemoveTokenLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/helpers/BalancerErrors.sol";
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-pool-utils/contracts/lib/PoolRegistrationLib.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "./ManagedPoolStorageLib.sol";
    import "./ManagedPoolTokenStorageLib.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 59 of 64 : ManagedPoolAmmLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-interfaces/contracts/pool-weighted/IExternalWeightedMath.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-weighted/WeightedPoolUserData.sol";
    import "@balancer-labs/v2-pool-utils/contracts/lib/ComposablePoolLib.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/ScalingHelpers.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/Authentication.sol";
    import "../managed/CircuitBreakerStorageLib.sol";
    import "./ManagedPoolTokenStorageLib.sol";
    import "./ManagedPoolStorageLib.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 60 of 64 : ManagedPoolAumStorageLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    /**
    * @title Managed Pool AUM Storage Library
    * @notice Library for manipulating a bitmap used for Pool state used for charging AUM fees in ManagedPool.
    */
    library ManagedPoolAumStorageLib {
    using WordCodec for bytes32;
    // Store AUM fee values:
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 61 of 64 : ManagedPoolSettings.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-interfaces/contracts/pool-weighted/WeightedPoolUserData.sol";
    import "@balancer-labs/v2-interfaces/contracts/pool-utils/IManagedPool.sol";
    import "@balancer-labs/v2-interfaces/contracts/standalone-utils/IProtocolFeePercentagesProvider.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/ERC20Helpers.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/ScalingHelpers.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    import "@balancer-labs/v2-pool-utils/contracts/lib/PoolRegistrationLib.sol";
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 62 of 64 : ManagedPoolStorageLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    import "../lib/GradualValueChange.sol";
    /**
    * @title Managed Pool Storage Library
    * @notice Library for manipulating a bitmap used for commonly used Pool state in ManagedPool.
    */
    library ManagedPoolStorageLib {
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 63 of 64 : ManagedPoolTokenStorageLib.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    pragma experimental ABIEncoderV2;
    import "@balancer-labs/v2-interfaces/contracts/solidity-utils/openzeppelin/IERC20.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/WordCodec.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/openzeppelin/ERC20.sol";
    import "../lib/GradualValueChange.sol";
    /**
    * @title Managed Pool Token Library
    * @notice Library for manipulating bitmaps used for storing token-related state in ManagedPool.
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    File 64 of 64 : WeightedMath.sol
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    // SPDX-License-Identifier: GPL-3.0-or-later
    // This program is free software: you can redistribute it and/or modify
    // it under the terms of the GNU General Public License as published by
    // the Free Software Foundation, either version 3 of the License, or
    // (at your option) any later version.
    // This program is distributed in the hope that it will be useful,
    // but WITHOUT ANY WARRANTY; without even the implied warranty of
    // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    // GNU General Public License for more details.
    // You should have received a copy of the GNU General Public License
    // along with this program. If not, see <http://www.gnu.org/licenses/>.
    pragma solidity ^0.7.0;
    import "@balancer-labs/v2-solidity-utils/contracts/helpers/InputHelpers.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/FixedPoint.sol";
    import "@balancer-labs/v2-solidity-utils/contracts/math/Math.sol";
    // These functions start with an underscore, as if they were part of a contract and not a library. At some point this
    // should be fixed.
    // solhint-disable private-vars-leading-underscore
    library WeightedMath {
    using FixedPoint for uint256;
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Settings
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    {
    "optimizer": {
    "enabled": true,
    "runs": 140
    },
    "outputSelection": {
    "*": {
    "*": [
    "evm.bytecode",
    "evm.deployedBytecode",
    "devdoc",
    "userdoc",
    "metadata",
    "abi"
    ]
    }
    },
    "libraries": {
    "contracts/lib/CircuitBreakerLib.sol": {
    "CircuitBreakerLib": "0xa46630db2d331223a505c746b58dc320fec7f03a"
    },
    "contracts/managed/ManagedPoolAddRemoveTokenLib.sol": {
    "ManagedPoolAddRemoveTokenLib": "0x46cc8bdf077f7ccf37b4b26183d41f22b4e4246e"
    },
    "contracts/managed/ManagedPoolAmmLib.sol": {
    "ManagedPoolAmmLib": "0xd2ff08ef7ee7c14e00b1b89d44815283667ab57c"
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Contract Security Audit

    Contract ABI

    API
    [{"inputs":[{"components":[{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"address[]","name":"assetManagers","type":"address[]"}],"internalType":"struct ManagedPool.ManagedPoolParams","name":"params","type":"tuple"},{"components":[{"internalType":"contract IVault","name":"vault","type":"address"},{"internalType":"contract IProtocolFeePercentagesProvider","name":"protocolFeeProvider","type":"address"},{"internalType":"contract IExternalWeightedMath","name":"weightedMath","type":"address"},{"internalType":"contract IRecoveryModeHelper","name":"recoveryModeHelper","type":"address"},{"internalType":"uint256","name":"pauseWindowDuration","type":"uint256"},{"internalType":"uint256","name":"bufferPeriodDuration","type":"uint256"},{"internalType":"string","name":"version","type":"string"}],"internalType":"struct ManagedPool.ManagedPoolConfigParams","name":"configParams","type":"tuple"},{"components":[{"internalType":"contract IERC20[]","name":"tokens","type":"address[]"},{"internalType":"uint256[]","name":"normalizedWeights","type":"uint256[]"},{"internalType":"uint256","name":"swapFeePercentage","type":"uint256"},{"internalType":"bool","name":"swapEnabledOnStart","type":"bool"},{"internalType":"bool","name":"mustAllowlistLPs","type":"bool"},{"internalType":"uint256","name":"managementAumFeePercentage","type":"uint256"},{"internalType":"uint256","name":"aumFeeId","type":"uint256"}],"internalType":"struct ManagedPoolSettings.ManagedPoolSettingsParams","name":"settingsParams","type":"tuple"},{"internalType":"address","name":"owner","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"member","type":"address"}],"name":"AllowlistAddressAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"member","type":"address"}],"name":"AllowlistAddressRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IERC20","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"bptPrice","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"lowerBoundPercentage","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"upperBoundPercentage","type":"uint256"}],"name":"CircuitBreakerSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"endTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startSwapFeePercentage","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"endSwapFeePercentage","type":"uint256"}],"name":"GradualSwapFeeUpdateScheduled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"endTime","type":"uint256"},{"indexed":false,"internalType":"uint256[]","name":"startWeights","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"endWeights","type":"uint256[]"}],"name":"GradualWeightUpdateScheduled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"joinExitEnabled","type":"bool"}],"name":"JoinExitEnabledSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"bptAmount","type":"uint256"}],"name":"ManagementAumFeeCollected","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"managementAumFeePercentage","type":"uint256"}],"name":"ManagementAumFeePercentageChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"mustAllowlistLPs","type":"bool"}],"name":"MustAllowlistLPsSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"paused","type":"bool"}],"name":"PausedStateChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"feeCache","type":"bytes32"}],"name":"ProtocolFeePercentageCacheUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"enabled","type":"bool"}],"name":"RecoveryModeStateChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"swapEnabled","type":"bool"}],"name":"SwapEnabledSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IERC20","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"normalizedWeight","type":"uint256"}],"name":"TokenAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"contract IERC20","name":"token","type":"address"}],"name":"TokenRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"member","type":"address"}],"name":"addAllowedAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"tokenToAdd","type":"address"},{"internalType":"address","name":"assetManager","type":"address"},{"internalType":"uint256","name":"tokenToAddNormalizedWeight","type":"uint256"},{"internalType":"uint256","name":"mintAmount","type":"uint256"},{"internalType":"address","name":"recipient","type":"address"}],"name":"addToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"collectAumManagementFees","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"disableRecoveryMode","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"enableRecoveryMode","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"selector","type":"bytes4"}],"name":"getActionId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getActualSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAuthorizer","outputs":[{"internalType":"contract IAuthorizer","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"getCircuitBreakerState","outputs":[{"internalType":"uint256","name":"bptPrice","type":"uint256"},{"internalType":"uint256","name":"referenceWeight","type":"uint256"},{"internalType":"uint256","name":"lowerBound","type":"uint256"},{"internalType":"uint256","name":"upperBound","type":"uint256"},{"internalType":"uint256","name":"lowerBptPriceBound","type":"uint256"},{"internalType":"uint256","name":"upperBptPriceBound","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getDomainSeparator","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getGradualSwapFeeUpdateParams","outputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256","name":"startSwapFeePercentage","type":"uint256"},{"internalType":"uint256","name":"endSwapFeePercentage","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getGradualWeightUpdateParams","outputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256[]","name":"startWeights","type":"uint256[]"},{"internalType":"uint256[]","name":"endWeights","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getJoinExitEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getManagementAumFeeParams","outputs":[{"internalType":"uint256","name":"aumFeePercentage","type":"uint256"},{"internalType":"uint256","name":"lastCollectionTimestamp","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMustAllowlistLPs","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"getNextNonce","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNormalizedWeights","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPausedState","outputs":[{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"uint256","name":"pauseWindowEndTime","type":"uint256"},{"internalType":"uint256","name":"bufferPeriodEndTime","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPoolId","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"feeType","type":"uint256"}],"name":"getProtocolFeePercentageCache","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getProtocolFeesCollector","outputs":[{"internalType":"contract IProtocolFeesCollector","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"feeType","type":"uint256"}],"name":"getProviderFeeId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getScalingFactors","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getSwapEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getSwapFeePercentage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getVault","outputs":[{"internalType":"contract IVault","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"inRecoveryMode","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"member","type":"address"}],"name":"isAddressOnAllowlist","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"poolId","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"userData","type":"bytes"}],"name":"onExitPool","outputs":[{"internalType":"uint256[]","name":"amountsOut","type":"uint256[]"},{"internalType":"uint256[]","name":"dueProtocolFees","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"poolId","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"userData","type":"bytes"}],"name":"onJoinPool","outputs":[{"internalType":"uint256[]","name":"amountsIn","type":"uint256[]"},{"internalType":"uint256[]","name":"dueProtocolFees","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"enum IVault.SwapKind","name":"kind","type":"uint8"},{"internalType":"contract IERC20","name":"tokenIn","type":"address"},{"internalType":"contract IERC20","name":"tokenOut","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes32","name":"poolId","type":"bytes32"},{"internalType":"uint256","name":"lastChangeBlock","type":"uint256"},{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes","name":"userData","type":"bytes"}],"internalType":"struct IPoolSwapStructs.SwapRequest","name":"request","type":"tuple"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"},{"internalType":"uint256","name":"indexIn","type":"uint256"},{"internalType":"uint256","name":"indexOut","type":"uint256"}],"name":"onSwap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"enum IVault.SwapKind","name":"kind","type":"uint8"},{"internalType":"contract IERC20","name":"tokenIn","type":"address"},{"internalType":"contract IERC20","name":"tokenOut","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes32","name":"poolId","type":"bytes32"},{"internalType":"uint256","name":"lastChangeBlock","type":"uint256"},{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes","name":"userData","type":"bytes"}],"internalType":"struct IPoolSwapStructs.SwapRequest","name":"request","type":"tuple"},{"internalType":"uint256","name":"balanceTokenIn","type":"uint256"},{"internalType":"uint256","name":"balanceTokenOut","type":"uint256"}],"name":"onSwap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"uint256","name":"deadline","type":"uint256"},{"internalType":"uint8","name":"v","type":"uint8"},{"internalType":"bytes32","name":"r","type":"bytes32"},{"internalType":"bytes32","name":"s","type":"bytes32"}],"name":"permit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"userData","type":"bytes"}],"name":"queryExit","outputs":[{"internalType":"uint256","name":"bptIn","type":"uint256"},{"internalType":"uint256[]","name":"amountsOut","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"balances","type":"uint256[]"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"bytes","name":"userData","type":"bytes"}],"name":"queryJoin","outputs":[{"internalType":"uint256","name":"bptOut","type":"uint256"},{"internalType":"uint256[]","name":"amountsIn","type":"uint256[]"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"member","type":"address"}],"name":"removeAllowedAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"tokenToRemove","type":"address"},{"internalType":"uint256","name":"burnAmount","type":"uint256"},{"internalType":"address","name":"sender","type":"address"}],"name":"removeToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20[]","name":"tokens","type":"address[]"},{"internalType":"uint256[]","name":"bptPrices","type":"uint256[]"},{"internalType":"uint256[]","name":"lowerBoundPercentages","type":"uint256[]"},{"internalType":"uint256[]","name":"upperBoundPercentages","type":"uint256[]"}],"name":"setCircuitBreakers","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"joinExitEnabled","type":"bool"}],"name":"setJoinExitEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"managementAumFeePercentage","type":"uint256"}],"name":"setManagementAumFeePercentage","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"mustAllowlistLPs","type":"bool"}],"name":"setMustAllowlistLPs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"swapEnabled","type":"bool"}],"name":"setSwapEnabled","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"updateProtocolFeePercentageCache","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256","name":"startSwapFeePercentage","type":"uint256"},{"internalType":"uint256","name":"endSwapFeePercentage","type":"uint256"}],"name":"updateSwapFeeGradually","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"contract IERC20[]","name":"tokens","type":"address[]"},{"internalType":"uint256[]","name":"endWeights","type":"uint256[]"}],"name":"updateWeightsGradually","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"version","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}]

    Deployed Bytecode

    0x608060405234801561001057600080fd5b506004361061033a5760003560e01c80637beed220116101b4578063a457c2d7116100fa578063d5c096c41161009d578063d5c096c4146106bf578063dd62ed3e146106d2578063de3d2b2d146106e5578063e01af92c146106f8578063ebf1b7421461070b578063ed24911d14610730578063f885a4bb14610738578063f89f27ed1461074b5761033a565b8063a457c2d714610653578063a9059cbb14610666578063aaabadc514610679578063b35056b814610681578063b62c1f0614610689578063b7b814fc1461069c578063d2946c2b146106a4578063d505accf146106ac5761033a565b806387ec68171161016257806387ec6817146105da578063893d20e8146105ed5780638d027466146106025780638d928af81461060a57806390193b7c1461061257806395d89b411461062557806397bb15c91461062d5780639d2c110c146106405761033a565b80637beed220146105665780637ecebe001461057e57806381788e2b14610591578063819c70f3146105a45780638456cb59146105b7578063851c1bb3146105bf578063876f303b146105d25761033a565b80633c9d93b8116102845780636028bfd4116102275780636028bfd4146104b55780636a2efb2c146104d65780636b47273b146104ee578063704640161461050457806370a082311461051757806373656f891461052a57806374f3b009146105325780637b749c45146105535761033a565b80633c9d93b81461045f5780633f4ba83a1461047257806341e45a201461047a57806347bc4d92146104825780634df77ce01461048a57806354a844ba1461049d57806354fd4d50146104a557806355c67628146104ad5761033a565b806323b872dd116102ec57806323b872dd146103db5780632a9a0323146103ee578063313ce5671461040157806334a36df8146104165780633644e5151461042957806336eb097b1461043157806338fff2d014610444578063395093511461044c5761033a565b806301ec954a1461033f57806306fdde0314610368578063095ea7b31461037d5780630da0669c1461039d57806318160ddd146103a75780631c0de051146103af5780631dd746ea146103c6575b600080fd5b61035261034d3660046156c4565b610753565b60405161035f9190615a91565b60405180910390f35b6103706107b3565b60405161035f9190615d07565b61039061038b366004615298565b610849565b60405161035f9190615a6e565b6103a5610860565b005b6103526108c4565b6103b76108ca565b60405161035f93929190615a79565b6103ce6108f3565b60405161035f91906159a8565b6103906103e93660046151e8565b610910565b6103526103fc36600461577f565b610986565b6104096109cd565b60405161035f9190615cf9565b6103a56104243660046155c8565b6109d6565b610352610b74565b61039061043f366004615194565b610b83565b610352610ba5565b61039061045a366004615298565b610bc9565b6103a561046d366004615194565b610c04565b6103a5610c71565b610390610c83565b610390610c90565b61035261049836600461577f565b610c9d565b6103a5610d06565b610370610d5a565b610352610dbb565b6104c86104c3366004615479565b610dc8565b60405161035f929190615d83565b6104de610de6565b60405161035f9493929190615e14565b6104f6610e05565b60405161035f929190615d9c565b61035261051236600461577f565b610e32565b610352610525366004615194565b610e94565b610352610eaf565b610545610540366004615479565b610ee4565b60405161035f9291906159bb565b6103a5610561366004615429565b610fa5565b61056e610fc1565b60405161035f9493929190615daa565b61035261058c366004615194565b6110f7565b6103a561059f366004615194565b611102565b6103a56105b23660046157c5565b611173565b6103a561121e565b6103526105cd366004615584565b611230565b610352611282565b6104c86105e8366004615479565b611294565b6105f56112a6565b60405161035f9190615994565b6103906112ca565b6105f56112d7565b610352610620366004615194565b6112fb565b610370611316565b6103a561063b366004615626565b611377565b61035261064e366004615734565b611542565b610390610661366004615298565b61157b565b610390610674366004615298565b6115b9565b6105f56115c6565b6103906115d0565b6103a561069736600461584a565b6115dd565b6103a5611608565b6105f5611652565b6103a56106ba366004615228565b611676565b6105456106cd366004615479565b611701565b6103526106e03660046151b0565b611798565b6103a56106f3366004615429565b6117d5565b6103a5610706366004615429565b6117ee565b61071e610719366004615194565b611807565b60405161035f96959493929190615e52565b6103526118ab565b6103a5610746366004615319565b6118b5565b6103ce61194b565b600084608001516107806107656112d7565b6001600160a01b0316336001600160a01b03161460cd611c85565b61079561078b610ba5565b82146101f4611c85565b61079d611c93565b6107a986868686611ca6565b9695505050505050565b60038054604080516020601f600260001961010060018816150201909516949094049384018190048102820181019092528281526060939092909183018282801561083f5780601f106108145761010080835404028352916020019161083f565b820191906000526020600020905b81548152906001019060200180831161082257829003601f168201915b5050505050905090565b6000610856338484611cb3565b5060015b92915050565b61087061086b611d1b565b611d3f565b610878611dfb565b6108c27f0000000000000000000000006d5657a51b11c56945603415f113f09687cd1f127f0000000000000000000000000000000000000000000000000000000000000200611e1e565b565b60025490565b60008060006108d7612032565b1592506108e261204f565b91506108ec612073565b9050909192565b6060806108fe612097565b50905061090a81612144565b91505090565b60008061091d8533611798565b9050610941336001600160a01b03871614806109395750838210155b61019e611c85565b61094c8585856121fe565b336001600160a01b0386161480159061096757506000198114155b15610979576109798533858403611cb3565b60019150505b9392505050565b60006109906122de565b610998611c93565b6109a061230c565b60006109aa612317565b905080156109be576109bb816123c1565b91505b6109c78361247d565b50919050565b60055460ff1690565b6109de6122de565b6109e6611c93565b6109ee61230c565b60006109f8612317565b9050610a086000821160ce611c85565b610a11816123c1565b50506060610a1d612097565b509050610a3360328251600101111560c9611c85565b60006060807346cc8bdf077f7ccf37b4b26183d41f22b4e4246e631face20a610a5a6112d7565b610a62610ba5565b60095488610a6f8a6124de565b8f8f8f6040518963ffffffff1660e01b8152600401610a95989796959493929190615bfd565b60006040518083038186803b158015610aad57600080fd5b505af4158015610ac1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ae9919081019061551b565b6001600160a01b038c166000908152600b6020526040902083905591945092509050610b1842808380866125a9565b8515610b2857610b2885876126cb565b886001600160a01b03167ff4c563a3ea86ff1f4275e8c207df0375a51963f2b831b7bf4da8be938d92876c88604051610b619190615a91565b60405180910390a2505050505050505050565b6000610b7e6118ab565b905090565b6001600160a01b0381166000908152600d602052604090205460ff165b919050565b7f0cdac437ce63a1e1b1cab10ab4df032234bb39a300010000000000000000000190565b3360008181526001602090815260408083206001600160a01b03871684529091528120549091610856918590610bff9086611b7a565b611cb3565b610c0c6122de565b610c14611c93565b610c28610c2082610b83565b6101b1611c85565b6001600160a01b0381166000818152600d6020526040808220805460ff19169055517f89aa0423af0b4cf311bfb79f61549f2b82b335f041e4f7ae674618059b51a4cb9190a250565b610c796122de565b6108c260006126d5565b6000610b7e600954612748565b6000610b7e600954612755565b60008082610cad57506000610cda565b6002831415610cbe57506008610cda565b6003831415610ccf57506010610cda565b610cda6101bb612762565b61097f7f0000000000000000000000000000000000000000000000000000000000000200826008611b5c565b610d0e6122de565b610d16612772565b610d206001612786565b7feff3d4d215b42bf0960be9c6d5e05c22cba4df6627a3a523e2acee733b5854c86001604051610d509190615a6e565b60405180910390a1565b600e8054604080516020601f600260001961010060018816150201909516949094049384018190048102820181019092528281526060939092909183018282801561083f5780601f106108145761010080835404028352916020019161083f565b6000610b7e6009546127a2565b60006060610dda8887856127c76128cc565b97509795505050505050565b600080600080610df76009546129c6565b935093509350935090919293565b600080610e13600a54612a0e565b6009549193509150610e2490612a33565b15610e2e57600091505b9091565b6000610e3c6115d0565b15610e4957506000610ba0565b600082610e5857506000610e85565b6002831415610e6957506040610e85565b6003831415610e7a57506080610e85565b610e856101bb612762565b60085461097f90826040611b5c565b6001600160a01b031660009081526020819052604090205490565b6000610eb9611c93565b610ec161230c565b6000610ecb612317565b9050610edb6000821160ce611c85565b61090a816123c1565b60608088610ef36107656112d7565b610efe61078b610ba5565b6000610f0985612a40565b15610f3157610f16612a6f565b610f2888610f226108c4565b87612a82565b94509050610f49565b610f39611c93565b610f448a89876127c7565b945090505b610f538a82612b24565b83516001600160401b0381118015610f6a57600080fd5b50604051908082528060200260200182016040528015610f94578160200160208202803683370190505b509250505097509795505050505050565b610fad6122de565b610fb5611c93565b610fbe81612b2e565b50565b600080606080610fd2600954612b6d565b90945092506060610fe1612097565b50905080516001600160401b0381118015610ffb57600080fd5b50604051908082528060200260200182016040528015611025578160200160208202803683370190505b50925080516001600160401b038111801561103f57600080fd5b50604051908082528060200260200182016040528015611069578160200160208202803683370190505b50915060005b81518110156110ef576110b9600b600084848151811061108b57fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002054612b8a565b8583815181106110c557fe5b602002602001018584815181106110d857fe5b60209081029190910101919091525260010161106f565b505090919293565b600061085a826112fb565b61110a6122de565b611112611c93565b61112761111e82610b83565b156101b0611c85565b6001600160a01b0381166000818152600d6020526040808220805460ff19166001179055517fbf5840c727acdcaceea5154edc82998fa82a490aa3dc7aeb66849c8bbea1f5799190a250565b61117b6122de565b611183611c93565b606061118d612097565b50905061119e835182518451612ba7565b60005b81518110156111f8576111f08482815181106111b957fe5b60200260200101516001600160a01b03168383815181106111d657fe5b60200260200101516001600160a01b031614610208611c85565b6001016111a1565b506112176112068686612bc4565b85611210866124de565b85876125a9565b5050505050565b6112266122de565b6108c260016126d5565b60007f000000000000000000000000863ef18f10ee05f468fc0c56bbc6947c69abc88682604051602001611265929190615935565b604051602081830303815290604052805190602001209050919050565b6000610b7e61128f612317565b612be1565b60006060610dda888785612c0c6128cc565b7f000000000000000000000000ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1b90565b6000610b7e600954612d24565b7f000000000000000000000000575ac25f047a76b467a84bfa69b328d6ebc6ae6090565b6001600160a01b031660009081526006602052604090205490565b60048054604080516020601f600260001961010060018816150201909516949094049384018190048102820181019092528281526060939092909183018282801561083f5780601f106108145761010080835404028352916020019161083f565b61137f6122de565b611387611c93565b61138f61230c565b6000611399612317565b90506113a96000821160ce611c85565b6113b2816123c1565b505060606113be612097565b5090506113d460026001835103101560c8611c85565b6001600160a01b0384166000908152600b60205260408120546113ff90670de0b6b3a7640000612d31565b90506060807346cc8bdf077f7ccf37b4b26183d41f22b4e4246e63a20d2e4d6114266112d7565b61142e610ba5565b6009548861143b8a6124de565b8d8a6040518863ffffffff1660e01b815260040161145f9796959493929190615c60565b60006040518083038186803b15801561147757600080fd5b505af415801561148b573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526114b391908101906152c3565b6001600160a01b0389166000908152600b602052604081205590925090506114de42808380866125a9565b8515611505576114fb6001600160a01b03861615156101bc611c85565b6115058587612b24565b6040516001600160a01b038816907f4c910b69fe65a61f7531b9c5042b2329ca7179c77290aa7e2eb3afa3c8511fd390600090a250505050505050565b600083608001516115546107656112d7565b61155f61078b610ba5565b611567611c93565b611572858585612d54565b95945050505050565b6000806115883385611798565b90508083106115a25761159d33856000611cb3565b6115af565b6115af3385858403611cb3565b5060019392505050565b60006108563384846121fe565b6000610b7e612e20565b6000610b7e600954612a33565b6115e56122de565b6115ed611c93565b6116026115fa8585612bc4565b848484612e9a565b50505050565b6116106122de565b611618612a6f565b6116226000612786565b7feff3d4d215b42bf0960be9c6d5e05c22cba4df6627a3a523e2acee733b5854c86000604051610d509190615a6e565b7f000000000000000000000000c148f6d6878ebd809fb3b3c9c1b243d8a6d71df890565b60007f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c98888886116a58c6112fb565b896040516020016116bb96959493929190615ab9565b6040516020818303038152906040528051906020012090506116ec88826116e3878787612f02565b886101f8612f41565b6116f7888888611cb3565b5050505050505050565b606080886117106107656112d7565b61171b61078b610ba5565b6000611725611c93565b61172d6108c4565b61177f5761173c8a8a87612f98565b9450905061175561174b61310f565b82101560cc611c85565b611767600061176261310f565b6126cb565b61177a8961177361310f565b83036126cb565b610f53565b61178a8a8987612c0c565b94509050610f5389826126cb565b60006117a26112d7565b6001600160a01b0316826001600160a01b031614156117c4575060001961085a565b6117ce8383613116565b905061085a565b6117dd6122de565b6117e5611c93565b610fbe81613141565b6117f66122de565b6117fe611c93565b610fbe81613180565b6001600160a01b0381166000908152600c602052604081205481908190819081908190611833816131bf565b9299509097509550935060006118488961320d565b90506118568282600161323c565b93506118648282600061323c565b925060006118796118748b613376565b613391565b905061188589826133b5565b985061189185826133b5565b945061189d84826133b5565b935050505091939550919395565b6000610b7e6133c1565b6118bd6122de565b6118c5611c93565b6118d3845183518351612ba7565b6118df84518451611b28565b60005b8451811015611217576119438582815181106118fa57fe5b602002602001015185838151811061190e57fe5b602002602001015185848151811061192257fe5b602002602001015185858151811061193657fe5b602002602001015161345e565b6001016118e2565b606080611956612097565b50905061090a816124de565b600061196d83611b52565b606083516001016001600160401b038111801561198957600080fd5b506040519080825280602002602001820160405280156119b3578160200160208202803683370190505b50905030816000815181106119c457fe5b60200260200101906001600160a01b031690816001600160a01b03168152505060005b8451811015611a33578481815181106119fc57fe5b6020026020010151828260010181518110611a1357fe5b6001600160a01b03909216602092830291909101909101526001016119e7565b50606083516001016001600160401b0381118015611a5057600080fd5b50604051908082528060200260200182016040528015611a7a578160200160208202803683370190505b509050600081600081518110611a8c57fe5b60200260200101906001600160a01b031690816001600160a01b03168152505060005b8451811015611afb57848181518110611ac457fe5b6020026020010151828260010181518110611adb57fe5b6001600160a01b0390921660209283029190910190910152600101611aaf565b50611b08878784846134ff565b925050505b949350505050565b6000611b228484846135ef565b50501b90565b611b358183146067611c85565b5050565b6000611b458184613636565b905061097f818384611b8c565b80611b35816136c5565b6001901b6000190191901c1690565b600061097f838383603c611c3d565b600082820161097f8482101583611c85565b6000611b0d82604080611ba188888784611c3d565b929190611c3d565b6000611bb88484836020611c3d565b9350611b0d8483602080611c3d565b6000611bd7868660406020611c3d565b9550611be7868560606020611c3d565b9550611bf786846080603e611c3d565b95506107a9868360be603e611c3d565b600061097f838360fc611c76565b600061097f838360fd611c76565b600061097f838360ff611c76565b80820390821102900390565b6000611c4a8484846135ef565b506001901b60001901811b1992909216911b1790565b6000611c70838311156001611c85565b50900390565b6001811b1992909216911b1790565b81611b3557611b3581612762565b6108c2611c9e612032565b610192611c85565b6000611b0d6103e6612762565b6001600160a01b0380841660008181526001602090815260408083209487168084529490915290819020849055517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92590611d0e908590615a91565b60405180910390a3505050565b7f000000000000000000000000575ac25f047a76b467a84bfa69b328d6ebc6ae6090565b6060816001600160a01b0316612710630e8e3e8460e01b6000604051602401611d689190615cf9565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909416939093179092529051611da6919061595d565b6000604051808303818686fa925050503d8060008114611de2576040519150601f19603f3d011682016040523d82523d6000602084013e611de7565b606091505b50915050611b358151600014610190611c85565b611e03611c93565b6000611e0d612317565b90508015610fbe57611b35816123c1565b60006001600160a01b038316631a7c3263611e3b84846008611b5c565b6040518263ffffffff1660e01b8152600401611e579190615a91565b60206040518083038186803b158015611e6f57600080fd5b505afa158015611e83573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ea79190615461565b905060006001600160a01b038416631a7c3263611ec685600880611b5c565b6040518263ffffffff1660e01b8152600401611ee29190615a91565b60206040518083038186803b158015611efa57600080fd5b505afa158015611f0e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f329190615461565b905060006001600160a01b038516631a7c3263611f528660106008611b5c565b6040518263ffffffff1660e01b8152600401611f6e9190615a91565b60206040518083038186803b158015611f8657600080fd5b505afa158015611f9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611fbe9190615461565b90506000611fcf8260806040611b15565b611fdb84604080611b15565b611fe88660006040611b15565b17179050806008819055507fc3f0acc358200d8e08ac6ce20bc2f9f27893a344f813bf682b7859b3e521502e816040516120229190615a91565b60405180910390a1505050505050565b600061203c612073565b421180610b7e57505060075460ff161590565b7f0000000000000000000000000000000000000000000000000000000067e50f2690565b7f0000000000000000000000000000000000000000000000000000000067e50f2690565b6060806060806120a56112d7565b6001600160a01b031663f94d46686120bb610ba5565b6040518263ffffffff1660e01b81526004016120d79190615a91565b60006040518083038186803b1580156120ef57600080fd5b505afa158015612103573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261212b91908101906153c0565b509150915061213a828261373e565b9350935050509091565b8051606090806001600160401b038111801561215f57600080fd5b50604051908082528060200260200182016040528015612189578160200160208202803683370190505b50915060005b818110156121f7576121d8600b60008684815181106121aa57fe5b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002054613391565b8382815181106121e457fe5b602090810291909101015260010161218f565b5050919050565b6122156001600160a01b0384161515610198611c85565b61222c6001600160a01b0383161515610199611c85565b612237838383612bbf565b6001600160a01b03831660009081526020819052604090205461225d90826101a061375e565b6001600160a01b03808516600090815260208190526040808220939093559084168152205461228c9082611b7a565b6001600160a01b0380841660008181526020819052604090819020939093559151908516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90611d0e908590615a91565b60006122f56000356001600160e01b031916611230565b9050610fbe6123048233613774565b610191611c85565b6108c261086b6112d7565b60008060006123246112d7565b6001600160a01b031663b05f8e4861233a610ba5565b306040518363ffffffff1660e01b8152600401612358929190615bc8565b60806040518083038186803b15801561237057600080fd5b505afa158015612384573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123a8919061580a565b5050915091508082016123b96108c4565b039250505090565b60008060006123ce610e05565b9150915060006123e08542848661385d565b90506123ea6138a1565b806123fb5760009350505050610ba0565b600061241161240a6003610e32565b83906138b2565b9050600061241f8383611c60565b905061242a826138f4565b7f0666d5a83bb8143573350414d5a13dbdcac60a706160576416096ad6a41c0ea5816040516124599190615a91565b60405180910390a161247261246c6112a6565b826126cb565b509095945050505050565b612494670d2f13f7789f0000821115610160611c85565b6124a0600a5482611b6b565b600a556040517f556cdf4052d939f8acbe593d83668d2e18500b032bcf51cbbf82b181c6094dd7906124d3908390615a91565b60405180910390a150565b606060006124ed600954613905565b8351909150806001600160401b038111801561250857600080fd5b50604051908082528060200260200182016040528015612532578160200160208202803683370190505b50925060005b818110156125a157612582600b600087848151811061255357fe5b60200260200101516001600160a01b03166001600160a01b031681526020019081526020016000205484612d31565b84828151811061258e57fe5b6020908102919091010152600101612538565b505050919050565b6000805b835181101561266e5760008482815181106125c457fe5b602002602001015190506125e4662386f26fc1000082101561012e611c85565b6125ee8382611b7a565b925060008483815181106125fe57fe5b6020026020010151905061264b600b6000836001600160a01b03166001600160a01b031681526020019081526020016000205488858151811061263d57fe5b602002602001015184611b8c565b6001600160a01b039091166000908152600b6020526040902055506001016125ad565b50612685670de0b6b3a76400008214610134611c85565b6126926009548787611ba9565b6009556040517f0f3631f9dab08169d1db21c6dc5f32536fb2b0a6b9bb5330d71c52132f968be090612022908890889088908890615daa565b611b358282613921565b80156126f5576126f06126e661204f565b4210610193611c85565b61270a565b61270a612700612073565b42106101a9611c85565b6007805460ff19168215151790556040517f9e3a5e37224532dea67b89face185703738a228a6e8a23dee546960180d3be64906124d3908390615a6e565b600061085a8260ff6139c5565b600061085a8260fc6139c5565b610fbe816210905360ea1b6139cc565b6108c261277d6115d0565b156101b5611c85565b61279260095482613a2d565b60095580610fbe57610fbe6138a1565b60008060008060006127b3866129c6565b93509350935093506107a982828686613a3b565b6000606060006127de6127d86108c4565b86613a55565b9550905060606127ec612097565b50905060006127fa836123c1565b8301905073d2ff08ef7ee7c14e00b1b89d44815283667ab57c63b8b0f79988888461282487612144565b61282d886124de565b612835613a96565b61283e8a613a9c565b612846613b29565b6040518963ffffffff1660e01b81526004016128699897969594939291906159e0565b60006040518083038186803b15801561288157600080fd5b505af4158015612895573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526128bd9190810190615797565b94509450505050935093915050565b33301461298a576000306001600160a01b03166000366040516128f092919061594d565b6000604051808303816000865af19150503d806000811461292d576040519150601f19603f3d011682016040523d82523d6000602084013e612932565b606091505b50509050806000811461294157fe5b60046000803e6000516001600160e01b0319166343adbafb60e01b811461296c573d6000803e3d6000fd5b506020600460003e604060205260243d03602460403e601c3d016000f35b6000606061299d8686868663ffffffff16565b8051601f1982018390526343adbafb603f19830152919350915060200260231982016044820181fd5b60008080806129d88560406020611b5c565b93506129e78560606020611b5c565b92506129f6856080603e611b5c565b9150612a058560be603e611b5c565b90509193509193565b600080612a1d8382603c611b5c565b9150612a2c83603c6020611b5c565b9050915091565b600061085a8260fe6139c5565b600080825111801561085a575060ff801682806020019051810190612a65919061587b565b60ff161492915050565b6108c2612a7a6115d0565b6101b6611c85565b60006060612a8e613b4d565b6001600160a01b0316632787a287612aa4610ba5565b85876040518463ffffffff1660e01b8152600401612ac493929190615b9f565b60006040518083038186803b158015612adc57600080fd5b505afa158015612af0573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612b189190810190615797565b91509150935093915050565b611b358282613b71565b612b3a60095482611c15565b6009556040517f5353e2cb47d505ba9b628610daec53fc41f3a4259dab35a757b0f1d5a58bc1c3906124d3908390615a6e565b600080612b7c83826020611b5c565b9150612a2c83602080611b5c565b600080612b9983826040611b5c565b9150612a2c83604080611b5c565b612bbf8284148015612bb857508183145b6067611c85565b505050565b6000612bd04284613c2c565b905061085a82821115610146611c85565b6000806000612bee610e05565b915091506000612c008542848661385d565b90506115728582611b7a565b600060606000612c1a613a96565b9050612c29610c208288613c38565b6000612c3c612c366108c4565b87613a55565b965090506060612c4a612097565b5090506000612c58836123c1565b8301905073d2ff08ef7ee7c14e00b1b89d44815283667ab57c63b8e7b848898984612c8287612144565b612c8b886124de565b8a612c958a613a9c565b612c9d613b29565b6040518963ffffffff1660e01b8152600401612cc09897969594939291906159e0565b60006040518083038186803b158015612cd857600080fd5b505af4158015612cec573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612d149190810190615797565b9550955050505050935093915050565b600061085a8260fd6139c5565b600061097f612d4284836040611b5c565b612d4e85604080611b5c565b84613c53565b600080612d5f613a96565b9050612d75612d6d82612755565b610147611c85565b60408501516001600160a01b0316301415612dce57612d9b610c20828760c00151613c38565b600083612da66108c4565b0390506000612db4826123c1565b82019050612dc487878386613cbd565b935050505061097f565b60208501516001600160a01b0316301415612e0c57600084612dee6108c4565b0390506000612dfc826123c1565b82019050612dc487868386613e9c565b612e1885858584614063565b91505061097f565b6000612e2a6112d7565b6001600160a01b031663aaabadc56040518163ffffffff1660e01b815260040160206040518083038186803b158015612e6257600080fd5b505afa158015612e76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b7e91906155ac565b612ea38261428d565b612eac8161428d565b612ebb60095485858585611bc7565b6009556040517fc42eae0298d32208994ed5d58e525fa31c2911e95451d98f8df3355259c4a13d90612ef4908690869086908690615e14565b60405180910390a150505050565b60408051604180825260808201909252606091829190602082018180368337019050509050836020820152826040820152846060820153949350505050565b6000612f4c856142b6565b9050612f62612f5c8783876142d2565b83611c85565b612f71428410156101b8611c85565b5050506001600160a01b039092166000908152600660205260409020805460010190555050565b60006060612fb0610c20612faa613a96565b87613c38565b6000612fbb84614381565b9050612fd66000826003811115612fce57fe5b1460ce611c85565b6060612fe0612097565b509050612fec85614397565b9250612ffa83518251611b28565b606061300582612144565b905061301184826143ad565b600061301b613b29565b6001600160a01b03166390043a58613032856124de565b876040518363ffffffff1660e01b81526004016130509291906159bb565b60206040518083038186803b15801561306857600080fd5b505afa15801561307c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130a09190615461565b90506130ad818651614416565b95506130b98583614430565b60006130c96001606f1b88611c60565b90506130d58a826126cb565b6130de86614499565b955080866000815181106130ee57fe5b6020026020010181815250506131026138a1565b5050505050935093915050565b620f424090565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b61314d60095482611c23565b6009556040517ff8f9c11ff5f69da8478cee58f9c7465663d787d1a0175fc6a416c772f7a8c64f906124d3908390615a6e565b61318c60095482611c07565b6009556040517f5a9e84f78f7957cb4ed7478eb0fcad35ee4ecbe2e0f298420b28a3955392573f906124d3908390615a6e565b60008080806131d085606080611b5c565b93506131df8560206040611b5c565b925060306131f08660006010611b5c565b901b9150603061320286601080611b5c565b901b90509193509193565b6001600160a01b0381166000908152600b602052604081205460095461085a919061323790613905565b612d31565b600080603061325c84613250576010613253565b60005b87906010611b5c565b901b90508061326f57600091505061097f565b600061327d86606080611b5c565b9050600061328e8760206040611b5c565b90506000818714156132d1576132ca6020678ac7230489e800006132c3896132b75760e06132ba565b60c05b8c906020611b5c565b9190614524565b905061335f565b604051633d3632df60e21b815273a46630db2d331223a505c746b58dc320fec7f03a9063f4d8cb7c9061330c9087908b908b90600401615de6565b60206040518083038186803b15801561332457600080fd5b505af4158015613338573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061335c9190615461565b90505b61336a81848861456a565b98975050505050505050565b6001600160a01b03166000908152600b602052604090205490565b6000806133a18360806005611b5c565b600a0a670de0b6b3a7640000029392505050565b600061097f838361458a565b60007f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f7f25ada9802841eb75331acc6ccadcefb33085ea1e963ac44db82452f836afa70f7fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc661342e6145b8565b30604051602001613443959493929190615b73565b60405160208183030381529060405280519060200120905090565b60006134698561320d565b9050613479811515610135611c85565b60006134908561348b61187489613376565b6145bc565b905061349e818386866145c8565b6001600160a01b0387166000818152600c6020526040908190209290925590517fcad1fdf49cd36960e377075cfe18dcc3aa113e526fbe184544cca2e7115c54f3906134ef90889088908890615dfe565b60405180910390a2505050505050565b600080856001600160a01b03166309b2760f866040518263ffffffff1660e01b815260040161352e9190615ce6565b602060405180830381600087803b15801561354857600080fd5b505af115801561355c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135809190615461565b604051633354e3e960e11b81529091506001600160a01b038716906366a9c7d2906135b390849088908890600401615aed565b600060405180830381600087803b1580156135cd57600080fd5b505af11580156135e1573d6000803e3d6000fd5b509298975050505050505050565b6135fe61010083106064611c85565b61362760018210158015613620575061361c60ff8461010003611c31565b8211155b6064611c85565b612bbf83821c156101b4611c85565b600061097f6136ba836001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561367757600080fd5b505afa15801561368b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906136af919061587b565b60129060ff16611c60565b849060806005611c3d565b6002815110156136d457610fbe565b6000816000815181106136e357fe5b602002602001015190506000600190505b8251811015612bbf57600083828151811061370b57fe5b60200260200101519050613734816001600160a01b0316846001600160a01b0316106065611c85565b91506001016136f4565b815160001990810160209384019081528251909101919092019081529091565b600061376d8484111583611c85565b5050900390565b600073ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1ba1b6137936112a6565b6001600160a01b0316141580156137ae57506137ae836147c1565b156137d6576137bb6112a6565b6001600160a01b0316336001600160a01b031614905061085a565b6137de612e20565b6001600160a01b0316639be2a8848484306040518463ffffffff1660e01b815260040161380d93929190615a9a565b60206040518083038186803b15801561382557600080fd5b505afa158015613839573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117ce9190615445565b6000828411158061386c575081155b1561387957506000611b0d565b600061388586846148d4565b9050838503611b086138978383614416565b6301e133806148ec565b6138ad600a544261490c565b600a55565b60008282026138d68415806138cf5750838583816138cc57fe5b04145b6003611c85565b6001670de0b6b3a76400006001830304018115150291505092915050565b8015610fbe57610fbe61246c611652565b600080600061391384612b6d565b91509150611b0d828261491c565b61392d60008383612bbf565b6139476139428261393c6108c4565b90611b7a565b614954565b6001600160a01b03821660009081526020819052604090205461396a9082611b7a565b6001600160a01b0383166000818152602081905260408082209390935591519091907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef906139b9908590615a91565b60405180910390a35050565b1c60011690565b62461bcd60e51b600090815260206004526007602452600a808404818106603090810160081b958390069590950190829004918206850160101b01602363ffffff0060e086901c160160181b0190930160c81b60445260e882901c90606490fd5b600061097f838360fe611c76565b600080613a48848461491c565b90506107a9868683613c53565b60006060613a8083600081518110613a6957fe5b602002602001015185611c6090919063ffffffff16565b8351600019016020909401938452949293505050565b60095490565b606081516001600160401b0381118015613ab557600080fd5b50604051908082528060200260200182016040528015613adf578160200160208202803683370190505b50905060005b82518110156109c757613b0a838281518110613afd57fe5b6020026020010151614959565b828281518110613b1657fe5b6020908102919091010152600101613ae5565b7f0000000000000000000000002df7261e96a2064813d829765954f3c897756ff190565b7f000000000000000000000000affeaccdd75bb73827d7f3b16db1ea60aa7dce8f90565b613b886001600160a01b038316151561019b611c85565b613b9482600083612bbf565b6001600160a01b038216600090815260208190526040902054613bba90826101b261375e565b6001600160a01b038316600090815260208190526040902055613be861394282613be26108c4565b90614974565b60006001600160a01b0316826001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516139b99190615a91565b80820390821002900390565b6000613c4383612d24565b158061097f575061097f82610b83565b6000670de0b6b3a764000082101580613c6b57508284145b15613c7757508161097f565b81613c8357508261097f565b82841115613ca4576000613c998385870361458a565b8503915061097f9050565b6000613cb28386860361458a565b8501915061097f9050565b6000613cd3613ccb83612748565b610166611c85565b600080613cec8760200151613ce786613905565b614982565b915091506000613cfb856127a2565b9050613d0787836133b5565b965060008089516001811115613d1957fe5b1415613dc857613d2d8960600151846133b5565b60608a0152613d3a613b29565b6001600160a01b031663afc4d0db89868c606001518b876040518663ffffffff1660e01b8152600401613d71959493929190615e2f565b60206040518083038186803b158015613d8957600080fd5b505afa158015613d9d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613dc19190615461565b9050613e5a565b613dd0613b29565b6001600160a01b0316637f1ae8a989868c606001518b876040518663ffffffff1660e01b8152600401613e07959493929190615e2f565b60206040518083038186803b158015613e1f57600080fd5b505afa158015613e33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613e579190615461565b90505b613e6789888360016149b1565b600089516001811115613e7657fe5b1415613e87579350611b0d92505050565b613e918184614bb1565b945050505050611b0d565b6000613eaa613ccb83612748565b600080613ebe8760400151613ce786613905565b915091506000613ecd856127a2565b9050613ed987836133b5565b965060008089516001811115613eeb57fe5b1415613f8757613ef9613b29565b6001600160a01b0316630ccd894189868c606001518b876040518663ffffffff1660e01b8152600401613f30959493929190615e2f565b60206040518083038186803b158015613f4857600080fd5b505afa158015613f5c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f809190615461565b905061402c565b613f958960600151846133b5565b60608a0152613fa2613b29565b6001600160a01b031663ef2aca7689868c606001518b876040518663ffffffff1660e01b8152600401613fd9959493929190615e2f565b60206040518083038186803b158015613ff157600080fd5b505afa158015614005573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140299190615461565b90505b61403989888360006149b1565b60008951600181111561404857fe5b141561405857613e9181846145bc565b9350611b0d92505050565b600061406d614e7d565b6140778684614bbd565b9050600061408c614087856127a2565b614c35565b905061409c8683604001516133b5565b95506140ac8583606001516133b5565b9450600080885160018111156140be57fe5b1415614186576140d6886060015184604001516133b5565b606089018190526000906140ea908461458a565b90506140f4613b29565b8451602086015160405163063c5da760e11b81526001600160a01b039390931692630c78bb4e9261412e928d928d91908890600401615e2f565b60206040518083038186803b15801561414657600080fd5b505afa15801561415a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061417e9190615461565b915050614245565b614198886060015184606001516133b5565b606089015260006141a7613b29565b8451602086015160608c015160405162d5905160e81b81526001600160a01b03949094169363d5905100936141e5938e9391928e9290600401615e2f565b60206040518083038186803b1580156141fd57600080fd5b505afa158015614211573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142359190615461565b90506142418184614c47565b9150505b6142528884898985614c9e565b60008851600181111561426157fe5b141561427f576142758184606001516145bc565b9350505050611b0d565b614275818460400151614bb1565b6142a064e8d4a5100082101560cb611c85565b610fbe670d2f13f7789f000082111560ca611c85565b60006142c06133c1565b82604051602001611265929190615979565b60006142e482516041146101b9611c85565b60208281015160408085015160608601518251600080825295019283905292939092811a9160019061431d908990859088908890615bdf565b6020604051602081039080840390855afa15801561433f573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061336a5750876001600160a01b0316816001600160a01b0316149450505050509392505050565b60008180602001905181019061085a9190615667565b60608180602001905181019061097f9190615682565b815181516143bc908290611b28565b60005b81811015611602576143f78482815181106143d657fe5b60200260200101518483815181106143ea57fe5b602002602001015161458a565b84828151811061440357fe5b60209081029190910101526001016143bf565b600082820261097f8415806138cf5750838583816138cc57fe5b8151815161443f908290611b28565b60005b818110156116025761447a84828151811061445957fe5b602002602001015184838151811061446d57fe5b6020026020010151614c47565b84828151811061448657fe5b6020908102919091010152600101614442565b606081516001016001600160401b03811180156144b557600080fd5b506040519080825280602002602001820160405280156144df578160200160208202803683370190505b50905060005b82518110156109c7578281815181106144fa57fe5b602002602001015182826001018151811061451157fe5b60209081029190910101526001016144e5565b600061454160028410158015613620575060ff8411156064611c85565b6000196001841b01614557818611156064611c85565b6115726145648685614416565b826148ec565b6000611b0d83858461457e5761458a614582565b6138b25b63ffffffff16565b60008282026145a48415806138cf5750838583816138cc57fe5b670de0b6b3a7640000815b04949350505050565b4690565b600061097f8383614df7565b60006145fd8315806145f5575067016345785d8a000084101580156145f55750670de0b6b3a76400008411155b610163611c85565b614614678ac7230489e80000831115610163611c85565b61462b8215806145f5575083831015610163611c85565b60006146428560206040611ba1858b606080611c3d565b9050614663603084811c906010908190611ba19086908a901c600084611c3d565b9050600073a46630db2d331223a505c746b58dc320fec7f03a63f4d8cb7c868860016040518463ffffffff1660e01b81526004016146a393929190615de6565b60206040518083038186803b1580156146bb57600080fd5b505af41580156146cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906146f39190615461565b9050600073a46630db2d331223a505c746b58dc320fec7f03a63f4d8cb7c868960006040518463ffffffff1660e01b815260040161473393929190615de6565b60206040518083038186803b15801561474b57600080fd5b505af415801561475f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906147839190615461565b905061336a61479c826020678ac7230489e80000614e37565b60e06020611ba16147b68783678ac7230489e80000614e37565b889060c06020611c3d565b60006147d363819c70f360e01b611230565b8214806147ee57506147eb635b160f8360e11b611230565b82145b80614807575061480463de3d2b2d60e01b611230565b82145b80614820575061481d633806be4b60e21b611230565b82145b8061483957506148366381788e2b60e01b611230565b82145b80614852575061484f630793b27760e31b611230565b82145b8061486b5750614868637b749c4560e01b611230565b82145b8061488457506148816306946dbf60e31b611230565b82145b8061489d575061489a6397bb15c960e01b611230565b82145b806148b657506148b3632a9a032360e01b611230565b82145b8061085a57506148cc63f885a4bb60e01b611230565b909114919050565b600061097f6148e38484614416565b6148ec84614c35565b60006148fb8215156004611c85565b81838161490457fe5b049392505050565b600061097f8383603c6020611c3d565b60008142106149345750670de0b6b3a764000061085a565b8242116149435750600061085a565b828203428490036115728183614df7565b600255565b6001600160a01b03166000908152600c602052604090205490565b600061097f8383600161375e565b600080600061499085613376565b905061499c8185612d31565b92506149a781613391565b9150509250929050565b60008082156149fe576000865160018111156149c957fe5b146149e45760608601516149de908690611b7a565b846149f4565b6149ee8585611b7a565b86606001515b9092509050614a3e565b600086516001811115614a0d57fe5b14614a2657614a1c8585611c60565b8660600151614a38565b6060860151614a36908690611c60565b845b90925090505b606080614a49612097565b915091506060614a58836124de565b9050614a6c82614a6785612144565b6143ad565b606083516001600160401b0381118015614a8557600080fd5b50604051908082528060200260200182016040528015614aaf578160200160208202803683370190505b509050600087614ac3578a60400151614ac9565b8a602001515b905060005b8551811015614b2a57816001600160a01b0316868281518110614aed57fe5b60200260200101516001600160a01b03161415614b225786838281518110614b1157fe5b602002602001018181525050614b2a565b600101614ace565b5073d2ff08ef7ee7c14e00b1b89d44815283667ab57c6328e379f588614b4f88613a9c565b8786888e6040518763ffffffff1660e01b8152600401614b7496959493929190615d1a565b60006040518083038186803b158015614b8c57600080fd5b505af4158015614ba0573d6000803e3d6000fd5b505050505050505050505050505050565b600061097f8383614c47565b614bc5614e7d565b6000614bd48460200151613376565b90506000614be58560400151613376565b90506000614bf285613905565b9050614bfe8382612d31565b8452614c0a8282612d31565b6020850152614c1883613391565b6040850152614c2682613391565b60608501525091949350505050565b670de0b6b3a764000081810391100290565b6000614c568215156004611c85565b670de0b6b3a76400008302614c88841580614c815750670de0b6b3a7640000858381614c7e57fe5b04145b6005611c85565b6001836001830304018115150291505092915050565b6000614cab61128f612317565b90506000808088516001811115614cbe57fe5b14614cce57838860600151614cd5565b8760600151845b9150915073d2ff08ef7ee7c14e00b1b89d44815283667ab57c63874b47826000614d028b60200151614959565b86614d0d8b88611b7a565b8c516040516001600160e01b031960e088901b168152614d34959493929190600401615cb8565b60006040518083038186803b158015614d4c57600080fd5b505af4158015614d60573d6000803e3d6000fd5b5050505073d2ff08ef7ee7c14e00b1b89d44815283667ab57c63874b47826001614d8d8b60400151614959565b86614d988a87611c60565b8c602001516040518663ffffffff1660e01b8152600401614dbd959493929190615cb8565b60006040518083038186803b158015614dd557600080fd5b505af4158015614de9573d6000803e3d6000fd5b505050505050505050505050565b6000614e068215156004611c85565b670de0b6b3a76400008302614e2e841580614c815750670de0b6b3a7640000858381614c7e57fe5b8281816145af57fe5b6000614e5460028410158015613620575060ff8411156064611c85565b614e62828511156064611c85565b6000196001841b01611572614e778683614416565b846148ec565b6040518060800160405280600081526020016000815260200160008152602001600081525090565b803561085a81615f01565b600082601f830112614ec0578081fd5b8135614ed3614ece82615ea0565b615e7a565b818152915060208083019084810181840286018201871015614ef457600080fd5b60005b84811015614f1c578135614f0a81615f01565b84529282019290820190600101614ef7565b505050505092915050565b600082601f830112614f37578081fd5b8151614f45614ece82615ea0565b818152915060208083019084810181840286018201871015614f6657600080fd5b60005b84811015614f1c578151614f7c81615f01565b84529282019290820190600101614f69565b600082601f830112614f9e578081fd5b8135614fac614ece82615ea0565b818152915060208083019084810181840286018201871015614fcd57600080fd5b60005b84811015614f1c57813584529282019290820190600101614fd0565b600082601f830112614ffc578081fd5b815161500a614ece82615ea0565b81815291506020808301908481018184028601820187101561502b57600080fd5b60005b84811015614f1c5781518452928201929082019060010161502e565b600082601f83011261505a578081fd5b81356001600160401b0381111561506f578182fd5b615082601f8201601f1916602001615e7a565b915080825283602082850101111561509957600080fd5b8060208401602084013760009082016020015292915050565b80516004811061085a57600080fd5b80356002811061085a57600080fd5b60006101208083850312156150e3578182fd5b6150ec81615e7a565b9150506150f983836150c1565b81526151088360208401614ea5565b602082015261511a8360408401614ea5565b6040820152606082013560608201526080820135608082015260a082013560a082015261514a8360c08401614ea5565b60c082015261515c8360e08401614ea5565b60e0820152610100808301356001600160401b0381111561517c57600080fd5b6151888582860161504a565b82840152505092915050565b6000602082840312156151a5578081fd5b813561097f81615f01565b600080604083850312156151c2578081fd5b82356151cd81615f01565b915060208301356151dd81615f01565b809150509250929050565b6000806000606084860312156151fc578081fd5b833561520781615f01565b9250602084013561521781615f01565b929592945050506040919091013590565b600080600080600080600060e0888a031215615242578485fd5b873561524d81615f01565b9650602088013561525d81615f01565b95506040880135945060608801359350608088013561527b81615f24565b9699959850939692959460a0840135945060c09093013592915050565b600080604083850312156152aa578182fd5b82356152b581615f01565b946020939093013593505050565b600080604083850312156152d5578182fd5b82516001600160401b03808211156152eb578384fd5b6152f786838701614f27565b9350602085015191508082111561530c578283fd5b506149a785828601614fec565b6000806000806080858703121561532e578182fd5b84356001600160401b0380821115615344578384fd5b61535088838901614eb0565b95506020870135915080821115615365578384fd5b61537188838901614f8e565b94506040870135915080821115615386578384fd5b61539288838901614f8e565b935060608701359150808211156153a7578283fd5b506153b487828801614f8e565b91505092959194509250565b6000806000606084860312156153d4578081fd5b83516001600160401b03808211156153ea578283fd5b6153f687838801614f27565b9450602086015191508082111561540b578283fd5b5061541886828701614fec565b925050604084015190509250925092565b60006020828403121561543a578081fd5b813561097f81615f16565b600060208284031215615456578081fd5b815161097f81615f16565b600060208284031215615472578081fd5b5051919050565b600080600080600080600060e0888a031215615493578081fd5b8735965060208801356154a581615f01565b955060408801356154b581615f01565b945060608801356001600160401b03808211156154d0578283fd5b6154dc8b838c01614f8e565b955060808a0135945060a08a0135935060c08a01359150808211156154ff578283fd5b5061550c8a828b0161504a565b91505092959891949750929550565b60008060006060848603121561552f578081fd5b8351925060208401516001600160401b038082111561554c578283fd5b61555887838801614f27565b9350604086015191508082111561556d578283fd5b5061557a86828701614fec565b9150509250925092565b600060208284031215615595578081fd5b81356001600160e01b03198116811461097f578182fd5b6000602082840312156155bd578081fd5b815161097f81615f01565b600080600080600060a086880312156155df578283fd5b85356155ea81615f01565b945060208601356155fa81615f01565b93506040860135925060608601359150608086013561561881615f01565b809150509295509295909350565b60008060006060848603121561563a578081fd5b833561564581615f01565b925060208401359150604084013561565c81615f01565b809150509250925092565b600060208284031215615678578081fd5b61097f83836150b2565b60008060408385031215615694578182fd5b61569e84846150b2565b915060208301516001600160401b038111156156b8578182fd5b6149a785828601614fec565b600080600080608085870312156156d9578182fd5b84356001600160401b03808211156156ef578384fd5b6156fb888389016150d0565b95506020870135915080821115615710578384fd5b5061571d87828801614f8e565b949794965050505060408301359260600135919050565b600080600060608486031215615748578081fd5b83356001600160401b0381111561575d578182fd5b615769868287016150d0565b9660208601359650604090950135949350505050565b600060208284031215615790578081fd5b5035919050565b600080604083850312156157a9578182fd5b8251915060208301516001600160401b038111156156b8578182fd5b600080600080608085870312156157da578182fd5b843593506020850135925060408501356001600160401b03808211156157fe578384fd5b61539288838901614eb0565b6000806000806080858703121561581f578182fd5b845193506020850151925060408501519150606085015161583f81615f01565b939692955090935050565b6000806000806080858703121561585f578182fd5b5050823594602084013594506040840135936060013592509050565b60006020828403121561588c578081fd5b815161097f81615f24565b6000815180845260208085019450808401835b838110156158c6578151875295820195908201906001016158aa565b509495945050505050565b6000815180845260208085019450808401835b838110156158c65781516001600160a01b0316875295820195908201906001016158e4565b60008151808452615921816020860160208601615ecb565b601f01601f19169290920160200192915050565b9182526001600160e01b031916602082015260240190565b6000828483379101908152919050565b6000825161596f818460208701615ecb565b9190910192915050565b61190160f01b81526002810192909252602282015260420190565b6001600160a01b0391909116815260200190565b60006020825261097f6020830184615897565b6000604082526159ce6040830185615897565b82810360208401526115728185615897565b60006101008083526159f48184018c615897565b90508281036020840152615a08818b615909565b90508860408401528281036060840152615a228189615897565b90508281036080840152615a368188615897565b90508560a084015282810360c0840152615a508186615897565b91505060018060a01b03831660e08301529998505050505050505050565b901515815260200190565b92151583526020830191909152604082015260600190565b90815260200190565b9283526001600160a01b03918216602084015216604082015260600190565b9586526001600160a01b0394851660208701529290931660408501526060840152608083019190915260a082015260c00190565b60006060820185835260206060818501528186518084526080860191508288019350845b81811015615b3557615b238551615ebf565b83529383019391830191600101615b11565b505084810360408601528551808252908201925081860190845b818110156135e157615b618351615ebf565b85529383019391830191600101615b4f565b9485526020850193909352604084019190915260608301526001600160a01b0316608082015260a00190565b600084825260606020830152615bb86060830185615909565b9050826040830152949350505050565b9182526001600160a01b0316602082015260400190565b93845260ff9290921660208401526040830152606082015260800190565b600061010060018060a01b03808c1684528a6020850152896040850152816060850152615c2c8285018a6158d1565b91508382036080850152615c408289615897565b96811660a08501529490941660c08301525060e001525095945050505050565b600060018060a01b03808a16835288602084015287604084015260e06060840152615c8e60e08401886158d1565b8381036080850152615ca08188615897565b9590911660a0840152505060c0015295945050505050565b60a08101615cc587615ef7565b95815260208101949094526040840192909252606083015260809091015290565b60208101615cf383615ef7565b91905290565b60ff91909116815260200190565b60006020825261097f6020830184615909565b600087825260c06020830152615d3360c0830188615897565b8281036040840152615d458188615897565b90508281036060840152615d598187615897565b90508281036080840152615d6d8186615897565b91505082151560a0830152979650505050505050565b600083825260406020830152611b0d6040830184615897565b918252602082015260400190565b600085825284602083015260806040830152615dc96080830185615897565b8281036060840152615ddb8185615897565b979650505050505050565b92835260208301919091521515604082015260600190565b9283526020830191909152604082015260600190565b93845260208401929092526040830152606082015260800190565b948552602085019390935260408401919091526060830152608082015260a00190565b958652602086019490945260408501929092526060840152608083015260a082015260c00190565b6040518181016001600160401b0381118282101715615e9857600080fd5b604052919050565b60006001600160401b03821115615eb5578081fd5b5060209081020190565b6001600160a01b031690565b60005b83811015615ee6578181015183820152602001615ece565b838111156116025750506000910152565b60038110610fbe57fe5b6001600160a01b0381168114610fbe57600080fd5b8015158114610fbe57600080fd5b60ff81168114610fbe57600080fdfea2646970667358221220eb092cf9f65dee0dfa42c4a8ec1f4cdac85f291e94d29e3ad31819a189a35cb664736f6c63430007010033

    Block Age Transaction Gas Used Reward
    view all blocks ##produced##

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

    Validator Index Block Age Amount
    View All Withdrawals

    Transaction Hash Block Age Value Eth2 PubKey Valid
    View All Deposits
    Loading...
    Loading
    Loading...
    Loading
    [ 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.