Contract 0x97e2768e8e73511ca874545dc5ff8067eb19b787 3

 
Txn Hash Method
Block
From
To
Value [Txn Fee]
0xf858305030083ffa6e4b0b0095f6680e77300d0b24910181ba50015fc0b2d2a5Claim_rewards47330052022-01-17 15:38:4936 mins ago0xfdbbfb0fe2986672af97eca0e797d76a0bbf35c9 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000977410127 ETH
0x00b789b8fb5a5f119ad7a3405b8406eee38f19eba920fef2a9587ba8e7f65711Deposit47316902022-01-17 14:47:501 hr 27 mins ago0xdc54c3e53f35f50b22164c0e71d060fb54d3f712 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000833147078 ETH
0x75b3c1cf7f5f16d327f05022bed7073af92ac51b2f51b37bacd7bf71f5d6caf7Deposit47314162022-01-17 14:30:551 hr 44 mins ago0x80281d33b56231ea95a5b8f61cfd91ca052c7b5a IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000831804028 ETH
0x9003c51e9b15895b077b6104c0b8ace51d458332353279c1722cefdbfa780882Deposit47313732022-01-17 14:28:401 hr 46 mins ago0xdc54c3e53f35f50b22164c0e71d060fb54d3f712 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000841292623 ETH
0x20ab4363ecd926a4eaf20c81955e344b4b5b7ad3aaf0e18f6c6d31fba5fbabe7Claim_rewards47311942022-01-17 14:18:341 hr 56 mins ago0x3e811a37478d3476c2e47bb95be318aabd5cb3d6 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000979897137 ETH
0xae8a5f41183ff9647e5ee1d0af5219645793592b009242ca383aaba27c8c4555Withdraw47311342022-01-17 14:15:391 hr 59 mins ago0x3e811a37478d3476c2e47bb95be318aabd5cb3d6 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001079190704 ETH
0x32846ec1ed37e6ca92038389da0342016fb18bac3c7b53334444e45a4eeb7bf7Deposit47299822022-01-17 13:22:012 hrs 53 mins ago0x80281d33b56231ea95a5b8f61cfd91ca052c7b5a IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000856486659 ETH
0x926a630f33984995719a8ae39460e5c091f1a316d29e01cf7ec823e4e0947de1Deposit47293872022-01-17 12:54:423 hrs 20 mins ago0xffa4dde9632d0985e967afed28240af0b137c4a9 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000971791624 ETH
0xb42befad849cca645cfcdc3d681df283d75183c2cd1034a121a3ed618979976eWithdraw47285452022-01-17 12:16:513 hrs 58 mins ago0xc97acf688cfe0a4d3bf23e9f772af83698216470 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000981412568 ETH
0xe9c8cef04b26b3774e6c73e95a2d7f2f91fc0b103853e260fea9f5c736db568bDeposit47216972022-01-17 6:06:2610 hrs 8 mins ago0x8f5b33b2a514c63f87fb754697c0d76914339a49 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000926154254 ETH
0x1473a16b231eccf385b7c0c52dfe3cba2474e4461a87915979696993a479d564Claim_rewards47216322022-01-17 6:04:2210 hrs 11 mins ago0x7c132bde28ad1e0101d45121757d7c6c2e8a550a IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001092359035 ETH
0x55f67c2a1f747da4e21153eff6529118c7bc5f46b555f2551aeee1fc6006b60dClaim_rewards47212102022-01-17 5:44:2410 hrs 30 mins ago0x8f5b33b2a514c63f87fb754697c0d76914339a49 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001094090364 ETH
0x7cd5ded4b64db122ab203b5b91916b744c63c672d7b746c5f9fbd13b78a42529Withdraw47209522022-01-17 5:28:5610 hrs 46 mins ago0x9a40856b23dc58309e8ce3417bd166875b967fc2 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000904839832 ETH
0x59ebda748f58af19085981dc4d7bda875e98041b8179def1046919930e51427aWithdraw47209112022-01-17 5:27:4510 hrs 47 mins ago0x9a40856b23dc58309e8ce3417bd166875b967fc2 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.0010590112 ETH
0x5f65931696d0c7c26d2532b577e4abc56a64c8d1364b56345604e065da15f5c0Claim_rewards47207052022-01-17 5:18:4910 hrs 56 mins ago0xe6156d93fba1f2387fce5f50f1bb45ef51ed5f2b IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001087346363 ETH
0xc55a829d728e7cf61198a6c2037f38144653c784791ec984e9b603c253db4c43Claim_rewards47196752022-01-17 4:36:1211 hrs 39 mins ago0xd66ba9b7d332ed5f399ca907bab7686292b14cdf IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000962304054 ETH
0x5a0c940b6ff79fe45c60ab21daac85b902fe8f8257a7c49081a5dd3acd68afaeWithdraw47195382022-01-17 4:30:0511 hrs 45 mins ago0xd66ba9b7d332ed5f399ca907bab7686292b14cdf IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.00108786712 ETH
0xb96a6177a9093e3a09cdc158af3e294878606a7dab14ecda1011600631c2342bClaim_rewards47191672022-01-17 4:12:3112 hrs 2 mins ago0x8f423720584b0eff220c8ff0b62700917089be22 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001094867526 ETH
0x2dffd749e6f54f7743dd80af47209f7ea3e160390daac8de28633e334f104f9aWithdraw47173522022-01-17 3:13:1213 hrs 2 mins ago0x8f423720584b0eff220c8ff0b62700917089be22 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001194973507 ETH
0x53ac2a64733b0d9a46d16b3945d8e89ddd45c3053854dcd0bf9fb6a47cea9883Claim_rewards47154002022-01-17 1:52:2614 hrs 22 mins ago0xc4b7bedce1e0face52a465d0d9af4a978bca303b IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000965355157 ETH
0x56e1cb64df2e8ffd2c9d5bdd8ba2b125609e4ae9624aa2151dae87e35e4f479dDeposit47134372022-01-17 0:12:2016 hrs 3 mins ago0xc6f0e9eefcf3bf41ce33d8352d3aba578e4de4ce IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000932297092 ETH
0x6bf3dc8ec521a293816865f5335320916a8c9205c7f18e9ea793de49f1c9ed01Claim_rewards47123202022-01-16 23:27:2016 hrs 48 mins ago0xc6f0e9eefcf3bf41ce33d8352d3aba578e4de4ce IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.000955172186 ETH
0x6d80d3460fef2e66f6e02c15975aac57d761e418cd6d9f85eefed6b6977dc319Claim_rewards47116762022-01-16 23:01:0917 hrs 14 mins ago0xebeea1bc1d8d1a0c59a14917701175900b71b34a IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001092008763 ETH
0xe01322c9fa7e93cce32d9f600b6fb9762eeb293e0ade458ddf2ca724e221f7e1Withdraw47116312022-01-16 22:59:2217 hrs 16 mins ago0xebeea1bc1d8d1a0c59a14917701175900b71b34a IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001076246629 ETH
0xc372e330902b0b23337488fcc5c897562f6d521030eafe9f39ffaaa265bcdc14Claim_rewards47108592022-01-16 22:22:3717 hrs 52 mins ago0xe93e68be1dae4aa652ee4d7cac0ba1a568af9811 IN  0x97e2768e8e73511ca874545dc5ff8067eb19b7870 ETH0.001088429385 ETH
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Similar Match Source Code
Note: This contract matches the deployed ByteCode of the Source Code for Contract 0xbf7e49483881c76487b0989cd7d9a8239b20ca41

Contract Name:
Vyper_contract

Compiler Version
vyper:0.2.12

Optimization Enabled:
N/A

Other Settings:
, MIT license

Contract Source Code (Vyper language format)

# @version 0.2.12
"""
@title Rewards-Only Gauge
@author Curve Finance
@license MIT
@notice Distribution of third-party rewards without CRV
"""

from vyper.interfaces import ERC20

implements: ERC20


interface ERC20Extended:
    def symbol() -> String[26]: view


event Deposit:
    provider: indexed(address)
    value: uint256

event Withdraw:
    provider: indexed(address)
    value: uint256

event CommitOwnership:
    admin: address

event ApplyOwnership:
    admin: address

event Transfer:
    _from: indexed(address)
    _to: indexed(address)
    _value: uint256

event Approval:
    _owner: indexed(address)
    _spender: indexed(address)
    _value: uint256

MAX_REWARDS: constant(uint256) = 8
CLAIM_FREQUENCY: constant(uint256) = 3600

lp_token: public(address)

balanceOf: public(HashMap[address, uint256])
totalSupply: public(uint256)
allowance: public(HashMap[address, HashMap[address, uint256]])

name: public(String[64])
symbol: public(String[32])

# For tracking external rewards
reward_data: uint256
reward_tokens: public(address[MAX_REWARDS])
reward_balances: public(HashMap[address, uint256])
# claimant -> default reward receiver
rewards_receiver: public(HashMap[address, address])

claim_sig: public(Bytes[4])

# reward token -> integral
reward_integral: public(HashMap[address, uint256])

# reward token -> claiming address -> integral
reward_integral_for: public(HashMap[address, HashMap[address, uint256]])

# user -> [uint128 claimable amount][uint128 claimed amount]
claim_data: HashMap[address, HashMap[address, uint256]]

admin: public(address)
future_admin: public(address)  # Can and will be a smart contract


@external
def __init__( _admin: address, _lp_token: address):
    """
    @notice Contract constructor
    @param _admin Admin who can kill the gauge
    @param _lp_token Liquidity Pool contract address
    """

    symbol: String[26] = ERC20Extended(_lp_token).symbol()
    self.name = concat("Curve.fi ", symbol, " RewardGauge Deposit")
    self.symbol = concat(symbol, "-gauge")

    self.lp_token = _lp_token
    self.admin = _admin


@view
@external
def decimals() -> uint256:
    """
    @notice Get the number of decimals for this token
    @dev Implemented as a view method to reduce gas costs
    @return uint256 decimal places
    """
    return 18


@internal
def _checkpoint_rewards(_user: address, _total_supply: uint256, _claim: bool, _receiver: address):
    """
    @notice Claim pending rewards and checkpoint rewards for a user
    """
    # claim from reward contract

    reward_data: uint256 = self.reward_data
    if _total_supply != 0 and reward_data != 0 and block.timestamp > shift(reward_data, -160) + CLAIM_FREQUENCY:
        reward_contract: address = convert(reward_data % 2**160, address)
        raw_call(reward_contract, self.claim_sig)  # dev: bad claim sig
        self.reward_data = convert(reward_contract, uint256) + shift(block.timestamp, 160)

    receiver: address = _receiver
    if _claim and receiver == ZERO_ADDRESS:
        # if receiver is not explicitly declared, check for default receiver
        receiver = self.rewards_receiver[_user]
        if receiver == ZERO_ADDRESS:
            # direct claims to user if no default receiver is set
            receiver = _user

    # calculate new user reward integral and transfer any owed rewards
    user_balance: uint256 = self.balanceOf[_user]
    for i in range(MAX_REWARDS):
        token: address = self.reward_tokens[i]
        if token == ZERO_ADDRESS:
            break
        dI: uint256 = 0
        if _total_supply != 0:
            token_balance: uint256 = ERC20(token).balanceOf(self)
            dI = 10**18 * (token_balance - self.reward_balances[token]) / _total_supply
            self.reward_balances[token] = token_balance
            if _user == ZERO_ADDRESS:
                if dI != 0:
                    self.reward_integral[token] += dI
                continue

        integral: uint256 = self.reward_integral[token] + dI
        if dI != 0:
            self.reward_integral[token] = integral

        integral_for: uint256 = self.reward_integral_for[token][_user]
        new_claimable: uint256 = 0
        if integral_for < integral:
            self.reward_integral_for[token][_user] = integral
            new_claimable = user_balance * (integral - integral_for) / 10**18

        claim_data: uint256 = self.claim_data[_user][token]
        total_claimable: uint256 = shift(claim_data, -128) + new_claimable
        if total_claimable > 0:
            total_claimed: uint256 = claim_data % 2 ** 128
            if _claim:
                response: Bytes[32] = raw_call(
                    token,
                    concat(
                        method_id("transfer(address,uint256)"),
                        convert(receiver, bytes32),
                        convert(total_claimable, bytes32),
                    ),
                    max_outsize=32,
                )
                if len(response) != 0:
                    assert convert(response, bool)
                self.reward_balances[token] -= total_claimable
                # update amount claimed (lower order bytes)
                self.claim_data[_user][token] = total_claimed + total_claimable
            elif new_claimable > 0:
                # update total_claimable (higher order bytes)
                self.claim_data[_user][token] = total_claimed + shift(total_claimable, 128)


@view
@external
def reward_contract() -> address:
    """
    @notice Address of the reward contract providing non-CRV incentives for this gauge
    @dev Returns `ZERO_ADDRESS` if there is no reward contract active
    """
    return convert(self.reward_data % 2**160, address)


@view
@external
def last_claim() -> uint256:
    """
    @notice Epoch timestamp of the last call to claim from `reward_contract`
    @dev Rewards are claimed at most once per hour in order to reduce gas costs
    """
    return shift(self.reward_data, -160)


@view
@external
def claimed_reward(_addr: address, _token: address) -> uint256:
    """
    @notice Get the number of already-claimed reward tokens for a user
    @param _addr Account to get reward amount for
    @param _token Token to get reward amount for
    @return uint256 Total amount of `_token` already claimed by `_addr`
    """
    return self.claim_data[_addr][_token] % 2**128


@view
@external
def claimable_reward(_addr: address, _token: address) -> uint256:
    """
    @notice Get the number of claimable reward tokens for a user
    @dev This call does not consider pending claimable amount in `reward_contract`.
         Off-chain callers should instead use `claimable_rewards_write` as a
         view method.
    @param _addr Account to get reward amount for
    @param _token Token to get reward amount for
    @return uint256 Claimable reward token amount
    """
    return shift(self.claim_data[_addr][_token], -128)


@external
@nonreentrant('lock')
def claimable_reward_write(_addr: address, _token: address) -> uint256:
    """
    @notice Get the number of claimable reward tokens for a user
    @dev This function should be manually changed to "view" in the ABI
         Calling it via a transaction will claim available reward tokens
    @param _addr Account to get reward amount for
    @param _token Token to get reward amount for
    @return uint256 Claimable reward token amount
    """
    if self.reward_tokens[0] != ZERO_ADDRESS:
        self._checkpoint_rewards(_addr, self.totalSupply, False, ZERO_ADDRESS)
    return shift(self.claim_data[_addr][_token], -128)


@external
def set_rewards_receiver(_receiver: address):
    """
    @notice Set the default reward receiver for the caller.
    @dev When set to ZERO_ADDRESS, rewards are sent to the caller
    @param _receiver Receiver address for any rewards claimed via `claim_rewards`
    """
    self.rewards_receiver[msg.sender] = _receiver


@external
@nonreentrant('lock')
def claim_rewards(_addr: address = msg.sender, _receiver: address = ZERO_ADDRESS):
    """
    @notice Claim available reward tokens for `_addr`
    @param _addr Address to claim for
    @param _receiver Address to transfer rewards to - if set to
                     ZERO_ADDRESS, uses the default reward receiver
                     for the caller
    """
    if _receiver != ZERO_ADDRESS:
        assert _addr == msg.sender  # dev: cannot redirect when claiming for another user
    self._checkpoint_rewards(_addr, self.totalSupply, True, _receiver)


@external
@nonreentrant('lock')
def deposit(_value: uint256, _addr: address = msg.sender, _claim_rewards: bool = False):
    """
    @notice Deposit `_value` LP tokens
    @dev Depositting also claims pending reward tokens
    @param _value Number of tokens to deposit
    @param _addr Address to deposit for
    """
    if _value != 0:
        reward_contract: address = convert(self.reward_data % 2**160, address)
        total_supply: uint256 = self.totalSupply

        self._checkpoint_rewards(_addr, total_supply, _claim_rewards, ZERO_ADDRESS)

        total_supply += _value
        new_balance: uint256 = self.balanceOf[_addr] + _value
        self.balanceOf[_addr] = new_balance
        self.totalSupply = total_supply

        ERC20(self.lp_token).transferFrom(msg.sender, self, _value)

    log Deposit(_addr, _value)
    log Transfer(ZERO_ADDRESS, _addr, _value)


@external
@nonreentrant('lock')
def withdraw(_value: uint256, _claim_rewards: bool = False):
    """
    @notice Withdraw `_value` LP tokens
    @dev Withdrawing also claims pending reward tokens
    @param _value Number of tokens to withdraw
    """
    if _value != 0:
        reward_contract: address = convert(self.reward_data % 2**160, address)
        total_supply: uint256 = self.totalSupply

        self._checkpoint_rewards(msg.sender, total_supply, _claim_rewards, ZERO_ADDRESS)

        total_supply -= _value
        new_balance: uint256 = self.balanceOf[msg.sender] - _value
        self.balanceOf[msg.sender] = new_balance
        self.totalSupply = total_supply

        ERC20(self.lp_token).transfer(msg.sender, _value)

    log Withdraw(msg.sender, _value)
    log Transfer(msg.sender, ZERO_ADDRESS, _value)


@internal
def _transfer(_from: address, _to: address, _value: uint256):
    reward_contract: address = convert(self.reward_data % 2**160, address)

    if _value != 0:
        total_supply: uint256 = self.totalSupply
        self._checkpoint_rewards(_from, total_supply, False, ZERO_ADDRESS)
        new_balance: uint256 = self.balanceOf[_from] - _value
        self.balanceOf[_from] = new_balance

        self._checkpoint_rewards(_to, total_supply, False, ZERO_ADDRESS)
        new_balance = self.balanceOf[_to] + _value
        self.balanceOf[_to] = new_balance

    log Transfer(_from, _to, _value)


@external
@nonreentrant('lock')
def transfer(_to : address, _value : uint256) -> bool:
    """
    @notice Transfer token for a specified address
    @dev Transferring claims pending reward tokens for the sender and receiver
    @param _to The address to transfer to.
    @param _value The amount to be transferred.
    """
    self._transfer(msg.sender, _to, _value)

    return True


@external
@nonreentrant('lock')
def transferFrom(_from : address, _to : address, _value : uint256) -> bool:
    """
    @notice Transfer tokens from one address to another.
    @dev Transferring claims pending reward tokens for the sender and receiver
    @param _from address The address which you want to send tokens from
    @param _to address The address which you want to transfer to
    @param _value uint256 the amount of tokens to be transferred
    """
    _allowance: uint256 = self.allowance[_from][msg.sender]
    if _allowance != MAX_UINT256:
        self.allowance[_from][msg.sender] = _allowance - _value

    self._transfer(_from, _to, _value)

    return True


@external
def approve(_spender : address, _value : uint256) -> bool:
    """
    @notice Approve the passed address to transfer the specified amount of
            tokens on behalf of msg.sender
    @dev Beware that changing an allowance via this method brings the risk
         that someone may use both the old and new allowance by unfortunate
         transaction ordering. This may be mitigated with the use of
         {incraseAllowance} and {decreaseAllowance}.
         https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
    @param _spender The address which will transfer the funds
    @param _value The amount of tokens that may be transferred
    @return bool success
    """
    self.allowance[msg.sender][_spender] = _value
    log Approval(msg.sender, _spender, _value)

    return True


@external
def increaseAllowance(_spender: address, _added_value: uint256) -> bool:
    """
    @notice Increase the allowance granted to `_spender` by the caller
    @dev This is alternative to {approve} that can be used as a mitigation for
         the potential race condition
    @param _spender The address which will transfer the funds
    @param _added_value The amount of to increase the allowance
    @return bool success
    """
    allowance: uint256 = self.allowance[msg.sender][_spender] + _added_value
    self.allowance[msg.sender][_spender] = allowance

    log Approval(msg.sender, _spender, allowance)

    return True


@external
def decreaseAllowance(_spender: address, _subtracted_value: uint256) -> bool:
    """
    @notice Decrease the allowance granted to `_spender` by the caller
    @dev This is alternative to {approve} that can be used as a mitigation for
         the potential race condition
    @param _spender The address which will transfer the funds
    @param _subtracted_value The amount of to decrease the allowance
    @return bool success
    """
    allowance: uint256 = self.allowance[msg.sender][_spender] - _subtracted_value
    self.allowance[msg.sender][_spender] = allowance

    log Approval(msg.sender, _spender, allowance)

    return True


@external
@nonreentrant('lock')
def set_rewards(_reward_contract: address, _claim_sig: bytes32, _reward_tokens: address[MAX_REWARDS]):
    """
    @notice Set the active reward contract
    @dev A reward contract cannot be set while this contract has no deposits
    @param _reward_contract Reward contract address. Set to ZERO_ADDRESS to
                            disable staking.
    @param _claim_sig Four byte selectors for staking, withdrawing and claiming,
                 left padded with zero bytes. If the reward contract can
                 be claimed from but does not require staking, the staking
                 and withdraw selectors should be set to 0x00
    @param _reward_tokens List of claimable reward tokens. New reward tokens
                          may be added but they cannot be removed. When calling
                          this function to unset or modify a reward contract,
                          this array must begin with the already-set reward
                          token addresses.
    """
    assert msg.sender == self.admin

    lp_token: address = self.lp_token
    current_reward_contract: address = convert(self.reward_data % 2**160, address)
    total_supply: uint256 = self.totalSupply
    self._checkpoint_rewards(ZERO_ADDRESS, total_supply, False, ZERO_ADDRESS)

    if _reward_contract != ZERO_ADDRESS:
        assert _reward_tokens[0] != ZERO_ADDRESS  # dev: no reward token
        assert _reward_contract.is_contract  # dev: not a contract

    self.reward_data = convert(_reward_contract, uint256)
    self.claim_sig = slice(_claim_sig, 28, 4)
    for i in range(MAX_REWARDS):
        current_token: address = self.reward_tokens[i]
        new_token: address = _reward_tokens[i]
        if current_token != ZERO_ADDRESS:
            assert current_token == new_token  # dev: cannot modify existing reward token
        elif new_token != ZERO_ADDRESS:
            self.reward_tokens[i] = new_token
        else:
            break

    if _reward_contract != ZERO_ADDRESS:
        # do an initial checkpoint to verify that claims are working
        self._checkpoint_rewards(ZERO_ADDRESS, total_supply, False, ZERO_ADDRESS)


@external
def commit_transfer_ownership(addr: address):
    """
    @notice Transfer ownership of GaugeController to `addr`
    @param addr Address to have ownership transferred to
    """
    assert msg.sender == self.admin  # dev: admin only

    self.future_admin = addr
    log CommitOwnership(addr)


@external
def accept_transfer_ownership():
    """
    @notice Accept a pending ownership transfer
    """
    _admin: address = self.future_admin
    assert msg.sender == _admin  # dev: future admin only

    self.admin = _admin
    log ApplyOwnership(_admin)

Contract ABI

[{"name":"Deposit","inputs":[{"name":"provider","type":"address","indexed":true},{"name":"value","type":"uint256","indexed":false}],"anonymous":false,"type":"event"},{"name":"Withdraw","inputs":[{"name":"provider","type":"address","indexed":true},{"name":"value","type":"uint256","indexed":false}],"anonymous":false,"type":"event"},{"name":"CommitOwnership","inputs":[{"name":"admin","type":"address","indexed":false}],"anonymous":false,"type":"event"},{"name":"ApplyOwnership","inputs":[{"name":"admin","type":"address","indexed":false}],"anonymous":false,"type":"event"},{"name":"Transfer","inputs":[{"name":"_from","type":"address","indexed":true},{"name":"_to","type":"address","indexed":true},{"name":"_value","type":"uint256","indexed":false}],"anonymous":false,"type":"event"},{"name":"Approval","inputs":[{"name":"_owner","type":"address","indexed":true},{"name":"_spender","type":"address","indexed":true},{"name":"_value","type":"uint256","indexed":false}],"anonymous":false,"type":"event"},{"stateMutability":"nonpayable","type":"constructor","inputs":[{"name":"_admin","type":"address"},{"name":"_lp_token","type":"address"}],"outputs":[]},{"stateMutability":"view","type":"function","name":"decimals","inputs":[],"outputs":[{"name":"","type":"uint256"}],"gas":288},{"stateMutability":"view","type":"function","name":"reward_contract","inputs":[],"outputs":[{"name":"","type":"address"}],"gas":2628},{"stateMutability":"view","type":"function","name":"last_claim","inputs":[],"outputs":[{"name":"","type":"uint256"}],"gas":2454},{"stateMutability":"view","type":"function","name":"claimed_reward","inputs":[{"name":"_addr","type":"address"},{"name":"_token","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":2976},{"stateMutability":"view","type":"function","name":"claimable_reward","inputs":[{"name":"_addr","type":"address"},{"name":"_token","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":2944},{"stateMutability":"nonpayable","type":"function","name":"claimable_reward_write","inputs":[{"name":"_addr","type":"address"},{"name":"_token","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":2067577},{"stateMutability":"nonpayable","type":"function","name":"set_rewards_receiver","inputs":[{"name":"_receiver","type":"address"}],"outputs":[],"gas":35643},{"stateMutability":"nonpayable","type":"function","name":"claim_rewards","inputs":[],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"claim_rewards","inputs":[{"name":"_addr","type":"address"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"claim_rewards","inputs":[{"name":"_addr","type":"address"},{"name":"_receiver","type":"address"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"deposit","inputs":[{"name":"_value","type":"uint256"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"deposit","inputs":[{"name":"_value","type":"uint256"},{"name":"_addr","type":"address"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"deposit","inputs":[{"name":"_value","type":"uint256"},{"name":"_addr","type":"address"},{"name":"_claim_rewards","type":"bool"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"withdraw","inputs":[{"name":"_value","type":"uint256"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"withdraw","inputs":[{"name":"_value","type":"uint256"},{"name":"_claim_rewards","type":"bool"}],"outputs":[]},{"stateMutability":"nonpayable","type":"function","name":"transfer","inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"outputs":[{"name":"","type":"bool"}],"gas":8092437},{"stateMutability":"nonpayable","type":"function","name":"transferFrom","inputs":[{"name":"_from","type":"address"},{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"outputs":[{"name":"","type":"bool"}],"gas":8130387},{"stateMutability":"nonpayable","type":"function","name":"approve","inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"outputs":[{"name":"","type":"bool"}],"gas":38091},{"stateMutability":"nonpayable","type":"function","name":"increaseAllowance","inputs":[{"name":"_spender","type":"address"},{"name":"_added_value","type":"uint256"}],"outputs":[{"name":"","type":"bool"}],"gas":40635},{"stateMutability":"nonpayable","type":"function","name":"decreaseAllowance","inputs":[{"name":"_spender","type":"address"},{"name":"_subtracted_value","type":"uint256"}],"outputs":[{"name":"","type":"bool"}],"gas":40659},{"stateMutability":"nonpayable","type":"function","name":"set_rewards","inputs":[{"name":"_reward_contract","type":"address"},{"name":"_claim_sig","type":"bytes32"},{"name":"_reward_tokens","type":"address[8]"}],"outputs":[],"gas":4442580},{"stateMutability":"nonpayable","type":"function","name":"commit_transfer_ownership","inputs":[{"name":"addr","type":"address"}],"outputs":[],"gas":39375},{"stateMutability":"nonpayable","type":"function","name":"accept_transfer_ownership","inputs":[],"outputs":[],"gas":39320},{"stateMutability":"view","type":"function","name":"lp_token","inputs":[],"outputs":[{"name":"","type":"address"}],"gas":2928},{"stateMutability":"view","type":"function","name":"balanceOf","inputs":[{"name":"arg0","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":3173},{"stateMutability":"view","type":"function","name":"totalSupply","inputs":[],"outputs":[{"name":"","type":"uint256"}],"gas":2988},{"stateMutability":"view","type":"function","name":"allowance","inputs":[{"name":"arg0","type":"address"},{"name":"arg1","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":3448},{"stateMutability":"view","type":"function","name":"name","inputs":[],"outputs":[{"name":"","type":"string"}],"gas":13350},{"stateMutability":"view","type":"function","name":"symbol","inputs":[],"outputs":[{"name":"","type":"string"}],"gas":11103},{"stateMutability":"view","type":"function","name":"reward_tokens","inputs":[{"name":"arg0","type":"uint256"}],"outputs":[{"name":"","type":"address"}],"gas":3217},{"stateMutability":"view","type":"function","name":"reward_balances","inputs":[{"name":"arg0","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":3353},{"stateMutability":"view","type":"function","name":"rewards_receiver","inputs":[{"name":"arg0","type":"address"}],"outputs":[{"name":"","type":"address"}],"gas":3383},{"stateMutability":"view","type":"function","name":"claim_sig","inputs":[],"outputs":[{"name":"","type":"bytes"}],"gas":11223},{"stateMutability":"view","type":"function","name":"reward_integral","inputs":[{"name":"arg0","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":3443},{"stateMutability":"view","type":"function","name":"reward_integral_for","inputs":[{"name":"arg0","type":"address"},{"name":"arg1","type":"address"}],"outputs":[{"name":"","type":"uint256"}],"gas":3688},{"stateMutability":"view","type":"function","name":"admin","inputs":[],"outputs":[{"name":"","type":"address"}],"gas":3288},{"stateMutability":"view","type":"function","name":"future_admin","inputs":[],"outputs":[{"name":"","type":"address"}],"gas":3318}]

6040611e34610140396020611e3460c03960c05160a01c1561002057600080fd5b60206020611e340160c03960c05160a01c1561003b57600080fd5b606061024060046395d89b416101e0526101fc610160515afa61005d57600080fd5b603f3d1161006a57600080fd5b601b6102406102405101511061007f57600080fd5b6000506102608051602001806101808284600060045af161009f57600080fd5b5050600060096101e0527f43757276652e6669200000000000000000000000000000000000000000000000610200526101e06009806020846102a001018260208501600060045af1505080518201915050610180601a806020846102a001018260208501600060045af15050805182019150506014610240527f205265776172644761756765204465706f736974000000000000000000000000610260526102406014806020846102a001018260208501600060045af1505080518201915050806102a0526102a0905080600460c052602060c020602082510161012060006003818352015b82610120516020021115610198576101ba565b61012051602002850151610120518501555b8151600101808352811415610185575b5050505050506000610180601a8060208461024001018260208501600060045af150508051820191505060066101e0527f2d67617567650000000000000000000000000000000000000000000000000000610200526101e060068060208461024001018260208501600060045af15050805182019150508061024052610240905080600560c052602060c020602082510161012060006002818352015b8261012051602002111561026a5761028c565b61012051602002850151610120518501555b8151600101808352811415610257575b5050505050506101605160005561014051600e55611e1c56600436101561000d576112ed565b600035601c52600051341561002157600080fd5b63313ce56781141561003857601260005260206000f35b63bf88a6ff81141561007e5760065474010000000000000000000000000000000000000000808206905090508060a01c1561007257600080fd5b80905060005260206000f35b633488bd198114156100995760065460a01c60005260206000f35b63e77e74378114156101065760043560a01c156100b557600080fd5b60243560a01c156100c557600080fd5b600d60043560e05260c052604060c02060243560e05260c052604060c020547001000000000000000000000000000000008082069050905060005260206000f35b6333fd6f7481141561015d5760043560a01c1561012257600080fd5b60243560a01c1561013257600080fd5b600d60043560e05260c052604060c02060243560e05260c052604060c0205460801c60005260206000f35b6359b7e409811415610215576010541561017657600080fd5b600160105560043560a01c1561018b57600080fd5b60243560a01c1561019b57600080fd5b6000600760c052602060c0205418156101e557600435610140526002546101605260006101805260006101a0526101a051610180516101605161014051600658016112f3565b6000505b600d60043560e05260c052604060c02060243560e05260c052604060c0205460801c600052600060105560206000f35b63bdf981168114156102455760043560a01c1561023157600080fd5b60043560093360e05260c052604060c02055005b63e6f1daf28114156102615733610140526000610160526102dc565b6384e9bd7e8114156102935760006101605260043560a01c1561028357600080fd5b60206004610140376000506102dc565b639faceb1b8114156102d75760043560a01c156102af57600080fd5b602060046101403760243560a01c156102c757600080fd5b60206024610160376000506102dc565b610359565b601054156102e957600080fd5b600160105560006101605118156103095733610140511461030957600080fd5b610140516101605161014051610180526002546101a05260016101c052610160516101e0526101e0516101c0516101a05161018051600658016112f3565b61016052610140526000506000601055005b63b6b55f258114156103755733610140526000610160526103f0565b636e553f658114156103a75760006101605260243560a01c1561039757600080fd5b60206024610140376000506103f0565b6383df67478114156103eb5760243560a01c156103c357600080fd5b602060246101403760443560011c156103db57600080fd5b60206044610160376000506103f0565b6105c6565b601054156103fd57600080fd5b6001601055600060043518156105595760065474010000000000000000000000000000000000000000808206905090508060a01c1561043b57600080fd5b809050610180526002546101a0526101405161016051610180516101a051610140516101c0526101a0516101e052610160516102005260006102205261022051610200516101e0516101c051600658016112f3565b6101a0526101805261016052610140526000506101a080516004358181830110156104ba57600080fd5b8082019050905081525060016101405160e05260c052604060c020546004358181830110156104e857600080fd5b808201905090506101c0526101c05160016101405160e05260c052604060c020556101a05160025560206102a060646323b872dd6101e05233610200523061022052600435610240526101fc60006000545af161054457600080fd5b601f3d1161055157600080fd5b6000506102a0505b60043561018052610140517fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c6020610180a2600435610180526101405160007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610180a36000601055005b632e1a7d4d8114156105dd5760006101405261060e565b6338d074368114156106095760243560011c156105f957600080fd5b602060246101403760005061060e565b6107c4565b6010541561061b57600080fd5b60016010556000600435181561075d5760065474010000000000000000000000000000000000000000808206905090508060a01c1561065957600080fd5b8090506101605260025461018052610140516101605161018051336101a052610180516101c052610140516101e052600061020052610200516101e0516101c0516101a051600658016112f3565b6101805261016052610140526000506101808051600435808210156106cb57600080fd5b8082039050905081525060013360e05260c052604060c02054600435808210156106f457600080fd5b808203905090506101a0526101a05160013360e05260c052604060c02055610180516002556020610260604463a9059cbb6101c052336101e052600435610200526101dc60006000545af161074857600080fd5b601f3d1161075557600080fd5b600050610260505b60043561016052337f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a94243646020610160a2600435610160526000337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610160a36000601055005b63a9059cbb81141561082d57601054156107dd57600080fd5b600160105560043560a01c156107f257600080fd5b336101405260043561016052602435610180526101805161016051610140516006580161197f565b6000506001600052600060105560206000f35b6323b872dd811415610935576010541561084657600080fd5b600160105560043560a01c1561085b57600080fd5b60243560a01c1561086b57600080fd5b600360043560e05260c052604060c0203360e05260c052604060c02054610140527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101405118156108f05761014051604435808210156108cb57600080fd5b80820390509050600360043560e05260c052604060c0203360e05260c052604060c020555b6101405160043561016052602435610180526044356101a0526101a05161018051610160516006580161197f565b610140526000506001600052600060105560206000f35b63095ea7b38114156109ae5760043560a01c1561095157600080fd5b60243560033360e05260c052604060c02060043560e05260c052604060c0205560243561014052600435337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256020610140a3600160005260206000f35b6339509351811415610a635760043560a01c156109ca57600080fd5b60033360e05260c052604060c02060043560e05260c052604060c020546024358181830110156109f957600080fd5b80820190509050610140526101405160033360e05260c052604060c02060043560e05260c052604060c020556101405161016052600435337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256020610160a3600160005260206000f35b63a457c2d7811415610b165760043560a01c15610a7f57600080fd5b60033360e05260c052604060c02060043560e05260c052604060c0205460243580821015610aac57600080fd5b80820390509050610140526101405160033360e05260c052604060c02060043560e05260c052604060c020556101405161016052600435337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256020610160a3600160005260206000f35b6347d2d5d3811415610e315760105415610b2f57600080fd5b600160105560043560a01c15610b4457600080fd5b6000610120525b610120516044013560a01c15610b6057600080fd5b6020610120510161012052610100610120511015610b7d57610b4b565b600e543314610b8b57600080fd5b6000546101405260065474010000000000000000000000000000000000000000808206905090508060a01c15610bc057600080fd5b809050610160526002546101805261014051610160516101805160006101a052610180516101c05260006101e052600061020052610200516101e0516101c0516101a051600658016112f3565b61018052610160526101405260005060006004351815610c4657600060443518610c3657600080fd5b60006004353b11610c4657600080fd5b600435600655601c6004602082066101a00160208284011115610c6857600080fd5b60246101c06020840161012060006001818352015b82610120516020021115610c9057610cb5565b61012051602002850135610120516020028501525b8151600101808352811415610c7d575b50505050508181528090509050905080600a60c052602060c020602082510161012060006002818352015b82610120516020021115610cf357610d15565b61012051602002850151610120518501555b8151600101808352811415610ce0575b5050505050506101a060006008818352015b6101a05160088110610d3857600080fd5b600760c052602060c02001546101c05260446101a05160088110610d5b57600080fd5b60200201356101e05260006101c0511815610d87576101e0516101c05114610d8257600080fd5b610dbe565b60006101e0511815610db9576101e0516101a05160088110610da857600080fd5b600760c052602060c0200155610dbe565b610dce565b8151600101808352811415610d27575b505060006004351815610e2a5761014051610160516101805160006101a052610180516101c05260006101e052600061020052610200516101e0516101c0516101a051600658016112f3565b6101805261016052610140526000505b6000601055005b636b441a40811415610e915760043560a01c15610e4d57600080fd5b600e543314610e5b57600080fd5b600435600f55600435610140527f2f56810a6bf40af059b96d3aea4db54081f378029a518390491093a7b67032e96020610140a1005b63e5ea47b8811415610eeb57600f5461014052610140513314610eb357600080fd5b61014051600e5561014051610160527febee2d5739011062cb4f14113f3b36bf0ffe3da5c0568f64189d1012a11891056020610160a1005b6382c63066811415610f035760005460005260206000f35b6370a08231811415610f395760043560a01c15610f1f57600080fd5b600160043560e05260c052604060c0205460005260206000f35b6318160ddd811415610f515760025460005260206000f35b63dd62ed3e811415610fa55760043560a01c15610f6d57600080fd5b60243560a01c15610f7d57600080fd5b600360043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f35b6306fdde0381141561104a5760048060c052602060c020610180602082540161012060006003818352015b82610120516020021115610fe357611005565b61012051850154610120516020028501525b8151600101808352811415610fd0575b50505050505061018051806101a001818260206001820306601f82010390500336823750506020610160526040610180510160206001820306601f8201039050610160f35b6395d89b418114156110ef5760058060c052602060c020610180602082540161012060006002818352015b82610120516020021115611088576110aa565b61012051850154610120516020028501525b8151600101808352811415611075575b50505050505061018051806101a001818260206001820306601f82010390500336823750506020610160526040610180510160206001820306601f8201039050610160f35b6354c49fe9811415611120576004356008811061110b57600080fd5b600760c052602060c020015460005260206000f35b63fe9e21788114156111565760043560a01c1561113c57600080fd5b600860043560e05260c052604060c0205460005260206000f35b6301ddabf181141561118c5760043560a01c1561117257600080fd5b600960043560e05260c052604060c0205460005260206000f35b63b7aca56881141561123157600a8060c052602060c020610180602082540161012060006002818352015b826101205160200211156111ca576111ec565b61012051850154610120516020028501525b81516001018083528114156111b7575b50505050505061018051806101a001818260206001820306601f82010390500336823750506020610160526040610180510160206001820306601f8201039050610160f35b6373861fb38114156112675760043560a01c1561124d57600080fd5b600b60043560e05260c052604060c0205460005260206000f35b63f05cc0588114156112bb5760043560a01c1561128357600080fd5b60243560a01c1561129357600080fd5b600c60043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f35b63f851a4408114156112d357600e5460005260206000f35b6317f7182a8114156112eb57600f5460005260206000f35b505b60006000fd5b6101c0526101405261016052610180526101a0526006546101e05260006101605118156113555760006101e051181561134d576101e05160a01c610e1081818301101561133f57600080fd5b808201905090504211611350565b60005b611358565b60005b1561142b576101e05174010000000000000000000000000000000000000000808206905090508060a01c1561138c57600080fd5b80905061020052600a8060c052602060c020610220602082540161012060006002818352015b826101205160200211156113c5576113e7565b61012051850154610120516020028501525b81516001018083528114156113b2575b50505050505060006000610220516102406000610200515af161140957600080fd5b610200514260a01b81818301101561142057600080fd5b808201905090506006555b6101a051610200526101805115611446576102005115611449565b60005b156114775760096101405160e05260c052604060c02054610200526102005115156114775761014051610200525b60016101405160e05260c052604060c020546102205261024060006008818352015b61024051600881106114aa57600080fd5b600760c052602060c0200154610260526102605115156114c957611977565b60006102805260006101605118156115e357602061034060246370a082316102c052306102e0526102dc610260515afa61150257600080fd5b601f3d1161150f57600080fd5b600050610340516102a052670de0b6b3a76400006102a05160086102605160e05260c052604060c020548082101561154657600080fd5b80820390509050808202821582848304141761156157600080fd5b8090509050905061016051808061157757600080fd5b820490509050610280526102a05160086102605160e05260c052604060c020556101405115156115e35760006102805118156115de57600b6102605160e05260c052604060c0208054610280518181830110156115d357600080fd5b808201905090508155505b611967565b600b6102605160e05260c052604060c020546102805181818301101561160857600080fd5b808201905090506102a0526000610280511815611636576102a051600b6102605160e05260c052604060c020555b600c6102605160e05260c052604060c0206101405160e05260c052604060c020546102c05260006102e0526102a0516102c05110156116e4576102a051600c6102605160e05260c052604060c0206101405160e05260c052604060c02055610220516102a0516102c051808210156116ad57600080fd5b8082039050905080820282158284830414176116c857600080fd5b80905090509050670de0b6b3a7640000808204905090506102e0525b600d6101405160e05260c052604060c0206102605160e05260c052604060c02054610300526103005160801c6102e05181818301101561172357600080fd5b8082019050905061032052600061032051111561196757610300517001000000000000000000000000000000008082069050905061034052610180511561191857600060046103c0527fa9059cbb000000000000000000000000000000000000000000000000000000006103e0526103c060048060208461042001018260208501600060045af15050805182019150506102005160208261042001015260208101905061032051602082610420010152602081019050806104205261042090508051602001806104c08284600060045af16117fd57600080fd5b505060206105806104c0516104e06000610260515af161181c57600080fd5b60203d8082111561182d578061182f565b815b90509050610560526105608051602001806103608284600060045af161185457600080fd5b505060006103605118156118a65761036080602001516000825180602090131561187d57600080fd5b809190121561188b57600080fd5b806020036101000a820490509050905015156118a657600080fd5b60086102605160e05260c052604060c020805461032051808210156118ca57600080fd5b8082039050905081555061034051610320518181830110156118eb57600080fd5b80820190509050600d6101405160e05260c052604060c0206102605160e05260c052604060c02055611967565b60006102e051111561196757610340516103205160801b81818301101561193e57600080fd5b80820190509050600d6101405160e05260c052604060c0206102605160e05260c052604060c020555b8151600101808352811415611499575b50506101c051565b6101a05261014052610160526101805260065474010000000000000000000000000000000000000000808206905090508060a01c156119bd57600080fd5b8090506101c0526000610180511815611b3a576002546101e0526101405161016051610180516101a0516101c0516101e05161014051610200526101e0516102205260006102405260006102605261026051610240516102205161020051600658016112f3565b6101e0526101c0526101a05261018052610160526101405260005060016101405160e05260c052604060c020546101805180821015611a6257600080fd5b80820390509050610200526102005160016101405160e05260c052604060c020556101405161016051610180516101a0516101c0516101e0516102005161016051610220526101e0516102405260006102605260006102805261028051610260516102405161022051600658016112f3565b610200526101e0526101c0526101a05261018052610160526101405260005060016101605160e05260c052604060c0205461018051818183011015611b1857600080fd5b80820190509050610200526102005160016101605160e05260c052604060c020555b610180516101e05261016051610140517fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206101e0a36101a051565b6102a5611e1c036102a56000396102a5611e1c036000f30000000000000000000000007eeac6cddbd1d0b8af061742d41877d7f707289a0000000000000000000000007f90122bf0700f9e7e1f688fe926940e8839f353

Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.