ETH Price: $3,326.34 (-4.50%)
Gas: 3 Gwei

Contract

0xFe27534EA0c016634b2DaA97Ae3eF43fEe71EEB0
 
Transaction Hash
Method
Block
From
To
Claim For203632252024-07-22 16:20:352 days ago1721665235IN
0xFe27534E...fEe71EEB0
0 ETH0.0007358113.07516684
Claim For203607492024-07-22 8:02:352 days ago1721635355IN
0xFe27534E...fEe71EEB0
0 ETH0.00025124.46385051
Claim For203532192024-07-21 6:48:233 days ago1721544503IN
0xFe27534E...fEe71EEB0
0 ETH0.000139642.48139538
Claim For203468672024-07-20 9:32:234 days ago1721467943IN
0xFe27534E...fEe71EEB0
0 ETH0.000259343.53451594
Claim For203429622024-07-19 20:27:115 days ago1721420831IN
0xFe27534E...fEe71EEB0
0 ETH0.000276584.91473105
Claim For203410702024-07-19 14:06:475 days ago1721398007IN
0xFe27534E...fEe71EEB0
0 ETH0.000480028.52978906
Claim For203392792024-07-19 8:07:595 days ago1721376479IN
0xFe27534E...fEe71EEB0
0 ETH0.000432377.6830921
Claim For203258352024-07-17 11:05:237 days ago1721214323IN
0xFe27534E...fEe71EEB0
0 ETH0.000478218.49944788
Claim For203171992024-07-16 6:12:118 days ago1721110331IN
0xFe27534E...fEe71EEB0
0 ETH0.000231994.12244693
Claim For203149212024-07-15 22:34:238 days ago1721082863IN
0xFe27534E...fEe71EEB0
0 ETH0.00040667.22520388
Claim For202979562024-07-13 13:43:1111 days ago1720878191IN
0xFe27534E...fEe71EEB0
0 ETH0.000121021.64939107
Claim For202911272024-07-12 14:49:5912 days ago1720795799IN
0xFe27534E...fEe71EEB0
0 ETH0.000346186.15163742
Claim For202829552024-07-11 11:26:2313 days ago1720697183IN
0xFe27534E...fEe71EEB0
0 ETH0.00020293.60629693
Claim For202754052024-07-10 10:09:2314 days ago1720606163IN
0xFe27534E...fEe71EEB0
0 ETH0.000351624.79289414
Claim For202715402024-07-09 21:12:3515 days ago1720559555IN
0xFe27534E...fEe71EEB0
0 ETH0.000471496.42580592
Claim For202570932024-07-07 20:43:1117 days ago1720384991IN
0xFe27534E...fEe71EEB0
0 ETH0.000120262.13697727
Claim For202544532024-07-07 11:52:1117 days ago1720353131IN
0xFe27534E...fEe71EEB0
0 ETH0.000085441.51834617
Claim For202514802024-07-07 1:53:3517 days ago1720317215IN
0xFe27534E...fEe71EEB0
0 ETH0.000139772.48377777
Claim For202511512024-07-07 0:47:3517 days ago1720313255IN
0xFe27534E...fEe71EEB0
0 ETH0.000067531.2
Claim For202419062024-07-05 17:49:5919 days ago1720201799IN
0xFe27534E...fEe71EEB0
0 ETH0.000326745.80609807
Claim For202400962024-07-05 11:46:1119 days ago1720179971IN
0xFe27534E...fEe71EEB0
0 ETH0.000442637.865395
Claim For202393152024-07-05 9:09:2319 days ago1720170563IN
0xFe27534E...fEe71EEB0
0 ETH0.0006114910.8660458
Claim For202371362024-07-05 1:51:1119 days ago1720144271IN
0xFe27534E...fEe71EEB0
0 ETH0.000426517.57898478
Claim For202330852024-07-04 12:15:1120 days ago1720095311IN
0xFe27534E...fEe71EEB0
0 ETH0.0006705911.91624298
Claim For202252872024-07-03 10:08:2321 days ago1720001303IN
0xFe27534E...fEe71EEB0
0 ETH0.000159672.83739609
View all transactions

Latest 25 internal transactions (View All)

Advanced mode:
Parent Transaction Hash Block From To
203632252024-07-22 16:20:352 days ago1721665235
0xFe27534E...fEe71EEB0
0 ETH
203607492024-07-22 8:02:352 days ago1721635355
0xFe27534E...fEe71EEB0
0 ETH
203532192024-07-21 6:48:233 days ago1721544503
0xFe27534E...fEe71EEB0
0 ETH
203468672024-07-20 9:32:234 days ago1721467943
0xFe27534E...fEe71EEB0
0 ETH
203429622024-07-19 20:27:115 days ago1721420831
0xFe27534E...fEe71EEB0
0 ETH
203410702024-07-19 14:06:475 days ago1721398007
0xFe27534E...fEe71EEB0
0 ETH
203392792024-07-19 8:07:595 days ago1721376479
0xFe27534E...fEe71EEB0
0 ETH
203258352024-07-17 11:05:237 days ago1721214323
0xFe27534E...fEe71EEB0
0 ETH
203171992024-07-16 6:12:118 days ago1721110331
0xFe27534E...fEe71EEB0
0 ETH
203149212024-07-15 22:34:238 days ago1721082863
0xFe27534E...fEe71EEB0
0 ETH
202979562024-07-13 13:43:1111 days ago1720878191
0xFe27534E...fEe71EEB0
0 ETH
202911272024-07-12 14:49:5912 days ago1720795799
0xFe27534E...fEe71EEB0
0 ETH
202829552024-07-11 11:26:2313 days ago1720697183
0xFe27534E...fEe71EEB0
0 ETH
202754052024-07-10 10:09:2314 days ago1720606163
0xFe27534E...fEe71EEB0
0 ETH
202715402024-07-09 21:12:3515 days ago1720559555
0xFe27534E...fEe71EEB0
0 ETH
202570932024-07-07 20:43:1117 days ago1720384991
0xFe27534E...fEe71EEB0
0 ETH
202544532024-07-07 11:52:1117 days ago1720353131
0xFe27534E...fEe71EEB0
0 ETH
202514802024-07-07 1:53:3517 days ago1720317215
0xFe27534E...fEe71EEB0
0 ETH
202511512024-07-07 0:47:3517 days ago1720313255
0xFe27534E...fEe71EEB0
0 ETH
202419062024-07-05 17:49:5919 days ago1720201799
0xFe27534E...fEe71EEB0
0 ETH
202400962024-07-05 11:46:1119 days ago1720179971
0xFe27534E...fEe71EEB0
0 ETH
202393152024-07-05 9:09:2319 days ago1720170563
0xFe27534E...fEe71EEB0
0 ETH
202371362024-07-05 1:51:1119 days ago1720144271
0xFe27534E...fEe71EEB0
0 ETH
202330852024-07-04 12:15:1120 days ago1720095311
0xFe27534E...fEe71EEB0
0 ETH
202252872024-07-03 10:08:2321 days ago1720001303
0xFe27534E...fEe71EEB0
0 ETH
View All Internal Transactions
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
DFRewards

Compiler Version
v0.8.12+commit.f00d7308

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 9 : DFRewards.sol
// SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
pragma solidity 0.8.12;

//import "OpenZeppelin/[email protected]/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
//import "OpenZeppelin/[email protected]/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";

//import "OpenZeppelin/[email protected]/contracts/security/ReentrancyGuard.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
//import "OpenZeppelin/[email protected]/contracts/access/Ownable.sol";
import '@openzeppelin/contracts/access/Ownable.sol';
import "../interfaces/IDFRewards.sol";

contract DFRewards is Ownable, ReentrancyGuard, IDFRewards {
    using SafeERC20 for IERC20;

    // token address => user address => balance
    mapping(address => mapping(address => uint256)) balances;
    mapping(address => uint256) allocated;
    //mapping(address => bool) live_strategies;
    address[] public live_strategies;

    // Caller calls token.safeApprove(contract_addr, sum(values)),
    // then it calls this function. Anyone can call this, if can they fund it!
    function allocate(
        address[] calldata _tos,
        uint256[] calldata _values,
        address tokenAddress
    ) external returns (bool) {
        require(_tos.length == _values.length, "Lengths must match");

        uint256 total_value = 0.0;
        for (uint256 i = 0; i < _values.length; i += 1) {
            require(_tos[i] != address(0), "Address invalid");
            require(_values[i] > 0, "Value invalid");
            balances[tokenAddress][_tos[i]] += _values[i];
            total_value += _values[i];
        }

        uint256 _before = IERC20(tokenAddress).balanceOf(address(this));
        IERC20(tokenAddress).safeTransferFrom(
            msg.sender,
            address(this),
            total_value
        );
        uint256 _after = IERC20(tokenAddress).balanceOf(address(this));
        require(_after - _before == total_value, "Not enough tokens");

        allocated[tokenAddress] = allocated[tokenAddress] + total_value;

        emit Allocated(_tos, _values, tokenAddress);
        return true;
    }

    function claimable(address _to, address tokenAddress)
        public
        view
        returns (uint256)
    {
        return balances[tokenAddress][_to];
    }

    function _claim(
        address _to,
        address tokenAddress,
        address _receiver
    ) internal returns (uint256) {
        uint256 amt = balances[tokenAddress][_to];
        if (amt == 0) {
            return 0;
        }
        balances[tokenAddress][_to] = 0;
        IERC20(tokenAddress).safeTransfer(_receiver, amt);
        allocated[tokenAddress] = allocated[tokenAddress] - amt;
        emit Claimed(_to, amt, tokenAddress);
        return amt;
    }

    // Others claim on behalf of recipient
    function claimFor(address _to, address tokenAddress)
        public
        nonReentrant
        returns (uint256)
    {
        return _claim(_to, tokenAddress, _to);
    }

    // Strategies can claim on behalf of recipient
    function claimForStrat(address _to, address tokenAddress)
        public
        nonReentrant
        returns (uint256)
    {
        require(tx.origin == _to, "Caller doesn't match");
        require(isStrategy(msg.sender), "Caller must be a strategy");

        return _claim(_to, tokenAddress, msg.sender);
    }

    /*
     * @dev Withdraw any ERC20 token from the contract, cannot withdraw the allocated amount.
     * @param _amount The amount of tokens to withdraw.
     * @param _token The token address to withdraw.
     */
    function withdrawERCToken(uint256 amount, address _token)
        external
        onlyOwner
    {
        require(
            IERC20(_token).balanceOf(address(this)) - amount >=
                allocated[_token],
            "Cannot withdraw allocated token"
        );
        IERC20(_token).transfer(msg.sender, amount);
    }

    /**
     * @dev isStrategy
     *      Returns true if strategy exists in the list
     *  @param _strategy address Strategy address to be checked
     */
    function isStrategy(address _strategy) public view returns (bool) {
        for (uint256 i = 0; i < live_strategies.length; i++) {
            if (live_strategies[i] == _strategy) return true;
        }
        return false;
    }

    /**
     * @dev addStrategy
     *      Adds a new strategy
     *  @param _strategy address Strategy address to be added
     */
    function addStrategy(address _strategy) external onlyOwner {
        if (!isStrategy(_strategy)) {
            live_strategies.push(_strategy);
            emit StrategyAdded(_strategy);
        }
    }

    /**
     * @dev retireStrategy
     *      Removes an existng strategy
     *  @param _strategy address Strategy address to be removed
     */
    function retireStrategy(address _strategy) external onlyOwner {
        require(_strategy != address(0), "Invalid strategy address");
        uint256 i;
        for (i = 0; i < live_strategies.length; i++) {
            if (live_strategies[i] == _strategy) break;
        }
        if (i < live_strategies.length) {
            live_strategies[i] = live_strategies[live_strategies.length - 1];
            live_strategies.pop();
            emit StrategyRetired(_strategy);
        }
    }

    // Don't allow eth transfers
    fallback() external {
        revert("Invalid ether transfer");
    }
}

File 2 of 9 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

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

    /**
     * @dev 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 `to`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address to, 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 `from` to `to` 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 from,
        address to,
        uint256 amount
    ) external returns (bool);
}

File 3 of 9 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../extensions/draft-IERC20Permit.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 Address for address;

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

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

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

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

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

    function safePermit(
        IERC20Permit token,
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal {
        uint256 nonceBefore = token.nonces(owner);
        token.permit(owner, spender, value, deadline, v, r, s);
        uint256 nonceAfter = token.nonces(owner);
        require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed");
    }

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

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

File 4 of 9 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol)

pragma solidity ^0.8.0;

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

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

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

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

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

        _;

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

File 5 of 9 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/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.
 */
abstract contract Ownable is Context {
    address private _owner;

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

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

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

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

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        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 {
        _transferOwnership(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");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 6 of 9 : IDFRewards.sol
// SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
pragma solidity 0.8.12;

interface IDFRewards {
    event Allocated(address[] tos, uint256[] values, address tokenAddress);
    event Claimed(address to, uint256 value, address tokenAddress);
    event StrategyAdded(address strategy);
    event StrategyRetired(address strategy);

    function claimable(address _to, address tokenAddress)
        external
        view
        returns (uint256);

    function claimFor(address _to, address tokenAddress)
        external
        returns (uint256);

    function withdrawERCToken(uint256 amount, address _token) external;

    function claimForStrat(address _to, address tokenAddress)
        external
        returns (uint256);
}

File 7 of 9 : draft-IERC20Permit.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in
 * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612].
 *
 * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by
 * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't
 * need to send a transaction, and thus is not required to hold Ether at all.
 */
interface IERC20Permit {
    /**
     * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens,
     * given ``owner``'s signed approval.
     *
     * IMPORTANT: The same issues {IERC20-approve} has related to transaction
     * ordering also apply here.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     * - `deadline` must be a timestamp in the future.
     * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner`
     * over the EIP712-formatted function arguments.
     * - the signature must use ``owner``'s current nonce (see {nonces}).
     *
     * For more information on the signature format, see the
     * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP
     * section].
     */
    function permit(
        address owner,
        address spender,
        uint256 value,
        uint256 deadline,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) external;

    /**
     * @dev Returns the current nonce for `owner`. This value must be
     * included whenever a signature is generated for {permit}.
     *
     * Every successful call to {permit} increases ``owner``'s nonce by one. This
     * prevents a signature from being used multiple times.
     */
    function nonces(address owner) external view returns (uint256);

    /**
     * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}.
     */
    // solhint-disable-next-line func-name-mixedcase
    function DOMAIN_SEPARATOR() external view returns (bytes32);
}

File 8 of 9 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

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

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

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

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly
                /// @solidity memory-safe-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 9 of 9 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.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 meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

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

Contract Security Audit

Contract ABI

[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"tos","type":"address[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"},{"indexed":false,"internalType":"address","name":"tokenAddress","type":"address"}],"name":"Allocated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"},{"indexed":false,"internalType":"address","name":"tokenAddress","type":"address"}],"name":"Claimed","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":"address","name":"strategy","type":"address"}],"name":"StrategyAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"strategy","type":"address"}],"name":"StrategyRetired","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"addStrategy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"_tos","type":"address[]"},{"internalType":"uint256[]","name":"_values","type":"uint256[]"},{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"allocate","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"claimFor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"claimForStrat","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"address","name":"tokenAddress","type":"address"}],"name":"claimable","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"isStrategy","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"live_strategies","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_strategy","type":"address"}],"name":"retireStrategy","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"_token","type":"address"}],"name":"withdrawERCToken","outputs":[],"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b5061001a33610023565b60018055610073565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b61143c806100826000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c80638da5cb5b116100715780638da5cb5b14610186578063b4ba9e11146101ab578063b94b7a97146101be578063d4570c1c146101d1578063d731060c1461020b578063f2fde38b1461021e576100b4565b8063223e5479146100fa5780632c71df621461010f5780632e8ebaae1461013557806344469f9814610158578063691083631461016b578063715018a61461017e575b60405162461bcd60e51b815260206004820152601660248201527524b73b30b634b21032ba3432b9103a3930b739b332b960511b60448201526064015b60405180910390fd5b61010d6101083660046110d6565b610231565b005b61012261011d3660046110f1565b6102cb565b6040519081526020015b60405180910390f35b6101486101433660046110d6565b6103df565b604051901515815260200161012c565b610148610166366004611170565b610449565b61010d6101793660046110d6565b610804565b61010d6109b9565b6000546001600160a01b03165b6040516001600160a01b03909116815260200161012c565b6101226101b93660046110f1565b6109cd565b61010d6101cc3660046111f1565b610a32565b6101226101df3660046110f1565b6001600160a01b0380821660009081526002602090815260408083209386168352929052205492915050565b610193610219366004611214565b610b83565b61010d61022c3660046110d6565b610bad565b610239610c23565b610242816103df565b6102c857600480546001810182556000919091527f8a35acfbc15ff81a39ae7d344fd709f28e8600b4aa8c65c6b64bfe7fe36bd19b0180546001600160a01b0319166001600160a01b0383169081179091556040519081527f3f008fd510eae7a9e7bee13513d7b83bef8003d488b5a3d0b0da4de71d6846f19060200160405180910390a15b50565b6000600260015414156103205760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016100f1565b6002600155326001600160a01b038416146103745760405162461bcd60e51b8152602060048201526014602482015273086c2d8d8cae440c8decae6dc4ee840dac2e8c6d60631b60448201526064016100f1565b61037d336103df565b6103c95760405162461bcd60e51b815260206004820152601960248201527f43616c6c6572206d75737420626520612073747261746567790000000000000060448201526064016100f1565b6103d4838333610c7d565b600180559392505050565b6000805b60045481101561044057826001600160a01b03166004828154811061040a5761040a61122d565b6000918252602090912001546001600160a01b0316141561042e5750600192915050565b8061043881611259565b9150506103e3565b50600092915050565b600084831461048f5760405162461bcd60e51b8152602060048201526012602482015271098cadccee8d0e640daeae6e840dac2e8c6d60731b60448201526064016100f1565b6000805b848110156106395760008888838181106104af576104af61122d565b90506020020160208101906104c491906110d6565b6001600160a01b0316141561050d5760405162461bcd60e51b815260206004820152600f60248201526e1059191c995cdcc81a5b9d985b1a59608a1b60448201526064016100f1565b60008686838181106105215761052161122d565b90506020020135116105655760405162461bcd60e51b815260206004820152600d60248201526c15985b1d59481a5b9d985b1a59609a1b60448201526064016100f1565b8585828181106105775761057761122d565b9050602002013560026000866001600160a01b03166001600160a01b0316815260200190815260200160002060008a8a858181106105b7576105b761122d565b90506020020160208101906105cc91906110d6565b6001600160a01b03166001600160a01b0316815260200190815260200160002060008282546105fb9190611274565b9091555086905085828181106106135761061361122d565b90506020020135826106259190611274565b9150610632600182611274565b9050610493565b506040516370a0823160e01b81523060048201526000906001600160a01b038516906370a0823190602401602060405180830381865afa158015610681573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106a5919061128c565b90506106bc6001600160a01b038516333085610d76565b6040516370a0823160e01b81523060048201526000906001600160a01b038616906370a0823190602401602060405180830381865afa158015610703573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610727919061128c565b90508261073483836112a5565b146107755760405162461bcd60e51b81526020600482015260116024820152704e6f7420656e6f75676820746f6b656e7360781b60448201526064016100f1565b6001600160a01b038516600090815260036020526040902054610799908490611274565b6001600160a01b0386166000908152600360205260409081902091909155517fa6c91e0714fa5cea1a48a7903a4cb4fdfc6a5409b04c2f5e5f01140140846f74906107ed908b908b908b908b908b906112bc565b60405180910390a150600198975050505050505050565b61080c610c23565b6001600160a01b0381166108625760405162461bcd60e51b815260206004820152601860248201527f496e76616c69642073747261746567792061646472657373000000000000000060448201526064016100f1565b60005b6004548110156108be57816001600160a01b03166004828154811061088c5761088c61122d565b6000918252602090912001546001600160a01b031614156108ac576108be565b806108b681611259565b915050610865565b6004548110156109b557600480546108d8906001906112a5565b815481106108e8576108e861122d565b600091825260209091200154600480546001600160a01b0390921691839081106109145761091461122d565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600480548061095357610953611353565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03841681527f43328b6eb7f0f6711a295cfc22368af8227bf60b67a6f6a5454f6168726d3e25910160405180910390a15b5050565b6109c1610c23565b6109cb6000610de7565b565b600060026001541415610a225760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016100f1565b60026001556103d4838381610c7d565b610a3a610c23565b6001600160a01b038116600081815260036020526040908190205490516370a0823160e01b8152306004820152909184916370a0823190602401602060405180830381865afa158015610a91573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ab5919061128c565b610abf91906112a5565b1015610b0d5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f7420776974686472617720616c6c6f636174656420746f6b656e0060448201526064016100f1565b60405163a9059cbb60e01b8152336004820152602481018390526001600160a01b0382169063a9059cbb906044016020604051808303816000875af1158015610b5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b7e9190611369565b505050565b60048181548110610b9357600080fd5b6000918252602090912001546001600160a01b0316905081565b610bb5610c23565b6001600160a01b038116610c1a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016100f1565b6102c881610de7565b6000546001600160a01b031633146109cb5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016100f1565b6001600160a01b03808316600090815260026020908152604080832093871683529290529081205480610cb4576000915050610d6f565b6001600160a01b038085166000818152600260209081526040808320948a16835293905291822091909155610cea908483610e37565b6001600160a01b038416600090815260036020526040902054610d0e9082906112a5565b6001600160a01b0385811660008181526003602090815260409182902094909455805192891683529282018490528183015290517f7e6632ca16a0ac6cf28448500b1a17d96c8b8163ad4c4a9b44ef5386cc02779e9181900360600190a190505b9392505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610de19085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610e67565b50505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6040516001600160a01b038316602482015260448101829052610b7e90849063a9059cbb60e01b90606401610daa565b6000610ebc826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610f399092919063ffffffff16565b805190915015610b7e5780806020019051810190610eda9190611369565b610b7e5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016100f1565b6060610f488484600085610f50565b949350505050565b606082471015610fb15760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016100f1565b6001600160a01b0385163b6110085760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016100f1565b600080866001600160a01b0316858760405161102491906113b7565b60006040518083038185875af1925050503d8060008114611061576040519150601f19603f3d011682016040523d82523d6000602084013e611066565b606091505b5091509150611076828286611081565b979650505050505050565b60608315611090575081610d6f565b8251156110a05782518084602001fd5b8160405162461bcd60e51b81526004016100f191906113d3565b80356001600160a01b03811681146110d157600080fd5b919050565b6000602082840312156110e857600080fd5b610d6f826110ba565b6000806040838503121561110457600080fd5b61110d836110ba565b915061111b602084016110ba565b90509250929050565b60008083601f84011261113657600080fd5b50813567ffffffffffffffff81111561114e57600080fd5b6020830191508360208260051b850101111561116957600080fd5b9250929050565b60008060008060006060868803121561118857600080fd5b853567ffffffffffffffff808211156111a057600080fd5b6111ac89838a01611124565b909750955060208801359150808211156111c557600080fd5b506111d288828901611124565b90945092506111e59050604087016110ba565b90509295509295909350565b6000806040838503121561120457600080fd5b8235915061111b602084016110ba565b60006020828403121561122657600080fd5b5035919050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561126d5761126d611243565b5060010190565b6000821982111561128757611287611243565b500190565b60006020828403121561129e57600080fd5b5051919050565b6000828210156112b7576112b7611243565b500390565b6060808252810185905260008660808301825b888110156112fd576001600160a01b036112e8846110ba565b168252602092830192909101906001016112cf565b5083810360208501528581526001600160fb1b0386111561131d57600080fd5b8560051b915081876020830137600091016020019081526001600160a01b03939093166040929092019190915250949350505050565b634e487b7160e01b600052603160045260246000fd5b60006020828403121561137b57600080fd5b81518015158114610d6f57600080fd5b60005b838110156113a657818101518382015260200161138e565b83811115610de15750506000910152565b600082516113c981846020870161138b565b9190910192915050565b60208152600082518060208401526113f281604085016020870161138b565b601f01601f1916919091016040019291505056fea26469706673582212203c781b135c8f41f0cdf7a39a7cff978fcb289db8e5010a17187b2c0a72ba28dd64736f6c634300080c0033

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100b45760003560e01c80638da5cb5b116100715780638da5cb5b14610186578063b4ba9e11146101ab578063b94b7a97146101be578063d4570c1c146101d1578063d731060c1461020b578063f2fde38b1461021e576100b4565b8063223e5479146100fa5780632c71df621461010f5780632e8ebaae1461013557806344469f9814610158578063691083631461016b578063715018a61461017e575b60405162461bcd60e51b815260206004820152601660248201527524b73b30b634b21032ba3432b9103a3930b739b332b960511b60448201526064015b60405180910390fd5b61010d6101083660046110d6565b610231565b005b61012261011d3660046110f1565b6102cb565b6040519081526020015b60405180910390f35b6101486101433660046110d6565b6103df565b604051901515815260200161012c565b610148610166366004611170565b610449565b61010d6101793660046110d6565b610804565b61010d6109b9565b6000546001600160a01b03165b6040516001600160a01b03909116815260200161012c565b6101226101b93660046110f1565b6109cd565b61010d6101cc3660046111f1565b610a32565b6101226101df3660046110f1565b6001600160a01b0380821660009081526002602090815260408083209386168352929052205492915050565b610193610219366004611214565b610b83565b61010d61022c3660046110d6565b610bad565b610239610c23565b610242816103df565b6102c857600480546001810182556000919091527f8a35acfbc15ff81a39ae7d344fd709f28e8600b4aa8c65c6b64bfe7fe36bd19b0180546001600160a01b0319166001600160a01b0383169081179091556040519081527f3f008fd510eae7a9e7bee13513d7b83bef8003d488b5a3d0b0da4de71d6846f19060200160405180910390a15b50565b6000600260015414156103205760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016100f1565b6002600155326001600160a01b038416146103745760405162461bcd60e51b8152602060048201526014602482015273086c2d8d8cae440c8decae6dc4ee840dac2e8c6d60631b60448201526064016100f1565b61037d336103df565b6103c95760405162461bcd60e51b815260206004820152601960248201527f43616c6c6572206d75737420626520612073747261746567790000000000000060448201526064016100f1565b6103d4838333610c7d565b600180559392505050565b6000805b60045481101561044057826001600160a01b03166004828154811061040a5761040a61122d565b6000918252602090912001546001600160a01b0316141561042e5750600192915050565b8061043881611259565b9150506103e3565b50600092915050565b600084831461048f5760405162461bcd60e51b8152602060048201526012602482015271098cadccee8d0e640daeae6e840dac2e8c6d60731b60448201526064016100f1565b6000805b848110156106395760008888838181106104af576104af61122d565b90506020020160208101906104c491906110d6565b6001600160a01b0316141561050d5760405162461bcd60e51b815260206004820152600f60248201526e1059191c995cdcc81a5b9d985b1a59608a1b60448201526064016100f1565b60008686838181106105215761052161122d565b90506020020135116105655760405162461bcd60e51b815260206004820152600d60248201526c15985b1d59481a5b9d985b1a59609a1b60448201526064016100f1565b8585828181106105775761057761122d565b9050602002013560026000866001600160a01b03166001600160a01b0316815260200190815260200160002060008a8a858181106105b7576105b761122d565b90506020020160208101906105cc91906110d6565b6001600160a01b03166001600160a01b0316815260200190815260200160002060008282546105fb9190611274565b9091555086905085828181106106135761061361122d565b90506020020135826106259190611274565b9150610632600182611274565b9050610493565b506040516370a0823160e01b81523060048201526000906001600160a01b038516906370a0823190602401602060405180830381865afa158015610681573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106a5919061128c565b90506106bc6001600160a01b038516333085610d76565b6040516370a0823160e01b81523060048201526000906001600160a01b038616906370a0823190602401602060405180830381865afa158015610703573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610727919061128c565b90508261073483836112a5565b146107755760405162461bcd60e51b81526020600482015260116024820152704e6f7420656e6f75676820746f6b656e7360781b60448201526064016100f1565b6001600160a01b038516600090815260036020526040902054610799908490611274565b6001600160a01b0386166000908152600360205260409081902091909155517fa6c91e0714fa5cea1a48a7903a4cb4fdfc6a5409b04c2f5e5f01140140846f74906107ed908b908b908b908b908b906112bc565b60405180910390a150600198975050505050505050565b61080c610c23565b6001600160a01b0381166108625760405162461bcd60e51b815260206004820152601860248201527f496e76616c69642073747261746567792061646472657373000000000000000060448201526064016100f1565b60005b6004548110156108be57816001600160a01b03166004828154811061088c5761088c61122d565b6000918252602090912001546001600160a01b031614156108ac576108be565b806108b681611259565b915050610865565b6004548110156109b557600480546108d8906001906112a5565b815481106108e8576108e861122d565b600091825260209091200154600480546001600160a01b0390921691839081106109145761091461122d565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600480548061095357610953611353565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03841681527f43328b6eb7f0f6711a295cfc22368af8227bf60b67a6f6a5454f6168726d3e25910160405180910390a15b5050565b6109c1610c23565b6109cb6000610de7565b565b600060026001541415610a225760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016100f1565b60026001556103d4838381610c7d565b610a3a610c23565b6001600160a01b038116600081815260036020526040908190205490516370a0823160e01b8152306004820152909184916370a0823190602401602060405180830381865afa158015610a91573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ab5919061128c565b610abf91906112a5565b1015610b0d5760405162461bcd60e51b815260206004820152601f60248201527f43616e6e6f7420776974686472617720616c6c6f636174656420746f6b656e0060448201526064016100f1565b60405163a9059cbb60e01b8152336004820152602481018390526001600160a01b0382169063a9059cbb906044016020604051808303816000875af1158015610b5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b7e9190611369565b505050565b60048181548110610b9357600080fd5b6000918252602090912001546001600160a01b0316905081565b610bb5610c23565b6001600160a01b038116610c1a5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016100f1565b6102c881610de7565b6000546001600160a01b031633146109cb5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016100f1565b6001600160a01b03808316600090815260026020908152604080832093871683529290529081205480610cb4576000915050610d6f565b6001600160a01b038085166000818152600260209081526040808320948a16835293905291822091909155610cea908483610e37565b6001600160a01b038416600090815260036020526040902054610d0e9082906112a5565b6001600160a01b0385811660008181526003602090815260409182902094909455805192891683529282018490528183015290517f7e6632ca16a0ac6cf28448500b1a17d96c8b8163ad4c4a9b44ef5386cc02779e9181900360600190a190505b9392505050565b6040516001600160a01b0380851660248301528316604482015260648101829052610de19085906323b872dd60e01b906084015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b031990931692909217909152610e67565b50505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6040516001600160a01b038316602482015260448101829052610b7e90849063a9059cbb60e01b90606401610daa565b6000610ebc826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b0316610f399092919063ffffffff16565b805190915015610b7e5780806020019051810190610eda9190611369565b610b7e5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016100f1565b6060610f488484600085610f50565b949350505050565b606082471015610fb15760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016100f1565b6001600160a01b0385163b6110085760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016100f1565b600080866001600160a01b0316858760405161102491906113b7565b60006040518083038185875af1925050503d8060008114611061576040519150601f19603f3d011682016040523d82523d6000602084013e611066565b606091505b5091509150611076828286611081565b979650505050505050565b60608315611090575081610d6f565b8251156110a05782518084602001fd5b8160405162461bcd60e51b81526004016100f191906113d3565b80356001600160a01b03811681146110d157600080fd5b919050565b6000602082840312156110e857600080fd5b610d6f826110ba565b6000806040838503121561110457600080fd5b61110d836110ba565b915061111b602084016110ba565b90509250929050565b60008083601f84011261113657600080fd5b50813567ffffffffffffffff81111561114e57600080fd5b6020830191508360208260051b850101111561116957600080fd5b9250929050565b60008060008060006060868803121561118857600080fd5b853567ffffffffffffffff808211156111a057600080fd5b6111ac89838a01611124565b909750955060208801359150808211156111c557600080fd5b506111d288828901611124565b90945092506111e59050604087016110ba565b90509295509295909350565b6000806040838503121561120457600080fd5b8235915061111b602084016110ba565b60006020828403121561122657600080fd5b5035919050565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b600060001982141561126d5761126d611243565b5060010190565b6000821982111561128757611287611243565b500190565b60006020828403121561129e57600080fd5b5051919050565b6000828210156112b7576112b7611243565b500390565b6060808252810185905260008660808301825b888110156112fd576001600160a01b036112e8846110ba565b168252602092830192909101906001016112cf565b5083810360208501528581526001600160fb1b0386111561131d57600080fd5b8560051b915081876020830137600091016020019081526001600160a01b03939093166040929092019190915250949350505050565b634e487b7160e01b600052603160045260246000fd5b60006020828403121561137b57600080fd5b81518015158114610d6f57600080fd5b60005b838110156113a657818101518382015260200161138e565b83811115610de15750506000910152565b600082516113c981846020870161138b565b9190910192915050565b60208152600082518060208401526113f281604085016020870161138b565b601f01601f1916919091016040019291505056fea26469706673582212203c781b135c8f41f0cdf7a39a7cff978fcb289db8e5010a17187b2c0a72ba28dd64736f6c634300080c0033

Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

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

Validator Index Block Amount
View All Withdrawals

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

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