Contract 0xb844bdcc64a748fdc8c9ee74fa4812e4bc28fd70 8

 

Contract Overview

Staking Proxy
Balance:
0 ETH

EtherValue:
$0.00

Token:
Txn Hash Method
Block
From
To
Value
0x659ad6ef45d93d773f529c890262d622657062383c23aada8fdd0836ab97d551Batch Execute1175337762024-03-17 9:05:2911 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000023366110.005911999
0x1ca8438bf7314d63f99b0dc8ef6a4b772cf4599d9f03dfc9255ab53ae0bdba14Batch Execute1146828752024-01-11 9:15:2777 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000452114370.003455837
0x0c142bea72c1b7afd6e076c3958e47a5c674e29ad209ca8a02ada6a89a969db8Batch Execute1139104132023-12-24 12:06:4395 days 18 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000595709480.004200547
0xb5f2c8a855368f1e0531d80bc0ab8a3c60527ef688e94d665581231b494b9e24Batch Execute1132989452023-12-10 8:24:27109 days 22 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000515205130.017125594
0xa00e63ae154025ecf706de2cb52117bfe5310e651ad1cb56985fccd5acb3163dBatch Execute1126610562023-11-25 14:01:29124 days 16 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000692770720.008485669
0x3940ce422e0b43e027521b77f5f5708e2a57160fd7a27e3a892fc83e650788b7Batch Execute1120513142023-11-11 11:16:45138 days 19 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000735123020.011675307
0xc759c013074c9da10652bc22a85b86598b7158abed955e5f7f7bd4389b31210dBatch Execute1114435762023-10-28 9:38:49152 days 20 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000563557550.016992383
0x1a77cd0120a8f70178d2ab169541ae4af809165dd16b7ac93c08842fd3b8371cBatch Execute1107571832023-10-12 12:19:03168 days 18 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000276535660.016326962
0x3d154ca118fc4a9e344561ff753d3e2d188388d8408eb9644fa5b9fb5b742cbdBatch Execute1101433452023-09-28 7:17:47182 days 23 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000450035140.046345285
0x7ffcf53ac84a5c8a2ff396f05281ac40917909346df3459d377ba6200dc13d23Batch Execute1095384262023-09-14 7:13:49196 days 23 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.000034884710.000003571
0x348cb85b0d1d902116f68f9de2c6a1ab9892ef9a726726fe6f7c00b5b2380246Batch Execute1085907912023-08-23 8:45:59218 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000529188020.000000117
0x74698bb484805d94f2626eeb9e15191779f02460ee52d98512f907a279cc3363Batch Execute1077252502023-08-03 7:54:37238 days 22 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001236545650.200000578
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b5Batch Execute1071196602023-07-20 7:28:17252 days 23 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001448783610.200005798
0xd89245464d3a5aba8504577ebb087ab7caf1c2db55251d212cc3d2ea64c7b1f6Batch Execute1063858602023-07-03 7:48:17269 days 22 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001172686770.200000222
0x3ddfd04d24f12bd0aae0dade4153967faa1b088c2fcfd831501dca118ff95ff5Batch Execute1056607942023-06-16 12:59:25286 days 17 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001271501720.200000063
0x44b090ad6294a1998383aeafb6e204acfa0a933b7542389012ab2230e702e000Finalize Pool1013465992023-05-25 9:21:12308 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001214323630.001
0x65299db76f22148ab958989e14ed38e8fc0143943268fd39e4b50a8ad920774fFinalize Pool1013434762023-05-25 9:11:27308 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001376589490.001
0xd5776dc1b58f1d9df862a7ccedf1932adc6f709c751c7a8cc43c8cbca7e04d25Batch Execute1013423102023-05-25 9:07:26308 days 21 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.00015937910.001
0x9df053684c8f060e51fab747d955d0ea44613b03a4b916ed15b1080e2cf21920Transfer Ownersh...974527962023-05-11 14:27:15322 days 16 hrs agoRigo Block: Deployer IN  Staking Proxy0 ETH0.0004591540420.001048154
0xbbd45da1d77460a21f9b0ec5d569e85ac280ece177cb03e79a1132c45b4a6b12Add Authorized A...974526842023-05-11 14:26:30322 days 16 hrs agoRigo Block: Deployer IN  Staking Proxy0 ETH0.0004609917190.001048154
0x763ed9e9b783c8ced489d98f96b1c9d2b74130cd572c41ffa6f9f47d129bacb5Remove Authorize...974520292023-05-11 14:23:00322 days 16 hrs agoRigo Block: Deployer IN  Staking Proxy0 ETH0.0005181636640.001048154
0xcfe054c2849254649e84013882d08d348d95bc8ca55d823e2ca5b54ff9f49d37Batch Execute971978312023-05-10 7:53:11323 days 22 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0002762304770.001
0x7cd592702e8aec9f7ba185d4fe98ef2ed9124920e096ad4f575adca1820ac939Batch Execute931709522023-04-22 9:34:00341 days 20 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.000162442410.001
0x966337de6c98122c6ea5e6cd1ffe71bf675174b0135bea4ccb6871e85abb993fBatch Execute853926772023-04-01 13:22:27362 days 17 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0001243506950.001
0x827d472879dd7e86209fc79d3e5a941f30de500548e98049c9d79835cebccc94Finalize Pool818966062023-03-18 12:57:46376 days 17 hrs ago0xca9f5049c1ea8fc78574f94b7cf5be5fee354c31 IN  Staking Proxy0 ETH0.0000613706240.001
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0xea34f46734fe5f9ab70b268dde21d76c1d7ee0983120b345dacd952fcb9d6b8f1071196862023-07-20 7:29:09252 days 22 hrs ago Staking ProxyStaking Implementation V30 ETH
0xea34f46734fe5f9ab70b268dde21d76c1d7ee0983120b345dacd952fcb9d6b8f1071196862023-07-20 7:29:09252 days 22 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0xea34f46734fe5f9ab70b268dde21d76c1d7ee0983120b345dacd952fcb9d6b8f1071196862023-07-20 7:29:09252 days 22 hrs ago Staking ProxyStaking Implementation V30 ETH
0xea34f46734fe5f9ab70b268dde21d76c1d7ee0983120b345dacd952fcb9d6b8f1071196862023-07-20 7:29:09252 days 22 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0x5b36e519b9cd8bf98cc3baa426c2e793aae4d09ef3b4c6ce9c5449b133842ffb1071196772023-07-20 7:28:51252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x5b36e519b9cd8bf98cc3baa426c2e793aae4d09ef3b4c6ce9c5449b133842ffb1071196772023-07-20 7:28:51252 days 23 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0x5b36e519b9cd8bf98cc3baa426c2e793aae4d09ef3b4c6ce9c5449b133842ffb1071196772023-07-20 7:28:51252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x5b36e519b9cd8bf98cc3baa426c2e793aae4d09ef3b4c6ce9c5449b133842ffb1071196772023-07-20 7:28:51252 days 23 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Rigo Block: GRG Token0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Rigo Block: GRG Token0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Rigo Block: GRG Token0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Rigo Block: GRG Token0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Rigo Block: GRG Token0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Inflation L2 Staking Proxy0 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking Proxy Inflation L20 ETH
0x5085f0bfd7a5db2cb36a517de271b75db3e78b76537f71d4d456faee07d8b2b51071196602023-07-20 7:28:17252 days 23 hrs ago Staking ProxyStaking Implementation V30 ETH
0x1b40cf87ed615ddb253b5bf8b1b0a1219c2aca358ccd214ee8eb37e82a393cd31063858882023-07-03 7:49:13269 days 22 hrs ago Staking ProxyStaking Implementation V30 ETH
0x1b40cf87ed615ddb253b5bf8b1b0a1219c2aca358ccd214ee8eb37e82a393cd31063858882023-07-03 7:49:13269 days 22 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0x1b40cf87ed615ddb253b5bf8b1b0a1219c2aca358ccd214ee8eb37e82a393cd31063858882023-07-03 7:49:13269 days 22 hrs ago Staking ProxyStaking Implementation V30 ETH
0x1b40cf87ed615ddb253b5bf8b1b0a1219c2aca358ccd214ee8eb37e82a393cd31063858882023-07-03 7:49:13269 days 22 hrs ago Proof of Performance V3 Staking Proxy0 ETH
0xa75ce660a1e3468173ae1eb7cf95bb08fdc4e3c9dde739dc67a5465afd1bef881063858782023-07-03 7:48:53269 days 22 hrs ago Staking ProxyStaking Implementation V30 ETH
0xa75ce660a1e3468173ae1eb7cf95bb08fdc4e3c9dde739dc67a5465afd1bef881063858782023-07-03 7:48:53269 days 22 hrs ago Proof of Performance V3 Staking Proxy0 ETH
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
StakingProxy

Compiler Version
v0.8.17+commit.8df45f5f

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 13 : StakingProxy.sol
// SPDX-License-Identifier: Apache 2.0

/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity 0.8.17;

import "./libs/LibSafeDowncast.sol";
import "./immutable/MixinStorage.sol";
import "./immutable/MixinConstants.sol";
import "./interfaces/IStorageInit.sol";
import "./interfaces/IStakingProxy.sol";

/// #dev The RigoBlock Staking contract.
contract StakingProxy is IStakingProxy, MixinStorage, MixinConstants {
    using LibSafeDowncast for uint256;

    /// @notice Constructor.
    /// @param stakingImplementation Address of the staking contract to delegate calls to.
    /// @param newOwner Address of the staking proxy owner.
    constructor(address stakingImplementation, address newOwner) Authorizable(newOwner) MixinStorage() {
        // Deployer address must be authorized in order to call `init`
        // in the context of deterministic deployment, the deployer factory (msg.sender) must be authorized.
        _addAuthorizedAddress(msg.sender);

        // Attach the staking contract and initialize state
        _attachStakingContract(stakingImplementation);

        // Remove the sender as an authorized address
        _removeAuthorizedAddressAtIndex(msg.sender, 0);
    }

    /* solhint-disable payable-fallback, no-complex-fallback */
    /// @notice Delegates calls to the staking contract, if it is set.
    fallback() external {
        // Sanity check that we have a staking contract to call
        address stakingContract_ = stakingContract;
        require(stakingContract_ != _NIL_ADDRESS, "STAKING_ADDRESS_NULL_ERROR");

        // Call the staking contract with the provided calldata.
        (bool success, bytes memory returnData) = stakingContract_.delegatecall(msg.data);

        // Revert on failure or return on success.
        assembly {
            switch success
            case 0 {
                revert(add(0x20, returnData), mload(returnData))
            }
            default {
                return(add(0x20, returnData), mload(returnData))
            }
        }
    }

    /* solhint-enable payable-fallback, no-complex-fallback */

    /// @inheritdoc IStakingProxy
    function attachStakingContract(address stakingImplementation) external override onlyAuthorized {
        _attachStakingContract(stakingImplementation);
    }

    /// @inheritdoc IStakingProxy
    function detachStakingContract() external override onlyAuthorized {
        stakingContract = _NIL_ADDRESS;
        emit StakingContractDetachedFromProxy();
    }

    /// @inheritdoc IStakingProxy
    function batchExecute(bytes[] calldata data) external returns (bytes[] memory batchReturnData) {
        // Initialize commonly used variables.
        bool success;
        bytes memory returnData;
        uint256 dataLength = data.length;
        batchReturnData = new bytes[](dataLength);
        address staking = stakingContract;

        // Ensure that a staking contract has been attached to the proxy.
        require(staking != _NIL_ADDRESS, "STAKING_ADDRESS_NULL_ERROR");

        // Execute all of the calls encoded in the provided calldata.
        for (uint256 i = 0; i != dataLength; i++) {
            // Call the staking contract with the provided calldata.
            (success, returnData) = staking.delegatecall(data[i]);

            // Revert on failure.
            if (!success) {
                assembly {
                    revert(add(0x20, returnData), mload(returnData))
                }
            }

            // Add the returndata to the batch returndata.
            batchReturnData[i] = returnData;
        }

        return batchReturnData;
    }

    /// @inheritdoc IStakingProxy
    function assertValidStorageParams() public view override {
        // Epoch length must be between 5 and 90 days long
        uint256 _epochDurationInSeconds = epochDurationInSeconds;
        require(
            _epochDurationInSeconds >= 5 days && _epochDurationInSeconds <= 90 days,
            "STAKING_PROXY_INVALID_EPOCH_DURATION_ERROR"
        );

        // Alpha must be 0 < x <= 1
        uint32 _cobbDouglasAlphaDenominator = cobbDouglasAlphaDenominator;
        require(
            cobbDouglasAlphaNumerator <= _cobbDouglasAlphaDenominator && _cobbDouglasAlphaDenominator != 0,
            "STAKING_PROXY_INVALID_COBB_DOUGLAS_ALPHA_ERROR"
        );

        // Weight of delegated stake must be <= 100%
        require(rewardDelegatedStakeWeight <= _PPM_DENOMINATOR, "STAKING_PROXY_INVALID_STAKE_WEIGHT_ERROR");

        // Minimum stake must be > 1
        require(minimumPoolStake >= 2, "STAKING_PROXY_INVALID_MINIMUM_STAKE_ERROR");
    }

    /// @dev Attach a staking contract; future calls will be delegated to the staking contract.
    /// @param stakingImplementation Address of staking contract.
    function _attachStakingContract(address stakingImplementation) internal {
        // Attach the staking contract
        stakingContract = stakingImplementation;
        emit StakingContractAttachedToProxy(stakingImplementation);

        // Call `init()` on the staking contract to initialize storage.
        (bool didInitSucceed, bytes memory initReturnData) = stakingContract.delegatecall(
            abi.encodeWithSelector(IStorageInit.init.selector)
        );

        if (!didInitSucceed) {
            assembly {
                revert(add(initReturnData, 0x20), mload(initReturnData))
            }
        }

        // Assert initialized storage values are valid
        assertValidStorageParams();
    }
}

File 2 of 13 : LibSafeDowncast.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

library LibSafeDowncast {
    /// @dev Safely downcasts to a uint96
    /// Note that this reverts if the input value is too large.
    function downcastToUint96(uint256 a) internal pure returns (uint96 b) {
        b = uint96(a);
        require(uint256(b) == a, "VALUE_TOO_LARGE_TO_DOWNCAST_TO_UINT96");
        return b;
    }

    /// @dev Safely downcasts to a uint64
    /// Note that this reverts if the input value is too large.
    function downcastToUint64(uint256 a) internal pure returns (uint64 b) {
        b = uint64(a);
        require(uint256(b) == a, "VALUE_TOO_LARGE_TO_DOWNCAST_TO_UINT64");
        return b;
    }
}

File 3 of 13 : MixinStorage.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

import "../../utils/0xUtils/Authorizable.sol";
import "../interfaces/IGrgVault.sol";
import "../interfaces/IStorage.sol";
import "../interfaces/IStructs.sol";

// solhint-disable max-states-count, no-empty-blocks
abstract contract MixinStorage is IStorage, Authorizable {
    /// @inheritdoc IStorage
    address public override stakingContract;

    // mapping from StakeStatus to global stored balance
    // NOTE: only Status.DELEGATED is used to access this mapping, but this format
    // is used for extensibility
    mapping(uint8 => IStructs.StoredBalance) internal _globalStakeByStatus;

    // mapping from StakeStatus to address of staker to stored balance
    mapping(uint8 => mapping(address => IStructs.StoredBalance)) internal _ownerStakeByStatus;

    // Mapping from Owner to Pool Id to Amount Delegated
    mapping(address => mapping(bytes32 => IStructs.StoredBalance)) internal _delegatedStakeToPoolByOwner;

    // Mapping from Pool Id to Amount Delegated
    mapping(bytes32 => IStructs.StoredBalance) internal _delegatedStakeByPoolId;

    /// @inheritdoc IStorage
    mapping(address => bytes32) public override poolIdByRbPoolAccount;

    // mapping from Pool Id to Pool
    mapping(bytes32 => IStructs.Pool) internal _poolById;

    /// @inheritdoc IStorage
    mapping(bytes32 => uint256) public override rewardsByPoolId;

    /// @inheritdoc IStorage
    uint256 public override currentEpoch;

    /// @inheritdoc IStorage
    uint256 public override currentEpochStartTimeInSeconds;

    // mapping from Pool Id to Epoch to Reward Ratio
    mapping(bytes32 => mapping(uint256 => IStructs.Fraction)) internal _cumulativeRewardsByPool;

    // mapping from Pool Id to Epoch
    mapping(bytes32 => uint256) internal _cumulativeRewardsByPoolLastStored;

    /// @inheritdoc IStorage
    mapping(address => bool) public override validPops;

    /* Tweakable parameters */

    /// @inheritdoc IStorage
    uint256 public override epochDurationInSeconds;

    /// @inheritdoc IStorage
    uint32 public override rewardDelegatedStakeWeight;

    /// @inheritdoc IStorage
    uint256 public override minimumPoolStake;

    /// @inheritdoc IStorage
    uint32 public override cobbDouglasAlphaNumerator;

    /// @inheritdoc IStorage
    uint32 public override cobbDouglasAlphaDenominator;

    /* State for finalization */

    /// @inheritdoc IStorage
    mapping(bytes32 => mapping(uint256 => IStructs.PoolStats)) public override poolStatsByEpoch;

    /// @inheritdoc IStorage
    mapping(uint256 => IStructs.AggregatedStats) public aggregatedStatsByEpoch;

    /// @inheritdoc IStorage
    uint256 public grgReservedForPoolRewards;
}

File 4 of 13 : MixinConstants.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

abstract contract MixinConstants {
    // 100% in parts-per-million.
    uint32 internal constant _PPM_DENOMINATOR = 10**6;

    bytes32 internal constant _NIL_POOL_ID = 0x0000000000000000000000000000000000000000000000000000000000000000;

    address internal constant _NIL_ADDRESS = 0x0000000000000000000000000000000000000000;

    uint256 internal constant _MIN_TOKEN_VALUE = 10**18;
}

File 5 of 13 : IStorageInit.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

interface IStorageInit {
    /// @notice Initialize storage owned by this contract.
    function init() external;
}

File 6 of 13 : IStakingProxy.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

import "./IStructs.sol";

interface IStakingProxy {
    /// @notice Emitted by StakingProxy when a staking contract is attached.
    /// @param newStakingContractAddress Address of newly attached staking contract.
    event StakingContractAttachedToProxy(address newStakingContractAddress);

    /// @notice Emitted by StakingProxy when a staking contract is detached.
    event StakingContractDetachedFromProxy();

    /// @notice Attach a staking contract; future calls will be delegated to the staking contract.
    /// @dev Note that this is callable only by an authorized address.
    /// @param stakingImplementation Address of staking contract.
    function attachStakingContract(address stakingImplementation) external;

    /// @notice Detach the current staking contract.
    /// @dev Note that this is callable only by an authorized address.
    function detachStakingContract() external;

    /// @notice Batch executes a series of calls to the staking contract.
    /// @param data An array of data that encodes a sequence of functions to call in the staking contracts.
    function batchExecute(bytes[] calldata data) external returns (bytes[] memory batchReturnData);

    /// @notice Asserts initialziation parameters are correct.
    /// @dev Asserts that an epoch is between 5 and 30 days long.
    /// @dev Asserts that 0 < cobb douglas alpha value <= 1.
    /// @dev Asserts that a stake weight is <= 100%.
    /// @dev Asserts that pools allow >= 1 maker.
    /// @dev Asserts that all addresses are initialized.
    function assertValidStorageParams() external view;
}

File 7 of 13 : Authorizable.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Copyright 2019 ZeroEx Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.5.9 <0.9.0;

import "./interfaces/IAuthorizable.sol";
import "./Ownable.sol";

// solhint-disable no-empty-blocks
// TODO: check if should use OwnedUninitialized and remove duplicate contract
abstract contract Authorizable is Ownable, IAuthorizable {
    /// @dev Only authorized addresses can invoke functions with this modifier.
    modifier onlyAuthorized() {
        _assertSenderIsAuthorized();
        _;
    }

    /// @dev Whether an address is authorized to call privileged functions.
    /// @dev 0 Address to query.
    /// @return 0 Whether the address is authorized.
    mapping(address => bool) public authorized;
    /// @dev Whether an adderss is authorized to call privileged functions.
    /// @dev 0 Index of authorized address.
    /// @return 0 Authorized address.
    address[] public authorities;

    /// @dev Initializes the `owner` address.
    constructor(address newOwner) Ownable(newOwner) {}

    /// @dev Authorizes an address.
    /// @param target Address to authorize.
    function addAuthorizedAddress(address target) external override onlyOwner {
        _addAuthorizedAddress(target);
    }

    /// @dev Removes authorizion of an address.
    /// @param target Address to remove authorization from.
    function removeAuthorizedAddress(address target) external override onlyOwner {
        require(authorized[target], "TARGET_NOT_AUTHORIZED");
        for (uint256 i = 0; i < authorities.length; i++) {
            if (authorities[i] == target) {
                _removeAuthorizedAddressAtIndex(target, i);
                break;
            }
        }
    }

    /// @dev Removes authorizion of an address.
    /// @param target Address to remove authorization from.
    /// @param index Index of target in authorities array.
    function removeAuthorizedAddressAtIndex(address target, uint256 index) external override onlyOwner {
        _removeAuthorizedAddressAtIndex(target, index);
    }

    /// @dev Gets all authorized addresses.
    /// @return Array of authorized addresses.
    function getAuthorizedAddresses() external view override returns (address[] memory) {
        return authorities;
    }

    /// @dev Reverts if msg.sender is not authorized.
    function _assertSenderIsAuthorized() internal view {
        require(authorized[msg.sender], "AUTHORIZABLE_SENDER_NOT_AUTHORIZED_ERROR");
    }

    /// @dev Authorizes an address.
    /// @param target Address to authorize.
    function _addAuthorizedAddress(address target) internal {
        // Ensure that the target is not the zero address.
        require(target != address(0), "AUTHORIZABLE_NULL_ADDRESS_ERROR");

        // Ensure that the target is not already authorized.
        require(!authorized[target], "AUTHORIZABLE_ALREADY_AUTHORIZED_ERROR");

        authorized[target] = true;
        authorities.push(target);
        emit AuthorizedAddressAdded(target, msg.sender);
    }

    /// @dev Removes authorization of an address.
    /// @param target Address to remove authorization from.
    /// @param index Index of target in authorities array.
    function _removeAuthorizedAddressAtIndex(address target, uint256 index) internal {
        require(authorized[target], "AUTHORIZABLE_ADDRESS_NOT_AUTHORIZED_ERROR");
        require(index < authorities.length, "AUTHORIZABLE_INDEX_OUT_OF_BOUNDS_ERROR");
        require(authorities[index] == target, "AUTHORIZABLE_ADDRESS_MISMATCH_ERROR");

        delete authorized[target];
        authorities[index] = authorities[authorities.length - 1];
        authorities.pop();
        emit AuthorizedAddressRemoved(target, msg.sender);
    }
}

File 8 of 13 : IGrgVault.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

interface IGrgVault {
    /// @notice Emmitted whenever a StakingProxy is set in a vault.
    /// @param stakingProxyAddress Address of the staking proxy contract.
    event StakingProxySet(address stakingProxyAddress);

    /// @notice Emitted when the Staking contract is put into Catastrophic Failure Mode
    /// @param sender Address of sender (`msg.sender`)
    event InCatastrophicFailureMode(address sender);

    /// @notice Emitted when Grg Tokens are deposited into the vault.
    /// @param staker Address of the Grg staker.
    /// @param amount of Grg Tokens deposited.
    event Deposit(address indexed staker, uint256 amount);

    /// @notice Emitted when Grg Tokens are withdrawn from the vault.
    /// @param staker Address of the Grg staker.
    /// @param amount of Grg Tokens withdrawn.
    event Withdraw(address indexed staker, uint256 amount);

    /// @notice Emitted whenever the Grg AssetProxy is set.
    /// @param grgProxyAddress Address of the Grg transfer proxy.
    event GrgProxySet(address grgProxyAddress);

    /// @notice Sets the address of the StakingProxy contract.
    /// @dev Note that only the contract staker can call this function.
    /// @param stakingProxyAddress Address of Staking proxy contract.
    function setStakingProxy(address stakingProxyAddress) external;

    /// @notice Vault enters into Catastrophic Failure Mode.
    /// @dev *** WARNING - ONCE IN CATOSTROPHIC FAILURE MODE, YOU CAN NEVER GO BACK! ***
    /// @dev Note that only the contract staker can call this function.
    function enterCatastrophicFailure() external;

    /// @notice Sets the Grg proxy.
    /// @dev Note that only the contract staker can call this.
    /// @dev Note that this can only be called when *not* in Catastrophic Failure mode.
    /// @param grgProxyAddress Address of the RigoBlock Grg Proxy.
    function setGrgProxy(address grgProxyAddress) external;

    /// @notice Deposit an `amount` of Grg Tokens from `staker` into the vault.
    /// @dev Note that only the Staking contract can call this.
    /// @dev Note that this can only be called when *not* in Catastrophic Failure mode.
    /// @param staker Address of the Grg staker.
    /// @param amount of Grg Tokens to deposit.
    function depositFrom(address staker, uint256 amount) external;

    /// @notice Withdraw an `amount` of Grg Tokens to `staker` from the vault.
    /// @dev Note that only the Staking contract can call this.
    /// @dev Note that this can only be called when *not* in Catastrophic Failure mode.
    /// @param staker Address of the Grg staker.
    /// @param amount of Grg Tokens to withdraw.
    function withdrawFrom(address staker, uint256 amount) external;

    /// @notice Withdraw ALL Grg Tokens to `staker` from the vault.
    /// @dev Note that this can only be called when *in* Catastrophic Failure mode.
    /// @param staker Address of the Grg staker.
    function withdrawAllFrom(address staker) external returns (uint256);

    /// @notice Returns the balance in Grg Tokens of the `staker`
    /// @param staker Address of the Grg staker.
    /// @return Balance in Grg.
    function balanceOf(address staker) external view returns (uint256);

    /// @notice Returns the entire balance of Grg tokens in the vault.
    /// @return Balance in Grg.
    function balanceOfGrgVault() external view returns (uint256);
}

File 9 of 13 : IStorage.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

interface IStorage {
    /// @notice Address of staking contract.
    /// @return stakingContract Address of the staking contract.
    function stakingContract() external view returns (address);

    /// @notice Mapping from RigoBlock pool subaccount to pool Id of rigoblock pool
    /// @dev 0 RigoBlock pool subaccount address.
    /// @return 0 The pool ID.
    function poolIdByRbPoolAccount(address) external view returns (bytes32);

    /// @notice mapping from pool ID to reward balance of members
    /// @dev 0 Pool ID.
    /// @return 0 The total reward balance of members in this pool.
    function rewardsByPoolId(bytes32) external view returns (uint256);

    /// @notice The current epoch.
    /// @return currentEpoch The number of the current epoch.
    function currentEpoch() external view returns (uint256);

    /// @notice The current epoch start time.
    /// @return currentEpochStartTimeInSeconds Timestamp of start time.
    function currentEpochStartTimeInSeconds() external view returns (uint256);

    /// @notice Registered RigoBlock Proof_of_Performance contracts, capable of paying protocol fees.
    /// @dev 0 The address to check.
    /// @return 0 Whether the address is a registered proof_of_performance.
    function validPops(address popAddress) external view returns (bool);

    /// @notice Minimum seconds between epochs.
    /// @return epochDurationInSeconds Number of seconds.
    function epochDurationInSeconds() external view returns (uint256);

    // @notice How much delegated stake is weighted vs operator stake, in ppm.
    /// @return rewardDelegatedStakeWeight Number in units of a million.
    function rewardDelegatedStakeWeight() external view returns (uint32);

    /// @notice Minimum amount of stake required in a pool to collect rewards.
    /// @return minimumPoolStake Minimum amount required.
    function minimumPoolStake() external view returns (uint256);

    /// @notice Numerator for cobb douglas alpha factor.
    /// @return cobbDouglasAlphaNumerator Number of the numerator.
    function cobbDouglasAlphaNumerator() external view returns (uint32);

    /// @notice Denominator for cobb douglas alpha factor.
    /// @return cobbDouglasAlphaDenominator Number of the denominator.
    function cobbDouglasAlphaDenominator() external view returns (uint32);

    /// @notice Stats for each pool that generated fees with sufficient stake to earn rewards.
    /// @dev See `_minimumPoolStake` in `MixinParams`.
    /// @param key Pool ID.
    /// @param epoch Epoch number.
    /// @return feesCollected Amount of fees collected in epoch.
    /// @return weightedStake Weighted stake per million.
    /// @return membersStake Members stake per million.
    function poolStatsByEpoch(bytes32 key, uint256 epoch)
        external
        view
        returns (
            uint256 feesCollected,
            uint256 weightedStake,
            uint256 membersStake
        );

    /// @notice Aggregated stats across all pools that generated fees with sufficient stake to earn rewards.
    /// @dev See `_minimumPoolStake` in MixinParams.
    /// @param epoch Epoch number.
    /// @return rewardsAvailable Rewards (GRG) available to the epoch being finalized (the previous epoch).
    /// @return numPoolsToFinalize The number of pools that have yet to be finalized through `finalizePools()`.
    /// @return totalFeesCollected The total fees collected for the epoch being finalized.
    /// @return totalWeightedStake The total fees collected for the epoch being finalized.
    /// @return totalRewardsFinalized Amount of rewards that have been paid during finalization.
    function aggregatedStatsByEpoch(uint256 epoch)
        external
        view
        returns (
            uint256 rewardsAvailable,
            uint256 numPoolsToFinalize,
            uint256 totalFeesCollected,
            uint256 totalWeightedStake,
            uint256 totalRewardsFinalized
        );

    /// @notice The GRG balance of this contract that is reserved for pool reward payouts.
    /// @return grgReservedForPoolRewards Number of tokens reserved for rewards.
    function grgReservedForPoolRewards() external view returns (uint256);
}

File 10 of 13 : IStructs.sol
// SPDX-License-Identifier: Apache 2.0
/*

  Original work Copyright 2019 ZeroEx Intl.
  Modified work Copyright 2020-2022 Rigo Intl.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

*/

pragma solidity >=0.8.0 <0.9.0;

interface IStructs {
    /// @notice Stats for a pool that earned rewards.
    /// @param feesCollected Fees collected in ETH by this pool.
    /// @param weightedStake Amount of weighted stake in the pool.
    /// @param membersStake Amount of non-operator stake in the pool.
    struct PoolStats {
        uint256 feesCollected;
        uint256 weightedStake;
        uint256 membersStake;
    }

    /// @notice Holds stats aggregated across a set of pools.
    /// @dev rewardsAvailable is simply the balanc of the contract at the end of the epoch.
    /// @param rewardsAvailable Rewards (GRG) available to the epoch being finalized (the previous epoch).
    /// @param numPoolsToFinalize The number of pools that have yet to be finalized through `finalizePools()`.
    /// @param totalFeesCollected The total fees collected for the epoch being finalized.
    /// @param totalWeightedStake The total fees collected for the epoch being finalized.
    /// @param totalRewardsFinalized Amount of rewards that have been paid during finalization.
    struct AggregatedStats {
        uint256 rewardsAvailable;
        uint256 numPoolsToFinalize;
        uint256 totalFeesCollected;
        uint256 totalWeightedStake;
        uint256 totalRewardsFinalized;
    }

    /// @notice Encapsulates a balance for the current and next epochs.
    /// @dev Note that these balances may be stale if the current epoch is greater than `currentEpoch`.
    /// @param currentEpoch The current epoch
    /// @param currentEpochBalance Balance in the current epoch.
    /// @param nextEpochBalance Balance in `currentEpoch+1`.
    struct StoredBalance {
        uint64 currentEpoch;
        uint96 currentEpochBalance;
        uint96 nextEpochBalance;
    }

    /// @notice Statuses that stake can exist in.
    /// @dev Any stake can be (re)delegated effective at the next epoch.
    /// @dev Undelegated stake can be withdrawn if it is available in both the current and next epoch.
    enum StakeStatus {
        UNDELEGATED,
        DELEGATED
    }

    /// @notice Info used to describe a status.
    /// @param status Status of the stake.
    /// @param poolId Unique Id of pool. This is set when status=DELEGATED.
    struct StakeInfo {
        StakeStatus status;
        bytes32 poolId;
    }

    /// @notice Struct to represent a fraction.
    /// @param numerator Numerator of fraction.
    /// @param denominator Denominator of fraction.
    struct Fraction {
        uint256 numerator;
        uint256 denominator;
    }

    /// @notice Holds the metadata for a staking pool.
    /// @param operator Operator of the pool.
    /// @param stakingPal Staking pal of the pool.
    /// @param operatorShare Fraction of the total balance owned by the operator, in ppm.
    /// @param stakingPalShare Fraction of the operator reward owned by the staking pal, in ppm.
    struct Pool {
        address operator;
        address stakingPal;
        uint32 operatorShare;
        uint32 stakingPalShare;
    }
}

File 11 of 13 : IAuthorizable.sol
// SPDX-License-Identifier: Apache 2.0
/*
  Copyright 2019 ZeroEx Intl.
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
    http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/

pragma solidity >=0.5.9 <0.9.0;

abstract contract IAuthorizable {
    /// @dev Emitted when a new address is authorized.
    /// @param target Address of the authorized address.
    /// @param caller Address of the address that authorized the target.
    event AuthorizedAddressAdded(address indexed target, address indexed caller);

    /// @dev Emitted when a currently authorized address is unauthorized.
    /// @param target Address of the authorized address.
    /// @param caller Address of the address that authorized the target.
    event AuthorizedAddressRemoved(address indexed target, address indexed caller);

    /// @dev Authorizes an address.
    /// @param target Address to authorize.
    function addAuthorizedAddress(address target) external virtual;

    /// @dev Removes authorizion of an address.
    /// @param target Address to remove authorization from.
    function removeAuthorizedAddress(address target) external virtual;

    /// @dev Removes authorizion of an address.
    /// @param target Address to remove authorization from.
    /// @param index Index of target in authorities array.
    function removeAuthorizedAddressAtIndex(address target, uint256 index) external virtual;

    /// @dev Gets all authorized addresses.
    /// @return Array of authorized addresses.
    function getAuthorizedAddresses() external view virtual returns (address[] memory);
}

File 12 of 13 : Ownable.sol
// SPDX-License-Identifier: Apache 2.0
/*
  Copyright 2019 ZeroEx Intl.
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
    http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/

pragma solidity >=0.5.9 <0.9.0;

import "./interfaces/IOwnable.sol";

abstract contract Ownable is IOwnable {
    /// @dev The owner of this contract.
    /// @return 0 The owner address.
    address public owner;

    constructor(address newOwner) {
        owner = newOwner;
    }

    modifier onlyOwner() {
        _assertSenderIsOwner();
        _;
    }

    /// @dev Change the owner of this contract.
    /// @param newOwner New owner address.
    function transferOwnership(address newOwner) public override onlyOwner {
        require(newOwner != address(0), "INPUT_ADDRESS_NULL_ERROR");
        owner = newOwner;
        emit OwnershipTransferred(msg.sender, newOwner);
    }

    function _assertSenderIsOwner() internal view {
        require(msg.sender == owner, "CALLER_NOT_OWNER_ERROR");
    }
}

File 13 of 13 : IOwnable.sol
// SPDX-License-Identifier: Apache 2.0
/*
  Copyright 2019 ZeroEx Intl.
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
    http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
*/

pragma solidity >=0.5.9 <0.9.0;

abstract contract IOwnable {
    /// @dev Emitted by Ownable when ownership is transferred.
    /// @param previousOwner The previous owner of the contract.
    /// @param newOwner The new owner of the contract.
    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /// @dev Transfers ownership of the contract to a new address.
    /// @param newOwner The address that will become the owner.
    function transferOwnership(address newOwner) public virtual;
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"stakingImplementation","type":"address"},{"internalType":"address","name":"newOwner","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"target","type":"address"},{"indexed":true,"internalType":"address","name":"caller","type":"address"}],"name":"AuthorizedAddressAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"target","type":"address"},{"indexed":true,"internalType":"address","name":"caller","type":"address"}],"name":"AuthorizedAddressRemoved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"newStakingContractAddress","type":"address"}],"name":"StakingContractAttachedToProxy","type":"event"},{"anonymous":false,"inputs":[],"name":"StakingContractDetachedFromProxy","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"addAuthorizedAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"aggregatedStatsByEpoch","outputs":[{"internalType":"uint256","name":"rewardsAvailable","type":"uint256"},{"internalType":"uint256","name":"numPoolsToFinalize","type":"uint256"},{"internalType":"uint256","name":"totalFeesCollected","type":"uint256"},{"internalType":"uint256","name":"totalWeightedStake","type":"uint256"},{"internalType":"uint256","name":"totalRewardsFinalized","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"assertValidStorageParams","outputs":[],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"stakingImplementation","type":"address"}],"name":"attachStakingContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"authorities","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"authorized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes[]","name":"data","type":"bytes[]"}],"name":"batchExecute","outputs":[{"internalType":"bytes[]","name":"batchReturnData","type":"bytes[]"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"cobbDouglasAlphaDenominator","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cobbDouglasAlphaNumerator","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"currentEpochStartTimeInSeconds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"detachStakingContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"epochDurationInSeconds","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAuthorizedAddresses","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"grgReservedForPoolRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minimumPoolStake","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"poolIdByRbPoolAccount","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"poolStatsByEpoch","outputs":[{"internalType":"uint256","name":"feesCollected","type":"uint256"},{"internalType":"uint256","name":"weightedStake","type":"uint256"},{"internalType":"uint256","name":"membersStake","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"}],"name":"removeAuthorizedAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"removeAuthorizedAddressAtIndex","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardDelegatedStakeWeight","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"rewardsByPoolId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stakingContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"validPops","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]

60806040523480156200001157600080fd5b5060405162001bfd38038062001bfd833981016040819052620000349162000760565b600080546001600160a01b0319166001600160a01b0383161790556200005a336200007a565b6200006582620001dd565b62000072336000620002dc565b50506200081d565b6001600160a01b038116620000d65760405162461bcd60e51b815260206004820152601f60248201527f415554484f52495a41424c455f4e554c4c5f414444524553535f4552524f520060448201526064015b60405180910390fd5b6001600160a01b03811660009081526001602052604090205460ff16156200014f5760405162461bcd60e51b815260206004820152602560248201527f415554484f52495a41424c455f414c52454144595f415554484f52495a45445f60448201526422a92927a960d91b6064820152608401620000cd565b6001600160a01b0381166000818152600160208190526040808320805460ff19168317905560028054928301815583527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace90910180546001600160a01b03191684179055513392917f3147867c59d17e8fa9d522465651d44aae0a9e38f902f3475b97e58072f0ed4c91a350565b600380546001600160a01b0319166001600160a01b0383169081179091556040519081527f048368388f801041f7690185c4e28b6f3505c740c47be8ac104b55df666bfc849060200160405180910390a160035460408051600481526024810182526020810180516001600160e01b03166370e39c9560e11b179052905160009283926001600160a01b039091169162000278919062000798565b600060405180830381855af49150503d8060008114620002b5576040519150601f19603f3d011682016040523d82523d6000602084013e620002ba565b606091505b509150915081620002cd57805160208201fd5b620002d76200055f565b505050565b6001600160a01b03821660009081526001602052604090205460ff16620003585760405162461bcd60e51b815260206004820152602960248201527f415554484f52495a41424c455f414444524553535f4e4f545f415554484f52496044820152682d22a22fa2a92927a960b91b6064820152608401620000cd565b6002548110620003ba5760405162461bcd60e51b815260206004820152602660248201527f415554484f52495a41424c455f494e4445585f4f55545f4f465f424f554e44536044820152652fa2a92927a960d11b6064820152608401620000cd565b816001600160a01b031660028281548110620003da57620003da620007c9565b6000918252602090912001546001600160a01b0316146200044a5760405162461bcd60e51b815260206004820152602360248201527f415554484f52495a41424c455f414444524553535f4d49534d415443485f45526044820152622927a960e91b6064820152608401620000cd565b6001600160a01b0382166000908152600160208190526040909120805460ff191690556002805490916200047e91620007df565b81548110620004915762000491620007c9565b600091825260209091200154600280546001600160a01b039092169183908110620004c057620004c0620007c9565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600280548062000502576200050262000807565b600082815260208120820160001990810180546001600160a01b031916905590910190915560405133916001600160a01b038516917f1f32c1b084e2de0713b8fb16bd46bb9df710a3dbeae2f3ca93af46e016dcc6b09190a35050565b6010546206978081108015906200057957506276a7008111155b620005da5760405162461bcd60e51b815260206004820152602a60248201527f5354414b494e475f50524f58595f494e56414c49445f45504f43485f445552416044820152692a24a7a72fa2a92927a960b11b6064820152608401620000cd565b60135463ffffffff640100000000820481169116811080159062000603575063ffffffff811615155b620006685760405162461bcd60e51b815260206004820152602e60248201527f5354414b494e475f50524f58595f494e56414c49445f434f42425f444f55474c60448201526d20a9afa0a6282420afa2a92927a960911b6064820152608401620000cd565b601154620f424063ffffffff9091161115620006d85760405162461bcd60e51b815260206004820152602860248201527f5354414b494e475f50524f58595f494e56414c49445f5354414b455f57454947604482015267242a2fa2a92927a960c11b6064820152608401620000cd565b600260125410156200073f5760405162461bcd60e51b815260206004820152602960248201527f5354414b494e475f50524f58595f494e56414c49445f4d494e494d554d5f535460448201526820a5a2afa2a92927a960b91b6064820152608401620000cd565b5050565b80516001600160a01b03811681146200075b57600080fd5b919050565b600080604083850312156200077457600080fd5b6200077f8362000743565b91506200078f6020840162000743565b90509250929050565b6000825160005b81811015620007bb57602081860181015185830152016200079f565b506000920191825250919050565b634e487b7160e01b600052603260045260246000fd5b818103818111156200080157634e487b7160e01b600052601160045260246000fd5b92915050565b634e487b7160e01b600052603160045260246000fd5b6113d0806200082d6000396000f3fe608060405234801561001057600080fd5b506004361061018e5760003560e01c8063856a65eb116100de578063c6f3a42711610097578063e0ee036e11610071578063e0ee036e146104ee578063e8eeb3f8146104fe578063ee99205c14610516578063f2fde38b146105295761018e565b8063c6f3a427146104c8578063d14dc231146104d0578063d39de6e9146104d95761018e565b8063856a65eb146104365780638da5cb5b146104565780639ad2674414610469578063a26171e21461047c578063b918161114610485578063c18c9141146104a85761018e565b8063587da0231161014b578063707129391161012557806370712939146103d557806376671808146103e85780637fa140c7146103f157806381666796146104115761018e565b8063587da023146103a257806363403801146103b957806366615d56146103c25761018e565b80632a94c2791461026a57806337b006a6146102c457806338229d93146102cc57806342f1181e14610331578063494503d414610344578063540c2d531461036f575b6003546001600160a01b0316806101ec5760405162461bcd60e51b815260206004820152601a60248201527f5354414b494e475f414444524553535f4e554c4c5f4552524f5200000000000060448201526064015b60405180910390fd5b600080826001600160a01b031660003660405161020a929190611099565b600060405180830381855af49150503d8060008114610245576040519150601f19603f3d011682016040523d82523d6000602084013e61024a565b606091505b5091509150816000811461026057815182602001f35b815182602001fd5b005b6102a46102783660046110a9565b601460209081526000928352604080842090915290825290208054600182015460029092015490919083565b604080519384526020840192909252908201526060015b60405180910390f35b61026861053c565b6103096102da3660046110cb565b601560205260009081526040902080546001820154600283015460038401546004909401549293919290919085565b604080519586526020860194909452928401919091526060830152608082015260a0016102bb565b61026861033f366004611100565b61057f565b6103576103523660046110cb565b610593565b6040516001600160a01b0390911681526020016102bb565b61039261037d366004611100565b600f6020526000908152604090205460ff1681565b60405190151581526020016102bb565b6103ab600c5481565b6040519081526020016102bb565b6103ab60105481565b6102686103d0366004611100565b6105bd565b6102686103e3366004611100565b6105ce565b6103ab600b5481565b6103ab6103ff366004611100565b60086020526000908152604090205481565b6013546104219063ffffffff1681565b60405163ffffffff90911681526020016102bb565b610449610444366004611122565b61069a565b6040516102bb91906111bb565b600054610357906001600160a01b031681565b610268610477366004611235565b61081f565b6103ab60125481565b610392610493366004611100565b60016020526000908152604090205460ff1681565b6103ab6104b63660046110cb565b600a6020526000908152604090205481565b610268610831565b6103ab60165481565b6104e1610a07565b6040516102bb919061125f565b6011546104219063ffffffff1681565b60135461042190640100000000900463ffffffff1681565b600354610357906001600160a01b031681565b610268610537366004611100565b610a69565b610544610b12565b600380546001600160a01b03191690556040517f6caedcb22a5c22c8ebd0caf751fec1228a6e006e6ee37169321e02d31ecc818390600090a1565b610587610b84565b61059081610bd7565b50565b600281815481106105a357600080fd5b6000918252602090912001546001600160a01b0316905081565b6105c5610b12565b61059081610d32565b6105d6610b84565b6001600160a01b03811660009081526001602052604090205460ff166106365760405162461bcd60e51b815260206004820152601560248201527415105491d15517d393d517d055551213d492569151605a1b60448201526064016101e3565b60005b60025481101561068457816001600160a01b031660028281548110610660576106606112ac565b6000918252602090912001546001600160a01b031603610688576106848282610e2a565b5050565b80610692816112d8565b915050610639565b6060600081838067ffffffffffffffff8111156106b9576106b96112f1565b6040519080825280602002602001820160405280156106ec57816020015b60608152602001906001900390816106d75790505b506003549094506001600160a01b0316806107495760405162461bcd60e51b815260206004820152601a60248201527f5354414b494e475f414444524553535f4e554c4c5f4552524f5200000000000060448201526064016101e3565b60005b82811461081357816001600160a01b031688888381811061076f5761076f6112ac565b90506020028101906107819190611307565b60405161078f929190611099565b600060405180830381855af49150503d80600081146107ca576040519150601f19603f3d011682016040523d82523d6000602084013e6107cf565b606091505b509095509350846107e257835184602001fd5b838682815181106107f5576107f56112ac565b6020026020010181905250808061080b906112d8565b91505061074c565b50505050505b92915050565b610827610b84565b6106848282610e2a565b60105462069780811080159061084a57506276a7008111155b6108a95760405162461bcd60e51b815260206004820152602a60248201527f5354414b494e475f50524f58595f494e56414c49445f45504f43485f445552416044820152692a24a7a72fa2a92927a960b11b60648201526084016101e3565b60135463ffffffff64010000000082048116911681108015906108d1575063ffffffff811615155b6109345760405162461bcd60e51b815260206004820152602e60248201527f5354414b494e475f50524f58595f494e56414c49445f434f42425f444f55474c60448201526d20a9afa0a6282420afa2a92927a960911b60648201526084016101e3565b601154620f424063ffffffff90911611156109a25760405162461bcd60e51b815260206004820152602860248201527f5354414b494e475f50524f58595f494e56414c49445f5354414b455f57454947604482015267242a2fa2a92927a960c11b60648201526084016101e3565b600260125410156106845760405162461bcd60e51b815260206004820152602960248201527f5354414b494e475f50524f58595f494e56414c49445f4d494e494d554d5f535460448201526820a5a2afa2a92927a960b91b60648201526084016101e3565b60606002805480602002602001604051908101604052809291908181526020018280548015610a5f57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311610a41575b5050505050905090565b610a71610b84565b6001600160a01b038116610ac75760405162461bcd60e51b815260206004820152601860248201527f494e5055545f414444524553535f4e554c4c5f4552524f52000000000000000060448201526064016101e3565b600080546001600160a01b0319166001600160a01b0383169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b3360009081526001602052604090205460ff16610b825760405162461bcd60e51b815260206004820152602860248201527f415554484f52495a41424c455f53454e4445525f4e4f545f415554484f52495a60448201526722a22fa2a92927a960c11b60648201526084016101e3565b565b6000546001600160a01b03163314610b825760405162461bcd60e51b815260206004820152601660248201527521a0a62622a92fa727aa2fa7aba722a92fa2a92927a960511b60448201526064016101e3565b6001600160a01b038116610c2d5760405162461bcd60e51b815260206004820152601f60248201527f415554484f52495a41424c455f4e554c4c5f414444524553535f4552524f520060448201526064016101e3565b6001600160a01b03811660009081526001602052604090205460ff1615610ca45760405162461bcd60e51b815260206004820152602560248201527f415554484f52495a41424c455f414c52454144595f415554484f52495a45445f60448201526422a92927a960d91b60648201526084016101e3565b6001600160a01b0381166000818152600160208190526040808320805460ff19168317905560028054928301815583527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace90910180546001600160a01b03191684179055513392917f3147867c59d17e8fa9d522465651d44aae0a9e38f902f3475b97e58072f0ed4c91a350565b600380546001600160a01b0319166001600160a01b0383169081179091556040519081527f048368388f801041f7690185c4e28b6f3505c740c47be8ac104b55df666bfc849060200160405180910390a160035460408051600481526024810182526020810180516001600160e01b03166370e39c9560e11b179052905160009283926001600160a01b0390911691610dcb9190611355565b600060405180830381855af49150503d8060008114610e06576040519150601f19603f3d011682016040523d82523d6000602084013e610e0b565b606091505b509150915081610e1d57805160208201fd5b610e25610831565b505050565b6001600160a01b03821660009081526001602052604090205460ff16610ea45760405162461bcd60e51b815260206004820152602960248201527f415554484f52495a41424c455f414444524553535f4e4f545f415554484f52496044820152682d22a22fa2a92927a960b91b60648201526084016101e3565b6002548110610f045760405162461bcd60e51b815260206004820152602660248201527f415554484f52495a41424c455f494e4445585f4f55545f4f465f424f554e44536044820152652fa2a92927a960d11b60648201526084016101e3565b816001600160a01b031660028281548110610f2157610f216112ac565b6000918252602090912001546001600160a01b031614610f8f5760405162461bcd60e51b815260206004820152602360248201527f415554484f52495a41424c455f414444524553535f4d49534d415443485f45526044820152622927a960e91b60648201526084016101e3565b6001600160a01b0382166000908152600160208190526040909120805460ff19169055600280549091610fc191611371565b81548110610fd157610fd16112ac565b600091825260209091200154600280546001600160a01b039092169183908110610ffd57610ffd6112ac565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600280548061103c5761103c611384565b600082815260208120820160001990810180546001600160a01b031916905590910190915560405133916001600160a01b038516917f1f32c1b084e2de0713b8fb16bd46bb9df710a3dbeae2f3ca93af46e016dcc6b09190a35050565b8183823760009101908152919050565b600080604083850312156110bc57600080fd5b50508035926020909101359150565b6000602082840312156110dd57600080fd5b5035919050565b80356001600160a01b03811681146110fb57600080fd5b919050565b60006020828403121561111257600080fd5b61111b826110e4565b9392505050565b6000806020838503121561113557600080fd5b823567ffffffffffffffff8082111561114d57600080fd5b818501915085601f83011261116157600080fd5b81358181111561117057600080fd5b8660208260051b850101111561118557600080fd5b60209290920196919550909350505050565b60005b838110156111b257818101518382015260200161119a565b50506000910152565b6000602080830181845280855180835260408601915060408160051b870101925083870160005b8281101561122857878503603f1901845281518051808752611209818989018a8501611197565b601f01601f1916959095018601945092850192908501906001016111e2565b5092979650505050505050565b6000806040838503121561124857600080fd5b611251836110e4565b946020939093013593505050565b6020808252825182820181905260009190848201906040850190845b818110156112a05783516001600160a01b03168352928401929184019160010161127b565b50909695505050505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016112ea576112ea6112c2565b5060010190565b634e487b7160e01b600052604160045260246000fd5b6000808335601e1984360301811261131e57600080fd5b83018035915067ffffffffffffffff82111561133957600080fd5b60200191503681900382131561134e57600080fd5b9250929050565b60008251611367818460208701611197565b9190910192915050565b81810381811115610819576108196112c2565b634e487b7160e01b600052603160045260246000fdfea26469706673582212200b9feb2e82bdb6b7b78f13eee4bda9c07a6f9f0b6996987aea8025b2303d330a64736f6c6343000811003300000000000000000000000027a2b90f5245aefe3e6f7cac12df98be2737d0fa000000000000000000000000080f08076e8eadc66006c3cbfed28a34918a1fa6

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061018e5760003560e01c8063856a65eb116100de578063c6f3a42711610097578063e0ee036e11610071578063e0ee036e146104ee578063e8eeb3f8146104fe578063ee99205c14610516578063f2fde38b146105295761018e565b8063c6f3a427146104c8578063d14dc231146104d0578063d39de6e9146104d95761018e565b8063856a65eb146104365780638da5cb5b146104565780639ad2674414610469578063a26171e21461047c578063b918161114610485578063c18c9141146104a85761018e565b8063587da0231161014b578063707129391161012557806370712939146103d557806376671808146103e85780637fa140c7146103f157806381666796146104115761018e565b8063587da023146103a257806363403801146103b957806366615d56146103c25761018e565b80632a94c2791461026a57806337b006a6146102c457806338229d93146102cc57806342f1181e14610331578063494503d414610344578063540c2d531461036f575b6003546001600160a01b0316806101ec5760405162461bcd60e51b815260206004820152601a60248201527f5354414b494e475f414444524553535f4e554c4c5f4552524f5200000000000060448201526064015b60405180910390fd5b600080826001600160a01b031660003660405161020a929190611099565b600060405180830381855af49150503d8060008114610245576040519150601f19603f3d011682016040523d82523d6000602084013e61024a565b606091505b5091509150816000811461026057815182602001f35b815182602001fd5b005b6102a46102783660046110a9565b601460209081526000928352604080842090915290825290208054600182015460029092015490919083565b604080519384526020840192909252908201526060015b60405180910390f35b61026861053c565b6103096102da3660046110cb565b601560205260009081526040902080546001820154600283015460038401546004909401549293919290919085565b604080519586526020860194909452928401919091526060830152608082015260a0016102bb565b61026861033f366004611100565b61057f565b6103576103523660046110cb565b610593565b6040516001600160a01b0390911681526020016102bb565b61039261037d366004611100565b600f6020526000908152604090205460ff1681565b60405190151581526020016102bb565b6103ab600c5481565b6040519081526020016102bb565b6103ab60105481565b6102686103d0366004611100565b6105bd565b6102686103e3366004611100565b6105ce565b6103ab600b5481565b6103ab6103ff366004611100565b60086020526000908152604090205481565b6013546104219063ffffffff1681565b60405163ffffffff90911681526020016102bb565b610449610444366004611122565b61069a565b6040516102bb91906111bb565b600054610357906001600160a01b031681565b610268610477366004611235565b61081f565b6103ab60125481565b610392610493366004611100565b60016020526000908152604090205460ff1681565b6103ab6104b63660046110cb565b600a6020526000908152604090205481565b610268610831565b6103ab60165481565b6104e1610a07565b6040516102bb919061125f565b6011546104219063ffffffff1681565b60135461042190640100000000900463ffffffff1681565b600354610357906001600160a01b031681565b610268610537366004611100565b610a69565b610544610b12565b600380546001600160a01b03191690556040517f6caedcb22a5c22c8ebd0caf751fec1228a6e006e6ee37169321e02d31ecc818390600090a1565b610587610b84565b61059081610bd7565b50565b600281815481106105a357600080fd5b6000918252602090912001546001600160a01b0316905081565b6105c5610b12565b61059081610d32565b6105d6610b84565b6001600160a01b03811660009081526001602052604090205460ff166106365760405162461bcd60e51b815260206004820152601560248201527415105491d15517d393d517d055551213d492569151605a1b60448201526064016101e3565b60005b60025481101561068457816001600160a01b031660028281548110610660576106606112ac565b6000918252602090912001546001600160a01b031603610688576106848282610e2a565b5050565b80610692816112d8565b915050610639565b6060600081838067ffffffffffffffff8111156106b9576106b96112f1565b6040519080825280602002602001820160405280156106ec57816020015b60608152602001906001900390816106d75790505b506003549094506001600160a01b0316806107495760405162461bcd60e51b815260206004820152601a60248201527f5354414b494e475f414444524553535f4e554c4c5f4552524f5200000000000060448201526064016101e3565b60005b82811461081357816001600160a01b031688888381811061076f5761076f6112ac565b90506020028101906107819190611307565b60405161078f929190611099565b600060405180830381855af49150503d80600081146107ca576040519150601f19603f3d011682016040523d82523d6000602084013e6107cf565b606091505b509095509350846107e257835184602001fd5b838682815181106107f5576107f56112ac565b6020026020010181905250808061080b906112d8565b91505061074c565b50505050505b92915050565b610827610b84565b6106848282610e2a565b60105462069780811080159061084a57506276a7008111155b6108a95760405162461bcd60e51b815260206004820152602a60248201527f5354414b494e475f50524f58595f494e56414c49445f45504f43485f445552416044820152692a24a7a72fa2a92927a960b11b60648201526084016101e3565b60135463ffffffff64010000000082048116911681108015906108d1575063ffffffff811615155b6109345760405162461bcd60e51b815260206004820152602e60248201527f5354414b494e475f50524f58595f494e56414c49445f434f42425f444f55474c60448201526d20a9afa0a6282420afa2a92927a960911b60648201526084016101e3565b601154620f424063ffffffff90911611156109a25760405162461bcd60e51b815260206004820152602860248201527f5354414b494e475f50524f58595f494e56414c49445f5354414b455f57454947604482015267242a2fa2a92927a960c11b60648201526084016101e3565b600260125410156106845760405162461bcd60e51b815260206004820152602960248201527f5354414b494e475f50524f58595f494e56414c49445f4d494e494d554d5f535460448201526820a5a2afa2a92927a960b91b60648201526084016101e3565b60606002805480602002602001604051908101604052809291908181526020018280548015610a5f57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311610a41575b5050505050905090565b610a71610b84565b6001600160a01b038116610ac75760405162461bcd60e51b815260206004820152601860248201527f494e5055545f414444524553535f4e554c4c5f4552524f52000000000000000060448201526064016101e3565b600080546001600160a01b0319166001600160a01b0383169081178255604051909133917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a350565b3360009081526001602052604090205460ff16610b825760405162461bcd60e51b815260206004820152602860248201527f415554484f52495a41424c455f53454e4445525f4e4f545f415554484f52495a60448201526722a22fa2a92927a960c11b60648201526084016101e3565b565b6000546001600160a01b03163314610b825760405162461bcd60e51b815260206004820152601660248201527521a0a62622a92fa727aa2fa7aba722a92fa2a92927a960511b60448201526064016101e3565b6001600160a01b038116610c2d5760405162461bcd60e51b815260206004820152601f60248201527f415554484f52495a41424c455f4e554c4c5f414444524553535f4552524f520060448201526064016101e3565b6001600160a01b03811660009081526001602052604090205460ff1615610ca45760405162461bcd60e51b815260206004820152602560248201527f415554484f52495a41424c455f414c52454144595f415554484f52495a45445f60448201526422a92927a960d91b60648201526084016101e3565b6001600160a01b0381166000818152600160208190526040808320805460ff19168317905560028054928301815583527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace90910180546001600160a01b03191684179055513392917f3147867c59d17e8fa9d522465651d44aae0a9e38f902f3475b97e58072f0ed4c91a350565b600380546001600160a01b0319166001600160a01b0383169081179091556040519081527f048368388f801041f7690185c4e28b6f3505c740c47be8ac104b55df666bfc849060200160405180910390a160035460408051600481526024810182526020810180516001600160e01b03166370e39c9560e11b179052905160009283926001600160a01b0390911691610dcb9190611355565b600060405180830381855af49150503d8060008114610e06576040519150601f19603f3d011682016040523d82523d6000602084013e610e0b565b606091505b509150915081610e1d57805160208201fd5b610e25610831565b505050565b6001600160a01b03821660009081526001602052604090205460ff16610ea45760405162461bcd60e51b815260206004820152602960248201527f415554484f52495a41424c455f414444524553535f4e4f545f415554484f52496044820152682d22a22fa2a92927a960b91b60648201526084016101e3565b6002548110610f045760405162461bcd60e51b815260206004820152602660248201527f415554484f52495a41424c455f494e4445585f4f55545f4f465f424f554e44536044820152652fa2a92927a960d11b60648201526084016101e3565b816001600160a01b031660028281548110610f2157610f216112ac565b6000918252602090912001546001600160a01b031614610f8f5760405162461bcd60e51b815260206004820152602360248201527f415554484f52495a41424c455f414444524553535f4d49534d415443485f45526044820152622927a960e91b60648201526084016101e3565b6001600160a01b0382166000908152600160208190526040909120805460ff19169055600280549091610fc191611371565b81548110610fd157610fd16112ac565b600091825260209091200154600280546001600160a01b039092169183908110610ffd57610ffd6112ac565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600280548061103c5761103c611384565b600082815260208120820160001990810180546001600160a01b031916905590910190915560405133916001600160a01b038516917f1f32c1b084e2de0713b8fb16bd46bb9df710a3dbeae2f3ca93af46e016dcc6b09190a35050565b8183823760009101908152919050565b600080604083850312156110bc57600080fd5b50508035926020909101359150565b6000602082840312156110dd57600080fd5b5035919050565b80356001600160a01b03811681146110fb57600080fd5b919050565b60006020828403121561111257600080fd5b61111b826110e4565b9392505050565b6000806020838503121561113557600080fd5b823567ffffffffffffffff8082111561114d57600080fd5b818501915085601f83011261116157600080fd5b81358181111561117057600080fd5b8660208260051b850101111561118557600080fd5b60209290920196919550909350505050565b60005b838110156111b257818101518382015260200161119a565b50506000910152565b6000602080830181845280855180835260408601915060408160051b870101925083870160005b8281101561122857878503603f1901845281518051808752611209818989018a8501611197565b601f01601f1916959095018601945092850192908501906001016111e2565b5092979650505050505050565b6000806040838503121561124857600080fd5b611251836110e4565b946020939093013593505050565b6020808252825182820181905260009190848201906040850190845b818110156112a05783516001600160a01b03168352928401929184019160010161127b565b50909695505050505050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016112ea576112ea6112c2565b5060010190565b634e487b7160e01b600052604160045260246000fd5b6000808335601e1984360301811261131e57600080fd5b83018035915067ffffffffffffffff82111561133957600080fd5b60200191503681900382131561134e57600080fd5b9250929050565b60008251611367818460208701611197565b9190910192915050565b81810381811115610819576108196112c2565b634e487b7160e01b600052603160045260246000fdfea26469706673582212200b9feb2e82bdb6b7b78f13eee4bda9c07a6f9f0b6996987aea8025b2303d330a64736f6c63430008110033

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

00000000000000000000000027a2b90f5245aefe3e6f7cac12df98be2737d0fa000000000000000000000000080f08076e8eadc66006c3cbfed28a34918a1fa6

-----Decoded View---------------
Arg [0] : stakingImplementation (address): 0x27A2b90f5245aeFE3E6F7CAc12df98Be2737D0fa
Arg [1] : newOwner (address): 0x080f08076e8EAdC66006C3CbFEd28a34918A1fA6

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000027a2b90f5245aefe3e6f7cac12df98be2737d0fa
Arg [1] : 000000000000000000000000080f08076e8eadc66006c3cbfed28a34918a1fa6


Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.