ETH Price: $2,625.87 (+1.20%)

Contract

0x6a582983cC19676848Ab32229AD44Fa0c4bA8Ad6
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Unstake154946902022-09-08 5:12:58714 days ago1662613978IN
0x6a582983...0c4bA8Ad6
0 ETH0.0010167412.63780351
Unstake150682692022-07-03 7:43:32781 days ago1656834212IN
0x6a582983...0c4bA8Ad6
0 ETH0.0009465311.76504106
Unstake141387812022-02-04 9:47:44930 days ago1643968064IN
0x6a582983...0c4bA8Ad6
0 ETH0.0036801158.08897668
Unstake137732512021-12-09 20:48:58986 days ago1639082938IN
0x6a582983...0c4bA8Ad6
0 ETH0.0045399471.66113605
Unstake137728452021-12-09 19:23:17986 days ago1639077797IN
0x6a582983...0c4bA8Ad6
0 ETH0.0056778270.57322414
Unstake137277792021-12-02 14:06:58993 days ago1638454018IN
0x6a582983...0c4bA8Ad6
0 ETH0.0060958296.21993326
Unstake137098102021-11-29 17:13:13996 days ago1638205993IN
0x6a582983...0c4bA8Ad6
0 ETH0.00892969140.95135341
Unstake137039072021-11-28 18:15:23997 days ago1638123323IN
0x6a582983...0c4bA8Ad6
0 ETH0.0069839986.80839504
Unstake136987482021-11-27 22:32:31998 days ago1638052351IN
0x6a582983...0c4bA8Ad6
0 ETH0.0049023360.93410839
Unstake136975262021-11-27 17:58:50998 days ago1638035930IN
0x6a582983...0c4bA8Ad6
0 ETH0.0071282988.60196428
Unstake136626432021-11-22 5:29:051004 days ago1637558945IN
0x6a582983...0c4bA8Ad6
0 ETH0.02281349283.5630626
Unstake136528062021-11-20 15:52:311005 days ago1637423551IN
0x6a582983...0c4bA8Ad6
0 ETH0.00690978109.06794669
Unstake136005132021-11-12 9:24:581014 days ago1636709098IN
0x6a582983...0c4bA8Ad6
0 ETH0.00945669149.26992273
Unstake135805162021-11-09 6:10:351017 days ago1636438235IN
0x6a582983...0c4bA8Ad6
0 ETH0.0083605131.96696192
Unstake135799082021-11-09 3:46:391017 days ago1636429599IN
0x6a582983...0c4bA8Ad6
0 ETH0.01143539142.13760842
Unstake135706032021-11-07 17:09:251018 days ago1636304965IN
0x6a582983...0c4bA8Ad6
0 ETH0.01035259128.67884815
Unstake135705512021-11-07 16:57:571018 days ago1636304277IN
0x6a582983...0c4bA8Ad6
0 ETH0.0074281792.32941577
Unstake135705452021-11-07 16:57:161018 days ago1636304236IN
0x6a582983...0c4bA8Ad6
0 ETH0.00735339116.07023857
Unstake135705012021-11-07 16:46:341018 days ago1636303594IN
0x6a582983...0c4bA8Ad6
0 ETH0.00991021123.18014956
Unstake135628412021-11-06 11:59:341020 days ago1636199974IN
0x6a582983...0c4bA8Ad6
0 ETH0.006337378.77024346
Unstake135628322021-11-06 11:57:281020 days ago1636199848IN
0x6a582983...0c4bA8Ad6
0 ETH0.0064895480.66254826
Unstake135626522021-11-06 11:16:521020 days ago1636197412IN
0x6a582983...0c4bA8Ad6
0 ETH0.00604695.43358616
Unstake135620922021-11-06 9:03:161020 days ago1636189396IN
0x6a582983...0c4bA8Ad6
0 ETH0.00639505100.94318563
Unstake133918992021-10-10 16:11:471046 days ago1633882307IN
0x6a582983...0c4bA8Ad6
0 ETH0.0052357179.79691895
Unstake133274392021-09-30 13:50:071056 days ago1633009807IN
0x6a582983...0c4bA8Ad6
0 ETH0.0047515457.44613856
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:
StakingPRY

Compiler Version
v0.6.10+commit.00c0fcaf

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2021-08-05
*/

// Dependency file: @openzeppelin/contracts/token/ERC20/IERC20.sol

// SPDX-License-Identifier: MIT

// pragma solidity ^0.6.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
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);
}


// Dependency file: @openzeppelin/contracts/math/SafeMath.sol


// pragma solidity ^0.6.0;

/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a, "SafeMath: addition overflow");

        return c;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return sub(a, b, "SafeMath: subtraction overflow");
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b <= a, errorMessage);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b, "SafeMath: multiplication overflow");

        return c;
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return div(a, b, "SafeMath: division by zero");
    }

    /**
     * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b > 0, errorMessage);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return mod(a, b, "SafeMath: modulo by zero");
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * Reverts with custom message when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        require(b != 0, errorMessage);
        return a % b;
    }
}


// Dependency file: @openzeppelin/contracts/utils/Address.sol


// pragma solidity ^0.6.2;

/**
 * @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) {
        // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
        // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
        // for accounts without code, i.e. `keccak256('')`
        bytes32 codehash;
        bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
        // solhint-disable-next-line no-inline-assembly
        assembly { codehash := extcodehash(account) }
        return (codehash != accountHash && codehash != 0x0);
    }

    /**
     * @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");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (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");
        return _functionCallWithValue(target, data, value, errorMessage);
    }

    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);
        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

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}


// Dependency file: @openzeppelin/contracts/token/ERC20/SafeERC20.sol


// pragma solidity ^0.6.0;

// import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
// import "@openzeppelin/contracts/math/SafeMath.sol";
// import "@openzeppelin/contracts/utils/Address.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 SafeMath for uint256;
    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'
        // solhint-disable-next-line max-line-length
        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).add(value);
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero");
        _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
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}


// Dependency file: @openzeppelin/contracts/GSN/Context.sol


// pragma solidity ^0.6.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with GSN 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 payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}


// Dependency file: @openzeppelin/contracts/access/Ownable.sol


// pragma solidity ^0.6.0;

// import "@openzeppelin/contracts/GSN/Context.sol";
/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
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 () internal {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view 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 {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}


// Root file: contracts/others/StakingPRY.sol

pragma solidity ^0.6.10;

// import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
// import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";
// import { SafeMath } from "@openzeppelin/contracts/math/SafeMath.sol";
// import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol";

/**
 * @title StakingPRY
 * @author Prophecy
 *
 * Stake PRY earn PRY as reward
 */
contract StakingPRY is Ownable {
    using SafeMath for uint256;
    using SafeERC20 for IERC20;

    /* ============ Constants ============ */

    uint256 constant public ONE_MONTH = 2592000;

    /* ============ State Variables ============ */

    address public token;
    bool public isAcceptStaking = true;
    mapping(address => uint256) public stakeAmount;
    uint256 public totalStaked;
    uint256 public timePenalty;
    uint256 public timeMature;

    /* ============ Constructor ============ */

    constructor(address _token) public {
        token = _token;
    }

    /* ============ External/Public Functions ============ */

    /**
     * Stake PRY
     *
     * @param _amount               Amount of tokens to stake
     */
    function stake(uint256 _amount) public {
        require(isAcceptStaking == true, "staking is not accepted");
        require(_amount >= 1000e18, "cannot invest less than 1k PRY");
        require(_amount.add(stakeAmount[msg.sender]) <= 200000e18, "cannot invest more than 200k PRY");
        require(_amount.add(totalStaked) <= 5000000000e18, "total invest cannot be more than 5m PRY");
        IERC20(token).transferFrom(msg.sender, address(this), _amount);
        stakeAmount[msg.sender] = stakeAmount[msg.sender].add(_amount);
        totalStaked = totalStaked.add(_amount);
    }

    /**
     * Unstake PRY
     */
    function unstake() public {
        address userAddr = msg.sender;
        require(stakeAmount[userAddr] > 0, "no staking amount");

        // if staking is still accepted, you should only the original stake 
        if (isAcceptStaking == true) {
            uint256 amountToUnstake = stakeAmount[userAddr];
            totalStaked = totalStaked.sub(stakeAmount[userAddr]);
            stakeAmount[userAddr] = 0;
            IERC20(token).safeTransfer(userAddr, amountToUnstake);
            return;
        }
        uint256 currentTime = block.timestamp;
        // if you unstakes after 90 days, you should receive the full reward + original stake
        if (timeMature < currentTime) {
            uint256 reward = stakeAmount[userAddr].mul(7).div(100);
            uint256 amountToUnstake = stakeAmount[userAddr].add(reward);
            totalStaked = totalStaked.sub(stakeAmount[userAddr]);
            stakeAmount[userAddr] = 0;
            IERC20(token).safeTransfer(userAddr, amountToUnstake);
            return;
        }
        // if you unstakes from day 31 - 89, you should receive 50% of the reward + original stake
        if (timePenalty < currentTime && currentTime <= timeMature) {
            uint256 reward = stakeAmount[userAddr].mul(7).div(200);
            uint256 amountToUnstake = stakeAmount[userAddr].add(reward);
            totalStaked = totalStaked.sub(stakeAmount[userAddr]);
            stakeAmount[userAddr] = 0;
            IERC20(token).safeTransfer(userAddr, amountToUnstake);
            return;
        }
        // if you unstakes from day 0 - 30, you should only the original stake
        if (currentTime <= timePenalty) {
            uint256 amountToUnstake = stakeAmount[userAddr];
            totalStaked = totalStaked.sub(stakeAmount[userAddr]);
            stakeAmount[userAddr] = 0;
            IERC20(token).safeTransfer(userAddr, amountToUnstake);
            return;
        }
    }

    /**
     * Get total amount of PRY in this pool.
     */
    function getTotalBalance() public view returns (uint256) {
        return IERC20(token).balanceOf(address(this));
    }

    /**
     * Get time left to mature
     */
    function getTimeLeft() public view returns (uint256) {
        uint256 currentTime = block.timestamp;
        if (currentTime > timeMature) {
            return 0;
        } else {
            return timeMature.sub(currentTime);
        }
    }

    /* ============ Owner Functions ============ */

    /**
     * Turn on staking. Users can stake PRYs.
     */
    function turnOnStaking() public onlyOwner() {
        uint256 currentTime = block.timestamp;
        require(currentTime > timeMature, "the time of unstaking has not finished");
        isAcceptStaking = true;
        timeMature = 0;
        timePenalty = 0;
    }

    /**
     * Turn off staking and start reward period. Users can't stake
     */
    function turnOffStaking() public onlyOwner() {
        uint256 currentTime = block.timestamp;
        require(currentTime > timeMature, "the time of unstaking has not finished");
        isAcceptStaking = false;
        timeMature = currentTime.add(ONE_MONTH.mul(3)); // 90 days
        timePenalty = currentTime.add(ONE_MONTH); // 30 days
    }

    /**
     * Withdraw tokens emergency.
     *
     * @param _token                Token contract address
     * @param _to                   Address where the token withdraw to
     * @param _amount               Amount of tokens to withdraw
     */
    function emergencyWithdraw(address _token, address _to, uint256 _amount) external onlyOwner {
        IERC20 erc20Token = IERC20(_token);
        require(erc20Token.balanceOf(address(this)) > 0, "Insufficient balane");

        uint256 amountToWithdraw = _amount;
        if (_amount == 0) {
            amountToWithdraw = erc20Token.balanceOf(address(this));
        }
        erc20Token.safeTransfer(_to, amountToWithdraw);
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_token","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"ONE_MONTH","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_token","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getTimeLeft","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTotalBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isAcceptStaking","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"stake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"stakeAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"timeMature","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"timePenalty","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"address","name":"","type":"address"}],"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":[],"name":"turnOffStaking","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"turnOnStaking","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unstake","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526001805460ff60a01b1916600160a01b17905534801561002357600080fd5b506040516114243803806114248339818101604052602081101561004657600080fd5b5051600061005b6001600160e01b036100ca16565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350600180546001600160a01b0319166001600160a01b03929092169190911790556100ce565b3390565b611347806100dd6000396000f3fe608060405234801561001057600080fd5b506004361061010b5760003560e01c8063817b1cd2116100a2578063c7e284b811610071578063c7e284b8146101d3578063e63ea408146101db578063f2fde38b14610211578063f9e9235414610237578063fc0c546a146102535761010b565b8063817b1cd2146101645780638da5cb5b1461016c578063a694fc3a14610190578063bf135267146101ad5761010b565b80632def6620116100de5780632def66201461014457806357341cb41461014c578063715018a61461015457806376dee2211461015c5761010b565b806312b583491461011057806320988cef1461012a57806321be0cfc1461013257806322c51eb81461013c575b600080fd5b61011861025b565b60408051918252519081900360200190f35b6101186102d8565b61013a6102df565b005b61013a610399565b61013a610480565b6101186106ed565b61013a6106f3565b610118610795565b61011861079b565b6101746107a1565b604080516001600160a01b039092168252519081900360200190f35b61013a600480360360208110156101a657600080fd5b50356107b0565b610118600480360360208110156101c357600080fd5b50356001600160a01b0316610a1e565b610118610a30565b61013a600480360360608110156101f157600080fd5b506001600160a01b03813581169160208101359091169060400135610a64565b61013a6004803603602081101561022757600080fd5b50356001600160a01b0316610c17565b61023f610d0f565b604080519115158252519081900360200190f35b610174610d1f565b600154604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b1580156102a657600080fd5b505afa1580156102ba573d6000803e3d6000fd5b505050506040513d60208110156102d057600080fd5b505190505b90565b62278d0081565b6102e7610d2e565b6000546001600160a01b03908116911614610337576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600554429081116103795760405162461bcd60e51b815260040180806020018281038252602681526020018061125a6026913960400191505060405180910390fd5b506001805460ff60a01b1916600160a01b17905560006005819055600455565b6103a1610d2e565b6000546001600160a01b039081169116146103f1576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600554429081116104335760405162461bcd60e51b815260040180806020018281038252602681526020018061125a6026913960400191505060405180910390fd5b6001805460ff60a01b1916905561046461045762278d00600363ffffffff610d3216565b829063ffffffff610d9416565b60055561047a8162278d0063ffffffff610d9416565b60045550565b336000818152600260205260409020546104d5576040805162461bcd60e51b81526020600482015260116024820152701b9bc81cdd185ada5b99c8185b5bdd5b9d607a1b604482015290519081900360640190fd5b60018054600160a01b900460ff1615151415610550576001600160a01b038116600090815260026020526040902054600354610517908263ffffffff610dee16565b6003556001600160a01b038083166000908152600260205260408120556001546105499116838363ffffffff610e3016565b50506106eb565b6005544290811115610630576001600160a01b0382166000908152600260205260408120546105999060649061058d90600763ffffffff610d3216565b9063ffffffff610e8716565b6001600160a01b038416600090815260026020526040812054919250906105c6908363ffffffff610d9416565b6001600160a01b0385166000908152600260205260409020546003549192506105f5919063ffffffff610dee16565b6003556001600160a01b038085166000908152600260205260408120556001546106279116858363ffffffff610e3016565b505050506106eb565b8060045410801561064357506005548111155b15610679576001600160a01b0382166000908152600260205260408120546105999060c89061058d90600763ffffffff610d3216565b60045481116106e8576001600160a01b0382166000908152600260205260409020546003546106ae908263ffffffff610dee16565b6003556001600160a01b038084166000908152600260205260408120556001546106e09116848363ffffffff610e3016565b5050506106eb565b50505b565b60055481565b6106fb610d2e565b6000546001600160a01b0390811691161461074b576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b60045481565b60035481565b6000546001600160a01b031690565b60018054600160a01b900460ff16151514610812576040805162461bcd60e51b815260206004820152601760248201527f7374616b696e67206973206e6f74206163636570746564000000000000000000604482015290519081900360640190fd5b683635c9adc5dea00000811015610870576040805162461bcd60e51b815260206004820152601e60248201527f63616e6e6f7420696e76657374206c657373207468616e20316b205052590000604482015290519081900360640190fd5b33600090815260026020526040902054692a5a058fc295ed0000009061089d90839063ffffffff610d9416565b11156108f0576040805162461bcd60e51b815260206004820181905260248201527f63616e6e6f7420696e76657374206d6f7265207468616e203230306b20505259604482015290519081900360640190fd5b6b1027e72f1f1281308800000061091260035483610d9490919063ffffffff16565b111561094f5760405162461bcd60e51b81526004018080602001828103825260278152602001806112806027913960400191505060405180910390fd5b600154604080516323b872dd60e01b81523360048201523060248201526044810184905290516001600160a01b03909216916323b872dd916064808201926020929091908290030181600087803b1580156109a957600080fd5b505af11580156109bd573d6000803e3d6000fd5b505050506040513d60208110156109d357600080fd5b5050336000908152600260205260409020546109f5908263ffffffff610d9416565b33600090815260026020526040902055600354610a18908263ffffffff610d9416565b60035550565b60026020526000908152604090205481565b6005546000904290811115610a495760009150506102d5565b600554610a5c908263ffffffff610dee16565b9150506102d5565b610a6c610d2e565b6000546001600160a01b03908116911614610abc576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b604080516370a0823160e01b8152306004820152905184916000916001600160a01b038416916370a08231916024808301926020929190829003018186803b158015610b0757600080fd5b505afa158015610b1b573d6000803e3d6000fd5b505050506040513d6020811015610b3157600080fd5b505111610b7b576040805162461bcd60e51b8152602060048201526013602482015272496e73756666696369656e742062616c616e6560681b604482015290519081900360640190fd5b8180610bf657604080516370a0823160e01b815230600482015290516001600160a01b038416916370a08231916024808301926020929190829003018186803b158015610bc757600080fd5b505afa158015610bdb573d6000803e3d6000fd5b505050506040513d6020811015610bf157600080fd5b505190505b610c106001600160a01b038316858363ffffffff610e3016565b5050505050565b610c1f610d2e565b6000546001600160a01b03908116911614610c6f576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b6001600160a01b038116610cb45760405162461bcd60e51b81526004018080602001828103825260268152602001806112346026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b600154600160a01b900460ff1681565b6001546001600160a01b031681565b3390565b600082610d4157506000610d8e565b82820282848281610d4e57fe5b0414610d8b5760405162461bcd60e51b81526004018080602001828103825260218152602001806112a76021913960400191505060405180910390fd5b90505b92915050565b600082820183811015610d8b576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6000610d8b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610ec9565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610e82908490610f60565b505050565b6000610d8b83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611011565b60008184841115610f585760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1d578181015183820152602001610f05565b50505050905090810190601f168015610f4a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6060610fb5826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166110769092919063ffffffff16565b805190915015610e8257808060200190516020811015610fd457600080fd5b5051610e825760405162461bcd60e51b815260040180806020018281038252602a8152602001806112e8602a913960400191505060405180910390fd5b600081836110605760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f1d578181015183820152602001610f05565b50600083858161106c57fe5b0495945050505050565b6060611085848460008561108d565b949350505050565b6060611098856111fa565b6110e9576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106111285780518252601f199092019160209182019101611109565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461118a576040519150601f19603f3d011682016040523d82523d6000602084013e61118f565b606091505b509150915081156111a35791506110859050565b8051156111b35780518082602001fd5b60405162461bcd60e51b8152602060048201818152865160248401528651879391928392604401919085019080838360008315610f1d578181015183820152602001610f05565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061108557505015159291505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573737468652074696d65206f6620756e7374616b696e6720686173206e6f742066696e6973686564746f74616c20696e766573742063616e6e6f74206265206d6f7265207468616e20356d20505259536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65725361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a26469706673582212203e242ab1214e0ad8d0888edc359f36738d4bbc4528dad1ca89d9c0e16caae06464736f6c634300060a00330000000000000000000000003c81d482172cc273c3b91dd9d8eb212023d00521

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061010b5760003560e01c8063817b1cd2116100a2578063c7e284b811610071578063c7e284b8146101d3578063e63ea408146101db578063f2fde38b14610211578063f9e9235414610237578063fc0c546a146102535761010b565b8063817b1cd2146101645780638da5cb5b1461016c578063a694fc3a14610190578063bf135267146101ad5761010b565b80632def6620116100de5780632def66201461014457806357341cb41461014c578063715018a61461015457806376dee2211461015c5761010b565b806312b583491461011057806320988cef1461012a57806321be0cfc1461013257806322c51eb81461013c575b600080fd5b61011861025b565b60408051918252519081900360200190f35b6101186102d8565b61013a6102df565b005b61013a610399565b61013a610480565b6101186106ed565b61013a6106f3565b610118610795565b61011861079b565b6101746107a1565b604080516001600160a01b039092168252519081900360200190f35b61013a600480360360208110156101a657600080fd5b50356107b0565b610118600480360360208110156101c357600080fd5b50356001600160a01b0316610a1e565b610118610a30565b61013a600480360360608110156101f157600080fd5b506001600160a01b03813581169160208101359091169060400135610a64565b61013a6004803603602081101561022757600080fd5b50356001600160a01b0316610c17565b61023f610d0f565b604080519115158252519081900360200190f35b610174610d1f565b600154604080516370a0823160e01b815230600482015290516000926001600160a01b0316916370a08231916024808301926020929190829003018186803b1580156102a657600080fd5b505afa1580156102ba573d6000803e3d6000fd5b505050506040513d60208110156102d057600080fd5b505190505b90565b62278d0081565b6102e7610d2e565b6000546001600160a01b03908116911614610337576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600554429081116103795760405162461bcd60e51b815260040180806020018281038252602681526020018061125a6026913960400191505060405180910390fd5b506001805460ff60a01b1916600160a01b17905560006005819055600455565b6103a1610d2e565b6000546001600160a01b039081169116146103f1576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600554429081116104335760405162461bcd60e51b815260040180806020018281038252602681526020018061125a6026913960400191505060405180910390fd5b6001805460ff60a01b1916905561046461045762278d00600363ffffffff610d3216565b829063ffffffff610d9416565b60055561047a8162278d0063ffffffff610d9416565b60045550565b336000818152600260205260409020546104d5576040805162461bcd60e51b81526020600482015260116024820152701b9bc81cdd185ada5b99c8185b5bdd5b9d607a1b604482015290519081900360640190fd5b60018054600160a01b900460ff1615151415610550576001600160a01b038116600090815260026020526040902054600354610517908263ffffffff610dee16565b6003556001600160a01b038083166000908152600260205260408120556001546105499116838363ffffffff610e3016565b50506106eb565b6005544290811115610630576001600160a01b0382166000908152600260205260408120546105999060649061058d90600763ffffffff610d3216565b9063ffffffff610e8716565b6001600160a01b038416600090815260026020526040812054919250906105c6908363ffffffff610d9416565b6001600160a01b0385166000908152600260205260409020546003549192506105f5919063ffffffff610dee16565b6003556001600160a01b038085166000908152600260205260408120556001546106279116858363ffffffff610e3016565b505050506106eb565b8060045410801561064357506005548111155b15610679576001600160a01b0382166000908152600260205260408120546105999060c89061058d90600763ffffffff610d3216565b60045481116106e8576001600160a01b0382166000908152600260205260409020546003546106ae908263ffffffff610dee16565b6003556001600160a01b038084166000908152600260205260408120556001546106e09116848363ffffffff610e3016565b5050506106eb565b50505b565b60055481565b6106fb610d2e565b6000546001600160a01b0390811691161461074b576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b60045481565b60035481565b6000546001600160a01b031690565b60018054600160a01b900460ff16151514610812576040805162461bcd60e51b815260206004820152601760248201527f7374616b696e67206973206e6f74206163636570746564000000000000000000604482015290519081900360640190fd5b683635c9adc5dea00000811015610870576040805162461bcd60e51b815260206004820152601e60248201527f63616e6e6f7420696e76657374206c657373207468616e20316b205052590000604482015290519081900360640190fd5b33600090815260026020526040902054692a5a058fc295ed0000009061089d90839063ffffffff610d9416565b11156108f0576040805162461bcd60e51b815260206004820181905260248201527f63616e6e6f7420696e76657374206d6f7265207468616e203230306b20505259604482015290519081900360640190fd5b6b1027e72f1f1281308800000061091260035483610d9490919063ffffffff16565b111561094f5760405162461bcd60e51b81526004018080602001828103825260278152602001806112806027913960400191505060405180910390fd5b600154604080516323b872dd60e01b81523360048201523060248201526044810184905290516001600160a01b03909216916323b872dd916064808201926020929091908290030181600087803b1580156109a957600080fd5b505af11580156109bd573d6000803e3d6000fd5b505050506040513d60208110156109d357600080fd5b5050336000908152600260205260409020546109f5908263ffffffff610d9416565b33600090815260026020526040902055600354610a18908263ffffffff610d9416565b60035550565b60026020526000908152604090205481565b6005546000904290811115610a495760009150506102d5565b600554610a5c908263ffffffff610dee16565b9150506102d5565b610a6c610d2e565b6000546001600160a01b03908116911614610abc576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b604080516370a0823160e01b8152306004820152905184916000916001600160a01b038416916370a08231916024808301926020929190829003018186803b158015610b0757600080fd5b505afa158015610b1b573d6000803e3d6000fd5b505050506040513d6020811015610b3157600080fd5b505111610b7b576040805162461bcd60e51b8152602060048201526013602482015272496e73756666696369656e742062616c616e6560681b604482015290519081900360640190fd5b8180610bf657604080516370a0823160e01b815230600482015290516001600160a01b038416916370a08231916024808301926020929190829003018186803b158015610bc757600080fd5b505afa158015610bdb573d6000803e3d6000fd5b505050506040513d6020811015610bf157600080fd5b505190505b610c106001600160a01b038316858363ffffffff610e3016565b5050505050565b610c1f610d2e565b6000546001600160a01b03908116911614610c6f576040805162461bcd60e51b815260206004820181905260248201526000805160206112c8833981519152604482015290519081900360640190fd5b6001600160a01b038116610cb45760405162461bcd60e51b81526004018080602001828103825260268152602001806112346026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b600154600160a01b900460ff1681565b6001546001600160a01b031681565b3390565b600082610d4157506000610d8e565b82820282848281610d4e57fe5b0414610d8b5760405162461bcd60e51b81526004018080602001828103825260218152602001806112a76021913960400191505060405180910390fd5b90505b92915050565b600082820183811015610d8b576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6000610d8b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250610ec9565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610e82908490610f60565b505050565b6000610d8b83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611011565b60008184841115610f585760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1d578181015183820152602001610f05565b50505050905090810190601f168015610f4a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6060610fb5826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166110769092919063ffffffff16565b805190915015610e8257808060200190516020811015610fd457600080fd5b5051610e825760405162461bcd60e51b815260040180806020018281038252602a8152602001806112e8602a913960400191505060405180910390fd5b600081836110605760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315610f1d578181015183820152602001610f05565b50600083858161106c57fe5b0495945050505050565b6060611085848460008561108d565b949350505050565b6060611098856111fa565b6110e9576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106111285780518252601f199092019160209182019101611109565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461118a576040519150601f19603f3d011682016040523d82523d6000602084013e61118f565b606091505b509150915081156111a35791506110859050565b8051156111b35780518082602001fd5b60405162461bcd60e51b8152602060048201818152865160248401528651879391928392604401919085019080838360008315610f1d578181015183820152602001610f05565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061108557505015159291505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573737468652074696d65206f6620756e7374616b696e6720686173206e6f742066696e6973686564746f74616c20696e766573742063616e6e6f74206265206d6f7265207468616e20356d20505259536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f774f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65725361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a26469706673582212203e242ab1214e0ad8d0888edc359f36738d4bbc4528dad1ca89d9c0e16caae06464736f6c634300060a0033

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

0000000000000000000000003c81d482172cc273c3b91dd9d8eb212023d00521

-----Decoded View---------------
Arg [0] : _token (address): 0x3C81D482172cC273c3b91dD9D8eb212023D00521

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 0000000000000000000000003c81d482172cc273c3b91dd9d8eb212023d00521


Deployed Bytecode Sourcemap

22250:5453:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25719:121;;;:::i;:::-;;;;;;;;;;;;;;;;22405:43;;;:::i;26277:270::-;;;:::i;:::-;;26641:351;;;:::i;23671:1976::-;;;:::i;22699:25::-;;;:::i;21217:148::-;;;:::i;22666:26::-;;;:::i;22633:::-;;;:::i;20575:79::-;;;:::i;:::-;;;;-1:-1:-1;;;;;20575:79:0;;;;;;;;;;;;;;23032:593;;;;;;;;;;;;;;;;-1:-1:-1;23032:593:0;;:::i;22580:46::-;;;;;;;;;;;;;;;;-1:-1:-1;22580:46:0;-1:-1:-1;;;;;22580:46:0;;:::i;25898:251::-;;;:::i;27260:440::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;27260:440:0;;;;;;;;;;;;;;;;;:::i;21520:244::-;;;;;;;;;;;;;;;;-1:-1:-1;21520:244:0;-1:-1:-1;;;;;21520:244:0;;:::i;22539:34::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;22512:20;;;:::i;25719:121::-;25801:5;;25794:38;;;-1:-1:-1;;;25794:38:0;;25826:4;25794:38;;;;;;25767:7;;-1:-1:-1;;;;;25801:5:0;;25794:23;;:38;;;;;;;;;;;;;;25801:5;25794:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;25794:38:0;;-1:-1:-1;25719:121:0;;:::o;22405:43::-;22441:7;22405:43;:::o;26277:270::-;20797:12;:10;:12::i;:::-;20787:6;;-1:-1:-1;;;;;20787:6:0;;;:22;;;20779:67;;;;;-1:-1:-1;;;20779:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20779:67:0;;;;;;;;;;;;;;;26402:10:::1;::::0;26354:15:::1;::::0;26388:24;::::1;26380:75;;;;-1:-1:-1::0;;;26380:75:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1::0;26484:4:0::1;26466:22:::0;;-1:-1:-1;;;;26466:22:0::1;-1:-1:-1::0;;;26466:22:0::1;::::0;;;26499:10:::1;:14:::0;;;26524:11:::1;:15:::0;26277:270::o;26641:351::-;20797:12;:10;:12::i;:::-;20787:6;;-1:-1:-1;;;;;20787:6:0;;;:22;;;20779:67;;;;;-1:-1:-1;;;20779:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20779:67:0;;;;;;;;;;;;;;;26767:10:::1;::::0;26719:15:::1;::::0;26753:24;::::1;26745:75;;;;-1:-1:-1::0;;;26745:75:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26831:15;:23:::0;;-1:-1:-1;;;;26831:23:0::1;::::0;;26878:33:::1;26894:16;22441:7;26908:1;26894:16;:13;:16;:::i;:::-;26878:11:::0;;:33:::1;:15;:33;:::i;:::-;26865:10;:46:::0;26947:26:::1;:11:::0;22441:7:::1;26947:26;:15;:26;:::i;:::-;26933:11;:40:::0;-1:-1:-1;26641:351:0:o;23671:1976::-;23727:10;23708:16;23756:21;;;:11;:21;;;;;;23748:55;;;;;-1:-1:-1;;;23748:55:0;;;;;;;;;;;;-1:-1:-1;;;23748:55:0;;;;;;;;;;;;;;;23898:15;;;-1:-1:-1;;;23898:15:0;;;;:23;;;23894:299;;;-1:-1:-1;;;;;23964:21:0;;23938:23;23964:21;;;:11;:21;;;;;;24014:11;;:38;;23964:21;24014:38;:15;:38;:::i;:::-;24000:11;:52;-1:-1:-1;;;;;24067:21:0;;;24091:1;24067:21;;;:11;:21;;;;;:25;24114:5;;24107:53;;24114:5;24079:8;24144:15;24107:53;:26;:53;:::i;:::-;24175:7;;;;23894:299;24350:10;;24225:15;;24350:24;-1:-1:-1;24346:381:0;;;-1:-1:-1;;;;;24408:21:0;;24391:14;24408:21;;;:11;:21;;;;;;:37;;24441:3;;24408:28;;24434:1;24408:28;:25;:28;:::i;:::-;:32;:37;:32;:37;:::i;:::-;-1:-1:-1;;;;;24486:21:0;;24460:23;24486:21;;;:11;:21;;;;;;24391:54;;-1:-1:-1;24460:23:0;24486:33;;24391:54;24486:33;:25;:33;:::i;:::-;-1:-1:-1;;;;;24564:21:0;;;;;;:11;:21;;;;;;24548:11;;24460:59;;-1:-1:-1;24548:38:0;;:11;:38;:15;:38;:::i;:::-;24534:11;:52;-1:-1:-1;;;;;24601:21:0;;;24625:1;24601:21;;;:11;:21;;;;;:25;24648:5;;24641:53;;24648:5;24613:8;24678:15;24641:53;:26;:53;:::i;:::-;24709:7;;;;;;24346:381;24855:11;24841;;:25;:54;;;;;24885:10;;24870:11;:25;;24841:54;24837:411;;;-1:-1:-1;;;;;24929:21:0;;24912:14;24929:21;;;:11;:21;;;;;;:37;;24962:3;;24929:28;;24955:1;24929:28;:25;:28;:::i;24837:411::-;25357:11;;25342;:26;25338:302;;-1:-1:-1;;;;;25411:21:0;;25385:23;25411:21;;;:11;:21;;;;;;25461:11;;:38;;25411:21;25461:38;:15;:38;:::i;:::-;25447:11;:52;-1:-1:-1;;;;;25514:21:0;;;25538:1;25514:21;;;:11;:21;;;;;:25;25561:5;;25554:53;;25561:5;25526:8;25591:15;25554:53;:26;:53;:::i;:::-;25622:7;;;;;25338:302;23671:1976;;;:::o;22699:25::-;;;;:::o;21217:148::-;20797:12;:10;:12::i;:::-;20787:6;;-1:-1:-1;;;;;20787:6:0;;;:22;;;20779:67;;;;;-1:-1:-1;;;20779:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20779:67:0;;;;;;;;;;;;;;;21324:1:::1;21308:6:::0;;21287:40:::1;::::0;-1:-1:-1;;;;;21308:6:0;;::::1;::::0;21287:40:::1;::::0;21324:1;;21287:40:::1;21355:1;21338:19:::0;;-1:-1:-1;;;;;;21338:19:0::1;::::0;;21217:148::o;22666:26::-;;;;:::o;22633:::-;;;;:::o;20575:79::-;20613:7;20640:6;-1:-1:-1;;;;;20640:6:0;20575:79;:::o;23032:593::-;23090:15;;;-1:-1:-1;;;23090:15:0;;;;:23;;;23082:59;;;;;-1:-1:-1;;;23082:59:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;23171:7;23160;:18;;23152:61;;;;;-1:-1:-1;;;23152:61:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;23256:10;23244:23;;;;:11;:23;;;;;;23272:9;;23232:36;;:7;;:36;:11;:36;:::i;:::-;:49;;23224:94;;;;;-1:-1:-1;;;23224:94:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23365:13;23337:24;23349:11;;23337:7;:11;;:24;;;;:::i;:::-;:41;;23329:93;;;;-1:-1:-1;;;23329:93:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23440:5;;23433:62;;;-1:-1:-1;;;23433:62:0;;23460:10;23433:62;;;;23480:4;23433:62;;;;;;;;;;;;-1:-1:-1;;;;;23440:5:0;;;;23433:26;;:62;;;;;;;;;;;;;;;23440:5;;23433:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;23544:10:0;23532:23;;;;:11;23433:62;23532:23;;;;;:36;;23560:7;23532:36;:27;:36;:::i;:::-;23518:10;23506:23;;;;:11;:23;;;;;:62;23593:11;;:24;;23609:7;23593:24;:15;:24;:::i;:::-;23579:11;:38;-1:-1:-1;23032:593:0:o;22580:46::-;;;;;;;;;;;;;:::o;25898:251::-;26028:10;;25942:7;;25984:15;;26014:24;;26010:132;;;26062:1;26055:8;;;;;26010:132;26103:10;;:27;;26118:11;26103:27;:14;:27;:::i;:::-;26096:34;;;;;27260:440;20797:12;:10;:12::i;:::-;20787:6;;-1:-1:-1;;;;;20787:6:0;;;:22;;;20779:67;;;;;-1:-1:-1;;;20779:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20779:67:0;;;;;;;;;;;;;;;27416:35:::1;::::0;;-1:-1:-1;;;27416:35:0;;27445:4:::1;27416:35;::::0;::::1;::::0;;;27390:6;;27363:17:::1;::::0;-1:-1:-1;;;;;27416:20:0;::::1;::::0;::::1;::::0;:35;;;;;::::1;::::0;;;;;;;;:20;:35;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;27416:35:0;:39:::1;27408:71;;;::::0;;-1:-1:-1;;;27408:71:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;27408:71:0;;;;;;;;;;;;;::::1;;27519:7:::0;27541:12;27537:99:::1;;27589:35;::::0;;-1:-1:-1;;;27589:35:0;;27618:4:::1;27589:35;::::0;::::1;::::0;;;-1:-1:-1;;;;;27589:20:0;::::1;::::0;::::1;::::0;:35;;;;;::::1;::::0;;;;;;;;:20;:35;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;27589:35:0;;-1:-1:-1;27537:99:0::1;27646:46;-1:-1:-1::0;;;;;27646:23:0;::::1;27670:3:::0;27675:16;27646:46:::1;:23;:46;:::i;:::-;20857:1;;27260:440:::0;;;:::o;21520:244::-;20797:12;:10;:12::i;:::-;20787:6;;-1:-1:-1;;;;;20787:6:0;;;:22;;;20779:67;;;;;-1:-1:-1;;;20779:67:0;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20779:67:0;;;;;;;;;;;;;;;-1:-1:-1;;;;;21609:22:0;::::1;21601:73;;;;-1:-1:-1::0;;;21601:73:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21711:6;::::0;;21690:38:::1;::::0;-1:-1:-1;;;;;21690:38:0;;::::1;::::0;21711:6;::::1;::::0;21690:38:::1;::::0;::::1;21739:6;:17:::0;;-1:-1:-1;;;;;;21739:17:0::1;-1:-1:-1::0;;;;;21739:17:0;;;::::1;::::0;;;::::1;::::0;;21520:244::o;22539:34::-;;;-1:-1:-1;;;22539:34:0;;;;;:::o;22512:20::-;;;-1:-1:-1;;;;;22512:20:0;;:::o;19059:106::-;19147:10;19059:106;:::o;5141:471::-;5199:7;5444:6;5440:47;;-1:-1:-1;5474:1:0;5467:8;;5440:47;5511:5;;;5515:1;5511;:5;:1;5535:5;;;;;:10;5527:56;;;;-1:-1:-1;;;5527:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5603:1;-1:-1:-1;5141:471:0;;;;;:::o;3787:181::-;3845:7;3877:5;;;3901:6;;;;3893:46;;;;;-1:-1:-1;;;3893:46:0;;;;;;;;;;;;;;;;;;;;;;;;;;;4251:136;4309:7;4336:43;4340:1;4343;4336:43;;;;;;;;;;;;;;;;;:3;:43::i;15346:177::-;15456:58;;;-1:-1:-1;;;;;15456:58:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;15456:58:0;-1:-1:-1;;;15456:58:0;;;15429:86;;15449:5;;15429:19;:86::i;:::-;15346:177;;;:::o;6088:132::-;6146:7;6173:39;6177:1;6180;6173:39;;;;;;;;;;;;;;;;;:3;:39::i;4690:192::-;4776:7;4812:12;4804:6;;;;4796:29;;;;-1:-1:-1;;;4796:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;4848:5:0;;;4690:192::o;17651:761::-;18075:23;18101:69;18129:4;18101:69;;;;;;;;;;;;;;;;;18109:5;-1:-1:-1;;;;;18101:27:0;;;:69;;;;;:::i;:::-;18185:17;;18075:95;;-1:-1:-1;18185:21:0;18181:224;;18327:10;18316:30;;;;;;;;;;;;;;;-1:-1:-1;18316:30:0;18308:85;;;;-1:-1:-1;;;18308:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6716:278;6802:7;6837:12;6830:5;6822:28;;;;-1:-1:-1;;;6822:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6861:9;6877:1;6873;:5;;;;;;;6716:278;-1:-1:-1;;;;;6716:278:0:o;12142:196::-;12245:12;12277:53;12300:6;12308:4;12314:1;12317:12;12277:22;:53::i;:::-;12270:60;12142:196;-1:-1:-1;;;;12142:196:0:o;13519:979::-;13649:12;13682:18;13693:6;13682:10;:18::i;:::-;13674:60;;;;;-1:-1:-1;;;13674:60:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;13808:12;13822:23;13849:6;-1:-1:-1;;;;;13849:11:0;13869:8;13880:4;13849:36;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;13849:36:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13807:78;;;;13900:7;13896:595;;;13931:10;-1:-1:-1;13924:17:0;;-1:-1:-1;13924:17:0;13896:595;14045:17;;:21;14041:439;;14308:10;14302:17;14369:15;14356:10;14352:2;14348:19;14341:44;14256:148;14444:20;;-1:-1:-1;;;14444:20:0;;;;;;;;;;;;;;;;;14451:12;;14444:20;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9027:619;9087:4;9555:20;;9398:66;9595:23;;;;;;:42;;-1:-1:-1;;9622:15:0;;;9587:51;-1:-1:-1;;9027:619:0:o

Swarm Source

ipfs://3e242ab1214e0ad8d0888edc359f36738d4bbc4528dad1ca89d9c0e16caae064

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.