POL Price: $0.382266 (+1.58%)
Gas: 36 GWei
 

Overview

POL Balance

Polygon PoS Chain LogoPolygon PoS Chain LogoPolygon PoS Chain Logo0 POL

POL Value

$0.00

Sponsored

Transaction Hash
Method
Block
From
To
0x60806040308588982022-07-18 11:27:34785 days ago1658143654IN
 Create: MasterPriceOracle
0 POL0.0327532438.99437601

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

Contract Source Code Verified (Exact Match)

Contract Name:
MasterPriceOracle

Compiler Version
v0.8.10+commit.fc410830

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, None license
File 1 of 7 : MasterPriceOracle.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity >=0.8.0;

import "openzeppelin-contracts-upgradeable/contracts/proxy/utils/Initializable.sol";

import "../external/compound/IPriceOracle.sol";
import "../external/compound/ICToken.sol";
import "../external/compound/ICErc20.sol";

import "./BasePriceOracle.sol";

/**
 * @title MasterPriceOracle
 * @notice Use a combination of price oracles.
 * @dev Implements `PriceOracle`.
 * @author David Lucid <[email protected]> (https://github.com/davidlucid)
 */
contract MasterPriceOracle is Initializable, IPriceOracle, BasePriceOracle {
  /**
   * @dev Maps underlying token addresses to `PriceOracle` contracts (can be `BasePriceOracle` contracts too).
   */
  mapping(address => IPriceOracle) public oracles;

  /**
   * @dev Default/fallback `PriceOracle`.
   */
  IPriceOracle public defaultOracle;

  /**
   * @dev The administrator of this `MasterPriceOracle`.
   */
  address public admin;

  /**
   * @dev Controls if `admin` can overwrite existing assignments of oracles to underlying tokens.
   */
  bool internal noAdminOverwrite;

  /**
   * @dev The Wrapped native asset address.
   */
  address public wtoken;

  /**
   * @dev Returns a boolean indicating if `admin` can overwrite existing assignments of oracles to underlying tokens.
   */
  function canAdminOverwrite() external view returns (bool) {
    return !noAdminOverwrite;
  }

  /**
   * @dev Event emitted when `admin` is changed.
   */
  event NewAdmin(address oldAdmin, address newAdmin);

  /**
   * @dev Event emitted when the default oracle is changed.
   */
  event NewDefaultOracle(address oldOracle, address newOracle);

  /**
   * @dev Event emitted when an underlying token's oracle is changed.
   */
  event NewOracle(address underlying, address oldOracle, address newOracle);

  /**
   * @dev  Initialize state variables.
   * @param underlyings The underlying ERC20 token addresses to link to `_oracles`.
   * @param _oracles The `PriceOracle` contracts to be assigned to `underlyings`.
   * @param _defaultOracle The default `PriceOracle` contract to use.
   * @param _admin The admin who can assign oracles to underlying tokens.
   * @param _canAdminOverwrite Controls if `admin` can overwrite existing assignments of oracles to underlying tokens.
   * @param _wtoken The Wrapped native asset address
   */
  function initialize(
    address[] memory underlyings,
    IPriceOracle[] memory _oracles,
    IPriceOracle _defaultOracle,
    address _admin,
    bool _canAdminOverwrite,
    address _wtoken
  ) external initializer {
    // Input validation
    require(underlyings.length == _oracles.length, "Lengths of both arrays must be equal.");

    // Initialize state variables
    for (uint256 i = 0; i < underlyings.length; i++) {
      address underlying = underlyings[i];
      IPriceOracle newOracle = _oracles[i];
      oracles[underlying] = newOracle;
      emit NewOracle(underlying, address(0), address(newOracle));
    }

    defaultOracle = _defaultOracle;
    admin = _admin;
    noAdminOverwrite = !_canAdminOverwrite;
    wtoken = _wtoken;
  }

  /**
   * @dev Sets `_oracles` for `underlyings`.
   */
  function add(address[] calldata underlyings, IPriceOracle[] calldata _oracles) external onlyAdmin {
    // Input validation
    require(
      underlyings.length > 0 && underlyings.length == _oracles.length,
      "Lengths of both arrays must be equal and greater than 0."
    );

    // Assign oracles to underlying tokens
    for (uint256 i = 0; i < underlyings.length; i++) {
      address underlying = underlyings[i];
      address oldOracle = address(oracles[underlying]);
      if (noAdminOverwrite)
        require(
          oldOracle == address(0),
          "Admin cannot overwrite existing assignments of oracles to underlying tokens."
        );
      IPriceOracle newOracle = _oracles[i];
      oracles[underlying] = newOracle;
      emit NewOracle(underlying, oldOracle, address(newOracle));
    }
  }

  /**
   * @dev Changes the default price oracle
   */
  function setDefaultOracle(IPriceOracle newOracle) external onlyAdmin {
    IPriceOracle oldOracle = defaultOracle;
    defaultOracle = newOracle;
    emit NewDefaultOracle(address(oldOracle), address(newOracle));
  }

  /**
   * @dev Changes the admin and emits an event.
   */
  function changeAdmin(address newAdmin) external onlyAdmin {
    address oldAdmin = admin;
    admin = newAdmin;
    emit NewAdmin(oldAdmin, newAdmin);
  }

  /**
   * @dev Modifier that checks if `msg.sender == admin`.
   */
  modifier onlyAdmin() {
    require(msg.sender == admin, "Sender is not the admin.");
    _;
  }

  /**
   * @notice Returns the price in ETH of the token underlying `cToken`.
   * @dev Implements the `PriceOracle` interface for Fuse pools (and Compound v2).
   * @return Price in ETH of the token underlying `cToken`, scaled by `10 ** (36 - underlyingDecimals)`.
   */
  function getUnderlyingPrice(ICToken cToken) external view override returns (uint256) {
    // Get underlying ERC20 token address
    address underlying = address(ICErc20(address(cToken)).underlying());

    // Return 1e18 for WETH
    if (underlying == wtoken) return 1e18;

    // Get underlying price from assigned oracle
    IPriceOracle oracle = oracles[underlying];
    if (address(oracle) != address(0)) return oracle.getUnderlyingPrice(cToken);
    if (address(defaultOracle) != address(0)) return defaultOracle.getUnderlyingPrice(cToken);
    revert("Price oracle not found for this underlying token address.");
  }

  /**
   * @dev Attempts to return the price in ETH of `underlying` (implements `BasePriceOracle`).
   */
  function price(address underlying) external view override returns (uint256) {
    // Return 1e18 for WETH
    if (underlying == wtoken) return 1e18;

    // Get underlying price from assigned oracle
    IPriceOracle oracle = oracles[underlying];
    if (address(oracle) != address(0)) return BasePriceOracle(address(oracle)).price(underlying);
    if (address(defaultOracle) != address(0)) return BasePriceOracle(address(defaultOracle)).price(underlying);
    revert("Price oracle not found for this underlying token address.");
  }
}

File 2 of 7 : ICErc20.sol
// SPDX-License-Identifier: BSD-3-Clause
pragma solidity >=0.8.0;

import "./ICToken.sol";

/**
 * @title Compound's CErc20 Contract
 * @notice CTokens which wrap an EIP-20 underlying
 * @author Compound
 */
interface ICErc20 is ICToken {
  function underlying() external view returns (address);

  function liquidateBorrow(
    address borrower,
    uint256 repayAmount,
    ICToken cTokenCollateral
  ) external returns (uint256);
}

File 3 of 7 : ICToken.sol
// SPDX-License-Identifier: BSD-3-Clause
pragma solidity >=0.8.0;

/**
 * @title Compound's CToken Contract
 * @notice Abstract base for CTokens
 * @author Compound
 */
interface ICToken {
  function admin() external view returns (address);

  function adminHasRights() external view returns (bool);

  function fuseAdminHasRights() external view returns (bool);

  function symbol() external view returns (string memory);

  function comptroller() external view returns (address);

  function adminFeeMantissa() external view returns (uint256);

  function fuseFeeMantissa() external view returns (uint256);

  function reserveFactorMantissa() external view returns (uint256);

  function totalReserves() external view returns (uint256);

  function totalAdminFees() external view returns (uint256);

  function totalFuseFees() external view returns (uint256);

  function isCToken() external view returns (bool);

  function isCEther() external view returns (bool);

  function balanceOf(address owner) external view returns (uint256);

  function balanceOfUnderlying(address owner) external returns (uint256);

  function borrowRatePerBlock() external view returns (uint256);

  function supplyRatePerBlock() external view returns (uint256);

  function totalBorrowsCurrent() external returns (uint256);

  function totalBorrows() external view returns (uint256);

  function totalSupply() external view returns (uint256);

  function borrowBalanceStored(address account) external view returns (uint256);

  function borrowBalanceCurrent(address account) external returns (uint256);

  function exchangeRateCurrent() external returns (uint256);

  function exchangeRateStored() external view returns (uint256);

  function exchangeRateHypothetical() external view returns (uint256);

  function accrueInterest() external returns (uint256);

  function getCash() external view returns (uint256);

  function mint(uint256 mintAmount) external returns (uint256);

  function redeem(uint256 redeemTokens) external returns (uint256);

  function redeemUnderlying(uint256 redeemAmount) external returns (uint256);

  function borrow(uint256 borrowAmount) external returns (uint256);

  function repayBorrow(uint256 repayAmount) external returns (uint256);

  function protocolSeizeShareMantissa() external view returns (uint256);

  function feeSeizeShareMantissa() external view returns (uint256);

  function _setReserveFactor(uint256 newReserveFactorMantissa) external returns (uint256);

  function _setAdminFee(uint256 newAdminFeeMantissa) external returns (uint256);

  function supplyRatePerBlockAfterDeposit(uint256 mintAmount) external view returns (uint256);

  function supplyRatePerBlockAfterWithdraw(uint256 withdrawAmount) external view returns (uint256);
}

File 4 of 7 : IPriceOracle.sol
// SPDX-License-Identifier: BSD-3-Clause
pragma solidity >=0.8.0;

import "./ICToken.sol";

interface IPriceOracle {
  /**
   * @notice Get the underlying price of a cToken asset
   * @param cToken The cToken to get the underlying price of
   * @return The underlying asset price mantissa (scaled by 1e18).
   *  Zero means the price is unavailable.
   */
  function getUnderlyingPrice(ICToken cToken) external view returns (uint256);
}

File 5 of 7 : BasePriceOracle.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity >=0.8.0;

import "../external/compound/IPriceOracle.sol";

/**
 * @title BasePriceOracle
 * @notice Returns prices of underlying tokens directly without the caller having to specify a cToken address.
 * @dev Implements the `PriceOracle` interface.
 * @author David Lucid <[email protected]> (https://github.com/davidlucid)
 */
interface BasePriceOracle is IPriceOracle {
  /**
   * @notice Get the price of an underlying asset.
   * @param underlying The underlying asset to get the price of.
   * @return The underlying asset price in ETH as a mantissa (scaled by 1e18).
   * Zero means the price is unavailable.
   */
  function price(address underlying) external view returns (uint256);
}

File 6 of 7 : Initializable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (proxy/utils/Initializable.sol)

pragma solidity ^0.8.2;

import "../../utils/AddressUpgradeable.sol";

/**
 * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
 * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
 * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
 * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
 *
 * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
 * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
 * case an upgrade adds a module that needs to be initialized.
 *
 * For example:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * contract MyToken is ERC20Upgradeable {
 *     function initialize() initializer public {
 *         __ERC20_init("MyToken", "MTK");
 *     }
 * }
 * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {
 *     function initializeV2() reinitializer(2) public {
 *         __ERC20Permit_init("MyToken");
 *     }
 * }
 * ```
 *
 * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
 * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
 *
 * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
 * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
 *
 * [CAUTION]
 * ====
 * Avoid leaving a contract uninitialized.
 *
 * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
 * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke
 * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * /// @custom:oz-upgrades-unsafe-allow constructor
 * constructor() {
 *     _disableInitializers();
 * }
 * ```
 * ====
 */
abstract contract Initializable {
    /**
     * @dev Indicates that the contract has been initialized.
     * @custom:oz-retyped-from bool
     */
    uint8 private _initialized;

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

    /**
     * @dev Triggered when the contract has been initialized or reinitialized.
     */
    event Initialized(uint8 version);

    /**
     * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,
     * `onlyInitializing` functions can be used to initialize parent contracts.
     *
     * Similar to `reinitializer(1)`, except that functions marked with `initializer` can be nested in the context of a
     * constructor.
     *
     * Emits an {Initialized} event.
     */
    modifier initializer() {
        bool isTopLevelCall = !_initializing;
        require(
            (isTopLevelCall && _initialized < 1) || (!AddressUpgradeable.isContract(address(this)) && _initialized == 1),
            "Initializable: contract is already initialized"
        );
        _initialized = 1;
        if (isTopLevelCall) {
            _initializing = true;
        }
        _;
        if (isTopLevelCall) {
            _initializing = false;
            emit Initialized(1);
        }
    }

    /**
     * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the
     * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be
     * used to initialize parent contracts.
     *
     * A reinitializer may be used after the original initialization step. This is essential to configure modules that
     * are added through upgrades and that require initialization.
     *
     * When `version` is 1, this modifier is similar to `initializer`, except that functions marked with `reinitializer`
     * cannot be nested. If one is invoked in the context of another, execution will revert.
     *
     * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in
     * a contract, executing them in the right order is up to the developer or operator.
     *
     * WARNING: setting the version to 255 will prevent any future reinitialization.
     *
     * Emits an {Initialized} event.
     */
    modifier reinitializer(uint8 version) {
        require(!_initializing && _initialized < version, "Initializable: contract is already initialized");
        _initialized = version;
        _initializing = true;
        _;
        _initializing = false;
        emit Initialized(version);
    }

    /**
     * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
     * {initializer} and {reinitializer} modifiers, directly or indirectly.
     */
    modifier onlyInitializing() {
        require(_initializing, "Initializable: contract is not initializing");
        _;
    }

    /**
     * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.
     * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized
     * to any version. It is recommended to use this to lock implementation contracts that are designed to be called
     * through proxies.
     *
     * Emits an {Initialized} event the first time it is successfully executed.
     */
    function _disableInitializers() internal virtual {
        require(!_initializing, "Initializable: contract is initializing");
        if (_initialized < type(uint8).max) {
            _initialized = type(uint8).max;
            emit Initialized(type(uint8).max);
        }
    }

    /**
     * @dev Internal function that returns the initialized version. Returns `_initialized`
     */
    function _getInitializedVersion() internal view returns (uint8) {
        return _initialized;
    }

    /**
     * @dev Internal function that returns the initialized version. Returns `_initializing`
     */
    function _isInitializing() internal view returns (bool) {
        return _initializing;
    }
}

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

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // Look for revert reason and bubble it up if present
        if (returndata.length > 0) {
            // The easiest way to bubble the revert reason is using memory via assembly
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}

Settings
{
  "remappings": [
    "openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/"
  ],
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "metadata": {
    "useLiteralContent": true,
    "bytecodeHash": "none"
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint8","name":"version","type":"uint8"}],"name":"Initialized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldAdmin","type":"address"},{"indexed":false,"internalType":"address","name":"newAdmin","type":"address"}],"name":"NewAdmin","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"oldOracle","type":"address"},{"indexed":false,"internalType":"address","name":"newOracle","type":"address"}],"name":"NewDefaultOracle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"underlying","type":"address"},{"indexed":false,"internalType":"address","name":"oldOracle","type":"address"},{"indexed":false,"internalType":"address","name":"newOracle","type":"address"}],"name":"NewOracle","type":"event"},{"inputs":[{"internalType":"address[]","name":"underlyings","type":"address[]"},{"internalType":"contract IPriceOracle[]","name":"_oracles","type":"address[]"}],"name":"add","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"canAdminOverwrite","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newAdmin","type":"address"}],"name":"changeAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"defaultOracle","outputs":[{"internalType":"contract IPriceOracle","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract ICToken","name":"cToken","type":"address"}],"name":"getUnderlyingPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"underlyings","type":"address[]"},{"internalType":"contract IPriceOracle[]","name":"_oracles","type":"address[]"},{"internalType":"contract IPriceOracle","name":"_defaultOracle","type":"address"},{"internalType":"address","name":"_admin","type":"address"},{"internalType":"bool","name":"_canAdminOverwrite","type":"bool"},{"internalType":"address","name":"_wtoken","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"oracles","outputs":[{"internalType":"contract IPriceOracle","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"underlying","type":"address"}],"name":"price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IPriceOracle","name":"newOracle","type":"address"}],"name":"setDefaultOracle","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"wtoken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b50610e3c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100a95760003560e01c80639c9192c6116100715780639c9192c614610137578063addd50991461014a578063aea9107814610173578063c44014d214610194578063f851a440146101a7578063fc57d4df146101ba57600080fd5b8063656b0fd1146100ae57806380dce169146100d1578063882b92a7146100fc5780638f283970146101115780639c0591c814610124575b600080fd5b600354600160a01b900460ff161560405190151581526020015b60405180910390f35b6002546100e4906001600160a01b031681565b6040516001600160a01b0390911681526020016100c8565b61010f61010a366004610bab565b6101cd565b005b61010f61011f366004610cae565b610458565b6004546100e4906001600160a01b031681565b61010f610145366004610d17565b6104e4565b6100e4610158366004610cae565b6001602052600090815260409020546001600160a01b031681565b610186610181366004610cae565b61073f565b6040519081526020016100c8565b61010f6101a2366004610cae565b6108ab565b6003546100e4906001600160a01b031681565b6101866101c8366004610cae565b61092f565b600054610100900460ff16158080156101ed5750600054600160ff909116105b806102075750303b158015610207575060005460ff166001145b61026f5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610292576000805461ff0019166101001790555b85518751146102f15760405162461bcd60e51b815260206004820152602560248201527f4c656e67746873206f6620626f746820617272617973206d757374206265206560448201526438bab0b61760d91b6064820152608401610266565b60005b87518110156103b957600088828151811061031157610311610d83565b60200260200101519050600088838151811061032f5761032f610d83565b6020908102919091018101516001600160a01b03848116600081815260018552604080822080546001600160a01b03191694861694851790558051928352948201529283015291507f10e7c87bebf274db4de1b5f9fc731d6f83096e550bd871b681314578404d31269060600160405180910390a1505080806103b190610d99565b9150506102f4565b50600280546001600160a01b038088166001600160a01b03199283161790925560038054600160a01b8715026001600160a81b0319909116888516171790556004805492851692909116919091179055801561044f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6003546001600160a01b031633146104825760405162461bcd60e51b815260040161026690610dc2565b600380546001600160a01b038381166001600160a01b031983168117909355604080519190921680825260208201939093527ff9ffabca9c8276e99321725bcb43fb076a6c66a54b7f21c4e8146d8519b417dc91015b60405180910390a15050565b6003546001600160a01b0316331461050e5760405162461bcd60e51b815260040161026690610dc2565b821580159061051c57508281145b61058e5760405162461bcd60e51b815260206004820152603860248201527f4c656e67746873206f6620626f746820617272617973206d757374206265206560448201527f7175616c20616e642067726561746572207468616e20302e00000000000000006064820152608401610266565b60005b838110156107385760008585838181106105ad576105ad610d83565b90506020020160208101906105c29190610cae565b6001600160a01b038181166000908152600160205260409020546003549293501690600160a01b900460ff1615610685576001600160a01b038116156106855760405162461bcd60e51b815260206004820152604c60248201527f41646d696e2063616e6e6f74206f7665727772697465206578697374696e672060448201527f61737369676e6d656e7473206f66206f7261636c657320746f20756e6465726c60648201526b3cb4b733903a37b5b2b7399760a11b608482015260a401610266565b600085858581811061069957610699610d83565b90506020020160208101906106ae9190610cae565b6001600160a01b0384811660008181526001602090815260409182902080546001600160a01b0319168686169081179091558251938452938716908301528101919091529091507f10e7c87bebf274db4de1b5f9fc731d6f83096e550bd871b681314578404d31269060600160405180910390a1505050808061073090610d99565b915050610591565b5050505050565b6004546000906001600160a01b03838116911614156107675750670de0b6b3a7640000919050565b6001600160a01b038083166000908152600160205260409020541680156107fa576040516315d5220f60e31b81526001600160a01b03848116600483015282169063aea91078906024015b602060405180830381865afa1580156107cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107f39190610df9565b9392505050565b6002546001600160a01b03161561083d576002546040516315d5220f60e31b81526001600160a01b0385811660048301529091169063aea91078906024016107b2565b60405162461bcd60e51b815260206004820152603960248201527f5072696365206f7261636c65206e6f7420666f756e6420666f7220746869732060448201527f756e6465726c79696e6720746f6b656e20616464726573732e000000000000006064820152608401610266565b6003546001600160a01b031633146108d55760405162461bcd60e51b815260040161026690610dc2565b600280546001600160a01b038381166001600160a01b031983168117909355604080519190921680825260208201939093527f0df2d61fdd201e9633368dca495e2c469e36c48039263448dd8a2a954c19ef1a91016104d8565b600080826001600160a01b0316636f307dc36040518163ffffffff1660e01b8152600401602060405180830381865afa158015610970573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109949190610e12565b6004549091506001600160a01b03808316911614156109bd5750670de0b6b3a764000092915050565b6001600160a01b03808216600090815260016020526040902054168015610a515760405163fc57d4df60e01b81526001600160a01b03858116600483015282169063fc57d4df906024015b602060405180830381865afa158015610a25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a499190610df9565b949350505050565b6002546001600160a01b03161561083d5760025460405163fc57d4df60e01b81526001600160a01b0386811660048301529091169063fc57d4df90602401610a08565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715610ad357610ad3610a94565b604052919050565b600067ffffffffffffffff821115610af557610af5610a94565b5060051b60200190565b6001600160a01b0381168114610b1457600080fd5b50565b8035610b2281610aff565b919050565b600082601f830112610b3857600080fd5b81356020610b4d610b4883610adb565b610aaa565b82815260059290921b84018101918181019086841115610b6c57600080fd5b8286015b84811015610b90578035610b8381610aff565b8352918301918301610b70565b509695505050505050565b80358015158114610b2257600080fd5b60008060008060008060c08789031215610bc457600080fd5b863567ffffffffffffffff80821115610bdc57600080fd5b818901915089601f830112610bf057600080fd5b81356020610c00610b4883610adb565b82815260059290921b8401810191818101908d841115610c1f57600080fd5b948201945b83861015610c46578535610c3781610aff565b82529482019490820190610c24565b9a50508a013592505080821115610c5c57600080fd5b50610c6989828a01610b27565b955050610c7860408801610b17565b9350610c8660608801610b17565b9250610c9460808801610b9b565b9150610ca260a08801610b17565b90509295509295509295565b600060208284031215610cc057600080fd5b81356107f381610aff565b60008083601f840112610cdd57600080fd5b50813567ffffffffffffffff811115610cf557600080fd5b6020830191508360208260051b8501011115610d1057600080fd5b9250929050565b60008060008060408587031215610d2d57600080fd5b843567ffffffffffffffff80821115610d4557600080fd5b610d5188838901610ccb565b90965094506020870135915080821115610d6a57600080fd5b50610d7787828801610ccb565b95989497509550505050565b634e487b7160e01b600052603260045260246000fd5b6000600019821415610dbb57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208082526018908201527f53656e646572206973206e6f74207468652061646d696e2e0000000000000000604082015260600190565b600060208284031215610e0b57600080fd5b5051919050565b600060208284031215610e2457600080fd5b81516107f381610aff56fea164736f6c634300080a000a

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100a95760003560e01c80639c9192c6116100715780639c9192c614610137578063addd50991461014a578063aea9107814610173578063c44014d214610194578063f851a440146101a7578063fc57d4df146101ba57600080fd5b8063656b0fd1146100ae57806380dce169146100d1578063882b92a7146100fc5780638f283970146101115780639c0591c814610124575b600080fd5b600354600160a01b900460ff161560405190151581526020015b60405180910390f35b6002546100e4906001600160a01b031681565b6040516001600160a01b0390911681526020016100c8565b61010f61010a366004610bab565b6101cd565b005b61010f61011f366004610cae565b610458565b6004546100e4906001600160a01b031681565b61010f610145366004610d17565b6104e4565b6100e4610158366004610cae565b6001602052600090815260409020546001600160a01b031681565b610186610181366004610cae565b61073f565b6040519081526020016100c8565b61010f6101a2366004610cae565b6108ab565b6003546100e4906001600160a01b031681565b6101866101c8366004610cae565b61092f565b600054610100900460ff16158080156101ed5750600054600160ff909116105b806102075750303b158015610207575060005460ff166001145b61026f5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff191660011790558015610292576000805461ff0019166101001790555b85518751146102f15760405162461bcd60e51b815260206004820152602560248201527f4c656e67746873206f6620626f746820617272617973206d757374206265206560448201526438bab0b61760d91b6064820152608401610266565b60005b87518110156103b957600088828151811061031157610311610d83565b60200260200101519050600088838151811061032f5761032f610d83565b6020908102919091018101516001600160a01b03848116600081815260018552604080822080546001600160a01b03191694861694851790558051928352948201529283015291507f10e7c87bebf274db4de1b5f9fc731d6f83096e550bd871b681314578404d31269060600160405180910390a1505080806103b190610d99565b9150506102f4565b50600280546001600160a01b038088166001600160a01b03199283161790925560038054600160a01b8715026001600160a81b0319909116888516171790556004805492851692909116919091179055801561044f576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050505050565b6003546001600160a01b031633146104825760405162461bcd60e51b815260040161026690610dc2565b600380546001600160a01b038381166001600160a01b031983168117909355604080519190921680825260208201939093527ff9ffabca9c8276e99321725bcb43fb076a6c66a54b7f21c4e8146d8519b417dc91015b60405180910390a15050565b6003546001600160a01b0316331461050e5760405162461bcd60e51b815260040161026690610dc2565b821580159061051c57508281145b61058e5760405162461bcd60e51b815260206004820152603860248201527f4c656e67746873206f6620626f746820617272617973206d757374206265206560448201527f7175616c20616e642067726561746572207468616e20302e00000000000000006064820152608401610266565b60005b838110156107385760008585838181106105ad576105ad610d83565b90506020020160208101906105c29190610cae565b6001600160a01b038181166000908152600160205260409020546003549293501690600160a01b900460ff1615610685576001600160a01b038116156106855760405162461bcd60e51b815260206004820152604c60248201527f41646d696e2063616e6e6f74206f7665727772697465206578697374696e672060448201527f61737369676e6d656e7473206f66206f7261636c657320746f20756e6465726c60648201526b3cb4b733903a37b5b2b7399760a11b608482015260a401610266565b600085858581811061069957610699610d83565b90506020020160208101906106ae9190610cae565b6001600160a01b0384811660008181526001602090815260409182902080546001600160a01b0319168686169081179091558251938452938716908301528101919091529091507f10e7c87bebf274db4de1b5f9fc731d6f83096e550bd871b681314578404d31269060600160405180910390a1505050808061073090610d99565b915050610591565b5050505050565b6004546000906001600160a01b03838116911614156107675750670de0b6b3a7640000919050565b6001600160a01b038083166000908152600160205260409020541680156107fa576040516315d5220f60e31b81526001600160a01b03848116600483015282169063aea91078906024015b602060405180830381865afa1580156107cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107f39190610df9565b9392505050565b6002546001600160a01b03161561083d576002546040516315d5220f60e31b81526001600160a01b0385811660048301529091169063aea91078906024016107b2565b60405162461bcd60e51b815260206004820152603960248201527f5072696365206f7261636c65206e6f7420666f756e6420666f7220746869732060448201527f756e6465726c79696e6720746f6b656e20616464726573732e000000000000006064820152608401610266565b6003546001600160a01b031633146108d55760405162461bcd60e51b815260040161026690610dc2565b600280546001600160a01b038381166001600160a01b031983168117909355604080519190921680825260208201939093527f0df2d61fdd201e9633368dca495e2c469e36c48039263448dd8a2a954c19ef1a91016104d8565b600080826001600160a01b0316636f307dc36040518163ffffffff1660e01b8152600401602060405180830381865afa158015610970573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109949190610e12565b6004549091506001600160a01b03808316911614156109bd5750670de0b6b3a764000092915050565b6001600160a01b03808216600090815260016020526040902054168015610a515760405163fc57d4df60e01b81526001600160a01b03858116600483015282169063fc57d4df906024015b602060405180830381865afa158015610a25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a499190610df9565b949350505050565b6002546001600160a01b03161561083d5760025460405163fc57d4df60e01b81526001600160a01b0386811660048301529091169063fc57d4df90602401610a08565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715610ad357610ad3610a94565b604052919050565b600067ffffffffffffffff821115610af557610af5610a94565b5060051b60200190565b6001600160a01b0381168114610b1457600080fd5b50565b8035610b2281610aff565b919050565b600082601f830112610b3857600080fd5b81356020610b4d610b4883610adb565b610aaa565b82815260059290921b84018101918181019086841115610b6c57600080fd5b8286015b84811015610b90578035610b8381610aff565b8352918301918301610b70565b509695505050505050565b80358015158114610b2257600080fd5b60008060008060008060c08789031215610bc457600080fd5b863567ffffffffffffffff80821115610bdc57600080fd5b818901915089601f830112610bf057600080fd5b81356020610c00610b4883610adb565b82815260059290921b8401810191818101908d841115610c1f57600080fd5b948201945b83861015610c46578535610c3781610aff565b82529482019490820190610c24565b9a50508a013592505080821115610c5c57600080fd5b50610c6989828a01610b27565b955050610c7860408801610b17565b9350610c8660608801610b17565b9250610c9460808801610b9b565b9150610ca260a08801610b17565b90509295509295509295565b600060208284031215610cc057600080fd5b81356107f381610aff565b60008083601f840112610cdd57600080fd5b50813567ffffffffffffffff811115610cf557600080fd5b6020830191508360208260051b8501011115610d1057600080fd5b9250929050565b60008060008060408587031215610d2d57600080fd5b843567ffffffffffffffff80821115610d4557600080fd5b610d5188838901610ccb565b90965094506020870135915080821115610d6a57600080fd5b50610d7787828801610ccb565b95989497509550505050565b634e487b7160e01b600052603260045260246000fd5b6000600019821415610dbb57634e487b7160e01b600052601160045260246000fd5b5060010190565b60208082526018908201527f53656e646572206973206e6f74207468652061646d696e2e0000000000000000604082015260600190565b600060208284031215610e0b57600080fd5b5051919050565b600060208284031215610e2457600080fd5b81516107f381610aff56fea164736f6c634300080a000a

Deployed Bytecode Sourcemap

512:5671:4:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1309:93;1381:16;;-1:-1:-1;;;1381:16:4;;;;1380:17;1309:93;;179:14:7;;172:22;154:41;;142:2;127:18;1309:93:4;;;;;;;;820:33;;;;;-1:-1:-1;;;;;820:33:4;;;;;;-1:-1:-1;;;;;390:32:7;;;372:51;;360:2;345:18;820:33:4;206:223:7;2352:751:4;;;;;;:::i;:::-;;:::i;:::-;;4318:154;;;;;;:::i;:::-;;:::i;1153:21::-;;;;;-1:-1:-1;;;;;1153:21:4;;;3164:815;;;;;;:::i;:::-;;:::i;714:47::-;;;;;;:::i;:::-;;;;;;;;;;;;-1:-1:-1;;;;;714:47:4;;;5649:532;;;;;;:::i;:::-;;:::i;:::-;;;5573:25:7;;;5561:2;5546:18;5649:532:4;5427:177:7;4038:216:4;;;;;;:::i;:::-;;:::i;927:20::-;;;;;-1:-1:-1;;;;;927:20:4;;;4916:623;;;;;;:::i;:::-;;:::i;2352:751::-;3268:19:5;3291:13;;;;;;3290:14;;3336:34;;;;-1:-1:-1;3354:12:5;;3369:1;3354:12;;;;:16;3336:34;3335:108;;;-1:-1:-1;3415:4:5;1476:19:6;:23;;;3376:66:5;;-1:-1:-1;3425:12:5;;;;;:17;3376:66;3314:201;;;;-1:-1:-1;;;3314:201:5;;6350:2:7;3314:201:5;;;6332:21:7;6389:2;6369:18;;;6362:30;6428:34;6408:18;;;6401:62;-1:-1:-1;;;6479:18:7;;;6472:44;6533:19;;3314:201:5;;;;;;;;;3525:12;:16;;-1:-1:-1;;3525:16:5;3540:1;3525:16;;;3551:65;;;;3585:13;:20;;-1:-1:-1;;3585:20:5;;;;;3551:65;2630:8:4::1;:15;2608:11;:18;:37;2600:87;;;::::0;-1:-1:-1;;;2600:87:4;;6765:2:7;2600:87:4::1;::::0;::::1;6747:21:7::0;6804:2;6784:18;;;6777:30;6843:34;6823:18;;;6816:62;-1:-1:-1;;;6894:18:7;;;6887:35;6939:19;;2600:87:4::1;6563:401:7::0;2600:87:4::1;2733:9;2728:248;2752:11;:18;2748:1;:22;2728:248;;;2785:18;2806:11;2818:1;2806:14;;;;;;;;:::i;:::-;;;;;;;2785:35;;2828:22;2853:8;2862:1;2853:11;;;;;;;;:::i;:::-;;::::0;;::::1;::::0;;;;;;;-1:-1:-1;;;;;2872:19:4;;::::1;;::::0;;;:7:::1;:19:::0;;;;;;:31;;-1:-1:-1;;;;;;2872:31:4::1;::::0;;::::1;::::0;;::::1;::::0;;2916:53;;7341:34:7;;;7391:18;;;7384:43;7443:18;;;7436:43;2853:11:4;-1:-1:-1;2916:53:4::1;::::0;7291:2:7;7276:18;2916:53:4::1;;;;;;;2777:199;;2772:3;;;;;:::i;:::-;;;;2728:248;;;-1:-1:-1::0;2982:13:4::1;:30:::0;;-1:-1:-1;;;;;2982:30:4;;::::1;-1:-1:-1::0;;;;;;2982:30:4;;::::1;;::::0;;;3018:5:::1;:14:::0;;-1:-1:-1;;;3057:19:4;::::1;3038:38;-1:-1:-1::0;;;;;;3038:38:4;;;3018:14;;::::1;3038:38:::0;::::1;::::0;;3082:6:::1;:16:::0;;;;::::1;::::0;;;::::1;::::0;;;::::1;::::0;;3636:99:5;;;;3686:5;3670:21;;-1:-1:-1;;3670:21:5;;;3710:14;;-1:-1:-1;7879:36:7;;3710:14:5;;7867:2:7;7852:18;3710:14:5;;;;;;;3636:99;3258:483;2352:751:4;;;;;;:::o;4318:154::-;4594:5;;-1:-1:-1;;;;;4594:5:4;4580:10;:19;4572:56;;;;-1:-1:-1;;;4572:56:4;;;;;;;:::i;:::-;4401:5:::1;::::0;;-1:-1:-1;;;;;4412:16:4;;::::1;-1:-1:-1::0;;;;;;4412:16:4;::::1;::::0;::::1;::::0;;;4439:28:::1;::::0;;4401:5;;;::::1;8491:34:7::0;;;8556:2;8541:18;;8534:43;;;;4439:28:4::1;::::0;8426:18:7;4439:28:4::1;;;;;;;;4376:96;4318:154:::0;:::o;3164:815::-;4594:5;;-1:-1:-1;;;;;4594:5:4;4580:10;:19;4572:56;;;;-1:-1:-1;;;4572:56:4;;;;;;;:::i;:::-;3307:22;;;;;:63:::1;;-1:-1:-1::0;3333:37:4;;::::1;3307:63;3292:150;;;::::0;-1:-1:-1;;;3292:150:4;;8790:2:7;3292:150:4::1;::::0;::::1;8772:21:7::0;8829:2;8809:18;;;8802:30;8868:34;8848:18;;;8841:62;8939:26;8919:18;;;8912:54;8983:19;;3292:150:4::1;8588:420:7::0;3292:150:4::1;3497:9;3492:483;3512:22:::0;;::::1;3492:483;;;3549:18;3570:11;;3582:1;3570:14;;;;;;;:::i;:::-;;;;;;;;;;;;;;:::i;:::-;-1:-1:-1::0;;;;;3620:19:4;;::::1;3592:17;3620:19:::0;;;:7:::1;:19;::::0;;;;;3652:16:::1;::::0;3620:19;;-1:-1:-1;3620:19:4::1;::::0;-1:-1:-1;;;3652:16:4;::::1;;;3648:172;;;-1:-1:-1::0;;;;;3697:23:4;::::1;::::0;3678:142:::1;;;::::0;-1:-1:-1;;;3678:142:4;;9215:2:7;3678:142:4::1;::::0;::::1;9197:21:7::0;9254:2;9234:18;;;9227:30;9293:34;9273:18;;;9266:62;9364:34;9344:18;;;9337:62;-1:-1:-1;;;9415:19:7;;;9408:43;9468:19;;3678:142:4::1;9013:480:7::0;3678:142:4::1;3828:22;3853:8;;3862:1;3853:11;;;;;;;:::i;:::-;;;;;;;;;;;;;;:::i;:::-;-1:-1:-1::0;;;;;3872:19:4;;::::1;;::::0;;;:7:::1;:19;::::0;;;;;;;;:31;;-1:-1:-1;;;;;;3872:31:4::1;::::0;;::::1;::::0;;::::1;::::0;;;3916:52;;7341:34:7;;;7411:15;;;7391:18;;;7384:43;7443:18;;7436:43;;;;3872:31:4;;-1:-1:-1;3916:52:4::1;::::0;7291:2:7;7276:18;3916:52:4::1;;;;;;;3541:434;;;3536:3;;;;;:::i;:::-;;;;3492:483;;;;3164:815:::0;;;;:::o;5649:532::-;5777:6;;5716:7;;-1:-1:-1;;;;;5763:20:4;;;5777:6;;5763:20;5759:37;;;-1:-1:-1;5792:4:4;;5649:532;-1:-1:-1;5649:532:4:o;5759:37::-;-1:-1:-1;;;;;5874:19:4;;;5852;5874;;;:7;:19;;;;;;;5903:29;;5899:92;;5941:50;;-1:-1:-1;;;5941:50:4;;-1:-1:-1;;;;;390:32:7;;;5941:50:4;;;372:51:7;5941:38:4;;;;;345:18:7;;5941:50:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;5934:57;5649:532;-1:-1:-1;;;5649:532:4:o;5899:92::-;6009:13;;-1:-1:-1;;;;;6009:13:4;6001:36;5997:106;;6070:13;;6046:57;;-1:-1:-1;;;6046:57:4;;-1:-1:-1;;;;;390:32:7;;;6046:57:4;;;372:51:7;6070:13:4;;;;6046:45;;345:18:7;;6046:57:4;206:223:7;5997:106:4;6109:67;;-1:-1:-1;;;6109:67:4;;9889:2:7;6109:67:4;;;9871:21:7;9928:2;9908:18;;;9901:30;9967:34;9947:18;;;9940:62;10038:27;10018:18;;;10011:55;10083:19;;6109:67:4;9687:421:7;4038:216:4;4594:5;;-1:-1:-1;;;;;4594:5:4;4580:10;:19;4572:56;;;;-1:-1:-1;;;4572:56:4;;;;;;;:::i;:::-;4138:13:::1;::::0;;-1:-1:-1;;;;;4157:25:4;;::::1;-1:-1:-1::0;;;;;;4157:25:4;::::1;::::0;::::1;::::0;;;4193:56:::1;::::0;;4138:13;;;::::1;8491:34:7::0;;;8556:2;8541:18;;8534:43;;;;4193:56:4::1;::::0;8426:18:7;4193:56:4::1;8279:304:7::0;4916:623:4;4992:7;5049:18;5094:6;-1:-1:-1;;;;;5078:35:4;;:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;5169:6;;5049:67;;-1:-1:-1;;;;;;5155:20:4;;;5169:6;;5155:20;5151:37;;;-1:-1:-1;5184:4:4;;4916:623;-1:-1:-1;;4916:623:4:o;5151:37::-;-1:-1:-1;;;;;5266:19:4;;;5244;5266;;;:7;:19;;;;;;;5295:29;;5291:75;;5333:33;;-1:-1:-1;;;5333:33:4;;-1:-1:-1;;;;;390:32:7;;;5333:33:4;;;372:51:7;5333:25:4;;;;;345:18:7;;5333:33:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;5326:40;4916:623;-1:-1:-1;;;;4916:623:4:o;5291:75::-;5384:13;;-1:-1:-1;;;;;5384:13:4;5376:36;5372:89;;5421:13;;:40;;-1:-1:-1;;;5421:40:4;;-1:-1:-1;;;;;390:32:7;;;5421:40:4;;;372:51:7;5421:13:4;;;;:32;;345:18:7;;5421:40:4;206:223:7;434:127;495:10;490:3;486:20;483:1;476:31;526:4;523:1;516:15;550:4;547:1;540:15;566:275;637:2;631:9;702:2;683:13;;-1:-1:-1;;679:27:7;667:40;;737:18;722:34;;758:22;;;719:62;716:88;;;784:18;;:::i;:::-;820:2;813:22;566:275;;-1:-1:-1;566:275:7:o;846:183::-;906:4;939:18;931:6;928:30;925:56;;;961:18;;:::i;:::-;-1:-1:-1;1006:1:7;1002:14;1018:4;998:25;;846:183::o;1034:131::-;-1:-1:-1;;;;;1109:31:7;;1099:42;;1089:70;;1155:1;1152;1145:12;1089:70;1034:131;:::o;1170:134::-;1238:20;;1267:31;1238:20;1267:31;:::i;:::-;1170:134;;;:::o;1309:751::-;1377:5;1430:3;1423:4;1415:6;1411:17;1407:27;1397:55;;1448:1;1445;1438:12;1397:55;1484:6;1471:20;1510:4;1534:60;1550:43;1590:2;1550:43;:::i;:::-;1534:60;:::i;:::-;1628:15;;;1714:1;1710:10;;;;1698:23;;1694:32;;;1659:12;;;;1738:15;;;1735:35;;;1766:1;1763;1756:12;1735:35;1802:2;1794:6;1790:15;1814:217;1830:6;1825:3;1822:15;1814:217;;;1910:3;1897:17;1927:31;1952:5;1927:31;:::i;:::-;1971:18;;2009:12;;;;1847;;1814:217;;;-1:-1:-1;2049:5:7;1309:751;-1:-1:-1;;;;;;1309:751:7:o;2065:160::-;2130:20;;2186:13;;2179:21;2169:32;;2159:60;;2215:1;2212;2205:12;2230:1562;2421:6;2429;2437;2445;2453;2461;2514:3;2502:9;2493:7;2489:23;2485:33;2482:53;;;2531:1;2528;2521:12;2482:53;2571:9;2558:23;2600:18;2641:2;2633:6;2630:14;2627:34;;;2657:1;2654;2647:12;2627:34;2695:6;2684:9;2680:22;2670:32;;2740:7;2733:4;2729:2;2725:13;2721:27;2711:55;;2762:1;2759;2752:12;2711:55;2798:2;2785:16;2820:4;2844:60;2860:43;2900:2;2860:43;:::i;2844:60::-;2938:15;;;3020:1;3016:10;;;;3008:19;;3004:28;;;2969:12;;;;3044:19;;;3041:39;;;3076:1;3073;3066:12;3041:39;3100:11;;;;3120:217;3136:6;3131:3;3128:15;3120:217;;;3216:3;3203:17;3233:31;3258:5;3233:31;:::i;:::-;3277:18;;3153:12;;;;3315;;;;3120:217;;;3356:5;-1:-1:-1;;3399:18:7;;3386:32;;-1:-1:-1;;3430:16:7;;;3427:36;;;3459:1;3456;3449:12;3427:36;;3482:77;3551:7;3540:8;3529:9;3525:24;3482:77;:::i;:::-;3472:87;;;3578:38;3612:2;3601:9;3597:18;3578:38;:::i;:::-;3568:48;;3635:38;3669:2;3658:9;3654:18;3635:38;:::i;:::-;3625:48;;3692:36;3723:3;3712:9;3708:19;3692:36;:::i;:::-;3682:46;;3747:39;3781:3;3770:9;3766:19;3747:39;:::i;:::-;3737:49;;2230:1562;;;;;;;;:::o;3797:247::-;3856:6;3909:2;3897:9;3888:7;3884:23;3880:32;3877:52;;;3925:1;3922;3915:12;3877:52;3964:9;3951:23;3983:31;4008:5;3983:31;:::i;4257:367::-;4320:8;4330:6;4384:3;4377:4;4369:6;4365:17;4361:27;4351:55;;4402:1;4399;4392:12;4351:55;-1:-1:-1;4425:20:7;;4468:18;4457:30;;4454:50;;;4500:1;4497;4490:12;4454:50;4537:4;4529:6;4525:17;4513:29;;4597:3;4590:4;4580:6;4577:1;4573:14;4565:6;4561:27;4557:38;4554:47;4551:67;;;4614:1;4611;4604:12;4551:67;4257:367;;;;;:::o;4629:793::-;4771:6;4779;4787;4795;4848:2;4836:9;4827:7;4823:23;4819:32;4816:52;;;4864:1;4861;4854:12;4816:52;4904:9;4891:23;4933:18;4974:2;4966:6;4963:14;4960:34;;;4990:1;4987;4980:12;4960:34;5029:70;5091:7;5082:6;5071:9;5067:22;5029:70;:::i;:::-;5118:8;;-1:-1:-1;5003:96:7;-1:-1:-1;5206:2:7;5191:18;;5178:32;;-1:-1:-1;5222:16:7;;;5219:36;;;5251:1;5248;5241:12;5219:36;;5290:72;5354:7;5343:8;5332:9;5328:24;5290:72;:::i;:::-;4629:793;;;;-1:-1:-1;5381:8:7;-1:-1:-1;;;;4629:793:7:o;6969:127::-;7030:10;7025:3;7021:20;7018:1;7011:31;7061:4;7058:1;7051:15;7085:4;7082:1;7075:15;7490:232;7529:3;-1:-1:-1;;7550:17:7;;7547:140;;;7609:10;7604:3;7600:20;7597:1;7590:31;7644:4;7641:1;7634:15;7672:4;7669:1;7662:15;7547:140;-1:-1:-1;7714:1:7;7703:13;;7490:232::o;7926:348::-;8128:2;8110:21;;;8167:2;8147:18;;;8140:30;8206:26;8201:2;8186:18;;8179:54;8265:2;8250:18;;7926:348::o;9498:184::-;9568:6;9621:2;9609:9;9600:7;9596:23;9592:32;9589:52;;;9637:1;9634;9627:12;9589:52;-1:-1:-1;9660:16:7;;9498:184;-1:-1:-1;9498:184:7:o;10113:251::-;10183:6;10236:2;10224:9;10215:7;10211:23;10207:32;10204:52;;;10252:1;10249;10242:12;10204:52;10284:9;10278:16;10303:31;10328:5;10303:31;:::i

Swarm Source

none

Block Transaction Gas Used Reward
view all blocks produced

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

Validator Index Block Amount
View All Withdrawals

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