ETH Price: $3,490.70 (-0.83%)
Gas: 8 Gwei

Contract

0x347a58878D04951588741d4d16d54B742c7f60fC
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Value
0x61010060140843202022-01-26 23:56:17876 days ago1643241377IN
 Create: RewardMaster
0 ETH0.24500715150

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
RewardMaster

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 800 runs

Other Settings:
default evmVersion
File 1 of 10 : RewardMaster.sol
// SPDX-License-Identifier: UNLICENSED
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

import "./actions/RewardAdvisersList.sol";
import "./interfaces/IActionMsgReceiver.sol";
import "./interfaces/IErc20Min.sol";
import "./interfaces/IRewardAdviser.sol";
import "./interfaces/IRewardPool.sol";
import "./utils/ImmutableOwnable.sol";
import "./utils/Claimable.sol";
import "./utils/NonReentrant.sol";
import "./utils/Utils.sol";

/***
 * @title RewardMaster
 * @notice It accounts rewards and distributes reward tokens to users.
 * @dev It withdraws the reward token from (or via) the "REWARD_POOL" contract,
 * and keeps tokens, aka "Treasury", on its balance until distribution.
 * It issues to users "shares" in the Treasury, or redeems shares, paying out
 * tokens from the Treasury to users, or on behalf of users, as follows.
 * It receives messages (calls) on "actions" to be rewarded from authorized
 * "ActionOracle" contracts.
 * On every "action" message received, it calls a "RewardAdviser" contract,
 * assigned for that ActionOracle and action type, which advices on how many
 * shares shall be created and to whom, or whose shares must be redeemed, and
 * where reward tokens shall be sent to.
 * The owner may add or remove addresses of ActionOracle`s and RewardAdviser`s.
 */
contract RewardMaster is
    ImmutableOwnable,
    Utils,
    Claimable,
    NonReentrant,
    RewardAdvisersList,
    IActionMsgReceiver
{
    // solhint-disable var-name-mixedcase

    /// @notice Token rewards are given in
    address public immutable REWARD_TOKEN;

    /// @notice RewardPool instance that vests the reward token
    address public immutable REWARD_POOL;

    /// @dev Block the contract deployed in
    uint256 public immutable START_BLOCK;

    // solhint-enable var-name-mixedcase

    /**
     * At any time, the amount of the reward token a user is entitled to is:
     *   tokenAmountEntitled = accumRewardPerShare * user.shares - user.offset
     *
     * This formula works since we update parameters as follows ...
     *
     * - when a new reward token amount added to the Treasury:
     *   accumRewardPerShare += tokenAmountAdded / totalShares
     *
     * - when new shares granted to a user:
     *   user.offset += sharesToCreate * accumRewardPerShare
     *   user.shares += sharesToCreate
     *   totalShares += sharesToCreate
     *
     * - when shares redeemed to a user:
     *   redemptionRate = accumRewardPerShare - user.offset/user.shares
     *   user.offset -= user.offset/user.shares * sharesToRedeem
     *   user.shares -= sharesToRedeem
     *   totalShares -= sharesToRedeem
     *   tokenAmountPayable = redemptionRate * sharesToRedeem
     *
     * (Scaling omitted in formulas above for clarity.)
     */

    /// @dev Block when reward tokens were last time were vested in
    uint32 public lastVestedBlock;
    /// @dev Reward token balance (aka Treasury) after last vesting
    /// (token total supply is supposed to not exceed 2**96)
    uint96 public lastBalance;

    /// @notice Total number of unredeemed shares
    /// (it is supposed to not exceed 2**128)
    uint128 public totalShares;
    /// @dev Min number of unredeemed shares being rewarded
    uint256 private constant MIN_SHARES_REWARDED = 1000;
    /// @dev Min number of blocks between vesting in the Treasury
    uint256 private constant MIN_VESTING_BLOCKS = 300;

    // see comments above for explanation
    uint256 public accumRewardPerShare;
    // `accumRewardPerShare` is scaled (up) with this factor
    uint256 private constant SCALE = 1e9;

    // see comments above for explanation
    struct UserRecord {
        // (limited to 2**96)
        uint96 shares;
        uint160 offset;
    }

    // Mapping from user address to UserRecord data
    mapping(address => UserRecord) public records;

    /// @dev Emitted when new shares granted to a user
    event SharesGranted(address indexed user, uint256 amount);
    /// @dev Emitted when shares of a user redeemed
    event SharesRedeemed(address indexed user, uint256 amount);
    /// @dev Emitted when new reward token amount vested to this contract
    event RewardAdded(uint256 reward);
    /// @dev Emitted when reward token amount paid to/for a user
    event RewardPaid(address indexed user, uint256 reward);
    /// @dev Emitted when the Treasury counts for "extra" reward tokens.
    /// "Extra" tokens are ones sent to this contract directly (rather than
    /// vested via the REWARD_POOL).
    event BalanceAdjusted(uint256 adjustment);

    constructor(
        address _rewardToken,
        address _rewardPool,
        address _owner
    ) ImmutableOwnable(_owner) {
        require(
            _rewardToken != address(0) && _rewardPool != address(0),
            "RM:C1"
        );

        REWARD_TOKEN = _rewardToken;
        REWARD_POOL = _rewardPool;
        START_BLOCK = blockNow();
    }

    /// @notice Returns reward token amount entitled to the given user/account
    // This amount the account would get if shares would be redeemed now
    function entitled(address account) public view returns (uint256 reward) {
        UserRecord memory rec = records[account];
        if (rec.shares == 0) return 0;

        // no reentrancy guard needed for the known contract call
        uint256 releasable = IRewardPool(REWARD_POOL).releasableAmount();
        uint256 _accumRewardPerShare = accumRewardPerShare;
        uint256 _totalShares = uint256(totalShares);
        if (releasable != 0 && _totalShares >= MIN_SHARES_REWARDED) {
            _accumRewardPerShare += (releasable * SCALE) / _totalShares;
        }

        (reward, , ) = _computeRedemption(
            uint256(rec.shares),
            rec,
            _accumRewardPerShare
        );
    }

    function onAction(bytes4 action, bytes memory message) external override {
        IRewardAdviser adviser = _getRewardAdviserOrRevert(msg.sender, action);
        // no reentrancy guard needed for the known contract call
        IRewardAdviser.Advice memory advice = adviser.getRewardAdvice(
            action,
            message
        );
        if (advice.sharesToCreate > 0) {
            _grantShares(advice.createSharesFor, advice.sharesToCreate);
        }
        if (advice.sharesToRedeem > 0) {
            _redeemShares(
                advice.redeemSharesFrom,
                advice.sharesToRedeem,
                advice.sendRewardTo
            );
        }
    }

    function triggerVesting() external {
        _triggerVesting(true, false);
    }

    /* ========== ONLY FOR OWNER FUNCTIONS ========== */

    /**
     * @notice Adds the "RewardAdviser" for given ActionOracle and action type
     * @dev May be only called by the {OWNER}
     * !!!!! Before adding a new "adviser", ensure "shares" it "advices" can not
     * overflow `UserRecord.shares`, `UserRecord.offset` and `totalShares`.
     */
    function addRewardAdviser(
        address oracle,
        bytes4 action,
        address adviser
    ) external onlyOwner {
        _addRewardAdviser(oracle, action, adviser);
    }

    /// @notice Remove "RewardAdviser" for given ActionOracle and action type
    /// @dev May be only called by the {OWNER}
    function removeRewardAdviser(address oracle, bytes4 action)
        external
        onlyOwner
    {
        _removeRewardAdviser(oracle, action);
    }

    /// @notice Withdraws accidentally sent token from this contract
    /// @dev May be only called by the {OWNER}
    function claimErc20(
        address claimedToken,
        address to,
        uint256 amount
    ) external onlyOwner nonReentrant {
        if (claimedToken == address(REWARD_TOKEN)) {
            // Not allowed if unclaimed shares remain
            require(totalShares == 0, "RM: Failed to claim");
        }
        _claimErc20(claimedToken, to, amount);
    }

    /* ========== INTERNAL & PRIVATE FUNCTIONS ========== */

    function _computeRedemption(
        uint256 sharesToRedeem,
        UserRecord memory rec,
        uint256 _accumRewardPerShare
    )
        internal
        pure
        returns (
            uint256 reward,
            uint256 newShares,
            uint256 newOffset
        )
    {
        // `rec.shares` and `sharesToRedeem` are assumed to be non-zero here,
        // and `sharesToRedeem` does not exceed `rec.shares`
        newShares = uint256(rec.shares) - sharesToRedeem;

        uint256 offsetRedeemed = newShares == 0
            ? uint256(rec.offset)
            : (uint256(rec.offset) * sharesToRedeem) / uint256(rec.shares);
        newOffset = uint256(rec.offset) - offsetRedeemed;

        reward = 0;
        if (_accumRewardPerShare != 0) {
            reward = (sharesToRedeem * _accumRewardPerShare) / SCALE;
            // avoid eventual overflow resulted from rounding
            reward -= reward >= offsetRedeemed ? offsetRedeemed : reward;
        }
    }

    function _grantShares(address to, uint256 shares)
        internal
        nonZeroAmount(shares)
        nonZeroAddress(to)
    {
        (uint256 _accumRewardPerShare, , ) = _triggerVesting(true, true);

        UserRecord memory rec = records[to];
        uint256 newOffset = uint256(rec.offset) +
            (shares * _accumRewardPerShare) /
            SCALE;
        uint256 newShares = uint256(rec.shares) + shares;

        records[to] = UserRecord(safe96(newShares), safe160(newOffset));
        totalShares = safe128(uint256(totalShares) + shares);

        emit SharesGranted(to, shares);
    }

    function _redeemShares(
        address from,
        // `shares` assumed to be non-zero
        uint256 shares,
        address to
    ) internal nonZeroAmount(shares) nonZeroAddress(from) nonZeroAddress(to) {
        UserRecord memory rec = records[from];
        require(rec.shares >= shares, "RM: Not enough shares to redeem");

        (
            uint256 _accumRewardPerShare,
            uint256 newBalance,
            uint256 oldBalance
        ) = _triggerVesting(false, true);

        (
            uint256 reward,
            uint256 newShares,
            uint256 newOffset
        ) = _computeRedemption(shares, rec, _accumRewardPerShare);

        records[from] = UserRecord(safe96(newShares), safe160(newOffset));
        totalShares = safe128(uint256(totalShares) - shares);

        uint256 _lastBalance = newBalance - reward;
        if (oldBalance != _lastBalance) {
            lastBalance = safe96(_lastBalance);
        }

        if (reward != 0) {
            // known contract - nether reentrancy guard nor safeTransfer required
            require(
                IErc20Min(REWARD_TOKEN).transfer(to, reward),
                "RM: Internal transfer failed"
            );
            emit RewardPaid(to, reward);
        }

        emit SharesRedeemed(from, shares);
    }

    function _triggerVesting(
        bool isLastBalanceToBeUpdated,
        bool isMinVestingBlocksApplied
    )
        internal
        returns (
            uint256 newAccumRewardPerShare,
            uint256 newBalance,
            uint256 oldBalance
        )
    {
        uint32 _blockNow = safe32BlockNow();
        newAccumRewardPerShare = accumRewardPerShare;
        oldBalance = uint256(lastBalance);
        uint256 _totalShares = totalShares;

        uint32 blocksPast = _blockNow - lastVestedBlock;
        if (
            (blocksPast == 0) ||
            (isMinVestingBlocksApplied && blocksPast < MIN_VESTING_BLOCKS) ||
            _totalShares < MIN_SHARES_REWARDED
        ) {
            // Do not request vesting from the REWARD_POOL
            return (newAccumRewardPerShare, oldBalance, oldBalance);
        }

        // known contracts, no reentrancy guard needed
        uint256 newlyVested = IRewardPool(REWARD_POOL).vestRewards();
        newBalance = IErc20Min(REWARD_TOKEN).balanceOf(address(this));

        uint256 expectedBalance = oldBalance + newlyVested;
        if (newBalance > expectedBalance) {
            // somebody transferred tokens to this contract directly
            uint256 adjustment = newBalance - expectedBalance;
            newlyVested += adjustment;
            emit BalanceAdjusted(adjustment);
        }
        if (newlyVested != 0) {
            newAccumRewardPerShare += (newlyVested * SCALE) / _totalShares;
            accumRewardPerShare = newAccumRewardPerShare;
            emit RewardAdded(newlyVested);
        }
        lastVestedBlock = _blockNow;
        if (isLastBalanceToBeUpdated && (oldBalance != newBalance)) {
            lastBalance = safe96(newBalance);
        }
    }

    /* ========== MODIFIERS ========== */

    modifier nonZeroAmount(uint256 amount) {
        require(amount > 0, "RM: Zero amount provided");
        _;
    }

    modifier nonZeroAddress(address account) {
        require(account != address(0), "RM: Zero address provided");
        _;
    }
}

File 2 of 10 : RewardAdvisersList.sol
// SPDX-License-Identifier: UNLICENSED
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

import "../interfaces/IRewardAdviser.sol";

/**
 * @title ActionControllers
 * @notice It maintains a list of "ActionOracle" and "RewardAdviser" instances.
 * For a tuple of ActionOracle address and action type, an RewardAdviser
 * instance of  may be mapped.
 */
abstract contract RewardAdvisersList {
    /// @dev Emitted when RewardAdviser added, updated, or removed
    event AdviserUpdated(
        address indexed oracle,
        bytes4 indexed action,
        address adviser
    );

    /// @dev mapping from ActionOracle and (type of) action to ActionController
    mapping(address => mapping(bytes4 => address)) public rewardAdvisers;

    function _addRewardAdviser(
        address oracle,
        bytes4 action,
        address adviser
    ) internal {
        require(
            oracle != address(0) &&
                adviser != address(0) &&
                action != bytes4(0),
            "ACM:E1"
        );
        require(rewardAdvisers[oracle][action] == address(0), "ACM:E2");
        rewardAdvisers[oracle][action] = adviser;
        emit AdviserUpdated(oracle, action, adviser);
    }

    function _removeRewardAdviser(address oracle, bytes4 action) internal {
        require(rewardAdvisers[oracle][action] != address(0), "ACM:E3");
        rewardAdvisers[oracle][action] = address(0);
        emit AdviserUpdated(oracle, action, address(0));
    }

    function _getRewardAdviserOrRevert(address oracle, bytes4 action)
        internal
        view
        returns (IRewardAdviser)
    {
        address adviser = rewardAdvisers[oracle][action];
        require(adviser != address(0), "ACM:E4");
        return IRewardAdviser(adviser);
    }
}

File 3 of 10 : IActionMsgReceiver.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface IActionMsgReceiver {
    function onAction(bytes4 action, bytes memory message) external;
}

File 4 of 10 : IErc20Min.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface IErc20Min {
    /// @dev ERC-20 `balanceOf`
    function balanceOf(address account) external view returns (uint256);

    /// @dev ERC-20 `transfer`
    function transfer(address recipient, uint256 amount)
        external
        returns (bool);

    /// @dev ERC-20 `transferFrom`
    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

    /// @dev EIP-2612 `permit`
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;
}

File 5 of 10 : IRewardAdviser.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface IRewardAdviser {
    struct Advice {
        // advice on new "shares" (in the reward pool) to create
        address createSharesFor;
        uint96 sharesToCreate;
        // advice on "shares" to redeem
        address redeemSharesFrom;
        uint96 sharesToRedeem;
        // advice on address the reward against redeemed shares to send to
        address sendRewardTo;
    }

    function getRewardAdvice(bytes4 action, bytes memory message)
        external
        returns (Advice memory);
}

File 6 of 10 : IRewardPool.sol
// SPDX-License-Identifier: BUSL-1.1
// SPDX-FileCopyrightText: Copyright 2021-22 Panther Ventures Limited Gibraltar
pragma solidity ^0.8.0;

interface IRewardPool {
    /// @notice Returns token amount that may be released (vested) now
    function releasableAmount() external view returns (uint256);

    /// @notice Vests releasable token amount to the {recipient}
    /// @dev {recipient} only may call
    function vestRewards() external returns (uint256 amount);

    /// @notice Emitted on vesting to the {recipient}
    event Vested(uint256 amount);

    /// @notice Emitted on parameters initialized.
    event Initialized(uint256 _poolId, address _recipient, uint256 _endTime);
}

File 7 of 10 : ImmutableOwnable.sol
// SPDX-License-Identifier: MIT
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

/// @title Staking
abstract contract ImmutableOwnable {
    /// @notice The owner who has privileged rights
    // solhint-disable-next-line var-name-mixedcase
    address public immutable OWNER;

    /// @dev Throws if called by any account other than the {OWNER}.
    modifier onlyOwner() {
        require(OWNER == msg.sender, "ImmOwn: unauthorized");
        _;
    }

    constructor(address _owner) {
        require(_owner != address(0), "ImmOwn: zero owner address");
        OWNER = _owner;
    }
}

File 8 of 10 : Claimable.sol
// SPDX-License-Identifier: MIT
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

/**
 * @title Claimable
 * @notice It withdraws accidentally sent tokens from this contract.
 */
contract Claimable {
    bytes4 private constant SELECTOR_TRANSFER =
        bytes4(keccak256(bytes("transfer(address,uint256)")));

    /// @dev Withdraws ERC20 tokens from this contract
    /// (take care of reentrancy attack risk mitigation)
    function _claimErc20(
        address token,
        address to,
        uint256 amount
    ) internal {
        // solhint-disable avoid-low-level-calls
        (bool success, bytes memory data) = token.call(
            abi.encodeWithSelector(SELECTOR_TRANSFER, to, amount)
        );
        require(
            success && (data.length == 0 || abi.decode(data, (bool))),
            "claimErc20: TRANSFER_FAILED"
        );
    }
}

File 9 of 10 : NonReentrant.sol
// SPDX-License-Identifier: MIT
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

/**
 * @title NonReentrant
 * @notice It provides reentrancy guard.
 * The code borrowed from openzeppelin-contracts.
 * Unlike original, this version requires neither `constructor` no `init` call.
 */
abstract contract NonReentrant {
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _reentrancyStatus;

    modifier nonReentrant() {
        // Being called right after deployment, when _reentrancyStatus is 0 ,
        // it does not revert (which is expected behaviour)
        require(_reentrancyStatus != _ENTERED, "claimErc20: reentrant call");

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

        _;

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

File 10 of 10 : Utils.sol
// SPDX-License-Identifier: MIT
// solhint-disable-next-line compiler-fixed, compiler-gt-0_8
pragma solidity ^0.8.0;

abstract contract Utils {
    function safe32(uint256 n) internal pure returns (uint32) {
        require(n < 2**32, "UNSAFE32");
        return uint32(n);
    }

    function safe96(uint256 n) internal pure returns (uint96) {
        require(n < 2**96, "UNSAFE96");
        return uint96(n);
    }

    function safe128(uint256 n) internal pure returns (uint128) {
        require(n < 2**128, "UNSAFE128");
        return uint128(n);
    }

    function safe160(uint256 n) internal pure returns (uint160) {
        require(n < 2**160, "UNSAFE160");
        return uint160(n);
    }

    function safe32TimeNow() internal view returns (uint32) {
        return safe32(timeNow());
    }

    function safe32BlockNow() internal view returns (uint32) {
        return safe32(blockNow());
    }

    /// @dev Returns the current block timestamp (added to ease testing)
    function timeNow() internal view virtual returns (uint256) {
        return block.timestamp;
    }

    /// @dev Returns the current block number (added to ease testing)
    function blockNow() internal view virtual returns (uint256) {
        return block.number;
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_rewardToken","type":"address"},{"internalType":"address","name":"_rewardPool","type":"address"},{"internalType":"address","name":"_owner","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oracle","type":"address"},{"indexed":true,"internalType":"bytes4","name":"action","type":"bytes4"},{"indexed":false,"internalType":"address","name":"adviser","type":"address"}],"name":"AdviserUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"adjustment","type":"uint256"}],"name":"BalanceAdjusted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"}],"name":"RewardAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"}],"name":"RewardPaid","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"SharesGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"SharesRedeemed","type":"event"},{"inputs":[],"name":"OWNER","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"REWARD_POOL","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"REWARD_TOKEN","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"START_BLOCK","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"accumRewardPerShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"oracle","type":"address"},{"internalType":"bytes4","name":"action","type":"bytes4"},{"internalType":"address","name":"adviser","type":"address"}],"name":"addRewardAdviser","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"claimedToken","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"claimErc20","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"entitled","outputs":[{"internalType":"uint256","name":"reward","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lastVestedBlock","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"action","type":"bytes4"},{"internalType":"bytes","name":"message","type":"bytes"}],"name":"onAction","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"records","outputs":[{"internalType":"uint96","name":"shares","type":"uint96"},{"internalType":"uint160","name":"offset","type":"uint160"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"oracle","type":"address"},{"internalType":"bytes4","name":"action","type":"bytes4"}],"name":"removeRewardAdviser","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"bytes4","name":"","type":"bytes4"}],"name":"rewardAdvisers","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalShares","outputs":[{"internalType":"uint128","name":"","type":"uint128"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"triggerVesting","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101006040523480156200001257600080fd5b5060405162001e9638038062001e96833981016040819052620000359162000145565b806001600160a01b038116620000925760405162461bcd60e51b815260206004820152601a60248201527f496d6d4f776e3a207a65726f206f776e6572206164647265737300000000000060448201526064015b60405180910390fd5b60601b6001600160601b0319166080526001600160a01b03831615801590620000c357506001600160a01b03821615155b620000f95760405162461bcd60e51b8152602060048201526005602482015264524d3a433160d81b604482015260640162000089565b6001600160601b0319606084811b821660a05283901b1660c0526200011b4390565b60e052506200018e915050565b80516001600160a01b03811681146200014057600080fd5b919050565b6000806000606084860312156200015a578283fd5b620001658462000128565b9250620001756020850162000128565b9150620001856040850162000128565b90509250925092565b60805160601c60a05160601c60c05160601c60e051611c8d62000209600039600061019f0152600081816103290152818161054201526108d5015260008181610302015281816107160152818161097e01526110e501526000818161010a0152818161046b0152818161064c01526107c50152611c8d6000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c8063492bc9bc1161009757806392a70fb01161006657806392a70fb0146102ea57806399248ea7146102fd57806399f91c281461032457806399ff97361461034b57600080fd5b8063492bc9bc146102765780634934da9e1461029b5780636e1ede72146102a45780638f1c56bd146102b757600080fd5b806339b3e826116100d357806339b3e8261461019a5780633a98ef39146101cf57806345d6854214610201578063469e90671461021457600080fd5b8063117803e31461010557806316762b3b146101495780631b865046146101535780632007577e14610166575b600080fd5b61012c7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020015b60405180910390f35b61015161035e565b005b6101516101613660046119a2565b61036f565b61012c610174366004611906565b60016020908152600092835260408084209091529082529020546001600160a01b031681565b6101c17f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610140565b6002546101e990600160801b90046001600160801b031681565b6040516001600160801b039091168152602001610140565b61015161020f366004611906565b610469565b61024f6102223660046118aa565b6004602052600090815260409020546001600160601b03811690600160601b90046001600160a01b031682565b604080516001600160601b0390931683526001600160a01b03909116602083015201610140565b6002546102869063ffffffff1681565b60405163ffffffff9091168152602001610140565b6101c160035481565b6101c16102b23660046118aa565b6104eb565b6002546102d29064010000000090046001600160601b031681565b6040516001600160601b039091168152602001610140565b6101516102f83660046118c6565b61064a565b61012c7f000000000000000000000000000000000000000000000000000000000000000081565b61012c7f000000000000000000000000000000000000000000000000000000000000000081565b61015161035936600461193a565b6107c3565b61036a6001600061083d565b505050565b600061037b3384610b36565b90506000816001600160a01b031663e9cb032485856040518363ffffffff1660e01b81526004016103ad929190611b09565b60a060405180830381600087803b1580156103c757600080fd5b505af11580156103db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ff9190611a42565b60208101519091506001600160601b03161561043057610430816000015182602001516001600160601b0316610bbc565b60608101516001600160601b03161561046357610463816040015182606001516001600160601b03168360800151610e08565b50505050565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031633146104dd5760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064015b60405180910390fd5b6104e78282611244565b5050565b6001600160a01b0380821660009081526004602090815260408083208151808301909252546001600160601b038116808352600160601b90910490941691810191909152909161053e5750600092915050565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316635b9400816040518163ffffffff1660e01b815260040160206040518083038186803b15801561059957600080fd5b505afa1580156105ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105d19190611ad5565b60035460025491925090600160801b90046001600160801b031682158015906105fc57506103e88110155b156106275780610610633b9aca0085611bb5565b61061a9190611b95565b6106249083611b7d565b91505b835161063d906001600160601b03168584611340565b5090979650505050505050565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031633146106b95760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064016104d4565b6002600054141561070c5760405162461bcd60e51b815260206004820152601a60248201527f636c61696d45726332303a207265656e7472616e742063616c6c00000000000060448201526064016104d4565b60026000819055507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316836001600160a01b031614156107ae57600254600160801b90046001600160801b0316156107ae5760405162461bcd60e51b815260206004820152601360248201527f524d3a204661696c656420746f20636c61696d0000000000000000000000000060448201526064016104d4565b6107b9838383611416565b5050600160005550565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031633146108325760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064016104d4565b61036a838383611576565b60008060008061084b6116fc565b6003546002549095506001600160601b0364010000000082041693509091506001600160801b03600160801b8204169060009061088e9063ffffffff1684611beb565b905063ffffffff811615806108b257508680156108b2575061012c8163ffffffff16105b806108be57506103e882105b156108d157858495509550505050610b2f565b60007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316633c43059d6040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561092e57600080fd5b505af1158015610942573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109669190611ad5565b6040516370a0823160e01b81523060048201529091507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a082319060240160206040518083038186803b1580156109c857600080fd5b505afa1580156109dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a009190611ad5565b95506000610a0e8287611b7d565b905080871115610a6d576000610a248289611bd4565b9050610a308184611b7d565b92507f0701991c7670454699af0d89a71c6225608163b182136536a3a34395535b5a4881604051610a6391815260200190565b60405180910390a1505b8115610ad25783610a82633b9aca0084611bb5565b610a8c9190611b95565b610a969089611b7d565b60038190556040518381529098507fde88a922e0d3b88b24e9623efeb464919c6bf9f66857a65e2bfcf2ce87a9433d9060200160405180910390a15b6002805463ffffffff191663ffffffff8716179055898015610af45750868614155b15610b2957610b028761170c565b600260046101000a8154816001600160601b0302191690836001600160601b031602179055505b50505050505b9250925092565b6001600160a01b0380831660009081526001602090815260408083206001600160e01b03198616845290915281205490911680610bb55760405162461bcd60e51b815260206004820152600660248201527f41434d3a4534000000000000000000000000000000000000000000000000000060448201526064016104d4565b9392505050565b8060008111610c0d5760405162461bcd60e51b815260206004820152601860248201527f524d3a205a65726f20616d6f756e742070726f7669646564000000000000000060448201526064016104d4565b826001600160a01b038116610c645760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b6000610c7160018061083d565b50506001600160a01b0380871660009081526004602090815260408083208151808301909252546001600160601b0381168252600160601b90049093169083015291925090633b9aca00610cc58488611bb5565b610ccf9190611b95565b82602001516001600160a01b0316610ce79190611b7d565b905060008683600001516001600160601b0316610d049190611b7d565b90506040518060400160405280610d1a8361170c565b6001600160601b03168152602001610d3184611765565b6001600160a01b03908116909152898116600090815260046020908152604090912083519390910151909116600160601b026001600160601b03909216919091179055600254610d9c90610d979089906001600160801b03600160801b90910416611b7d565b6117cb565b600280546001600160801b03928316600160801b0292169190911790556040516001600160a01b038916907fa9cb08b17f930ad003053de9e6b23478fb011aa5113047ce62b832dcbb6d2e4290610df6908a815260200190565b60405180910390a25050505050505050565b8160008111610e595760405162461bcd60e51b815260206004820152601860248201527f524d3a205a65726f20616d6f756e742070726f7669646564000000000000000060448201526064016104d4565b836001600160a01b038116610eb05760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b826001600160a01b038116610f075760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b6001600160a01b038087166000908152600460209081526040918290208251808401909352546001600160601b038116808452600160601b9091049093169082015290861115610f995760405162461bcd60e51b815260206004820152601f60248201527f524d3a204e6f7420656e6f7567682073686172657320746f2072656465656d0060448201526064016104d4565b6000806000610faa6000600161083d565b9250925092506000806000610fc08c8888611340565b9250925092506040518060400160405280610fda8461170c565b6001600160601b03168152602001610ff183611765565b6001600160a01b039081169091528e8116600090815260046020908152604090912083519390910151909116600160601b026001600160601b0390921691909117905560025461105790610d97908e906001600160801b03600160801b90910416611bd4565b600280546001600160801b03928316600160801b02921691909117905560006110808487611bd4565b90508085146110b9576110928161170c565b600260046101000a8154816001600160601b0302191690836001600160601b031602179055505b83156111f15760405163a9059cbb60e01b81526001600160a01b038d81166004830152602482018690527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb90604401602060405180830381600087803b15801561112957600080fd5b505af115801561113d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111619190611982565b6111ad5760405162461bcd60e51b815260206004820152601c60248201527f524d3a20496e7465726e616c207472616e73666572206661696c65640000000060448201526064016104d4565b8b6001600160a01b03167fe2403640ba68fed3a2f88b7557551d1993f84b99bb10ff833f0cf8db0c5e0486856040516111e891815260200190565b60405180910390a25b8d6001600160a01b03167fc064950777109fc27d3ee46c0e316d1aad25e9b115d36ea363e5623fabf0f4fe8e60405161122c91815260200190565b60405180910390a25050505050505050505050505050565b6001600160a01b0382811660009081526001602090815260408083206001600160e01b031986168452909152902054166112c05760405162461bcd60e51b815260206004820152600660248201527f41434d3a4533000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b03821660008181526001602090815260408083206001600160e01b03198616808552908352818420805473ffffffffffffffffffffffffffffffffffffffff19169055905192835292917fc3b2e3d4ba2ea7ac7abc74ac870cb893deaa227c6c21322632d97e6a2e2bf92d910160405180910390a35050565b60008060008585600001516001600160601b031661135e9190611bd4565b91506000821561139e5785600001516001600160601b03168787602001516001600160a01b031661138f9190611bb5565b6113999190611b95565b6113ad565b85602001516001600160a01b03165b90508086602001516001600160a01b03166113c89190611bd4565b600094509150841561140c57633b9aca006113e38689611bb5565b6113ed9190611b95565b9350808410156113fd57836113ff565b805b6114099085611bd4565b93505b5093509350939050565b604080518082018252601981527f7472616e7366657228616464726573732c75696e74323536290000000000000060209182015281516001600160a01b0385811660248301526044808301869052845180840390910181526064909201845291810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1663a9059cbb60e01b179052915160009283928716916114b79190611aed565b6000604051808303816000865af19150503d80600081146114f4576040519150601f19603f3d011682016040523d82523d6000602084013e6114f9565b606091505b50915091508180156115235750805115806115235750808060200190518101906115239190611982565b61156f5760405162461bcd60e51b815260206004820152601b60248201527f636c61696d45726332303a205452414e534645525f4641494c4544000000000060448201526064016104d4565b5050505050565b6001600160a01b0383161580159061159657506001600160a01b03811615155b80156115ab57506001600160e01b0319821615155b6115f75760405162461bcd60e51b815260206004820152600660248201527f41434d3a4531000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b0383811660009081526001602090815260408083206001600160e01b03198716845290915290205416156116745760405162461bcd60e51b815260206004820152600660248201527f41434d3a4532000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b0383811660008181526001602090815260408083206001600160e01b0319881680855290835292819020805473ffffffffffffffffffffffffffffffffffffffff191695871695861790555193845290927fc3b2e3d4ba2ea7ac7abc74ac870cb893deaa227c6c21322632d97e6a2e2bf92d910160405180910390a3505050565b600061170743611820565b905090565b6000600160601b82106117615760405162461bcd60e51b815260206004820152600860248201527f554e53414645393600000000000000000000000000000000000000000000000060448201526064016104d4565b5090565b60007401000000000000000000000000000000000000000082106117615760405162461bcd60e51b815260206004820152600960248201527f554e53414645313630000000000000000000000000000000000000000000000060448201526064016104d4565b6000600160801b82106117615760405162461bcd60e51b815260206004820152600960248201527f554e53414645313238000000000000000000000000000000000000000000000060448201526064016104d4565b600064010000000082106117615760405162461bcd60e51b815260206004820152600860248201527f554e53414645333200000000000000000000000000000000000000000000000060448201526064016104d4565b80356001600160e01b03198116811461188e57600080fd5b919050565b80516001600160601b038116811461188e57600080fd5b6000602082840312156118bb578081fd5b8135610bb581611c68565b6000806000606084860312156118da578182fd5b83356118e581611c68565b925060208401356118f581611c68565b929592945050506040919091013590565b60008060408385031215611918578182fd5b823561192381611c68565b915061193160208401611876565b90509250929050565b60008060006060848603121561194e578283fd5b833561195981611c68565b925061196760208501611876565b9150604084013561197781611c68565b809150509250925092565b600060208284031215611993578081fd5b81518015158114610bb5578182fd5b600080604083850312156119b4578182fd5b6119bd83611876565b915060208084013567ffffffffffffffff808211156119da578384fd5b818601915086601f8301126119ed578384fd5b8135818111156119ff576119ff611c52565b611a11601f8201601f19168501611b4c565b91508082528784828501011115611a26578485fd5b8084840185840137810190920192909252919491935090915050565b600060a08284031215611a53578081fd5b60405160a0810181811067ffffffffffffffff82111715611a7657611a76611c52565b6040528251611a8481611c68565b8152611a9260208401611893565b60208201526040830151611aa581611c68565b6040820152611ab660608401611893565b60608201526080830151611ac981611c68565b60808201529392505050565b600060208284031215611ae6578081fd5b5051919050565b60008251611aff818460208701611c10565b9190910192915050565b63ffffffff60e01b831681526040602082015260008251806040840152611b37816060850160208701611c10565b601f01601f1916919091016060019392505050565b604051601f8201601f1916810167ffffffffffffffff81118282101715611b7557611b75611c52565b604052919050565b60008219821115611b9057611b90611c3c565b500190565b600082611bb057634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615611bcf57611bcf611c3c565b500290565b600082821015611be657611be6611c3c565b500390565b600063ffffffff83811690831681811015611c0857611c08611c3c565b039392505050565b60005b83811015611c2b578181015183820152602001611c13565b838111156104635750506000910152565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114611c7d57600080fd5b5056fea164736f6c6343000804000a000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa173000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e5000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd77

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106101005760003560e01c8063492bc9bc1161009757806392a70fb01161006657806392a70fb0146102ea57806399248ea7146102fd57806399f91c281461032457806399ff97361461034b57600080fd5b8063492bc9bc146102765780634934da9e1461029b5780636e1ede72146102a45780638f1c56bd146102b757600080fd5b806339b3e826116100d357806339b3e8261461019a5780633a98ef39146101cf57806345d6854214610201578063469e90671461021457600080fd5b8063117803e31461010557806316762b3b146101495780631b865046146101535780632007577e14610166575b600080fd5b61012c7f000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd7781565b6040516001600160a01b0390911681526020015b60405180910390f35b61015161035e565b005b6101516101613660046119a2565b61036f565b61012c610174366004611906565b60016020908152600092835260408084209091529082529020546001600160a01b031681565b6101c17f0000000000000000000000000000000000000000000000000000000000d6e8e081565b604051908152602001610140565b6002546101e990600160801b90046001600160801b031681565b6040516001600160801b039091168152602001610140565b61015161020f366004611906565b610469565b61024f6102223660046118aa565b6004602052600090815260409020546001600160601b03811690600160601b90046001600160a01b031682565b604080516001600160601b0390931683526001600160a01b03909116602083015201610140565b6002546102869063ffffffff1681565b60405163ffffffff9091168152602001610140565b6101c160035481565b6101c16102b23660046118aa565b6104eb565b6002546102d29064010000000090046001600160601b031681565b6040516001600160601b039091168152602001610140565b6101516102f83660046118c6565b61064a565b61012c7f000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa17381565b61012c7f000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e581565b61015161035936600461193a565b6107c3565b61036a6001600061083d565b505050565b600061037b3384610b36565b90506000816001600160a01b031663e9cb032485856040518363ffffffff1660e01b81526004016103ad929190611b09565b60a060405180830381600087803b1580156103c757600080fd5b505af11580156103db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103ff9190611a42565b60208101519091506001600160601b03161561043057610430816000015182602001516001600160601b0316610bbc565b60608101516001600160601b03161561046357610463816040015182606001516001600160601b03168360800151610e08565b50505050565b7f000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd776001600160a01b031633146104dd5760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064015b60405180910390fd5b6104e78282611244565b5050565b6001600160a01b0380821660009081526004602090815260408083208151808301909252546001600160601b038116808352600160601b90910490941691810191909152909161053e5750600092915050565b60007f000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e56001600160a01b0316635b9400816040518163ffffffff1660e01b815260040160206040518083038186803b15801561059957600080fd5b505afa1580156105ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105d19190611ad5565b60035460025491925090600160801b90046001600160801b031682158015906105fc57506103e88110155b156106275780610610633b9aca0085611bb5565b61061a9190611b95565b6106249083611b7d565b91505b835161063d906001600160601b03168584611340565b5090979650505050505050565b7f000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd776001600160a01b031633146106b95760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064016104d4565b6002600054141561070c5760405162461bcd60e51b815260206004820152601a60248201527f636c61696d45726332303a207265656e7472616e742063616c6c00000000000060448201526064016104d4565b60026000819055507f000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa1736001600160a01b0316836001600160a01b031614156107ae57600254600160801b90046001600160801b0316156107ae5760405162461bcd60e51b815260206004820152601360248201527f524d3a204661696c656420746f20636c61696d0000000000000000000000000060448201526064016104d4565b6107b9838383611416565b5050600160005550565b7f000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd776001600160a01b031633146108325760405162461bcd60e51b8152602060048201526014602482015273125b5b53dddb8e881d5b985d5d1a1bdc9a5e995960621b60448201526064016104d4565b61036a838383611576565b60008060008061084b6116fc565b6003546002549095506001600160601b0364010000000082041693509091506001600160801b03600160801b8204169060009061088e9063ffffffff1684611beb565b905063ffffffff811615806108b257508680156108b2575061012c8163ffffffff16105b806108be57506103e882105b156108d157858495509550505050610b2f565b60007f000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e56001600160a01b0316633c43059d6040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561092e57600080fd5b505af1158015610942573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109669190611ad5565b6040516370a0823160e01b81523060048201529091507f000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa1736001600160a01b0316906370a082319060240160206040518083038186803b1580156109c857600080fd5b505afa1580156109dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a009190611ad5565b95506000610a0e8287611b7d565b905080871115610a6d576000610a248289611bd4565b9050610a308184611b7d565b92507f0701991c7670454699af0d89a71c6225608163b182136536a3a34395535b5a4881604051610a6391815260200190565b60405180910390a1505b8115610ad25783610a82633b9aca0084611bb5565b610a8c9190611b95565b610a969089611b7d565b60038190556040518381529098507fde88a922e0d3b88b24e9623efeb464919c6bf9f66857a65e2bfcf2ce87a9433d9060200160405180910390a15b6002805463ffffffff191663ffffffff8716179055898015610af45750868614155b15610b2957610b028761170c565b600260046101000a8154816001600160601b0302191690836001600160601b031602179055505b50505050505b9250925092565b6001600160a01b0380831660009081526001602090815260408083206001600160e01b03198616845290915281205490911680610bb55760405162461bcd60e51b815260206004820152600660248201527f41434d3a4534000000000000000000000000000000000000000000000000000060448201526064016104d4565b9392505050565b8060008111610c0d5760405162461bcd60e51b815260206004820152601860248201527f524d3a205a65726f20616d6f756e742070726f7669646564000000000000000060448201526064016104d4565b826001600160a01b038116610c645760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b6000610c7160018061083d565b50506001600160a01b0380871660009081526004602090815260408083208151808301909252546001600160601b0381168252600160601b90049093169083015291925090633b9aca00610cc58488611bb5565b610ccf9190611b95565b82602001516001600160a01b0316610ce79190611b7d565b905060008683600001516001600160601b0316610d049190611b7d565b90506040518060400160405280610d1a8361170c565b6001600160601b03168152602001610d3184611765565b6001600160a01b03908116909152898116600090815260046020908152604090912083519390910151909116600160601b026001600160601b03909216919091179055600254610d9c90610d979089906001600160801b03600160801b90910416611b7d565b6117cb565b600280546001600160801b03928316600160801b0292169190911790556040516001600160a01b038916907fa9cb08b17f930ad003053de9e6b23478fb011aa5113047ce62b832dcbb6d2e4290610df6908a815260200190565b60405180910390a25050505050505050565b8160008111610e595760405162461bcd60e51b815260206004820152601860248201527f524d3a205a65726f20616d6f756e742070726f7669646564000000000000000060448201526064016104d4565b836001600160a01b038116610eb05760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b826001600160a01b038116610f075760405162461bcd60e51b815260206004820152601960248201527f524d3a205a65726f20616464726573732070726f76696465640000000000000060448201526064016104d4565b6001600160a01b038087166000908152600460209081526040918290208251808401909352546001600160601b038116808452600160601b9091049093169082015290861115610f995760405162461bcd60e51b815260206004820152601f60248201527f524d3a204e6f7420656e6f7567682073686172657320746f2072656465656d0060448201526064016104d4565b6000806000610faa6000600161083d565b9250925092506000806000610fc08c8888611340565b9250925092506040518060400160405280610fda8461170c565b6001600160601b03168152602001610ff183611765565b6001600160a01b039081169091528e8116600090815260046020908152604090912083519390910151909116600160601b026001600160601b0390921691909117905560025461105790610d97908e906001600160801b03600160801b90910416611bd4565b600280546001600160801b03928316600160801b02921691909117905560006110808487611bd4565b90508085146110b9576110928161170c565b600260046101000a8154816001600160601b0302191690836001600160601b031602179055505b83156111f15760405163a9059cbb60e01b81526001600160a01b038d81166004830152602482018690527f000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa173169063a9059cbb90604401602060405180830381600087803b15801561112957600080fd5b505af115801561113d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111619190611982565b6111ad5760405162461bcd60e51b815260206004820152601c60248201527f524d3a20496e7465726e616c207472616e73666572206661696c65640000000060448201526064016104d4565b8b6001600160a01b03167fe2403640ba68fed3a2f88b7557551d1993f84b99bb10ff833f0cf8db0c5e0486856040516111e891815260200190565b60405180910390a25b8d6001600160a01b03167fc064950777109fc27d3ee46c0e316d1aad25e9b115d36ea363e5623fabf0f4fe8e60405161122c91815260200190565b60405180910390a25050505050505050505050505050565b6001600160a01b0382811660009081526001602090815260408083206001600160e01b031986168452909152902054166112c05760405162461bcd60e51b815260206004820152600660248201527f41434d3a4533000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b03821660008181526001602090815260408083206001600160e01b03198616808552908352818420805473ffffffffffffffffffffffffffffffffffffffff19169055905192835292917fc3b2e3d4ba2ea7ac7abc74ac870cb893deaa227c6c21322632d97e6a2e2bf92d910160405180910390a35050565b60008060008585600001516001600160601b031661135e9190611bd4565b91506000821561139e5785600001516001600160601b03168787602001516001600160a01b031661138f9190611bb5565b6113999190611b95565b6113ad565b85602001516001600160a01b03165b90508086602001516001600160a01b03166113c89190611bd4565b600094509150841561140c57633b9aca006113e38689611bb5565b6113ed9190611b95565b9350808410156113fd57836113ff565b805b6114099085611bd4565b93505b5093509350939050565b604080518082018252601981527f7472616e7366657228616464726573732c75696e74323536290000000000000060209182015281516001600160a01b0385811660248301526044808301869052845180840390910181526064909201845291810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1663a9059cbb60e01b179052915160009283928716916114b79190611aed565b6000604051808303816000865af19150503d80600081146114f4576040519150601f19603f3d011682016040523d82523d6000602084013e6114f9565b606091505b50915091508180156115235750805115806115235750808060200190518101906115239190611982565b61156f5760405162461bcd60e51b815260206004820152601b60248201527f636c61696d45726332303a205452414e534645525f4641494c4544000000000060448201526064016104d4565b5050505050565b6001600160a01b0383161580159061159657506001600160a01b03811615155b80156115ab57506001600160e01b0319821615155b6115f75760405162461bcd60e51b815260206004820152600660248201527f41434d3a4531000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b0383811660009081526001602090815260408083206001600160e01b03198716845290915290205416156116745760405162461bcd60e51b815260206004820152600660248201527f41434d3a4532000000000000000000000000000000000000000000000000000060448201526064016104d4565b6001600160a01b0383811660008181526001602090815260408083206001600160e01b0319881680855290835292819020805473ffffffffffffffffffffffffffffffffffffffff191695871695861790555193845290927fc3b2e3d4ba2ea7ac7abc74ac870cb893deaa227c6c21322632d97e6a2e2bf92d910160405180910390a3505050565b600061170743611820565b905090565b6000600160601b82106117615760405162461bcd60e51b815260206004820152600860248201527f554e53414645393600000000000000000000000000000000000000000000000060448201526064016104d4565b5090565b60007401000000000000000000000000000000000000000082106117615760405162461bcd60e51b815260206004820152600960248201527f554e53414645313630000000000000000000000000000000000000000000000060448201526064016104d4565b6000600160801b82106117615760405162461bcd60e51b815260206004820152600960248201527f554e53414645313238000000000000000000000000000000000000000000000060448201526064016104d4565b600064010000000082106117615760405162461bcd60e51b815260206004820152600860248201527f554e53414645333200000000000000000000000000000000000000000000000060448201526064016104d4565b80356001600160e01b03198116811461188e57600080fd5b919050565b80516001600160601b038116811461188e57600080fd5b6000602082840312156118bb578081fd5b8135610bb581611c68565b6000806000606084860312156118da578182fd5b83356118e581611c68565b925060208401356118f581611c68565b929592945050506040919091013590565b60008060408385031215611918578182fd5b823561192381611c68565b915061193160208401611876565b90509250929050565b60008060006060848603121561194e578283fd5b833561195981611c68565b925061196760208501611876565b9150604084013561197781611c68565b809150509250925092565b600060208284031215611993578081fd5b81518015158114610bb5578182fd5b600080604083850312156119b4578182fd5b6119bd83611876565b915060208084013567ffffffffffffffff808211156119da578384fd5b818601915086601f8301126119ed578384fd5b8135818111156119ff576119ff611c52565b611a11601f8201601f19168501611b4c565b91508082528784828501011115611a26578485fd5b8084840185840137810190920192909252919491935090915050565b600060a08284031215611a53578081fd5b60405160a0810181811067ffffffffffffffff82111715611a7657611a76611c52565b6040528251611a8481611c68565b8152611a9260208401611893565b60208201526040830151611aa581611c68565b6040820152611ab660608401611893565b60608201526080830151611ac981611c68565b60808201529392505050565b600060208284031215611ae6578081fd5b5051919050565b60008251611aff818460208701611c10565b9190910192915050565b63ffffffff60e01b831681526040602082015260008251806040840152611b37816060850160208701611c10565b601f01601f1916919091016060019392505050565b604051601f8201601f1916810167ffffffffffffffff81118282101715611b7557611b75611c52565b604052919050565b60008219821115611b9057611b90611c3c565b500190565b600082611bb057634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615611bcf57611bcf611c3c565b500290565b600082821015611be657611be6611c3c565b500390565b600063ffffffff83811690831681811015611c0857611c08611c3c565b039392505050565b60005b83811015611c2b578181015183820152602001611c13565b838111156104635750506000910152565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114611c7d57600080fd5b5056fea164736f6c6343000804000a

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

000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa173000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e5000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd77

-----Decoded View---------------
Arg [0] : _rewardToken (address): 0x909E34d3f6124C324ac83DccA84b74398a6fa173
Arg [1] : _rewardPool (address): 0xcF463713521Af5cE31AD18F6914f3706493F10e5
Arg [2] : _owner (address): 0x505796f5Bc290269D2522cf19135aD7Aa60dfd77

-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 000000000000000000000000909e34d3f6124c324ac83dcca84b74398a6fa173
Arg [1] : 000000000000000000000000cf463713521af5ce31ad18f6914f3706493f10e5
Arg [2] : 000000000000000000000000505796f5bc290269d2522cf19135ad7aa60dfd77


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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