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

Overview

Max Total Supply

0.027472804786911864 vSLP

Holders

40

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 18 Decimals)

Filtered by Token Holder
donalmoore.eth
Balance
0.000000562054769216 vSLP

Value
$0.00
0x564e67f219d0aa971f76da43bd96043740244b51
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:
MithJar

Compiler Version
v0.6.7+commit.b8d736ae

Optimization Enabled:
Yes with 9999 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2021-01-24
*/

// hevm: flattened sources of src/mith-jar.sol
pragma solidity >=0.6.0 <0.7.0 >=0.6.2 <0.7.0 >=0.6.7 <0.7.0;

////// src/interfaces/strategy.sol
// SPDX-License-Identifier: MIT
/* pragma solidity ^0.6.2; */

interface IStrategy {
    function rewards() external view returns (address);

    function gauge() external view returns (address);

    function want() external view returns (address);

    function initiator() external view returns (address);

    function stakingContract() external view returns (address);

    function treasury() external view returns (address);

    function deposit() external;

    function withdrawForSwap(uint256) external returns (uint256);

    function withdraw(address) external;

    function withdraw(uint256) external;

    function skim() external;

    function withdrawAll() external returns (uint256);

    function balanceOf() external view returns (uint256);

    function getHarvestable() external view returns (uint256);

    function harvest() external;

    function setJar(address _jar) external;
    
    function setInitiator(address _initiator) external;

    function setStakingContract(address _stakingContract) external;

    function execute(address _target, bytes calldata _data)
        external
        payable
        returns (bytes memory response);

    function execute(bytes calldata _data)
        external
        payable
        returns (bytes memory response);
}

////// src/lib/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;
    }
}

////// src/lib/safe-math.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;
    }
}
////// src/lib/erc20.sol

// File: contracts/GSN/Context.sol

// SPDX-License-Identifier: MIT

/* pragma solidity ^0.6.0; */

/* import "./safe-math.sol"; */
/* import "./context.sol"; */

// File: contracts/token/ERC20/IERC20.sol


/**
 * @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: contracts/utils/Address.sol


/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // 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: contracts/token/ERC20/ERC20.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 { }
}

/**
 * @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");
        }
    }
}
////// src/mith-jar.sol
// https://github.com/iearn-finance/vaults/blob/master/contracts/vaults/yVault.sol

/* pragma solidity ^0.6.7; */

/* import "./interfaces/strategy.sol"; */

/* import "./lib/erc20.sol"; */
/* import "./lib/safe-math.sol"; */

contract MithJar is ERC20 {
    using SafeERC20 for IERC20;
    using Address for address;
    using SafeMath for uint256;

    IERC20 public token;

    uint256 public min = 9500;
    uint256 public constant max = 10000;

    address public strategy;

    constructor(IStrategy _strategy)
        public
        ERC20(
            string(abi.encodePacked(ERC20(_strategy.want()).name(), "vault")),
            string(abi.encodePacked("v", ERC20(_strategy.want()).symbol()))
        )
    {
        _setupDecimals(ERC20(_strategy.want()).decimals());
        token = IERC20(_strategy.want());
        strategy = address(_strategy);
    }

    function balance() public view returns (uint256) {
        return
            token.balanceOf(address(this)).add(
                IStrategy(strategy).balanceOf()
            );
    }

    // Custom logic in here for how much the jars allows to be borrowed
    // Sets minimum required on-hand to keep small withdrawals cheap
    function available() public view returns (uint256) {
        return token.balanceOf(address(this)).mul(min).div(max);
    }

    function earn() public {
        uint256 _bal = available();
        token.safeTransfer(strategy, _bal);
        IStrategy(strategy).deposit();
    }

    function depositAll() external {
        deposit(token.balanceOf(msg.sender));
    }

    function deposit(uint256 _amount) public {
        uint256 _pool = balance();
        uint256 _before = token.balanceOf(address(this));
        token.safeTransferFrom(msg.sender, address(this), _amount);
        uint256 _after = token.balanceOf(address(this));
        _amount = _after.sub(_before); // Additional check for deflationary tokens
        uint256 shares = 0;
        if (totalSupply() == 0) {
            shares = _amount;
        } else {
            shares = (_amount.mul(totalSupply())).div(_pool);
        }
        _mint(msg.sender, shares);
    }

    function withdrawAll() external {
        withdraw(balanceOf(msg.sender));
    }

    // No rebalance implementation for lower fees and faster swaps
    function withdraw(uint256 _shares) public {
        uint256 r = (balance().mul(_shares)).div(totalSupply());
        _burn(msg.sender, _shares);

        // Check balance
        uint256 b = token.balanceOf(address(this));
        if (b < r) {
            uint256 _withdraw = r.sub(b);
            IStrategy(strategy).withdraw(_withdraw);
            uint256 _after = token.balanceOf(address(this));
            uint256 _diff = _after.sub(b);
            if (_diff < _withdraw) {
                r = b.add(_diff);
            }
        }

        token.safeTransfer(msg.sender, r);
    }

    function getRatio() public view returns (uint256) {
        return balance().mul(1e18).div(totalSupply());
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IStrategy","name":"_strategy","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":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"},{"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":[],"name":"available","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"balance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":"depositAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"earn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getRatio","outputs":[{"internalType":"uint256","name":"","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":[],"name":"max","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"min","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"strategy","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"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":"uint256","name":"_shares","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawAll","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405261251c6006553480156200001757600080fd5b506040516200219f3803806200219f833981810160405260208110156200003d57600080fd5b505160408051631f1fcd5160e01b815290516001600160a01b03831691631f1fcd51916004808301926020929190829003018186803b1580156200008057600080fd5b505afa15801562000095573d6000803e3d6000fd5b505050506040513d6020811015620000ac57600080fd5b5051604080516306fdde0360e01b815290516001600160a01b03909216916306fdde0391600480820192600092909190829003018186803b158015620000f157600080fd5b505afa15801562000106573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156200013057600080fd5b81019080805160405193929190846401000000008211156200015157600080fd5b9083019060208201858111156200016757600080fd5b82516401000000008111828201881017156200018257600080fd5b82525081516020918201929091019080838360005b83811015620001b157818101518382015260200162000197565b50505050905090810190601f168015620001df5780820380516001836020036101000a031916815260200191505b506040525050506040516020018082805190602001908083835b602083106200021a5780518252601f199092019160209182019101620001f9565b6001836020036101000a03801982511681845116808217855250505050505090500180641d985d5b1d60da1b815250600501915050604051602081830303815290604052816001600160a01b0316631f1fcd516040518163ffffffff1660e01b815260040160206040518083038186803b1580156200029857600080fd5b505afa158015620002ad573d6000803e3d6000fd5b505050506040513d6020811015620002c457600080fd5b5051604080516395d89b4160e01b815290516001600160a01b03909216916395d89b4191600480820192600092909190829003018186803b1580156200030957600080fd5b505afa1580156200031e573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156200034857600080fd5b81019080805160405193929190846401000000008211156200036957600080fd5b9083019060208201858111156200037f57600080fd5b82516401000000008111828201881017156200039a57600080fd5b82525081516020918201929091019080838360005b83811015620003c9578181015183820152602001620003af565b50505050905090810190601f168015620003f75780820380516001836020036101000a031916815260200191505b506040525050506040516020018080603b60f91b81525060010182805190602001908083835b602083106200043e5780518252601f1990920191602091820191016200041d565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405160208183030381529060405281600390805190602001906200048a92919062000662565b508051620004a090600490602084019062000662565b50506005805460ff191660121790555060408051631f1fcd5160e01b81529051620005a5916001600160a01b03841691631f1fcd5191600480820192602092909190829003018186803b158015620004f757600080fd5b505afa1580156200050c573d6000803e3d6000fd5b505050506040513d60208110156200052357600080fd5b50516040805163313ce56760e01b815290516001600160a01b039092169163313ce56791600480820192602092909190829003018186803b1580156200056857600080fd5b505afa1580156200057d573d6000803e3d6000fd5b505050506040513d60208110156200059457600080fd5b50516001600160e01b036200064c16565b806001600160a01b0316631f1fcd516040518163ffffffff1660e01b815260040160206040518083038186803b158015620005df57600080fd5b505afa158015620005f4573d6000803e3d6000fd5b505050506040513d60208110156200060b57600080fd5b505160058054610100600160a81b0319166101006001600160a01b0393841602179055600780546001600160a01b0319169290911691909117905562000707565b6005805460ff191660ff92909216919091179055565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620006a557805160ff1916838001178555620006d5565b82800160010185558215620006d5579182015b82811115620006d5578251825591602001919060010190620006b8565b50620006e3929150620006e7565b5090565b6200070491905b80821115620006e35760008155600101620006ee565b90565b611a8880620007176000396000f3fe608060405234801561001057600080fd5b506004361061018d5760003560e01c806395d89b41116100e3578063d389800f1161008c578063ec1ebd7a11610066578063ec1ebd7a1461042d578063f889794514610435578063fc0c546a1461043d5761018d565b8063d389800f146103ef578063dd62ed3e146103f7578063de5f6268146104255761018d565b8063a9059cbb116100bd578063a9059cbb1461039e578063b69ef8a8146103ca578063b6b55f25146103d25761018d565b806395d89b4114610346578063a457c2d71461034e578063a8c62e761461037a5761018d565b8063313ce567116101455780636ac5db191161011f5780636ac5db191461031057806370a0823114610318578063853828b61461033e5761018d565b8063313ce567146102be57806339509351146102dc57806348a0d754146103085761018d565b806318160ddd1161017657806318160ddd1461024f57806323b872dd146102695780632e1a7d4d1461029f5761018d565b806306fdde0314610192578063095ea7b31461020f575b600080fd5b61019a610445565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101d45781810151838201526020016101bc565b50505050905090810190601f1680156102015780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61023b6004803603604081101561022557600080fd5b506001600160a01b0381351690602001356104f9565b604080519115158252519081900360200190f35b610257610517565b60408051918252519081900360200190f35b61023b6004803603606081101561027f57600080fd5b506001600160a01b0381358116916020810135909116906040013561051d565b6102bc600480360360208110156102b557600080fd5b50356105aa565b005b6102c6610805565b6040805160ff9092168252519081900360200190f35b61023b600480360360408110156102f257600080fd5b506001600160a01b03813516906020013561080e565b610257610862565b610257610918565b6102576004803603602081101561032e57600080fd5b50356001600160a01b031661091e565b6102bc610939565b61019a61094c565b61023b6004803603604081101561036457600080fd5b506001600160a01b0381351690602001356109cb565b610382610a39565b604080516001600160a01b039092168252519081900360200190f35b61023b600480360360408110156103b457600080fd5b506001600160a01b038135169060200135610a48565b610257610a5c565b6102bc600480360360208110156103e857600080fd5b5035610b7b565b6102bc610d2d565b6102576004803603604081101561040d57600080fd5b506001600160a01b0381358116916020013516610dc6565b6102bc610df1565b610257610e8c565b610257610ead565b610382610eb3565b60038054604080516020601f60027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156104ef5780601f106104c4576101008083540402835291602001916104ef565b820191906000526020600020905b8154815290600101906020018083116104d257829003601f168201915b5050505050905090565b600061050d610506610ec7565b8484610ecb565b5060015b92915050565b60025490565b600061052a848484610fb7565b6105a084610536610ec7565b61059b85604051806060016040528060288152602001611972602891396001600160a01b038a16600090815260016020526040812090610574610ec7565b6001600160a01b03168152602081019190915260400160002054919063ffffffff61111e16565b610ecb565b5060019392505050565b60006105db6105b7610517565b6105cf846105c3610a5c565b9063ffffffff6111b516565b9063ffffffff61121516565b90506105e73383611257565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152905160009261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b15801561065057600080fd5b505afa158015610664573d6000803e3d6000fd5b505050506040513d602081101561067a57600080fd5b50519050818110156107e4576000610698838363ffffffff61135f16565b600754604080517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905290519293506001600160a01b0390911691632e1a7d4d9160248082019260009290919082900301818387803b15801561070157600080fd5b505af1158015610715573d6000803e3d6000fd5b5050600554604080517f70a082310000000000000000000000000000000000000000000000000000000081523060048201529051600094506101009092046001600160a01b031692506370a08231916024808301926020929190829003018186803b15801561078357600080fd5b505afa158015610797573d6000803e3d6000fd5b505050506040513d60208110156107ad57600080fd5b5051905060006107c3828563ffffffff61135f16565b9050828110156107e0576107dd848263ffffffff6113a116565b94505b5050505b6005546108009061010090046001600160a01b031633846113fb565b505050565b60055460ff1690565b600061050d61081b610ec7565b8461059b856001600061082c610ec7565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff6113a116565b60006109136127106105cf600654600560019054906101000a90046001600160a01b03166001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156108db57600080fd5b505afa1580156108ef573d6000803e3d6000fd5b505050506040513d602081101561090557600080fd5b50519063ffffffff6111b516565b905090565b61271081565b6001600160a01b031660009081526020819052604090205490565b61094a6109453361091e565b6105aa565b565b60048054604080516020601f60027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156104ef5780601f106104c4576101008083540402835291602001916104ef565b600061050d6109d8610ec7565b8461059b85604051806060016040528060258152602001611a2e6025913960016000610a02610ec7565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff61111e16565b6007546001600160a01b031681565b600061050d610a55610ec7565b8484610fb7565b6000610913600760009054906101000a90046001600160a01b03166001600160a01b031663722713f76040518163ffffffff1660e01b815260040160206040518083038186803b158015610aaf57600080fd5b505afa158015610ac3573d6000803e3d6000fd5b505050506040513d6020811015610ad957600080fd5b5051600554604080517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290516101009092046001600160a01b0316916370a0823191602480820192602092909190829003018186803b158015610b4357600080fd5b505afa158015610b57573d6000803e3d6000fd5b505050506040513d6020811015610b6d57600080fd5b50519063ffffffff6113a116565b6000610b85610a5c565b600554604080517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290519293506000926101009092046001600160a01b0316916370a0823191602480820192602092909190829003018186803b158015610bf357600080fd5b505afa158015610c07573d6000803e3d6000fd5b505050506040513d6020811015610c1d57600080fd5b5051600554909150610c3f9061010090046001600160a01b031633308661147b565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152905160009261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610ca857600080fd5b505afa158015610cbc573d6000803e3d6000fd5b505050506040513d6020811015610cd257600080fd5b50519050610ce6818363ffffffff61135f16565b93506000610cf2610517565b610cfd575083610d1c565b610d19846105cf610d0c610517565b889063ffffffff6111b516565b90505b610d263382611509565b5050505050565b6000610d37610862565b600754600554919250610d629161010090046001600160a01b0390811691168363ffffffff6113fb16565b600760009054906101000a90046001600160a01b03166001600160a01b031663d0e30db06040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610db257600080fd5b505af1158015610d26573d6000803e3d6000fd5b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152336004820152905161094a9261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5b57600080fd5b505afa158015610e6f573d6000803e3d6000fd5b505050506040513d6020811015610e8557600080fd5b5051610b7b565b6000610913610e99610517565b6105cf670de0b6b3a76400006105c3610a5c565b60065481565b60055461010090046001600160a01b031681565b3390565b6001600160a01b038316610f105760405162461bcd60e51b81526004018080602001828103825260248152602001806119e06024913960400191505060405180910390fd5b6001600160a01b038216610f555760405162461bcd60e51b81526004018080602001828103825260228152602001806119096022913960400191505060405180910390fd5b6001600160a01b03808416600081815260016020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6001600160a01b038316610ffc5760405162461bcd60e51b81526004018080602001828103825260258152602001806119bb6025913960400191505060405180910390fd5b6001600160a01b0382166110415760405162461bcd60e51b81526004018080602001828103825260238152602001806118c46023913960400191505060405180910390fd5b61104c838383610800565b61108f8160405180606001604052806026815260200161192b602691396001600160a01b038616600090815260208190526040902054919063ffffffff61111e16565b6001600160a01b0380851660009081526020819052604080822093909355908416815220546110c4908263ffffffff6113a116565b6001600160a01b038084166000818152602081815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b600081848411156111ad5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561117257818101518382015260200161115a565b50505050905090810190601f16801561119f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6000826111c457506000610511565b828202828482816111d157fe5b041461120e5760405162461bcd60e51b81526004018080602001828103825260218152602001806119516021913960400191505060405180910390fd5b9392505050565b600061120e83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611605565b6001600160a01b03821661129c5760405162461bcd60e51b815260040180806020018281038252602181526020018061199a6021913960400191505060405180910390fd5b6112a882600083610800565b6112eb816040518060600160405280602281526020016118e7602291396001600160a01b038516600090815260208190526040902054919063ffffffff61111e16565b6001600160a01b038316600090815260208190526040902055600254611317908263ffffffff61135f16565b6002556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b600061120e83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061111e565b60008282018381101561120e576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb0000000000000000000000000000000000000000000000000000000017905261080090849061166a565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f23b872dd0000000000000000000000000000000000000000000000000000000017905261150390859061166a565b50505050565b6001600160a01b038216611564576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b61157060008383610800565b600254611583908263ffffffff6113a116565b6002556001600160a01b0382166000908152602081905260409020546115af908263ffffffff6113a116565b6001600160a01b0383166000818152602081815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b600081836116545760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561117257818101518382015260200161115a565b50600083858161166057fe5b0495945050505050565b60606116bf826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661171b9092919063ffffffff16565b805190915015610800578080602001905160208110156116de57600080fd5b50516108005760405162461bcd60e51b815260040180806020018281038252602a815260200180611a04602a913960400191505060405180910390fd5b606061172a8484600085611732565b949350505050565b606061173d856118bd565b61178e576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106117eb57805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe090920191602091820191016117ae565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461184d576040519150601f19603f3d011682016040523d82523d6000602084013e611852565b606091505b5091509150811561186657915061172a9050565b8051156118765780518082602001fd5b60405162461bcd60e51b815260206004820181815286516024840152865187939192839260440191908501908083836000831561117257818101518382015260200161115a565b3b15159056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f20616464726573735361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656445524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa2646970667358221220bdbd996b0d590b517f8bc790e4b4dfef2ec4f02e6a078e7bb2e65a9deafdcc3764736f6c6343000607003300000000000000000000000023f503725330c0e181a1ebb3e17d43fec0ed2773

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061018d5760003560e01c806395d89b41116100e3578063d389800f1161008c578063ec1ebd7a11610066578063ec1ebd7a1461042d578063f889794514610435578063fc0c546a1461043d5761018d565b8063d389800f146103ef578063dd62ed3e146103f7578063de5f6268146104255761018d565b8063a9059cbb116100bd578063a9059cbb1461039e578063b69ef8a8146103ca578063b6b55f25146103d25761018d565b806395d89b4114610346578063a457c2d71461034e578063a8c62e761461037a5761018d565b8063313ce567116101455780636ac5db191161011f5780636ac5db191461031057806370a0823114610318578063853828b61461033e5761018d565b8063313ce567146102be57806339509351146102dc57806348a0d754146103085761018d565b806318160ddd1161017657806318160ddd1461024f57806323b872dd146102695780632e1a7d4d1461029f5761018d565b806306fdde0314610192578063095ea7b31461020f575b600080fd5b61019a610445565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101d45781810151838201526020016101bc565b50505050905090810190601f1680156102015780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61023b6004803603604081101561022557600080fd5b506001600160a01b0381351690602001356104f9565b604080519115158252519081900360200190f35b610257610517565b60408051918252519081900360200190f35b61023b6004803603606081101561027f57600080fd5b506001600160a01b0381358116916020810135909116906040013561051d565b6102bc600480360360208110156102b557600080fd5b50356105aa565b005b6102c6610805565b6040805160ff9092168252519081900360200190f35b61023b600480360360408110156102f257600080fd5b506001600160a01b03813516906020013561080e565b610257610862565b610257610918565b6102576004803603602081101561032e57600080fd5b50356001600160a01b031661091e565b6102bc610939565b61019a61094c565b61023b6004803603604081101561036457600080fd5b506001600160a01b0381351690602001356109cb565b610382610a39565b604080516001600160a01b039092168252519081900360200190f35b61023b600480360360408110156103b457600080fd5b506001600160a01b038135169060200135610a48565b610257610a5c565b6102bc600480360360208110156103e857600080fd5b5035610b7b565b6102bc610d2d565b6102576004803603604081101561040d57600080fd5b506001600160a01b0381358116916020013516610dc6565b6102bc610df1565b610257610e8c565b610257610ead565b610382610eb3565b60038054604080516020601f60027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156104ef5780601f106104c4576101008083540402835291602001916104ef565b820191906000526020600020905b8154815290600101906020018083116104d257829003601f168201915b5050505050905090565b600061050d610506610ec7565b8484610ecb565b5060015b92915050565b60025490565b600061052a848484610fb7565b6105a084610536610ec7565b61059b85604051806060016040528060288152602001611972602891396001600160a01b038a16600090815260016020526040812090610574610ec7565b6001600160a01b03168152602081019190915260400160002054919063ffffffff61111e16565b610ecb565b5060019392505050565b60006105db6105b7610517565b6105cf846105c3610a5c565b9063ffffffff6111b516565b9063ffffffff61121516565b90506105e73383611257565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152905160009261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b15801561065057600080fd5b505afa158015610664573d6000803e3d6000fd5b505050506040513d602081101561067a57600080fd5b50519050818110156107e4576000610698838363ffffffff61135f16565b600754604080517f2e1a7d4d0000000000000000000000000000000000000000000000000000000081526004810184905290519293506001600160a01b0390911691632e1a7d4d9160248082019260009290919082900301818387803b15801561070157600080fd5b505af1158015610715573d6000803e3d6000fd5b5050600554604080517f70a082310000000000000000000000000000000000000000000000000000000081523060048201529051600094506101009092046001600160a01b031692506370a08231916024808301926020929190829003018186803b15801561078357600080fd5b505afa158015610797573d6000803e3d6000fd5b505050506040513d60208110156107ad57600080fd5b5051905060006107c3828563ffffffff61135f16565b9050828110156107e0576107dd848263ffffffff6113a116565b94505b5050505b6005546108009061010090046001600160a01b031633846113fb565b505050565b60055460ff1690565b600061050d61081b610ec7565b8461059b856001600061082c610ec7565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549063ffffffff6113a116565b60006109136127106105cf600654600560019054906101000a90046001600160a01b03166001600160a01b03166370a08231306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156108db57600080fd5b505afa1580156108ef573d6000803e3d6000fd5b505050506040513d602081101561090557600080fd5b50519063ffffffff6111b516565b905090565b61271081565b6001600160a01b031660009081526020819052604090205490565b61094a6109453361091e565b6105aa565b565b60048054604080516020601f60027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101006001881615020190951694909404938401819004810282018101909252828152606093909290918301828280156104ef5780601f106104c4576101008083540402835291602001916104ef565b600061050d6109d8610ec7565b8461059b85604051806060016040528060258152602001611a2e6025913960016000610a02610ec7565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919063ffffffff61111e16565b6007546001600160a01b031681565b600061050d610a55610ec7565b8484610fb7565b6000610913600760009054906101000a90046001600160a01b03166001600160a01b031663722713f76040518163ffffffff1660e01b815260040160206040518083038186803b158015610aaf57600080fd5b505afa158015610ac3573d6000803e3d6000fd5b505050506040513d6020811015610ad957600080fd5b5051600554604080517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290516101009092046001600160a01b0316916370a0823191602480820192602092909190829003018186803b158015610b4357600080fd5b505afa158015610b57573d6000803e3d6000fd5b505050506040513d6020811015610b6d57600080fd5b50519063ffffffff6113a116565b6000610b85610a5c565b600554604080517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015290519293506000926101009092046001600160a01b0316916370a0823191602480820192602092909190829003018186803b158015610bf357600080fd5b505afa158015610c07573d6000803e3d6000fd5b505050506040513d6020811015610c1d57600080fd5b5051600554909150610c3f9061010090046001600160a01b031633308661147b565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152905160009261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610ca857600080fd5b505afa158015610cbc573d6000803e3d6000fd5b505050506040513d6020811015610cd257600080fd5b50519050610ce6818363ffffffff61135f16565b93506000610cf2610517565b610cfd575083610d1c565b610d19846105cf610d0c610517565b889063ffffffff6111b516565b90505b610d263382611509565b5050505050565b6000610d37610862565b600754600554919250610d629161010090046001600160a01b0390811691168363ffffffff6113fb16565b600760009054906101000a90046001600160a01b03166001600160a01b031663d0e30db06040518163ffffffff1660e01b8152600401600060405180830381600087803b158015610db257600080fd5b505af1158015610d26573d6000803e3d6000fd5b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b600554604080517f70a08231000000000000000000000000000000000000000000000000000000008152336004820152905161094a9261010090046001600160a01b0316916370a08231916024808301926020929190829003018186803b158015610e5b57600080fd5b505afa158015610e6f573d6000803e3d6000fd5b505050506040513d6020811015610e8557600080fd5b5051610b7b565b6000610913610e99610517565b6105cf670de0b6b3a76400006105c3610a5c565b60065481565b60055461010090046001600160a01b031681565b3390565b6001600160a01b038316610f105760405162461bcd60e51b81526004018080602001828103825260248152602001806119e06024913960400191505060405180910390fd5b6001600160a01b038216610f555760405162461bcd60e51b81526004018080602001828103825260228152602001806119096022913960400191505060405180910390fd5b6001600160a01b03808416600081815260016020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6001600160a01b038316610ffc5760405162461bcd60e51b81526004018080602001828103825260258152602001806119bb6025913960400191505060405180910390fd5b6001600160a01b0382166110415760405162461bcd60e51b81526004018080602001828103825260238152602001806118c46023913960400191505060405180910390fd5b61104c838383610800565b61108f8160405180606001604052806026815260200161192b602691396001600160a01b038616600090815260208190526040902054919063ffffffff61111e16565b6001600160a01b0380851660009081526020819052604080822093909355908416815220546110c4908263ffffffff6113a116565b6001600160a01b038084166000818152602081815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b600081848411156111ad5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561117257818101518382015260200161115a565b50505050905090810190601f16801561119f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b6000826111c457506000610511565b828202828482816111d157fe5b041461120e5760405162461bcd60e51b81526004018080602001828103825260218152602001806119516021913960400191505060405180910390fd5b9392505050565b600061120e83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611605565b6001600160a01b03821661129c5760405162461bcd60e51b815260040180806020018281038252602181526020018061199a6021913960400191505060405180910390fd5b6112a882600083610800565b6112eb816040518060600160405280602281526020016118e7602291396001600160a01b038516600090815260208190526040902054919063ffffffff61111e16565b6001600160a01b038316600090815260208190526040902055600254611317908263ffffffff61135f16565b6002556040805182815290516000916001600160a01b038516917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b600061120e83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061111e565b60008282018381101561120e576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb0000000000000000000000000000000000000000000000000000000017905261080090849061166a565b604080516001600160a01b0380861660248301528416604482015260648082018490528251808303909101815260849091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f23b872dd0000000000000000000000000000000000000000000000000000000017905261150390859061166a565b50505050565b6001600160a01b038216611564576040805162461bcd60e51b815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015290519081900360640190fd5b61157060008383610800565b600254611583908263ffffffff6113a116565b6002556001600160a01b0382166000908152602081905260409020546115af908263ffffffff6113a116565b6001600160a01b0383166000818152602081815260408083209490945583518581529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35050565b600081836116545760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561117257818101518382015260200161115a565b50600083858161166057fe5b0495945050505050565b60606116bf826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661171b9092919063ffffffff16565b805190915015610800578080602001905160208110156116de57600080fd5b50516108005760405162461bcd60e51b815260040180806020018281038252602a815260200180611a04602a913960400191505060405180910390fd5b606061172a8484600085611732565b949350505050565b606061173d856118bd565b61178e576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106117eb57805182527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe090920191602091820191016117ae565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d806000811461184d576040519150601f19603f3d011682016040523d82523d6000602084013e611852565b606091505b5091509150811561186657915061172a9050565b8051156118765780518082602001fd5b60405162461bcd60e51b815260206004820181815286516024840152865187939192839260440191908501908083836000831561117257818101518382015260200161115a565b3b15159056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f20616464726573735361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656445524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa2646970667358221220bdbd996b0d590b517f8bc790e4b4dfef2ec4f02e6a078e7bb2e65a9deafdcc3764736f6c63430006070033

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

00000000000000000000000023f503725330c0e181a1ebb3e17d43fec0ed2773

-----Decoded View---------------
Arg [0] : _strategy (address): 0x23f503725330C0e181a1eBB3e17d43FEC0ed2773

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 00000000000000000000000023f503725330c0e181a1ebb3e17d43fec0ed2773


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.