ETH Price: $3,317.18 (+3.70%)

Contract

0xe07b8FA0D41800ff5Ef828080c4ED7837495fEd7
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Commit213086512024-12-01 15:46:5945 days ago1733068019IN
0xe07b8FA0...37495fEd7
0 ETH0.0053242924.10424675
Commit212761732024-11-27 2:42:2350 days ago1732675343IN
0xe07b8FA0...37495fEd7
0 ETH0.00178598.17933456
Commit211343052024-11-07 7:32:5970 days ago1730964779IN
0xe07b8FA0...37495fEd7
0 ETH0.002095979.55843851
Commit210211222024-10-22 12:28:5985 days ago1729600139IN
0xe07b8FA0...37495fEd7
0 ETH0.0016460910.68704471
Commit206041792024-08-25 7:41:11144 days ago1724571671IN
0xe07b8FA0...37495fEd7
0 ETH0.00018371.1950267
Commit205869202024-08-22 21:45:23146 days ago1724363123IN
0xe07b8FA0...37495fEd7
0 ETH0.00015941.01511612
Commit204251132024-07-31 7:42:35169 days ago1722411755IN
0xe07b8FA0...37495fEd7
0 ETH0.000835565.24956923
Commit200116412024-06-03 13:37:47226 days ago1717421867IN
0xe07b8FA0...37495fEd7
0 ETH0.0028196618.24010151
Commit199100452024-05-20 8:48:23241 days ago1716194903IN
0xe07b8FA0...37495fEd7
0 ETH0.000582563.55105697
Commit196542962024-04-14 14:13:35276 days ago1713104015IN
0xe07b8FA0...37495fEd7
0 ETH0.0023491814.75875544
Commit196225412024-04-10 3:26:59281 days ago1712719619IN
0xe07b8FA0...37495fEd7
0 ETH0.0026046615.70076537
Commit195315082024-03-28 8:45:59294 days ago1711615559IN
0xe07b8FA0...37495fEd7
0 ETH0.0036669422.95084168
Commit195315062024-03-28 8:45:35294 days ago1711615535IN
0xe07b8FA0...37495fEd7
0 ETH0.0040560725.48284601
Commit194442082024-03-16 1:29:35306 days ago1710552575IN
0xe07b8FA0...37495fEd7
0 ETH0.0009693535.77087097
Commit193752272024-03-06 9:26:59316 days ago1709717219IN
0xe07b8FA0...37495fEd7
0 ETH0.0109848367.96916859
Commit193526252024-03-03 5:42:11319 days ago1709444531IN
0xe07b8FA0...37495fEd7
0 ETH0.0067860141.99007
Commit193504552024-03-02 22:26:35319 days ago1709418395IN
0xe07b8FA0...37495fEd7
0 ETH0.0068810744.34050778
Commit192950462024-02-24 4:25:35327 days ago1708748735IN
0xe07b8FA0...37495fEd7
0 ETH0.0033161720.49831254
Commit188888342023-12-29 4:22:59384 days ago1703823779IN
0xe07b8FA0...37495fEd7
0 ETH0.0025938718.64409563
Commit185662332023-11-13 23:22:59429 days ago1699917779IN
0xe07b8FA0...37495fEd7
0 ETH0.0044014330.6602492
Commit183873542023-10-19 22:26:47454 days ago1697754407IN
0xe07b8FA0...37495fEd7
0 ETH0.0021683414.72242414
Commit183649072023-10-16 19:04:35457 days ago1697483075IN
0xe07b8FA0...37495fEd7
0 ETH0.0015757610.46373589
Commit183649062023-10-16 19:04:23457 days ago1697483063IN
0xe07b8FA0...37495fEd7
0 ETH0.0015080110.23894467
Commit183649052023-10-16 19:04:11457 days ago1697483051IN
0xe07b8FA0...37495fEd7
0 ETH0.0015447110.46659616
Commit183649052023-10-16 19:04:11457 days ago1697483051IN
0xe07b8FA0...37495fEd7
0 ETH0.0015155310.46659616
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:
CommitGaugeStatus

Compiler Version
v0.8.10+commit.fc410830

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 4 : CommitGaugeStatus.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.10;

import "./interfaces/ICurveGauge.sol";
import "./interfaces/IGaugeController.sol";
import "./interfaces/IZkEvmBridge.sol";

contract CommitGaugeStatus {

    bytes4 private constant updateSelector = bytes4(keccak256("setGauge(address,bool,uint256)"));
    address public constant gaugeController = address(0x2F50D538606Fa9EDD2B11E2446BEb18C9D5846bB);
    address public constant bridge = address(0x2a3DD3EB832aF982ec71669E178424b10Dca2EDe);
    uint256 public constant epochDuration = 86400 * 7;
    
    function currentEpoch() public view returns (uint256) {
        return block.timestamp/epochDuration*epochDuration;
    }

    function commit(
        address _gauge,
        address _contractAddr
    ) external  {
        //check killed for status
        bool active = isValidGauge(_gauge);

        //build data
        bytes memory data = abi.encodeWithSelector(updateSelector, _gauge, active, currentEpoch());

        //submit to L2
        uint32 destinationNetwork = 1;
        bool forceUpdateGlobalExitRoot = true;
        IZkEvmBridge(bridge).bridgeMessage{value:0}(
            destinationNetwork,
            _contractAddr,
            forceUpdateGlobalExitRoot,
            data
        );
    }

    function isValidGauge(address _gauge) public view returns(bool){
        return IGaugeController(gaugeController).get_gauge_weight(_gauge) > 0 && !ICurveGauge(_gauge).is_killed();
    }
}

File 2 of 4 : IZkEvmBridge.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.10;


interface IZkEvmBridge{
	function bridgeMessage(
		uint32 destinationNetwork,
		address destinationAddress,
		bool forceUpdateGlobalExitRoot,
		bytes calldata metadata
	) external payable;
}

File 3 of 4 : IGaugeController.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.10;

interface IGaugeController {
    function get_gauge_weight(address _gauge) external view returns(uint256);
    function vote_user_slopes(address,address) external view returns(uint256,uint256,uint256);//slope,power,end
    function vote_for_gauge_weights(address,uint256) external;
    function add_gauge(address,int128,uint256) external;
}

File 4 of 4 : ICurveGauge.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.10;

interface ICurveGauge {
    function is_killed() external view returns(bool);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[],"name":"bridge","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_gauge","type":"address"},{"internalType":"address","name":"_contractAddr","type":"address"}],"name":"commit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"currentEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"epochDuration","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"gaugeController","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_gauge","type":"address"}],"name":"isValidGauge","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]

608060405234801561001057600080fd5b506104e0806100206000396000f3fe608060405234801561001057600080fd5b50600436106100625760003560e01c80634ff0876a14610067578063766718081461008457806399eecb3b1461008c578063bb82717b146100bf578063dd7fb65b146100d4578063e78cea92146100f7575b600080fd5b61007162093a8081565b6040519081526020015b60405180910390f35b610071610112565b6100a7732f50d538606fa9edd2b11e2446beb18c9d5846bb81565b6040516001600160a01b03909116815260200161007b565b6100d26100cd366004610350565b610131565b005b6100e76100e2366004610383565b610241565b604051901515815260200161007b565b6100a7732a3dd3eb832af982ec71669e178424b10dca2ede81565b600062093a8061012281426103a5565b61012c91906103c7565b905090565b600061013c83610241565b905060007f22f6277b2efe600733069d522cf5aca244295c74c9337c4b357a6e5619799440848361016b610112565b6040516001600160a01b0390931660248401529015156044830152606482015260840160408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909416939093179092529051630481fe6f60e31b81529091506001908190732a3dd3eb832af982ec71669e178424b10dca2ede9063240ff378906000906102079085908a9082908a906004016103f4565b6000604051808303818588803b15801561022057600080fd5b505af1158015610234573d6000803e3d6000fd5b5050505050505050505050565b60405163273c8d1d60e11b81526001600160a01b03821660048201526000908190732f50d538606fa9edd2b11e2446beb18c9d5846bb90634e791a3a90602401602060405180830381865afa15801561029e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102c2919061046f565b11801561032e5750816001600160a01b0316639c868ac06040518163ffffffff1660e01b8152600401602060405180830381865afa158015610308573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061032c9190610488565b155b92915050565b80356001600160a01b038116811461034b57600080fd5b919050565b6000806040838503121561036357600080fd5b61036c83610334565b915061037a60208401610334565b90509250929050565b60006020828403121561039557600080fd5b61039e82610334565b9392505050565b6000826103c257634e487b7160e01b600052601260045260246000fd5b500490565b60008160001904831182151516156103ef57634e487b7160e01b600052601160045260246000fd5b500290565b63ffffffff851681526000602060018060a01b03861681840152841515604084015260806060840152835180608085015260005b818110156104445785810183015185820160a001528201610428565b8181111561045657600060a083870101525b50601f01601f19169290920160a0019695505050505050565b60006020828403121561048157600080fd5b5051919050565b60006020828403121561049a57600080fd5b8151801515811461039e57600080fdfea2646970667358221220bdb8f48e30f200920f9119070b3e2e20cae6003389ab99c0fa238ed832fd83cd64736f6c634300080a0033

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100625760003560e01c80634ff0876a14610067578063766718081461008457806399eecb3b1461008c578063bb82717b146100bf578063dd7fb65b146100d4578063e78cea92146100f7575b600080fd5b61007162093a8081565b6040519081526020015b60405180910390f35b610071610112565b6100a7732f50d538606fa9edd2b11e2446beb18c9d5846bb81565b6040516001600160a01b03909116815260200161007b565b6100d26100cd366004610350565b610131565b005b6100e76100e2366004610383565b610241565b604051901515815260200161007b565b6100a7732a3dd3eb832af982ec71669e178424b10dca2ede81565b600062093a8061012281426103a5565b61012c91906103c7565b905090565b600061013c83610241565b905060007f22f6277b2efe600733069d522cf5aca244295c74c9337c4b357a6e5619799440848361016b610112565b6040516001600160a01b0390931660248401529015156044830152606482015260840160408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909416939093179092529051630481fe6f60e31b81529091506001908190732a3dd3eb832af982ec71669e178424b10dca2ede9063240ff378906000906102079085908a9082908a906004016103f4565b6000604051808303818588803b15801561022057600080fd5b505af1158015610234573d6000803e3d6000fd5b5050505050505050505050565b60405163273c8d1d60e11b81526001600160a01b03821660048201526000908190732f50d538606fa9edd2b11e2446beb18c9d5846bb90634e791a3a90602401602060405180830381865afa15801561029e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102c2919061046f565b11801561032e5750816001600160a01b0316639c868ac06040518163ffffffff1660e01b8152600401602060405180830381865afa158015610308573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061032c9190610488565b155b92915050565b80356001600160a01b038116811461034b57600080fd5b919050565b6000806040838503121561036357600080fd5b61036c83610334565b915061037a60208401610334565b90509250929050565b60006020828403121561039557600080fd5b61039e82610334565b9392505050565b6000826103c257634e487b7160e01b600052601260045260246000fd5b500490565b60008160001904831182151516156103ef57634e487b7160e01b600052601160045260246000fd5b500290565b63ffffffff851681526000602060018060a01b03861681840152841515604084015260806060840152835180608085015260005b818110156104445785810183015185820160a001528201610428565b8181111561045657600060a083870101525b50601f01601f19169290920160a0019695505050505050565b60006020828403121561048157600080fd5b5051919050565b60006020828403121561049a57600080fd5b8151801515811461039e57600080fdfea2646970667358221220bdb8f48e30f200920f9119070b3e2e20cae6003389ab99c0fa238ed832fd83cd64736f6c634300080a0033

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.