ETH Price: $3,483.65 (+0.93%)

Contract

0xC53baAAA8595A7A2E7Fee71dB7291b939F696734
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Execute Proposal206117092024-08-26 8:56:23116 days ago1724662583IN
0xC53baAAA...39F696734
0 ETH0.004565678.30220411
Execute Proposal203060852024-07-14 16:57:35159 days ago1720976255IN
0xC53baAAA...39F696734
0 ETH0.000315585.46335911
Vote For Proposa...201873282024-06-28 2:54:23175 days ago1719543263IN
0xC53baAAA...39F696734
0 ETH0.000401766.01945844
Create New Propo...201763942024-06-26 14:14:35177 days ago1719411275IN
0xC53baAAA...39F696734
0 ETH0.0019013410.76866181
Execute Proposal201194862024-06-18 15:18:47185 days ago1718723927IN
0xC53baAAA...39F696734
0 ETH0.0142263813.79274096
Create New Propo...200908312024-06-14 15:06:11189 days ago1718377571IN
0xC53baAAA...39F696734
0 ETH0.015745217.95860163
Execute Proposal200901882024-06-14 12:56:59189 days ago1718369819IN
0xC53baAAA...39F696734
0 ETH0.000656678.70237582
Create New Propo...200413682024-06-07 17:13:23196 days ago1717780403IN
0xC53baAAA...39F696734
0 ETH0.0047129519.48364425
Execute Proposal199116412024-05-20 14:09:35214 days ago1716214175IN
0xC53baAAA...39F696734
0 ETH0.000817211.56545068
Vote For Proposa...198941672024-05-18 3:30:35216 days ago1716003035IN
0xC53baAAA...39F696734
0 ETH0.000278994.38655456
Vote For Proposa...198820062024-05-16 10:41:23218 days ago1715856083IN
0xC53baAAA...39F696734
0 ETH0.000397776.25292758
Vote For Proposa...198760062024-05-15 14:33:47219 days ago1715783627IN
0xC53baAAA...39F696734
0 ETH0.001514621.86396605
Create New Propo...198714072024-05-14 23:09:59220 days ago1715728199IN
0xC53baAAA...39F696734
0 ETH0.000941453.88922333
Execute Proposal198241292024-05-08 8:23:47226 days ago1715156627IN
0xC53baAAA...39F696734
0 ETH0.004135145.44771323
Vote For Proposa...198092832024-05-06 6:32:59228 days ago1714977179IN
0xC53baAAA...39F696734
0 ETH0.000271934.27482018
Vote For Proposa...198070612024-05-05 23:06:11229 days ago1714950371IN
0xC53baAAA...39F696734
0 ETH0.000280754.41562597
Create New Propo...198070352024-05-05 23:00:59229 days ago1714950059IN
0xC53baAAA...39F696734
0 ETH0.010771935.02574299
Vote For Proposa...198067562024-05-05 22:05:11229 days ago1714946711IN
0xC53baAAA...39F696734
0 ETH0.000254384
Create New Propo...197973072024-05-04 14:21:35230 days ago1714832495IN
0xC53baAAA...39F696734
0 ETH0.015133157.06072662
Execute Proposal196650722024-04-16 2:28:23249 days ago1713234503IN
0xC53baAAA...39F696734
0 ETH0.002336128.22631943
Vote For Proposa...196486542024-04-13 19:12:47251 days ago1713035567IN
0xC53baAAA...39F696734
0 ETH0.0011565218.1837635
Vote For Proposa...196451032024-04-13 7:15:35251 days ago1712992535IN
0xC53baAAA...39F696734
0 ETH0.0007258811.41070985
Vote For Proposa...196449672024-04-13 6:48:11251 days ago1712990891IN
0xC53baAAA...39F696734
0 ETH0.0007425611.65191573
Create New Propo...196425592024-04-12 22:40:47252 days ago1712961647IN
0xC53baAAA...39F696734
0 ETH0.004718315.93322282
Execute Proposal195982452024-04-06 17:42:23258 days ago1712425343IN
0xC53baAAA...39F696734
0 ETH0.0376913914.26814599
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
AdminVoting

Compiler Version
v0.8.19+commit.7dd6d404

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion, MIT license
File 1 of 6 : AdminVoting.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.8.19;

import "Address.sol";
import "DelegatedOps.sol";
import "SystemStart.sol";
import "ITokenLocker.sol";

/**
    @title Prisma DAO Admin Voter
    @notice Primary ownership contract for all Prisma contracts. Allows executing
            arbitrary function calls only after a required percentage of PRISMA
            lockers have signalled in favor of performing the action.
 */
contract AdminVoting is DelegatedOps, SystemStart {
    using Address for address;

    event ProposalCreated(
        address indexed account,
        uint256 proposalId,
        Action[] payload,
        uint256 week,
        uint256 requiredWeight
    );
    event ProposalHasMetQuorum(uint256 id, uint256 canExecuteAfter);
    event ProposalExecuted(uint256 proposalId);
    event ProposalCancelled(uint256 proposalId);
    event VoteCast(
        address indexed account,
        uint256 indexed id,
        uint256 weight,
        uint256 proposalCurrentWeight,
        bool hasPassed
    );
    event ProposalCreationMinPctSet(uint256 weight);
    event ProposalPassingPctSet(uint256 pct);

    struct Proposal {
        uint16 week; // week which vote weights are based upon
        uint32 createdAt; // timestamp when the proposal was created
        uint32 canExecuteAfter; // earliest timestamp when proposal can be executed (0 if not passed)
        uint40 currentWeight; //  amount of weight currently voting in favor
        uint40 requiredWeight; // amount of weight required for the proposal to be executed
        bool processed; // set to true once the proposal is processed
    }

    struct Action {
        address target;
        bytes data;
    }

    uint256 public immutable BOOTSTRAP_FINISH;
    uint256 public constant VOTING_PERIOD = 1 weeks;
    uint256 public constant MIN_TIME_TO_EXECUTION = 1 days;
    uint256 public constant MAX_TIME_TO_EXECUTION = 3 weeks;
    uint256 public constant MIN_TIME_BETWEEN_PROPOSALS = 1 weeks;
    uint256 public constant SET_GUARDIAN_PASSING_PCT = 5010;

    ITokenLocker public immutable tokenLocker;
    IPrismaCore public immutable prismaCore;

    Proposal[] proposalData;
    mapping(uint256 => Action[]) proposalPayloads;

    // account -> ID -> amount of weight voted in favor
    mapping(address => mapping(uint256 => uint256)) public accountVoteWeights;

    mapping(address account => uint256 timestamp) public latestProposalTimestamp;

    // percentages are expressed as a whole number out of `MAX_PCT`
    uint256 public constant MAX_PCT = 10000;
    // percent of total weight required to create a new proposal
    uint256 public minCreateProposalPct;
    // percent of total weight that must vote for a proposal before it can be executed
    uint256 public passingPct;

    constructor(
        address _prismaCore,
        ITokenLocker _tokenLocker,
        uint256 _minCreateProposalPct,
        uint256 _passingPct,
        uint256 _bootstrapFinish
    ) SystemStart(_prismaCore) {
        tokenLocker = _tokenLocker;
        prismaCore = IPrismaCore(_prismaCore);

        minCreateProposalPct = _minCreateProposalPct;
        passingPct = _passingPct;

        BOOTSTRAP_FINISH = _bootstrapFinish;
    }

    /**
        @notice The total number of votes created
     */
    function getProposalCount() external view returns (uint256) {
        return proposalData.length;
    }

    function minCreateProposalWeight() public view returns (uint256) {
        uint256 week = getWeek();
        if (week == 0) return 0;
        week -= 1;

        uint256 totalWeight = tokenLocker.getTotalWeightAt(week);
        return (totalWeight * minCreateProposalPct) / MAX_PCT;
    }

    /**
        @notice Gets information on a specific proposal
     */
    function getProposalData(
        uint256 id
    )
        external
        view
        returns (
            uint256 week,
            uint256 createdAt,
            uint256 currentWeight,
            uint256 requiredWeight,
            uint256 canExecuteAfter,
            bool executed,
            bool canExecute,
            Action[] memory payload
        )
    {
        Proposal memory proposal = proposalData[id];
        payload = proposalPayloads[id];
        canExecute = (!proposal.processed &&
            proposal.currentWeight >= proposal.requiredWeight &&
            proposal.canExecuteAfter < block.timestamp &&
            proposal.canExecuteAfter + MAX_TIME_TO_EXECUTION > block.timestamp);

        return (
            proposal.week,
            proposal.createdAt,
            proposal.currentWeight,
            proposal.requiredWeight,
            proposal.canExecuteAfter,
            proposal.processed,
            canExecute,
            payload
        );
    }

    /**
        @notice Create a new proposal
        @param payload Tuple of [(target address, calldata), ... ] to be
                       executed if the proposal is passed.
     */
    function createNewProposal(address account, Action[] calldata payload) external callerOrDelegated(account) {
        require(payload.length > 0, "Empty payload");

        require(
            latestProposalTimestamp[account] + MIN_TIME_BETWEEN_PROPOSALS < block.timestamp,
            "MIN_TIME_BETWEEN_PROPOSALS"
        );

        // week is set at -1 to the active week so that weights are finalized
        uint256 week = getWeek();
        require(week > 0, "No proposals in first week");
        week -= 1;

        uint256 accountWeight = tokenLocker.getAccountWeightAt(account, week);
        require(accountWeight >= minCreateProposalWeight(), "Not enough weight to propose");

        // if the only action is `prismaCore.setGuardian()`, use
        // `SET_GUARDIAN_PASSING_PCT` instead of `passingPct`
        uint256 _passingPct;
        bool isSetGuardianPayload = _isSetGuardianPayload(payload.length, payload[0]);
        if (isSetGuardianPayload) {
            require(block.timestamp > BOOTSTRAP_FINISH, "Cannot change guardian during bootstrap");
            _passingPct = SET_GUARDIAN_PASSING_PCT;
        } else _passingPct = passingPct;

        uint256 totalWeight = tokenLocker.getTotalWeightAt(week);
        uint40 requiredWeight = uint40((totalWeight * _passingPct) / MAX_PCT);
        require(requiredWeight > 0, "Not enough total lock weight");
        uint256 idx = proposalData.length;
        proposalData.push(
            Proposal({
                week: uint16(week),
                createdAt: uint32(block.timestamp),
                canExecuteAfter: 0,
                currentWeight: 0,
                requiredWeight: requiredWeight,
                processed: false
            })
        );

        for (uint256 i = 0; i < payload.length; i++) {
            proposalPayloads[idx].push(payload[i]);
        }
        latestProposalTimestamp[account] = block.timestamp;
        emit ProposalCreated(account, idx, payload, week, requiredWeight);
    }

    /**
        @notice Vote in favor of a proposal
        @dev Each account can vote once per proposal
        @param id Proposal ID
        @param weight Weight to allocate to this action. If set to zero, the full available
                      account weight is used. Integrating protocols may wish to use partial
                      weight to reflect partial support from their own users.
     */
    function voteForProposal(address account, uint256 id, uint256 weight) external callerOrDelegated(account) {
        require(id < proposalData.length, "Invalid ID");
        require(accountVoteWeights[account][id] == 0, "Already voted");

        Proposal memory proposal = proposalData[id];
        require(!proposal.processed, "Proposal already processed");
        require(proposal.createdAt + VOTING_PERIOD > block.timestamp, "Voting period has closed");

        uint256 accountWeight = tokenLocker.getAccountWeightAt(account, proposal.week);
        if (weight == 0) {
            weight = accountWeight;
            require(weight > 0, "No vote weight");
        } else {
            require(weight <= accountWeight, "Weight exceeds account weight");
        }

        accountVoteWeights[account][id] = weight;
        uint40 updatedWeight = uint40(proposal.currentWeight + weight);
        proposalData[id].currentWeight = updatedWeight;
        bool hasPassed = updatedWeight >= proposal.requiredWeight;

        if (proposal.canExecuteAfter == 0 && hasPassed) {
            uint256 canExecuteAfter = block.timestamp + MIN_TIME_TO_EXECUTION;
            proposalData[id].canExecuteAfter = uint32(canExecuteAfter);
            emit ProposalHasMetQuorum(id, canExecuteAfter);
        }

        emit VoteCast(account, id, weight, updatedWeight, hasPassed);
    }

    /**
        @notice Cancels a pending proposal
        @dev Can only be called by the guardian to avoid malicious proposals
             The guardian cannot cancel a proposal where the only action is
             changing the guardian.
        @param id Proposal ID
     */
    function cancelProposal(uint256 id) external {
        require(msg.sender == prismaCore.guardian(), "Only guardian can cancel proposals");
        require(id < proposalData.length, "Invalid ID");

        Action[] storage payload = proposalPayloads[id];
        require(!_isSetGuardianPayload(payload.length, payload[0]), "Guardian replacement not cancellable");
        proposalData[id].processed = true;
        emit ProposalCancelled(id);
    }

    /**
        @notice Execute a proposal's payload
        @dev Can only be called if the proposal has received sufficient vote weight,
             and has been active for at least `MIN_TIME_TO_EXECUTION`
        @param id Proposal ID
     */
    function executeProposal(uint256 id) external {
        require(id < proposalData.length, "Invalid ID");

        Proposal memory proposal = proposalData[id];
        require(!proposal.processed, "Already processed");

        uint256 executeAfter = proposal.canExecuteAfter;
        require(executeAfter != 0, "Not passed");
        require(executeAfter < block.timestamp, "MIN_TIME_TO_EXECUTION");
        require(executeAfter + MAX_TIME_TO_EXECUTION > block.timestamp, "MAX_TIME_TO_EXECUTION");

        proposalData[id].processed = true;

        Action[] storage payload = proposalPayloads[id];
        uint256 payloadLength = payload.length;

        for (uint256 i = 0; i < payloadLength; i++) {
            payload[i].target.functionCall(payload[i].data);
        }
        emit ProposalExecuted(id);
    }

    /**
        @notice Set the minimum % of the total weight required to create a new proposal
        @dev Only callable via a passing proposal that includes a call
             to this contract and function within it's payload
     */
    function setMinCreateProposalPct(uint256 pct) external returns (bool) {
        require(msg.sender == address(this), "Only callable via proposal");
        require(pct <= MAX_PCT, "Invalid value");
        minCreateProposalPct = pct;
        emit ProposalCreationMinPctSet(pct);
        return true;
    }

    /**
        @notice Set the required % of the total weight that must vote
                for a proposal prior to being able to execute it
        @dev Only callable via a passing proposal that includes a call
             to this contract and function within it's payload
     */
    function setPassingPct(uint256 pct) external returns (bool) {
        require(msg.sender == address(this), "Only callable via proposal");
        require(pct > 0, "pct must be nonzero");
        require(pct <= MAX_PCT, "Invalid value");
        passingPct = pct;
        emit ProposalPassingPctSet(pct);
        return true;
    }

    /**
        @dev Unguarded method to allow accepting ownership transfer of `PrismaCore`
             at the end of the deployment sequence
     */
    function acceptTransferOwnership() external {
        prismaCore.acceptTransferOwnership();
    }

    function _isSetGuardianPayload(uint256 payloadLength, Action memory action) internal view returns (bool) {
        if (payloadLength == 1 && action.target == address(prismaCore)) {
            bytes memory data = action.data;
            // Extract the call sig from payload data
            bytes4 sig;
            assembly {
                sig := mload(add(data, 0x20))
            }
            return sig == IPrismaCore.setGuardian.selector;
        }
        return false;
    }
}

File 2 of 6 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol)

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

File 3 of 6 : DelegatedOps.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.8.19;

/**
    @title Prisma Delegated Operations
    @notice Allows delegation to specific contract functionality. Useful for creating
            wrapper contracts to bundle multiple interactions into a single call.

            Functions that supports delegation should include an `account` input allowing
            the delegated caller to indicate who they are calling on behalf of. In executing
            the call, all internal state updates should be applied for `account` and all
            value transfers should occur to or from the caller.

            For example: a delegated call to `openTrove` should transfer collateral
            from the caller, create the debt position for `account`, and send newly
            minted tokens to the caller.
 */
contract DelegatedOps {
    mapping(address owner => mapping(address caller => bool isApproved)) public isApprovedDelegate;

    modifier callerOrDelegated(address _account) {
        require(msg.sender == _account || isApprovedDelegate[_account][msg.sender], "Delegate not approved");
        _;
    }

    function setDelegateApproval(address _delegate, bool _isApproved) external {
        isApprovedDelegate[msg.sender][_delegate] = _isApproved;
    }
}

File 4 of 6 : SystemStart.sol
// SPDX-License-Identifier: MIT

pragma solidity 0.8.19;

import "IPrismaCore.sol";

/**
    @title Prisma System Start Time
    @dev Provides a unified `startTime` and `getWeek`, used for emissions.
 */
contract SystemStart {
    uint256 immutable startTime;

    constructor(address prismaCore) {
        startTime = IPrismaCore(prismaCore).startTime();
    }

    function getWeek() public view returns (uint256 week) {
        return (block.timestamp - startTime) / 1 weeks;
    }
}

File 5 of 6 : IPrismaCore.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

interface IPrismaCore {
    event FeeReceiverSet(address feeReceiver);
    event GuardianSet(address guardian);
    event NewOwnerAccepted(address oldOwner, address owner);
    event NewOwnerCommitted(address owner, address pendingOwner, uint256 deadline);
    event NewOwnerRevoked(address owner, address revokedOwner);
    event Paused();
    event PriceFeedSet(address priceFeed);
    event Unpaused();

    function acceptTransferOwnership() external;

    function commitTransferOwnership(address newOwner) external;

    function revokeTransferOwnership() external;

    function setFeeReceiver(address _feeReceiver) external;

    function setGuardian(address _guardian) external;

    function setPaused(bool _paused) external;

    function setPriceFeed(address _priceFeed) external;

    function OWNERSHIP_TRANSFER_DELAY() external view returns (uint256);

    function feeReceiver() external view returns (address);

    function guardian() external view returns (address);

    function owner() external view returns (address);

    function ownershipTransferDeadline() external view returns (uint256);

    function paused() external view returns (bool);

    function pendingOwner() external view returns (address);

    function priceFeed() external view returns (address);

    function startTime() external view returns (uint256);
}

File 6 of 6 : ITokenLocker.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

interface ITokenLocker {
    struct LockData {
        uint256 amount;
        uint256 weeksToUnlock;
    }
    struct ExtendLockData {
        uint256 amount;
        uint256 currentWeeks;
        uint256 newWeeks;
    }

    event LockCreated(address indexed account, uint256 amount, uint256 _weeks);
    event LockExtended(address indexed account, uint256 amount, uint256 _weeks, uint256 newWeeks);
    event LocksCreated(address indexed account, LockData[] newLocks);
    event LocksExtended(address indexed account, ExtendLockData[] locks);
    event LocksFrozen(address indexed account, uint256 amount);
    event LocksUnfrozen(address indexed account, uint256 amount);
    event LocksWithdrawn(address indexed account, uint256 withdrawn, uint256 penalty);

    function extendLock(uint256 _amount, uint256 _weeks, uint256 _newWeeks) external returns (bool);

    function extendMany(ExtendLockData[] calldata newExtendLocks) external returns (bool);

    function freeze() external;

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

    function getTotalWeightWrite() external returns (uint256);

    function lock(address _account, uint256 _amount, uint256 _weeks) external returns (bool);

    function lockMany(address _account, LockData[] calldata newLocks) external returns (bool);

    function setPenaltyWithdrawalsEnabled(bool _enabled) external returns (bool);

    function unfreeze(bool keepIncentivesVote) external;

    function withdrawExpiredLocks(uint256 _weeks) external returns (bool);

    function withdrawWithPenalty(uint256 amountToWithdraw) external returns (uint256);

    function MAX_LOCK_WEEKS() external view returns (uint256);

    function PRISMA_CORE() external view returns (address);

    function getAccountActiveLocks(
        address account,
        uint256 minWeeks
    ) external view returns (LockData[] memory lockData, uint256 frozenAmount);

    function getAccountBalances(address account) external view returns (uint256 locked, uint256 unlocked);

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

    function getAccountWeightAt(address account, uint256 week) external view returns (uint256);

    function getTotalWeight() external view returns (uint256);

    function getTotalWeightAt(uint256 week) external view returns (uint256);

    function getWeek() external view returns (uint256 week);

    function getWithdrawWithPenaltyAmounts(
        address account,
        uint256 amountToWithdraw
    ) external view returns (uint256 amountWithdrawn, uint256 penaltyAmountPaid);

    function guardian() external view returns (address);

    function incentiveVoter() external view returns (address);

    function lockToTokenRatio() external view returns (uint256);

    function lockToken() external view returns (address);

    function owner() external view returns (address);

    function penaltyWithdrawalsEnabled() external view returns (bool);

    function prismaCore() external view returns (address);

    function totalDecayRate() external view returns (uint32);

    function totalUpdatedWeek() external view returns (uint16);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_prismaCore","type":"address"},{"internalType":"contract ITokenLocker","name":"_tokenLocker","type":"address"},{"internalType":"uint256","name":"_minCreateProposalPct","type":"uint256"},{"internalType":"uint256","name":"_passingPct","type":"uint256"},{"internalType":"uint256","name":"_bootstrapFinish","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"proposalId","type":"uint256"}],"name":"ProposalCancelled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"proposalId","type":"uint256"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"indexed":false,"internalType":"struct AdminVoting.Action[]","name":"payload","type":"tuple[]"},{"indexed":false,"internalType":"uint256","name":"week","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"requiredWeight","type":"uint256"}],"name":"ProposalCreated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"weight","type":"uint256"}],"name":"ProposalCreationMinPctSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"proposalId","type":"uint256"}],"name":"ProposalExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"canExecuteAfter","type":"uint256"}],"name":"ProposalHasMetQuorum","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"pct","type":"uint256"}],"name":"ProposalPassingPctSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"weight","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"proposalCurrentWeight","type":"uint256"},{"indexed":false,"internalType":"bool","name":"hasPassed","type":"bool"}],"name":"VoteCast","type":"event"},{"inputs":[],"name":"BOOTSTRAP_FINISH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_PCT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_TIME_TO_EXECUTION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_TIME_BETWEEN_PROPOSALS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MIN_TIME_TO_EXECUTION","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SET_GUARDIAN_PASSING_PCT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"VOTING_PERIOD","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"acceptTransferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"accountVoteWeights","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelProposal","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct AdminVoting.Action[]","name":"payload","type":"tuple[]"}],"name":"createNewProposal","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"executeProposal","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getProposalCount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getProposalData","outputs":[{"internalType":"uint256","name":"week","type":"uint256"},{"internalType":"uint256","name":"createdAt","type":"uint256"},{"internalType":"uint256","name":"currentWeight","type":"uint256"},{"internalType":"uint256","name":"requiredWeight","type":"uint256"},{"internalType":"uint256","name":"canExecuteAfter","type":"uint256"},{"internalType":"bool","name":"executed","type":"bool"},{"internalType":"bool","name":"canExecute","type":"bool"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"internalType":"struct AdminVoting.Action[]","name":"payload","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getWeek","outputs":[{"internalType":"uint256","name":"week","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"caller","type":"address"}],"name":"isApprovedDelegate","outputs":[{"internalType":"bool","name":"isApproved","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"latestProposalTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minCreateProposalPct","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minCreateProposalWeight","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"passingPct","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"prismaCore","outputs":[{"internalType":"contract IPrismaCore","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_delegate","type":"address"},{"internalType":"bool","name":"_isApproved","type":"bool"}],"name":"setDelegateApproval","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"pct","type":"uint256"}],"name":"setMinCreateProposalPct","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"pct","type":"uint256"}],"name":"setPassingPct","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"tokenLocker","outputs":[{"internalType":"contract ITokenLocker","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"weight","type":"uint256"}],"name":"voteForProposal","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101006040523480156200001257600080fd5b506040516200272f3803806200272f8339810160408190526200003591620000dc565b84806001600160a01b03166378e979256040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000134565b608052506001600160a01b0393841660c0529390921660e05260055560065560a0526200014e565b6001600160a01b0381168114620000d957600080fd5b50565b600080600080600060a08688031215620000f557600080fd5b85516200010281620000c3565b60208701519095506200011581620000c3565b6040870151606088015160809098015196999198509695945092505050565b6000602082840312156200014757600080fd5b5051919050565b60805160a05160c05160e05161256f620001c06000396000818161027201528181610fe3015281816112790152611b8f0152600081816103390152818161091e01528181610ac9015281816117b20152611aa401526000818161022b0152610a2301526000611061015261256f6000f3fe608060405234801561001057600080fd5b506004361061018e5760003560e01c80638e792050116100de578063b380019711610097578063c3c854b611610071578063c3c854b614610388578063e0a8f6f5146103cc578063e5052fb7146103df578063fb696d6f146103f257600080fd5b8063b380019714610364578063ba4aecee1461036d578063c08cc02d1461038057600080fd5b80638e792050146102f657806397f318b61461032157806399eacd601461032a578063a80bf3e614610334578063ac4cbe761461035b578063b1610d7e146101fb57600080fd5b80635e06f1931161014b5780636e768530116101255780636e768530146102ac5780637b371107146102d3578063874d6d81146102db5780638c76068c146102e357600080fd5b80635e06f193146102265780636318f9e51461024d5780636b2c0ccb1461026d57600080fd5b80630d61b519146101935780631195436b146101a85780631930e825146101bb578063343f8fda146101fb5780633afe957e14610213578063561ac3eb1461021d575b600080fd5b6101a66101a1366004611d71565b6103fa565b005b6101a66101b6366004611da2565b61075c565b6101e66101c9366004611e2a565b600060208181529281526040808220909352908152205460ff1681565b60405190151581526020015b60405180910390f35b61020562093a8081565b6040519081526020016101f2565b610205621baf8081565b61020561139281565b6102057f000000000000000000000000000000000000000000000000000000000000000081565b61020561025b366004611e63565b60046020526000908152604090205481565b6102947f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016101f2565b6102bf6102ba366004611d71565b610da0565b6040516101f2989796959493929190611ed7565b6101a6610fe1565b610205611056565b6101e66102f1366004611d71565b611095565b610205610304366004611f92565b600360209081526000928352604080842090915290825290205481565b61020560065481565b6102056201518081565b6102947f000000000000000000000000000000000000000000000000000000000000000081565b61020560055481565b61020561271081565b6101e661037b366004611d71565b611169565b600154610205565b6101a6610396366004611fbe565b336000908152602081815260408083206001600160a01b0395909516835293905291909120805460ff1916911515919091179055565b6101a66103da366004611d71565b611277565b6101a66103ed366004611ff1565b611541565b610205611a58565b60015481106104245760405162461bcd60e51b815260040161041b90612026565b60405180910390fd5b6000600182815481106104395761043961204a565b60009182526020918290206040805160c081018252929091015461ffff8116835262010000810463ffffffff90811694840194909452600160301b810490931690820152600160501b820464ffffffffff9081166060830152600160781b8304166080820152600160a01b90910460ff1615801560a08301529091506104f55760405162461bcd60e51b8152602060048201526011602482015270105b1c9958591e481c1c9bd8d95cdcd959607a1b604482015260640161041b565b604081015163ffffffff16600081900361053e5760405162461bcd60e51b815260206004820152600a602482015269139bdd081c185cdcd95960b21b604482015260640161041b565b4281106105855760405162461bcd60e51b815260206004820152601560248201527426a4a72faa24a6a2afaa27afa2ac22a1aaaa24a7a760591b604482015260640161041b565b42610593621baf8083612076565b116105d85760405162461bcd60e51b815260206004820152601560248201527426a0ac2faa24a6a2afaa27afa2ac22a1aaaa24a7a760591b604482015260640161041b565b60018084815481106105ec576105ec61204a565b600091825260208083209091018054931515600160a01b0260ff60a01b1990941693909317909255848152600290915260408120805490915b818110156107215761070e8382815481106106425761064261204a565b9060005260206000209060020201600101805461065e90612089565b80601f016020809104026020016040519081016040528092919081815260200182805461068a90612089565b80156106d75780601f106106ac576101008083540402835291602001916106d7565b820191906000526020600020905b8154815290600101906020018083116106ba57829003601f168201915b50505050508483815481106106ee576106ee61204a565b60009182526020909120600290910201546001600160a01b031690611b33565b5080610719816120c3565b915050610625565b506040518581527f712ae1383f79ac853f8d882153778e0260ef8f03b504e2866e0593e04d2b291f9060200160405180910390a15050505050565b82336001600160a01b038216148061079557506001600160a01b03811660009081526020818152604080832033845290915290205460ff165b6107d95760405162461bcd60e51b815260206004820152601560248201527411195b1959d85d19481b9bdd08185c1c1c9bdd9959605a1b604482015260640161041b565b816108165760405162461bcd60e51b815260206004820152600d60248201526c115b5c1d1e481c185e5b1bd859609a1b604482015260640161041b565b6001600160a01b038416600090815260046020526040902054429061083f9062093a8090612076565b1061088c5760405162461bcd60e51b815260206004820152601a60248201527f4d494e5f54494d455f4245545745454e5f50524f504f53414c53000000000000604482015260640161041b565b6000610896611056565b9050600081116108e85760405162461bcd60e51b815260206004820152601a60248201527f4e6f2070726f706f73616c7320696e206669727374207765656b000000000000604482015260640161041b565b6108f36001826120dc565b60405162ff274760e31b81526001600160a01b038781166004830152602482018390529192506000917f000000000000000000000000000000000000000000000000000000000000000016906307f93a3890604401602060405180830381865afa158015610965573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061098991906120ef565b9050610993611a58565b8110156109e25760405162461bcd60e51b815260206004820152601c60248201527f4e6f7420656e6f7567682077656967687420746f2070726f706f736500000000604482015260640161041b565b600080610a1986888184816109f9576109f961204a565b9050602002810190610a0b9190612108565b610a1490612198565b611b80565b90508015610aaa577f00000000000000000000000000000000000000000000000000000000000000004211610aa05760405162461bcd60e51b815260206004820152602760248201527f43616e6e6f74206368616e676520677561726469616e20647572696e6720626f60448201526606f7473747261760cc1b606482015260840161041b565b6113929150610ab0565b60065491505b6040516350735f6f60e01b8152600481018590526000907f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906350735f6f90602401602060405180830381865afa158015610b18573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b3c91906120ef565b90506000612710610b4d8584612246565b610b57919061225d565b905060008164ffffffffff1611610bb05760405162461bcd60e51b815260206004820152601c60248201527f4e6f7420656e6f75676820746f74616c206c6f636b2077656967687400000000604482015260640161041b565b600180546040805160c08101825261ffff808b16825263ffffffff4281166020840190815260009484018581526060850186815264ffffffffff8a81166080880190815260a088018981528a8c018c559a895296517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68a01805495519451935198519b511515600160a01b0260ff60a01b199c8416600160781b029c909c1665ffffffffffff60781b1999909316600160501b0264ffffffffff60501b19948816600160301b02949094166effffffffffffffffff0000000000001995909716620100000265ffffffffffff19909616919097161793909317919091169290921791909117929092169190911793909317909255905b89811015610d375760008281526002602052604090208b8b83818110610cee57610cee61204a565b9050602002810190610d009190612108565b815460018101835560009283526020909220909160020201610d2282826122ce565b50508080610d2f906120c3565b915050610cc6565b506001600160a01b038b1660008181526004602052604090819020429055517f48dd3eb1da9035a25fb1644e9b5f3e5a39a6888d5cd415bad5467791c77149ed90610d8b9084908e908e908d9089906123ea565b60405180910390a25050505050505050505050565b60008060008060008060006060600060018a81548110610dc257610dc261204a565b600091825260208083206040805160c081018252919093015461ffff8116825263ffffffff620100008204811683850152600160301b8204168285015264ffffffffff600160501b820481166060840152600160781b820416608083015260ff600160a01b90910416151560a08201528d84526002825282842080548451818502810185019095528085529195509293909184015b82821015610f30576000848152602090819020604080518082019091526002850290910180546001600160a01b031682526001810180549293919291840191610e9f90612089565b80601f0160208091040260200160405190810160405280929190818152602001828054610ecb90612089565b8015610f185780601f10610eed57610100808354040283529160200191610f18565b820191906000526020600020905b815481529060010190602001808311610efb57829003601f168201915b50505050508152505081526020019060010190610e57565b5050505091508060a00151158015610f5e5750806080015164ffffffffff16816060015164ffffffffff1610155b8015610f73575042816040015163ffffffff16105b8015610f96575042621baf80826040015163ffffffff16610f949190612076565b115b8151602083015160608401516080850151604086015160a09096015161ffff9094169f63ffffffff9384169f5064ffffffffff9283169e5091169b5093169850965094509092509050565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316637b3711076040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561103c57600080fd5b505af1158015611050573d6000803e3d6000fd5b50505050565b600062093a806110867f0000000000000000000000000000000000000000000000000000000000000000426120dc565b611090919061225d565b905090565b60003330146110e65760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c65207669612070726f706f73616c000000000000604482015260640161041b565b6127108211156111285760405162461bcd60e51b815260206004820152600d60248201526c496e76616c69642076616c756560981b604482015260640161041b565b60058290556040518281527f8d1f94446a5b32ed366552dc6d865de8d56664c78fc568bad9d451ba3dceede4906020015b60405180910390a1506001919050565b60003330146111ba5760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c65207669612070726f706f73616c000000000000604482015260640161041b565b600082116112005760405162461bcd60e51b8152602060048201526013602482015272706374206d757374206265206e6f6e7a65726f60681b604482015260640161041b565b6127108211156112425760405162461bcd60e51b815260206004820152600d60248201526c496e76616c69642076616c756560981b604482015260640161041b565b60068290556040518281527f7d98debaf5d867c5b1c938dd5489ca3938acd06771b03b51e1d138b354cb66f590602001611159565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663452a93206040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112d5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112f991906124f7565b6001600160a01b0316336001600160a01b0316146113645760405162461bcd60e51b815260206004820152602260248201527f4f6e6c7920677561726469616e2063616e2063616e63656c2070726f706f73616044820152616c7360f01b606482015260840161041b565b60015481106113855760405162461bcd60e51b815260040161041b90612026565b60008181526002602052604081208054909161147191908390826113ab576113ab61204a565b60009182526020918290206040805180820190915260029092020180546001600160a01b0316825260018101805492939192918401916113ea90612089565b80601f016020809104026020016040519081016040528092919081815260200182805461141690612089565b80156114635780601f1061143857610100808354040283529160200191611463565b820191906000526020600020905b81548152906001019060200180831161144657829003601f168201915b505050505081525050611b80565b156114ca5760405162461bcd60e51b8152602060048201526024808201527f477561726469616e207265706c6163656d656e74206e6f742063616e63656c6c60448201526361626c6560e01b606482015260840161041b565b60018083815481106114de576114de61204a565b60009182526020909120018054911515600160a01b0260ff60a01b199092169190911790556040517f416e669c63d9a3a5e36ee7cc7e2104b8db28ccd286aa18966e98fa230c73b08c906115359084815260200190565b60405180910390a15050565b82336001600160a01b038216148061157a57506001600160a01b03811660009081526020818152604080832033845290915290205460ff165b6115be5760405162461bcd60e51b815260206004820152601560248201527411195b1959d85d19481b9bdd08185c1c1c9bdd9959605a1b604482015260640161041b565b60015483106115df5760405162461bcd60e51b815260040161041b90612026565b6001600160a01b0384166000908152600360209081526040808320868452909152902054156116405760405162461bcd60e51b815260206004820152600d60248201526c105b1c9958591e481d9bdd1959609a1b604482015260640161041b565b6000600184815481106116555761165561204a565b60009182526020918290206040805160c081018252929091015461ffff8116835262010000810463ffffffff90811694840194909452600160301b810490931690820152600160501b820464ffffffffff9081166060830152600160781b8304166080820152600160a01b90910460ff1615801560a083015290915061171d5760405162461bcd60e51b815260206004820152601a60248201527f50726f706f73616c20616c72656164792070726f636573736564000000000000604482015260640161041b565b4262093a80826020015163ffffffff166117379190612076565b116117845760405162461bcd60e51b815260206004820152601860248201527f566f74696e6720706572696f642068617320636c6f7365640000000000000000604482015260640161041b565b805160405162ff274760e31b81526001600160a01b03878116600483015261ffff90921660248201526000917f000000000000000000000000000000000000000000000000000000000000000016906307f93a3890604401602060405180830381865afa1580156117f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061181d91906120ef565b905083600003611870578093506000841161186b5760405162461bcd60e51b815260206004820152600e60248201526d139bc81d9bdd19481dd95a59da1d60921b604482015260640161041b565b6118c0565b808411156118c05760405162461bcd60e51b815260206004820152601d60248201527f5765696768742065786365656473206163636f756e7420776569676874000000604482015260640161041b565b6001600160a01b0386166000908152600360209081526040808320888452909152812085905560608301516118fd90869064ffffffffff16612076565b905080600187815481106119135761191361204a565b6000918252602090912001805464ffffffffff60501b1916600160501b64ffffffffff938416021790556080840151604085015190821691831691909110159063ffffffff161580156119635750805b156119fa5760006119776201518042612076565b9050806001898154811061198d5761198d61204a565b600091825260209182902001805463ffffffff93909316600160301b0269ffffffff0000000000001990931692909217909155604080518a81529182018390527f407448672a34a64678187eff47062769585299ed5e403a11921690eb97a4f135910160405180910390a1505b6040805187815264ffffffffff8416602082015282151581830152905188916001600160a01b038b16917ff8ae44fd949d0d124f4e237255d08733d8bcaf2c2add8526f38f676c170c1c4f9181900360600190a35050505050505050565b600080611a63611056565b905080600003611a7557600091505090565b611a806001826120dc565b6040516350735f6f60e01b8152600481018290529091506000906001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016906350735f6f90602401602060405180830381865afa158015611aeb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b0f91906120ef565b905061271060055482611b229190612246565b611b2c919061225d565b9250505090565b6060611b77838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c65640000815250611bf6565b90505b92915050565b6000826001148015611bc757507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031682600001516001600160a01b0316145b15611bed575060208082015101516001600160e01b031916634506d62560e11b14611b7a565b50600092915050565b606082471015611c575760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161041b565b600080866001600160a01b03168587604051611c739190612514565b60006040518083038185875af1925050503d8060008114611cb0576040519150601f19603f3d011682016040523d82523d6000602084013e611cb5565b606091505b5091509150611cc687838387611cd3565b925050505b949350505050565b60608315611d42578251600003611d3b576001600160a01b0385163b611d3b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161041b565b5081611ccb565b611ccb8383815115611d575781518083602001fd5b8060405162461bcd60e51b815260040161041b9190612526565b600060208284031215611d8357600080fd5b5035919050565b6001600160a01b0381168114611d9f57600080fd5b50565b600080600060408486031215611db757600080fd5b8335611dc281611d8a565b9250602084013567ffffffffffffffff80821115611ddf57600080fd5b818601915086601f830112611df357600080fd5b813581811115611e0257600080fd5b8760208260051b8501011115611e1757600080fd5b6020830194508093505050509250925092565b60008060408385031215611e3d57600080fd5b8235611e4881611d8a565b91506020830135611e5881611d8a565b809150509250929050565b600060208284031215611e7557600080fd5b8135611e8081611d8a565b9392505050565b60005b83811015611ea2578181015183820152602001611e8a565b50506000910152565b60008151808452611ec3816020860160208601611e87565b601f01601f19169290920160200192915050565b60006101008083018b845260208b8186015260408b818701528a606087015289608087015288151560a087015287151560c08701528360e0870152829350865180845261012093508387019450838160051b880101935082880160005b82811015611f7d5788860361011f19018752815180516001600160a01b03168752850151858701859052611f6a85880182611eab565b9786019796505090840190600101611f34565b50939f9e505050505050505050505050505050565b60008060408385031215611fa557600080fd5b8235611fb081611d8a565b946020939093013593505050565b60008060408385031215611fd157600080fd5b8235611fdc81611d8a565b915060208301358015158114611e5857600080fd5b60008060006060848603121561200657600080fd5b833561201181611d8a565b95602085013595506040909401359392505050565b6020808252600a9082015269125b9d985b1a5908125160b21b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115611b7a57611b7a612060565b600181811c9082168061209d57607f821691505b6020821081036120bd57634e487b7160e01b600052602260045260246000fd5b50919050565b6000600182016120d5576120d5612060565b5060010190565b81810381811115611b7a57611b7a612060565b60006020828403121561210157600080fd5b5051919050565b60008235603e1983360301811261211e57600080fd5b9190910192915050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561216157612161612128565b60405290565b604051601f8201601f1916810167ffffffffffffffff8111828210171561219057612190612128565b604052919050565b6000604082360312156121aa57600080fd5b6121b261213e565b82356121bd81611d8a565b815260208381013567ffffffffffffffff808211156121db57600080fd5b9085019036601f8301126121ee57600080fd5b81358181111561220057612200612128565b612212601f8201601f19168501612167565b9150808252368482850101111561222857600080fd5b80848401858401376000908201840152918301919091525092915050565b8082028115828204841417611b7a57611b7a612060565b60008261227a57634e487b7160e01b600052601260045260246000fd5b500490565b601f8211156122c957600081815260208120601f850160051c810160208610156122a65750805b601f850160051c820191505b818110156122c5578281556001016122b2565b5050505b505050565b81356122d981611d8a565b81546001600160a01b0319166001600160a01b0391909116178155600181810160208481013536869003601e1901811261231257600080fd5b8501803567ffffffffffffffff81111561232b57600080fd5b803603838301131561233c57600080fd5b6123508161234a8654612089565b8661227f565b6000601f821160018114612386576000831561236e57508382018501355b600019600385901b1c1916600184901b1786556123df565b600086815260209020601f19841690835b828110156123b657868501880135825593870193908901908701612397565b50848210156123d55760001960f88660031b161c198785880101351681555b50508683881b0186555b505050505050505050565b60006080820187835260206080818501528187835260a08501905060a08860051b86010192508860005b898110156124d357868503609f190183528135368c9003603e1901811261243a57600080fd5b8b016040813561244981611d8a565b6001600160a01b031687528186013536839003601e1901811261246b57600080fd5b90910185810191903567ffffffffffffffff81111561248957600080fd5b80360383131561249857600080fd5b81878901528082890152606091508083838a01376000888201830152601f01601f191690960190950194509183019190830190600101612414565b505050506040830185905264ffffffffff8416606084015290509695505050505050565b60006020828403121561250957600080fd5b8151611e8081611d8a565b6000825161211e818460208701611e87565b602081526000611b776020830184611eab56fea26469706673582212201a3c5d9d3128b231d3d75c87f5f011797da77d3d322e402be34d78fa4a7c0b7f64736f6c634300081300330000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf80000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d00000000000000000000000000000000000000000000000000000000000000640000000000000000000000000000000000000000000000000000000000000bb8000000000000000000000000000000000000000000000000000000006567d080

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061018e5760003560e01c80638e792050116100de578063b380019711610097578063c3c854b611610071578063c3c854b614610388578063e0a8f6f5146103cc578063e5052fb7146103df578063fb696d6f146103f257600080fd5b8063b380019714610364578063ba4aecee1461036d578063c08cc02d1461038057600080fd5b80638e792050146102f657806397f318b61461032157806399eacd601461032a578063a80bf3e614610334578063ac4cbe761461035b578063b1610d7e146101fb57600080fd5b80635e06f1931161014b5780636e768530116101255780636e768530146102ac5780637b371107146102d3578063874d6d81146102db5780638c76068c146102e357600080fd5b80635e06f193146102265780636318f9e51461024d5780636b2c0ccb1461026d57600080fd5b80630d61b519146101935780631195436b146101a85780631930e825146101bb578063343f8fda146101fb5780633afe957e14610213578063561ac3eb1461021d575b600080fd5b6101a66101a1366004611d71565b6103fa565b005b6101a66101b6366004611da2565b61075c565b6101e66101c9366004611e2a565b600060208181529281526040808220909352908152205460ff1681565b60405190151581526020015b60405180910390f35b61020562093a8081565b6040519081526020016101f2565b610205621baf8081565b61020561139281565b6102057f000000000000000000000000000000000000000000000000000000006567d08081565b61020561025b366004611e63565b60046020526000908152604090205481565b6102947f0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf881565b6040516001600160a01b0390911681526020016101f2565b6102bf6102ba366004611d71565b610da0565b6040516101f2989796959493929190611ed7565b6101a6610fe1565b610205611056565b6101e66102f1366004611d71565b611095565b610205610304366004611f92565b600360209081526000928352604080842090915290825290205481565b61020560065481565b6102056201518081565b6102947f0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d81565b61020560055481565b61020561271081565b6101e661037b366004611d71565b611169565b600154610205565b6101a6610396366004611fbe565b336000908152602081815260408083206001600160a01b0395909516835293905291909120805460ff1916911515919091179055565b6101a66103da366004611d71565b611277565b6101a66103ed366004611ff1565b611541565b610205611a58565b60015481106104245760405162461bcd60e51b815260040161041b90612026565b60405180910390fd5b6000600182815481106104395761043961204a565b60009182526020918290206040805160c081018252929091015461ffff8116835262010000810463ffffffff90811694840194909452600160301b810490931690820152600160501b820464ffffffffff9081166060830152600160781b8304166080820152600160a01b90910460ff1615801560a08301529091506104f55760405162461bcd60e51b8152602060048201526011602482015270105b1c9958591e481c1c9bd8d95cdcd959607a1b604482015260640161041b565b604081015163ffffffff16600081900361053e5760405162461bcd60e51b815260206004820152600a602482015269139bdd081c185cdcd95960b21b604482015260640161041b565b4281106105855760405162461bcd60e51b815260206004820152601560248201527426a4a72faa24a6a2afaa27afa2ac22a1aaaa24a7a760591b604482015260640161041b565b42610593621baf8083612076565b116105d85760405162461bcd60e51b815260206004820152601560248201527426a0ac2faa24a6a2afaa27afa2ac22a1aaaa24a7a760591b604482015260640161041b565b60018084815481106105ec576105ec61204a565b600091825260208083209091018054931515600160a01b0260ff60a01b1990941693909317909255848152600290915260408120805490915b818110156107215761070e8382815481106106425761064261204a565b9060005260206000209060020201600101805461065e90612089565b80601f016020809104026020016040519081016040528092919081815260200182805461068a90612089565b80156106d75780601f106106ac576101008083540402835291602001916106d7565b820191906000526020600020905b8154815290600101906020018083116106ba57829003601f168201915b50505050508483815481106106ee576106ee61204a565b60009182526020909120600290910201546001600160a01b031690611b33565b5080610719816120c3565b915050610625565b506040518581527f712ae1383f79ac853f8d882153778e0260ef8f03b504e2866e0593e04d2b291f9060200160405180910390a15050505050565b82336001600160a01b038216148061079557506001600160a01b03811660009081526020818152604080832033845290915290205460ff165b6107d95760405162461bcd60e51b815260206004820152601560248201527411195b1959d85d19481b9bdd08185c1c1c9bdd9959605a1b604482015260640161041b565b816108165760405162461bcd60e51b815260206004820152600d60248201526c115b5c1d1e481c185e5b1bd859609a1b604482015260640161041b565b6001600160a01b038416600090815260046020526040902054429061083f9062093a8090612076565b1061088c5760405162461bcd60e51b815260206004820152601a60248201527f4d494e5f54494d455f4245545745454e5f50524f504f53414c53000000000000604482015260640161041b565b6000610896611056565b9050600081116108e85760405162461bcd60e51b815260206004820152601a60248201527f4e6f2070726f706f73616c7320696e206669727374207765656b000000000000604482015260640161041b565b6108f36001826120dc565b60405162ff274760e31b81526001600160a01b038781166004830152602482018390529192506000917f0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d16906307f93a3890604401602060405180830381865afa158015610965573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061098991906120ef565b9050610993611a58565b8110156109e25760405162461bcd60e51b815260206004820152601c60248201527f4e6f7420656e6f7567682077656967687420746f2070726f706f736500000000604482015260640161041b565b600080610a1986888184816109f9576109f961204a565b9050602002810190610a0b9190612108565b610a1490612198565b611b80565b90508015610aaa577f000000000000000000000000000000000000000000000000000000006567d0804211610aa05760405162461bcd60e51b815260206004820152602760248201527f43616e6e6f74206368616e676520677561726469616e20647572696e6720626f60448201526606f7473747261760cc1b606482015260840161041b565b6113929150610ab0565b60065491505b6040516350735f6f60e01b8152600481018590526000907f0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d6001600160a01b0316906350735f6f90602401602060405180830381865afa158015610b18573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b3c91906120ef565b90506000612710610b4d8584612246565b610b57919061225d565b905060008164ffffffffff1611610bb05760405162461bcd60e51b815260206004820152601c60248201527f4e6f7420656e6f75676820746f74616c206c6f636b2077656967687400000000604482015260640161041b565b600180546040805160c08101825261ffff808b16825263ffffffff4281166020840190815260009484018581526060850186815264ffffffffff8a81166080880190815260a088018981528a8c018c559a895296517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68a01805495519451935198519b511515600160a01b0260ff60a01b199c8416600160781b029c909c1665ffffffffffff60781b1999909316600160501b0264ffffffffff60501b19948816600160301b02949094166effffffffffffffffff0000000000001995909716620100000265ffffffffffff19909616919097161793909317919091169290921791909117929092169190911793909317909255905b89811015610d375760008281526002602052604090208b8b83818110610cee57610cee61204a565b9050602002810190610d009190612108565b815460018101835560009283526020909220909160020201610d2282826122ce565b50508080610d2f906120c3565b915050610cc6565b506001600160a01b038b1660008181526004602052604090819020429055517f48dd3eb1da9035a25fb1644e9b5f3e5a39a6888d5cd415bad5467791c77149ed90610d8b9084908e908e908d9089906123ea565b60405180910390a25050505050505050505050565b60008060008060008060006060600060018a81548110610dc257610dc261204a565b600091825260208083206040805160c081018252919093015461ffff8116825263ffffffff620100008204811683850152600160301b8204168285015264ffffffffff600160501b820481166060840152600160781b820416608083015260ff600160a01b90910416151560a08201528d84526002825282842080548451818502810185019095528085529195509293909184015b82821015610f30576000848152602090819020604080518082019091526002850290910180546001600160a01b031682526001810180549293919291840191610e9f90612089565b80601f0160208091040260200160405190810160405280929190818152602001828054610ecb90612089565b8015610f185780601f10610eed57610100808354040283529160200191610f18565b820191906000526020600020905b815481529060010190602001808311610efb57829003601f168201915b50505050508152505081526020019060010190610e57565b5050505091508060a00151158015610f5e5750806080015164ffffffffff16816060015164ffffffffff1610155b8015610f73575042816040015163ffffffff16105b8015610f96575042621baf80826040015163ffffffff16610f949190612076565b115b8151602083015160608401516080850151604086015160a09096015161ffff9094169f63ffffffff9384169f5064ffffffffff9283169e5091169b5093169850965094509092509050565b7f0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf86001600160a01b0316637b3711076040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561103c57600080fd5b505af1158015611050573d6000803e3d6000fd5b50505050565b600062093a806110867f0000000000000000000000000000000000000000000000000000000064d42880426120dc565b611090919061225d565b905090565b60003330146110e65760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c65207669612070726f706f73616c000000000000604482015260640161041b565b6127108211156111285760405162461bcd60e51b815260206004820152600d60248201526c496e76616c69642076616c756560981b604482015260640161041b565b60058290556040518281527f8d1f94446a5b32ed366552dc6d865de8d56664c78fc568bad9d451ba3dceede4906020015b60405180910390a1506001919050565b60003330146111ba5760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c65207669612070726f706f73616c000000000000604482015260640161041b565b600082116112005760405162461bcd60e51b8152602060048201526013602482015272706374206d757374206265206e6f6e7a65726f60681b604482015260640161041b565b6127108211156112425760405162461bcd60e51b815260206004820152600d60248201526c496e76616c69642076616c756560981b604482015260640161041b565b60068290556040518281527f7d98debaf5d867c5b1c938dd5489ca3938acd06771b03b51e1d138b354cb66f590602001611159565b7f0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf86001600160a01b031663452a93206040518163ffffffff1660e01b8152600401602060405180830381865afa1580156112d5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112f991906124f7565b6001600160a01b0316336001600160a01b0316146113645760405162461bcd60e51b815260206004820152602260248201527f4f6e6c7920677561726469616e2063616e2063616e63656c2070726f706f73616044820152616c7360f01b606482015260840161041b565b60015481106113855760405162461bcd60e51b815260040161041b90612026565b60008181526002602052604081208054909161147191908390826113ab576113ab61204a565b60009182526020918290206040805180820190915260029092020180546001600160a01b0316825260018101805492939192918401916113ea90612089565b80601f016020809104026020016040519081016040528092919081815260200182805461141690612089565b80156114635780601f1061143857610100808354040283529160200191611463565b820191906000526020600020905b81548152906001019060200180831161144657829003601f168201915b505050505081525050611b80565b156114ca5760405162461bcd60e51b8152602060048201526024808201527f477561726469616e207265706c6163656d656e74206e6f742063616e63656c6c60448201526361626c6560e01b606482015260840161041b565b60018083815481106114de576114de61204a565b60009182526020909120018054911515600160a01b0260ff60a01b199092169190911790556040517f416e669c63d9a3a5e36ee7cc7e2104b8db28ccd286aa18966e98fa230c73b08c906115359084815260200190565b60405180910390a15050565b82336001600160a01b038216148061157a57506001600160a01b03811660009081526020818152604080832033845290915290205460ff165b6115be5760405162461bcd60e51b815260206004820152601560248201527411195b1959d85d19481b9bdd08185c1c1c9bdd9959605a1b604482015260640161041b565b60015483106115df5760405162461bcd60e51b815260040161041b90612026565b6001600160a01b0384166000908152600360209081526040808320868452909152902054156116405760405162461bcd60e51b815260206004820152600d60248201526c105b1c9958591e481d9bdd1959609a1b604482015260640161041b565b6000600184815481106116555761165561204a565b60009182526020918290206040805160c081018252929091015461ffff8116835262010000810463ffffffff90811694840194909452600160301b810490931690820152600160501b820464ffffffffff9081166060830152600160781b8304166080820152600160a01b90910460ff1615801560a083015290915061171d5760405162461bcd60e51b815260206004820152601a60248201527f50726f706f73616c20616c72656164792070726f636573736564000000000000604482015260640161041b565b4262093a80826020015163ffffffff166117379190612076565b116117845760405162461bcd60e51b815260206004820152601860248201527f566f74696e6720706572696f642068617320636c6f7365640000000000000000604482015260640161041b565b805160405162ff274760e31b81526001600160a01b03878116600483015261ffff90921660248201526000917f0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d16906307f93a3890604401602060405180830381865afa1580156117f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061181d91906120ef565b905083600003611870578093506000841161186b5760405162461bcd60e51b815260206004820152600e60248201526d139bc81d9bdd19481dd95a59da1d60921b604482015260640161041b565b6118c0565b808411156118c05760405162461bcd60e51b815260206004820152601d60248201527f5765696768742065786365656473206163636f756e7420776569676874000000604482015260640161041b565b6001600160a01b0386166000908152600360209081526040808320888452909152812085905560608301516118fd90869064ffffffffff16612076565b905080600187815481106119135761191361204a565b6000918252602090912001805464ffffffffff60501b1916600160501b64ffffffffff938416021790556080840151604085015190821691831691909110159063ffffffff161580156119635750805b156119fa5760006119776201518042612076565b9050806001898154811061198d5761198d61204a565b600091825260209182902001805463ffffffff93909316600160301b0269ffffffff0000000000001990931692909217909155604080518a81529182018390527f407448672a34a64678187eff47062769585299ed5e403a11921690eb97a4f135910160405180910390a1505b6040805187815264ffffffffff8416602082015282151581830152905188916001600160a01b038b16917ff8ae44fd949d0d124f4e237255d08733d8bcaf2c2add8526f38f676c170c1c4f9181900360600190a35050505050505050565b600080611a63611056565b905080600003611a7557600091505090565b611a806001826120dc565b6040516350735f6f60e01b8152600481018290529091506000906001600160a01b037f0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d16906350735f6f90602401602060405180830381865afa158015611aeb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b0f91906120ef565b905061271060055482611b229190612246565b611b2c919061225d565b9250505090565b6060611b77838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c65640000815250611bf6565b90505b92915050565b6000826001148015611bc757507f0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf86001600160a01b031682600001516001600160a01b0316145b15611bed575060208082015101516001600160e01b031916634506d62560e11b14611b7a565b50600092915050565b606082471015611c575760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b606482015260840161041b565b600080866001600160a01b03168587604051611c739190612514565b60006040518083038185875af1925050503d8060008114611cb0576040519150601f19603f3d011682016040523d82523d6000602084013e611cb5565b606091505b5091509150611cc687838387611cd3565b925050505b949350505050565b60608315611d42578251600003611d3b576001600160a01b0385163b611d3b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161041b565b5081611ccb565b611ccb8383815115611d575781518083602001fd5b8060405162461bcd60e51b815260040161041b9190612526565b600060208284031215611d8357600080fd5b5035919050565b6001600160a01b0381168114611d9f57600080fd5b50565b600080600060408486031215611db757600080fd5b8335611dc281611d8a565b9250602084013567ffffffffffffffff80821115611ddf57600080fd5b818601915086601f830112611df357600080fd5b813581811115611e0257600080fd5b8760208260051b8501011115611e1757600080fd5b6020830194508093505050509250925092565b60008060408385031215611e3d57600080fd5b8235611e4881611d8a565b91506020830135611e5881611d8a565b809150509250929050565b600060208284031215611e7557600080fd5b8135611e8081611d8a565b9392505050565b60005b83811015611ea2578181015183820152602001611e8a565b50506000910152565b60008151808452611ec3816020860160208601611e87565b601f01601f19169290920160200192915050565b60006101008083018b845260208b8186015260408b818701528a606087015289608087015288151560a087015287151560c08701528360e0870152829350865180845261012093508387019450838160051b880101935082880160005b82811015611f7d5788860361011f19018752815180516001600160a01b03168752850151858701859052611f6a85880182611eab565b9786019796505090840190600101611f34565b50939f9e505050505050505050505050505050565b60008060408385031215611fa557600080fd5b8235611fb081611d8a565b946020939093013593505050565b60008060408385031215611fd157600080fd5b8235611fdc81611d8a565b915060208301358015158114611e5857600080fd5b60008060006060848603121561200657600080fd5b833561201181611d8a565b95602085013595506040909401359392505050565b6020808252600a9082015269125b9d985b1a5908125160b21b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115611b7a57611b7a612060565b600181811c9082168061209d57607f821691505b6020821081036120bd57634e487b7160e01b600052602260045260246000fd5b50919050565b6000600182016120d5576120d5612060565b5060010190565b81810381811115611b7a57611b7a612060565b60006020828403121561210157600080fd5b5051919050565b60008235603e1983360301811261211e57600080fd5b9190910192915050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561216157612161612128565b60405290565b604051601f8201601f1916810167ffffffffffffffff8111828210171561219057612190612128565b604052919050565b6000604082360312156121aa57600080fd5b6121b261213e565b82356121bd81611d8a565b815260208381013567ffffffffffffffff808211156121db57600080fd5b9085019036601f8301126121ee57600080fd5b81358181111561220057612200612128565b612212601f8201601f19168501612167565b9150808252368482850101111561222857600080fd5b80848401858401376000908201840152918301919091525092915050565b8082028115828204841417611b7a57611b7a612060565b60008261227a57634e487b7160e01b600052601260045260246000fd5b500490565b601f8211156122c957600081815260208120601f850160051c810160208610156122a65750805b601f850160051c820191505b818110156122c5578281556001016122b2565b5050505b505050565b81356122d981611d8a565b81546001600160a01b0319166001600160a01b0391909116178155600181810160208481013536869003601e1901811261231257600080fd5b8501803567ffffffffffffffff81111561232b57600080fd5b803603838301131561233c57600080fd5b6123508161234a8654612089565b8661227f565b6000601f821160018114612386576000831561236e57508382018501355b600019600385901b1c1916600184901b1786556123df565b600086815260209020601f19841690835b828110156123b657868501880135825593870193908901908701612397565b50848210156123d55760001960f88660031b161c198785880101351681555b50508683881b0186555b505050505050505050565b60006080820187835260206080818501528187835260a08501905060a08860051b86010192508860005b898110156124d357868503609f190183528135368c9003603e1901811261243a57600080fd5b8b016040813561244981611d8a565b6001600160a01b031687528186013536839003601e1901811261246b57600080fd5b90910185810191903567ffffffffffffffff81111561248957600080fd5b80360383131561249857600080fd5b81878901528082890152606091508083838a01376000888201830152601f01601f191690960190950194509183019190830190600101612414565b505050506040830185905264ffffffffff8416606084015290509695505050505050565b60006020828403121561250957600080fd5b8151611e8081611d8a565b6000825161211e818460208701611e87565b602081526000611b776020830184611eab56fea26469706673582212201a3c5d9d3128b231d3d75c87f5f011797da77d3d322e402be34d78fa4a7c0b7f64736f6c63430008130033

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

0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf80000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d00000000000000000000000000000000000000000000000000000000000000640000000000000000000000000000000000000000000000000000000000000bb8000000000000000000000000000000000000000000000000000000006567d080

-----Decoded View---------------
Arg [0] : _prismaCore (address): 0x5d17eA085F2FF5da3e6979D5d26F1dBaB664ccf8
Arg [1] : _tokenLocker (address): 0x3f78544364c3eCcDCe4d9C89a630AEa26122829d
Arg [2] : _minCreateProposalPct (uint256): 100
Arg [3] : _passingPct (uint256): 3000
Arg [4] : _bootstrapFinish (uint256): 1701302400

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 0000000000000000000000005d17ea085f2ff5da3e6979d5d26f1dbab664ccf8
Arg [1] : 0000000000000000000000003f78544364c3eccdce4d9c89a630aea26122829d
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000064
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000bb8
Arg [4] : 000000000000000000000000000000000000000000000000000000006567d080


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

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