ETH Price: $3,418.85 (+3.72%)

Contract

0x46B5Ab6FAb5bc9AFc1Ff074Ff8CC01b242aD5E9E
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Withdraw211213942024-11-05 12:17:3518 days ago1730809055IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000318556.34701502
Claim211213922024-11-05 12:17:1118 days ago1730809031IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000580876.02141096
Withdraw210873232024-10-31 18:09:4722 days ago1730398187IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0015743815.54147395
Withdraw210861252024-10-31 14:09:5922 days ago1730383799IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0025381125.05794857
Withdraw210774482024-10-30 9:04:5924 days ago1730279099IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0006442412.83615141
Withdraw210774412024-10-30 9:03:3524 days ago1730279015IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0005621211.2
Withdraw210699352024-10-29 7:55:5925 days ago1730188559IN
0x46B5Ab6F...242aD5E9E
0 ETH0.00074616.54822482
Withdraw210430652024-10-25 13:55:3528 days ago1729864535IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000875769.36091554
Withdraw210430602024-10-25 13:54:3528 days ago1729864475IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000488719.73730466
Withdraw210430532024-10-25 13:53:1128 days ago1729864391IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0005064310.09040259
Claim210430492024-10-25 13:52:2328 days ago1729864343IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0009975810.3411303
Withdraw210082552024-10-20 17:23:1133 days ago1729444991IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0014380915.37169401
Withdraw210082512024-10-20 17:22:2333 days ago1729444943IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000758715.11673786
Withdraw210082452024-10-20 17:21:1133 days ago1729444871IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000835116.63887921
Claim210082412024-10-20 17:20:2333 days ago1729444823IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0015148515.70321903
Withdraw209977212024-10-19 6:07:3535 days ago1729318055IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0009546810.20456008
Claim209977182024-10-19 6:06:5935 days ago1729318019IN
0x46B5Ab6F...242aD5E9E
0 ETH0.000962219.97444814
Withdraw209823962024-10-17 2:47:5937 days ago1729133279IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0010396911.11324258
Withdraw209823842024-10-17 2:45:3537 days ago1729133135IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0005471810.90225205
Withdraw209732142024-10-15 20:00:5938 days ago1729022459IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0019820521.18597417
Withdraw209529762024-10-13 0:03:5941 days ago1728777839IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0005982911.92061342
Claim209212092024-10-08 13:38:3545 days ago1728394715IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0013209926.09945911
Withdraw209212072024-10-08 13:38:1145 days ago1728394691IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0027308326.95735273
Withdraw209160512024-10-07 20:23:3546 days ago1728332615IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0012740625.38485982
Claim209160482024-10-07 20:22:5946 days ago1728332579IN
0x46B5Ab6F...242aD5E9E
0 ETH0.0025487626.42088436
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:
CresoFlexibleStake

Compiler Version
v0.8.23+commit.f704f362

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, GNU GPLv3 license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2023-11-16
*/

// File: @openzeppelin/contracts/utils/Context.sol
// Linktree - https://linktr.ee/cresowallet
// CRESO Official Staking V2.0
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

//import "hardhat/console.sol";

interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

/**
 * @dev Interface for the optional metadata functions from the ERC20 standard.
 *
 * _Available since v4.1._
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the symbol of the token.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

/*
 * @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: @openzeppelin/contracts/access/Ownable.sol

abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _setOwner(_msgSender());
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _setOwner(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _setOwner(newOwner);
    }

    function _setOwner(address newOwner) private {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

// File: @openzeppelin/contracts/utils/ReentrancyGuard.sol

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
abstract contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and make it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        // On the first call to nonReentrant, _notEntered will be true
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

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

        _;

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

// File: @openzeppelin/contracts/utils/Address.sol

/**
 * @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
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 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 functionCall(target, data, "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");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return _verifyCallResult(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) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(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) {
        require(isContract(target), "Address: delegate call to non-contract");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) private pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // 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

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

// File: "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
    unchecked {
        uint256 oldAllowance = token.allowance(address(this), spender);
        require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
        uint256 newAllowance = oldAllowance - value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}



contract CresoFlexibleStake is Ownable, ReentrancyGuard {
    using SafeERC20 for IERC20Metadata;

    // apy
    uint256 public apy;

    // Accrued token per share
    uint256 public accTokenPerShare;

    uint256 public totalStaked;

    // The block number of the last pool update
    uint256 public lastRewardTimeStamp;

    // The precision factor
    uint256 public PRECISION_FACTOR = uint256(10**12);

    // The staked token
    IERC20Metadata public cresoToken;

    // Info of each user that stakes tokens (cresoToken)
    mapping(address => UserInfo) public userInfo;

    struct UserInfo {
        uint256 amount; // How many staked tokens the user has provided
        uint256 rewardDebt; // Reward debt
    }

    event Deposit(address indexed user, uint256 amount);
    event EmergencyWithdraw(address indexed user, uint256 amount);
    event NewAPY(uint256 apy);
    event TokenRecovery(address indexed token, uint256 amount);
    event Withdraw(address indexed user, uint256 amount);
    event Claim(address indexed user, uint256 amount);

    /**
     * @notice Constructor
     */
    constructor(){
        cresoToken = IERC20Metadata(0x41EA5d41EEACc2D5c4072260945118a13bb7EbCE); //CRESO
        // Set the lastRewardTimeStamp as the current timestamp
        lastRewardTimeStamp = block.timestamp;

        apy = 20; // 20%
    }

    /*
     * @notice Deposit staked tokens and collect reward tokens (if any)
     * @param _amount: amount to withdraw 
     */
    function deposit(uint256 _amount) external nonReentrant {
        UserInfo storage user = userInfo[msg.sender];

        _updatePool();

        if (user.amount > 0) {
            uint256 pending = (user.amount * accTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;
            if (pending > 0) {
                cresoToken.safeTransfer(address(msg.sender), pending);
            }
        }

        if (_amount > 0) {
            totalStaked += _amount;
            user.amount += _amount;
            cresoToken.safeTransferFrom(address(msg.sender), address(this), _amount);
        }

        user.rewardDebt = (user.amount * accTokenPerShare) / PRECISION_FACTOR;

        emit Deposit(msg.sender, _amount);
    }

    /*
     * @notice Withdraw staked tokens and collect reward tokens
     * @param _amount: amount to withdraw
     */
    function withdraw(uint256 _amount) external nonReentrant {
        UserInfo storage user = userInfo[msg.sender];
        require(user.amount >= _amount, "Amount to withdraw too high");

        _updatePool();

        uint256 pending = (user.amount * accTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;

        if (_amount > 0) {
            totalStaked -= _amount;
            user.amount -= _amount;
            cresoToken.safeTransfer(address(msg.sender), _amount);
        }

        if (pending > 0) {
            cresoToken.safeTransfer(address(msg.sender), pending);
        }

        user.rewardDebt = (user.amount * accTokenPerShare) / PRECISION_FACTOR;

        emit Withdraw(msg.sender, _amount);
    }


    /*
     * @notice Collect reward tokens
     */
    function claim() external nonReentrant {
        UserInfo storage user = userInfo[msg.sender];

        _updatePool();

        uint256 pending = (user.amount * accTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;
        require (pending > 0, "No reward to claim"); 
        cresoToken.safeTransfer(address(msg.sender), pending);

        user.rewardDebt = (user.amount * accTokenPerShare) / PRECISION_FACTOR;

        emit Claim(msg.sender, pending);
    }

    /*
     * @notice Withdraw staked tokens without caring about rewards rewards
     * @dev Needs to be for emergency.
     */
    function emergencyWithdraw() external nonReentrant {
        UserInfo storage user = userInfo[msg.sender];
        uint256 amountToTransfer = user.amount;

        uint256 pending = (user.amount * accTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;
        if(pending > 0){
            rewardTreasure += pending;
            _updatePool();
        }

        user.amount = 0;
        user.rewardDebt = 0;
        totalStaked -= amountToTransfer;

        if (amountToTransfer > 0) {
            cresoToken.safeTransfer(address(msg.sender), amountToTransfer);
        }

        emit EmergencyWithdraw(msg.sender, user.amount);
    }

    /*
     * @notice Stop rewards, withdraw all reward
     * @dev Only callable by owner. Needs to be for emergency.
     */
    function emergencyRewardWithdraw(uint256 _amount) external onlyOwner {
        require(_amount <= rewardTreasure, "Exceed withdrawable amount");
        cresoToken.safeTransfer(address(msg.sender), _amount);
        rewardTreasure -= _amount;

        _updatePool();
    }

    /**
     * @notice Allows the owner to recover tokens sent to the contract by mistake
     * @param _token: token address
     * @dev Callable by owner
     */
    function recoverToken(address _token) external onlyOwner {
        require(_token != address(cresoToken), "Operations: Cannot recover staked token");

        uint256 balance = IERC20Metadata(_token).balanceOf(address(this));
        require(balance != 0, "Operations: Cannot recover zero balance");

        IERC20Metadata(_token).safeTransfer(address(msg.sender), balance);

        emit TokenRecovery(_token, balance);
    }

    /*
     * @notice Update APY
     * @dev Only callable by owner. Change APY.
     */
    function updateNewAPY(uint256 _newAPY) external onlyOwner {
        _updatePool();
        apy = _newAPY;
        emit NewAPY(_newAPY);
    }

    /*
     * @notice View function to see pending reward on frontend.
     * @param _user: user address
     * @return Pending reward for a given user
     */
    function pendingReward(address _user) external view returns (uint256) {
        UserInfo storage user = userInfo[_user];
        if (block.timestamp > lastRewardTimeStamp && totalStaked != 0) {
            uint256 multiplier = block.timestamp - lastRewardTimeStamp;
            uint256 estimatedReward = multiplier * (((totalStaked * apy)/100) / (365 days));
            if(estimatedReward > rewardTreasure){
                estimatedReward = rewardTreasure;
            }
            uint256 adjustedTokenPerShare = accTokenPerShare + (estimatedReward * PRECISION_FACTOR) / totalStaked;
            return (user.amount * adjustedTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;
        } else {
            return (user.amount * accTokenPerShare) / PRECISION_FACTOR - user.rewardDebt;
        }
    }

    /*
     * @notice Update reward variables of the given pool to be up-to-date.
     */
    function _updatePool() internal {
        if (block.timestamp <= lastRewardTimeStamp) {
            return;
        }

        if (totalStaked == 0) {
            lastRewardTimeStamp = block.timestamp;
            return;
        }

        uint256 multiplier = block.timestamp - lastRewardTimeStamp;
        uint256 estimatedReward = multiplier * (((totalStaked * apy)/100) / (365 days));
        uint256 realReward = _allocateReward(estimatedReward);
        accTokenPerShare += (realReward * PRECISION_FACTOR) / totalStaked;
        lastRewardTimeStamp = block.timestamp;
    }


    uint256 public rewardTreasure;
    uint256 public rewardAllocated;
    function addRewardTreasure(uint256 _amount) external nonReentrant{
        require( _amount > 0 , "err _amount=0");
        uint256 oldBalance = cresoToken.balanceOf(address(this));
        cresoToken.safeTransferFrom(msg.sender, address(this), _amount);
        uint256 newBalance = cresoToken.balanceOf(address(this));
        uint256 realAmount = newBalance - oldBalance;
        rewardTreasure += realAmount;

        _updatePool();
    }

    function _allocateReward(uint256 amount ) internal returns(uint256){
        uint256 allocatedAmount = amount;
        if( amount >= rewardTreasure ){
            allocatedAmount = rewardTreasure;
        }
        rewardTreasure -= allocatedAmount;
        rewardAllocated += allocatedAmount;
        return allocatedAmount;
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Claim","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"apy","type":"uint256"}],"name":"NewAPY","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"token","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"TokenRecovery","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"PRECISION_FACTOR","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"accTokenPerShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"addRewardTreasure","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"apy","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"cresoToken","outputs":[{"internalType":"contract IERC20Metadata","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"emergencyRewardWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"lastRewardTimeStamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"pendingReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"name":"recoverToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardAllocated","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardTreasure","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newAPY","type":"uint256"}],"name":"updateNewAPY","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userInfo","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405264e8d4a51000600655348015610018575f80fd5b506100223361005a565b60018055600780546001600160a01b0319167341ea5d41eeacc2d5c4072260945118a13bb7ebce1790554260055560146002556100a9565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b611402806100b65f395ff3fe608060405234801561000f575f80fd5b5060043610610132575f3560e01c8063817b1cd2116100b4578063b6b55f2511610079578063b6b55f2514610253578063ccd34cd514610266578063db2e21bc1461026f578063dbda80ca14610277578063f2fde38b1461028a578063f40f0f521461029d575f80fd5b8063817b1cd214610215578063828ac8cd1461021e5780638da5cb5b146102275780638f662915146102375780639be65a6014610240575f80fd5b80633279beab116100fa5780633279beab146101e0578063356c7284146101f35780633bcfc4b8146101fc5780634e71d92d14610205578063715018a61461020d575f80fd5b8063048d015e14610136578063086801eb146101665780631063c0c41461017b5780631959a002146101925780632e1a7d4d146101cd575b5f80fd5b600754610149906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b610179610174366004611208565b6102b0565b005b61018460095481565b60405190815260200161015d565b6101b86101a036600461121f565b60086020525f90815260409020805460019091015482565b6040805192835260208301919091520161015d565b6101796101db366004611208565b610444565b6101796101ee366004611208565b6105ca565b61018460055481565b61018460025481565b61017961067e565b6101796107a5565b61018460045481565b610184600a5481565b5f546001600160a01b0316610149565b61018460035481565b61017961024e36600461121f565b6107d9565b610179610261366004611208565b610994565b61018460065481565b610179610ac6565b610179610285366004611208565b610bc5565b61017961029836600461121f565b610c31565b6101846102ab36600461121f565b610cc8565b6002600154036102db5760405162461bcd60e51b81526004016102d290611245565b60405180910390fd5b60026001558061031d5760405162461bcd60e51b815260206004820152600d60248201526c0657272205f616d6f756e743d3609c1b60448201526064016102d2565b6007546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa158015610363573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610387919061127c565b6007549091506103a2906001600160a01b0316333085610de0565b6007546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa1580156103e8573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061040c919061127c565b90505f61041983836112a7565b90508060095f82825461042c91906112c0565b9091555061043a9050610e51565b5050600180555050565b6002600154036104665760405162461bcd60e51b81526004016102d290611245565b6002600155335f90815260086020526040902080548211156104ca5760405162461bcd60e51b815260206004820152601b60248201527f416d6f756e7420746f20776974686472617720746f6f2068696768000000000060448201526064016102d2565b6104d2610e51565b5f8160010154600654600354845f01546104ec91906112d3565b6104f691906112ea565b61050091906112a7565b9050821561054d578260045f82825461051991906112a7565b90915550508154839083905f906105319084906112a7565b909155505060075461054d906001600160a01b03163385610ef9565b801561056a5760075461056a906001600160a01b03163383610ef9565b600654600354835461057c91906112d3565b61058691906112ea565b600183015560405183815233907f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364906020015b60405180910390a250506001805550565b5f546001600160a01b031633146105f35760405162461bcd60e51b81526004016102d290611309565b6009548111156106455760405162461bcd60e51b815260206004820152601a60248201527f45786365656420776974686472617761626c6520616d6f756e7400000000000060448201526064016102d2565b60075461065c906001600160a01b03163383610ef9565b8060095f82825461066d91906112a7565b9091555061067b9050610e51565b50565b6002600154036106a05760405162461bcd60e51b81526004016102d290611245565b6002600155335f9081526008602052604090206106bb610e51565b5f8160010154600654600354845f01546106d591906112d3565b6106df91906112ea565b6106e991906112a7565b90505f811161072f5760405162461bcd60e51b81526020600482015260126024820152714e6f2072657761726420746f20636c61696d60701b60448201526064016102d2565b600754610746906001600160a01b03163383610ef9565b600654600354835461075891906112d3565b61076291906112ea565b600183015560405181815233907f47cee97cb7acd717b3c0aa1435d004cd5b3c8c57d70dbceb4e4458bbd60e39d4906020015b60405180910390a2505060018055565b5f546001600160a01b031633146107ce5760405162461bcd60e51b81526004016102d290611309565b6107d75f610f2e565b565b5f546001600160a01b031633146108025760405162461bcd60e51b81526004016102d290611309565b6007546001600160a01b03908116908216036108705760405162461bcd60e51b815260206004820152602760248201527f4f7065726174696f6e733a2043616e6e6f74207265636f766572207374616b6560448201526632103a37b5b2b760c91b60648201526084016102d2565b6040516370a0823160e01b81523060048201525f906001600160a01b038316906370a0823190602401602060405180830381865afa1580156108b4573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108d8919061127c565b9050805f036109395760405162461bcd60e51b815260206004820152602760248201527f4f7065726174696f6e733a2043616e6e6f74207265636f766572207a65726f2060448201526662616c616e636560c81b60648201526084016102d2565b61094d6001600160a01b0383163383610ef9565b816001600160a01b03167f14f11966a996e0629572e51064726d2057a80fbd34efc066682c06a71dbb6e988260405161098891815260200190565b60405180910390a25050565b6002600154036109b65760405162461bcd60e51b81526004016102d290611245565b6002600155335f9081526008602052604090206109d1610e51565b805415610a27575f8160010154600654600354845f01546109f291906112d3565b6109fc91906112ea565b610a0691906112a7565b90508015610a2557600754610a25906001600160a01b03163383610ef9565b505b8115610a73578160045f828254610a3e91906112c0565b90915550508054829082905f90610a569084906112c0565b9091555050600754610a73906001600160a01b0316333085610de0565b6006546003548254610a8591906112d3565b610a8f91906112ea565b600182015560405182815233907fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c90602001610795565b600260015403610ae85760405162461bcd60e51b81526004016102d290611245565b60026001908155335f90815260086020526040812080549281015460065460035492949392610b1790856112d3565b610b2191906112ea565b610b2b91906112a7565b90508015610b52578060095f828254610b4491906112c0565b90915550610b529050610e51565b5f8084556001840181905560048054849290610b6f9084906112a7565b90915550508115610b9157600754610b91906001600160a01b03163384610ef9565b825460405190815233907f5fafa99d0643513820be26656b45130b01e1c03062e1266bf36f88cbd3bd9695906020016105b9565b5f546001600160a01b03163314610bee5760405162461bcd60e51b81526004016102d290611309565b610bf6610e51565b60028190556040518181527fdf6a785a3f6f4690f12091be4b76d03b768c8f82a8d1612aac2f53cb2b7a9cad9060200160405180910390a150565b5f546001600160a01b03163314610c5a5760405162461bcd60e51b81526004016102d290611309565b6001600160a01b038116610cbf5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016102d2565b61067b81610f2e565b6001600160a01b0381165f90815260086020526040812060055442118015610cf1575060045415155b15610dae575f60055442610d0591906112a7565b90505f6301e133806064600254600454610d1f91906112d3565b610d2991906112ea565b610d3391906112ea565b610d3d90836112d3565b9050600954811115610d4e57506009545b5f60045460065483610d6091906112d3565b610d6a91906112ea565b600354610d7791906112c0565b9050836001015460065482865f0154610d9091906112d3565b610d9a91906112ea565b610da491906112a7565b9695505050505050565b60018101546006546003548354610dc591906112d3565b610dcf91906112ea565b610dd991906112a7565b9392505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610e4b9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610f7d565b50505050565b6005544211610e5c57565b6004545f03610e6b5742600555565b5f60055442610e7a91906112a7565b90505f6301e133806064600254600454610e9491906112d3565b610e9e91906112ea565b610ea891906112ea565b610eb290836112d3565b90505f610ebe8261104e565b905060045460065482610ed191906112d3565b610edb91906112ea565b60035f828254610eeb91906112c0565b909155505042600555505050565b6040516001600160a01b038316602482015260448101829052610f2990849063a9059cbb60e01b90606401610e14565b505050565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f610fd1826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166110959092919063ffffffff16565b805190915015610f295780806020019051810190610fef919061133e565b610f295760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102d2565b6009545f908290811061106057506009545b8060095f82825461107191906112a7565b9250508190555080600a5f82825461108991906112c0565b90915550909392505050565b60606110a384845f856110ab565b949350505050565b60608247101561110c5760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102d2565b843b61115a5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102d2565b5f80866001600160a01b03168587604051611175919061137f565b5f6040518083038185875af1925050503d805f81146111af576040519150601f19603f3d011682016040523d82523d5f602084013e6111b4565b606091505b50915091506111c48282866111cf565b979650505050505050565b606083156111de575081610dd9565b8251156111ee5782518084602001fd5b8160405162461bcd60e51b81526004016102d2919061139a565b5f60208284031215611218575f80fd5b5035919050565b5f6020828403121561122f575f80fd5b81356001600160a01b0381168114610dd9575f80fd5b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b5f6020828403121561128c575f80fd5b5051919050565b634e487b7160e01b5f52601160045260245ffd5b818103818111156112ba576112ba611293565b92915050565b808201808211156112ba576112ba611293565b80820281158282048414176112ba576112ba611293565b5f8261130457634e487b7160e01b5f52601260045260245ffd5b500490565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b5f6020828403121561134e575f80fd5b81518015158114610dd9575f80fd5b5f5b8381101561137757818101518382015260200161135f565b50505f910152565b5f825161139081846020870161135d565b9190910192915050565b602081525f82518060208401526113b881604085016020870161135d565b601f01601f1916919091016040019291505056fea26469706673582212205bea6cd3cbcbc2875e03eba174ed4cc714224cb185542a4f2612f21e3474aa1464736f6c63430008170033

Deployed Bytecode

0x608060405234801561000f575f80fd5b5060043610610132575f3560e01c8063817b1cd2116100b4578063b6b55f2511610079578063b6b55f2514610253578063ccd34cd514610266578063db2e21bc1461026f578063dbda80ca14610277578063f2fde38b1461028a578063f40f0f521461029d575f80fd5b8063817b1cd214610215578063828ac8cd1461021e5780638da5cb5b146102275780638f662915146102375780639be65a6014610240575f80fd5b80633279beab116100fa5780633279beab146101e0578063356c7284146101f35780633bcfc4b8146101fc5780634e71d92d14610205578063715018a61461020d575f80fd5b8063048d015e14610136578063086801eb146101665780631063c0c41461017b5780631959a002146101925780632e1a7d4d146101cd575b5f80fd5b600754610149906001600160a01b031681565b6040516001600160a01b0390911681526020015b60405180910390f35b610179610174366004611208565b6102b0565b005b61018460095481565b60405190815260200161015d565b6101b86101a036600461121f565b60086020525f90815260409020805460019091015482565b6040805192835260208301919091520161015d565b6101796101db366004611208565b610444565b6101796101ee366004611208565b6105ca565b61018460055481565b61018460025481565b61017961067e565b6101796107a5565b61018460045481565b610184600a5481565b5f546001600160a01b0316610149565b61018460035481565b61017961024e36600461121f565b6107d9565b610179610261366004611208565b610994565b61018460065481565b610179610ac6565b610179610285366004611208565b610bc5565b61017961029836600461121f565b610c31565b6101846102ab36600461121f565b610cc8565b6002600154036102db5760405162461bcd60e51b81526004016102d290611245565b60405180910390fd5b60026001558061031d5760405162461bcd60e51b815260206004820152600d60248201526c0657272205f616d6f756e743d3609c1b60448201526064016102d2565b6007546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa158015610363573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610387919061127c565b6007549091506103a2906001600160a01b0316333085610de0565b6007546040516370a0823160e01b81523060048201525f916001600160a01b0316906370a0823190602401602060405180830381865afa1580156103e8573d5f803e3d5ffd5b505050506040513d601f19601f8201168201806040525081019061040c919061127c565b90505f61041983836112a7565b90508060095f82825461042c91906112c0565b9091555061043a9050610e51565b5050600180555050565b6002600154036104665760405162461bcd60e51b81526004016102d290611245565b6002600155335f90815260086020526040902080548211156104ca5760405162461bcd60e51b815260206004820152601b60248201527f416d6f756e7420746f20776974686472617720746f6f2068696768000000000060448201526064016102d2565b6104d2610e51565b5f8160010154600654600354845f01546104ec91906112d3565b6104f691906112ea565b61050091906112a7565b9050821561054d578260045f82825461051991906112a7565b90915550508154839083905f906105319084906112a7565b909155505060075461054d906001600160a01b03163385610ef9565b801561056a5760075461056a906001600160a01b03163383610ef9565b600654600354835461057c91906112d3565b61058691906112ea565b600183015560405183815233907f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364906020015b60405180910390a250506001805550565b5f546001600160a01b031633146105f35760405162461bcd60e51b81526004016102d290611309565b6009548111156106455760405162461bcd60e51b815260206004820152601a60248201527f45786365656420776974686472617761626c6520616d6f756e7400000000000060448201526064016102d2565b60075461065c906001600160a01b03163383610ef9565b8060095f82825461066d91906112a7565b9091555061067b9050610e51565b50565b6002600154036106a05760405162461bcd60e51b81526004016102d290611245565b6002600155335f9081526008602052604090206106bb610e51565b5f8160010154600654600354845f01546106d591906112d3565b6106df91906112ea565b6106e991906112a7565b90505f811161072f5760405162461bcd60e51b81526020600482015260126024820152714e6f2072657761726420746f20636c61696d60701b60448201526064016102d2565b600754610746906001600160a01b03163383610ef9565b600654600354835461075891906112d3565b61076291906112ea565b600183015560405181815233907f47cee97cb7acd717b3c0aa1435d004cd5b3c8c57d70dbceb4e4458bbd60e39d4906020015b60405180910390a2505060018055565b5f546001600160a01b031633146107ce5760405162461bcd60e51b81526004016102d290611309565b6107d75f610f2e565b565b5f546001600160a01b031633146108025760405162461bcd60e51b81526004016102d290611309565b6007546001600160a01b03908116908216036108705760405162461bcd60e51b815260206004820152602760248201527f4f7065726174696f6e733a2043616e6e6f74207265636f766572207374616b6560448201526632103a37b5b2b760c91b60648201526084016102d2565b6040516370a0823160e01b81523060048201525f906001600160a01b038316906370a0823190602401602060405180830381865afa1580156108b4573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906108d8919061127c565b9050805f036109395760405162461bcd60e51b815260206004820152602760248201527f4f7065726174696f6e733a2043616e6e6f74207265636f766572207a65726f2060448201526662616c616e636560c81b60648201526084016102d2565b61094d6001600160a01b0383163383610ef9565b816001600160a01b03167f14f11966a996e0629572e51064726d2057a80fbd34efc066682c06a71dbb6e988260405161098891815260200190565b60405180910390a25050565b6002600154036109b65760405162461bcd60e51b81526004016102d290611245565b6002600155335f9081526008602052604090206109d1610e51565b805415610a27575f8160010154600654600354845f01546109f291906112d3565b6109fc91906112ea565b610a0691906112a7565b90508015610a2557600754610a25906001600160a01b03163383610ef9565b505b8115610a73578160045f828254610a3e91906112c0565b90915550508054829082905f90610a569084906112c0565b9091555050600754610a73906001600160a01b0316333085610de0565b6006546003548254610a8591906112d3565b610a8f91906112ea565b600182015560405182815233907fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c90602001610795565b600260015403610ae85760405162461bcd60e51b81526004016102d290611245565b60026001908155335f90815260086020526040812080549281015460065460035492949392610b1790856112d3565b610b2191906112ea565b610b2b91906112a7565b90508015610b52578060095f828254610b4491906112c0565b90915550610b529050610e51565b5f8084556001840181905560048054849290610b6f9084906112a7565b90915550508115610b9157600754610b91906001600160a01b03163384610ef9565b825460405190815233907f5fafa99d0643513820be26656b45130b01e1c03062e1266bf36f88cbd3bd9695906020016105b9565b5f546001600160a01b03163314610bee5760405162461bcd60e51b81526004016102d290611309565b610bf6610e51565b60028190556040518181527fdf6a785a3f6f4690f12091be4b76d03b768c8f82a8d1612aac2f53cb2b7a9cad9060200160405180910390a150565b5f546001600160a01b03163314610c5a5760405162461bcd60e51b81526004016102d290611309565b6001600160a01b038116610cbf5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016102d2565b61067b81610f2e565b6001600160a01b0381165f90815260086020526040812060055442118015610cf1575060045415155b15610dae575f60055442610d0591906112a7565b90505f6301e133806064600254600454610d1f91906112d3565b610d2991906112ea565b610d3391906112ea565b610d3d90836112d3565b9050600954811115610d4e57506009545b5f60045460065483610d6091906112d3565b610d6a91906112ea565b600354610d7791906112c0565b9050836001015460065482865f0154610d9091906112d3565b610d9a91906112ea565b610da491906112a7565b9695505050505050565b60018101546006546003548354610dc591906112d3565b610dcf91906112ea565b610dd991906112a7565b9392505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610e4b9085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610f7d565b50505050565b6005544211610e5c57565b6004545f03610e6b5742600555565b5f60055442610e7a91906112a7565b90505f6301e133806064600254600454610e9491906112d3565b610e9e91906112ea565b610ea891906112ea565b610eb290836112d3565b90505f610ebe8261104e565b905060045460065482610ed191906112d3565b610edb91906112ea565b60035f828254610eeb91906112c0565b909155505042600555505050565b6040516001600160a01b038316602482015260448101829052610f2990849063a9059cbb60e01b90606401610e14565b505050565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f610fd1826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166110959092919063ffffffff16565b805190915015610f295780806020019051810190610fef919061133e565b610f295760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016102d2565b6009545f908290811061106057506009545b8060095f82825461107191906112a7565b9250508190555080600a5f82825461108991906112c0565b90915550909392505050565b60606110a384845f856110ab565b949350505050565b60608247101561110c5760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016102d2565b843b61115a5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016102d2565b5f80866001600160a01b03168587604051611175919061137f565b5f6040518083038185875af1925050503d805f81146111af576040519150601f19603f3d011682016040523d82523d5f602084013e6111b4565b606091505b50915091506111c48282866111cf565b979650505050505050565b606083156111de575081610dd9565b8251156111ee5782518084602001fd5b8160405162461bcd60e51b81526004016102d2919061139a565b5f60208284031215611218575f80fd5b5035919050565b5f6020828403121561122f575f80fd5b81356001600160a01b0381168114610dd9575f80fd5b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b5f6020828403121561128c575f80fd5b5051919050565b634e487b7160e01b5f52601160045260245ffd5b818103818111156112ba576112ba611293565b92915050565b808201808211156112ba576112ba611293565b80820281158282048414176112ba576112ba611293565b5f8261130457634e487b7160e01b5f52601260045260245ffd5b500490565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b5f6020828403121561134e575f80fd5b81518015158114610dd9575f80fd5b5f5b8381101561137757818101518382015260200161135f565b50505f910152565b5f825161139081846020870161135d565b9190910192915050565b602081525f82518060208401526113b881604085016020870161135d565b601f01601f1916919091016040019291505056fea26469706673582212205bea6cd3cbcbc2875e03eba174ed4cc714224cb185542a4f2612f21e3474aa1464736f6c63430008170033

Deployed Bytecode Sourcemap

20314:8332:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20770:32;;;;;-1:-1:-1;;;;;20770:32:0;;;;;;-1:-1:-1;;;;;199:32:1;;;181:51;;169:2;154:18;20770:32:0;;;;;;;;27845:451;;;;;;:::i;:::-;;:::i;:::-;;27772:29;;;;;;;;;574:25:1;;;562:2;547:18;27772:29:0;428:177:1;20869:44:0;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;1075:25:1;;;1131:2;1116:18;;1109:34;;;;1048:18;20869:44:0;901:248:1;22725:740:0;;;;;;:::i;:::-;;:::i;24938:278::-;;;;;;:::i;:::-;;:::i;20615:34::-;;;;;;20432:18;;;;;;23530:473;;;:::i;5305:94::-;;;:::i;20531:26::-;;;;;;27808:30;;;;;;4654:87;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4654:87;;20491:31;;;;;;25393:436;;;;;;:::i;:::-;;:::i;21851:741::-;;;;;;:::i;:::-;;:::i;20687:49::-;;;;;;24144:655;;;:::i;25930:145::-;;;;;;:::i;:::-;;:::i;5554:192::-;;;;;;:::i;:::-;;:::i;26248:818::-;;;;;;:::i;:::-;;:::i;27845:451::-;7647:1;8243:7;;:19;8235:63;;;;-1:-1:-1;;;8235:63:0;;;;;;;:::i;:::-;;;;;;;;;7647:1;8376:7;:18;27930:11;27921:39:::1;;;::::0;-1:-1:-1;;;27921:39:0;;1924:2:1;27921:39:0::1;::::0;::::1;1906:21:1::0;1963:2;1943:18;;;1936:30;-1:-1:-1;;;1982:18:1;;;1975:43;2035:18;;27921:39:0::1;1722:337:1::0;27921:39:0::1;27992:10;::::0;:35:::1;::::0;-1:-1:-1;;;27992:35:0;;28021:4:::1;27992:35;::::0;::::1;181:51:1::0;27971:18:0::1;::::0;-1:-1:-1;;;;;27992:10:0::1;::::0;:20:::1;::::0;154:18:1;;27992:35:0::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;28038:10;::::0;27971:56;;-1:-1:-1;28038:63:0::1;::::0;-1:-1:-1;;;;;28038:10:0::1;28066;28086:4;28093:7:::0;28038:27:::1;:63::i;:::-;28133:10;::::0;:35:::1;::::0;-1:-1:-1;;;28133:35:0;;28162:4:::1;28133:35;::::0;::::1;181:51:1::0;28112:18:0::1;::::0;-1:-1:-1;;;;;28133:10:0::1;::::0;:20:::1;::::0;154:18:1;;28133:35:0::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;28112:56:::0;-1:-1:-1;28179:18:0::1;28200:23;28213:10:::0;28112:56;28200:23:::1;:::i;:::-;28179:44;;28252:10;28234:14;;:28;;;;;;;:::i;:::-;::::0;;;-1:-1:-1;28275:13:0::1;::::0;-1:-1:-1;28275:11:0::1;:13::i;:::-;-1:-1:-1::0;;7603:1:0;8555:22;;-1:-1:-1;;27845:451:0:o;22725:740::-;7647:1;8243:7;;:19;8235:63;;;;-1:-1:-1;;;8235:63:0;;;;;;;:::i;:::-;7647:1;8376:7;:18;22826:10:::1;22793:21;22817:20:::0;;;:8:::1;:20;::::0;;;;22856:11;;:22;-1:-1:-1;22856:22:0::1;22848:62;;;::::0;-1:-1:-1;;;22848:62:0;;2850:2:1;22848:62:0::1;::::0;::::1;2832:21:1::0;2889:2;2869:18;;;2862:30;2928:29;2908:18;;;2901:57;2975:18;;22848:62:0::1;2648:351:1::0;22848:62:0::1;22923:13;:11;:13::i;:::-;22949:15;23021:4;:15;;;23002:16;;22982;;22968:4;:11;;;:30;;;;:::i;:::-;22967:51;;;;:::i;:::-;:69;;;;:::i;:::-;22949:87:::0;-1:-1:-1;23053:11:0;;23049:171:::1;;23096:7;23081:11;;:22;;;;;;;:::i;:::-;::::0;;;-1:-1:-1;;23118:22:0;;23133:7;;23118:4;;:11:::1;::::0;:22:::1;::::0;23133:7;;23118:22:::1;:::i;:::-;::::0;;;-1:-1:-1;;23155:10:0::1;::::0;:53:::1;::::0;-1:-1:-1;;;;;23155:10:0::1;23187;23200:7:::0;23155:23:::1;:53::i;:::-;23236:11:::0;;23232:97:::1;;23264:10;::::0;:53:::1;::::0;-1:-1:-1;;;;;23264:10:0::1;23296;23309:7:::0;23264:23:::1;:53::i;:::-;23394:16;::::0;23374::::1;::::0;23360:11;;:30:::1;::::0;23374:16;23360:30:::1;:::i;:::-;23359:51;;;;:::i;:::-;23341:15;::::0;::::1;:69:::0;23428:29:::1;::::0;574:25:1;;;23437:10:0::1;::::0;23428:29:::1;::::0;562:2:1;547:18;23428:29:0::1;;;;;;;;-1:-1:-1::0;;7603:1:0;8555:22;;-1:-1:-1;22725:740:0:o;24938:278::-;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4062:10;4874:23;4866:68;;;;-1:-1:-1;;;4866:68:0;;;;;;;:::i;:::-;25037:14:::1;;25026:7;:25;;25018:64;;;::::0;-1:-1:-1;;;25018:64:0;;3962:2:1;25018:64:0::1;::::0;::::1;3944:21:1::0;4001:2;3981:18;;;3974:30;4040:28;4020:18;;;4013:56;4086:18;;25018:64:0::1;3760:350:1::0;25018:64:0::1;25093:10;::::0;:53:::1;::::0;-1:-1:-1;;;;;25093:10:0::1;25125;25138:7:::0;25093:23:::1;:53::i;:::-;25175:7;25157:14;;:25;;;;;;;:::i;:::-;::::0;;;-1:-1:-1;25195:13:0::1;::::0;-1:-1:-1;25195:11:0::1;:13::i;:::-;24938:278:::0;:::o;23530:473::-;7647:1;8243:7;;:19;8235:63;;;;-1:-1:-1;;;8235:63:0;;;;;;;:::i;:::-;7647:1;8376:7;:18;23613:10:::1;23580:21;23604:20:::0;;;:8:::1;:20;::::0;;;;23637:13:::1;:11;:13::i;:::-;23663:15;23735:4;:15;;;23716:16;;23696;;23682:4;:11;;;:30;;;;:::i;:::-;23681:51;;;;:::i;:::-;:69;;;;:::i;:::-;23663:87;;23780:1;23770:7;:11;23761:43;;;::::0;-1:-1:-1;;;23761:43:0;;4317:2:1;23761:43:0::1;::::0;::::1;4299:21:1::0;4356:2;4336:18;;;4329:30;-1:-1:-1;;;4375:18:1;;;4368:48;4433:18;;23761:43:0::1;4115:342:1::0;23761:43:0::1;23816:10;::::0;:53:::1;::::0;-1:-1:-1;;;;;23816:10:0::1;23848;23861:7:::0;23816:23:::1;:53::i;:::-;23935:16;::::0;23915::::1;::::0;23901:11;;:30:::1;::::0;23915:16;23901:30:::1;:::i;:::-;23900:51;;;;:::i;:::-;23882:15;::::0;::::1;:69:::0;23969:26:::1;::::0;574:25:1;;;23975:10:0::1;::::0;23969:26:::1;::::0;562:2:1;547:18;23969:26:0::1;;;;;;;;-1:-1:-1::0;;7603:1:0;8555:22;;23530:473::o;5305:94::-;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4062:10;4874:23;4866:68;;;;-1:-1:-1;;;4866:68:0;;;;;;;:::i;:::-;5370:21:::1;5388:1;5370:9;:21::i;:::-;5305:94::o:0;25393:436::-;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4062:10;4874:23;4866:68;;;;-1:-1:-1;;;4866:68:0;;;;;;;:::i;:::-;25487:10:::1;::::0;-1:-1:-1;;;;;25487:10:0;;::::1;25469:29:::0;;::::1;::::0;25461:81:::1;;;::::0;-1:-1:-1;;;25461:81:0;;4664:2:1;25461:81:0::1;::::0;::::1;4646:21:1::0;4703:2;4683:18;;;4676:30;4742:34;4722:18;;;4715:62;-1:-1:-1;;;4793:18:1;;;4786:37;4840:19;;25461:81:0::1;4462:403:1::0;25461:81:0::1;25573:47;::::0;-1:-1:-1;;;25573:47:0;;25614:4:::1;25573:47;::::0;::::1;181:51:1::0;25555:15:0::1;::::0;-1:-1:-1;;;;;25573:32:0;::::1;::::0;::::1;::::0;154:18:1;;25573:47:0::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;25555:65;;25639:7;25650:1;25639:12:::0;25631:64:::1;;;::::0;-1:-1:-1;;;25631:64:0;;5072:2:1;25631:64:0::1;::::0;::::1;5054:21:1::0;5111:2;5091:18;;;5084:30;5150:34;5130:18;;;5123:62;-1:-1:-1;;;5201:18:1;;;5194:37;5248:19;;25631:64:0::1;4870:403:1::0;25631:64:0::1;25708:65;-1:-1:-1::0;;;;;25708:35:0;::::1;25752:10;25765:7:::0;25708:35:::1;:65::i;:::-;25805:6;-1:-1:-1::0;;;;;25791:30:0::1;;25813:7;25791:30;;;;574:25:1::0;;562:2;547:18;;428:177;25791:30:0::1;;;;;;;;25450:379;25393:436:::0;:::o;21851:741::-;7647:1;8243:7;;:19;8235:63;;;;-1:-1:-1;;;8235:63:0;;;;;;;:::i;:::-;7647:1;8376:7;:18;21951:10:::1;21918:21;21942:20:::0;;;:8:::1;:20;::::0;;;;21975:13:::1;:11;:13::i;:::-;22005:11:::0;;:15;22001:254:::1;;22037:15;22109:4;:15;;;22090:16;;22070;;22056:4;:11;;;:30;;;;:::i;:::-;22055:51;;;;:::i;:::-;:69;;;;:::i;:::-;22037:87:::0;-1:-1:-1;22143:11:0;;22139:105:::1;;22175:10;::::0;:53:::1;::::0;-1:-1:-1;;;;;22175:10:0::1;22207;22220:7:::0;22175:23:::1;:53::i;:::-;22022:233;22001:254;22271:11:::0;;22267:190:::1;;22314:7;22299:11;;:22;;;;;;;:::i;:::-;::::0;;;-1:-1:-1;;22336:22:0;;22351:7;;22336:4;;:11:::1;::::0;:22:::1;::::0;22351:7;;22336:22:::1;:::i;:::-;::::0;;;-1:-1:-1;;22373:10:0::1;::::0;:72:::1;::::0;-1:-1:-1;;;;;22373:10:0::1;22409;22430:4;22437:7:::0;22373:27:::1;:72::i;:::-;22522:16;::::0;22502::::1;::::0;22488:11;;:30:::1;::::0;22502:16;22488:30:::1;:::i;:::-;22487:51;;;;:::i;:::-;22469:15;::::0;::::1;:69:::0;22556:28:::1;::::0;574:25:1;;;22564:10:0::1;::::0;22556:28:::1;::::0;562:2:1;547:18;22556:28:0::1;428:177:1::0;24144:655:0;7647:1;8243:7;;:19;8235:63;;;;-1:-1:-1;;;8235:63:0;;;;;;;:::i;:::-;7647:1;8376:7;:18;;;24239:10:::1;24206:21;24230:20:::0;;;:8:::1;:20;::::0;;;;24288:11;;24384:15;;::::1;::::0;24365:16:::1;::::0;24345::::1;::::0;24230:20;;24288:11;24206:21;24331:30:::1;::::0;24288:11;24331:30:::1;:::i;:::-;24330:51;;;;:::i;:::-;:69;;;;:::i;:::-;24312:87:::0;-1:-1:-1;24413:11:0;;24410:95:::1;;24458:7;24440:14;;:25;;;;;;;:::i;:::-;::::0;;;-1:-1:-1;24480:13:0::1;::::0;-1:-1:-1;24480:11:0::1;:13::i;:::-;24531:1;24517:15:::0;;;24543::::1;::::0;::::1;:19:::0;;;24573:11:::1;:31:::0;;24588:16;;24531:1;24573:31:::1;::::0;24588:16;;24573:31:::1;:::i;:::-;::::0;;;-1:-1:-1;;24621:20:0;;24617:115:::1;;24658:10;::::0;:62:::1;::::0;-1:-1:-1;;;;;24658:10:0::1;24690;24703:16:::0;24658:23:::1;:62::i;:::-;24779:11:::0;;24749:42:::1;::::0;574:25:1;;;24767:10:0::1;::::0;24749:42:::1;::::0;562:2:1;547:18;24749:42:0::1;428:177:1::0;25930:145:0;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4062:10;4874:23;4866:68;;;;-1:-1:-1;;;4866:68:0;;;;;;;:::i;:::-;25999:13:::1;:11;:13::i;:::-;26023:3;:13:::0;;;26052:15:::1;::::0;574:25:1;;;26052:15:0::1;::::0;562:2:1;547:18;26052:15:0::1;;;;;;;25930:145:::0;:::o;5554:192::-;4700:7;4727:6;-1:-1:-1;;;;;4727:6:0;4062:10;4874:23;4866:68;;;;-1:-1:-1;;;4866:68:0;;;;;;;:::i;:::-;-1:-1:-1;;;;;5643:22:0;::::1;5635:73;;;::::0;-1:-1:-1;;;5635:73:0;;5480:2:1;5635:73:0::1;::::0;::::1;5462:21:1::0;5519:2;5499:18;;;5492:30;5558:34;5538:18;;;5531:62;-1:-1:-1;;;5609:18:1;;;5602:36;5655:19;;5635:73:0::1;5278:402:1::0;5635:73:0::1;5719:19;5729:8;5719:9;:19::i;26248:818::-:0;-1:-1:-1;;;;;26353:15:0;;26309:7;26353:15;;;:8;:15;;;;;26401:19;;26383:15;:37;:57;;;;-1:-1:-1;26424:11:0;;:16;;26383:57;26379:680;;;26457:18;26496:19;;26478:15;:37;;;;:::i;:::-;26457:58;;26530:23;26599:8;26591:3;26586;;26572:11;;:17;;;;:::i;:::-;26571:23;;;;:::i;:::-;26570:38;;;;:::i;:::-;26556:53;;:10;:53;:::i;:::-;26530:79;;26645:14;;26627:15;:32;26624:103;;;-1:-1:-1;26697:14:0;;26624:103;26741:29;26831:11;;26811:16;;26793:15;:34;;;;:::i;:::-;26792:50;;;;:::i;:::-;26773:16;;:69;;;;:::i;:::-;26741:101;;26923:4;:15;;;26904:16;;26879:21;26865:4;:11;;;:35;;;;:::i;:::-;26864:56;;;;:::i;:::-;:74;;;;:::i;:::-;26857:81;26248:818;-1:-1:-1;;;;;;26248:818:0:o;26379:680::-;27032:15;;;;27013:16;;26993;;26979:11;;:30;;26993:16;26979:30;:::i;:::-;26978:51;;;;:::i;:::-;:69;;;;:::i;:::-;26971:76;26248:818;-1:-1:-1;;;26248:818:0:o;17257:248::-;17428:68;;-1:-1:-1;;;;;5943:15:1;;;17428:68:0;;;5925:34:1;5995:15;;5975:18;;;5968:43;6027:18;;;6020:34;;;17401:96:0;;17421:5;;-1:-1:-1;;;17451:27:0;5860:18:1;;17428:68:0;;;;-1:-1:-1;;17428:68:0;;;;;;;;;;;;;;-1:-1:-1;;;;;17428:68:0;-1:-1:-1;;;;;;17428:68:0;;;;;;;;;;17401:19;:96::i;:::-;17257:248;;;;:::o;27167:595::-;27233:19;;27214:15;:38;27210:77;;27167:595::o;27210:77::-;27303:11;;27318:1;27303:16;27299:107;;27358:15;27336:19;:37;27167:595::o;27299:107::-;27418:18;27457:19;;27439:15;:37;;;;:::i;:::-;27418:58;;27487:23;27556:8;27548:3;27543;;27529:11;;:17;;;;:::i;:::-;27528:23;;;;:::i;:::-;27527:38;;;;:::i;:::-;27513:53;;:10;:53;:::i;:::-;27487:79;;27577:18;27598:32;27614:15;27598;:32::i;:::-;27577:53;;27695:11;;27675:16;;27662:10;:29;;;;:::i;:::-;27661:45;;;;:::i;:::-;27641:16;;:65;;;;;;;:::i;:::-;;;;-1:-1:-1;;27739:15:0;27717:19;:37;-1:-1:-1;;;27167:595:0:o;17038:211::-;17182:58;;-1:-1:-1;;;;;6257:32:1;;17182:58:0;;;6239:51:1;6306:18;;;6299:34;;;17155:86:0;;17175:5;;-1:-1:-1;;;17205:23:0;6212:18:1;;17182:58:0;6065:274:1;17155:86:0;17038:211;;;:::o;5754:173::-;5810:16;5829:6;;-1:-1:-1;;;;;5846:17:0;;;-1:-1:-1;;;;;;5846:17:0;;;;;;5879:40;;5829:6;;;;;;;5879:40;;5810:16;5879:40;5799:128;5754:173;:::o;19587:716::-;20011:23;20037:69;20065:4;20037:69;;;;;;;;;;;;;;;;;20045:5;-1:-1:-1;;;;;20037:27:0;;;:69;;;;;:::i;:::-;20121:17;;20011:95;;-1:-1:-1;20121:21:0;20117:179;;20218:10;20207:30;;;;;;;;;;;;:::i;:::-;20199:85;;;;-1:-1:-1;;;20199:85:0;;6828:2:1;20199:85:0;;;6810:21:1;6867:2;6847:18;;;6840:30;6906:34;6886:18;;;6879:62;-1:-1:-1;;;6957:18:1;;;6950:40;7007:19;;20199:85:0;6626:406:1;28304:339:0;28439:14;;28363:7;;28408:6;;28429:24;;28425:89;;-1:-1:-1;28488:14:0;;28425:89;28542:15;28524:14;;:33;;;;;;;:::i;:::-;;;;;;;;28587:15;28568;;:34;;;;;;;:::i;:::-;;;;-1:-1:-1;28620:15:0;;28304:339;-1:-1:-1;;;28304:339:0:o;12133:229::-;12270:12;12302:52;12324:6;12332:4;12338:1;12341:12;12302:21;:52::i;:::-;12295:59;12133:229;-1:-1:-1;;;;12133:229:0:o;13253:511::-;13423:12;13481:5;13456:21;:30;;13448:81;;;;-1:-1:-1;;;13448:81:0;;7239:2:1;13448:81:0;;;7221:21:1;7278:2;7258:18;;;7251:30;7317:34;7297:18;;;7290:62;-1:-1:-1;;;7368:18:1;;;7361:36;7414:19;;13448:81:0;7037:402:1;13448:81:0;9650:20;;13540:60;;;;-1:-1:-1;;;13540:60:0;;7646:2:1;13540:60:0;;;7628:21:1;7685:2;7665:18;;;7658:30;7724:31;7704:18;;;7697:59;7773:18;;13540:60:0;7444:353:1;13540:60:0;13614:12;13628:23;13655:6;-1:-1:-1;;;;;13655:11:0;13674:5;13681:4;13655:31;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13613:73;;;;13704:52;13722:7;13731:10;13743:12;13704:17;:52::i;:::-;13697:59;13253:511;-1:-1:-1;;;;;;;13253:511:0:o;15722:712::-;15872:12;15901:7;15897:530;;;-1:-1:-1;15932:10:0;15925:17;;15897:530;16046:17;;:21;16042:374;;16244:10;16238:17;16305:15;16292:10;16288:2;16284:19;16277:44;16042:374;16387:12;16380:20;;-1:-1:-1;;;16380:20:0;;;;;;;;:::i;243:180:1:-;302:6;355:2;343:9;334:7;330:23;326:32;323:52;;;371:1;368;361:12;323:52;-1:-1:-1;394:23:1;;243:180;-1:-1:-1;243:180:1:o;610:286::-;669:6;722:2;710:9;701:7;697:23;693:32;690:52;;;738:1;735;728:12;690:52;764:23;;-1:-1:-1;;;;;816:31:1;;806:42;;796:70;;862:1;859;852:12;1362:355;1564:2;1546:21;;;1603:2;1583:18;;;1576:30;1642:33;1637:2;1622:18;;1615:61;1708:2;1693:18;;1362:355::o;2064:184::-;2134:6;2187:2;2175:9;2166:7;2162:23;2158:32;2155:52;;;2203:1;2200;2193:12;2155:52;-1:-1:-1;2226:16:1;;2064:184;-1:-1:-1;2064:184:1:o;2253:127::-;2314:10;2309:3;2305:20;2302:1;2295:31;2345:4;2342:1;2335:15;2369:4;2366:1;2359:15;2385:128;2452:9;;;2473:11;;;2470:37;;;2487:18;;:::i;:::-;2385:128;;;;:::o;2518:125::-;2583:9;;;2604:10;;;2601:36;;;2617:18;;:::i;3004:168::-;3077:9;;;3108;;3125:15;;;3119:22;;3105:37;3095:71;;3146:18;;:::i;3177:217::-;3217:1;3243;3233:132;;3287:10;3282:3;3278:20;3275:1;3268:31;3322:4;3319:1;3312:15;3350:4;3347:1;3340:15;3233:132;-1:-1:-1;3379:9:1;;3177:217::o;3399:356::-;3601:2;3583:21;;;3620:18;;;3613:30;3679:34;3674:2;3659:18;;3652:62;3746:2;3731:18;;3399:356::o;6344:277::-;6411:6;6464:2;6452:9;6443:7;6439:23;6435:32;6432:52;;;6480:1;6477;6470:12;6432:52;6512:9;6506:16;6565:5;6558:13;6551:21;6544:5;6541:32;6531:60;;6587:1;6584;6577:12;7802:250;7887:1;7897:113;7911:6;7908:1;7905:13;7897:113;;;7987:11;;;7981:18;7968:11;;;7961:39;7933:2;7926:10;7897:113;;;-1:-1:-1;;8044:1:1;8026:16;;8019:27;7802:250::o;8057:287::-;8186:3;8224:6;8218:13;8240:66;8299:6;8294:3;8287:4;8279:6;8275:17;8240:66;:::i;:::-;8322:16;;;;;8057:287;-1:-1:-1;;8057:287:1:o;8349:396::-;8498:2;8487:9;8480:21;8461:4;8530:6;8524:13;8573:6;8568:2;8557:9;8553:18;8546:34;8589:79;8661:6;8656:2;8645:9;8641:18;8636:2;8628:6;8624:15;8589:79;:::i;:::-;8729:2;8708:15;-1:-1:-1;;8704:29:1;8689:45;;;;8736:2;8685:54;;8349:396;-1:-1:-1;;8349:396:1:o

Swarm Source

ipfs://5bea6cd3cbcbc2875e03eba174ed4cc714224cb185542a4f2612f21e3474aa14

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.