ETH Price: $3,381.55 (+3.13%)

Contract

0xd061D61a4d941c39E5453435B6345Dc261C2fcE0
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Mint214649472024-12-23 11:40:1114 hrs ago1734954011IN
Curve.fi: Minter
0 ETH0.002225995.80858505
Mint214649402024-12-23 11:38:4714 hrs ago1734953927IN
Curve.fi: Minter
0 ETH0.00209925.4777294
Mint214649372024-12-23 11:38:1114 hrs ago1734953891IN
Curve.fi: Minter
0 ETH0.002573125.93877371
Mint214649342024-12-23 11:37:3514 hrs ago1734953855IN
Curve.fi: Minter
0 ETH0.002162355.64253043
Mint214642862024-12-23 9:27:2316 hrs ago1734946043IN
Curve.fi: Minter
0 ETH0.002702676.14285931
Mint214638722024-12-23 8:04:3518 hrs ago1734941075IN
Curve.fi: Minter
0 ETH0.001641044.09213838
Mint214631672024-12-23 5:41:4720 hrs ago1734932507IN
Curve.fi: Minter
0 ETH0.001864594.70530254
Mint214624222024-12-23 3:11:3522 hrs ago1734923495IN
Curve.fi: Minter
0 ETH0.002402375.2064282
Mint214585432024-12-22 14:10:1135 hrs ago1734876611IN
Curve.fi: Minter
0 ETH0.002981887.21350135
Mint214585412024-12-22 14:09:4735 hrs ago1734876587IN
Curve.fi: Minter
0 ETH0.002970827.18674508
Mint214585402024-12-22 14:09:3535 hrs ago1734876575IN
Curve.fi: Minter
0 ETH0.002816656.81379596
Mint214578352024-12-22 11:47:3538 hrs ago1734868055IN
Curve.fi: Minter
0 ETH0.002192635.74025838
Mint214569942024-12-22 8:58:2341 hrs ago1734857903IN
Curve.fi: Minter
0 ETH0.001886484.93877608
Mint214566092024-12-22 7:41:1142 hrs ago1734853271IN
Curve.fi: Minter
0 ETH0.002107925.01237854
Mint214548632024-12-22 1:50:232 days ago1734832223IN
Curve.fi: Minter
0 ETH0.002496646.29275997
Mint214548082024-12-22 1:39:232 days ago1734831563IN
Curve.fi: Minter
0 ETH0.002737546.62242932
Mint214541152024-12-21 23:19:472 days ago1734823187IN
Curve.fi: Minter
0 ETH0.003286798.19603596
Mint214535422024-12-21 21:23:472 days ago1734816227IN
Curve.fi: Minter
0 ETH0.002293135.78673042
Mint214533192024-12-21 20:38:352 days ago1734813515IN
Curve.fi: Minter
0 ETH0.002773636.59553983
Mint214532972024-12-21 20:34:112 days ago1734813251IN
Curve.fi: Minter
0 ETH0.002644566.25860187
Mint214528912024-12-21 19:12:112 days ago1734808331IN
Curve.fi: Minter
0 ETH0.00335818.47418295
Mint214521172024-12-21 16:35:592 days ago1734798959IN
Curve.fi: Minter
0 ETH0.003865128.16478877
Mint214521152024-12-21 16:35:352 days ago1734798935IN
Curve.fi: Minter
0 ETH0.003956458.06652509
Mint214516152024-12-21 14:55:232 days ago1734792923IN
Curve.fi: Minter
0 ETH0.0038200410.08114225
Mint214500062024-12-21 9:32:232 days ago1734773543IN
Curve.fi: Minter
0 ETH0.003317828.02618285
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Vyper_contract

Compiler Version
vyper:0.2.4

Optimization Enabled:
N/A

Other Settings:
default evmVersion, MIT license

Contract Source Code (Vyper language format)

# @version 0.2.4
"""
@title Token Minter
@author Curve Finance
@license MIT
"""

interface LiquidityGauge:
    # Presumably, other gauges will provide the same interfaces
    def integrate_fraction(addr: address) -> uint256: view
    def user_checkpoint(addr: address) -> bool: nonpayable

interface MERC20:
    def mint(_to: address, _value: uint256) -> bool: nonpayable

interface GaugeController:
    def gauge_types(addr: address) -> int128: view


event Minted:
    recipient: indexed(address)
    gauge: address
    minted: uint256


token: public(address)
controller: public(address)

# user -> gauge -> value
minted: public(HashMap[address, HashMap[address, uint256]])

# minter -> user -> can mint?
allowed_to_mint_for: public(HashMap[address, HashMap[address, bool]])


@external
def __init__(_token: address, _controller: address):
    self.token = _token
    self.controller = _controller


@internal
def _mint_for(gauge_addr: address, _for: address):
    assert GaugeController(self.controller).gauge_types(gauge_addr) >= 0  # dev: gauge is not added

    LiquidityGauge(gauge_addr).user_checkpoint(_for)
    total_mint: uint256 = LiquidityGauge(gauge_addr).integrate_fraction(_for)
    to_mint: uint256 = total_mint - self.minted[_for][gauge_addr]

    if to_mint != 0:
        MERC20(self.token).mint(_for, to_mint)
        self.minted[_for][gauge_addr] = total_mint

        log Minted(_for, gauge_addr, total_mint)


@external
@nonreentrant('lock')
def mint(gauge_addr: address):
    """
    @notice Mint everything which belongs to `msg.sender` and send to them
    @param gauge_addr `LiquidityGauge` address to get mintable amount from
    """
    self._mint_for(gauge_addr, msg.sender)


@external
@nonreentrant('lock')
def mint_many(gauge_addrs: address[8]):
    """
    @notice Mint everything which belongs to `msg.sender` across multiple gauges
    @param gauge_addrs List of `LiquidityGauge` addresses
    """
    for i in range(8):
        if gauge_addrs[i] == ZERO_ADDRESS:
            break
        self._mint_for(gauge_addrs[i], msg.sender)


@external
@nonreentrant('lock')
def mint_for(gauge_addr: address, _for: address):
    """
    @notice Mint tokens for `_for`
    @dev Only possible when `msg.sender` has been approved via `toggle_approve_mint`
    @param gauge_addr `LiquidityGauge` address to get mintable amount from
    @param _for Address to mint to
    """
    if self.allowed_to_mint_for[msg.sender][_for]:
        self._mint_for(gauge_addr, _for)


@external
def toggle_approve_mint(minting_user: address):
    """
    @notice allow `minting_user` to mint for `msg.sender`
    @param minting_user Address to toggle permission for
    """
    self.allowed_to_mint_for[minting_user][msg.sender] = not self.allowed_to_mint_for[minting_user][msg.sender]

Contract Security Audit

Contract ABI

[{"name":"Minted","inputs":[{"type":"address","name":"recipient","indexed":true},{"type":"address","name":"gauge","indexed":false},{"type":"uint256","name":"minted","indexed":false}],"anonymous":false,"type":"event"},{"outputs":[],"inputs":[{"type":"address","name":"_token"},{"type":"address","name":"_controller"}],"stateMutability":"nonpayable","type":"constructor"},{"name":"mint","outputs":[],"inputs":[{"type":"address","name":"gauge_addr"}],"stateMutability":"nonpayable","type":"function","gas":100038},{"name":"mint_many","outputs":[],"inputs":[{"type":"address[8]","name":"gauge_addrs"}],"stateMutability":"nonpayable","type":"function","gas":408502},{"name":"mint_for","outputs":[],"inputs":[{"type":"address","name":"gauge_addr"},{"type":"address","name":"_for"}],"stateMutability":"nonpayable","type":"function","gas":101219},{"name":"toggle_approve_mint","outputs":[],"inputs":[{"type":"address","name":"minting_user"}],"stateMutability":"nonpayable","type":"function","gas":36726},{"name":"token","outputs":[{"type":"address","name":""}],"inputs":[],"stateMutability":"view","type":"function","gas":1301},{"name":"controller","outputs":[{"type":"address","name":""}],"inputs":[],"stateMutability":"view","type":"function","gas":1331},{"name":"minted","outputs":[{"type":"uint256","name":""}],"inputs":[{"type":"address","name":"arg0"},{"type":"address","name":"arg1"}],"stateMutability":"view","type":"function","gas":1669},{"name":"allowed_to_mint_for","outputs":[{"type":"bool","name":""}],"inputs":[{"type":"address","name":"arg0"},{"type":"address","name":"arg1"}],"stateMutability":"view","type":"function","gas":1699}]

740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a05260406107036101403934156100a157600080fd5b602061070360c03960c05160205181106100ba57600080fd5b50602060206107030160c03960c05160205181106100d757600080fd5b5061014051600055610160516001556106eb56600436101561000d576105fa565b600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a052600015610278575b610180526101405261016052600060206102206024633f9095b76101a052610140516101c0526101bc6001545afa6100e057600080fd5b601f3d116100ed57600080fd5b6000506102205112156100ff57600080fd5b60206102c06024634b82009361024052610160516102605261025c6000610140515af161012b57600080fd5b601f3d1161013857600080fd5b6000506102c05060206103806024630940070761030052610160516103205261031c610140515afa61016957600080fd5b601f3d1161017657600080fd5b600050610380516102e0526102e05160026101605160e05260c052604060c0206101405160e05260c052604060c02054808210156101b357600080fd5b808203905090506103a05260006103a051181561027257602061046060446340c10f196103c052610160516103e0526103a051610400526103dc60006000545af16101fd57600080fd5b601f3d1161020a57600080fd5b600050610460506102e05160026101605160e05260c052604060c0206101405160e05260c052604060c0205561014051610480526102e0516104a052610160517f9d228d69b5fdb8d273a2336f8fb8612d039631024ea9bf09c424a9503aa078f06040610480a25b61018051565b636a62784260005114156102e25762ffffff541561029557600080fd5b600162ffffff5534156102a757600080fd5b60043560205181106102b857600080fd5b506004356101405233610160526101605161014051600658016100a9565b600050600062ffffff55005b63a51e190460005114156103d45762ffffff54156102ff57600080fd5b600162ffffff55341561031157600080fd5b6000610120525b6101205160040135602051811061032e57600080fd5b50602061012051016101205261010061012051101561034c57610318565b61014060006008818352015b6004610140516008811061036b57600080fd5b6020020135151561037b576103c9565b610140516004610140516008811061039257600080fd5b602002013561018052336101a0526101a05161018051600658016100a9565b610140526000505b8151600101808352811415610358575b5050600062ffffff55005b6327f18ae360005114156104755762ffffff54156103f157600080fd5b600162ffffff55341561040357600080fd5b600435602051811061041457600080fd5b50602435602051811061042657600080fd5b5060033360e05260c052604060c02060243560e05260c052604060c020541561046c5760043561014052602435610160526101605161014051600658016100a9565b6000505b600062ffffff55005b63dd289d6060005114156104dd57341561048e57600080fd5b600435602051811061049f57600080fd5b50600360043560e05260c052604060c0203360e05260c052604060c0205415600360043560e05260c052604060c0203360e05260c052604060c02055005b63fc0c546a60005114156105045734156104f657600080fd5b60005460005260206000f350005b63f77c4791600051141561052b57341561051d57600080fd5b60015460005260206000f350005b638b752bb0600051141561059257341561054457600080fd5b600435602051811061055557600080fd5b50602435602051811061056757600080fd5b50600260043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f350005b63a099003360005114156105f95734156105ab57600080fd5b60043560205181106105bc57600080fd5b5060243560205181106105ce57600080fd5b50600360043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f350005b5b60006000fd5b6100eb6106eb036100eb6000396100eb6106eb036000f3000000000000000000000000d533a949740bb3306d119cc777fa900ba034cd520000000000000000000000002f50d538606fa9edd2b11e2446beb18c9d5846bb

Deployed Bytecode

0x600436101561000d576105fa565b600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a052600015610278575b610180526101405261016052600060206102206024633f9095b76101a052610140516101c0526101bc6001545afa6100e057600080fd5b601f3d116100ed57600080fd5b6000506102205112156100ff57600080fd5b60206102c06024634b82009361024052610160516102605261025c6000610140515af161012b57600080fd5b601f3d1161013857600080fd5b6000506102c05060206103806024630940070761030052610160516103205261031c610140515afa61016957600080fd5b601f3d1161017657600080fd5b600050610380516102e0526102e05160026101605160e05260c052604060c0206101405160e05260c052604060c02054808210156101b357600080fd5b808203905090506103a05260006103a051181561027257602061046060446340c10f196103c052610160516103e0526103a051610400526103dc60006000545af16101fd57600080fd5b601f3d1161020a57600080fd5b600050610460506102e05160026101605160e05260c052604060c0206101405160e05260c052604060c0205561014051610480526102e0516104a052610160517f9d228d69b5fdb8d273a2336f8fb8612d039631024ea9bf09c424a9503aa078f06040610480a25b61018051565b636a62784260005114156102e25762ffffff541561029557600080fd5b600162ffffff5534156102a757600080fd5b60043560205181106102b857600080fd5b506004356101405233610160526101605161014051600658016100a9565b600050600062ffffff55005b63a51e190460005114156103d45762ffffff54156102ff57600080fd5b600162ffffff55341561031157600080fd5b6000610120525b6101205160040135602051811061032e57600080fd5b50602061012051016101205261010061012051101561034c57610318565b61014060006008818352015b6004610140516008811061036b57600080fd5b6020020135151561037b576103c9565b610140516004610140516008811061039257600080fd5b602002013561018052336101a0526101a05161018051600658016100a9565b610140526000505b8151600101808352811415610358575b5050600062ffffff55005b6327f18ae360005114156104755762ffffff54156103f157600080fd5b600162ffffff55341561040357600080fd5b600435602051811061041457600080fd5b50602435602051811061042657600080fd5b5060033360e05260c052604060c02060243560e05260c052604060c020541561046c5760043561014052602435610160526101605161014051600658016100a9565b6000505b600062ffffff55005b63dd289d6060005114156104dd57341561048e57600080fd5b600435602051811061049f57600080fd5b50600360043560e05260c052604060c0203360e05260c052604060c0205415600360043560e05260c052604060c0203360e05260c052604060c02055005b63fc0c546a60005114156105045734156104f657600080fd5b60005460005260206000f350005b63f77c4791600051141561052b57341561051d57600080fd5b60015460005260206000f350005b638b752bb0600051141561059257341561054457600080fd5b600435602051811061055557600080fd5b50602435602051811061056757600080fd5b50600260043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f350005b63a099003360005114156105f95734156105ab57600080fd5b60043560205181106105bc57600080fd5b5060243560205181106105ce57600080fd5b50600360043560e05260c052604060c02060243560e05260c052604060c0205460005260206000f350005b5b60006000fd

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

000000000000000000000000d533a949740bb3306d119cc777fa900ba034cd520000000000000000000000002f50d538606fa9edd2b11e2446beb18c9d5846bb

-----Decoded View---------------
Arg [0] : _token (address): 0xD533a949740bb3306d119CC777fa900bA034cd52
Arg [1] : _controller (address): 0x2F50D538606Fa9EDD2B11E2446BEb18C9D5846bB

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000d533a949740bb3306d119cc777fa900ba034cd52
Arg [1] : 0000000000000000000000002f50d538606fa9edd2b11e2446beb18c9d5846bb


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.