Mumbai Testnet

Contract

0x75e752887f63add35430991119fAAC6eaf1d3e4b

Overview

MATIC Balance

Multichain Info

N/A
Transaction Hash
Method
Block
From
To
Value
Claim Block Rewa...240107572022-01-18 9:46:35851 days ago1642499195IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100043145
Propose240106352022-01-18 9:40:39851 days ago1642498839IN
0x75e75288...eaf1d3e4b
0 MATIC0.0090697945
Propose240106352022-01-18 9:40:39851 days ago1642498839IN
0x75e75288...eaf1d3e4b
0 MATIC0.010590745
Propose240106352022-01-18 9:40:39851 days ago1642498839IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100905345
Claim Block Rewa...240104552022-01-18 9:31:55851 days ago1642498315IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100043145
Propose240103352022-01-18 9:26:43851 days ago1642498003IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100440945
Propose240103352022-01-18 9:26:43851 days ago1642498003IN
0x75e75288...eaf1d3e4b
0 MATIC0.0096917845
Propose240103342022-01-18 9:26:39851 days ago1642497999IN
0x75e75288...eaf1d3e4b
0 MATIC0.0101805345
Claim Block Rewa...240101552022-01-18 9:17:19851 days ago1642497439IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100043145
Propose240100392022-01-18 9:13:19851 days ago1642497199IN
0x75e75288...eaf1d3e4b
0 MATIC0.0089797945
Propose240100372022-01-18 9:13:15851 days ago1642497195IN
0x75e75288...eaf1d3e4b
0 MATIC0.010590745
Propose240100372022-01-18 9:13:15851 days ago1642497195IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100545345
Claim Block Rewa...240098542022-01-18 9:04:47851 days ago1642496687IN
0x75e75288...eaf1d3e4b
0 MATIC0.0100043145
Propose240097372022-01-18 8:58:43851 days ago1642496323IN
0x75e75288...eaf1d3e4b
0 MATIC0.0091944945
Claim Block Rewa...240083592022-01-18 7:54:15851 days ago1642492455IN
0x75e75288...eaf1d3e4b
0 MATIC0.000726653
Propose240082492022-01-18 7:50:15851 days ago1642492215IN
0x75e75288...eaf1d3e4b
0 MATIC0.000663493
Propose240082432022-01-18 7:49:51851 days ago1642492191IN
0x75e75288...eaf1d3e4b
0 MATIC0.000700043
Propose240082422022-01-18 7:49:47851 days ago1642492187IN
0x75e75288...eaf1d3e4b
0 MATIC0.00067033
Claim Block Rewa...240080612022-01-18 7:39:43851 days ago1642491583IN
0x75e75288...eaf1d3e4b
0 MATIC0.000666953
Propose240079722022-01-18 7:36:41851 days ago1642491401IN
0x75e75288...eaf1d3e4b
0 MATIC0.000612963
Claim Block Rewa...240077712022-01-18 7:27:39851 days ago1642490859IN
0x75e75288...eaf1d3e4b
0 MATIC0.000666953
Propose240076622022-01-18 7:21:45851 days ago1642490505IN
0x75e75288...eaf1d3e4b
0 MATIC0.000663493
Propose240076602022-01-18 7:21:41851 days ago1642490501IN
0x75e75288...eaf1d3e4b
0 MATIC0.000646113
Propose240076532022-01-18 7:21:27851 days ago1642490487IN
0x75e75288...eaf1d3e4b
0 MATIC0.00067873
Claim Block Rewa...240074742022-01-18 7:13:09851 days ago1642489989IN
0x75e75288...eaf1d3e4b
0 MATIC0.000666953
View all transactions

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

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

Contract Name:
BlockManager

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 30000 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 22 : BlockManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "./interface/IBlockManager.sol";
import "./interface/IStakeManager.sol";
import "./interface/IRewardManager.sol";
import "./interface/IVoteManager.sol";
import "./interface/IAssetManager.sol";
import "../randomNumber/IRandomNoProvider.sol";
import "./storage/BlockStorage.sol";
import "./parameters/child/BlockManagerParams.sol";
import "./StateManager.sol";
import "../lib/Random.sol";
import "../Initializable.sol";

contract BlockManager is Initializable, BlockStorage, StateManager, BlockManagerParams, IBlockManager {
    IStakeManager public stakeManager;
    IRewardManager public rewardManager;
    IVoteManager public voteManager;
    IAssetManager public assetManager;
    IRandomNoProvider public randomNoProvider;

    event BlockConfirmed(uint32 epoch, uint32 stakerId, uint32[] medians, uint256 timestamp);

    event Proposed(uint32 epoch, uint32 stakerId, uint32[] medians, uint256 iteration, uint32 biggestStakerId, uint256 timestamp);

    function initialize(
        address stakeManagerAddress,
        address rewardManagerAddress,
        address voteManagerAddress,
        address assetManagerAddress,
        address randomNoManagerAddress
    ) external initializer onlyRole(DEFAULT_ADMIN_ROLE) {
        stakeManager = IStakeManager(stakeManagerAddress);
        rewardManager = IRewardManager(rewardManagerAddress);
        voteManager = IVoteManager(voteManagerAddress);
        assetManager = IAssetManager(assetManagerAddress);
        randomNoProvider = IRandomNoProvider(randomNoManagerAddress);
    }

    // elected proposer proposes block.
    //we use a probabilistic method to elect stakers weighted by stake
    // protocol works like this.
    //select a staker pseudorandomly (not weighted by anything)
    // that staker then tosses a biased coin.
    //bias = hisStake/biggestStake. if its heads, he can propose block
    // end of iteration. try next iteration
    // note that only one staker or no stakers selected in each iteration.
    // stakers elected in higher iterations can also propose hoping that
    // stakers with lower iteration do not propose for some reason
    function propose(
        uint32 epoch,
        uint32[] memory medians,
        uint256 iteration,
        uint32 biggestStakerId
    ) external initialized checkEpochAndState(State.Propose, epoch, epochLength) {
        uint32 proposerId = stakeManager.getStakerId(msg.sender);
        require(_isElectedProposer(iteration, biggestStakerId, proposerId, epoch), "not elected");
        require(stakeManager.getStake(proposerId) >= minStake, "stake below minimum stake");
        //staker can just skip commit/reveal and only propose every epoch to avoid penalty.
        //following line is to prevent that
        require(voteManager.getEpochLastRevealed(proposerId) == epoch, "Cannot propose without revealing");
        require(epochLastProposed[proposerId] != epoch, "Already proposed");
        require(medians.length == assetManager.getNumActiveCollections(), "invalid block proposed");

        uint256 biggestStake = voteManager.getStakeSnapshot(epoch, biggestStakerId);
        if (sortedProposedBlockIds[epoch].length == 0) numProposedBlocks = 0;
        proposedBlocks[epoch][numProposedBlocks] = Structs.Block(true, proposerId, medians, iteration, biggestStake);
        bool isAdded = _insertAppropriately(epoch, numProposedBlocks, iteration, biggestStake);
        epochLastProposed[proposerId] = epoch;
        if (isAdded) {
            numProposedBlocks = numProposedBlocks + 1;
        }
        emit Proposed(epoch, proposerId, medians, iteration, biggestStakerId, block.timestamp);
    }

    //anyone can give sorted votes in batches in dispute state
    function giveSorted(
        uint32 epoch,
        uint16 collectionId,
        uint32[] memory sortedStakers
    ) external initialized checkEpochAndState(State.Dispute, epoch, epochLength) {
        uint256 accWeight = disputes[epoch][msg.sender].accWeight;
        uint256 accProd = disputes[epoch][msg.sender].accProd;
        uint32 lastVisitedStaker = disputes[epoch][msg.sender].lastVisitedStaker;
        uint16 collectionIndex = assetManager.getCollectionIndex(collectionId);
        if (disputes[epoch][msg.sender].accWeight == 0) {
            disputes[epoch][msg.sender].collectionId = collectionId;
        } else {
            require(disputes[epoch][msg.sender].collectionId == collectionId, "AssetId not matching");
            // require(disputes[epoch][msg.sender].median == 0, "median already found");
        }
        for (uint32 i = 0; i < sortedStakers.length; i++) {
            require(sortedStakers[i] > lastVisitedStaker, "sortedStaker <= LVS "); // LVS : Last Visited Staker
            lastVisitedStaker = sortedStakers[i];
            // slither-disable-next-line calls-loop
            Structs.Vote memory vote = voteManager.getVote(lastVisitedStaker);
            require(vote.epoch == epoch, "staker didnt vote in this epoch");

            uint48 value = vote.values[collectionIndex - 1];
            // slither-disable-next-line calls-loop
            uint256 influence = voteManager.getInfluenceSnapshot(epoch, lastVisitedStaker);
            accProd = accProd + value * influence;
            accWeight = accWeight + influence;
        }
        disputes[epoch][msg.sender].lastVisitedStaker = lastVisitedStaker;
        disputes[epoch][msg.sender].accWeight = accWeight;
        disputes[epoch][msg.sender].accProd = accProd;
    }

    // //if any mistake made during giveSorted, resetDispute and start again
    function resetDispute(uint32 epoch) external initialized checkEpochAndState(State.Dispute, epoch, epochLength) {
        disputes[epoch][msg.sender] = Structs.Dispute(0, 0, 0, 0);
    }

    //O(1)
    function claimBlockReward() external initialized checkState(State.Confirm, epochLength) {
        uint32 epoch = _getEpoch(epochLength);
        uint32 stakerId = stakeManager.getStakerId(msg.sender);
        require(stakerId > 0, "Structs.Staker does not exist");
        require(blocks[epoch].proposerId == 0, "Block already confirmed");

        uint16[] memory deactivatedCollections = assetManager.getPendingDeactivations();
        if (sortedProposedBlockIds[epoch].length == 0 || blockIndexToBeConfirmed == -1) {
            assetManager.executePendingDeactivations(epoch);
            return;
        }
        uint32 proposerId = proposedBlocks[epoch][sortedProposedBlockIds[epoch][uint8(blockIndexToBeConfirmed)]].proposerId;
        require(proposerId == stakerId, "Block Proposer mismatches");
        _confirmBlock(epoch, deactivatedCollections, proposerId);
    }

    function confirmPreviousEpochBlock(uint32 stakerId) external override initialized onlyRole(BLOCK_CONFIRMER_ROLE) {
        uint32 epoch = _getEpoch(epochLength);
        uint16[] memory deactivatedCollections = assetManager.getPendingDeactivations();
        if (sortedProposedBlockIds[epoch - 1].length == 0 || blockIndexToBeConfirmed == -1) {
            assetManager.executePendingDeactivations(epoch);
            return;
        }
        _confirmBlock(epoch - 1, deactivatedCollections, stakerId);
    }

    function disputeBiggestStakeProposed(
        uint32 epoch,
        uint8 blockIndex,
        uint32 correctBiggestStakerId
    ) external initialized checkEpochAndState(State.Dispute, epoch, epochLength) returns (uint32) {
        uint32 blockId = sortedProposedBlockIds[epoch][blockIndex];
        require(proposedBlocks[epoch][blockId].valid, "Block already has been disputed");
        uint256 correctBiggestStake = voteManager.getStakeSnapshot(epoch, correctBiggestStakerId);
        require(correctBiggestStake > proposedBlocks[epoch][blockId].biggestStake, "Invalid dispute : Stake");
        return _executeDispute(epoch, blockIndex, blockId);
    }

    // Complexity O(1)
    function finalizeDispute(uint32 epoch, uint8 blockIndex)
        external
        initialized
        checkEpochAndState(State.Dispute, epoch, epochLength)
        returns (uint32)
    {
        require(disputes[epoch][msg.sender].accWeight == voteManager.getTotalInfluenceRevealed(epoch), "TIR is wrong"); // TIR : total influence revealed
        uint32 median = uint32(disputes[epoch][msg.sender].accProd / disputes[epoch][msg.sender].accWeight);
        require(median > 0, "median can not be zero");
        uint32 blockId = sortedProposedBlockIds[epoch][blockIndex];
        require(proposedBlocks[epoch][blockId].valid, "Block already has been disputed");
        uint16 collectionId = disputes[epoch][msg.sender].collectionId;
        uint16 collectionIndex = assetManager.getCollectionIndex(collectionId);
        require(proposedBlocks[epoch][blockId].medians[collectionIndex - 1] != median, "Block proposed with same medians");
        return _executeDispute(epoch, blockIndex, blockId);
    }

    function getBlock(uint32 epoch) external view override returns (Structs.Block memory _block) {
        return (blocks[epoch]);
    }

    function getProposedBlock(uint32 epoch, uint32 proposedBlock) external view returns (Structs.Block memory _block) {
        _block = proposedBlocks[epoch][proposedBlock];
        return (_block);
    }

    function getNumProposedBlocks(uint32 epoch) external view returns (uint8) {
        return (uint8(sortedProposedBlockIds[epoch].length));
    }

    function isBlockConfirmed(uint32 epoch) external view override returns (bool) {
        return (blocks[epoch].proposerId != 0);
    }

    function _confirmBlock(
        uint32 epoch,
        uint16[] memory deactivatedCollections,
        uint32 stakerId
    ) internal {
        uint32 blockId = sortedProposedBlockIds[epoch][uint8(blockIndexToBeConfirmed)];
        for (uint16 i = uint16(deactivatedCollections.length); i > 0; i--) {
            // slither-disable-next-line calls-loop
            uint16 index = assetManager.getCollectionIndex(deactivatedCollections[i - 1]);
            if (index == proposedBlocks[epoch][blockId].medians.length) {
                proposedBlocks[epoch][blockId].medians.pop();
            } else {
                proposedBlocks[epoch][blockId].medians[index - 1] = proposedBlocks[epoch][blockId].medians[
                    proposedBlocks[epoch][blockId].medians.length - 1
                ];
                proposedBlocks[epoch][blockId].medians.pop();
            }
        }
        blocks[epoch] = proposedBlocks[epoch][blockId];
        emit BlockConfirmed(epoch, proposedBlocks[epoch][blockId].proposerId, proposedBlocks[epoch][blockId].medians, block.timestamp);
        assetManager.executePendingDeactivations(epoch);
        rewardManager.giveBlockReward(stakerId, epoch);
        randomNoProvider.provideSecret(epoch, voteManager.getRandaoHash());
    }

    function _insertAppropriately(
        uint32 epoch,
        uint32 blockId,
        uint256 iteration,
        uint256 biggestStake
    ) internal returns (bool isAdded) {
        uint8 sortedProposedBlockslength = uint8(sortedProposedBlockIds[epoch].length);

        if (sortedProposedBlockslength == 0) {
            sortedProposedBlockIds[epoch].push(0);
            blockIndexToBeConfirmed = 0;
            return true;
        }

        if (proposedBlocks[epoch][sortedProposedBlockIds[epoch][0]].biggestStake > biggestStake) {
            return false;
        }

        if (proposedBlocks[epoch][sortedProposedBlockIds[epoch][0]].biggestStake < biggestStake) {
            for (uint8 i = 0; i < sortedProposedBlockslength; i++) {
                sortedProposedBlockIds[epoch].pop();
            }
            sortedProposedBlockIds[epoch].push(blockId);
            return true;
        }

        for (uint8 i = 0; i < sortedProposedBlockslength; i++) {
            // Push and Shift
            if (proposedBlocks[epoch][sortedProposedBlockIds[epoch][i]].iteration > iteration) {
                sortedProposedBlockIds[epoch].push(blockId);

                sortedProposedBlockslength = sortedProposedBlockslength + 1;

                for (uint256 j = sortedProposedBlockslength - 1; j > i; j--) {
                    sortedProposedBlockIds[epoch][j] = sortedProposedBlockIds[epoch][j - 1];
                }

                sortedProposedBlockIds[epoch][i] = blockId;

                if (sortedProposedBlockIds[epoch].length > maxAltBlocks) {
                    sortedProposedBlockIds[epoch].pop();
                }

                return true;
            }
        }
        // Worst Iteration and for all other blocks, influence was >=
        if (sortedProposedBlockIds[epoch].length < maxAltBlocks) {
            sortedProposedBlockIds[epoch].push(blockId);
            return true;
        }
    }

    function _executeDispute(
        uint32 epoch,
        uint8 blockIndex,
        uint32 blockId
    ) internal returns (uint32) {
        proposedBlocks[epoch][blockId].valid = false;

        uint8 sortedProposedBlocksLength = uint8(sortedProposedBlockIds[epoch].length);
        if (uint8(blockIndexToBeConfirmed) == blockIndex) {
            // If the chosen one only is the culprit one, find successor
            // O(maxAltBlocks)

            blockIndexToBeConfirmed = -1;
            for (uint8 i = blockIndex + 1; i < sortedProposedBlocksLength; i++) {
                uint32 _blockId = sortedProposedBlockIds[epoch][i];
                if (proposedBlocks[epoch][_blockId].valid) {
                    // slither-disable-next-line costly-loop
                    blockIndexToBeConfirmed = int8(i);
                    break;
                }
            }
        }

        uint32 proposerId = proposedBlocks[epoch][blockId].proposerId;
        return stakeManager.slash(epoch, proposerId, msg.sender);
    }

    function _isElectedProposer(
        uint256 iteration,
        uint32 biggestStakerId,
        uint32 stakerId,
        uint32 epoch
    ) internal view initialized returns (bool) {
        // generating pseudo random number (range 0..(totalstake - 1)), add (+1) to the result,
        // since prng returns 0 to max-1 and staker start from 1

        bytes32 randaoHashes = voteManager.getRandaoHash();
        bytes32 seed1 = Random.prngHash(randaoHashes, keccak256(abi.encode(iteration)));
        uint256 rand1 = Random.prng(stakeManager.getNumStakers(), seed1);
        if ((rand1 + 1) != stakerId) {
            return false;
        }
        bytes32 seed2 = Random.prngHash(randaoHashes, keccak256(abi.encode(stakerId, iteration)));
        uint256 rand2 = Random.prng(2**32, seed2);

        uint256 biggestStake = voteManager.getStakeSnapshot(epoch, biggestStakerId);
        uint256 stake = voteManager.getStakeSnapshot(epoch, stakerId);
        if (rand2 * (biggestStake) > stake * (2**32)) return (false);
        return true;
    }
}

File 2 of 22 : IBlockManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "../../lib/Structs.sol";

interface IBlockManager {
    function confirmPreviousEpochBlock(uint32 stakerId) external;

    function getBlock(uint32 epoch) external view returns (Structs.Block memory _block);

    function isBlockConfirmed(uint32 epoch) external view returns (bool);
}

File 2 of 22 : IStakeManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "../../lib/Structs.sol";
import "../storage/Constants.sol";

interface IStakeManager {
    function setStakerStake(
        uint32 _epoch,
        uint32 _id,
        Constants.StakeChanged reason,
        uint256 _prevStake,
        uint256 _stake
    ) external;

    function slash(
        uint32 epoch,
        uint32 stakerId,
        address bountyHunter
    ) external returns (uint32);

    function setStakerAge(
        uint32 _epoch,
        uint32 _id,
        uint32 _age,
        Constants.AgeChanged reason
    ) external;

    function setStakerEpochFirstStakedOrLastPenalized(uint32 _epoch, uint32 _id) external;

    function escape(address _address) external;

    function srzrTransfer(
        address from,
        address to,
        uint256 amount,
        uint32 stakerId
    ) external;

    function getStakerId(address _address) external view returns (uint32);

    function getStaker(uint32 _id) external view returns (Structs.Staker memory staker);

    function getNumStakers() external view returns (uint32);

    function getInfluence(uint32 stakerId) external view returns (uint256);

    function getStake(uint32 stakerId) external view returns (uint256);

    function getEpochFirstStakedOrLastPenalized(uint32 stakerId) external view returns (uint32);
}

File 2 of 22 : IRewardManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "../../lib/Structs.sol";

interface IRewardManager {
    function givePenalties(uint32 epoch, uint32 stakerId) external;

    function giveBlockReward(uint32 epoch, uint32 stakerId) external;

    function giveInactivityPenalties(uint32 epoch, uint32 stakerId) external;
}

File 2 of 22 : IVoteManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "../../lib/Structs.sol";

interface IVoteManager {
    function getVoteValue(uint16 assetId, uint32 stakerId) external view returns (uint48);

    function getVote(uint32 stakerId) external view returns (Structs.Vote memory vote);

    function getInfluenceSnapshot(uint32 epoch, uint32 stakerId) external view returns (uint256);

    function getStakeSnapshot(uint32 epoch, uint32 stakerId) external view returns (uint256);

    function getTotalInfluenceRevealed(uint32 epoch) external view returns (uint256);

    function getEpochLastRevealed(uint32 stakerId) external view returns (uint32);

    function getEpochLastCommitted(uint32 stakerId) external view returns (uint32);

    function getRandaoHash() external view returns (bytes32);
}

File 2 of 22 : IAssetManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

interface IAssetManager {
    function executePendingDeactivations(uint32 epoch) external;

    function getActiveCollections() external view returns (uint16[] memory);

    function getPendingDeactivations() external view returns (uint16[] memory);

    function getCollectionIndex(uint16 id) external view returns (uint16);

    function getCollectionTolerance(uint16 id) external view returns (uint16);

    function getNumActiveCollections() external view returns (uint256);

    function getCollectionPower(uint16 id) external view returns (int8);
}

File 2 of 22 : IRandomNoProvider.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

interface IRandomNoProvider {
    /// @notice Called by BlockManager in ClaimBlockReward or ConfirmBlockLastEpoch
    /// @param epoch current epoch
    /// @param _secret hash of encoded rando secret from stakers
    function provideSecret(uint32 epoch, bytes32 _secret) external;
}

File 2 of 22 : BlockStorage.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;
import "../../lib/Structs.sol";

contract BlockStorage {
    //epoch -> address -> dispute
    mapping(uint32 => mapping(address => Structs.Dispute)) public disputes;
    //epoch -> blockId -> block
    mapping(uint32 => mapping(uint32 => Structs.Block)) public proposedBlocks;
    //epoch->blockId
    mapping(uint32 => uint32[]) public sortedProposedBlockIds;
    //stakerId->epoch
    mapping(uint32 => uint32) public epochLastProposed;

    // slither-disable-next-line constable-states
    uint32 public numProposedBlocks;
    // slither-disable-next-line constable-states
    int8 public blockIndexToBeConfirmed; // Index in sortedProposedBlockIds
    // epoch -> blocks
    mapping(uint32 => Structs.Block) public blocks;
}

File 2 of 22 : BlockManagerParams.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;
import "../interfaces/IBlockManagerParams.sol";
import "../ACL.sol";
import "../../storage/Constants.sol";

abstract contract BlockManagerParams is ACL, IBlockManagerParams, Constants {
    uint8 public maxAltBlocks = 5;
    uint16 public epochLength = 300;
    uint256 public blockReward = 100 * (10**18);
    uint256 public minStake = 1000 * (10**18);

    function setEpochLength(uint16 _epochLength) external override onlyRole(GOVERNANCE_ROLE) {
        // slither-disable-next-line events-maths
        epochLength = _epochLength;
    }

    function setMaxAltBlocks(uint8 _maxAltBlocks) external override onlyRole(GOVERNANCE_ROLE) {
        // slither-disable-next-line events-maths
        maxAltBlocks = _maxAltBlocks;
    }

    function setBlockReward(uint256 _blockReward) external override onlyRole(GOVERNANCE_ROLE) {
        // slither-disable-next-line events-maths
        blockReward = _blockReward;
    }

    function setMinStake(uint256 _minStake) external override onlyRole(GOVERNANCE_ROLE) {
        // slither-disable-next-line events-maths
        minStake = _minStake;
    }
}

File 2 of 22 : StateManager.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "./storage/Constants.sol";

contract StateManager is Constants {
    modifier checkEpoch(uint32 epoch, uint32 epochLength) {
        // slither-disable-next-line incorrect-equality
        require(epoch == _getEpoch(epochLength), "incorrect epoch");
        _;
    }

    modifier checkState(State state, uint32 epochLength) {
        // slither-disable-next-line incorrect-equality
        require(state == _getState(epochLength), "incorrect state");
        _;
    }

    modifier notState(State state, uint32 epochLength) {
        // slither-disable-next-line incorrect-equality
        require(state != _getState(epochLength), "incorrect state");
        _;
    }

    modifier checkEpochAndState(
        State state,
        uint32 epoch,
        uint32 epochLength
    ) {
        // slither-disable-next-line incorrect-equality
        require(epoch == _getEpoch(epochLength), "incorrect epoch");
        // slither-disable-next-line incorrect-equality
        require(state == _getState(epochLength), "incorrect state");
        _;
    }

    function _getEpoch(uint32 epochLength) internal view returns (uint32) {
        return (uint32(block.number) / (epochLength));
    }

    function _getState(uint32 epochLength) internal view returns (State) {
        uint8 state = uint8(((block.number) / (epochLength / NUM_STATES)) % (NUM_STATES));
        return State(state);
    }
}

File 2 of 22 : Random.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

library Random {
    // pseudo random number generator based on hash. returns 0 -> max-1
    // slither ignore reason : Internal library
    // slither-disable-next-line dead-code
    function prng(uint256 max, bytes32 randHash) internal pure returns (uint256) {
        uint256 sum = uint256(randHash);
        return (sum % max);
    }

    // pseudo random hash generator based on hashes.
    // slither ignore reason : Internal library
    // slither-disable-next-line dead-code
    function prngHash(bytes32 seed, bytes32 salt) internal pure returns (bytes32) {
        bytes32 prngHashVal = keccak256(abi.encodePacked(seed, salt));
        return (prngHashVal);
    }
}

File 2 of 22 : Initializable.sol
// SPDX-License-Identifier: MIT

// solhint-disable-next-line compiler-version
pragma solidity ^0.8.0;

/**
 * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
 * behind a proxy. Since a proxied contract can't have a constructor, it's common to move constructor logic to an
 * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
 * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
 *
 * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
 * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
 *
 * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
 * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
 *
 * Forked from OZ's (https://github.com/OpenZeppelin/openzeppelin-contracts/blob/b9125001f0a1c44d596ca3a47536f1a467e3a29d/contracts/proxy/utils/Initializable.sol)
 */

abstract contract Initializable {
    /**
     * @dev Indicates that the contract has been initialized.
     */
    bool private _initialized;

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

    /**
     * @dev Modifier to protect an initializer function from being invoked twice.
     */
    modifier initializer() {
        require(_initializing || !_initialized, "contract already initialized");

        bool isTopLevelCall = !_initializing;
        if (isTopLevelCall) {
            _initializing = true;
            _initialized = true;
        }

        _;

        if (isTopLevelCall) {
            _initializing = false;
        }
    }

    modifier initialized() {
        require(_initialized, "Contract should be initialized");
        _;
    }
}

File 2 of 22 : Structs.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

library Structs {
    struct Vote {
        uint32 epoch;
        uint48[] values;
    }

    struct Commitment {
        uint32 epoch;
        bytes32 commitmentHash;
    }
    struct Staker {
        // Slot 1
        bool acceptDelegation;
        bool isSlashed;
        uint8 commission;
        uint32 id;
        uint32 age;
        address _address;
        // Slot 2
        address tokenAddress;
        uint32 epochFirstStakedOrLastPenalized;
        uint32 epochCommissionLastUpdated;
        // Slot 3
        uint256 stake;
    }

    struct Lock {
        uint256 amount; //amount in RZR
        uint256 commission;
        uint256 withdrawAfter; // Can be made uint32 later if packing is possible
    }

    struct BountyLock {
        uint32 redeemAfter;
        address bountyHunter;
        uint256 amount; //amount in RZR
    }

    struct Block {
        bool valid;
        uint32 proposerId;
        uint32[] medians;
        uint256 iteration;
        uint256 biggestStake;
    }

    struct Dispute {
        uint16 collectionId;
        uint32 lastVisitedStaker;
        uint256 accWeight;
        uint256 accProd;
    }

    struct Job {
        uint16 id;
        uint8 selectorType; // 0-1
        uint8 weight; // 1-100
        int8 power;
        string name;
        string selector;
        string url;
    }

    struct Collection {
        bool active;
        uint16 id;
        uint16 assetIndex;
        uint16 tolerance;
        int8 power;
        uint32 aggregationMethod;
        uint16[] jobIDs;
        string name;
    }
}

File 2 of 22 : Constants.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

contract Constants {
    enum State {
        Commit,
        Reveal,
        Propose,
        Dispute,
        Confirm
    }

    enum StakeChanged {
        BlockReward,
        InactivityPenalty,
        RandaoPenalty,
        Slashed
    }

    enum AgeChanged {
        InactivityPenalty,
        VotingPenalty
    }

    uint8 public constant NUM_STATES = 5;
    address public constant BURN_ADDRESS = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;

    uint16 public constant BASE_DENOMINATOR = 10000;
    // keccak256("BLOCK_CONFIRMER_ROLE")
    bytes32 public constant BLOCK_CONFIRMER_ROLE = 0x18797bc7973e1dadee1895be2f1003818e30eae3b0e7a01eb9b2e66f3ea2771f;

    // keccak256("ASSET_CONFIRMER_ROLE")
    bytes32 public constant ASSET_CONFIRMER_ROLE = 0xed202a1bc048f9b31cb3937bc52e7c8fe76413f0674b9146ff4bcc15612ccbc2;

    // keccak256("STAKER_ACTIVITY_UPDATER_ROLE")
    bytes32 public constant STAKER_ACTIVITY_UPDATER_ROLE = 0x4cd3070aaa07d03ab33731cbabd0cb27eb9e074a9430ad006c96941d71b77ece;

    // keccak256("STAKE_MODIFIER_ROLE")
    bytes32 public constant STAKE_MODIFIER_ROLE = 0xdbaaaff2c3744aa215ebd99971829e1c1b728703a0bf252f96685d29011fc804;

    // keccak256("REWARD_MODIFIER_ROLE")
    bytes32 public constant REWARD_MODIFIER_ROLE = 0xcabcaf259dd9a27f23bd8a92bacd65983c2ebf027c853f89f941715905271a8d;

    // keccak256("ASSET_MODIFIER_ROLE")
    bytes32 public constant ASSET_MODIFIER_ROLE = 0xca0fffcc0404933256f3ec63d47233fbb05be25fc0eacc2cfb1a2853993fbbe4;

    // keccak256("VOTE_MODIFIER_ROLE")
    bytes32 public constant VOTE_MODIFIER_ROLE = 0xca0fffcc0404933256f3ec63d47233fbb05be25fc0eacc2cfb1a2853993fbbe5;

    // keccak256("DELEGATOR_MODIFIER_ROLE")
    bytes32 public constant DELEGATOR_MODIFIER_ROLE = 0x6b7da7a33355c6e035439beb2ac6a052f1558db73f08690b1c9ef5a4e8389597;

    // keccak256("SECRETS_MODIFIER_ROLE")
    bytes32 public constant SECRETS_MODIFIER_ROLE = 0x46aaf8a125792dfff6db03d74f94fe1acaf55c8cab22f65297c15809c364465c;

    // keccak256("PAUSE_ROLE")
    bytes32 public constant PAUSE_ROLE = 0x139c2898040ef16910dc9f44dc697df79363da767d8bc92f2e310312b816e46d;

    // keccak256("GOVERNANCE_ROLE")
    bytes32 public constant GOVERNANCE_ROLE = 0x71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb1;

    // keccak256("STOKEN_ROLE")
    bytes32 public constant STOKEN_ROLE = 0xce3e6c780f179d7a08d28e380f7be9c36d990f56515174f8adb6287c543e30dc;
}

File 2 of 22 : IBlockManagerParams.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

interface IBlockManagerParams {
    function setEpochLength(uint16 _epochLength) external;

    function setMaxAltBlocks(uint8 _maxAltBlocks) external;

    function setBlockReward(uint256 _blockReward) external;

    function setMinStake(uint256 _minStake) external;
}

File 2 of 22 : ACL.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/access/AccessControl.sol";

contract ACL is AccessControl {
    constructor() {
        _setupRole(DEFAULT_ADMIN_ROLE, msg.sender);
    }
}

File 2 of 22 : AccessControl.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/AccessControl.sol)

pragma solidity ^0.8.0;

import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";

/**
 * @dev Contract module that allows children to implement role-based access
 * control mechanisms. This is a lightweight version that doesn't allow enumerating role
 * members except through off-chain means by accessing the contract event logs. Some
 * applications may benefit from on-chain enumerability, for those cases see
 * {AccessControlEnumerable}.
 *
 * Roles are referred to by their `bytes32` identifier. These should be exposed
 * in the external API and be unique. The best way to achieve this is by
 * using `public constant` hash digests:
 *
 * ```
 * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
 * ```
 *
 * Roles can be used to represent a set of permissions. To restrict access to a
 * function call, use {hasRole}:
 *
 * ```
 * function foo() public {
 *     require(hasRole(MY_ROLE, msg.sender));
 *     ...
 * }
 * ```
 *
 * Roles can be granted and revoked dynamically via the {grantRole} and
 * {revokeRole} functions. Each role has an associated admin role, and only
 * accounts that have a role's admin role can call {grantRole} and {revokeRole}.
 *
 * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
 * that only accounts with this role will be able to grant or revoke other
 * roles. More complex role relationships can be created by using
 * {_setRoleAdmin}.
 *
 * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
 * grant and revoke this role. Extra precautions should be taken to secure
 * accounts that have been granted it.
 */
abstract contract AccessControl is Context, IAccessControl, ERC165 {
    struct RoleData {
        mapping(address => bool) members;
        bytes32 adminRole;
    }

    mapping(bytes32 => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @dev Modifier that checks that an account has a specific role. Reverts
     * with a standardized message including the required role.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     *
     * _Available since v4.1._
     */
    modifier onlyRole(bytes32 role) {
        _checkRole(role, _msgSender());
        _;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) public view override returns (bool) {
        return _roles[role].members[account];
    }

    /**
     * @dev Revert with a standard message if `account` is missing `role`.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     */
    function _checkRole(bytes32 role, address account) internal view {
        if (!hasRole(role, account)) {
            revert(
                string(
                    abi.encodePacked(
                        "AccessControl: account ",
                        Strings.toHexString(uint160(account), 20),
                        " is missing role ",
                        Strings.toHexString(uint256(role), 32)
                    )
                )
            );
        }
    }

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) public view override returns (bytes32) {
        return _roles[role].adminRole;
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _grantRole(role, account);
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _revokeRole(role, account);
    }

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been revoked `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) public virtual override {
        require(account == _msgSender(), "AccessControl: can only renounce roles for self");

        _revokeRole(role, account);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event. Note that unlike {grantRole}, this function doesn't perform any
     * checks on the calling account.
     *
     * [WARNING]
     * ====
     * This function should only be called from the constructor when setting
     * up the initial roles for the system.
     *
     * Using this function in any other way is effectively circumventing the admin
     * system imposed by {AccessControl}.
     * ====
     *
     * NOTE: This function is deprecated in favor of {_grantRole}.
     */
    function _setupRole(bytes32 role, address account) internal virtual {
        _grantRole(role, account);
    }

    /**
     * @dev Sets `adminRole` as ``role``'s admin role.
     *
     * Emits a {RoleAdminChanged} event.
     */
    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
        bytes32 previousAdminRole = getRoleAdmin(role);
        _roles[role].adminRole = adminRole;
        emit RoleAdminChanged(role, previousAdminRole, adminRole);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * Internal function without access restriction.
     */
    function _grantRole(bytes32 role, address account) internal virtual {
        if (!hasRole(role, account)) {
            _roles[role].members[account] = true;
            emit RoleGranted(role, account, _msgSender());
        }
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * Internal function without access restriction.
     */
    function _revokeRole(bytes32 role, address account) internal virtual {
        if (hasRole(role, account)) {
            _roles[role].members[account] = false;
            emit RoleRevoked(role, account, _msgSender());
        }
    }
}

File 2 of 22 : IAccessControl.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)

pragma solidity ^0.8.0;

/**
 * @dev External interface of AccessControl declared to support ERC165 detection.
 */
interface IAccessControl {
    /**
     * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
     *
     * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
     * {RoleAdminChanged} not being emitted signaling this.
     *
     * _Available since v3.1._
     */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);

    /**
     * @dev Emitted when `account` is granted `role`.
     *
     * `sender` is the account that originated the contract call, an admin role
     * bearer except when using {AccessControl-_setupRole}.
     */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Emitted when `account` is revoked `role`.
     *
     * `sender` is the account that originated the contract call:
     *   - if using `revokeRole`, it is the admin role bearer
     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)
     */
    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) external view returns (bool);

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {AccessControl-_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) external view returns (bytes32);

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) external;
}

File 2 of 22 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

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

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

File 2 of 22 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}

File 2 of 22 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 2 of 22 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 30000
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"},{"indexed":false,"internalType":"uint32","name":"stakerId","type":"uint32"},{"indexed":false,"internalType":"uint32[]","name":"medians","type":"uint32[]"},{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"BlockConfirmed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"},{"indexed":false,"internalType":"uint32","name":"stakerId","type":"uint32"},{"indexed":false,"internalType":"uint32[]","name":"medians","type":"uint32[]"},{"indexed":false,"internalType":"uint256","name":"iteration","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"biggestStakerId","type":"uint32"},{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"Proposed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"inputs":[],"name":"ASSET_CONFIRMER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"ASSET_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BASE_DENOMINATOR","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BLOCK_CONFIRMER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"BURN_ADDRESS","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DELEGATOR_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"GOVERNANCE_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NUM_STATES","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PAUSE_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"REWARD_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SECRETS_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"STAKER_ACTIVITY_UPDATER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"STAKE_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"STOKEN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VOTE_MODIFIER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"assetManager","outputs":[{"internalType":"contract IAssetManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"blockIndexToBeConfirmed","outputs":[{"internalType":"int8","name":"","type":"int8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"blockReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"}],"name":"blocks","outputs":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"uint32","name":"proposerId","type":"uint32"},{"internalType":"uint256","name":"iteration","type":"uint256"},{"internalType":"uint256","name":"biggestStake","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimBlockReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"stakerId","type":"uint32"}],"name":"confirmPreviousEpochBlock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"},{"internalType":"uint8","name":"blockIndex","type":"uint8"},{"internalType":"uint32","name":"correctBiggestStakerId","type":"uint32"}],"name":"disputeBiggestStakeProposed","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"},{"internalType":"address","name":"","type":"address"}],"name":"disputes","outputs":[{"internalType":"uint16","name":"collectionId","type":"uint16"},{"internalType":"uint32","name":"lastVisitedStaker","type":"uint32"},{"internalType":"uint256","name":"accWeight","type":"uint256"},{"internalType":"uint256","name":"accProd","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"}],"name":"epochLastProposed","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"epochLength","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"},{"internalType":"uint8","name":"blockIndex","type":"uint8"}],"name":"finalizeDispute","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"getBlock","outputs":[{"components":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"uint32","name":"proposerId","type":"uint32"},{"internalType":"uint32[]","name":"medians","type":"uint32[]"},{"internalType":"uint256","name":"iteration","type":"uint256"},{"internalType":"uint256","name":"biggestStake","type":"uint256"}],"internalType":"struct Structs.Block","name":"_block","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"getNumProposedBlocks","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"},{"internalType":"uint32","name":"proposedBlock","type":"uint32"}],"name":"getProposedBlock","outputs":[{"components":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"uint32","name":"proposerId","type":"uint32"},{"internalType":"uint32[]","name":"medians","type":"uint32[]"},{"internalType":"uint256","name":"iteration","type":"uint256"},{"internalType":"uint256","name":"biggestStake","type":"uint256"}],"internalType":"struct Structs.Block","name":"_block","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"},{"internalType":"uint16","name":"collectionId","type":"uint16"},{"internalType":"uint32[]","name":"sortedStakers","type":"uint32[]"}],"name":"giveSorted","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"stakeManagerAddress","type":"address"},{"internalType":"address","name":"rewardManagerAddress","type":"address"},{"internalType":"address","name":"voteManagerAddress","type":"address"},{"internalType":"address","name":"assetManagerAddress","type":"address"},{"internalType":"address","name":"randomNoManagerAddress","type":"address"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"isBlockConfirmed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxAltBlocks","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minStake","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numProposedBlocks","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"},{"internalType":"uint32[]","name":"medians","type":"uint32[]"},{"internalType":"uint256","name":"iteration","type":"uint256"},{"internalType":"uint32","name":"biggestStakerId","type":"uint32"}],"name":"propose","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"},{"internalType":"uint32","name":"","type":"uint32"}],"name":"proposedBlocks","outputs":[{"internalType":"bool","name":"valid","type":"bool"},{"internalType":"uint32","name":"proposerId","type":"uint32"},{"internalType":"uint256","name":"iteration","type":"uint256"},{"internalType":"uint256","name":"biggestStake","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"randomNoProvider","outputs":[{"internalType":"contract IRandomNoProvider","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"resetDispute","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardManager","outputs":[{"internalType":"contract IRewardManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_blockReward","type":"uint256"}],"name":"setBlockReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint16","name":"_epochLength","type":"uint16"}],"name":"setEpochLength","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint8","name":"_maxAltBlocks","type":"uint8"}],"name":"setMaxAltBlocks","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minStake","type":"uint256"}],"name":"setMinStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint32","name":"","type":"uint32"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"sortedProposedBlockIds","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"stakeManager","outputs":[{"internalType":"contract IStakeManager","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"voteManager","outputs":[{"internalType":"contract IVoteManager","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106103625760003560e01c80635b070278116101c857806397788d0611610104578063c9e99c25116100a2578063ef8bf6841161007c578063ef8bf684146109f3578063f2dd046314610a1a578063f36c8f5c14610a2d578063fccc281314610a5457600080fd5b8063c9e99c25146109a6578063d547741f146109b9578063da984295146109cc57600080fd5b8063bd859584116100de578063bd859584146108e3578063be436df1146108ec578063bf897a9a14610912578063c1a2bab51461093257600080fd5b806397788d06146108b5578063a217fddf146108c8578063accd8f53146108d057600080fd5b80638622f3a9116101715780638c80fd901161014b5780638c80fd90146107f457806391d148541461080757806394217ad11461084d5780639493aff81461086d57600080fd5b80638622f3a91461077657806389447125146107a65780638b5b922d146107cd57600080fd5b8063776076e7116101a2578063776076e71461072957806381d96db81461075057806385a9777c1461076357600080fd5b80635b0702781461067c5780635cd0783e146106a35780637542ff951461070957600080fd5b8063248a9ca3116102a2578063389ed2671161024057806342c1e5871161021a57806342c1e587146105e85780634912b72a146106085780634d4b56bd1461062f57806357d775f81461065657600080fd5b8063389ed2671461059e5780634007ce18146105c557806342a1035f146105d857600080fd5b80632f50bcc41161027c5780632f50bcc41461054e57806336568abe14610575578063375b3c0a14610588578063379597e01461059157600080fd5b8063248a9ca3146104f15780632d93b9a0146105145780632f2ff15d1461053b57600080fd5b80630f4ef8a61161030f57806316391253116102e9578063163912531461049d5780631a18e707146104a55780631bea14e9146104b85780632023d0be146104cb57600080fd5b80630f4ef8a61461041b57806311e29f52146104605780631459457a1461048857600080fd5b80630ac168a1116103405780630ac168a1146103c95780630c92ad7d146103e05780630cde122a1461040857600080fd5b806301ffc9a71461036757806305db56df1461038f57806309f2f13d146103a9575b600080fd5b61037a610375366004614f11565b610a6f565b60405190151581526020015b60405180910390f35b610397600581565b60405160ff9091168152602001610386565b6103bc6103b73660046151cc565b610b08565b60405161038691906153a3565b6103d260095481565b604051908152602001610386565b6103f36103ee36600461522f565b610c1d565b60405163ffffffff9091168152602001610386565b6103f3610416366004615204565b610f85565b600c5461043b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610386565b60055461047590640100000000900460000b81565b60405160009190910b8152602001610386565b61049b610496366004614db6565b6114fb565b005b61049b61165e565b61049b6104b3366004614eb6565b611b72565b6103bc6104c6366004615074565b611ba3565b6103f36104d9366004615074565b60046020526000908152604090205463ffffffff1681565b6103d26104ff366004614eb6565b60009081526007602052604090206001015490565b6103d27fca0fffcc0404933256f3ec63d47233fbb05be25fc0eacc2cfb1a2853993fbbe581565b61049b610549366004614ee6565b611cad565b6103d27f46aaf8a125792dfff6db03d74f94fe1acaf55c8cab22f65297c15809c364465c81565b61049b610583366004614ee6565b611cd8565b6103d2600a5481565b6008546103979060ff1681565b6103d27f139c2898040ef16910dc9f44dc697df79363da767d8bc92f2e310312b816e46d81565b61049b6105d336600461503c565b611d6d565b6005546103f39063ffffffff1681565b600d5461043b9073ffffffffffffffffffffffffffffffffffffffff1681565b6103d27f6b7da7a33355c6e035439beb2ac6a052f1558db73f08690b1c9ef5a4e838959781565b6103d27f4cd3070aaa07d03ab33731cbabd0cb27eb9e074a9430ad006c96941d71b77ece81565b60085461066990610100900461ffff1681565b60405161ffff9091168152602001610386565b6103d27fce3e6c780f179d7a08d28e380f7be9c36d990f56515174f8adb6287c543e30dc81565b6106e26106b1366004615074565b60066020526000908152604090208054600282015460039092015460ff82169261010090920463ffffffff16919084565b60408051941515855263ffffffff9093166020850152918301526060820152608001610386565b600b5461043b9073ffffffffffffffffffffffffffffffffffffffff1681565b6103d27fdbaaaff2c3744aa215ebd99971829e1c1b728703a0bf252f96685d29011fc80481565b61049b61075e366004615074565b611dd3565b6103f36107713660046151a1565b611fc8565b61037a610784366004615074565b63ffffffff908116600090815260066020526040902054610100900416151590565b6103d27fca0fffcc0404933256f3ec63d47233fbb05be25fc0eacc2cfb1a2853993fbbe481565b6103d27fed202a1bc048f9b31cb3937bc52e7c8fe76413f0674b9146ff4bcc15612ccbc281565b61049b610802366004614eb6565b612011565b61037a610815366004614ee6565b600091825260076020908152604080842073ffffffffffffffffffffffffffffffffffffffff93909316845291905290205460ff1690565b600e5461043b9073ffffffffffffffffffffffffffffffffffffffff1681565b6106e261087b3660046151cc565b6002602081815260009384526040808520909152918352912080549181015460039091015460ff831692610100900463ffffffff16919084565b61049b6108c3366004615277565b612042565b6103d2600081565b61049b6108de3660046150d7565b6120a2565b61066961271081565b6103976108fa366004615074565b63ffffffff1660009081526003602052604090205490565b600f5461043b9073ffffffffffffffffffffffffffffffffffffffff1681565b61097c6109403660046150ac565b6001602081815260009384526040808520909152918352912080549181015460029091015461ffff83169262010000900463ffffffff16919084565b6040805161ffff909516855263ffffffff9093166020850152918301526060820152608001610386565b61049b6109b4366004615074565b612914565b61049b6109c7366004614ee6565b612b83565b6103d27f18797bc7973e1dadee1895be2f1003818e30eae3b0e7a01eb9b2e66f3ea2771f81565b6103d27fcabcaf259dd9a27f23bd8a92bacd65983c2ebf027c853f89f941715905271a8d81565b61049b610a28366004615141565b612ba9565b6103d27f71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb181565b61043b73eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee81565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f7965db0b000000000000000000000000000000000000000000000000000000001480610b0257507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b610b426040518060a00160405280600015158152602001600063ffffffff1681526020016060815260200160008152602001600081525090565b63ffffffff80841660009081526002602090815260408083208685168452825291829020825160a081018452815460ff81161515825261010090049094168483015260018101805484518185028101850186528181529294860193830182828015610bf857602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411610bbb5790505b5050505050815260200160028201548152602001600382015481525050905092915050565b6000805460ff16610c755760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a6564000060448201526064015b60405180910390fd5b6008546003908590610100900461ffff16610c8f81613280565b63ffffffff168263ffffffff1614610ce95760405162461bcd60e51b815260206004820152600f60248201527f696e636f72726563742065706f636800000000000000000000000000000000006044820152606401610c6c565b610cf28161328c565b6004811115610d1157634e487b7160e01b600052602160045260246000fd5b836004811115610d3157634e487b7160e01b600052602160045260246000fd5b14610d7e5760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b63ffffffff87166000908152600360205260408120805460ff8916908110610db657634e487b7160e01b600052603260045260246000fd5b6000918252602080832060088304015463ffffffff8c8116855260028352604080862060079095166004026101000a90920416808552929091529091205490915060ff16610e465760405162461bcd60e51b815260206004820152601f60248201527f426c6f636b20616c726561647920686173206265656e206469737075746564006044820152606401610c6c565b600d546040517fe1730ac600000000000000000000000000000000000000000000000000000000815263ffffffff808b1660048301528816602482015260009173ffffffffffffffffffffffffffffffffffffffff169063e1730ac69060440160206040518083038186803b158015610ebe57600080fd5b505afa158015610ed2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ef69190614ece565b63ffffffff808b166000908152600260209081526040808320938716835292905220600301549091508111610f6d5760405162461bcd60e51b815260206004820152601760248201527f496e76616c69642064697370757465203a205374616b650000000000000000006044820152606401610c6c565b610f788989846132e1565b9998505050505050505050565b6000805460ff16610fd85760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b6008546003908490610100900461ffff16610ff281613280565b63ffffffff168263ffffffff161461104c5760405162461bcd60e51b815260206004820152600f60248201527f696e636f72726563742065706f636800000000000000000000000000000000006044820152606401610c6c565b6110558161328c565b600481111561107457634e487b7160e01b600052602160045260246000fd5b83600481111561109457634e487b7160e01b600052602160045260246000fd5b146110e15760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b600d546040517f38e692a900000000000000000000000000000000000000000000000000000000815263ffffffff8816600482015273ffffffffffffffffffffffffffffffffffffffff909116906338e692a99060240160206040518083038186803b15801561115057600080fd5b505afa158015611164573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111889190614ece565b63ffffffff871660009081526001602081815260408084203385529091529091200154146111f85760405162461bcd60e51b815260206004820152600c60248201527f5449522069732077726f6e6700000000000000000000000000000000000000006044820152606401610c6c565b63ffffffff8616600090815260016020818152604080842033855290915282209081015460029091015461122c919061573d565b905060008163ffffffff16116112845760405162461bcd60e51b815260206004820152601660248201527f6d656469616e2063616e206e6f74206265207a65726f000000000000000000006044820152606401610c6c565b63ffffffff87166000908152600360205260408120805460ff89169081106112bc57634e487b7160e01b600052603260045260246000fd5b6000918252602080832060088304015463ffffffff8c8116855260028352604080862060079095166004026101000a90920416808552929091529091205490915060ff1661134c5760405162461bcd60e51b815260206004820152601f60248201527f426c6f636b20616c726561647920686173206265656e206469737075746564006044820152606401610c6c565b63ffffffff8816600090815260016020908152604080832033845290915280822054600e5491517f43f015dd00000000000000000000000000000000000000000000000000000000815261ffff90911660048201819052929173ffffffffffffffffffffffffffffffffffffffff16906343f015dd9060240160206040518083038186803b1580156113dd57600080fd5b505afa1580156113f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114159190615058565b63ffffffff8b811660009081526002602090815260408083208885168452909152902091925085169060019081019061144e90846157b1565b61ffff168154811061147057634e487b7160e01b600052603260045260246000fd5b6000918252602090912060088204015460079091166004026101000a900463ffffffff1614156114e25760405162461bcd60e51b815260206004820181905260248201527f426c6f636b2070726f706f73656420776974682073616d65206d656469616e736044820152606401610c6c565b6114ed8a8a856132e1565b9a9950505050505050505050565b600054610100900460ff1680611514575060005460ff16155b6115605760405162461bcd60e51b815260206004820152601c60248201527f636f6e747261637420616c726561647920696e697469616c697a6564000000006044820152606401610c6c565b600054610100900460ff1615801561159f57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000166101011790555b60006115ab813361355a565b50600b80547fffffffffffffffffffffffff000000000000000000000000000000000000000090811673ffffffffffffffffffffffffffffffffffffffff89811691909117909255600c80548216888416179055600d80548216878416179055600e80548216868416179055600f8054909116918416919091179055801561165657600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555b505050505050565b60005460ff166116b05760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b600854600490610100900461ffff166116c88161328c565b60048111156116e757634e487b7160e01b600052602160045260246000fd5b82600481111561170757634e487b7160e01b600052602160045260246000fd5b146117545760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b60085460009061176c90610100900461ffff16613280565b600b546040517f6022a48500000000000000000000000000000000000000000000000000000000815233600482015291925060009173ffffffffffffffffffffffffffffffffffffffff90911690636022a4859060240160206040518083038186803b1580156117db57600080fd5b505afa1580156117ef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118139190615090565b905060008163ffffffff161161186b5760405162461bcd60e51b815260206004820152601d60248201527f537472756374732e5374616b657220646f6573206e6f742065786973740000006044820152606401610c6c565b63ffffffff808316600090815260066020526040902054610100900416156118d55760405162461bcd60e51b815260206004820152601760248201527f426c6f636b20616c726561647920636f6e6669726d65640000000000000000006044820152606401610c6c565b600e54604080517fbe780837000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163be7808379160048083019286929190829003018186803b15801561193f57600080fd5b505afa158015611953573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526119999190810190614e1a565b63ffffffff841660009081526003602052604090205490915015806119ee57506005546401000000009004600090810b900b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff145b15611a8357600e546040517fbbefc10a00000000000000000000000000000000000000000000000000000000815263ffffffff8516600482015273ffffffffffffffffffffffffffffffffffffffff9091169063bbefc10a90602401600060405180830381600087803b158015611a6457600080fd5b505af1158015611a78573d6000803e3d6000fd5b505050505050505050565b63ffffffff831660009081526002602090815260408083206003909252822060055481548492916401000000009004830b60ff16908110611ad457634e487b7160e01b600052603260045260246000fd5b60009182526020808320600883040154600790921660040261010090810a90920463ffffffff9081168552908401949094526040909201902054048116915083168114611b635760405162461bcd60e51b815260206004820152601960248201527f426c6f636b2050726f706f736572206d69736d617463686573000000000000006044820152606401610c6c565b611656848383613612565b5050565b7f71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb1611b9d813361355a565b50600955565b611bdd6040518060a00160405280600015158152602001600063ffffffff1681526020016060815260200160008152602001600081525090565b63ffffffff808316600090815260066020908152604091829020825160a081018452815460ff81161515825261010090049094168483015260018101805484518185028101850186528181529294860193830182828015611c8957602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411611c4c5790505b50505050508152602001600282015481526020016003820154815250509050919050565b600082815260076020526040902060010154611cc9813361355a565b611cd38383613d20565b505050565b73ffffffffffffffffffffffffffffffffffffffff81163314611d635760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201527f20726f6c657320666f722073656c6600000000000000000000000000000000006064820152608401610c6c565b611b6e8282613e14565b7f71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb1611d98813361355a565b506008805461ffff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ff909216919091179055565b60005460ff16611e255760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b6008546003908290610100900461ffff16611e3f81613280565b63ffffffff168263ffffffff1614611e995760405162461bcd60e51b815260206004820152600f60248201527f696e636f72726563742065706f636800000000000000000000000000000000006044820152606401610c6c565b611ea28161328c565b6004811115611ec157634e487b7160e01b600052602160045260246000fd5b836004811115611ee157634e487b7160e01b600052602160045260246000fd5b14611f2e5760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b505060408051608081018252600080825260208083018281528385018381526060850184815263ffffffff988916855260018085528786203387529094529590932093518454915190971662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000090911661ffff979097169690961795909517825551938101939093555160029092019190915550565b60036020528160005260406000208181548110611fe457600080fd5b9060005260206000209060089182820401919006600402915091509054906101000a900463ffffffff1681565b7f71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb161203c813361355a565b50600a55565b7f71840dc4906352362b0cdaf79870196c8e42acafade72d5d5a6d59291253ceb161206d813361355a565b50600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff92909216919091179055565b60005460ff166120f45760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b6008546002908590610100900461ffff1661210e81613280565b63ffffffff168263ffffffff16146121685760405162461bcd60e51b815260206004820152600f60248201527f696e636f72726563742065706f636800000000000000000000000000000000006044820152606401610c6c565b6121718161328c565b600481111561219057634e487b7160e01b600052602160045260246000fd5b8360048111156121b057634e487b7160e01b600052602160045260246000fd5b146121fd5760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b600b546040517f6022a48500000000000000000000000000000000000000000000000000000000815233600482015260009173ffffffffffffffffffffffffffffffffffffffff1690636022a4859060240160206040518083038186803b15801561226757600080fd5b505afa15801561227b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061229f9190615090565b90506122ad8686838b613ecf565b6122f95760405162461bcd60e51b815260206004820152600b60248201527f6e6f7420656c65637465640000000000000000000000000000000000000000006044820152606401610c6c565b600a54600b546040517edd998100000000000000000000000000000000000000000000000000000000815263ffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff9091169062dd99819060240160206040518083038186803b15801561236957600080fd5b505afa15801561237d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123a19190614ece565b10156123ef5760405162461bcd60e51b815260206004820152601960248201527f7374616b652062656c6f77206d696e696d756d207374616b65000000000000006044820152606401610c6c565b600d546040517f0bb34f5600000000000000000000000000000000000000000000000000000000815263ffffffff83811660048301528a169173ffffffffffffffffffffffffffffffffffffffff1690630bb34f569060240160206040518083038186803b15801561246057600080fd5b505afa158015612474573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124989190615090565b63ffffffff16146124eb5760405162461bcd60e51b815260206004820181905260248201527f43616e6e6f742070726f706f736520776974686f75742072657665616c696e676044820152606401610c6c565b63ffffffff818116600090815260046020526040902054811690891614156125555760405162461bcd60e51b815260206004820152601060248201527f416c72656164792070726f706f736564000000000000000000000000000000006044820152606401610c6c565b600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663618b0bb76040518163ffffffff1660e01b815260040160206040518083038186803b1580156125bd57600080fd5b505afa1580156125d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125f59190614ece565b8751146126445760405162461bcd60e51b815260206004820152601660248201527f696e76616c696420626c6f636b2070726f706f736564000000000000000000006044820152606401610c6c565b600d546040517fe1730ac600000000000000000000000000000000000000000000000000000000815263ffffffff808b1660048301528716602482015260009173ffffffffffffffffffffffffffffffffffffffff169063e1730ac69060440160206040518083038186803b1580156126bc57600080fd5b505afa1580156126d0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126f49190614ece565b63ffffffff8a1660009081526003602052604090205490915061273a57600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001690555b6040805160a081018252600180825263ffffffff85811660208085019182528486018e8152606086018e9052608086018890528f8416600090815260028352878120600554861682528352969096208551815493517fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009094169015157fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1617610100939094169290920292909217815593518051939493612802938501929190910190614bf2565b5060608201516002820155608090910151600390910155600554600090612832908b9063ffffffff168a856142bc565b63ffffffff848116600090815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000016918d16919091179055905080156128c7576005546128919063ffffffff1660016156f0565b600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff929092169190911790555b7f60b28e9913876d5cd18aedee156a4b9a83cb2e4661a47a60d5dbe1f6f71f4bf58a848b8b8b42604051612900969594939291906153fb565b60405180910390a150505050505050505050565b60005460ff166129665760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b7f18797bc7973e1dadee1895be2f1003818e30eae3b0e7a01eb9b2e66f3ea2771f612991813361355a565b6008546000906129a990610100900461ffff16613280565b90506000600e60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663be7808376040518163ffffffff1660e01b815260040160006040518083038186803b158015612a1557600080fd5b505afa158015612a29573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612a6f9190810190614e1a565b905060036000612a806001856157eb565b63ffffffff1681526020810191909152604001600020541580612ad357506005546401000000009004600090810b900b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff145b15612b6857600e546040517fbbefc10a00000000000000000000000000000000000000000000000000000000815263ffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff9091169063bbefc10a906024015b600060405180830381600087803b158015612b4a57600080fd5b505af1158015612b5e573d6000803e3d6000fd5b5050505050505050565b612b7d612b766001846157eb565b8286613612565b50505050565b600082815260076020526040902060010154612b9f813361355a565b611cd38383613e14565b60005460ff16612bfb5760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b6008546003908490610100900461ffff16612c1581613280565b63ffffffff168263ffffffff1614612c6f5760405162461bcd60e51b815260206004820152600f60248201527f696e636f72726563742065706f636800000000000000000000000000000000006044820152606401610c6c565b612c788161328c565b6004811115612c9757634e487b7160e01b600052602160045260246000fd5b836004811115612cb757634e487b7160e01b600052602160045260246000fd5b14612d045760405162461bcd60e51b815260206004820152600f60248201527f696e636f727265637420737461746500000000000000000000000000000000006044820152606401610c6c565b63ffffffff86811660009081526001602081815260408084203385529091528083209182015460028301549254600e5492517f43f015dd00000000000000000000000000000000000000000000000000000000815261ffff8c1660048201529195939462010000909104909316929173ffffffffffffffffffffffffffffffffffffffff16906343f015dd9060240160206040518083038186803b158015612dab57600080fd5b505afa158015612dbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612de39190615058565b63ffffffff8b1660009081526001602081815260408084203385529091529091200154909150612e5e5763ffffffff8a166000908152600160209081526040808320338452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff8b16179055612ed4565b63ffffffff8a16600090815260016020908152604080832033845290915290205461ffff8a8116911614612ed45760405162461bcd60e51b815260206004820152601460248201527f41737365744964206e6f74206d61746368696e670000000000000000000000006044820152606401610c6c565b60005b88518163ffffffff161015613211578263ffffffff16898263ffffffff1681518110612f1357634e487b7160e01b600052603260045260246000fd5b602002602001015163ffffffff1611612f6e5760405162461bcd60e51b815260206004820152601460248201527f736f727465645374616b6572203c3d204c5653200000000000000000000000006044820152606401610c6c565b888163ffffffff1681518110612f9457634e487b7160e01b600052603260045260246000fd5b6020908102919091010151600d546040517fca0652bf00000000000000000000000000000000000000000000000000000000815263ffffffff8316600482015291945060009173ffffffffffffffffffffffffffffffffffffffff9091169063ca0652bf9060240160006040518083038186803b15801561301457600080fd5b505afa158015613028573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261306e9190810190614f51565b90508b63ffffffff16816000015163ffffffff16146130cf5760405162461bcd60e51b815260206004820152601f60248201527f7374616b6572206469646e7420766f746520696e20746869732065706f6368006044820152606401610c6c565b60208101516000906130e26001866157b1565b61ffff168151811061310457634e487b7160e01b600052603260045260246000fd5b602002602001015190506000600d60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348fd8e7b8f886040518363ffffffff1660e01b815260040161317f92919063ffffffff92831681529116602082015260400190565b60206040518083038186803b15801561319757600080fd5b505afa1580156131ab573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131cf9190614ece565b90506131e38165ffffffffffff8416615774565b6131ed90886156d8565b96506131f981896156d8565b97505050508080613209906158c8565b915050612ed7565b505063ffffffff9889166000908152600160208181526040808420338552909152909120805492909a1662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ffff9092169190911789558801919091556002909601959095555050505050565b6000610b028243615751565b600080600561329b8185615751565b6132ab9063ffffffff164361573d565b6132b5919061590c565b90508060ff1660048111156132da57634e487b7160e01b600052602160045260246000fd5b9392505050565b63ffffffff8381166000818152600260209081526040808320948616835293815283822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905591815260039091529081205460055460ff858116640100000000909204840b16141561347257600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff1664ff00000000179055600061338d856001615718565b90505b8160ff168160ff1610156134705763ffffffff86166000908152600360205260408120805460ff84169081106133d657634e487b7160e01b600052603260045260246000fd5b6000918252602080832060088304015463ffffffff8b8116855260028352604080862060079095166004026101000a90920416808552929091529091205490915060ff161561345d5750600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff1664010000000060ff600085900b1602179055613470565b5080613468816158ec565b915050613390565b505b63ffffffff858116600081815260026020908152604080832088861684529091529081902054600b5491517f8f764cf400000000000000000000000000000000000000000000000000000000815260048101939093526101009004909216602482018190523360448301529173ffffffffffffffffffffffffffffffffffffffff1690638f764cf490606401602060405180830381600087803b15801561351857600080fd5b505af115801561352c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135509190615090565b9695505050505050565b600082815260076020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16611b6e576135b28173ffffffffffffffffffffffffffffffffffffffff166014614919565b6135bd836020614919565b6040516020016135ce9291906152d1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905262461bcd60e51b8252610c6c91600401615352565b63ffffffff831660009081526003602052604081206005548154640100000000909104830b60ff1690811061365757634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690506000835190505b61ffff8116156139b457600e5460009073ffffffffffffffffffffffffffffffffffffffff166343f015dd866136bd6001866157b1565b61ffff16815181106136df57634e487b7160e01b600052603260045260246000fd5b60200260200101516040518263ffffffff1660e01b815260040161370d919061ffff91909116815260200190565b60206040518083038186803b15801561372557600080fd5b505afa158015613739573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061375d9190615058565b63ffffffff80881660009081526002602090815260408083209388168352929052206001015490915061ffff821614156138245763ffffffff80871660009081526002602090815260408083209387168352929052206001018054806137d357634e487b7160e01b600052603160045260246000fd5b60008281526020902060087fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191820401805463ffffffff600460078516026101000a021916905590556139a1565b63ffffffff8681166000908152600260209081526040808320938716835292905220600190810180549091613858916157d4565b8154811061387657634e487b7160e01b600052603260045260246000fd5b6000918252602080832060088304015463ffffffff8a8116855260028352604080862089831687529093529190932060079092166004026101000a909204909116906001908101906138c890846157b1565b61ffff16815481106138ea57634e487b7160e01b600052603260045260246000fd5b600091825260208083206008830401805460079093166004026101000a63ffffffff8181021990941695841602949094179093558881168252600283526040808320918716835292522060010180548061395457634e487b7160e01b600052603160045260246000fd5b60008281526020902060087fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191820401805463ffffffff600460078516026101000a021916905590555b50806139ac81615857565b915050613686565b5063ffffffff808516600081815260026020908152604080832086861684528252808320938352600690915290208154815460ff90911615157fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008216811783558354610100908190049095169094027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff9094167fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009091161792909217825560018082018054929392613a899284019190614ca1565b5060028281015482820155600392830154929091019190915563ffffffff8581166000908152602092835260408082208584168352909352829020805492517f736990cb4424cb3b541e24055819082dfdec9a3c74c5b7b771350f0cff7ec19593613b0593899361010090920416916001909101904290615440565b60405180910390a1600e546040517fbbefc10a00000000000000000000000000000000000000000000000000000000815263ffffffff8616600482015273ffffffffffffffffffffffffffffffffffffffff9091169063bbefc10a90602401600060405180830381600087803b158015613b7e57600080fd5b505af1158015613b92573d6000803e3d6000fd5b5050600c546040517f01f47e3800000000000000000000000000000000000000000000000000000000815263ffffffff80871660048301528816602482015273ffffffffffffffffffffffffffffffffffffffff90911692506301f47e389150604401600060405180830381600087803b158015613c0f57600080fd5b505af1158015613c23573d6000803e3d6000fd5b5050600f54600d54604080517fa7a62a10000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff938416955063ffe87625945089939092169163a7a62a1091600480820192602092909190829003018186803b158015613ca157600080fd5b505afa158015613cb5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613cd99190614ece565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815263ffffffff9290921660048301526024820152604401612b30565b600082815260076020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff16611b6e57600082815260076020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055613db63390565b73ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b600082815260076020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915290205460ff1615611b6e57600082815260076020908152604080832073ffffffffffffffffffffffffffffffffffffffff8516808552925280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6000805460ff16613f225760405162461bcd60e51b815260206004820152601e60248201527f436f6e74726163742073686f756c6420626520696e697469616c697a656400006044820152606401610c6c565b600d54604080517fa7a62a10000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff169163a7a62a10916004808301926020929190829003018186803b158015613f8d57600080fd5b505afa158015613fa1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fc59190614ece565b90506000613ffb8288604051602001613fe091815260200190565b60405160208183030381529060405280519060200120614b88565b905060006140ae600b60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bc788d466040518163ffffffff1660e01b815260040160206040518083038186803b15801561406a57600080fd5b505afa15801561407e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140a29190615090565b63ffffffff1683614be5565b905063ffffffff86166140c28260016156d8565b146140d357600093505050506142b4565b6040805163ffffffff881660208201529081018990526000906140fa908590606001613fe0565b9050600061410d64010000000083614be5565b600d546040517fe1730ac600000000000000000000000000000000000000000000000000000000815263ffffffff808b1660048301528c16602482015291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063e1730ac69060440160206040518083038186803b15801561418a57600080fd5b505afa15801561419e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906141c29190614ece565b600d546040517fe1730ac600000000000000000000000000000000000000000000000000000000815263ffffffff808c1660048301528c16602482015291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063e1730ac69060440160206040518083038186803b15801561423f57600080fd5b505afa158015614253573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142779190614ece565b905061428881640100000000615774565b6142928385615774565b11156142a85760009750505050505050506142b4565b60019750505050505050505b949350505050565b63ffffffff841660009081526003602052604081205460ff811661434c57505063ffffffff84811660009081526003602090815260408220805460018082018355918452919092206008820401805460079092166004026101000a9093021916909155600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff1690556142b4565b63ffffffff8616600090815260026020908152604080832060039092528220805486939190829061438d57634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020019081526020016000206003015411156143e15760009150506142b4565b63ffffffff8616600090815260026020908152604080832060039092528220805486939190829061442257634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020019081526020016000206003015410156145655760005b8160ff168160ff16101561450d5763ffffffff871660009081526003602052604090208054806144af57634e487b7160e01b600052603160045260246000fd5b60008281526020902060087fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191820401805463ffffffff600460078516026101000a0219169055905580614505816158ec565b91505061446f565b50505063ffffffff80851660009081526003602090815260408220805460018181018355918452919092206008820401805487851660046007909416939093026101000a9283029290940219909316179091556142b4565b60005b8160ff168160ff1610156148945763ffffffff871660009081526002602090815260408083206003909252822080548893919060ff86169081106145bc57634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020019081526020016000206002015411156148825763ffffffff8088166000908152600360209081526040822080546001818101835591845291909220600882040180548a851660046007909416939093026101000a928302929094021990931617909155614661908390615718565b91506000614670600184615808565b60ff1690505b8160ff168111156147695763ffffffff881660009081526003602052604090206146a16001836157d4565b815481106146bf57634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004029054906101000a900463ffffffff16600360008a63ffffffff1663ffffffff168152602001908152602001600020828154811061472357634e487b7160e01b600052603260045260246000fd5b90600052602060002090600891828204019190066004026101000a81548163ffffffff021916908363ffffffff160217905550808061476190615893565b915050614676565b5063ffffffff87166000908152600360205260409020805487919060ff84169081106147a557634e487b7160e01b600052603260045260246000fd5b600091825260208083206008808404909101805460079094166004026101000a63ffffffff8181021990951696851602959095179094559254908a1682526003909252604090205460ff90911610156148775763ffffffff8716600090815260036020526040902080548061482a57634e487b7160e01b600052603160045260246000fd5b60008281526020902060087fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191820401805463ffffffff600460078516026101000a021916905590555b6001925050506142b4565b8061488c816158ec565b915050614568565b5060085463ffffffff871660009081526003602052604090205460ff909116111561491057505063ffffffff80851660009081526003602090815260408220805460018181018355918452919092206008820401805487851660046007909416939093026101000a9283029290940219909316179091556142b4565b50949350505050565b60606000614928836002615774565b6149339060026156d8565b67ffffffffffffffff81111561495957634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015614983576020820181803683370190505b5090507f3000000000000000000000000000000000000000000000000000000000000000816000815181106149c857634e487b7160e01b600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053507f780000000000000000000000000000000000000000000000000000000000000081600181518110614a3957634e487b7160e01b600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506000614a75846002615774565b614a809060016156d8565b90505b6001811115614b39577f303132333435363738396162636465660000000000000000000000000000000085600f1660108110614acf57634e487b7160e01b600052603260045260246000fd5b1a60f81b828281518110614af357634e487b7160e01b600052603260045260246000fd5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535060049490941c93614b3281615893565b9050614a83565b5083156132da5760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610c6c565b6000808383604051602001614ba7929190918252602082015260400190565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190528051602090910120949350505050565b6000816142b4848261590c565b82805482825590600052602060002090600701600890048101928215614c915791602002820160005b83821115614c5f57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614c1b565b8015614c8f5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614c5f565b505b50614c9d929150614cef565b5090565b82805482825590600052602060002090600701600890048101928215614c91576000526020600020916007016008900482015b82811115614c91578254825591600101919060010190614cd4565b5b80821115614c9d5760008155600101614cf0565b803573ffffffffffffffffffffffffffffffffffffffff81168114614d2857600080fd5b919050565b600082601f830112614d3d578081fd5b81356020614d52614d4d836156b4565b615665565b80838252828201915082860187848660051b8901011115614d71578586fd5b855b85811015614d98578135614d8681615975565b84529284019290840190600101614d73565b5090979650505050505050565b803560ff81168114614d2857600080fd5b600080600080600060a08688031215614dcd578081fd5b614dd686614d04565b9450614de460208701614d04565b9350614df260408701614d04565b9250614e0060608701614d04565b9150614e0e60808701614d04565b90509295509295909350565b60006020808385031215614e2c578182fd5b825167ffffffffffffffff811115614e42578283fd5b8301601f81018513614e52578283fd5b8051614e60614d4d826156b4565b80828252848201915084840188868560051b8701011115614e7f578687fd5b8694505b83851015614eaa578051614e9681615962565b835260019490940193918501918501614e83565b50979650505050505050565b600060208284031215614ec7578081fd5b5035919050565b600060208284031215614edf578081fd5b5051919050565b60008060408385031215614ef8578182fd5b82359150614f0860208401614d04565b90509250929050565b600060208284031215614f22578081fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146132da578182fd5b60006020808385031215614f63578182fd5b825167ffffffffffffffff80821115614f7a578384fd5b9084019060408287031215614f8d578384fd5b614f9561563c565b8251614fa081615975565b81528284015182811115614fb2578586fd5b80840193505086601f840112614fc6578485fd5b82519150614fd6614d4d836156b4565b80838252858201915085850189878660051b8801011115614ff5578788fd5b8795505b8486101561502a57805165ffffffffffff81168114615016578889fd5b835260019590950194918601918601614ff9565b50948201949094529695505050505050565b60006020828403121561504d578081fd5b81356132da81615962565b600060208284031215615069578081fd5b81516132da81615962565b600060208284031215615085578081fd5b81356132da81615975565b6000602082840312156150a1578081fd5b81516132da81615975565b600080604083850312156150be578182fd5b82356150c981615975565b9150614f0860208401614d04565b600080600080608085870312156150ec578182fd5b84356150f781615975565b9350602085013567ffffffffffffffff811115615112578283fd5b61511e87828801614d2d565b93505060408501359150606085013561513681615975565b939692955090935050565b600080600060608486031215615155578081fd5b833561516081615975565b9250602084013561517081615962565b9150604084013567ffffffffffffffff81111561518b578182fd5b61519786828701614d2d565b9150509250925092565b600080604083850312156151b3578182fd5b82356151be81615975565b946020939093013593505050565b600080604083850312156151de578182fd5b82356151e981615975565b915060208301356151f981615975565b809150509250929050565b60008060408385031215615216578182fd5b823561522181615975565b9150614f0860208401614da5565b600080600060608486031215615243578081fd5b833561524e81615975565b925061525c60208501614da5565b9150604084013561526c81615975565b809150509250925092565b600060208284031215615288578081fd5b6132da82614da5565b6000815180845260208085019450808401835b838110156152c657815163ffffffff16875295820195908201906001016152a4565b509495945050505050565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161530981601785016020880161582b565b7f206973206d697373696e6720726f6c6520000000000000000000000000000000601791840191820152835161534681602884016020880161582b565b01602801949350505050565b602081526000825180602084015261537181604085016020870161582b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b6020815281511515602082015263ffffffff60208301511660408201526000604083015160a060608401526153db60c0840182615291565b905060608401516080840152608084015160a08401528091505092915050565b600063ffffffff8089168352808816602084015260c0604084015261542360c0840188615291565b606084019690965293909316608082015260a00152509392505050565b6000608080830163ffffffff808916855260208189168187015260408481880152838954615472818790815260200190565b60008c81526020902096509150875b8160078201101561552d57865463ffffffff87821616845263ffffffff81871c8816168487015263ffffffff81861c8816168486015260606154ce8186018984841c1663ffffffff169052565b5063ffffffff818a1c881616848a015260a06154f58186018984841c1663ffffffff169052565b5060c061550d8186018984841c1663ffffffff169052565b5060e090811c908401526001969096019561010090920191600801615481565b9554958181101561554b5763ffffffff878716168352918401916001015b818110156155685763ffffffff87861c8716168352918401916001015b818110156155855763ffffffff87851c8716168352918401916001015b818110156155a9576155a183878960601c1663ffffffff169052565b918401916001015b818110156155c65763ffffffff87891c8716168352918401916001015b818110156155ea576155e283878960a01c1663ffffffff169052565b918401916001015b8181101561560e5761560683878960c01c1663ffffffff169052565b918401916001015b818110156156225760e087901c8352918401915b505080965050505050505082606083015295945050505050565b6040805190810167ffffffffffffffff8111828210171561565f5761565f61594c565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156156ac576156ac61594c565b604052919050565b600067ffffffffffffffff8211156156ce576156ce61594c565b5060051b60200190565b600082198211156156eb576156eb615920565b500190565b600063ffffffff80831681851680830382111561570f5761570f615920565b01949350505050565b600060ff821660ff84168060ff0382111561573557615735615920565b019392505050565b60008261574c5761574c615936565b500490565b600063ffffffff8084168061576857615768615936565b92169190910492915050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156157ac576157ac615920565b500290565b600061ffff838116908316818110156157cc576157cc615920565b039392505050565b6000828210156157e6576157e6615920565b500390565b600063ffffffff838116908316818110156157cc576157cc615920565b600060ff821660ff84168082101561582257615822615920565b90039392505050565b60005b8381101561584657818101518382015260200161582e565b83811115612b7d5750506000910152565b600061ffff82168061586b5761586b615920565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0192915050565b6000816158a2576158a2615920565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600063ffffffff808316818114156158e2576158e2615920565b6001019392505050565b600060ff821660ff81141561590357615903615920565b60010192915050565b60008261591b5761591b615936565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b61ffff8116811461597257600080fd5b50565b63ffffffff8116811461597257600080fdfea26469706673582212207f4c48bc72773a9032fb098a2e226f616af08a56986b7b4247279e6936cebba964736f6c63430008040033

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

Txn Hash Block Value Eth2 PubKey Valid
View All Deposits
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.