Description:
Smart contract deployed on Ethereum.
Blockchain: Ethereum
Source Code: View Code On The Blockchain
Solidity Source Code:
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.30;
/// @title BurnVerifierL1
/// @author Shibburn.com
/// @notice Finalizes verified burn reports from Base (L2) and triggers the actual SHIB burn on Ethereum.
/// @dev Hardcoded and permissionless — anyone may call finalizeBurn() once a report is verified.
interface IShibburnL1 {
function burn(uint256 amount) external;
}
contract BurnVerifierL1 {
/// @notice Verified ShibburnL1 contract on Ethereum that executes the real burn
IShibburnL1 public constant SHIBBURN_L1 = IShibburnL1(0x5476E7F4d7691359504875D256B5B8533B8eE173);
/// @notice Tracks already executed burn reports to prevent duplicates
mapping(bytes32 => bool) public executedReports;
/// @notice Emitted whenever a burn is finalized on L1
event ReportFinalized(bytes32 indexed reportId, uint256 amount, uint256 timestamp);
/// @notice Finalizes a verified burn report and triggers a real SHIB burn.
/// @param reportId Unique report ID emitted by BurnReporterL2 on Base
/// @param amount Amount of SHIB to burn (in wei)
function finalizeBurn(bytes32 reportId, uint256 amount) external {
require(!executedReports[reportId], "already executed");
require(amount > 0, "amount=0");
executedReports[reportId] = true;
SHIBBURN_L1.burn(amount);
emit ReportFinalized(reportId, amount, block.timestamp);
}
/// @notice Helper view — checks if a report was already finalized
function isExecuted(bytes32 reportId) external view returns (bool) {
return executedReports[reportId];
}
}
Submitted on: 2025-10-18 11:30:48
Comments
Log in to comment.
No comments yet.