Source Code
Overview
ETH Balance
0.0006985 ETH
More Info
ContractCreator
Multichain Info
N/A
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Method | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|---|
Add Execution Fe... | 5711614 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711612 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711610 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711608 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711606 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711604 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711602 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711600 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711598 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711596 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711594 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711592 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711590 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711588 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711586 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711584 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711583 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711581 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711579 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711577 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711575 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711573 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711571 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711569 | 341 days ago | 0.0000005 ETH | ||||
Add Execution Fe... | 5711567 | 341 days ago | 0.0000005 ETH |
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0xD0fd41B4...328521208 The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
ExecutionFees
Compiler Version
v0.8.20+commit.a1b79de6
Optimization Enabled:
Yes with 200 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity 0.8.20; import {ExecutionFeesEvents} from "./events/ExecutionFeesEvents.sol"; import {IExecutionFees} from "./interfaces/IExecutionFees.sol"; import {AccessControl} from "@openzeppelin/contracts/access/AccessControl.sol"; import {Address} from "@openzeppelin/contracts/utils/Address.sol"; contract ExecutionFees is AccessControl, ExecutionFeesEvents, IExecutionFees { bytes32 public constant RECORDER_ROLE = keccak256("RECORDER_ROLE"); /// @inheritdoc IExecutionFees mapping(uint256 chainId => mapping(bytes32 transactionId => uint256 fee)) public executionFee; /// @inheritdoc IExecutionFees mapping(address executor => uint256 totalAccumulated) public accumulatedRewards; /// @inheritdoc IExecutionFees mapping(address executor => uint256 totalClaimed) public unclaimedRewards; /// @inheritdoc IExecutionFees mapping(uint256 chainId => mapping(bytes32 transactionId => address executor)) public recordedExecutor; constructor(address admin) { _grantRole(DEFAULT_ADMIN_ROLE, admin); } // @inheritdoc IExecutionFees function addExecutionFee(uint256 dstChainId, bytes32 transactionId) external payable { if (msg.value == 0) revert ExecutionFees__ZeroAmount(); executionFee[dstChainId][transactionId] += msg.value; // Use the new total fee as the event parameter. emit ExecutionFeeAdded(dstChainId, transactionId, executionFee[dstChainId][transactionId]); address executor = recordedExecutor[dstChainId][transactionId]; // If the executor is recorded, the previous fee has been awarded already. Award the new fee. if (executor != address(0)) { _awardFee(executor, msg.value); } } // @inheritdoc IExecutionFees function recordExecutor( uint256 dstChainId, bytes32 transactionId, address executor ) external onlyRole(RECORDER_ROLE) { if (executor == address(0)) revert ExecutionFees__ZeroAddress(); address previousExecutor = recordedExecutor[dstChainId][transactionId]; if (previousExecutor != address(0)) { revert ExecutionFees__AlreadyRecorded(dstChainId, transactionId, previousExecutor); } uint256 fee = executionFee[dstChainId][transactionId]; recordedExecutor[dstChainId][transactionId] = executor; emit ExecutorRecorded(dstChainId, transactionId, executor); _awardFee(executor, fee); } // @inheritdoc IExecutionFees function claimExecutionFees(address executor) external { uint256 amount = unclaimedRewards[executor]; if (amount == 0) revert ExecutionFees__ZeroAmount(); unclaimedRewards[executor] = 0; Address.sendValue(payable(executor), amount); emit ExecutionFeesClaimed(executor, amount); } /// @dev Award the executor with the fee for completing the transaction. function _awardFee(address executor, uint256 fee) internal { accumulatedRewards[executor] += fee; unclaimedRewards[executor] += fee; emit ExecutionFeesAwarded(executor, fee); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; abstract contract ExecutionFeesEvents { event ExecutionFeeAdded(uint256 dstChainId, bytes32 indexed transactionId, uint256 totalFee); event ExecutorRecorded(uint256 dstChainId, bytes32 indexed transactionId, address indexed executor); event ExecutionFeesAwarded(address indexed executor, uint256 amount); event ExecutionFeesClaimed(address indexed executor, uint256 amount); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; interface IExecutionFees { error ExecutionFees__AlreadyRecorded(uint256 dstChainId, bytes32 transactionId, address executor); error ExecutionFees__ZeroAddress(); error ExecutionFees__ZeroAmount(); /// @notice Add the execution fee for a transaction. The attached value will be added to the /// rewards for the executor completing the transaction. /// Note: this could be used to store the execution fee for a new transaction, or to add more /// funds to the execution fee of an existing transaction. Therefore this function is payable, /// and does not implement any caller restrictions. /// @dev Will revert if the executor is already recorded for the transaction. /// @param dstChainId The chain id of the destination chain. /// @param transactionId The id of the transaction to add the execution fee to. function addExecutionFee(uint256 dstChainId, bytes32 transactionId) external payable; /// @notice Record the executor (who completed the transaction) for a transaction, /// and update the accumulated rewards for the executor. /// @dev Could only be called by the Recorder. /// @param dstChainId The chain id of the destination chain. /// @param transactionId The id of the transaction to record the executor for. /// @param executor The address of the executor who completed the transaction. function recordExecutor(uint256 dstChainId, bytes32 transactionId, address executor) external; /// @notice Allows the executor to claim their unclaimed rewards. /// @dev Will revert if the executor has no unclaimed rewards. function claimExecutionFees(address executor) external; // ═══════════════════════════════════════════════════ VIEWS ═══════════════════════════════════════════════════════ /// @notice Get the accumulated rewards for an executor. /// @param executor The address of the executor to get the rewards for. function accumulatedRewards(address executor) external view returns (uint256 accumulated); /// @notice Get the unclaimed rewards for an executor. /// @param executor The address of the executor to get the rewards for. function unclaimedRewards(address executor) external view returns (uint256 unclaimed); /// @notice Get the total execution fee for a transaction. /// @param dstChainId The chain id of the destination chain. /// @param transactionId The id of the transaction to get the execution fee for. function executionFee(uint256 dstChainId, bytes32 transactionId) external view returns (uint256 fee); /// @notice Get the address of the recorded executor for a transaction. /// @dev Will return address(0) if the executor is not recorded. /// @param dstChainId The chain id of the destination chain. /// @param transactionId The id of the transaction to get the recorded executor for. function recordedExecutor(uint256 dstChainId, bytes32 transactionId) external view returns (address executor); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (access/AccessControl.sol) pragma solidity ^0.8.20; import {IAccessControl} from "./IAccessControl.sol"; import {Context} from "../utils/Context.sol"; import {ERC165} from "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ```solidity * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ```solidity * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. We recommend using {AccessControlDefaultAdminRules} * to enforce additional security measures for this role. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address account => bool) hasRole; bytes32 adminRole; } mapping(bytes32 role => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with an {AccessControlUnauthorizedAccount} error including the required role. */ modifier onlyRole(bytes32 role) { _checkRole(role); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view virtual returns (bool) { return _roles[role].hasRole[account]; } /** * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `_msgSender()` * is missing `role`. Overriding this function changes the behavior of the {onlyRole} modifier. */ function _checkRole(bytes32 role) internal view virtual { _checkRole(role, _msgSender()); } /** * @dev Reverts with an {AccessControlUnauthorizedAccount} error if `account` * is missing `role`. */ function _checkRole(bytes32 role, address account) internal view virtual { if (!hasRole(role, account)) { revert AccessControlUnauthorizedAccount(account, role); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view virtual returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. * * May emit a {RoleGranted} event. */ function grantRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. * * May emit a {RoleRevoked} event. */ function revokeRole(bytes32 role, address account) public virtual onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been revoked `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `callerConfirmation`. * * May emit a {RoleRevoked} event. */ function renounceRole(bytes32 role, address callerConfirmation) public virtual { if (callerConfirmation != _msgSender()) { revert AccessControlBadConfirmation(); } _revokeRole(role, callerConfirmation); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } /** * @dev Attempts to grant `role` to `account` and returns a boolean indicating if `role` was granted. * * Internal function without access restriction. * * May emit a {RoleGranted} event. */ function _grantRole(bytes32 role, address account) internal virtual returns (bool) { if (!hasRole(role, account)) { _roles[role].hasRole[account] = true; emit RoleGranted(role, account, _msgSender()); return true; } else { return false; } } /** * @dev Attempts to revoke `role` to `account` and returns a boolean indicating if `role` was revoked. * * Internal function without access restriction. * * May emit a {RoleRevoked} event. */ function _revokeRole(bytes32 role, address account) internal virtual returns (bool) { if (hasRole(role, account)) { _roles[role].hasRole[account] = false; emit RoleRevoked(role, account, _msgSender()); return true; } else { return false; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/Address.sol) pragma solidity ^0.8.20; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev The ETH balance of the account is not enough to perform the operation. */ error AddressInsufficientBalance(address account); /** * @dev There's no code at `target` (it is not a contract). */ error AddressEmptyCode(address target); /** * @dev A call to an address target failed. The target may have reverted. */ error FailedInnerCall(); /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://consensys.net/diligence/blog/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.8.20/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { if (address(this).balance < amount) { revert AddressInsufficientBalance(address(this)); } (bool success, ) = recipient.call{value: amount}(""); if (!success) { revert FailedInnerCall(); } } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason or custom error, it is bubbled * up by this function (like regular Solidity function calls). However, if * the call reverted with no returned reason, this function reverts with a * {FailedInnerCall} error. * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCallWithValue(target, data, 0); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. */ function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { if (address(this).balance < value) { revert AddressInsufficientBalance(address(this)); } (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResultFromTarget(target, success, returndata); } /** * @dev Tool to verify that a low level call to smart-contract was successful, and reverts if the target * was not a contract or bubbling up the revert reason (falling back to {FailedInnerCall}) in case of an * unsuccessful call. */ function verifyCallResultFromTarget( address target, bool success, bytes memory returndata ) internal view returns (bytes memory) { if (!success) { _revert(returndata); } else { // only check if target is a contract if the call was successful and the return data is empty // otherwise we already know that it was a contract if (returndata.length == 0 && target.code.length == 0) { revert AddressEmptyCode(target); } return returndata; } } /** * @dev Tool to verify that a low level call was successful, and reverts if it wasn't, either by bubbling the * revert reason or with a default {FailedInnerCall} error. */ function verifyCallResult(bool success, bytes memory returndata) internal pure returns (bytes memory) { if (!success) { _revert(returndata); } else { return returndata; } } /** * @dev Reverts with returndata if present. Otherwise reverts with {FailedInnerCall}. */ function _revert(bytes memory returndata) private pure { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly /// @solidity memory-safe-assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert FailedInnerCall(); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (access/IAccessControl.sol) pragma solidity ^0.8.20; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev The `account` is missing a role. */ error AccessControlUnauthorizedAccount(address account, bytes32 neededRole); /** * @dev The caller of a function is not the expected one. * * NOTE: Don't confuse with {AccessControlUnauthorizedAccount}. */ error AccessControlBadConfirmation(); /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `callerConfirmation`. */ function renounceRole(bytes32 role, address callerConfirmation) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol) pragma solidity ^0.8.20; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } function _contextSuffixLength() internal view virtual returns (uint256) { return 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.sol) pragma solidity ^0.8.20; import {IERC165} from "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
{ "remappings": [ "@openzeppelin/=node_modules/@openzeppelin/", "@synapsecns/=node_modules/@synapsecns/", "ds-test/=node_modules/ds-test/src/", "forge-std/=node_modules/forge-std/src/" ], "optimizer": { "enabled": true, "runs": 200 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "paris", "viaIR": false, "libraries": {} }
Contract ABI
API[{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AccessControlBadConfirmation","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32","name":"neededRole","type":"bytes32"}],"name":"AccessControlUnauthorizedAccount","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"AddressInsufficientBalance","type":"error"},{"inputs":[{"internalType":"uint256","name":"dstChainId","type":"uint256"},{"internalType":"bytes32","name":"transactionId","type":"bytes32"},{"internalType":"address","name":"executor","type":"address"}],"name":"ExecutionFees__AlreadyRecorded","type":"error"},{"inputs":[],"name":"ExecutionFees__ZeroAddress","type":"error"},{"inputs":[],"name":"ExecutionFees__ZeroAmount","type":"error"},{"inputs":[],"name":"FailedInnerCall","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"dstChainId","type":"uint256"},{"indexed":true,"internalType":"bytes32","name":"transactionId","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"totalFee","type":"uint256"}],"name":"ExecutionFeeAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"executor","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ExecutionFeesAwarded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"executor","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"ExecutionFeesClaimed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"dstChainId","type":"uint256"},{"indexed":true,"internalType":"bytes32","name":"transactionId","type":"bytes32"},{"indexed":true,"internalType":"address","name":"executor","type":"address"}],"name":"ExecutorRecorded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"RECORDER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"executor","type":"address"}],"name":"accumulatedRewards","outputs":[{"internalType":"uint256","name":"totalAccumulated","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"dstChainId","type":"uint256"},{"internalType":"bytes32","name":"transactionId","type":"bytes32"}],"name":"addExecutionFee","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"executor","type":"address"}],"name":"claimExecutionFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"bytes32","name":"transactionId","type":"bytes32"}],"name":"executionFee","outputs":[{"internalType":"uint256","name":"fee","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"dstChainId","type":"uint256"},{"internalType":"bytes32","name":"transactionId","type":"bytes32"},{"internalType":"address","name":"executor","type":"address"}],"name":"recordExecutor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"chainId","type":"uint256"},{"internalType":"bytes32","name":"transactionId","type":"bytes32"}],"name":"recordedExecutor","outputs":[{"internalType":"address","name":"executor","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"callerConfirmation","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"executor","type":"address"}],"name":"unclaimedRewards","outputs":[{"internalType":"uint256","name":"totalClaimed","type":"uint256"}],"stateMutability":"view","type":"function"}]
Deployed Bytecode
0x6080604052600436106100e85760003560e01c806391d148541161008a578063bea8658111610059578063bea86581146102a9578063d01e09a6146102dd578063d547741f14610336578063ffecec7e1461035657600080fd5b806391d148541461020f578063936fd4db1461022f578063949813b814610267578063a217fddf1461029457600080fd5b80632f2ff15d116100c65780632f2ff15d1461018257806336568abe146101a25780634e497dac146101c257806373f273fc146101e257600080fd5b806301ffc9a7146100ed5780630676b70614610122578063248a9ca314610144575b600080fd5b3480156100f957600080fd5b5061010d61010836600461097b565b610369565b60405190151581526020015b60405180910390f35b34801561012e57600080fd5b5061014261013d3660046109c8565b6103a0565b005b34801561015057600080fd5b5061017461015f3660046109fd565b60009081526020819052604090206001015490565b604051908152602001610119565b34801561018e57600080fd5b5061014261019d366004610a16565b6104e0565b3480156101ae57600080fd5b506101426101bd366004610a16565b61050b565b3480156101ce57600080fd5b506101426101dd366004610a42565b610543565b3480156101ee57600080fd5b506101746101fd366004610a42565b60026020526000908152604090205481565b34801561021b57600080fd5b5061010d61022a366004610a16565b6105e7565b34801561023b57600080fd5b5061017461024a366004610a5d565b600160209081526000928352604080842090915290825290205481565b34801561027357600080fd5b50610174610282366004610a42565b60036020526000908152604090205481565b3480156102a057600080fd5b50610174600081565b3480156102b557600080fd5b506101747ff996da754c790e95d5c7ca3330cfcad529487fe9d1d8edb7afc65076fdf9adb481565b3480156102e957600080fd5b5061031e6102f8366004610a5d565b60046020908152600092835260408084209091529082529020546001600160a01b031681565b6040516001600160a01b039091168152602001610119565b34801561034257600080fd5b50610142610351366004610a16565b610610565b610142610364366004610a5d565b610635565b60006001600160e01b03198216637965db0b60e01b148061039a57506301ffc9a760e01b6001600160e01b03198316145b92915050565b7ff996da754c790e95d5c7ca3330cfcad529487fe9d1d8edb7afc65076fdf9adb46103ca81610708565b6001600160a01b0382166103f157604051630a382b5360e21b815260040160405180910390fd5b60008481526004602090815260408083208684529091529020546001600160a01b03168015610451576040516377d1d6e760e01b815260048101869052602481018590526001600160a01b03821660448201526064015b60405180910390fd5b60008581526001602090815260408083208784528252808320548884526004835281842088855283529281902080546001600160a01b0319166001600160a01b0388169081179091559051888152909187917fd2d84ea2767c19fcb12500825861bc54544855f11841d1195f06bcb8ade9e503910160405180910390a36104d88482610715565b505050505050565b6000828152602081905260409020600101546104fb81610708565b61050583836107aa565b50505050565b6001600160a01b03811633146105345760405163334bd91960e11b815260040160405180910390fd5b61053e828261083c565b505050565b6001600160a01b0381166000908152600360205260408120549081900361057d57604051631c72727560e21b815260040160405180910390fd5b6001600160a01b0382166000908152600360205260408120556105a082826108a7565b816001600160a01b03167fe23da55db72f38bf1669acc38c185416e268baad2a0378ca38e3d445014436ac826040516105db91815260200190565b60405180910390a25050565b6000918252602082815260408084206001600160a01b0393909316845291905290205460ff1690565b60008281526020819052604090206001015461062b81610708565b610505838361083c565b3460000361065657604051631c72727560e21b815260040160405180910390fd5b60008281526001602090815260408083208484529091528120805434929061067f908490610a7f565b909155505060008281526001602090815260408083208484528252918290205482518581529182015282917ff50d0e3a2a325edbbdeb50dbcc13b41ad5faa0b055930f9fd1b5a3b3d8a8e8a9910160405180910390a260008281526004602090815260408083208484529091529020546001600160a01b0316801561053e5761053e8134610715565b610712813361093e565b50565b6001600160a01b0382166000908152600260205260408120805483929061073d908490610a7f565b90915550506001600160a01b0382166000908152600360205260408120805483929061076a908490610a7f565b90915550506040518181526001600160a01b038316907f355f0465685492a677e197d9eaa3fe3d68dcc069796a79c899fd19eb2416c30f906020016105db565b60006107b683836105e7565b610834576000838152602081815260408083206001600160a01b03861684529091529020805460ff191660011790556107ec3390565b6001600160a01b0316826001600160a01b0316847f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a450600161039a565b50600061039a565b600061084883836105e7565b15610834576000838152602081815260408083206001600160a01b0386168085529252808320805460ff1916905551339286917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a450600161039a565b804710156108ca5760405163cd78605960e01b8152306004820152602401610448565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114610917576040519150601f19603f3d011682016040523d82523d6000602084013e61091c565b606091505b505090508061053e57604051630a12f52160e11b815260040160405180910390fd5b61094882826105e7565b6109775760405163e2517d3f60e01b81526001600160a01b038216600482015260248101839052604401610448565b5050565b60006020828403121561098d57600080fd5b81356001600160e01b0319811681146109a557600080fd5b9392505050565b80356001600160a01b03811681146109c357600080fd5b919050565b6000806000606084860312156109dd57600080fd5b83359250602084013591506109f4604085016109ac565b90509250925092565b600060208284031215610a0f57600080fd5b5035919050565b60008060408385031215610a2957600080fd5b82359150610a39602084016109ac565b90509250929050565b600060208284031215610a5457600080fd5b6109a5826109ac565b60008060408385031215610a7057600080fd5b50508035926020909101359150565b8082018082111561039a57634e487b7160e01b600052601160045260246000fdfea26469706673582212207b1a0c3bed0b670ac3d604bb89cb3172172395b03eff01fbd98dd576b65cad0464736f6c63430008140033
Loading...
Loading
Loading...
Loading
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.