Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 70 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Create | 17219132 | 648 days ago | IN | 0 ETH | 0.02235278 | ||||
Create | 16973420 | 683 days ago | IN | 0 ETH | 0.00682571 | ||||
Create | 16583489 | 737 days ago | IN | 0 ETH | 0.00733784 | ||||
Create | 16473384 | 753 days ago | IN | 0 ETH | 0.00519836 | ||||
Create | 16381968 | 766 days ago | IN | 0 ETH | 0.00482645 | ||||
Create | 16371086 | 767 days ago | IN | 0 ETH | 0.01107298 | ||||
Create | 16370942 | 767 days ago | IN | 0 ETH | 0.00331282 | ||||
Create | 16370932 | 767 days ago | IN | 0 ETH | 0.00364993 | ||||
Create | 16335903 | 772 days ago | IN | 0 ETH | 0.00656377 | ||||
Create | 16240092 | 785 days ago | IN | 0 ETH | 0.0034232 | ||||
Create | 16182975 | 793 days ago | IN | 0 ETH | 0.00378398 | ||||
Create | 16182971 | 793 days ago | IN | 0 ETH | 0.00374499 | ||||
Create | 16116016 | 803 days ago | IN | 0 ETH | 0.00107127 | ||||
Create | 16076835 | 808 days ago | IN | 0 ETH | 0.00473132 | ||||
Create | 16069007 | 809 days ago | IN | 0 ETH | 0.00452013 | ||||
Create | 16045210 | 813 days ago | IN | 0 ETH | 0.00341078 | ||||
Create | 16040396 | 813 days ago | IN | 0 ETH | 0.00417146 | ||||
Create | 16040393 | 813 days ago | IN | 0 ETH | 0.0045558 | ||||
Create | 16034842 | 814 days ago | IN | 0 ETH | 0.00461513 | ||||
Create | 16017282 | 816 days ago | IN | 0 ETH | 0.00383818 | ||||
Create | 15979480 | 822 days ago | IN | 0 ETH | 0.00519996 | ||||
Create | 15972323 | 823 days ago | IN | 0 ETH | 0.00597907 | ||||
Create | 15895371 | 833 days ago | IN | 0 ETH | 0.00544263 | ||||
Create | 15884618 | 835 days ago | IN | 0 ETH | 0.0065461 | ||||
Create | 15882489 | 835 days ago | IN | 0 ETH | 0.0033017 |
Latest 25 internal transactions (View All)
Advanced mode:
Loading...
Loading
This contract may be a proxy contract. Click on More Options and select Is this a proxy? to confirm and enable the "Read as Proxy" & "Write as Proxy" tabs.
Contract Source Code Verified (Exact Match)
Contract Name:
LiquidityGaugeFactory
Compiler Version
v0.7.1+commit.f4a555be
Optimization Enabled:
Yes with 9999 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-3.0-or-later // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. pragma solidity ^0.7.0; pragma experimental ABIEncoderV2; import "@balancer-labs/v2-solidity-utils/contracts/openzeppelin/Clones.sol"; import "../../interfaces/IStakingLiquidityGauge.sol"; import "../../interfaces/ILiquidityGaugeFactory.sol"; contract LiquidityGaugeFactory is ILiquidityGaugeFactory { ILiquidityGauge private immutable _gaugeImplementation; mapping(address => bool) private _isGaugeFromFactory; mapping(address => address) private _poolGauge; event GaugeCreated(address indexed gauge, address indexed pool); constructor(ILiquidityGauge gauge) { _gaugeImplementation = gauge; } /** * @notice Returns the address of the implementation used for gauge deployments. */ function getGaugeImplementation() public view returns (ILiquidityGauge) { return _gaugeImplementation; } /** * @notice Returns the address of the gauge belonging to `pool`. */ function getPoolGauge(address pool) external view returns (ILiquidityGauge) { return ILiquidityGauge(_poolGauge[pool]); } /** * @notice Returns true if `gauge` was created by this factory. */ function isGaugeFromFactory(address gauge) external view override returns (bool) { return _isGaugeFromFactory[gauge]; } /** * @notice Deploys a new gauge for a Balancer pool. * @dev As anyone can register arbitrary Balancer pools with the Vault, * it's impossible to prove onchain that `pool` is a "valid" deployment. * * Care must be taken to ensure that gauges deployed from this factory are * suitable before they are added to the GaugeController. * * This factory disallows deploying multiple gauges for a single pool. * @param pool The address of the pool for which to deploy a gauge * @return The address of the deployed gauge */ function create(address pool) external returns (address) { require(_poolGauge[pool] == address(0), "Gauge already exists"); address gauge = Clones.clone(address(_gaugeImplementation)); IStakingLiquidityGauge(gauge).initialize(pool); _isGaugeFromFactory[gauge] = true; _poolGauge[pool] = gauge; emit GaugeCreated(gauge, pool); return gauge; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.7.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: GPL-3.0-or-later // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. pragma solidity ^0.7.0; // For compatibility, we're keeping the same function names as in the original Curve code, including the mixed-case // naming convention. // solhint-disable func-name-mixedcase interface ILiquidityGauge { function integrate_fraction(address user) external view returns (uint256); function user_checkpoint(address user) external returns (bool); function is_killed() external view returns (bool); function killGauge() external; function unkillGauge() external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (proxy/Clones.sol) pragma solidity ^0.7.0; /** * @dev https://eips.ethereum.org/EIPS/eip-1167[EIP 1167] is a standard for * deploying minimal proxy contracts, also known as "clones". * * > To simply and cheaply clone contract functionality in an immutable way, this standard specifies * > a minimal bytecode implementation that delegates all calls to a known, fixed address. * * The library includes functions to deploy a proxy using either `create` (traditional deployment) or `create2` * (salted deterministic deployment). It also includes functions to predict the addresses of clones deployed using the * deterministic method. * * _Available since v3.4._ */ library Clones { /** * @dev Deploys and returns the address of a clone that mimics the behaviour of `implementation`. * * This function uses the create opcode, which should never revert. */ function clone(address implementation) internal returns (address instance) { assembly { let ptr := mload(0x40) mstore(ptr, 0x3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000) mstore(add(ptr, 0x14), shl(0x60, implementation)) mstore(add(ptr, 0x28), 0x5af43d82803e903d91602b57fd5bf30000000000000000000000000000000000) instance := create(0, ptr, 0x37) } require(instance != address(0), "ERC1167: create failed"); } /** * @dev Deploys and returns the address of a clone that mimics the behaviour of `implementation`. * * This function uses the create2 opcode and a `salt` to deterministically deploy * the clone. Using the same `implementation` and `salt` multiple time will revert, since * the clones cannot be deployed twice at the same address. */ function cloneDeterministic(address implementation, bytes32 salt) internal returns (address instance) { assembly { let ptr := mload(0x40) mstore(ptr, 0x3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000) mstore(add(ptr, 0x14), shl(0x60, implementation)) mstore(add(ptr, 0x28), 0x5af43d82803e903d91602b57fd5bf30000000000000000000000000000000000) instance := create2(0, ptr, 0x37, salt) } require(instance != address(0), "ERC1167: create2 failed"); } /** * @dev Computes the address of a clone deployed using {Clones-cloneDeterministic}. */ function predictDeterministicAddress( address implementation, bytes32 salt, address deployer ) internal pure returns (address predicted) { assembly { let ptr := mload(0x40) mstore(ptr, 0x3d602d80600a3d3981f3363d3d373d3d3d363d73000000000000000000000000) mstore(add(ptr, 0x14), shl(0x60, implementation)) mstore(add(ptr, 0x28), 0x5af43d82803e903d91602b57fd5bf3ff00000000000000000000000000000000) mstore(add(ptr, 0x38), shl(0x60, deployer)) mstore(add(ptr, 0x4c), salt) mstore(add(ptr, 0x6c), keccak256(ptr, 0x37)) predicted := keccak256(add(ptr, 0x37), 0x55) } } /** * @dev Computes the address of a clone deployed using {Clones-cloneDeterministic}. */ function predictDeterministicAddress(address implementation, bytes32 salt) internal view returns (address predicted) { return predictDeterministicAddress(implementation, salt, address(this)); } }
// SPDX-License-Identifier: GPL-3.0-or-later // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. pragma solidity ^0.7.0; pragma experimental ABIEncoderV2; import "./ILiquidityGauge.sol"; interface ILiquidityGaugeFactory { /** * @notice Returns true if `gauge` was created by this factory. */ function isGaugeFromFactory(address gauge) external view returns (bool); }
// SPDX-License-Identifier: GPL-3.0-or-later // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. pragma solidity ^0.7.0; import "@balancer-labs/v2-solidity-utils/contracts/openzeppelin/IERC20.sol"; import "./ILiquidityGauge.sol"; // For compatibility, we're keeping the same function names as in the original Curve code, including the mixed-case // naming convention. // solhint-disable func-name-mixedcase interface IStakingLiquidityGauge is ILiquidityGauge, IERC20 { function initialize(address lpToken) external; function lp_token() external view returns (IERC20); function deposit(uint256 value, address recipient) external; function withdraw(uint256 value) external; function claim_rewards(address user) external; function add_reward(address rewardToken, address distributor) external; function set_reward_distributor(address rewardToken, address distributor) external; }
{ "optimizer": { "enabled": true, "runs": 9999 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"contract ILiquidityGauge","name":"gauge","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"gauge","type":"address"},{"indexed":true,"internalType":"address","name":"pool","type":"address"}],"name":"GaugeCreated","type":"event"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"create","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"getGaugeImplementation","outputs":[{"internalType":"contract ILiquidityGauge","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"getPoolGauge","outputs":[{"internalType":"contract ILiquidityGauge","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"gauge","type":"address"}],"name":"isGaugeFromFactory","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a060405234801561001057600080fd5b5060405161054b38038061054b83398101604081905261002f91610044565b60601b6001600160601b031916608052610072565b600060208284031215610055578081fd5b81516001600160a01b038116811461006b578182fd5b9392505050565b60805160601c6104b86100936000398060b7528061014a52506104b86000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c806339312dee146100515780639ed933181461006f578063a8ea687514610082578063ce3cc8bd14610095575b600080fd5b6100596100b5565b60405161006691906103e8565b60405180910390f35b61005961007d3660046103ad565b6100d9565b6100596100903660046103ad565b6102aa565b6100a86100a33660046103ad565b6102d5565b6040516100669190610409565b7f000000000000000000000000000000000000000000000000000000000000000090565b73ffffffffffffffffffffffffffffffffffffffff81811660009081526001602052604081205490911615610143576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013a90610414565b60405180910390fd5b600061016e7f0000000000000000000000000000000000000000000000000000000000000000610300565b6040517fc4d66de800000000000000000000000000000000000000000000000000000000815290915073ffffffffffffffffffffffffffffffffffffffff82169063c4d66de8906101c39086906004016103e8565b600060405180830381600087803b1580156101dd57600080fd5b505af11580156101f1573d6000803e3d6000fd5b5050505073ffffffffffffffffffffffffffffffffffffffff81811660008181526020818152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091559488168084529490915280822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001684179055517fbc0aff029cf899fe358381e295caa21dd2e8c1a6607e2b9e6c7ec915db15bd539190a390505b919050565b73ffffffffffffffffffffffffffffffffffffffff9081166000908152600160205260409020541690565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205460ff1690565b60006040517f3d602d80600a3d3981f3363d3d373d3d3d363d7300000000000000000000000081528260601b60148201527f5af43d82803e903d91602b57fd5bf3000000000000000000000000000000000060288201526037816000f091505073ffffffffffffffffffffffffffffffffffffffff81166102a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013a9061044b565b6000602082840312156103be578081fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146103e1578182fd5b9392505050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b60208082526014908201527f476175676520616c726561647920657869737473000000000000000000000000604082015260600190565b60208082526016908201527f455243313136373a20637265617465206661696c65640000000000000000000060408201526060019056fea2646970667358221220c8bcb512d185826a523e34d12bfb4dfb477cb7c3a8e9a517795e546d6b434c8e64736f6c634300070100330000000000000000000000003b8ca519122cdd8efb272b0d3085453404b25bd0
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806339312dee146100515780639ed933181461006f578063a8ea687514610082578063ce3cc8bd14610095575b600080fd5b6100596100b5565b60405161006691906103e8565b60405180910390f35b61005961007d3660046103ad565b6100d9565b6100596100903660046103ad565b6102aa565b6100a86100a33660046103ad565b6102d5565b6040516100669190610409565b7f0000000000000000000000003b8ca519122cdd8efb272b0d3085453404b25bd090565b73ffffffffffffffffffffffffffffffffffffffff81811660009081526001602052604081205490911615610143576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013a90610414565b60405180910390fd5b600061016e7f0000000000000000000000003b8ca519122cdd8efb272b0d3085453404b25bd0610300565b6040517fc4d66de800000000000000000000000000000000000000000000000000000000815290915073ffffffffffffffffffffffffffffffffffffffff82169063c4d66de8906101c39086906004016103e8565b600060405180830381600087803b1580156101dd57600080fd5b505af11580156101f1573d6000803e3d6000fd5b5050505073ffffffffffffffffffffffffffffffffffffffff81811660008181526020818152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091559488168084529490915280822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001684179055517fbc0aff029cf899fe358381e295caa21dd2e8c1a6607e2b9e6c7ec915db15bd539190a390505b919050565b73ffffffffffffffffffffffffffffffffffffffff9081166000908152600160205260409020541690565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205460ff1690565b60006040517f3d602d80600a3d3981f3363d3d373d3d3d363d7300000000000000000000000081528260601b60148201527f5af43d82803e903d91602b57fd5bf3000000000000000000000000000000000060288201526037816000f091505073ffffffffffffffffffffffffffffffffffffffff81166102a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161013a9061044b565b6000602082840312156103be578081fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146103e1578182fd5b9392505050565b73ffffffffffffffffffffffffffffffffffffffff91909116815260200190565b901515815260200190565b60208082526014908201527f476175676520616c726561647920657869737473000000000000000000000000604082015260600190565b60208082526016908201527f455243313136373a20637265617465206661696c65640000000000000000000060408201526060019056fea2646970667358221220c8bcb512d185826a523e34d12bfb4dfb477cb7c3a8e9a517795e546d6b434c8e64736f6c63430007010033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000003b8ca519122cdd8efb272b0d3085453404b25bd0
-----Decoded View---------------
Arg [0] : gauge (address): 0x3b8cA519122CdD8efb272b0D3085453404B25bD0
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 0000000000000000000000003b8ca519122cdd8efb272b0d3085453404b25bd0
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ 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.