ETH Price: $3,110.32 (+1.14%)
Gas: 6 Gwei

Token

Staked HEGIC (sHEGIC)
 

Overview

Max Total Supply

1,764,299.364134793486685135 sHEGIC

Holders

212

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 18 Decimals)

Balance
0 sHEGIC

Value
$0.00
0x6859ea44dc8e9a42222ea1bc38ed74e8c8fe6dc7
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
HegicStakingPool

Compiler Version
v0.6.12+commit.27d51765

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion, GNU GPLv3 license
File 1 of 9 : Context.sol
// SPDX-License-Identifier: MIT

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;
    }
}

File 2 of 9 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

import "../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;
    }
}

File 3 of 9 : SafeMath.sol
// SPDX-License-Identifier: MIT

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;
    }
}

File 4 of 9 : ERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.6.0;

import "../../GSN/Context.sol";
import "./IERC20.sol";
import "../../math/SafeMath.sol";
import "../../utils/Address.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 * For a generic mechanism see {ERC20PresetMinterPauser}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * We have followed general OpenZeppelin guidelines: functions revert instead
 * of returning `false` on failure. This behavior is nonetheless conventional
 * and does not conflict with the expectations of ERC20 applications.
 *
 * Additionally, an {Approval} event is emitted on calls to {transferFrom}.
 * This allows applications to reconstruct the allowance for all accounts just
 * by listening to said events. Other implementations of the EIP may not emit
 * these events, as it isn't required by the specification.
 *
 * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}
 * functions have been added to mitigate the well-known issues around setting
 * allowances. See {IERC20-approve}.
 */
contract ERC20 is Context, IERC20 {
    using SafeMath for uint256;
    using Address for address;

    mapping (address => uint256) private _balances;

    mapping (address => mapping (address => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;
    uint8 private _decimals;

    /**
     * @dev Sets the values for {name} and {symbol}, initializes {decimals} with
     * a default value of 18.
     *
     * To select a different value for {decimals}, use {_setupDecimals}.
     *
     * All three of these values are immutable: they can only be set once during
     * construction.
     */
    constructor (string memory name, string memory symbol) public {
        _name = name;
        _symbol = symbol;
        _decimals = 18;
    }

    /**
     * @dev Returns the name of the token.
     */
    function name() public view returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5,05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the value {ERC20} uses, unless {_setupDecimals} is
     * called.
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view returns (uint8) {
        return _decimals;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `recipient` cannot be the zero address.
     * - the caller must have a balance of at least `amount`.
     */
    function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 amount) public virtual override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Emits an {Approval} event indicating the updated allowance. This is not
     * required by the EIP. See the note at the beginning of {ERC20};
     *
     * Requirements:
     * - `sender` and `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     * - the caller must have allowance for ``sender``'s tokens of at least
     * `amount`.
     */
    function transferFrom(address sender, address recipient, uint256 amount) public virtual override returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

    /**
     * @dev Atomically increases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

    /**
     * @dev Atomically decreases the allowance granted to `spender` by the caller.
     *
     * This is an alternative to {approve} that can be used as a mitigation for
     * problems described in {IERC20-approve}.
     *
     * Emits an {Approval} event indicating the updated allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `spender` must have allowance for the caller of at least
     * `subtractedValue`.
     */
    function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
        return true;
    }

    /**
     * @dev Moves tokens `amount` from `sender` to `recipient`.
     *
     * This is internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * Requirements:
     *
     * - `sender` cannot be the zero address.
     * - `recipient` cannot be the zero address.
     * - `sender` must have a balance of at least `amount`.
     */
    function _transfer(address sender, address recipient, uint256 amount) internal virtual {
        require(sender != address(0), "ERC20: transfer from the zero address");
        require(recipient != address(0), "ERC20: transfer to the zero address");

        _beforeTokenTransfer(sender, recipient, amount);

        _balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
        _balances[recipient] = _balances[recipient].add(amount);
        emit Transfer(sender, recipient, amount);
    }

    /** @dev Creates `amount` tokens and assigns them to `account`, increasing
     * the total supply.
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * Requirements
     *
     * - `to` cannot be the zero address.
     */
    function _mint(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: mint to the zero address");

        _beforeTokenTransfer(address(0), account, amount);

        _totalSupply = _totalSupply.add(amount);
        _balances[account] = _balances[account].add(amount);
        emit Transfer(address(0), account, amount);
    }

    /**
     * @dev Destroys `amount` tokens from `account`, reducing the
     * total supply.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * Requirements
     *
     * - `account` cannot be the zero address.
     * - `account` must have at least `amount` tokens.
     */
    function _burn(address account, uint256 amount) internal virtual {
        require(account != address(0), "ERC20: burn from the zero address");

        _beforeTokenTransfer(account, address(0), amount);

        _balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
        _totalSupply = _totalSupply.sub(amount);
        emit Transfer(account, address(0), amount);
    }

    /**
     * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     */
    function _approve(address owner, address spender, uint256 amount) internal virtual {
        require(owner != address(0), "ERC20: approve from the zero address");
        require(spender != address(0), "ERC20: approve to the zero address");

        _allowances[owner][spender] = amount;
        emit Approval(owner, spender, amount);
    }

    /**
     * @dev Sets {decimals} to a value other than the default one of 18.
     *
     * WARNING: This function should only be called from the constructor. Most
     * applications that interact with token contracts will not expect
     * {decimals} to ever change, and may work incorrectly if it does.
     */
    function _setupDecimals(uint8 decimals_) internal {
        _decimals = decimals_;
    }

    /**
     * @dev Hook that is called before any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * will be to transferred to `to`.
     * - when `from` is zero, `amount` tokens will be minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual { }
}

File 5 of 9 : 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);
}

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

pragma solidity ^0.6.0;

import "./IERC20.sol";
import "../../math/SafeMath.sol";
import "../../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");
        }
    }
}

File 7 of 9 : Address.sol
// SPDX-License-Identifier: MIT

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) {
        // This method relies in extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        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");

        // 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);
            }
        }
    }
}

File 8 of 9 : HegicStakingPool.sol
// SPDX-License-Identifier: GPL-3.0
pragma solidity 0.6.12;

import "./Interfaces.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/SafeERC20.sol";

contract HegicStakingPool is Ownable, ERC20{
    using SafeMath for uint;
    using SafeERC20 for IERC20;

    // Tokens
    IERC20 public immutable HEGIC;
    IERC20 public immutable WBTC;

    mapping(Asset => IHegicStaking) public staking; 

    uint public STAKING_LOT_PRICE = 888_000e18;
    uint public ACCURACY = 1e32;

    address payable public FALLBACK_RECIPIENT;
    address payable public FEE_RECIPIENT;
    
    uint public DISCOUNTED_LOTS = 10;
    uint public DISCOUNT_FIRST_LOTS = 20000; // 25%
    uint public DISCOUNT_FIRST_LOT = 50000; // 50%

    uint public performanceFee = 5000;
    bool public depositsAllowed = true;
    uint public lockUpPeriod = 15 minutes;

    uint public totalBalance;
    uint public lockedBalance;
    uint public totalNumberOfStakingLots;
    mapping(Asset => uint) public numberOfStakingLots;
    mapping(Asset => uint) public totalProfitPerToken;

    enum Asset {WBTC, ETH}

    address[] owners;
    mapping(address => uint) public ownerPerformanceFee;
    mapping(address => bool) public isNotFirstTime;
    mapping(address => uint) public lastDepositTime;
    mapping(address => mapping(Asset => uint)) lastProfit;
    mapping(address => mapping(Asset => uint)) savedProfit;

    event Deposit(address account, uint amount);
    event Withdraw(address account, uint amount);
    event BuyLot(uint id, Asset asset, address account);
    event SellLot(uint id, Asset asset, address account);
    event ClaimedProfit(address account, Asset asset, uint netProfit, uint fee);

    constructor(IERC20 _HEGIC, IERC20 _WBTC, IHegicStaking _stakingWBTC, IHegicStaking _stakingETH) public ERC20("Staked HEGIC", "sHEGIC"){
        HEGIC = _HEGIC;
        WBTC = _WBTC;
        staking[Asset.WBTC] = _stakingWBTC;
        staking[Asset.ETH] = _stakingETH;

        FEE_RECIPIENT = msg.sender;
        FALLBACK_RECIPIENT = msg.sender;

        // Approving to Staking Lot Contract
        _HEGIC.approve(address(staking[Asset.WBTC]), 888e30);
        _HEGIC.approve(address(staking[Asset.ETH]), 888e30);
    }

    // Payable 
    receive() external payable {}

    /**
     * @notice Stops the ability to add new deposits
     * @param _allow If set to false, new deposits will be rejected
     */
    function allowDeposits(bool _allow) external onlyOwner {
        depositsAllowed = _allow;
    }

    /**
     * @notice Changes Fee paid to creator (only paid when taking profits)
     * @param _fee New fee
     */
    function changePerformanceFee(uint _fee) external onlyOwner {
        require(_fee >= 0, "Fee too low");
        require(_fee <= 8000, "Fee too high");
        
        performanceFee = _fee;
    }

    /**
     * @notice Changes Fee Recipient address
     * @param _recipient New address
     */
    function changeFeeRecipient(address _recipient) external onlyOwner {
        FEE_RECIPIENT = payable(_recipient);
    }

    /**
     * @notice Changes Fallback Recipient address. This is only used in case of unexpected behavior
     * @param _recipient New address
     */
    function changeFallbackRecipient(address _recipient) external onlyOwner {
        FALLBACK_RECIPIENT = payable(_recipient);
    }

    /**
     * @notice Toggles effect of lockup period by setting lockUpPeriod to 0 (disabled) or to 15 minutes(enabled)
     * @param _unlock Boolean: if true, unlocks funds
     */
    function unlockAllFunds(bool _unlock) external onlyOwner {
        if(_unlock) lockUpPeriod = 0;
        else lockUpPeriod = 15 minutes;
    }

    /**
     * @notice Deposits _amount HEGIC in the contract. 
     * 
     * @param _amount Number of HEGIC to deposit in the contract // number of sHEGIC that will be minted
     */
    function deposit(uint _amount) external {
        require(_amount > 0, "Amount too low");
        require(depositsAllowed, "Deposits are not allowed at the moment");
        // set fee for that staking lot owner - this effectively sets the maximum FEE an owner can have
        // each time user deposits, this checks if current fee is higher or lower than previous fees
        // and updates it if it is lower
        if(ownerPerformanceFee[msg.sender] > performanceFee || !isNotFirstTime[msg.sender]) {
            ownerPerformanceFee[msg.sender] = performanceFee;
            // those that deposit in first DISCOUNTED_LOTS lots get a discount
            if(!isNotFirstTime[msg.sender] && totalNumberOfStakingLots < 1){
                ownerPerformanceFee[msg.sender] = ownerPerformanceFee[msg.sender].mul(uint(100000).sub(DISCOUNT_FIRST_LOT)).div(100000);
            } else if(!isNotFirstTime[msg.sender] && totalNumberOfStakingLots < DISCOUNTED_LOTS){
                ownerPerformanceFee[msg.sender] = ownerPerformanceFee[msg.sender].mul(uint(100000).sub(DISCOUNT_FIRST_LOTS)).div(100000);
            }
            isNotFirstTime[msg.sender] = true;
        }
        lastDepositTime[msg.sender] = block.timestamp;
        // receive deposit
        depositHegic(_amount);

        while(totalBalance.sub(lockedBalance) >= STAKING_LOT_PRICE){
            buyStakingLot();
        }
    }

    /**
     * @notice Withdraws _amount HEGIC from the contract. 
     * 
     * @param _amount Number of HEGIC to withdraw from contract // number of sHEGIC that will be burnt
     */
    function withdraw(uint _amount) public {
        require(_amount <= balanceOf(msg.sender), "Not enough balance");
        require(lastDepositTime[msg.sender].add(lockUpPeriod) <= block.timestamp, "You deposited less than 15 mins ago. Your funds are locked");

        while(totalBalance.sub(lockedBalance) < _amount){
            sellStakingLot();
        }

        withdrawHegic(_amount);
    }

    /**
     * @notice Withdraws _amount HEGIC from the contract and claims all profit pending in contract
     * 
     */
    function claimProfitAndWithdraw() external {
        claimAllProfit();
        withdraw(balanceOf(msg.sender));
    }

    /**
     * @notice Claims profit for both assets. Profit will be paid to msg.sender
     * This is the most gas-efficient way to claim profits (instead of separately)
     * 
     */
    function claimAllProfit() public {
        claimProfit(Asset.WBTC);
        claimProfit(Asset.ETH);
    }

    /**
     * @notice Claims profit for specific _asset. Profit will be paid to msg.sender
     * 
     * @param _asset Asset (ETH or WBTC)
     */
    function claimProfit(Asset _asset) public {
        uint profit = saveProfit(msg.sender, _asset);
        savedProfit[msg.sender][_asset] = 0;
        
        _transferProfit(profit, _asset, msg.sender, ownerPerformanceFee[msg.sender]);
    }

    /**
     * @notice Returns profit to be paid when claimed
     * 
     * @param _account Account to get profit for
     * @param _asset Asset (ETH or WBTC)
     */
    function profitOf(address _account, Asset _asset) public view returns (uint profit) {
        return savedProfit[_account][_asset].add(getUnsaved(_account, _asset));
    }

    /**
     * @notice Returns address of Hegic's ETH Staking Lot contract
     */
    function getHegicStakingETH() public view returns (IHegicStaking HegicStakingETH){
        return staking[Asset.ETH];
    }

    /**
     * @notice Returns address of Hegic's WBTC Staking Lot contract
     */
    function getHegicStakingWBTC() public view returns (IHegicStaking HegicStakingWBTC){
        return staking[Asset.WBTC];
    }

    /**
     * @notice Support function. Gets profit that has not been saved (either in Staking Lot contracts)
     * or in this contract
     * 
     * @param _account Account to get unsaved profit for
     * @param _asset Asset (ETH or WBTC)
     */
    function getUnsaved(address _account, Asset _asset) public view returns (uint profit) {
        profit = totalProfitPerToken[_asset].sub(lastProfit[_account][_asset]).add(getUnreceivedProfitPerToken(_asset)).mul(balanceOf(_account)).div(ACCURACY);
    }

    /**
     * @notice Internal function. Update profit per token for _asset
     * 
     * @param _asset Underlying asset (ETH or WBTC)
     */
    function updateProfit(Asset _asset) internal {
        uint profit;
        profit = staking[_asset].profitOf(address(this));
        if(profit > 0) staking[_asset].claimProfit();
        
        if(totalBalance <= 0) {
            if(_asset == Asset.ETH) FALLBACK_RECIPIENT.transfer(profit);
            else if(_asset == Asset.WBTC) WBTC.safeTransfer(FALLBACK_RECIPIENT, profit);
        } else totalProfitPerToken[_asset] = totalProfitPerToken[_asset].add(profit.mul(ACCURACY).div(totalBalance));
    }

    /**
     * @notice Internal function. Transfers net profit to the owner of the sHEGIC. 
     * 
     * @param _amount Amount of Asset (ETH or WBTC) to be sent
     * @param _asset Asset to be sent (ETH or WBTC)
     * @param _account Receiver of the net profit
     * @param _fee Fee % to be applied to the profit (100% = 100000)
     */
    function _transferProfit(uint _amount, Asset _asset, address _account, uint _fee) internal {
        uint netProfit = _amount.mul(uint(100000).sub(_fee)).div(100000);
        uint fee = _amount.sub(netProfit);

        if(_asset == Asset.ETH){
            payable(_account).transfer(netProfit);
            FEE_RECIPIENT.transfer(fee);
        } else if (_asset == Asset.WBTC) {
            WBTC.safeTransfer(_account, netProfit);
            WBTC.safeTransfer(FEE_RECIPIENT, fee);
        }
        emit ClaimedProfit(_account, _asset, netProfit, fee);
    }

    /**
     * @notice Internal function to transfer deposited HEGIC to the contract and mint sHEGIC (Staked HEGIC)
     * @param _amount Amount of HEGIC to deposit // Amount of sHEGIC that will be minted
     */
    function depositHegic(uint _amount) internal {
        totalBalance = totalBalance.add(_amount); 

        HEGIC.safeTransferFrom(msg.sender, address(this), _amount);

        _mint(msg.sender, _amount);
    }

    /**
     * @notice Internal function. Moves _amount HEGIC from contract to user
     * also burns staked HEGIC (sHEGIC) tokens
     * @param _amount Amount of HEGIC to withdraw // Amount of sHEGIC that will be burned
     */
    function withdrawHegic(uint _amount) internal {

        emit Withdraw(msg.sender, _amount);

        _burn(msg.sender, _amount);
        HEGIC.safeTransfer(msg.sender, _amount);
        totalBalance = totalBalance.sub(_amount);
    }

    /**
     * @notice Internal function. Chooses which lot to buy (ETH or WBTC) and buys it
     *
     */
    function buyStakingLot() internal {
        // we buy 1 ETH staking lot, then 1 WBTC staking lot, then 1 eth, ...
        Asset asset = Asset.ETH;
        if(numberOfStakingLots[Asset.ETH] > numberOfStakingLots[Asset.WBTC]){
            asset = Asset.WBTC;
        }

        if(staking[asset].totalSupply() == staking[asset].MAX_SUPPLY()){
            if(asset == Asset.ETH) asset = Asset.WBTC;
            else asset = Asset.ETH;
        }

        require(staking[asset].totalSupply() < staking[asset].MAX_SUPPLY(), "There are no more available lots for purchase");

        lockedBalance = lockedBalance.add(STAKING_LOT_PRICE);
        staking[asset].buy(1);
        emit BuyLot(block.timestamp, asset, msg.sender);
        totalNumberOfStakingLots++;
        numberOfStakingLots[asset]++;
    }

    /**
     * @notice Internal function. Chooses which lot to sell (ETH or WBTC) and sells it
     *
     */
    function sellStakingLot() internal {
        Asset asset = Asset.ETH;
        if(numberOfStakingLots[Asset.ETH] < numberOfStakingLots[Asset.WBTC]){
            asset = Asset.WBTC;
        }

        // I check if the staking lot to be sold is locked by HEGIC.
        // if it is, I try switching underlying asset (which should be the previously bought lot). 
        if(staking[asset].lastBoughtTimestamp(address(this))
                .add(staking[asset].lockupPeriod()) > block.timestamp){
            if(asset == Asset.ETH) asset = Asset.WBTC;
            else asset = Asset.ETH;
        }
        
        if(staking[asset].balanceOf(address(this)) == 0){
            if(asset == Asset.ETH) asset = Asset.WBTC;
            else asset = Asset.ETH;
        }

        require(
            staking[asset].lastBoughtTimestamp(address(this))
                .add(staking[asset].lockupPeriod()) <= block.timestamp,
             "Lot sale is locked by Hegic. Funds should be available in less than 24h"
        );

        lockedBalance = lockedBalance.sub(STAKING_LOT_PRICE);
        staking[asset].sell(1);
        emit SellLot(block.timestamp, asset, msg.sender);
        totalNumberOfStakingLots--;
        numberOfStakingLots[asset]--;
    }

    /**
     * @notice Support function. Calculates how much profit would receive each token if the contract claimed
     * profit accumulated in Hegic's Staking Lot contracts
     * 
     * @param _asset Asset (WBTC or ETH)
     */
    function getUnreceivedProfitPerToken(Asset _asset) public view returns (uint unreceivedProfitPerToken){
        uint profit = staking[_asset].profitOf(address(this));
        
        unreceivedProfitPerToken = profit.mul(ACCURACY).div(totalBalance);
    }

    /**
     * @notice Saves profit for a certain _account. This profit is absolute in value
     * this function is called before every token transfer to keep the state of profits correctly
     * 
     * @param _account account to save profit to
     */
    function saveProfit(address _account) internal {
        saveProfit(_account, Asset.WBTC);
        saveProfit(_account, Asset.ETH);
    }

    /**
     * @notice Internal function that saves unpaid profit to keep accounting.
     * 
     * @param _account Account to save profit to
     * @param _asset Asset (WBTC or ETH)     
     */
    function saveProfit(address _account, Asset _asset) internal returns (uint profit) {
        updateProfit(_asset);
        uint unsaved = getUnsaved(_account, _asset);
        lastProfit[_account][_asset] = totalProfitPerToken[_asset];
        profit = savedProfit[_account][_asset].add(unsaved);
        savedProfit[_account][_asset] = profit;
    }

    /**
     * @notice Support function. Relevant to the profit system. It will save state of profit before each 
     * token transfer (either deposit or withdrawal)
     * 
     * @param from Account sending tokens 
     * @param to Account receiving tokens
     */
    function _beforeTokenTransfer(address from, address to, uint256) internal override {
        if (from != address(0)) saveProfit(from);
        if (to != address(0)) saveProfit(to);
    }

    /**
     * @notice Returns a boolean indicating if that specific _account can withdraw or not
     * (due to lockupperiod reasons)
     * @param _account Account to check withdrawal status 
     */
    function canWithdraw(address _account) public view returns (bool) {
        return (lastDepositTime[_account].add(lockUpPeriod) <= block.timestamp);
    }
}

File 9 of 9 : Interfaces.sol
/**
 * SPDX-License-Identifier: GPL-3.0-or-later
 * Hegic
 * Copyright (C) 2020 Hegic Protocol
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

pragma solidity 0.6.12;
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

interface IHegicStaking is IERC20 {
    function lockupPeriod() external view returns (uint256);
    function MAX_SUPPLY() external view returns (uint256);
    function lastBoughtTimestamp(address) external view returns (uint256);

    function claimProfit() external returns (uint profit);
    function buy(uint amount) external;
    function sell(uint amount) external;
    function profitOf(address account) external view returns (uint profit);
}

interface IHegicStakingETH is IHegicStaking {
    function sendProfit() external payable;
}

interface IHegicStakingERC20 is IHegicStaking {
    function sendProfit(uint amount) external;
}

Settings
{
  "evmVersion": "istanbul",
  "libraries": {},
  "metadata": {
    "bytecodeHash": "ipfs",
    "useLiteralContent": true
  },
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "remappings": [],
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IERC20","name":"_HEGIC","type":"address"},{"internalType":"contract IERC20","name":"_WBTC","type":"address"},{"internalType":"contract IHegicStaking","name":"_stakingWBTC","type":"address"},{"internalType":"contract IHegicStaking","name":"_stakingETH","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"enum HegicStakingPool.Asset","name":"asset","type":"uint8"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"BuyLot","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"enum HegicStakingPool.Asset","name":"asset","type":"uint8"},{"indexed":false,"internalType":"uint256","name":"netProfit","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"fee","type":"uint256"}],"name":"ClaimedProfit","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"enum HegicStakingPool.Asset","name":"asset","type":"uint8"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"SellLot","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"ACCURACY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DISCOUNTED_LOTS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DISCOUNT_FIRST_LOT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"DISCOUNT_FIRST_LOTS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FALLBACK_RECIPIENT","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"FEE_RECIPIENT","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"HEGIC","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"STAKING_LOT_PRICE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"WBTC","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_allow","type":"bool"}],"name":"allowDeposits","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"canWithdraw","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_recipient","type":"address"}],"name":"changeFallbackRecipient","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_recipient","type":"address"}],"name":"changeFeeRecipient","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fee","type":"uint256"}],"name":"changePerformanceFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimAllProfit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum HegicStakingPool.Asset","name":"_asset","type":"uint8"}],"name":"claimProfit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimProfitAndWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"subtractedValue","type":"uint256"}],"name":"decreaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"depositsAllowed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getHegicStakingETH","outputs":[{"internalType":"contract IHegicStaking","name":"HegicStakingETH","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getHegicStakingWBTC","outputs":[{"internalType":"contract IHegicStaking","name":"HegicStakingWBTC","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"enum HegicStakingPool.Asset","name":"_asset","type":"uint8"}],"name":"getUnreceivedProfitPerToken","outputs":[{"internalType":"uint256","name":"unreceivedProfitPerToken","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"enum HegicStakingPool.Asset","name":"_asset","type":"uint8"}],"name":"getUnsaved","outputs":[{"internalType":"uint256","name":"profit","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"addedValue","type":"uint256"}],"name":"increaseAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isNotFirstTime","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastDepositTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lockUpPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lockedBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"enum HegicStakingPool.Asset","name":"","type":"uint8"}],"name":"numberOfStakingLots","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"ownerPerformanceFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"performanceFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"},{"internalType":"enum HegicStakingPool.Asset","name":"_asset","type":"uint8"}],"name":"profitOf","outputs":[{"internalType":"uint256","name":"profit","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum HegicStakingPool.Asset","name":"","type":"uint8"}],"name":"staking","outputs":[{"internalType":"contract IHegicStaking","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalNumberOfStakingLots","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"enum HegicStakingPool.Asset","name":"","type":"uint8"}],"name":"totalProfitPerToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_unlock","type":"bool"}],"name":"unlockAllFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

60c060405269bc0a9392c65c3b0000006008556d04ee2d6d415b85acef8100000000600955600a600c55614e20600d5561c350600e55611388600f556010805460ff191660011790556103846011553480156200005b57600080fd5b506040516200383838038062003838833981810160405260808110156200008157600080fd5b50805160208083015160408085015160609095015181518083018352600c81526b5374616b656420484547494360a01b818601528251808401909352600683526573484547494360d01b94830194909452939491939192906000620000e5620003a3565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350815162000144906004906020850190620003a7565b5080516200015a906005906020840190620003a7565b50506006805460ff19166012179055506001600160601b0319606085811b821660805284901b1660a05281600760008060018111156200019657fe5b815260200190815260200160002060006101000a8154816001600160a01b0302191690836001600160a01b031602179055508060076000600180811115620001da57fe5b6001811115620001e657fe5b81526020808201929092526040908101600090812080546001600160a01b039586166001600160a01b031991821617909155600b8054821633908117909155600a8054909216179055808052600783527f6d5257204ebe7d88fd91ae87941cb2dd9d8062b64ae5a2bd2d28ec40b9fbf6df54825163095ea7b360e01b815290851660048201526d2bc822bff2746599448e00000000602482015291519388169363095ea7b3936044808501949193918390030190829087803b158015620002ac57600080fd5b505af1158015620002c1573d6000803e3d6000fd5b505050506040513d6020811015620002d857600080fd5b505060016000908152600760209081527fb39221ace053465ec3453ce2b36430bd138b997ecea25c1043da0c366812b828546040805163095ea7b360e01b81526001600160a01b0392831660048201526d2bc822bff2746599448e00000000602482015290519188169363095ea7b39360448084019491939192918390030190829087803b1580156200036a57600080fd5b505af11580156200037f573d6000803e3d6000fd5b505050506040513d60208110156200039657600080fd5b5062000443945050505050565b3390565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620003ea57805160ff19168380011785556200041a565b828001600101855582156200041a579182015b828111156200041a578251825591602001919060010190620003fd565b50620004289291506200042c565b5090565b5b808211156200042857600081556001016200042d565b60805160601c60a05160601c6133b26200048660003980610f145280612822528061285a5280612df552508061103c5280612091528061218352506133b26000f3fe6080604052600436106102e85760003560e01c806385335da811610190578063bc41ab72116100dc578063ebd0905411610095578063f6156d5a1161006f578063f6156d5a14610a69578063fbcd9b0514610a93578063fbf683c114610aa8578063ff4dfa9614610abd576102ef565b8063ebd09054146109ee578063f02a7d1914610a03578063f2fde38b14610a36576102ef565b8063bc41ab72146108f3578063bdd79f0714610920578063cf7a77ce1461095c578063dd62ed3e14610971578063de886eab146109ac578063e32d03bf146109c1576102ef565b8063940b265511610149578063a457c2d711610123578063a457c2d714610842578063a9059cbb1461087b578063ad7a672f146108b4578063b6b55f25146108c9576102ef565b8063940b2655146107ec57806395d89b41146108015780639a21376314610816576102ef565b806385335da81461073857806387788782146107655780638ad8a5391461077a5780638da5cb5b146107ad5780638eaa9597146107c25780638f76137f146107d7576102ef565b80632d3008dd1161024f5780636132ac361161020857806370a08231116101e257806370a08231146106c6578063715018a6146106f957806371e395a81461070e5780637b80889b14610723576102ef565b80636132ac36146106515780636c6925f9146106845780636cc94a6914610699576102ef565b80632d3008dd146105845780632e1a7d4d14610599578063313ce567146105c357806339509351146105ee5780634dede3de146106275780635c029ac81461063c576102ef565b80631b016373116102a15780631b016373146104865780631cc23341146104b75780631e8bc190146104cc57806323604071146104e157806323b872dd146105145780632c2e33c314610557576102ef565b80630100670b146102f4578063025277531461032257806306fdde0314610367578063095ea7b3146103f157806318160ddd1461043e57806319262d3014610453576102ef565b366102ef57005b600080fd5b34801561030057600080fd5b506103206004803603602081101561031757600080fd5b50351515610af9565b005b34801561032e57600080fd5b506103556004803603602081101561034557600080fd5b50356001600160a01b0316610b64565b60408051918252519081900360200190f35b34801561037357600080fd5b5061037c610b76565b6040805160208082528351818301528351919283929083019185019080838360005b838110156103b657818101518382015260200161039e565b50505050905090810190601f1680156103e35780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103fd57600080fd5b5061042a6004803603604081101561041457600080fd5b506001600160a01b038135169060200135610c0c565b604080519115158252519081900360200190f35b34801561044a57600080fd5b50610355610c2a565b34801561045f57600080fd5b5061042a6004803603602081101561047657600080fd5b50356001600160a01b0316610c30565b34801561049257600080fd5b5061049b610c61565b604080516001600160a01b039092168252519081900360200190f35b3480156104c357600080fd5b50610320610c70565b3480156104d857600080fd5b5061049b610c8b565b3480156104ed57600080fd5b506103206004803603602081101561050457600080fd5b50356001600160a01b0316610cbd565b34801561052057600080fd5b5061042a6004803603606081101561053757600080fd5b506001600160a01b03813581169160208101359091169060400135610d37565b34801561056357600080fd5b506103556004803603602081101561057a57600080fd5b503560ff16610dbe565b34801561059057600080fd5b50610355610dd0565b3480156105a557600080fd5b50610320600480360360208110156105bc57600080fd5b5035610dd6565b3480156105cf57600080fd5b506105d8610ebb565b6040805160ff9092168252519081900360200190f35b3480156105fa57600080fd5b5061042a6004803603604081101561061157600080fd5b506001600160a01b038135169060200135610ec4565b34801561063357600080fd5b5061049b610f12565b34801561064857600080fd5b50610320610f36565b34801561065d57600080fd5b506103556004803603602081101561067457600080fd5b50356001600160a01b0316610f4a565b34801561069057600080fd5b50610355610f5c565b3480156106a557600080fd5b5061049b600480360360208110156106bc57600080fd5b503560ff16610f62565b3480156106d257600080fd5b50610355600480360360208110156106e957600080fd5b50356001600160a01b0316610f7d565b34801561070557600080fd5b50610320610f98565b34801561071a57600080fd5b5061049b61103a565b34801561072f57600080fd5b5061035561105e565b34801561074457600080fd5b506103556004803603602081101561075b57600080fd5b503560ff16611064565b34801561077157600080fd5b50610355611128565b34801561078657600080fd5b5061042a6004803603602081101561079d57600080fd5b50356001600160a01b031661112e565b3480156107b957600080fd5b5061049b611143565b3480156107ce57600080fd5b5061049b611152565b3480156107e357600080fd5b5061042a61115d565b3480156107f857600080fd5b50610355611166565b34801561080d57600080fd5b5061037c61116c565b34801561082257600080fd5b506103206004803603602081101561083957600080fd5b503515156111cd565b34801561084e57600080fd5b5061042a6004803603604081101561086557600080fd5b506001600160a01b03813516906020013561123e565b34801561088757600080fd5b5061042a6004803603604081101561089e57600080fd5b506001600160a01b0381351690602001356112a6565b3480156108c057600080fd5b506103556112ba565b3480156108d557600080fd5b50610320600480360360208110156108ec57600080fd5b50356112c0565b3480156108ff57600080fd5b506103556004803603602081101561091657600080fd5b503560ff166114b3565b34801561092c57600080fd5b506103556004803603604081101561094357600080fd5b5080356001600160a01b0316906020013560ff166114c5565b34801561096857600080fd5b50610355611521565b34801561097d57600080fd5b506103556004803603604081101561099457600080fd5b506001600160a01b0381358116916020013516611527565b3480156109b857600080fd5b50610355611552565b3480156109cd57600080fd5b50610320600480360360208110156109e457600080fd5b503560ff16611558565b3480156109fa57600080fd5b5061049b6115d6565b348015610a0f57600080fd5b5061032060048036036020811015610a2657600080fd5b50356001600160a01b03166115e5565b348015610a4257600080fd5b5061032060048036036020811015610a5957600080fd5b50356001600160a01b031661165f565b348015610a7557600080fd5b5061032060048036036020811015610a8c57600080fd5b5035611757565b348015610a9f57600080fd5b506103556117fa565b348015610ab457600080fd5b50610355611800565b348015610ac957600080fd5b5061035560048036036040811015610ae057600080fd5b5080356001600160a01b0316906020013560ff16611806565b610b016118ac565b6000546001600160a01b03908116911614610b51576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b6010805460ff1916911515919091179055565b601a6020526000908152604090205481565b60048054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c025780601f10610bd757610100808354040283529160200191610c02565b820191906000526020600020905b815481529060010190602001808311610be557829003601f168201915b5050505050905090565b6000610c20610c196118ac565b84846118b0565b5060015b92915050565b60035490565b6011546001600160a01b0382166000908152601a602052604081205490914291610c599161199c565b111592915050565b600a546001600160a01b031681565b610c78610f36565b610c89610c8433610f7d565b610dd6565b565b600060078160015b6001811115610c9e57fe5b81526020810191909152604001600020546001600160a01b0316905090565b610cc56118ac565b6000546001600160a01b03908116911614610d15576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600b80546001600160a01b0319166001600160a01b0392909216919091179055565b6000610d448484846119f6565b610db484610d506118ac565b610daf85604051806060016040528060288152602001613229602891396001600160a01b038a16600090815260026020526040812090610d8e6118ac565b6001600160a01b031681526020810191909152604001600020549190611b53565b6118b0565b5060019392505050565b60156020526000908152604090205481565b60085481565b610ddf33610f7d565b811115610e28576040805162461bcd60e51b81526020600482015260126024820152714e6f7420656e6f7567682062616c616e636560701b604482015290519081900360640190fd5b601154336000908152601a60205260409020544291610e47919061199c565b1115610e845760405162461bcd60e51b815260040180806020018281038252603a8152602001806130f7603a913960400191505060405180910390fd5b80610e9c601354601254611bea90919063ffffffff16565b1015610eaf57610eaa611c2c565b610e84565b610eb88161203f565b50565b60065460ff1690565b6000610c20610ed16118ac565b84610daf8560026000610ee26118ac565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549061199c565b7f000000000000000000000000000000000000000000000000000000000000000081565b610f406000611558565b610c896001611558565b60186020526000908152604090205481565b60115481565b6007602052600090815260409020546001600160a01b031681565b6001600160a01b031660009081526001602052604090205490565b610fa06118ac565b6000546001600160a01b03908116911614610ff0576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b7f000000000000000000000000000000000000000000000000000000000000000081565b60135481565b6000806007600084600181111561107757fe5b600181111561108257fe5b815260208082019290925260409081016000205481516354198ce960e01b815230600482015291516001600160a01b03909116926354198ce99260248082019391829003018186803b1580156110d757600080fd5b505afa1580156110eb573d6000803e3d6000fd5b505050506040513d602081101561110157600080fd5b50516012546009549192506111219161111b9084906120cb565b90612124565b9392505050565b600f5481565b60196020526000908152604090205460ff1681565b6000546001600160a01b031690565b600060078180610c93565b60105460ff1681565b600c5481565b60058054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c025780601f10610bd757610100808354040283529160200191610c02565b6111d56118ac565b6000546001600160a01b03908116911614611225576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b8015611235576000601155610eb8565b61038460115550565b6000610c2061124b6118ac565b84610daf8560405180606001604052806025815260200161333260259139600260006112756118ac565b6001600160a01b03908116825260208083019390935260409182016000908120918d16815292529020549190611b53565b6000610c206112b36118ac565b84846119f6565b60125481565b60008111611306576040805162461bcd60e51b815260206004820152600e60248201526d416d6f756e7420746f6f206c6f7760901b604482015290519081900360640190fd5b60105460ff166113475760405162461bcd60e51b81526004018080602001828103825260268152602001806133576026913960400191505060405180910390fd5b600f5433600090815260186020526040902054118061137657503360009081526019602052604090205460ff16155b1561147457600f543360009081526018602090815260408083209390935560199052205460ff161580156113ac57506001601454105b156113fe576113e9620186a061111b6113d3600e54620186a0611bea90919063ffffffff16565b33600090815260186020526040902054906120cb565b33600090815260186020526040902055611459565b3360009081526019602052604090205460ff161580156114215750600c54601454105b1561145957611448620186a061111b6113d3600d54620186a0611bea90919063ffffffff16565b336000908152601860205260409020555b336000908152601960205260409020805460ff191660011790555b336000908152601a6020526040902042905561148f81612166565b6008546013546012546114a191611bea565b10610eb8576114ae6121b5565b61148f565b60166020526000908152604090205481565b60006111216114d48484611806565b6001600160a01b0385166000908152601c60205260408120908560018111156114f957fe5b600181111561150457fe5b81526020019081526020016000205461199c90919063ffffffff16565b600e5481565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b600d5481565b60006115643383612632565b336000908152601c60205260408120919250908184600181111561158457fe5b600181111561158f57fe5b8152602001908152602001600020819055506115d281833360186000336001600160a01b03166001600160a01b0316815260200190815260200160002054612749565b5050565b600b546001600160a01b031681565b6115ed6118ac565b6000546001600160a01b0390811691161461163d576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600a80546001600160a01b0319166001600160a01b0392909216919091179055565b6116676118ac565b6000546001600160a01b039081169116146116b7576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b6001600160a01b0381166116fc5760405162461bcd60e51b81526004018080602001828103825260268152602001806131536026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b61175f6118ac565b6000546001600160a01b039081169116146117af576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b611f408111156117f5576040805162461bcd60e51b815260206004820152600c60248201526b08ccaca40e8dede40d0d2ced60a31b604482015290519081900360640190fd5b600f55565b60095481565b60145481565b600061112160095461111b61181a86610f7d565b6118a661182687611064565b6001600160a01b0389166000908152601b602052604081206118a0918a600181111561184e57fe5b600181111561185957fe5b815260200190815260200160002054601660008b600181111561187857fe5b600181111561188357fe5b815260200190815260200160002054611bea90919063ffffffff16565b9061199c565b906120cb565b3390565b6001600160a01b0383166118f55760405162461bcd60e51b81526004018080602001828103825260248152602001806132b76024913960400191505060405180910390fd5b6001600160a01b03821661193a5760405162461bcd60e51b81526004018080602001828103825260228152602001806131796022913960400191505060405180910390fd5b6001600160a01b03808416600081815260026020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b600082820183811015611121576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6001600160a01b038316611a3b5760405162461bcd60e51b81526004018080602001828103825260258152602001806132926025913960400191505060405180910390fd5b6001600160a01b038216611a805760405162461bcd60e51b81526004018080602001828103825260238152602001806130d46023913960400191505060405180910390fd5b611a8b8383836128ee565b611ac88160405180606001604052806026815260200161319b602691396001600160a01b0386166000908152600160205260409020549190611b53565b6001600160a01b038085166000908152600160205260408082209390935590841681522054611af7908261199c565b6001600160a01b0380841660008181526001602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b60008184841115611be25760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611ba7578181015183820152602001611b8f565b50505050905090810190601f168015611bd45780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600061112183836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611b53565b60156020527fa31547ce6245cdb9ecea19cf8c7eb9f5974025bb4075011409251ae855b30aed54600160008190527f27739e4bb5e6f8b5e4b57a047dca8767cc9b982a011081e086cbb0dfa9de818d5490911115611c88575060005b42611dcf60076000846001811115611c9c57fe5b6001811115611ca757fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b031663ee947a7c6040518163ffffffff1660e01b815260040160206040518083038186803b158015611d0157600080fd5b505afa158015611d15573d6000803e3d6000fd5b505050506040513d6020811015611d2b57600080fd5b505160076000856001811115611d3d57fe5b6001811115611d4857fe5b8152602080820192909252604090810160002054815163a673729160e01b815230600482015291516001600160a01b039091169263a67372919260248082019391829003018186803b158015611d9d57600080fd5b505afa158015611db1573d6000803e3d6000fd5b505050506040513d6020811015611dc757600080fd5b50519061199c565b1115611df5576001816001811115611de357fe5b1415611df157506000611df5565b5060015b60076000826001811115611e0557fe5b6001811115611e1057fe5b815260208082019290925260409081016000205481516370a0823160e01b815230600482015291516001600160a01b03909116926370a082319260248082019391829003018186803b158015611e6557600080fd5b505afa158015611e79573d6000803e3d6000fd5b505050506040513d6020811015611e8f57600080fd5b5051611eb5576001816001811115611ea357fe5b1415611eb157506000611eb5565b5060015b42611ec960076000846001811115611c9c57fe5b1115611f065760405162461bcd60e51b81526004018080602001828103825260478152602001806131c16047913960600191505060405180910390fd5b600854601354611f1591611bea565b60135560076000826001811115611f2857fe5b6001811115611f3357fe5b81526020810191909152604090810160009081205482516372424d9960e11b81526001600482015292516001600160a01b039091169263e4849b3292602480830193919282900301818387803b158015611f8c57600080fd5b505af1158015611fa0573d6000803e3d6000fd5b505050507f24cd5f994ad649e7a524dd5aced6dd8e80ca7541246c3cf335422bd80c565caa42823360405180848152602001836001811115611fde57fe5b8152602001826001600160a01b03168152602001935050505060405180910390a1601480546000190190556015600082600181111561201957fe5b600181111561202457fe5b81526020810191909152604001600020805460001901905550565b604080513381526020810183905281517f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364929181900390910190a16120843382612923565b6120b86001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163383612a1f565b6012546120c59082611bea565b60125550565b6000826120da57506000610c24565b828202828482816120e757fe5b04146111215760405162461bcd60e51b81526004018080602001828103825260218152602001806132086021913960400191505060405180910390fd5b600061112183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612a71565b601254612173908261199c565b6012556121ab6001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016333084612ad6565b610eb83382612b36565b60156020527fa31547ce6245cdb9ecea19cf8c7eb9f5974025bb4075011409251ae855b30aed54600160008190527f27739e4bb5e6f8b5e4b57a047dca8767cc9b982a011081e086cbb0dfa9de818d5490911015612211575060005b6007600082600181111561222157fe5b600181111561222c57fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166332cb6b0c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561228657600080fd5b505afa15801561229a573d6000803e3d6000fd5b505050506040513d60208110156122b057600080fd5b5051600760008360018111156122c257fe5b60018111156122cd57fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561232757600080fd5b505afa15801561233b573d6000803e3d6000fd5b505050506040513d602081101561235157600080fd5b5051141561237957600181600181111561236757fe5b141561237557506000612379565b5060015b6007600082600181111561238957fe5b600181111561239457fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166332cb6b0c6040518163ffffffff1660e01b815260040160206040518083038186803b1580156123ee57600080fd5b505afa158015612402573d6000803e3d6000fd5b505050506040513d602081101561241857600080fd5b50516007600083600181111561242a57fe5b600181111561243557fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561248f57600080fd5b505afa1580156124a3573d6000803e3d6000fd5b505050506040513d60208110156124b957600080fd5b5051106124f75760405162461bcd60e51b815260040180806020018281038252602d8152602001806132db602d913960400191505060405180910390fd5b6008546013546125069161199c565b6013556007600082600181111561251957fe5b600181111561252457fe5b8152602081019190915260409081016000908120548251636cb504a560e11b81526001600482015292516001600160a01b039091169263d96a094a92602480830193919282900301818387803b15801561257d57600080fd5b505af1158015612591573d6000803e3d6000fd5b505050507fd1b43b4b3653b24940204c31867a89713bb84aabe4ee82be10570f0dd791ccb0428233604051808481526020018360018111156125cf57fe5b8152602001826001600160a01b03168152602001935050505060405180910390a1601480546001908101909155601590600090839081111561260d57fe5b600181111561261857fe5b815260208101919091526040016000208054600101905550565b600061263d82612c28565b60006126498484611806565b90506016600084600181111561265b57fe5b600181111561266657fe5b815260200190815260200160002054601b6000866001600160a01b03166001600160a01b0316815260200190815260200160002060008560018111156126a857fe5b60018111156126b357fe5b8152602001908152602001600020819055506126fc81601c6000876001600160a01b03166001600160a01b0316815260200190815260200160002060008660018111156114f957fe5b6001600160a01b0385166000908152601c6020526040812091935083919085600181111561272657fe5b600181111561273157fe5b81526020810191909152604001600020555092915050565b6000612766620186a061111b61275f8286611bea565b88906120cb565b905060006127748683611bea565b9050600185600181111561278457fe5b1415612801576040516001600160a01b0385169083156108fc029084906000818181858888f193505050501580156127c0573d6000803e3d6000fd5b50600b546040516001600160a01b039091169082156108fc029083906000818181858888f193505050501580156127fb573d6000803e3d6000fd5b50612883565b600085600181111561280f57fe5b1415612883576128496001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000168584612a1f565b600b54612883906001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116911683612a1f565b7f42bf830ec222b3077f036a1be5d7d50fd1fc16cfcb9c67a8547cf0241679eae08486848460405180856001600160a01b031681526020018460018111156128c757fe5b815260200183815260200182815260200194505050505060405180910390a1505050505050565b6001600160a01b038316156129065761290683612e81565b6001600160a01b0382161561291e5761291e82612e81565b505050565b6001600160a01b0382166129685760405162461bcd60e51b81526004018080602001828103825260218152602001806132716021913960400191505060405180910390fd5b612974826000836128ee565b6129b181604051806060016040528060228152602001613131602291396001600160a01b0385166000908152600160205260409020549190611b53565b6001600160a01b0383166000908152600160205260409020556003546129d79082611bea565b6003556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261291e908490612e98565b60008183612ac05760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611ba7578181015183820152602001611b8f565b506000838581612acc57fe5b0495945050505050565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052612b30908590612e98565b50505050565b6001600160a01b038216612b91576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b612b9d600083836128ee565b600354612baa908261199c565b6003556001600160a01b038216600090815260016020526040902054612bd0908261199c565b6001600160a01b03831660008181526001602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b600060076000836001811115612c3a57fe5b6001811115612c4557fe5b815260208082019290925260409081016000205481516354198ce960e01b815230600482015291516001600160a01b03909116926354198ce99260248082019391829003018186803b158015612c9a57600080fd5b505afa158015612cae573d6000803e3d6000fd5b505050506040513d6020811015612cc457600080fd5b505190508015612d725760076000836001811115612cde57fe5b6001811115612ce957fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b031663f011a7af6040518163ffffffff1660e01b8152600401602060405180830381600087803b158015612d4557600080fd5b505af1158015612d59573d6000803e3d6000fd5b505050506040513d6020811015612d6f57600080fd5b50505b600060125411612e23576001826001811115612d8a57fe5b1415612dd057600a546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015612dca573d6000803e3d6000fd5b50612e1e565b6000826001811115612dde57fe5b1415612e1e57600a54612e1e906001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116911683612a1f565b6115d2565b612e51612e4160125461111b600954856120cb90919063ffffffff16565b601660008560018111156114f957fe5b60166000846001811115612e6157fe5b6001811115612e6c57fe5b81526020810191909152604001600020555050565b612e8c816000612632565b506115d2816001612632565b6060612eed826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316612f499092919063ffffffff16565b80519091501561291e57808060200190516020811015612f0c57600080fd5b505161291e5760405162461bcd60e51b815260040180806020018281038252602a815260200180613308602a913960400191505060405180910390fd5b6060612f588484600085612f60565b949350505050565b6060612f6b856130cd565b612fbc576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b60208310612ffb5780518252601f199092019160209182019101612fdc565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461305d576040519150601f19603f3d011682016040523d82523d6000602084013e613062565b606091505b50915091508115613076579150612f589050565b8051156130865780518082602001fd5b60405162461bcd60e51b8152602060048201818152865160248401528651879391928392604401919085019080838360008315611ba7578181015183820152602001611b8f565b3b15159056fe45524332303a207472616e7366657220746f20746865207a65726f2061646472657373596f75206465706f7369746564206c657373207468616e203135206d696e732061676f2e20596f75722066756e647320617265206c6f636b656445524332303a206275726e20616d6f756e7420657863656564732062616c616e63654f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e63654c6f742073616c65206973206c6f636b65642062792048656769632e2046756e64732073686f756c6420626520617661696c61626c6520696e206c657373207468616e20323468536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e63654f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657245524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373546865726520617265206e6f206d6f726520617661696c61626c65206c6f747320666f722070757263686173655361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656445524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f4465706f7369747320617265206e6f7420616c6c6f77656420617420746865206d6f6d656e74a26469706673582212206f3f52c5d0a1378ddc30763d84d626a114e49d7e87c39aa0184ce79b18b7a4a864736f6c634300060c0033000000000000000000000000584bc13c7d411c00c01a62e8019472de687684300000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c599000000000000000000000000840a1ae46b7364855206eb5b7286ab7e207e515b0000000000000000000000001ef61e3e5676ec182eed6f052f8920fd49c7f69a

Deployed Bytecode

0x6080604052600436106102e85760003560e01c806385335da811610190578063bc41ab72116100dc578063ebd0905411610095578063f6156d5a1161006f578063f6156d5a14610a69578063fbcd9b0514610a93578063fbf683c114610aa8578063ff4dfa9614610abd576102ef565b8063ebd09054146109ee578063f02a7d1914610a03578063f2fde38b14610a36576102ef565b8063bc41ab72146108f3578063bdd79f0714610920578063cf7a77ce1461095c578063dd62ed3e14610971578063de886eab146109ac578063e32d03bf146109c1576102ef565b8063940b265511610149578063a457c2d711610123578063a457c2d714610842578063a9059cbb1461087b578063ad7a672f146108b4578063b6b55f25146108c9576102ef565b8063940b2655146107ec57806395d89b41146108015780639a21376314610816576102ef565b806385335da81461073857806387788782146107655780638ad8a5391461077a5780638da5cb5b146107ad5780638eaa9597146107c25780638f76137f146107d7576102ef565b80632d3008dd1161024f5780636132ac361161020857806370a08231116101e257806370a08231146106c6578063715018a6146106f957806371e395a81461070e5780637b80889b14610723576102ef565b80636132ac36146106515780636c6925f9146106845780636cc94a6914610699576102ef565b80632d3008dd146105845780632e1a7d4d14610599578063313ce567146105c357806339509351146105ee5780634dede3de146106275780635c029ac81461063c576102ef565b80631b016373116102a15780631b016373146104865780631cc23341146104b75780631e8bc190146104cc57806323604071146104e157806323b872dd146105145780632c2e33c314610557576102ef565b80630100670b146102f4578063025277531461032257806306fdde0314610367578063095ea7b3146103f157806318160ddd1461043e57806319262d3014610453576102ef565b366102ef57005b600080fd5b34801561030057600080fd5b506103206004803603602081101561031757600080fd5b50351515610af9565b005b34801561032e57600080fd5b506103556004803603602081101561034557600080fd5b50356001600160a01b0316610b64565b60408051918252519081900360200190f35b34801561037357600080fd5b5061037c610b76565b6040805160208082528351818301528351919283929083019185019080838360005b838110156103b657818101518382015260200161039e565b50505050905090810190601f1680156103e35780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103fd57600080fd5b5061042a6004803603604081101561041457600080fd5b506001600160a01b038135169060200135610c0c565b604080519115158252519081900360200190f35b34801561044a57600080fd5b50610355610c2a565b34801561045f57600080fd5b5061042a6004803603602081101561047657600080fd5b50356001600160a01b0316610c30565b34801561049257600080fd5b5061049b610c61565b604080516001600160a01b039092168252519081900360200190f35b3480156104c357600080fd5b50610320610c70565b3480156104d857600080fd5b5061049b610c8b565b3480156104ed57600080fd5b506103206004803603602081101561050457600080fd5b50356001600160a01b0316610cbd565b34801561052057600080fd5b5061042a6004803603606081101561053757600080fd5b506001600160a01b03813581169160208101359091169060400135610d37565b34801561056357600080fd5b506103556004803603602081101561057a57600080fd5b503560ff16610dbe565b34801561059057600080fd5b50610355610dd0565b3480156105a557600080fd5b50610320600480360360208110156105bc57600080fd5b5035610dd6565b3480156105cf57600080fd5b506105d8610ebb565b6040805160ff9092168252519081900360200190f35b3480156105fa57600080fd5b5061042a6004803603604081101561061157600080fd5b506001600160a01b038135169060200135610ec4565b34801561063357600080fd5b5061049b610f12565b34801561064857600080fd5b50610320610f36565b34801561065d57600080fd5b506103556004803603602081101561067457600080fd5b50356001600160a01b0316610f4a565b34801561069057600080fd5b50610355610f5c565b3480156106a557600080fd5b5061049b600480360360208110156106bc57600080fd5b503560ff16610f62565b3480156106d257600080fd5b50610355600480360360208110156106e957600080fd5b50356001600160a01b0316610f7d565b34801561070557600080fd5b50610320610f98565b34801561071a57600080fd5b5061049b61103a565b34801561072f57600080fd5b5061035561105e565b34801561074457600080fd5b506103556004803603602081101561075b57600080fd5b503560ff16611064565b34801561077157600080fd5b50610355611128565b34801561078657600080fd5b5061042a6004803603602081101561079d57600080fd5b50356001600160a01b031661112e565b3480156107b957600080fd5b5061049b611143565b3480156107ce57600080fd5b5061049b611152565b3480156107e357600080fd5b5061042a61115d565b3480156107f857600080fd5b50610355611166565b34801561080d57600080fd5b5061037c61116c565b34801561082257600080fd5b506103206004803603602081101561083957600080fd5b503515156111cd565b34801561084e57600080fd5b5061042a6004803603604081101561086557600080fd5b506001600160a01b03813516906020013561123e565b34801561088757600080fd5b5061042a6004803603604081101561089e57600080fd5b506001600160a01b0381351690602001356112a6565b3480156108c057600080fd5b506103556112ba565b3480156108d557600080fd5b50610320600480360360208110156108ec57600080fd5b50356112c0565b3480156108ff57600080fd5b506103556004803603602081101561091657600080fd5b503560ff166114b3565b34801561092c57600080fd5b506103556004803603604081101561094357600080fd5b5080356001600160a01b0316906020013560ff166114c5565b34801561096857600080fd5b50610355611521565b34801561097d57600080fd5b506103556004803603604081101561099457600080fd5b506001600160a01b0381358116916020013516611527565b3480156109b857600080fd5b50610355611552565b3480156109cd57600080fd5b50610320600480360360208110156109e457600080fd5b503560ff16611558565b3480156109fa57600080fd5b5061049b6115d6565b348015610a0f57600080fd5b5061032060048036036020811015610a2657600080fd5b50356001600160a01b03166115e5565b348015610a4257600080fd5b5061032060048036036020811015610a5957600080fd5b50356001600160a01b031661165f565b348015610a7557600080fd5b5061032060048036036020811015610a8c57600080fd5b5035611757565b348015610a9f57600080fd5b506103556117fa565b348015610ab457600080fd5b50610355611800565b348015610ac957600080fd5b5061035560048036036040811015610ae057600080fd5b5080356001600160a01b0316906020013560ff16611806565b610b016118ac565b6000546001600160a01b03908116911614610b51576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b6010805460ff1916911515919091179055565b601a6020526000908152604090205481565b60048054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c025780601f10610bd757610100808354040283529160200191610c02565b820191906000526020600020905b815481529060010190602001808311610be557829003601f168201915b5050505050905090565b6000610c20610c196118ac565b84846118b0565b5060015b92915050565b60035490565b6011546001600160a01b0382166000908152601a602052604081205490914291610c599161199c565b111592915050565b600a546001600160a01b031681565b610c78610f36565b610c89610c8433610f7d565b610dd6565b565b600060078160015b6001811115610c9e57fe5b81526020810191909152604001600020546001600160a01b0316905090565b610cc56118ac565b6000546001600160a01b03908116911614610d15576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600b80546001600160a01b0319166001600160a01b0392909216919091179055565b6000610d448484846119f6565b610db484610d506118ac565b610daf85604051806060016040528060288152602001613229602891396001600160a01b038a16600090815260026020526040812090610d8e6118ac565b6001600160a01b031681526020810191909152604001600020549190611b53565b6118b0565b5060019392505050565b60156020526000908152604090205481565b60085481565b610ddf33610f7d565b811115610e28576040805162461bcd60e51b81526020600482015260126024820152714e6f7420656e6f7567682062616c616e636560701b604482015290519081900360640190fd5b601154336000908152601a60205260409020544291610e47919061199c565b1115610e845760405162461bcd60e51b815260040180806020018281038252603a8152602001806130f7603a913960400191505060405180910390fd5b80610e9c601354601254611bea90919063ffffffff16565b1015610eaf57610eaa611c2c565b610e84565b610eb88161203f565b50565b60065460ff1690565b6000610c20610ed16118ac565b84610daf8560026000610ee26118ac565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549061199c565b7f0000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c59981565b610f406000611558565b610c896001611558565b60186020526000908152604090205481565b60115481565b6007602052600090815260409020546001600160a01b031681565b6001600160a01b031660009081526001602052604090205490565b610fa06118ac565b6000546001600160a01b03908116911614610ff0576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b7f000000000000000000000000584bc13c7d411c00c01a62e8019472de6876843081565b60135481565b6000806007600084600181111561107757fe5b600181111561108257fe5b815260208082019290925260409081016000205481516354198ce960e01b815230600482015291516001600160a01b03909116926354198ce99260248082019391829003018186803b1580156110d757600080fd5b505afa1580156110eb573d6000803e3d6000fd5b505050506040513d602081101561110157600080fd5b50516012546009549192506111219161111b9084906120cb565b90612124565b9392505050565b600f5481565b60196020526000908152604090205460ff1681565b6000546001600160a01b031690565b600060078180610c93565b60105460ff1681565b600c5481565b60058054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c025780601f10610bd757610100808354040283529160200191610c02565b6111d56118ac565b6000546001600160a01b03908116911614611225576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b8015611235576000601155610eb8565b61038460115550565b6000610c2061124b6118ac565b84610daf8560405180606001604052806025815260200161333260259139600260006112756118ac565b6001600160a01b03908116825260208083019390935260409182016000908120918d16815292529020549190611b53565b6000610c206112b36118ac565b84846119f6565b60125481565b60008111611306576040805162461bcd60e51b815260206004820152600e60248201526d416d6f756e7420746f6f206c6f7760901b604482015290519081900360640190fd5b60105460ff166113475760405162461bcd60e51b81526004018080602001828103825260268152602001806133576026913960400191505060405180910390fd5b600f5433600090815260186020526040902054118061137657503360009081526019602052604090205460ff16155b1561147457600f543360009081526018602090815260408083209390935560199052205460ff161580156113ac57506001601454105b156113fe576113e9620186a061111b6113d3600e54620186a0611bea90919063ffffffff16565b33600090815260186020526040902054906120cb565b33600090815260186020526040902055611459565b3360009081526019602052604090205460ff161580156114215750600c54601454105b1561145957611448620186a061111b6113d3600d54620186a0611bea90919063ffffffff16565b336000908152601860205260409020555b336000908152601960205260409020805460ff191660011790555b336000908152601a6020526040902042905561148f81612166565b6008546013546012546114a191611bea565b10610eb8576114ae6121b5565b61148f565b60166020526000908152604090205481565b60006111216114d48484611806565b6001600160a01b0385166000908152601c60205260408120908560018111156114f957fe5b600181111561150457fe5b81526020019081526020016000205461199c90919063ffffffff16565b600e5481565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b600d5481565b60006115643383612632565b336000908152601c60205260408120919250908184600181111561158457fe5b600181111561158f57fe5b8152602001908152602001600020819055506115d281833360186000336001600160a01b03166001600160a01b0316815260200190815260200160002054612749565b5050565b600b546001600160a01b031681565b6115ed6118ac565b6000546001600160a01b0390811691161461163d576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b600a80546001600160a01b0319166001600160a01b0392909216919091179055565b6116676118ac565b6000546001600160a01b039081169116146116b7576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b6001600160a01b0381166116fc5760405162461bcd60e51b81526004018080602001828103825260268152602001806131536026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b61175f6118ac565b6000546001600160a01b039081169116146117af576040805162461bcd60e51b81526020600482018190526024820152600080516020613251833981519152604482015290519081900360640190fd5b611f408111156117f5576040805162461bcd60e51b815260206004820152600c60248201526b08ccaca40e8dede40d0d2ced60a31b604482015290519081900360640190fd5b600f55565b60095481565b60145481565b600061112160095461111b61181a86610f7d565b6118a661182687611064565b6001600160a01b0389166000908152601b602052604081206118a0918a600181111561184e57fe5b600181111561185957fe5b815260200190815260200160002054601660008b600181111561187857fe5b600181111561188357fe5b815260200190815260200160002054611bea90919063ffffffff16565b9061199c565b906120cb565b3390565b6001600160a01b0383166118f55760405162461bcd60e51b81526004018080602001828103825260248152602001806132b76024913960400191505060405180910390fd5b6001600160a01b03821661193a5760405162461bcd60e51b81526004018080602001828103825260228152602001806131796022913960400191505060405180910390fd5b6001600160a01b03808416600081815260026020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b600082820183811015611121576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6001600160a01b038316611a3b5760405162461bcd60e51b81526004018080602001828103825260258152602001806132926025913960400191505060405180910390fd5b6001600160a01b038216611a805760405162461bcd60e51b81526004018080602001828103825260238152602001806130d46023913960400191505060405180910390fd5b611a8b8383836128ee565b611ac88160405180606001604052806026815260200161319b602691396001600160a01b0386166000908152600160205260409020549190611b53565b6001600160a01b038085166000908152600160205260408082209390935590841681522054611af7908261199c565b6001600160a01b0380841660008181526001602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b60008184841115611be25760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611ba7578181015183820152602001611b8f565b50505050905090810190601f168015611bd45780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600061112183836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611b53565b60156020527fa31547ce6245cdb9ecea19cf8c7eb9f5974025bb4075011409251ae855b30aed54600160008190527f27739e4bb5e6f8b5e4b57a047dca8767cc9b982a011081e086cbb0dfa9de818d5490911115611c88575060005b42611dcf60076000846001811115611c9c57fe5b6001811115611ca757fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b031663ee947a7c6040518163ffffffff1660e01b815260040160206040518083038186803b158015611d0157600080fd5b505afa158015611d15573d6000803e3d6000fd5b505050506040513d6020811015611d2b57600080fd5b505160076000856001811115611d3d57fe5b6001811115611d4857fe5b8152602080820192909252604090810160002054815163a673729160e01b815230600482015291516001600160a01b039091169263a67372919260248082019391829003018186803b158015611d9d57600080fd5b505afa158015611db1573d6000803e3d6000fd5b505050506040513d6020811015611dc757600080fd5b50519061199c565b1115611df5576001816001811115611de357fe5b1415611df157506000611df5565b5060015b60076000826001811115611e0557fe5b6001811115611e1057fe5b815260208082019290925260409081016000205481516370a0823160e01b815230600482015291516001600160a01b03909116926370a082319260248082019391829003018186803b158015611e6557600080fd5b505afa158015611e79573d6000803e3d6000fd5b505050506040513d6020811015611e8f57600080fd5b5051611eb5576001816001811115611ea357fe5b1415611eb157506000611eb5565b5060015b42611ec960076000846001811115611c9c57fe5b1115611f065760405162461bcd60e51b81526004018080602001828103825260478152602001806131c16047913960600191505060405180910390fd5b600854601354611f1591611bea565b60135560076000826001811115611f2857fe5b6001811115611f3357fe5b81526020810191909152604090810160009081205482516372424d9960e11b81526001600482015292516001600160a01b039091169263e4849b3292602480830193919282900301818387803b158015611f8c57600080fd5b505af1158015611fa0573d6000803e3d6000fd5b505050507f24cd5f994ad649e7a524dd5aced6dd8e80ca7541246c3cf335422bd80c565caa42823360405180848152602001836001811115611fde57fe5b8152602001826001600160a01b03168152602001935050505060405180910390a1601480546000190190556015600082600181111561201957fe5b600181111561202457fe5b81526020810191909152604001600020805460001901905550565b604080513381526020810183905281517f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364929181900390910190a16120843382612923565b6120b86001600160a01b037f000000000000000000000000584bc13c7d411c00c01a62e8019472de68768430163383612a1f565b6012546120c59082611bea565b60125550565b6000826120da57506000610c24565b828202828482816120e757fe5b04146111215760405162461bcd60e51b81526004018080602001828103825260218152602001806132086021913960400191505060405180910390fd5b600061112183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612a71565b601254612173908261199c565b6012556121ab6001600160a01b037f000000000000000000000000584bc13c7d411c00c01a62e8019472de6876843016333084612ad6565b610eb83382612b36565b60156020527fa31547ce6245cdb9ecea19cf8c7eb9f5974025bb4075011409251ae855b30aed54600160008190527f27739e4bb5e6f8b5e4b57a047dca8767cc9b982a011081e086cbb0dfa9de818d5490911015612211575060005b6007600082600181111561222157fe5b600181111561222c57fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166332cb6b0c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561228657600080fd5b505afa15801561229a573d6000803e3d6000fd5b505050506040513d60208110156122b057600080fd5b5051600760008360018111156122c257fe5b60018111156122cd57fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561232757600080fd5b505afa15801561233b573d6000803e3d6000fd5b505050506040513d602081101561235157600080fd5b5051141561237957600181600181111561236757fe5b141561237557506000612379565b5060015b6007600082600181111561238957fe5b600181111561239457fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166332cb6b0c6040518163ffffffff1660e01b815260040160206040518083038186803b1580156123ee57600080fd5b505afa158015612402573d6000803e3d6000fd5b505050506040513d602081101561241857600080fd5b50516007600083600181111561242a57fe5b600181111561243557fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561248f57600080fd5b505afa1580156124a3573d6000803e3d6000fd5b505050506040513d60208110156124b957600080fd5b5051106124f75760405162461bcd60e51b815260040180806020018281038252602d8152602001806132db602d913960400191505060405180910390fd5b6008546013546125069161199c565b6013556007600082600181111561251957fe5b600181111561252457fe5b8152602081019190915260409081016000908120548251636cb504a560e11b81526001600482015292516001600160a01b039091169263d96a094a92602480830193919282900301818387803b15801561257d57600080fd5b505af1158015612591573d6000803e3d6000fd5b505050507fd1b43b4b3653b24940204c31867a89713bb84aabe4ee82be10570f0dd791ccb0428233604051808481526020018360018111156125cf57fe5b8152602001826001600160a01b03168152602001935050505060405180910390a1601480546001908101909155601590600090839081111561260d57fe5b600181111561261857fe5b815260208101919091526040016000208054600101905550565b600061263d82612c28565b60006126498484611806565b90506016600084600181111561265b57fe5b600181111561266657fe5b815260200190815260200160002054601b6000866001600160a01b03166001600160a01b0316815260200190815260200160002060008560018111156126a857fe5b60018111156126b357fe5b8152602001908152602001600020819055506126fc81601c6000876001600160a01b03166001600160a01b0316815260200190815260200160002060008660018111156114f957fe5b6001600160a01b0385166000908152601c6020526040812091935083919085600181111561272657fe5b600181111561273157fe5b81526020810191909152604001600020555092915050565b6000612766620186a061111b61275f8286611bea565b88906120cb565b905060006127748683611bea565b9050600185600181111561278457fe5b1415612801576040516001600160a01b0385169083156108fc029084906000818181858888f193505050501580156127c0573d6000803e3d6000fd5b50600b546040516001600160a01b039091169082156108fc029083906000818181858888f193505050501580156127fb573d6000803e3d6000fd5b50612883565b600085600181111561280f57fe5b1415612883576128496001600160a01b037f0000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c599168584612a1f565b600b54612883906001600160a01b037f0000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c5998116911683612a1f565b7f42bf830ec222b3077f036a1be5d7d50fd1fc16cfcb9c67a8547cf0241679eae08486848460405180856001600160a01b031681526020018460018111156128c757fe5b815260200183815260200182815260200194505050505060405180910390a1505050505050565b6001600160a01b038316156129065761290683612e81565b6001600160a01b0382161561291e5761291e82612e81565b505050565b6001600160a01b0382166129685760405162461bcd60e51b81526004018080602001828103825260218152602001806132716021913960400191505060405180910390fd5b612974826000836128ee565b6129b181604051806060016040528060228152602001613131602291396001600160a01b0385166000908152600160205260409020549190611b53565b6001600160a01b0383166000908152600160205260409020556003546129d79082611bea565b6003556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b17905261291e908490612e98565b60008183612ac05760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611ba7578181015183820152602001611b8f565b506000838581612acc57fe5b0495945050505050565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180516001600160e01b03166323b872dd60e01b179052612b30908590612e98565b50505050565b6001600160a01b038216612b91576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b612b9d600083836128ee565b600354612baa908261199c565b6003556001600160a01b038216600090815260016020526040902054612bd0908261199c565b6001600160a01b03831660008181526001602090815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b600060076000836001811115612c3a57fe5b6001811115612c4557fe5b815260208082019290925260409081016000205481516354198ce960e01b815230600482015291516001600160a01b03909116926354198ce99260248082019391829003018186803b158015612c9a57600080fd5b505afa158015612cae573d6000803e3d6000fd5b505050506040513d6020811015612cc457600080fd5b505190508015612d725760076000836001811115612cde57fe5b6001811115612ce957fe5b815260200190815260200160002060009054906101000a90046001600160a01b03166001600160a01b031663f011a7af6040518163ffffffff1660e01b8152600401602060405180830381600087803b158015612d4557600080fd5b505af1158015612d59573d6000803e3d6000fd5b505050506040513d6020811015612d6f57600080fd5b50505b600060125411612e23576001826001811115612d8a57fe5b1415612dd057600a546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015612dca573d6000803e3d6000fd5b50612e1e565b6000826001811115612dde57fe5b1415612e1e57600a54612e1e906001600160a01b037f0000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c5998116911683612a1f565b6115d2565b612e51612e4160125461111b600954856120cb90919063ffffffff16565b601660008560018111156114f957fe5b60166000846001811115612e6157fe5b6001811115612e6c57fe5b81526020810191909152604001600020555050565b612e8c816000612632565b506115d2816001612632565b6060612eed826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316612f499092919063ffffffff16565b80519091501561291e57808060200190516020811015612f0c57600080fd5b505161291e5760405162461bcd60e51b815260040180806020018281038252602a815260200180613308602a913960400191505060405180910390fd5b6060612f588484600085612f60565b949350505050565b6060612f6b856130cd565b612fbc576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b60208310612ffb5780518252601f199092019160209182019101612fdc565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461305d576040519150601f19603f3d011682016040523d82523d6000602084013e613062565b606091505b50915091508115613076579150612f589050565b8051156130865780518082602001fd5b60405162461bcd60e51b8152602060048201818152865160248401528651879391928392604401919085019080838360008315611ba7578181015183820152602001611b8f565b3b15159056fe45524332303a207472616e7366657220746f20746865207a65726f2061646472657373596f75206465706f7369746564206c657373207468616e203135206d696e732061676f2e20596f75722066756e647320617265206c6f636b656445524332303a206275726e20616d6f756e7420657863656564732062616c616e63654f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e63654c6f742073616c65206973206c6f636b65642062792048656769632e2046756e64732073686f756c6420626520617661696c61626c6520696e206c657373207468616e20323468536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e63654f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657245524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373546865726520617265206e6f206d6f726520617661696c61626c65206c6f747320666f722070757263686173655361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656445524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f4465706f7369747320617265206e6f7420616c6c6f77656420617420746865206d6f6d656e74a26469706673582212206f3f52c5d0a1378ddc30763d84d626a114e49d7e87c39aa0184ce79b18b7a4a864736f6c634300060c0033

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

000000000000000000000000584bc13c7d411c00c01a62e8019472de687684300000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c599000000000000000000000000840a1ae46b7364855206eb5b7286ab7e207e515b0000000000000000000000001ef61e3e5676ec182eed6f052f8920fd49c7f69a

-----Decoded View---------------
Arg [0] : _HEGIC (address): 0x584bC13c7D411c00c01A62e8019472dE68768430
Arg [1] : _WBTC (address): 0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599
Arg [2] : _stakingWBTC (address): 0x840a1AE46B7364855206Eb5b7286Ab7E207e515b
Arg [3] : _stakingETH (address): 0x1Ef61E3E5676eC182EED6F052F8920fD49C7f69a

-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 000000000000000000000000584bc13c7d411c00c01a62e8019472de68768430
Arg [1] : 0000000000000000000000002260fac5e5542a773aa44fbcfedf7c193bc2c599
Arg [2] : 000000000000000000000000840a1ae46b7364855206eb5b7286ab7e207e515b
Arg [3] : 0000000000000000000000001ef61e3e5676ec182eed6f052f8920fd49c7f69a


Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.